Prabhu Ramachandran wrote:
>>>>>> "Juerg" == Juerg Schmidli <[EMAIL PROTECTED]> writes:
> 
>     Juerg> Hi I have four-dimensional data stored in a netcdf file and
>     Juerg> want to create an isosurface visualization for each time
>     Juerg> step in the file (>100 times) and save the resulting image
>     Juerg> as a PNG-file.
> 
>     Juerg> The problem is that after a few iterations I run out of
>     Juerg> memory. How do I correctly destroy the tvtk and mayavi
>     Juerg> objects which I have created before entering into the next
>     Juerg> iteration?
> 
> Can you try again now after you update from SVN?  I think I may have
> fixed a potential cause of the problem.  You may also want to do
> 
> import gc
> gc.collect() 
> 
> a few times to collect reference cycles.

Thanks, the memory is now beeing freed up.

I do have a follow-up question. I've noticed that with the current
implementation (on-screen rendering) I cannot switch to any another
window (or lock the screen) without getting "errors" (e.g. other
windows) in the png-files. I've tried the offscreen.py example shipped
with mayavi, but this produces only garbage in the png-file.

Running the offscreen example produces first a small NON-BLACK popup
window (with the scene visible). The window including the scene is then
briefly enlarged (propabely due to the win.scene.save command), but the
PNG output is garbage. (The PNG output from my on-screen rendering
example works fine).

What is the best way forward in order to run the script (on-screen or
off-screen) but still being able to switch windows and work with other
applications while the script is running?

Thanks,
Juerg

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
MayaVi-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mayavi-users

Reply via email to