Memory usage

Werner,

Recently I reported a batch plot memory issue when using
mostly matlab-style commands and TkAgg backend. In my case
I found that the memory increased when I called close().
If I stopped using this the memory use became more or less
constant. Based on Fernando Perez's comments I also
started using import gc and gc.collect() to reduce memory
use more. This just calls the garbage collector more
frequently to clean up memory. If your system is paging to
disk because of memory use it can speed things up quite a
bit. In my case it keeps the total python footprint
significantly reduced.

Good Luck,

David

From: "Werner F. Bruhin" <werner.bruhin@...185...>
Date: Thu, 14 Apr 2005 11:42:34 +0200
Subject: [Matplotlib-users] Memory usage

Hi All,

Doing multiple plots I see that memory usage grows and

grows.

Before doing a new plot I do "self.figure.clear()", or
"self.figure.clf()", is there some other call I should

use?

···

See you
Werner

+_+_+_+_+_+_+_+_+_+_+_+_+_+_+_+_+

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around

Hi David,

Thanks for the info.

See you
Werner

D Brown wrote:

···

Werner,

Recently I reported a batch plot memory issue when using
mostly matlab-style commands and TkAgg backend. In my case
I found that the memory increased when I called close(). If I stopped using this the memory use became more or less
constant. Based on Fernando Perez's comments I also
started using import gc and gc.collect() to reduce memory
use more. This just calls the garbage collector more
frequently to clean up memory. If your system is paging to
disk because of memory use it can speed things up quite a
bit. In my case it keeps the total python footprint
significantly reduced.

Good Luck,

David

From: "Werner F. Bruhin" <werner.bruhin@...185...>
Date: Thu, 14 Apr 2005 11:42:34 +0200
Subject: [Matplotlib-users] Memory usage

Hi All,

Doing multiple plots I see that memory usage grows and

grows.

Before doing a new plot I do "self.figure.clear()", or "self.figure.clf()", is there some other call I should

use?

See you
Werner

+_+_+_+_+_+_+_+_+_+_+_+_+_+_+_+_+

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click