[Matplotlib-users] Memory leak in Agg backend?

2009-04-15 Thread Jesper Larsen
Hi matplotlib developers and users, I have had some problems with a memory leak in a long running matplotlib based web application that I have developed (www.worldwildweather.com). I believe the problem is due to a memory leak in the Agg backend but I am not sure. Below is a script which for me re

[Matplotlib-users] memory leak in Agg backend

2007-07-13 Thread Emanuele Passera
Hi all, a few hours ago I have wtitten for a possible memory leak in Agg backend. It was my fault. It was a bad placement of matplotlibrc file. Sorry for the raised alarm. Instead i am glad to say that I have checked for the Agg backend with a for statement of opening a figure, drawing, saving and

Re: [Matplotlib-users] Memory leak in Agg backend?

2009-04-17 Thread Andres Luhamaa
Michael Droettboom wrote: > I am not able to reproduce this leak here with 0.98.6svn from today on > RHEL4. What platform are you on? > > (See attached massif profile -- the memory usage is flat...) > > Mike Well, in my setup I see similar behaviour as in the initial question. Ubuntu 8.10 32bit,

Re: [Matplotlib-users] Memory leak in Agg backend?

2009-04-17 Thread Michael Droettboom
Are you able to run it inside of valgrind's massif tool? Calling out to ps can be a bit spurious (particularly with a memory-pooling Python build) especially for a leak this small. Mike Andres Luhamaa wrote: > Michael Droettboom wrote: > >> I am not able to reproduce this leak here with 0.9

Re: [Matplotlib-users] Memory leak in Agg backend?

2009-04-17 Thread Andres Luhamaa
Well, I have never used it before but here is the output from valgrind masstif, can you figure out something from this? The mem usage from python was still increasing. Andres Michael Droettboom wrote: Are you able to run it inside of valgrind's massif tool? Calling out to ps can be a bit spu

Re: [Matplotlib-users] Memory leak in Agg backend?

2009-04-22 Thread Jesper Larsen
Hi Michael and others, Sorry for the late answer. I am on Ubuntu 8.10. Unfortunately I have not had time to look any more into the issue (which might very well be an error on my part) but I will return when I have more info (I have made a temporary fix). I tried using valgrind-massif to reproduce

Re: [Matplotlib-users] Memory leak in Agg backend?

2009-04-22 Thread Jesper Larsen
I forgot to mention that it seems like the issue is related to the Figure object (and not any foreign language extensions?). When a fig.clf() is added before the call to report_memory the memory usage is constant. Since I am reusing the Figure instance this is a problem for me. But maybe I just nee