This patch corrected the problem for me, numpy test pass...
On 8/2/07, Lisandro Dalcin <[EMAIL PROTECTED]> wrote:
> I think the problem is in _array_fromobject (seen as numpy.array in Python)
--
Lisandro Dalcín
---
Centro Internacional de Métodos Computacionales en Ingeniería (CIM
I think the problem is in _array_fromobject (seen as numpy.array in Python)
This function parses its arguments by using the convertor
PyArray_DescrConverter2. which RETURNS A NEW REFERENCE!!! This
reference is never DECREF'ed.
BTW, A lesson I've learned of the pattern
if (!PyArg_ParseXXX())
Ups, I forgot to mention I was using gc.collect(), I accidentally
cleaned it my mail
Anyway, the following
import sys, gc
import numpy
def test():
a = numpy.zeros(5, dtype=float)
while 1:
gc.collect()
b = numpy.asarray(a, dtype=float); del b
gc.collect()
p
On 8/2/07, Lisandro Dalcin <[EMAIL PROTECTED]> wrote:
>
> using numpy-1.0.3, I believe there are a reference leak somewhere.
> Using a debug build of Python 2.5.1 (--with-pydebug), I get the
> following
>
> import sys, gc
> import numpy
>
> def testleaks(func, args=(), kargs={}, repeats=5):
> f
using numpy-1.0.3, I believe there are a reference leak somewhere.
Using a debug build of Python 2.5.1 (--with-pydebug), I get the
following
import sys, gc
import numpy
def testleaks(func, args=(), kargs={}, repeats=5):
for i in xrange(repeats):
r1 = sys.gettotalrefcount()
fun