[Paraview] Python Scripting Memory Overload

2012-12-19 Thread Sebastian
Hello, I am running Paraview in batch mode using a Python script to analyze my data. However, after looping through few files ny script gets terminated because of a memory overload. Is it possible to deallocate the used memory after a file has been processed? Currently I am using the "Delete()"

Re: [Paraview] Python Scripting Memory Overload

2012-12-19 Thread Karl König
Hi Sebastian, What version of ParaView are you using? Pre-3.14 suffered from http://www.paraview.org/Bug/view.php?id=12424. An issue similar to what you described and a workaround for it got discussed last year, see http://markmail.org/message/72qrmqwjaxmgsa7h. Karl Sebastian wrote, On 19.12.20

Re: [Paraview] Python Scripting Memory Overload

2012-12-19 Thread Sebastian
Hello Karl, thank you for your message. I am using Paraview 3.14.1 (64bit). This is what my script looks like: # SETTINGS directory_pvtu= '/scratch/mesh3mm_SEM/' directory_csv = '/scratch/mesh3mm_SEM/Z085_velocity_data/' file_number_start = 373527 file_number_end = 640332 file_interval

Re: [Paraview] Python Scripting Memory Overload

2012-12-19 Thread David E DeMarle
Not sure why it isn't garbage collecting for you, but you might try moving the entire pipeline setup out of the loop and then inside the loop just call the two set filenames to modify the existing pipeline before calling Write(). David E DeMarle Kitware, Inc. R&D Engineer 21 Corporate Drive Clifto

Re: [Paraview] Python Scripting Memory Overload

2012-12-19 Thread Andy Bauer
I believe the filter won't get deleted until after the proxy goes out of scope. If I'm right, you need to call Delete() on it and then have the variable that's holding the proxy either go out of scope or set to something else. Andy On Wed, Dec 19, 2012 at 4:36 PM, David E DeMarle wrote: > Not su

Re: [Paraview] Python Scripting Memory Overload

2012-12-19 Thread Pat Marion
I think you need to replace "del writer" with "Delete(writer)". ParaView has a proxy manager that keeps all proxies. Proxies will not be deleted when the python reference is deleted, you must explicitly call paraview.simple.Delete(). The return value of CreateWriter is a proxy, so it must be Del

Re: [Paraview] Python Scripting Memory Overload

2012-12-20 Thread Sebastian
Hello, thank you for your messages. I tried changing "del writer" to "Delete(writer)". However, I get the following error now: Traceback (most recent call last): File "/scratch/mesh3mm/Z085_velocity_data.py", line 41, in Delete(writer) File "/software/paraview/3.14.1/lib/paraview-3.14/sit

Re: [Paraview] Python Scripting Memory Overload

2012-12-20 Thread Sebastian
Hello again, the memory leak has definitely something to do with the writer as everything works well when I run my script without it. Is there any other way to delete the writer after a file has been processed? Best, Sebastian ___ Powered by www.kit