[Numpy-discussion] Non-meta indexing improvements discussion

2015-04-08 Thread Sebastian Berg
Hi all, Let me take a shot at summing up some suggestions to make the indexing less surprising, and maybe we can gather some more in a more concentrated way now. 1. Implement something like `arr.fancy_index[...]` and `arr.ortho_index[...]` (i.e. Jaimes PR is the start for trying this) 2. Add war

[Numpy-discussion] SIAM meeting in Snowbird anyone?

2015-04-08 Thread Sebastian Berg
Hey, since I am not in the US often and the SIAM conference is pretty large, I was wondering if some more of our community will be at the SIAM conference in Snowbird around May 17th-21st and would like to meet up then. - Sebastian signature.asc Description: This is a digitally signed message pa

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Nathaniel Smith
On Wed, Apr 8, 2015 at 4:02 PM, Alan G Isaac wrote: > 1. I use numpy in teaching. > I have never heard a complaint about its indexing behavior. > Have you heard such complaints? Some observations: 1) There's an unrelated thread on numpy-discussion right now in which a user is baffled by the inte

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Nathaniel Smith
On Wed, Apr 8, 2015 at 2:09 PM, Alan G Isaac wrote: > That analogy fails because it suggests a private conversation. This list is > extremely public. > For example, I am just a user, and I am on it. I can tell you that as a > long-time numpy user > my reaction to the proposal to change indexing

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Ralf Gommers
On Wed, Apr 8, 2015 at 10:20 PM, Robert Kern wrote: > On Wed, Apr 8, 2015 at 8:40 PM, Ralf Gommers > wrote: > > > To address in detail the list of Matthew you mention above: > > > > * implement orthogonal indexing as a method arr.sensible_index[...] > > That's basically Jaime's PR. > > > > *

Re: [Numpy-discussion] Multidimensional Indexing

2015-04-08 Thread Sebastian Berg
On Di, 2015-04-07 at 00:49 +0100, Nicholas Devenish wrote: > With the indexing example from the documentation: > > y = np.arange(35).reshape(5,7) > > Why does selecting an item from explicitly every row work as I’d expect: > >>> y[np.array([0,1,2,3,4]),np.array([0,0,0,0,0])] > array([ 0, 7, 14,

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Fernando Perez
Trying to bring the meta back into this thread (sorry for Robert's PB :)... The only thing I'd like to add, is that it's perhaps worth messaging that: a PR is just (as the Github folks like to say) "a conversation based on code". It is NOT necessarily something intended explicitly for merging. In

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Robert Kern
On Wed, Apr 8, 2015 at 8:40 PM, Ralf Gommers wrote: > To address in detail the list of Matthew you mention above: > > * implement orthogonal indexing as a method arr.sensible_index[...] > That's basically Jaime's PR. > > * implement the current non-boolean fancy indexing behavior as a method

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Eric Firing
On 2015/04/08 10:02 AM, Alan G Isaac wrote: > 3. I admit, my students are NOT using non-boolen fancy indexing on > multidimensional arrays. (As far as I know.) Are yours? Yes, one attempted to, essentially by accident. That was in my original message. Please refer back to that. The earlier p

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Alan G Isaac
1. I use numpy in teaching. I have never heard a complaint about its indexing behavior. Have you heard such complaints? 2. One reason I use numpy in teaching is its indexing behavior. What specific language provides a better indexing model, in your opinion? 3. I admit, my students are NOT using n

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Eric Firing
On 2015/04/08 9:40 AM, Ralf Gommers wrote: > Their proposal is not being discussed; instead that potentially useful > discussion is being completely derailed by insisting on wanting to talk > about changes to numpy's indexing behavior. Good point. That was an unintended consequence of my message.

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Ralf Gommers
On Wed, Apr 8, 2015 at 9:05 PM, Eric Firing wrote: > On 2015/04/08 8:09 AM, Alan G Isaac wrote: > > That analogy fails because it suggests a private conversation. This list > is extremely public. > > For example, I am just a user, and I am on it. I can tell you that as a > long-time numpy user >

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Robert Kern
On Wed, Apr 8, 2015 at 8:05 PM, Eric Firing wrote: > Now, can we please get back to consideration of reasonable options? Sure, but I recommend going back to the actually topical thread (or a new one), as this one is meta. -- Robert Kern ___ NumPy-Disc

Re: [Numpy-discussion] IDE's for numpy development?

2015-04-08 Thread Yuxiang Wang
I think spyder supports code highlighting in C and that's all... There's no way to compile in Spyder, is there? Shawn On Tue, Apr 7, 2015 at 2:46 AM, Suzen, Mehmet wrote: >> Spyder supports C. > > Thanks for correcting this. I wasn't aware of it. > How was your experience with it? > > Best, > -m

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Eric Firing
On 2015/04/08 8:09 AM, Alan G Isaac wrote: > That analogy fails because it suggests a private conversation. This list is > extremely public. > For example, I am just a user, and I am on it. I can tell you that as a > long-time numpy user > my reaction to the proposal to change indexing semantics

Re: [Numpy-discussion] IDE's for numpy development?

2015-04-08 Thread Suzen, Mehmet
> Spyder supports C. Thanks for correcting this. I wasn't aware of it. How was your experience with it? Best, -m ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] FutureWarning: comparison to `None` will result in an elementwise object comparison in the future.

2015-04-08 Thread Andreas Hilboll
On 08.04.2015 20:30, Nathaniel Smith wrote: > On Apr 8, 2015 2:16 PM, "Andreas Hilboll" > wrote: >> >> Hi all, >> >> I'm commonly using function signatures like >> >>def myfunc(a, b, c=None): >>if c is None: >># do something ... >>... >> >>

Re: [Numpy-discussion] Multidimensional Indexing

2015-04-08 Thread Chad Fulton
On Mon, Apr 6, 2015 at 4:49 PM, Nicholas Devenish wrote: > With the indexing example from the documentation: > > y = np.arange(35).reshape(5,7) > > Why does selecting an item from explicitly every row work as I’d expect: y[np.array([0,1,2,3,4]),np.array([0,0,0,0,0])] > array([ 0, 7, 14, 21,

Re: [Numpy-discussion] FutureWarning: comparison to `None` will result in an elementwise object comparison in the future.

2015-04-08 Thread Nathaniel Smith
On Apr 8, 2015 2:16 PM, "Andreas Hilboll" wrote: > > Hi all, > > I'm commonly using function signatures like > >def myfunc(a, b, c=None): >if c is None: ># do something ... >... > > where c is an optional array argument. For some time now, I'm getting a > >Futu

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread josef.pktd
On Wed, Apr 8, 2015 at 1:38 PM, Robert Kern wrote: > On Wed, Apr 8, 2015 at 2:06 AM, Nathaniel Smith wrote: >> >> On Apr 5, 2015 7:04 AM, "Robert Kern" wrote: >> > >> > On Sat, Apr 4, 2015 at 10:38 PM, Nathaniel Smith wrote: >> > > >> > > On Apr 4, 2015 4:12 AM, "Todd" wrote: >> > > > >> > > >

[Numpy-discussion] Research position in the Brazilian Research Institute for Science and Neurotechnology - BRAINN

2015-04-08 Thread Thiago Franco Moraes
Research position in the Brazilian Research Institute for Science and Neurotechnology – BRAINN Postdoc researcher to work with software development for medical imaging The Brazilian Research Institute for Neuroscience and Neurotechnology (BRAINN) (www.brainn.org.br) focuses on the investigation o

[Numpy-discussion] FutureWarning: comparison to `None` will result in an elementwise object comparison in the future.

2015-04-08 Thread Andreas Hilboll
Hi all, I'm commonly using function signatures like def myfunc(a, b, c=None): if c is None: # do something ... ... where c is an optional array argument. For some time now, I'm getting a FutureWarning: comparison to `None` will result in an elementwise object

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Alan G Isaac
That analogy fails because it suggests a private conversation. This list is extremely public. For example, I am just a user, and I am on it. I can tell you that as a long-time numpy user my reaction to the proposal to change indexing semantics was (i) OMG YMBFKM and then (ii) take a breath; thi

Re: [Numpy-discussion] Behavior of np.random.multivariate_normal with bad covariance matrices

2015-04-08 Thread Blake Griffith
I like your idea Josef, I'll add it to the PR. Just to be clear, we should have something like: Have a single "check_valid" keyword arg, which will default to warn, since that is the current behavior. It will check approximate symmetry, PSDness, and for NaN & infs. Other options on the check_valid

Re: [Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Robert Kern
On Wed, Apr 8, 2015 at 2:06 AM, Nathaniel Smith wrote: > > On Apr 5, 2015 7:04 AM, "Robert Kern" wrote: > > > > On Sat, Apr 4, 2015 at 10:38 PM, Nathaniel Smith wrote: > > > > > > On Apr 4, 2015 4:12 AM, "Todd" wrote: > > > > > > > > There was no break as large as this. In fact I would say this

[Numpy-discussion] On responding to dubious ideas (was: Re: Advanced indexing: "fancy" vs. orthogonal)

2015-04-08 Thread Nathaniel Smith
On Apr 5, 2015 7:04 AM, "Robert Kern" wrote: > > On Sat, Apr 4, 2015 at 10:38 PM, Nathaniel Smith wrote: > > > > On Apr 4, 2015 4:12 AM, "Todd" wrote: > > > > > > There was no break as large as this. In fact I would say this is even a larger change than any individual change we saw in the python

Re: [Numpy-discussion] Multidimensional Indexing

2015-04-08 Thread Nikolay Mayorov
I think the rationale is to allow selection of whole rows / columns. If you want to choose a single element from each row/column, then, yes, you have to pass np.arange(...). There is also np.choose function, but not recommended to use for such cases as far as I understand. I'm not an expert, tho