analyzing memory usage of python code

Tomeu Vizoso tomeu at tomeuvizoso.net
Tue Sep 9 07:24:32 EDT 2008


On Sun, Aug 24, 2008 at 10:09 AM, Polychronis Ypodimatopoulos
<ypod at mit.edu> wrote:
> Polychronis Ypodimatopoulos wrote:
>> I filed #8128 to address the memory usage that seems excessive.
>>
>> I have also disabled cerebro from start-up while this is being
>> investigated and the issue with blocking shutdown process (#8108).
>> Should be picked up at the next version of joyride.
>>
>
> Any suggestions on how to isolate the parts of some python code that
> take the most memory? It's rather impossible to start commenting out
> modules because of dependency issues.

It's impossible because of dependency cycles, but aside of that you
can execute python with -v, and from the output make a list of module
imports that reduce implicit imports to the most.

Hope that helps,

Tomeu



More information about the Devel mailing list