[Paraview] python exodus parsing segaults

Julian A. Quick jaquick at humboldt.edu
Sat Dec 2 13:34:13 EST 2017


Hello All,

I wrote a python script using the Paraview ExodusIIReader to convert exodus
II files into csv's. The script usually runs successfully, but sometimes I
get a segfault. Am I missing something? How might I be able to better
handle memory in this code? I tried pasting the reset function I found on
the mailing list
<https://public.kitware.com/pipermail/paraview/2015-July/034588.html> to
the top of the code but it did not seem to help. I appreciate your time and
support.


from paraview.simple import *
from paraview.numpy_support import vtk_to_numpy
import vtk.numpy_interface.dataset_adapter as dsa
import sys
s = ExodusIIReader(FileName='./results/%s.e'%sys.argv[-1])
d = CreateWriter('./out.csv', s)
Delete(d)
d.FieldAssociation = "Points"
d.UpdatePipeline(time=s.TimestepValues[-1])
Delete(s)
Delete(d)
del d



$ pvpython mycode.py my_ecodus_file
$ pvpython mycode.py my_ecodus_file
Segmentation fault: 11


Thanks,
Julian
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview/attachments/20171202/e8a4fdf0/attachment.html>


More information about the ParaView mailing list