how to use the vti file to make a picture by python

419 views
Skip to first unread message

HT.T

unread,
Jan 29, 2021, 9:56:04 AM1/29/21
to gprMax-users
Hello guys! I am bothered by how to use  a vti file  to build a picture  by python not paraview,  I need  some  help
Thanks!
HT.T

Craig Warren

unread,
Jan 29, 2021, 3:59:48 PM1/29/21
to gprMax-users
There is a VTK toolkit for Python which you could look at - https://pypi.org/project/vtk/ This might allow you to convert the file to a numpy array and then display as an image. Why do you want to do this? It may be OK for smaller 2D geometries, but will most likely be quite slow and tricky for bigger 3D models.

Kind regards,

Craig

HT.T

unread,
Feb 2, 2021, 7:21:28 AM2/2/21
to gprMax-users
Thank you! When I used vtkDataSetReader or vtkXMLImageDataReader to open my vti  file, there was a mistake 'ValueError: could not extract hexadecimal address from argument string',But I can use paraview to open the vti file.
Reply all
Reply to author
Forward
0 new messages