Re: [matplotlib-devel] Removing lines leaks memory

2010-05-28 Thread Pearu Peterson
Thanks, John! Calling ax.autoscale_view after ax.relim makes the script work. Best regards, Pearu -- ___ Matplotlib-devel mailing list Matplotlib-devel@lists.sourceforge.net

Re: [matplotlib-devel] Removing lines leaks memory

2010-05-28 Thread Pearu Peterson
Thanks, John! Adding ax.autoscale_view after ax.relim makes the script work correctly. Best regards, Pearu -- ___ Matplotlib-devel mailing list Matplotlib-devel@lists.sourcef

Re: [matplotlib-devel] Removing lines leaks memory

2010-05-28 Thread Pearu Peterson
On Fri, May 28, 2010 9:15 pm, John Hunter wrote: > On Fri, May 28, 2010 at 1:04 PM, Pearu Peterson wrote: > >> Regarding reusing existing line --- I have understood that this >> will work only if the length of the line data does not change. > > This is not correct --

Re: [matplotlib-devel] Removing lines leaks memory

2010-05-28 Thread Pearu Peterson
On Fri, May 28, 2010 5:12 pm, John Hunter wrote: > Hey Pearu -- thanks for the report. We'll try and track down and fix > this leak. In the interim, would an acceptable work around for you be > to *reuse* an existing line by calling set_data on it. That way you > wouldn't have to do the add/rem

[matplotlib-devel] Removing lines leaks memory

2010-05-28 Thread Pearu Peterson
Hi, In an application that updates a plot with new experimental data, say, every second and the experiment can last hours, I have tried two approaches: 1) clear axes and plot new experimental data - this is slow and takes too much cpu resources. 2) remove lines and plot new experimental data - th