[vtkusers] Passing data between VTK and NumPy.
Maurice van de Rijzen
maurice at akst.tn.tudelft.nl
Tue Sep 17 12:12:32 EDT 2002
Dear all,
I'm using VTK to visualize 5D-data.
However, VTK cannot handle 5D-data. I thought I had a solution but there
are still some things that I don't know how to solve.
I can put all the data of the 5D-data and the dimensions into a long 1D
vtkStructuredPoints.
Later on I can reconstruct the 5D-dataset by using these dimensions.
This 1D vtkStructuredPoints can be used as input in an instance of
vtkProgrammableFilter.
Using the SetExecuteMethod I want to implement a method to select some
'3D-slices' of the 5D-dataset.
The wat I want to implement the slicing is by using NumPy(A fast
Numerical Extension of python).
The problem is that I don't know how to get the data from the
SetExecuteMethod into NumPy.
Afaik know NumPy can read from strings and files.
Do I need to convert the data into a string?
Is there a way to 'say' to NumPy where in memory the 5D-dataset starts?
Does someone has experience in using NumPy in combination with VTK?
More information about the vtkusers
mailing list