Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #72130

Re: help with memory leak

References <lm2qls$a40$1@ger.gmane.org>
Date 2014-05-28 06:50 +1000
Subject Re: help with memory leak
From Chris Angelico <rosuav@gmail.com>
Newsgroups comp.lang.python
Message-ID <mailman.10375.1401223845.18130.python-list@python.org> (permalink)

Show all headers | View raw


On Wed, May 28, 2014 at 5:56 AM, Neal Becker <ndbecker2@gmail.com> wrote:
> I'm trying to track down a memory leak in a fairly large code.  It uses a lot of
> numpy, and a bit of c++-wrapped code.  I don't yet know if the leak is purely
> python or is caused by the c++ modules.

Something to try, which would separate the two types of leak: Run your
program in a separate namespace of some sort (eg a function), make
sure all your globals have been cleaned up, run a gc collection, and
then see if you still have a whole lot more junk around. If that
cleans everything up, it's some sort of refloop; if it doesn't, it's
either a global you didn't find, or a C-level refleak.

ChrisA

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: help with memory leak Chris Angelico <rosuav@gmail.com> - 2014-05-28 06:50 +1000

csiph-web