Re: [Numpy-discussion] memory allocation at assignment

2012-06-28 Thread srean
Yes it does. If you want to avoid this extra copy, and have a pre-existing output array, you can do: np.add(a, b, out=c) ('+' on numpy array's is just a synonym for np.add; np.add is a ufunc, and all ufunc's accept this syntax:  http://docs.scipy.org/doc/numpy/reference/ufuncs.html ) Is

Re: [Numpy-discussion] Created NumPy 1.7.x branch

2012-06-28 Thread Travis Oliphant
On Jun 27, 2012, at 1:18 AM, Fernando Perez wrote: On Tue, Jun 26, 2012 at 11:02 PM, Travis Oliphant tra...@continuum.io wrote: I just want to speak up for the people who are affected by API breakage who are not as vocal on this list. Certainly! And indeed I bet you that's a community

[Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread srean
Hi List, this has been brought up several times, and the response has been generally positive but it has fallen through the cracks. So here are a few repeat requests. Am keeping it terse just for brevity i) Split the list into [devel] and [help] and as was mentioned recently [rant/flame]:

Re: [Numpy-discussion] memory allocation at assignment

2012-06-28 Thread Pierre Haessig
Le 28/06/2012 02:34, Nathaniel Smith a écrit : Yes it does. If you want to avoid this extra copy, and have a pre-existing output array, you can do: np.add(a, b, out=c) And is there a temporary copy when using inplace operators like: c = a.copy() c += b Is there a temporary (c+b) array which

[Numpy-discussion] Dropping support for Python 2.4 in NumPy 1.8

2012-06-28 Thread Travis Oliphant
Hey all, I'd like to propose dropping support for Python 2.4 in NumPy 1.8 (not the 1.7 release). What does everyone think of that? -Travis ___ NumPy-Discussion mailing list NumPy-Discussion@scipy.org

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Aron Ahmadia
We try to support numpy questions on http://scicomp.stackexchange.com, which is a StackOverflow site dedicated towards technical computing issues that gets a fair amount of traffic from mathematicians and computational scientists. We could always use more questions and answerers :) A On Thu,

Re: [Numpy-discussion] memory allocation at assignment

2012-06-28 Thread Travis Oliphant
Yes, the creation of the tmp *is* the creation of a new NumPy array. So, it is as expensive. Travis -- Travis Oliphant (on a mobile) 512-826-7480 On Jun 28, 2012, at 12:44 AM, srean srean.l...@gmail.com wrote: Yes it does. If you want to avoid this extra copy, and have a pre-existing

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Travis Oliphant
There are some good ideas here. I propose splitting this list into devel and users lists. This might best be done by creating a new list for users and using this list for development. Travis -- Travis Oliphant (on a mobile) 512-826-7480 On Jun 27, 2012, at 11:38 PM, srean

Re: [Numpy-discussion] memory allocation at assignment

2012-06-28 Thread Travis Oliphant
-- Travis Oliphant (on a mobile) 512-826-7480 On Jun 28, 2012, at 1:20 AM, Pierre Haessig pierre.haes...@crans.org wrote: Le 28/06/2012 02:34, Nathaniel Smith a écrit : Yes it does. If you want to avoid this extra copy, and have a pre-existing output array, you can do: np.add(a, b,

Re: [Numpy-discussion] Non-deterministic test failure in master

2012-06-28 Thread Ondřej Čertík
Hi Nathaniel, On Wed, Jun 27, 2012 at 11:22 AM, Nathaniel Smith n...@pobox.com wrote: According to the Travis-CI build logs, this code produces non-deterministic behaviour in master:  a = np.arange(5)  a[:3] = a[2:]  assert_equal(a, [2, 3, 4, 3, 4]) Sometimes 'a' is [2, 3, 4, 3, 4], and

Re: [Numpy-discussion] Dropping support for Python 2.4 in NumPy 1.8

2012-06-28 Thread David Cournapeau
Hi Travis, On Thu, Jun 28, 2012 at 1:25 PM, Travis Oliphant tra...@continuum.io wrote: Hey all, I'd like to propose dropping support for Python 2.4 in NumPy 1.8 (not the 1.7 release).      What does everyone think of that? I think it would depend on 1.7 state. I am unwilling to drop support

Re: [Numpy-discussion] Non-deterministic test failure in master

2012-06-28 Thread Pierre Haessig
Hi Nathaniel, Le 27/06/2012 20:22, Nathaniel Smith a écrit : According to the Travis-CI build logs, this code produces non-deterministic behaviour in master: You mean non-deterministic across different builds, not across different executions on the same build, right ? I just ran a small loop :

Re: [Numpy-discussion] memory allocation at assignment

2012-06-28 Thread astronomer
Hi Nathaniel, Thanks for the clearing my understand. This is exactly what i needed. Thanks, Nathaniel Smith wrote: On Thu, Jun 28, 2012 at 12:38 AM, astronomer shailendra.vi...@gmail.com wrote: Hi All, I am wondering if there any difference in memory overhead between the following

Re: [Numpy-discussion] Dropping support for Python 2.4 in NumPy 1.8

2012-06-28 Thread Richard Hattersley
The project/environment we work with already targets Python 2.7, so it'd be fine for us and our collaborators. But it's hard to comment in a more altruistic way without knowing the impact of the change. Is it possible to summarise the benefits? (e.g. Simplifies NumPy codebase; allows better

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Olivier Delalleau
+1 for a numpy-users list without dev noise. -=- Olivier 2012/6/28 Travis Oliphant tra...@continuum.io There are some good ideas here. I propose splitting this list into devel and users lists. This might best be done by creating a new list for users and using this list for development.

Re: [Numpy-discussion] Dropping support for Python 2.4 in NumPy 1.8

2012-06-28 Thread Olivier Delalleau
2012/6/28 David Cournapeau courn...@gmail.com Hi Travis, On Thu, Jun 28, 2012 at 1:25 PM, Travis Oliphant tra...@continuum.io wrote: Hey all, I'd like to propose dropping support for Python 2.4 in NumPy 1.8 (not the 1.7 release). What does everyone think of that? I think it

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Éric Depagne
Le jeudi 28 juin 2012 15:33:07, Travis Oliphant a écrit : There are some good ideas here. I propose splitting this list into devel and users lists. This might best be done by creating a new list for users and using this list for development. I second that idea. As one of the silent users

Re: [Numpy-discussion] Dropping support for Python 2.4 in NumPy 1.8

2012-06-28 Thread John Hunter
On Thu, Jun 28, 2012 at 7:25 AM, Travis Oliphant tra...@continuum.io wrote: Hey all, I'd like to propose dropping support for Python 2.4 in NumPy 1.8 (not the 1.7 release).      What does everyone think of that? As a tangential point, MPL is dropping support for python2.4 in it's next major

Re: [Numpy-discussion] Dropping support for Python 2.4 in NumPy 1.8

2012-06-28 Thread Andreas Hilboll
Hi Travis, On Thu, Jun 28, 2012 at 1:25 PM, Travis Oliphant tra...@continuum.io wrote: Hey all, I'd like to propose dropping support for Python 2.4 in NumPy 1.8 (not the 1.7 release).      What does everyone think of that? I think it would depend on 1.7 state. I am unwilling to drop

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Cera, Tim
Similar to http://scicomp.stackexchange.com there is http://meta.programmers.stackexchange.com/ intended for programmers. Darn it, there are choices involved! I had proposed http://meta.programmers.stackexchange.com/ on this mailing list earlier and no-one seemed interested, but maybe now the

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Aron Ahmadia
Did you mean http://programmers.stackexchange.com? The meta sites on *. stackexchange.com are used (as one might guess) for meta discussions on the site. A On Thu, Jun 28, 2012 at 4:58 PM, Cera, Tim t...@cerazone.net wrote: Similar to http://scicomp.stackexchange.com there is

Re: [Numpy-discussion] Dropping support for Python 2.4 in NumPy 1.8

2012-06-28 Thread Ralf Gommers
On Thu, Jun 28, 2012 at 4:44 PM, Olivier Delalleau sh...@keba.be wrote: 2012/6/28 David Cournapeau courn...@gmail.com Hi Travis, On Thu, Jun 28, 2012 at 1:25 PM, Travis Oliphant tra...@continuum.io wrote: Hey all, I'd like to propose dropping support for Python 2.4 in NumPy 1.8 (not

Re: [Numpy-discussion] dot() function question

2012-06-28 Thread x . piter
Warren Weckesser warren.weckes...@enthought.com writes: In [6]: a = array([1, -2, 3]) In [7]: outer(a, a) Out[7]: array([[ 1, -2,  3],    [-2,  4, -6],    [ 3, -6,  9]]) Warren Thanks, It is much nicer then my method of adding a zero column. Petro.

Re: [Numpy-discussion] Dropping support for Python 2.4 in NumPy 1.8

2012-06-28 Thread Olivier Delalleau
2012/6/28 Ralf Gommers ralf.gomm...@googlemail.com On Thu, Jun 28, 2012 at 4:44 PM, Olivier Delalleau sh...@keba.be wrote: 2012/6/28 David Cournapeau courn...@gmail.com Hi Travis, On Thu, Jun 28, 2012 at 1:25 PM, Travis Oliphant tra...@continuum.io wrote: Hey all, I'd like to

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Cera, Tim
You are correct, I meant http://programmers.stackexchange.com/ And on a site like stackexchange I could actually edit my post instead of my mistake being permanent. :-) Kindest regards, Tim ___ NumPy-Discussion mailing list

Re: [Numpy-discussion] memory allocation at assignment

2012-06-28 Thread Pierre Haessig
Hi, Le 28/06/2012 15:35, Travis Oliphant a écrit : It really is inplace. As Nathaniel mentioned --- all ufuncs take an out keyword. The inplace mechanism uses this so that one input and the output are the same. Thanks for the feedback about inplace assignment. On the other hand, just

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Cera, Tim
A little more research shows that we could have a http://numpy.stackexchange.com. The requirements are just to have people involved. See http://area51.stackexchange.com/faq for more info. Kindest regards, Tim ___ NumPy-Discussion mailing list

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread srean
If I remember correctly there used to be a stackexchange site at ask.scipy.org. It might be good to learn from that experience. I think handling with spam was a significant problem, but am not sure whether that is the reson why it got discontinued. Best srean On Thu, Jun 28, 2012 at 11:36 AM,

Re: [Numpy-discussion] memory allocation at assignment

2012-06-28 Thread Chris Barker
On Thu, Jun 28, 2012 at 9:06 AM, Pierre Haessig On the other hand, just like srean mentionned, I think I also misused the c[:] = a+b syntax. I feel it's a bit confusing since this way of writing the assignment really feels likes it happens inplace. Good to know it's not the case. well, c is

Re: [Numpy-discussion] dot() function question

2012-06-28 Thread Chris Barker
On Wed, Jun 27, 2012 at 2:38 PM, x.pi...@gmail.com wrote: How how can I perform matrix multiplication of two vectors? (in matlab I do it like a*a') np.outer is a bit cleaner, I suppose, but you can exactly the same thing you do with matlab if a is a column (single column 2-d array): In [40]:

Re: [Numpy-discussion] memory allocation at assignment

2012-06-28 Thread Nathaniel Smith
On Thu, Jun 28, 2012 at 7:04 PM, Chris Barker chris.bar...@noaa.gov wrote: On Thu, Jun 28, 2012 at 9:06 AM, Pierre Haessig On the other hand, just like srean mentionned, I think I also misused the c[:] = a+b syntax. I feel it's a bit confusing since this way of writing the assignment really

Re: [Numpy-discussion] Non-deterministic test failure in master

2012-06-28 Thread Nathaniel Smith
On Thu, Jun 28, 2012 at 7:13 AM, Pierre Haessig pierre.haes...@crans.org wrote: Hi Nathaniel, Le 27/06/2012 20:22, Nathaniel Smith a écrit : According to the Travis-CI build logs, this code produces non-deterministic behaviour in master: You mean non-deterministic across different builds, not

Re: [Numpy-discussion] Non-deterministic test failure in master

2012-06-28 Thread David Cournapeau
On Thu, Jun 28, 2012 at 8:06 PM, Nathaniel Smith n...@pobox.com wrote: On Thu, Jun 28, 2012 at 7:13 AM, Pierre Haessig pierre.haes...@crans.org wrote: Hi Nathaniel, Le 27/06/2012 20:22, Nathaniel Smith a écrit : According to the Travis-CI build logs, this code produces non-deterministic

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Matthew Brett
Hi, On Thu, Jun 28, 2012 at 7:42 AM, Olivier Delalleau sh...@keba.be wrote: +1 for a numpy-users list without dev noise. Moderately strong vote against splitting the mailing lists into devel and user. As we know, this list can be unhappy and distracting, but I don't think splitting the lists

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Cera, Tim
That is really funny. Looking through the posts, there wasn't any spam (could have been deleted), but it wasn't used as much as I would think. Have to attract people who answer questions. Early on the registration seemed to be a problem. Solace, the software behind ask.scipy.org looks pretty

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Jason Grout
On 6/28/12 2:46 PM, Cera, Tim wrote: That is really funny. Looking through the posts, there wasn't any spam (could have been deleted), but it wasn't used as much as I would think. Have to attract people who answer questions. Early on the registration seemed to be a problem. Solace, the

Re: [Numpy-discussion] Created NumPy 1.7.x branch

2012-06-28 Thread Fernando Perez
On Thu, Jun 28, 2012 at 5:50 AM, Travis Oliphant tra...@continuum.io wrote: Python in fact has the __future__ imports that help quite a bit for people to start adapting their codes.  How about creating a numpy.future module where new, non-backward-compatible APIs could go? That would give the

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread srean
In case this changes your mind (or assuages fears) just wanted to point out that many open source projects do this. It is not about claiming that one is more important than the other, nor does it reinforce the idea that developers and users live in separate silos, but more of directing the mails

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Matthew Brett
Hi, On Thu, Jun 28, 2012 at 1:42 PM, srean srean.l...@gmail.com wrote: In case this changes your mind (or assuages fears) just wanted to point out that many open source projects do this. It is not about claiming that one is more important than the other, nor does it reinforce the idea that

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Hanno Klemm
Am 28.06.2012 um 23:07 schrieb Matthew Brett: Hi, On Thu, Jun 28, 2012 at 1:42 PM, srean srean.l...@gmail.com wrote: In case this changes your mind (or assuages fears) just wanted to point out that many open source projects do this. It is not about claiming that one is more important than

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Matthew Brett
Hi, On Thu, Jun 28, 2012 at 2:30 PM, Hanno Klemm kl...@phys.ethz.ch wrote: Am 28.06.2012 um 23:07 schrieb Matthew Brett: Hi, On Thu, Jun 28, 2012 at 1:42 PM, srean srean.l...@gmail.com wrote: In case this changes your mind (or assuages fears) just wanted to point out that many open source

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Fernando Perez
On Thu, Jun 28, 2012 at 2:07 PM, Matthew Brett matthew.br...@gmail.com wrote: I see that sympy, for example, has only one mailing list, and that works extremely well.  I'd be interested to hear from the Cython and IPython guys as to whether they feel the user / devel split has helped or hurt.  

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Matthew Brett
Hi, On Thu, Jun 28, 2012 at 2:57 PM, Fernando Perez fperez@gmail.com wrote: On Thu, Jun 28, 2012 at 2:07 PM, Matthew Brett matthew.br...@gmail.com wrote: I see that sympy, for example, has only one mailing list, and that works extremely well.  I'd be interested to hear from the Cython

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread srean
And I continue to think it sends the wrong message. Maybe if you articulate your fears I will be able to appreciate your point of view more. My impression is that, at the moment, we numpy-ers are trying to work out what kind of community we are. Are we a developer community, or are we some

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread srean
Could not have said this better even if I tried, so thank you for your long answer. -- srean On Thu, Jun 28, 2012 at 4:57 PM, Fernando Perez fperez@gmail.com wrote: Long answer, I know... ___ NumPy-Discussion mailing list

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Fernando Perez
On Thu, Jun 28, 2012 at 3:03 PM, Matthew Brett matthew.br...@gmail.com wrote: Fernando - you told me a week or so ago that you'd come across a blog post or similar advocating a single list - do you remember the reference? Found it after some digging: http://www.kitware.com/blog/home/post/263

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Matthew Brett
Hi, On Thu, Jun 28, 2012 at 3:06 PM, srean srean.l...@gmail.com wrote: And I continue to think it sends the wrong message. Maybe if you articulate your fears I will be able to appreciate your point of view more. Ah - I'm afraid I don't know how to say what I mean more clearly :( I can

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Fernando Perez
On Thu, Jun 28, 2012 at 3:06 PM, srean srean.l...@gmail.com wrote:  What I like about having two lists is that on one hand it does not prevent me or you from participating in both, on the other hand it allows those who dont want to delve too deeply in one aspect or the other, the option of a

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Matthew Brett
Hi, On Thu, Jun 28, 2012 at 3:20 PM, Fernando Perez fperez@gmail.com wrote: On Thu, Jun 28, 2012 at 3:03 PM, Matthew Brett matthew.br...@gmail.com wrote: Fernando - you told me a week or so ago that you'd come across a blog post or similar advocating a single list - do you remember the

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread srean
I'm not on the python mailing lists, but my impression is that python is in a different space from numpy.  I mean, I have the impression Indeed one could seek out philosphical differences between different projects. No two projects are the same but they can and often do have common issues.

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread T J
On Thu, Jun 28, 2012 at 3:23 PM, Fernando Perez fperez@gmail.comwrote: On Thu, Jun 28, 2012 at 3:06 PM, srean srean.l...@gmail.com wrote: What I like about having two lists is that on one hand it does not prevent me or you from participating in both, on the other hand it allows those

[Numpy-discussion] PyArray_FILLWBYTE dangerous doc

2012-06-28 Thread Frédéric Bastien
Hi, The doc of PyArray_FILLWBYTE here http://docs.scipy.org/doc/numpy/reference/c-api.array.html is this PyArray_FILLWBYTE(PyObject* obj, int val) Fill the array pointed to by obj —which must be a (subclass of) bigndarray—with the contents of val (evaluated as a byte). In the code, what it

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread srean
I like this solution and I think ask.scipy.org can be revived to take over that role, but this will need some policing to send standard questions there and also some hangout time at ask.scipy.org. I love the stackoverflow model but it requires more active participation of those who want to

Re: [Numpy-discussion] Meta: help, devel and stackoverflow

2012-06-28 Thread Matthew Brett
Hi, On Thu, Jun 28, 2012 at 7:50 PM, srean srean.l...@gmail.com wrote: I like this solution and I think ask.scipy.org can be revived to take over that role, but this will need some policing to send standard questions there and also some hangout time at ask.scipy.org. Sounds like a good idea