Re: [Numpy-discussion] Helper function to "unroll" a array

2006-11-12 Thread Gael Varoquaux
You're probably right. Well it would most definitely be useful for all the lads in my lab, but I am not sure this is a broad audience. The use case is when you have a array representing data in an "mgrid" way, and you wnat to apply transformations to the coordinates. It is something I have done and

Re: [Numpy-discussion] Helper function to "unroll" a array

2006-11-12 Thread Gael Varoquaux
:52PM +0200, Gael Varoquaux wrote: > Hi, > There is an operation I do a lot, I would call it "unrolling" a array. > The best way to describe it is probably to give the code: > def unroll(M): > """ Flattens the array M and returns a 2D array with the first col

Re: [Numpy-discussion] memory position of numpy arrays

2006-10-26 Thread Gael Varoquaux
On Fri, Oct 27, 2006 at 07:55:06AM +0200, Lars Friedrich wrote: > If anyone is using python / numpy / ctypes for hardware control (say, > Cameras with grabber-cards or fire-wire / DCAM; National Instruments > acquisition cards using NIDAQmx, ...) I am interested in discussion! Worked great for me

[Numpy-discussion] Helper function to "unroll" a array

2006-10-20 Thread Gael Varoquaux
Hi, There is an operation I do a lot, I would call it "unrolling" a array. The best way to describe it is probably to give the code: def unroll(M): """ Flattens the array M and returns a 2D array with the first columns being the indices of M, and the last column the flatten M. ""

Re: [Numpy-discussion] [SciPy-dev] NumPy/SciPy + MPI for Python

2006-10-14 Thread Gael Varoquaux
On Sat, Oct 14, 2006 at 10:50:36AM -0600, Charles R Harris wrote: > So, well, any suggestion for a name? pylab is already in use by > matplotlib (for some reason), as is Scientific Python (and numpy, > Numeric and numarray are obviously already confusing). >supernumpy? I th

Re: [Numpy-discussion] [SciPy-dev] NumPy/SciPy + MPI for Python

2006-10-14 Thread Gael Varoquaux
On Sat, Oct 14, 2006 at 06:58:45AM -0600, Bill Spotz wrote: > I would like to second the notion of converging on a single MPI > interface. My parallel project encapsulates most of the inter- > processor communication within higher-level objects because the lower- > level communication patterns

Re: [Numpy-discussion] return type diffences of indexed arrays with Intel C++ compiler (Python 2.5)

2006-10-03 Thread Gael Varoquaux
On Tue, Oct 03, 2006 at 11:53:22AM +0200, Lars Bittrich wrote: > On Monday 02 October 2006 23:53, Travis Oliphant wrote: > > This is a Python 2.5 issue (the new __index__ method) was incorrectly > > implemented and allowing a 1-d array to be interpreted as an index. > > This should be fixed in SV

[Numpy-discussion] Adding an assert to ctypeslib.py

2006-10-01 Thread Gael Varoquaux
Hi, I just lost a bit of time because I had an old version of ctypes (the one that comes with ubuntu dapper). It doesn't work with ctypeslib.py. I think we should add a warning just after the import. Cheers, Gaƫl 22d21 < assert ctypes.__version__ >= '0.9.9.6' ---