I’ve been testing matplotlib and basemap (0.98.x and 0.99.x via svn source) and python 2.6 (via svn) on ubuntu 8.04 (AMD-64).
I noticed that calling basemap in a loop results in a fairly steep linear increase in memory use; I burn though 6 Gb in a minute.
Putting a loop in plotmap.py from the provided examples does this as well, so I don’t think it’s something I’m doing.
Any ideas?
Thanks.
Mike
P.S. Note that I’d like to use python 2.6 for the multiprocessing module (not in use in this script as of yet). My base install of python 2.5 with matplotlib and basemap (0.98.3 and 0.99.1 via sourceforge sourse) works fine.
Mike Bauer wrote:
I've been testing matplotlib and basemap (0.98.x and 0.99.x via svn source) and python 2.6 (via svn) on ubuntu 8.04 (AMD-64).
I noticed that calling basemap in a loop results in a fairly steep linear increase in memory use; I burn though 6 Gb in a minute.
Putting a loop in plotmap.py from the provided examples does this as well, so I don't think it's something I'm doing.
Any ideas?
Thanks.
Mike
P.S. Note that I'd like to use python 2.6 for the multiprocessing module (not in use in this script as of yet). My base install of python 2.5 with matplotlib and basemap (0.98.3 and 0.99.1 via sourceforge sourse) works fine.
Mike: Note that you don't actually need to recreate the basemap instance each time through the loop (since the map projection region is not changing).
AFAIK there are no serious memory leaks in basemap with python 2.5 - so if you can provide an example that triggers one I'd like to see it.
Sounds like it might only be occurring with python 2.6?
-Jeff
···
--
Jeffrey S. Whitaker Phone : (303)497-6313
Meteorologist FAX : (303)497-6449
NOAA/OAR/PSD R/PSD1 Email : Jeffrey.S.Whitaker@...259...
325 Broadway Office : Skaggs Research Cntr 1D-113
Boulder, CO, USA 80303-3328 Web : Jeffrey S. Whitaker: NOAA Physical Sciences Laboratory