[Numpy-discussion] Putmask/take ?
PGM
pgmdevlist at gmail.com
Thu Sep 21 19:40:39 EDT 2006
Folks,
I'm running into the following problem with putmask on take.
>>> import numpy
>>> x = N.arange(12.)
>>> m = [1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1]
>>> i = N.nonzero(m)[0]
>>> w = N.array([-1, -2, -3, -4.])
>>> x.putmask(w,m)
>>> x.take(i)
>>> N.allclose(x.take(i),w)
False
I'm wondering ifit is intentional, or if it's a problem on my build (1.0b5), or if somebody experienced it as well.
Thanks a lot for your input.
P.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20060921/6b857145/attachment.html>
More information about the NumPy-Discussion
mailing list