Re: [Numpy-discussion] how to compile numpy with visual-studio-2003?

2006-09-28 Thread Travis Oliphant
mg wrote: > Hello, > > I just download the newly Python-2.5 and Numpy-1.0rc1 and all work fine > on Linux-x86 32 and 64bit platforms. > Now, I try to compile the both distributions on WindowsXP with > VisualStudio2003. No problem to compile Python-2.5, but i have some > troubles with Numpy-1.0rc

[Numpy-discussion] compiling ATLAS for numpy

2006-09-28 Thread Emanuele Olivetti
Hi, I'm installing numpy on a 2 cpus intel pentium 4 Linux box. I'm installing BLAS and LAPACK from sources too and I need to tune compiler flags. Here is the question: which are the proper flags for compiling LAPACK? Inside lapack.tgz make.inc.LINUX says: OPTS = -funroll-all-loo

Re: [Numpy-discussion] compiling ATLAS for numpy

2006-09-28 Thread Emanuele Olivetti
Ops, sorry for the misleding subject: I wrote ATLAS but I meant LAPACK :) Emanuele Olivetti wrote: > Hi, > I'm installing numpy on a 2 cpus intel pentium 4 Linux box. I'm installing > BLAS and > LAPACK from sources too and I need to tune compiler flags. Here is the > question: which > are the pr

Re: [Numpy-discussion] Release candidate 2.0 will come out mid-week next week

2006-09-28 Thread Francesc Altet
El dc 27 de 09 del 2006 a les 21:17 -0600, en/na Travis Oliphant va escriure: > Hi all, > > I'd like to release numpy 1.0rc2 on about October 5 of next week. > Then, the release of numpy 1.0 official should happen on Monday, October > 17. Please try and get all fixes and improvements in befo

[Numpy-discussion] storage order and concatenate

2006-09-28 Thread David Cournapeau
Hi, I noticed a behaviour which I found counter-intuitive at least when using concatenate. I have a function which takes a numpy array of rank 2 as input, let's say foo(in): a= N.randn((10, 2)) foo(a) To test a ctype implementation of foo against the python version, my test has someth

[Numpy-discussion] return value of negative power

2006-09-28 Thread Stefan van der Walt
Hi all, Currently, the power function returns '0' for negative powers of integers: In [1]: N.power(3,-2) Out[1]: 0 (or, more confusingly) In [1]: N.power(a,b) Out[1]: 0 which is almost certainly not the answer you want. Two possible solutions may be to upcast the input to float before calcula

Re: [Numpy-discussion] compiling ATLAS for numpy

2006-09-28 Thread Hanno Klemm
Emanuele, the scipy compiler flags under http://www.scipy.org/Installing_SciPy/BuildingGeneral work well. However, if you happen to have to use gcc 3.2.3 (e.g. often in Redhat Enterprise editions present), you have to turn off optimization, otherwise lapack doesn't build properly. The correc

Re: [Numpy-discussion] storage order and concatenate

2006-09-28 Thread Travis Oliphant
David Cournapeau wrote: > Hi, > > > What are the rules concerning storage with numpy ? The rule is that a numpy array has "strides" which specify how many bytes to skip to get to the next element in the array. That's the internal model. There are no hard and fast rules about storage order.

[Numpy-discussion] lexsort segfault sorting strings

2006-09-28 Thread eric
I've been using the new record arrays and lexsort from numpy quite a lot lately. Very cool stuff. Using the nightly egg for numpy from here (I believe it is up to date...): http://code.enthought.com/enstaller/eggs/numpy-nightly-py2.4-win32.egg I get segfaults when using lexsort on character a

Re: [Numpy-discussion] how to compile numpy with visual-studio-2003?

2006-09-28 Thread Tim Hochberg
Travis Oliphant wrote: > mg wrote: > >> Hello, >> >> I just download the newly Python-2.5 and Numpy-1.0rc1 and all work fine >> on Linux-x86 32 and 64bit platforms. >> Now, I try to compile the both distributions on WindowsXP with >> VisualStudio2003. No problem to compile Python-2.5, but i ha

Re: [Numpy-discussion] how to compile numpy with visual-studio-2003?

2006-09-28 Thread mg
Unfortunately, no Windows-x86 or Windows-x86-64bit Numpy-1.0rc1 installer are available on SourceForge yet. So the only current solution for us is to compile it. Moreover, our generic C++ framework is compiled with VisualStudio on Windows-native and we compile all additions to it with the same

Re: [Numpy-discussion] how to compile numpy with visual-studio-2003?

2006-09-28 Thread Tim Hochberg
Tim Hochberg wrote: > Travis Oliphant wrote: >> mg wrote: >> >>> Hello, >>> >>> I just download the newly Python-2.5 and Numpy-1.0rc1 and all work >>> fine on Linux-x86 32 and 64bit platforms. >>> Now, I try to compile the both distributions on WindowsXP with >>> VisualStudio2003. No problem to

[Numpy-discussion] 32/64-bit machines, integer arrays and python ints

2006-09-28 Thread Bill Spotz
I am wrapping code using swig and extending it to use numpy. One class method I wrap (let's call it myElements()) returns an array of ints, and I convert it to a numpy array with PyArray_SimpleNew(1,n,'i'); I obtain the data pointer, fill in the values and return it as the method return

Re: [Numpy-discussion] return value of negative power

2006-09-28 Thread Tim Hochberg
Stefan van der Walt wrote: > Hi all, > > Currently, the power function returns '0' for negative powers of > integers: > > In [1]: N.power(3,-2) > Out[1]: 0 > > (or, more confusingly) > > In [1]: N.power(a,b) > Out[1]: 0 > > which is almost certainly not the answer you want. Two possible > solution

Re: [Numpy-discussion] how to compile numpy with visual-studio-2003?

2006-09-28 Thread Tim Hochberg
Tim Hochberg wrote: > Tim Hochberg wrote: > >> Travis Oliphant wrote: >> >>> mg wrote: >>> >>> Hello, I just download the newly Python-2.5 and Numpy-1.0rc1 and all work fine on Linux-x86 32 and 64bit platforms. Now, I try to compile the both distributions

Re: [Numpy-discussion] 32/64-bit machines, integer arrays and python ints

2006-09-28 Thread Travis Oliphant
Bill Spotz wrote: > I am wrapping code using swig and extending it to use numpy. > > One class method I wrap (let's call it myElements()) returns an array > of ints, and I convert it to a numpy array with > > PyArray_SimpleNew(1,n,'i'); > You should probably use NPY_INT instead of 'i' fo

Re: [Numpy-discussion] 32/64-bit machines, integer arrays and python ints

2006-09-28 Thread Bill Spotz
On Sep 28, 2006, at 12:03 PM, Travis Oliphant wrote: > The other option is to improve your converter in setElements so > that it > can understand any of the array scalar integers and not just the > default > Python integer. I think this may be the best approach. This may be something worthwh

Re: [Numpy-discussion] 32/64-bit machines, integer arrays and python ints

2006-09-28 Thread Travis Oliphant
Bill Spotz wrote: >On Sep 28, 2006, at 12:03 PM, Travis Oliphant wrote: > > > >>The other option is to improve your converter in setElements so >>that it >>can understand any of the array scalar integers and not just the >>default >>Python integer. >> >> > >I think this may be the best a