8000 Divide by zero memory leak (Trac #830) · Issue #1428 · numpy/numpy · GitHub
[go: up one dir, main page]

Skip to content

Divide by zero memory leak (Trac #830) #1428

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of 8000 service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
numpy-gitbot opened this issue Oct 19, 2012 · 10 comments
Closed

Divide by zero memory leak (Trac #830) #1428

numpy-gitbot opened this issue Oct 19, 2012 · 10 comments

Comments

@numpy-gitbot
Copy link

Original ticket http://projects.scipy.org/numpy/ticket/830 on 2008-06-24 by @cournape, assigned to @cournape.

See ticket 493 from scipy trac

Dividing by zero (e.g. 1/scipy.float64(0.)) yields scipy.inf as it is supposed to, but leaks memory in the process.

I'll attach a sample program where memory usage grows without bound.

#!python
import scipy
x = scipy.float64(0.)
while 1:
    1/x
@numpy-gitbot
Copy link
Author

@charris wrote on 2008-06-24

Where's the attachment?

@numpy-gitbot
Copy link
Author

Attachment added by @charris on 2008-06-24: bug.py

@numpy-gitbot
Copy link
Author

@charris wrote on 2008-06-24

I can't reproduce this:

$[charris@dragon ~]$ python --version
Python 2.5.1
$[charris@dragon ~]$ uname -a
Linux dragon 2.6.25.6-27.fc8 #1 SMP Fri Jun 13 16:38:52 EDT 2008 i686 i686 i386 GNU/Linux

@numpy-gitbot
Copy link
Author

@pv wrote on 2008-06-25

I can't reproduce this either. (Tested: Python 2.4.4 and Python 2.5 on 32-bit Debian Linux.)

@numpy-gitbot
Copy link
Author

@cournape wrote on 2008-12-30

I can reproduce the leak on last svn (ubuntu 32 bits, python 2.5).

@numpy-gitbot
Copy link
Author

@pv wrote on 2008-12-30

I don't see this on Numpy 1.1.1 (Ubuntu-shipped), 1.2.1 (self-compiled), or SVN (self-compiled); on Ubuntu 8.10, 32-bit, python2.5.

It's the same platform as david's, so I wonder what's different.

@numpy-gitbot
Copy link
Author

@cournape wrote on 2008-12-30

Hm, this is getting weird. There is not question about the leak: after ~1 min run, I have a python processing taking ~1Gb. But I don't see the behavior on a Centos 5 (same last svn checkout, but with python 2.4 on x86_64).

To make things more fun, I don't see the leak with ubuntu-shipped numpy...

@numpy-gitbot
Copy link
Author

@cournape wrote on 2009-03-02

Ok, I don't see it anymore. Must have been some weird config problem on my machine

@numpy-gitbot
Copy link
Author

@pv wrote on 2009-03-02

Probably duplicate of #1553; was fixed in r6351

@numpy-gitbot
Copy link
Author

@pv wrote on 2009-03-02

Hmm, or possibly not, difficult to say. In any case there was a error object leak in #1553 that occurred for division by zero...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant
0