Re: [Numpy-discussion] Providing array interface from SWIG-wrapped C struct

2006-10-12 Thread vallis . 35530053
Wonderful, it works, thanks! Michele --- Discussion of Numerical Python numpy-discussion@lists.sourceforge.net wrote: On 10/12/06, Michele Vallisneri [EMAIL PROTECTED] wrote: Does anybody here have experience about offering the array interface from a SWIG-wrapped C struct? I

[Numpy-discussion] numpy.where behavior

2006-11-13 Thread vallis . 35530053
Using numpy 1.0, why does a = numpy.array([0.0,1.0,2.0],'d') numpy.where(a == 0.0,1,1/a) give the correct result, but with the warning Warning: divide by zero encountered in divide? ? I thought that the point of where was that the second expression is never used for the elements where