Re: [Numpy-discussion] Pickling and initializing

2008-03-03 Thread Anne Archibald
On 03/03/2008, Dinesh B Vadhia <[EMAIL PROTECTED]> wrote: > When you pickle a numpy/scipy matrix does it have to be initialized by > another program? For example: Most python objects do not need to be initialized. You just call a function that makes the one you want: >>> l = range(10) This mak

Re: [Numpy-discussion] numpy.correlate with phase offset 1D data series

2008-03-03 Thread Anne Archibald
On 03/03/2008, Ray Schumacher <[EMAIL PROTECTED]> wrote: > Xie's 2D algorithm reduced to 1D works nicely for computing the > relative phase, but is it the fastest way? It might be, since some > correlation algorithms use FFTs as well. What does _correlateND use, in > scipy? Which way will be

Re: [Numpy-discussion] Pickling and initializing

2008-03-03 Thread Robert Kern
On Mon, Mar 3, 2008 at 5:29 PM, Dinesh B Vadhia <[EMAIL PROTECTED]> wrote: > > > When you pickle a numpy/scipy matrix does it have to be initialized by > another program? For example: > > Program One: > A = scipy.asmatrix(scipy.empty((i, i)), dtype=int)# initialize > matrix A > >

[Numpy-discussion] Pickling and initializing

2008-03-03 Thread Dinesh B Vadhia
When you pickle a numpy/scipy matrix does it have to be initialized by another program? For example: Program One: A = scipy.asmatrix(scipy.empty((i, i)), dtype=int)# initialize matrix A pickle.dump(A) Program Two: pickle.load(A) .. in Program Two, do we need the stat

Re: [Numpy-discussion] cross

2008-03-03 Thread Lisandro Dalcin
On 3/3/08, Revaz Yves <[EMAIL PROTECTED]> wrote: > I'm computing the cross product of positions and velocities of n points > in a 3d space. > Using the numpy function "cross", this can be written as : > I compare the computation time needed with a C-api I wrote (dedicated to > this operation).

Re: [Numpy-discussion] numpy.correlate with phase offset 1D data series

2008-03-03 Thread Timothy Hochberg
On Mon, Mar 3, 2008 at 2:45 PM, Ray Schumacher <[EMAIL PROTECTED]> wrote: > At 01:24 PM 3/3/2008, you wrote: > > > If you use 'same' or 'full' you'll end of with different > > >amounts of offset. I imagine that this is due to the way the data is > padded. > > >The offset should be deterministic ba

Re: [Numpy-discussion] preparing to tag NumPy 1.0.5 on Wednesday

2008-03-03 Thread Charles R Harris
On Mon, Mar 3, 2008 at 10:21 AM, Jarrod Millman <[EMAIL PROTECTED]> wrote: > Hello, > > I would like to tag the 1.0.5 release on Wednesday night and announce > the release by Monday (3/10). If you have anything that you would > like to get in before then, please do it now. It would also be great

Re: [Numpy-discussion] numpy.correlate with phase offset 1D data series

2008-03-03 Thread Anne Archibald
On 03/03/2008, Ray Schumacher <[EMAIL PROTECTED]> wrote: > > I'm trying to figure out what numpy.correlate does, and, what are people > using to calculate the phase shift of 1D signals? I use a hand-rolled Fourier-domain cross-correlation, but then, I'm using a Fourier-domain representation of my

[Numpy-discussion] numpy.correlate with phase offset 1D data series

2008-03-03 Thread Ray Schumacher
At 01:24 PM 3/3/2008, you wrote: > > If you use 'same' or 'full' you'll end of with different > >amounts of offset. I imagine that this is due to the way the data is padded. > >The offset should be deterministic based on the mode and the size of the > >data, so it should be straightforward to compe

Re: [Numpy-discussion] numpy.correlate with phase offset 1D data series

2008-03-03 Thread Timothy Hochberg
On Mon, Mar 3, 2008 at 12:57 PM, Ray Schumacher <[EMAIL PROTECTED]> wrote: > I'm trying to figure out what numpy.correlate does, and, what are people > using to calculate the phase shift of 1D signals? > > (I coded on routine that uses rfft, conjugate, ratio, irfft, and argmax > based on a paper

Re: [Numpy-discussion] preparing to tag NumPy 1.0.5 on Wednesday

2008-03-03 Thread Travis E. Oliphant
Charles R Harris wrote: > > > On Mon, Mar 3, 2008 at 10:21 AM, Jarrod Millman <[EMAIL PROTECTED] > > wrote: > > Hello, > > I would like to tag the 1.0.5 release on Wednesday night and announce > the release by Monday (3/10). If you have anything that you woul

[Numpy-discussion] numpy.correlate with phase offset 1D data series

2008-03-03 Thread Ray Schumacher
I'm trying to figure out what numpy.correlate does, and, what are people using to calculate the phase shift of 1D signals? (I coded on routine that uses rfft, conjugate, ratio, irfft, and argmax based on a paper by Hongjie Xie "An IDL/ENVI implementation of the FFT Based Algorithm for Automat

Re: [Numpy-discussion] preparing to tag NumPy 1.0.5 on Wednesday

2008-03-03 Thread Travis E. Oliphant
Alan G Isaac wrote: > I never got a response to this: > http://projects.scipy.org/pipermail/scipy-dev/2008-February/008424.html> > (Two different types claim to be numpy.int32.) > It's not a bug :-) There are two c-level types that are both 32-bit (on 32-bit systems). -Travis _

[Numpy-discussion] cross

2008-03-03 Thread Revaz Yves
Dear List, I'm computing the cross product of positions and velocities of n points in a 3d space. Using the numpy function "cross", this can be written as : n=1000 pos = random.random([n,3]) vel = random.random([n,3]) cross(pos,vel) I compare the computation time needed with a C-api I wrote (de

Re: [Numpy-discussion] confusion about eigenvector

2008-03-03 Thread Arnar Flatberg
> This will not work with numpy matrices.* is elementwise mult. Sorry, disregard that comment ___ Numpy-discussion mailing list Numpy-discussion@scipy.org http://projects.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] preparing to tag NumPy 1.0.5 on Wednesday

2008-03-03 Thread dmitrey
Also, it would be very well if asfarray() doesn't drop down float128 to float64. D. Alan G Isaac wrote: > I never got a response to this: > http://projects.scipy.org/pipermail/scipy-dev/2008-February/008424.html> > (Two different types claim to be numpy.int32.) > > Cheers, > Alan > > > >

Re: [Numpy-discussion] preparing to tag NumPy 1.0.5 on Wednesday

2008-03-03 Thread Alan G Isaac
I never got a response to this: http://projects.scipy.org/pipermail/scipy-dev/2008-February/008424.html> (Two different types claim to be numpy.int32.) Cheers, Alan ___ Numpy-discussion mailing list Numpy-discussion@scipy.org http://projects.scipy.org

Re: [Numpy-discussion] numpy and roundoff(?)

2008-03-03 Thread Christopher Barker
Damian Eads wrote: > At work we noticed a significant difference in results occurring in two > versions of our code, an earlier version written in C++, and a later > version written in Python/numpy. The algorithms were structured about > the same. My colleague found the cause of the discrepancy;

Re: [Numpy-discussion] confusion about eigenvector

2008-03-03 Thread Arnar Flatberg
> i read in some document on the topic of eigenfaces that > 'Multiplying the sorted eigenvector with face vector results in > getting the > face-space vector' > facespace=sortedeigenvectorsmatrix * adjustedfacematrix > (when these are numpy.matrices ) This will not work with numpy matrices.

[Numpy-discussion] preparing to tag NumPy 1.0.5 on Wednesday

2008-03-03 Thread Jarrod Millman
Hello, I would like to tag the 1.0.5 release on Wednesday night and announce the release by Monday (3/10). If you have anything that you would like to get in before then, please do it now. It would also be great if everyone could test the trunk. If anyone finds a bug or regression that should d

Re: [Numpy-discussion] A little help please?

2008-03-03 Thread Neal Becker
Travis E. Oliphant wrote: > Travis E. Oliphant wrote: >> Neal Becker wrote: >> >>> Travis E. Oliphant wrote: >>> >>> >>> >>> >>> The code for this is a bit hard to understand. It does appear that it >>> only >>> searches for a conversion on the 2nd argument. I don't think that's >>> desira

Re: [Numpy-discussion] confusion about eigenvector

2008-03-03 Thread [EMAIL PROTECTED]
>Arnar wrote > I dont know if this made anything any clearer. However, a simple > example may be clearer: > # X is (a ndarray, *not* matrix) column centered with vectorized images in > rows > # method 1: > XX = dot(X, X.T) > s, u = linalg.eigh(XX) > reorder = s.argsort()[::-1] > facespace = dot(X.