Re: [Numpy-discussion] Strange crash in numpy.linalg.lstsq.

2009-08-18 Thread Jonathan Taylor
Right... So I was able to get everything working finally. I am not 100% sure how or why it works though so I am going to outline what I did here for reference. I first tried just using LAPACK 3.1.1 (since it seemed set up for g77 instead of gfortran which I do not have). I compiled this to yield

[Numpy-discussion] how can i optimize this function further more?

2009-08-18 Thread Victor Noagbodji
hello, i'm fairly new to numpy. i need help with a snow effect done with pygame. the entire code is below. the performance drops in the snowfall function. the original c code and a demo can be found here : http://sol.gfxile.net/gp/ch04.html as you can see. the original c code went the pixel by pix

Re: [Numpy-discussion] indexing problem

2009-08-18 Thread Robert Kern
2009/8/18 Ernest Adrogué : > 18/08/09 @ 07:33 (-0700), thus spake Robert Kern: >> 2009/8/18 Ernest Adrogué : >> > Hi, >> > >> > Suppose I have a 3-dimansional array, where one dimension >> > is time. I'm not particularly interested in selecting specific >> > moments in time, so most of the time I w

Re: [Numpy-discussion] indexing problem

2009-08-18 Thread Ernest Adrogué
18/08/09 @ 07:33 (-0700), thus spake Robert Kern: > 2009/8/18 Ernest Adrogué : > > Hi, > > > > Suppose I have a 3-dimansional array, where one dimension > > is time. I'm not particularly interested in selecting specific > > moments in time, so most of the time I won't be indexing this > > dimension

Re: [Numpy-discussion] indexing problem

2009-08-18 Thread Robert Kern
2009/8/18 Ernest Adrogué : > Hi, > > Suppose I have a 3-dimansional array, where one dimension > is time. I'm not particularly interested in selecting specific > moments in time, so most of the time I won't be indexing this > dimension. > > Intuitively, one would make time the third dimension, but

Re: [Numpy-discussion] unique rows of array

2009-08-18 Thread josef . pktd
On Tue, Aug 18, 2009 at 2:01 AM, Maria Liukis wrote: > Josef, > Many thanks for the example! It should become an official NumPy recipe :) > Thanks again, > Masha > > liu...@usc.edu Actually, there is also an implementation of unique rows in scipy.stats._support. It uses loops

[Numpy-discussion] indexing problem

2009-08-18 Thread Ernest Adrogué
Hi, Suppose I have a 3-dimansional array, where one dimension is time. I'm not particularly interested in selecting specific moments in time, so most of the time I won't be indexing this dimension. Intuitively, one would make time the third dimension, but if you do that you have to specifiy the t

Re: [Numpy-discussion] add axis to results of reduction (mean, min, ...)

2009-08-18 Thread Vincent Schut
Keith Goodman wrote: > On Thu, Aug 6, 2009 at 9:58 AM, Charles R > Harris wrote: >> >> On Thu, Aug 6, 2009 at 9:55 AM, wrote: >>> What's the best way of getting back the correct shape to be able to >>> broadcast, mean, min,.. to the original array, that works for >>> arbitrary dimension and axis?