← Back to team overview

yade-users team mailing list archive

[Question #698346]: Why VTKExporter does not work?

 

New question #698346 on Yade:
https://answers.launchpad.net/yade/+question/698346

I load a saved file of simulation and after loading it, I import every function in original script. every thing is good but it does n`t export VTK.

When I run main script (not saved file) , all things are ok and data export to VTK . Here is its code:

"
os.mkdir(O.tags['id'])   

ClumpVtkData = expt.VTKExporter(O.tags['id']+'/'+'clumpData')            
def VTKview():
    for b in O.bodies:
        ClumpVtkData.exportSpheres(ids='all', what={('color','b.shape.color')})
        ClumpVtkData.exportFacets(ids='all', what={('color','b.shape.color')})

O.engines=O.engines+[PyRunner(iterPeriod=70000,command='VTKview()',label="VTKview")] 
"

But now in saved file, I could n`t export any vtk file.  (I import all codes above in terminal after loading saved file, but something is wrong .)
When I type     VTKview()       in terminal (when saved file of simulation is running), it says: 

"global name 'ClumpVtkData' is not defined"

Please help me.

Best regards,

ubuntu : 18.04
yade 2018.02b



-- 
You received this question notification because your team yade-users is
an answer contact for Yade.