[Scipy-tickets] [SciPy] #1797: Apparent memory leak in scipy.sparse.csr_matrix

SciPy Trac scipy-tickets@scipy....
Fri Dec 21 16:22:25 CST 2012

#1797: Apparent memory leak in scipy.sparse.csr_matrix
 Reporter:  mrabinovich               |       Owner:  jakevdp    
     Type:  defect                    |      Status:  new        
 Priority:  normal                    |   Milestone:  Unscheduled
Component:  scipy.sparse              |     Version:  0.8.0      
 Keywords:  csr_matrix, leak, update  |  
 I've been using NumPy and SciPy to implement fast inference in some
 probabilistic models of text I'm developing. When I started using them on
 large-ish data sets, I noticed I was running out of memory. After a lot of
 digging, I discovered the culprit was a simple update to a
 scipy.sparse.csr_matrix. Although I was only updating a nonzero entry,
 something seems to have gone wrong--not only was it time-inefficient, it
 also caused the process to use more and more memory. I'm attaching a short
 script that replicates this issue in a simpler context.

 Note: because I'm on an old Ubuntu (11.04) distribution, I'm using SciPy
 0.8.0 and NumPy 1.6.2.

Ticket URL: <http://projects.scipy.org/scipy/ticket/1797>
SciPy <http://www.scipy.org>
SciPy is open-source software for mathematics, science, and engineering.

More information about the Scipy-tickets mailing list