Re: [Numpy-discussion] Unexpected attribute error

2009-11-17 Thread Robert Kern
On Tue, Nov 17, 2009 at 20:48, James Bergstra wrote: > Is it by design that  "numpy.sqrt(None)" raises an "AttributeError: sqrt"? Yes. numpy.sqrt() is a ufunc. Ufuncs take their arguments and try to convert them to numpy arrays; the manual equivalent is numpy.asarray(None). In this case, you get

[Numpy-discussion] Unexpected attribute error

2009-11-17 Thread James Bergstra
Is it by design that  "numpy.sqrt(None)" raises an "AttributeError: sqrt"? This was confusing because there was an attribute lookup of 'sqrt' in numpy right there in the expression I typed, but that was not the attribute that python was complaining about.  I presume that numpy.sqrt didn't know wha

Re: [Numpy-discussion] REMINDER: trunk is about to be frozen for 1.4.0

2009-11-17 Thread David Cournapeau
already done in r7743 :) Did you report it as a bug on trac, so that I close it as well, David ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Strange inversion in shape with some slices

2009-11-17 Thread Travis Oliphant
On Nov 17, 2009, at 12:33 PM, Sebastian Haase wrote: On Tue, Nov 17, 2009 at 5:40 PM, wrote: On Tue, Nov 17, 2009 at 11:24 AM, Jean-Baptiste Rudant wrote: Hello, I think there's something strange with shape when a slice is given by an array. import numpy as N my_array = N.ones((2, 3, 6)

Re: [Numpy-discussion] Strange inversion in shape with some slices

2009-11-17 Thread Robert Kern
On Tue, Nov 17, 2009 at 12:33, Sebastian Haase wrote: > On Tue, Nov 17, 2009 at 5:40 PM,   wrote: >> On Tue, Nov 17, 2009 at 11:24 AM, Jean-Baptiste Rudant >> wrote: >>> Hello, >>> I think there's something strange with shape when a slice is given by an >>> array. >>> import numpy as N >>> my_arr

Re: [Numpy-discussion] Strange inversion in shape with some slices

2009-11-17 Thread Sebastian Haase
On Tue, Nov 17, 2009 at 5:40 PM, wrote: > On Tue, Nov 17, 2009 at 11:24 AM, Jean-Baptiste Rudant > wrote: >> Hello, >> I think there's something strange with shape when a slice is given by an >> array. >> import numpy as N >> my_array = N.ones((2, 3, 6)) >> ind = N.arange(4) >> #you hope to find

Re: [Numpy-discussion] Fitting a curve on a log-normal distributed data

2009-11-17 Thread Gökhan Sever
On Tue, Nov 17, 2009 at 12:13 AM, Ian Mallett wrote: > Theory wise: > -Do a linear regression on your data. > -Apply a logrithmic transform to your data's dependent variable, and do > another linear regression. > -Apply a logrithmic transform to your data's independent variable, and do > another

Re: [Numpy-discussion] REMINDER: trunk is about to be frozen for 1.4.0

2009-11-17 Thread Robert Kern
On Tue, Nov 17, 2009 at 11:16, Darren Dale wrote: > Please consider applying this patch before freezing, or you can't do > "python setup.py develop" with Distribute (at least not with > Enthought's Enable): It's just a temporary complete freeze while David branches 1.4 off the trunk and then just

Re: [Numpy-discussion] REMINDER: trunk is about to be frozen for 1.4.0

2009-11-17 Thread Darren Dale
Please consider applying this patch before freezing, or you can't do "python setup.py develop" with Distribute (at least not with Enthought's Enable): ndex: numpy/distutils/command/build_ext.py === --- numpy/distutils/command/build_ex

Re: [Numpy-discussion] Strange inversion in shape with some slices

2009-11-17 Thread josef . pktd
On Tue, Nov 17, 2009 at 11:24 AM, Jean-Baptiste Rudant wrote: > Hello, > I think there's something strange with shape when a slice is given by an > array. > import numpy as N > my_array = N.ones((2, 3, 6)) > ind = N.arange(4) > #you hope to find (3, 4) > print my_array[0, :, ind].shape > print my_

[Numpy-discussion] Strange inversion in shape with some slices

2009-11-17 Thread Jean-Baptiste Rudant
Hello, I think there's something strange with shape when a slice is given by an array. import numpy as N my_array = N.ones((2, 3, 6)) ind = N.arange(4) #you hope to find (3, 4) print my_array[0, :, ind].shape print my_array[0, :, 0:4].shape print my_array[0][:, ind].shape print my_array[0][:, 0:

Re: [Numpy-discussion] failure building trunk with mingw

2009-11-17 Thread josef . pktd
On Mon, Nov 16, 2009 at 10:52 PM, David Cournapeau wrote: > On Tue, Nov 17, 2009 at 3:33 AM,   wrote: > >> >> Now, the numpy build runs for a while then breaks while building umath. >> >> Any ideas? > > The behavior of distutils with config files is mysterious, I gave up > trying to understand it

Re: [Numpy-discussion] min bug

2009-11-17 Thread Neil
Alan McIntyre gmail.com> writes: > > On Mon, Nov 16, 2009 at 11:34 PM, "V. Armando Solé" esrf.fr> wrote: > > Sebastian Berg wrote: > >> Known issue, I think someone posted about it a while ago too. The numpy > >> min is array aware, and it expects an array. The second argument is the > >> axis,