RE: [SciPy-user] Help needed: Problem in translating a file readroutine from Matlab to Python-Scipy
![](https://secure.gravatar.com/avatar/decc9162d0c3bfcf58a9bfb7737fa126.jpg?s=120&d=mm&r=g)
Thank you to Travis and Stephen for the help ! Now all work correcly. What I am trying to do now I to write my processed data in VTK format (in fact VTR - non uniform rectangular grid with various point and cell data). I am trying to use pyvtk: do you think is possible to write COMPRESSED files? Visualisation of post-processed files will pick up files in VTK format; now I am using ParaView but I am thinking to move to MayaVi, directly from Python... Luca Guasina
![](https://secure.gravatar.com/avatar/ae8af6eeaed0dff0f9d6a06548e7dae5.jpg?s=120&d=mm&r=g)
"GL" == Guasina Luca <L.Guasina@barilla.it> writes:
GL> Thank you to Travis and Stephen for the help ! Now all work GL> correcly. What I am trying to do now I to write my processed GL> data in VTK format (in fact VTR - non uniform rectangular grid GL> with various point and cell data). I am trying to use pyvtk: GL> do you think is possible to write COMPRESSED files? If you mean the XML output format, I don't think pyvtk will help you. However, in the VTK sources there is a file called Utilities/vtk2xml.py that you can use to convert an old style VTK file to an XML file. If you don't have the VTK sources handy grab the file from here: http://www.ae.iitm.ac.in/~prabhu/software/code/mayavi/vtk2xml.py It supports compressing the file also, so perhaps you can generate a temporary file using pyvtk, convert it using vtk2xml and then use that file. cheers, prabhu
participants (2)
-
Guasina Luca
-
Prabhu Ramachandran