![]() ![]() ('output data = ', VTKArray(, shape=(0L, 534L), dtype=float64)Īs seen from the output, the object type is UnstructuredGrid, the "ID_half" key has been added, but the data in the output object is empty. The output in the output window when applying the filter is ('output object = ', ) Writing the Python scripts for these views is somewhat more complicated than writing the scripts for Programmable Sources and Filters, and is only recommended to more advanced users. Note that all the vtkDataSet calls have now been switched to vtkUnstructuredGrid. Paraview - Advanced: Python View ParaView allows you to create customized views in which you can display visualization pipeline data in new ways. Output = dsa.WrapDataObject(vtkUnstructuredGrid.GetData(outInfo)) Input0 = dsa.WrapDataObject(vtkUnstructuredGrid.GetData(inInfo)) I have rewritten the custom filter as follows: from vtkmodules.vtkCommonDataModel import vtkDataSet, vtkUnstructuredGrid I still cannot access the output data in the ParaView data pipeline. Making the object type consistent did not solve the problem. However, nothing is outputted into the pipeline. I’m hoping to apply this filter and get a new cell data entry named “ID_half”.Ĭurrently, I am able to load the filter and apply it. The data set contains cell data named “ID”. The above filter is applied to a data set that has been loaded into the pipeline. ![]() Output = dsa.WrapDataObject(vtkDataSet.GetData(outInfo)) Input0 = dsa.WrapDataObject(vtkDataSet.GetData(inInfo)) I’ve adopted the “Half V Filter” example in the chapter 12.4 of the ParaView guide for my particular dataset: from vtkmodules.vtkCommonDataModel import vtkDataSetįrom import VTKPythonAlgorithmBaseįrom vtkmodules.numpy_interface import dataset_adapter as dsaįrom import smproxy, smproperty, ID HalfIDFilter(VTKPythonAlgorithmBase):ĭef RequestData(self, request, inInfo, outInfo): I am trying to use the VTKPythonAlgorithmBase approach to create a custom filter plugin that will send the filter output back to the ParaView pipeline. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |