Hi, I posted this on maplotlib-users list, but got no reply. I guess that bugs should rather be reported here...
I have noticed a memory leak when using pylab.pcolor. Here is the code, fa() and fb() do the same thing. The difference is the size of the array which is passed to pcolor. With a large array pcolor leaks but not with a small one. Cheers, Ben import numpy as np import matplotlib matplotlib.use('Agg') from matplotlib import pylab def fa(): """ This function leaks. """ a = np.arange(1024**2) a = a.reshape(1024,1024) for i in range(1): pylab.pcolor(a) pylab.close() def fb(): """This function does not leak. """ b = np.arange(1024) b = b.reshape(32,32) for i in range(1024): pylab.pcolor(b) pylab.close() ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Matplotlib-devel mailing list Matplotlib-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-devel