Dear all,

I have a very short python script to import a pvd-file (with associated 
.vtu-files) and simply save the same data in csv-format (see at the bottom of 
the message). Using:


writer.WriteAllTimeSteps = 1


I can easily make sure that paraview saves all my time steps in subsequent 
order (without introducing a loop). The script works fine, but as of now I just 
have to wait with no screen output whilst all files are created. My question is 
therefore, is there a way to print the current time step that is being saved, 
such that I can see the progress (if I want)? Is there some kind of 
write.WriteCurrentTimeStep?


Thanks for your help,


/David


SCRIPT:


from paraview.simple import *
import sys
import os
print "Importing "+sys.argv[1]
print "Creating "+sys.argv[2]
inp = os.getcwd()+"/"+sys.argv[1]
csv_output_directory = os.getcwd()+"/csv"
outp = csv_output_directory+"/"+sys.argv[2]
os.system('mkdir '+csv_output_directory)
reader = OpenDataFile(inp)
#writer = simple.CreateWriter("path/to/solution.csv", reader)
writer = CreateWriter(outp, reader)
writer.WriteAllTimeSteps = 1
writer.FieldAssociation = "Points"
writer.UpdatePipeline()
exit()

_______________________________________________
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

Reply via email to