I am trying to write a python programmable filter which calculates statistics across multiple input datasets and outputs those as a vtkTable.
All is ok for numeric values. But I can't seem to get any approach to work for outputting a vtkTable column of string values. Using numpy_interface/dataset_adapter.py is the cleanest approach I've yet tried for appending columns of numeric values to an output dataset of type vtkTable, but it raises the following error on string-valued arrays: > Traceback (most recent call last): File "<string>", line 29, in <module> File "<string>", line 14, in RequestData File "C:\Program > Files\ParaView\lib\paraview-5.0\site-packages\vtk\numpy_interface\dataset_adapter.py", > line 648, in append narray = narray * numpy.ones(arrLength) TypeError: only integer arrays with one element can be converted to an index Can someone please post an example python programmable filter that outputs a vtkTable which includes a column of string valued data? I have attached a minimal script which reproduces the problem. Thanks.... Dean Neumann
numpy_fail.py
Description: Binary data
_______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the ParaView Wiki at: http://paraview.org/Wiki/ParaView Search the list archives at: http://markmail.org/search/?q=ParaView Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/paraview
