igraph-help
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[igraph] Memory leak when using Graph.Adjacency in Python interface


From: Jonathan F. Donges
Subject: [igraph] Memory leak when using Graph.Adjacency in Python interface
Date: Thu, 10 Dec 2009 11:59:23 +0100

Dear list,

I use igraph 0.5.2 via the Python interface. There appears to be a memory leak, when using the Graph.Adjacency function to create a graph from an adjacency matrix. Please consider the following code:

>>> import numpy, igraph
>>> for i in xrange(1000):
...     a = numpy.random.randn(1000,1000)
...     g = igraph.Graph.Adjacency(list((a>0.5).astype("float64")))

While the loop is being executed, the memory is quickly being filled up. The memory is only freed, when the Python shell is closed or the program terminates. Explicitly calling the Python garbage collector does not help.

 I ran into this problem using Mac OSX Leopard and Linux.

I would be delighted if you could help me with this issue!

Best wishes,
Jonathan

reply via email to

[Prev in Thread] Current Thread [Next in Thread]