[Numpy-discussion] ufuncs on funny strides; also isnan, isfinite, etc on a variety of dtypes

2010-04-01 Thread M Trumpis
Hi all, disclaimer: pardon my vast ignorance on the subject of ufuncs, that will explain the naivety of the following questions This morning I was looking at this line of code, which was running quite slow for me and making me think data_has_nan = numpy.isnan(data_array).any() I knew that the a

Re: [Numpy-discussion] ufuncs on funny strides; also isnan, isfinite, etc on a variety of dtypes

2010-04-01 Thread M Trumpis
On Thu, Apr 1, 2010 at 11:53 AM, Warren Weckesser wrote: > M Trumpis wrote: >> Hi all, >> >> >> >> And a last mini question, it doesn't appear that any() is doing short >> circuit evaluation. It runs in appx the same time whether an array is >&

Re: [Numpy-discussion] Datarray BoF, part2

2010-07-21 Thread M Trumpis
On Wed, Jul 21, 2010 at 10:08 AM, Keith Goodman wrote: > On Wed, Jul 21, 2010 at 9:56 AM, John Salvatier > wrote: >> I don't really know much about this topic, but what about a flag at array >> creation time (or whenever you define labels) that says whether valid >> indexes will be treated as lab

[Numpy-discussion] datarray lightning talk at NYC Python group

2010-10-18 Thread M Trumpis
Just a heads up that I'm going to do a quick pitch for datarray this Wed. at the NYC Python Meetup thing. If any collaborator is attending, please introduce yourself! Mike ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.or

Re: [Numpy-discussion] datarray lightning talk at NYC Python group

2010-10-20 Thread M Trumpis
On Mon, Oct 18, 2010 at 5:18 PM, Fernando Perez wrote: > On Mon, Oct 18, 2010 at 11:21 AM, M Trumpis wrote: >> Just a heads up that I'm going to do a quick pitch for datarray this >> Wed. at the NYC Python Meetup thing. >> >> If any collaborator is atte

Re: [Numpy-discussion] SVD errors

2009-02-09 Thread M Trumpis
I played around with a C translation of that test program, and found that dgesvd (but not dgesdd) happens to converge and return all non-negative singular values for both operators I was having trouble with. I'm also looking at the Octave code just now, and I think they're using dgesvd also. Any on

Re: [Numpy-discussion] Summary of ticket 937

2009-02-24 Thread M Trumpis
I ran into this problem as well a few months back. The reason for the empty residual array when M==N is that the LAPACK routine for Ax = b puts the solution for x in b. When M>N, the norm-squared is parceled out into the unused (M-N) points in the b array. When M==N, there's no room for the resids

Re: [Numpy-discussion] Interpolation via Fourier transform

2009-03-05 Thread M Trumpis
Hi Nadav.. if you want a lower resolution 2d function with the same field of view (or whatever term is appropriate to your case), then in principle you can truncate your higher frequencies and do this: sig = ifft2_func(sig[N/2 - M/2:N/2 + M/2, N/2 - M/2:N/2+M/2]) I like to use an fft that transfo