[Numpy-discussion] Numpy's policy for releasing memory

2012-11-12 Thread Austin Bingham
I'm trying to understand how numpy decides when to release memory and whether it's possible to exert any control over that. The situation is that I'm profiling memory usage on a system in which a great deal of the overall memory is tied up in ndarrays. Since numpy manages ndarray memory on its own

Re: [Numpy-discussion] Do we want scalar casting to behave as it does at the moment?

2012-11-12 Thread Benjamin Root
On Monday, November 12, 2012, Matthew Brett wrote: > Hi, > > On Mon, Nov 12, 2012 at 8:15 PM, Benjamin Root wrote: > > > > > > On Monday, November 12, 2012, Olivier Delalleau wrote: > >> > >> 2012/11/12 Nathaniel Smith > >>> > >>> On Mon, Nov 12, 2012 at 8:54 PM, Matthew Brett < > matthew.br...@

Re: [Numpy-discussion] Do we want scalar casting to behave as it does at the moment?

2012-11-12 Thread Matthew Brett
Hi, On Mon, Nov 12, 2012 at 8:15 PM, Benjamin Root wrote: > > > On Monday, November 12, 2012, Olivier Delalleau wrote: >> >> 2012/11/12 Nathaniel Smith >>> >>> On Mon, Nov 12, 2012 at 8:54 PM, Matthew Brett >>> wrote: >>> > Hi, >>> > >>> > I wanted to check that everyone knows about and is happ

Re: [Numpy-discussion] Do we want scalar casting to behave as it does at the moment?

2012-11-12 Thread Benjamin Root
On Monday, November 12, 2012, Benjamin Root wrote: > > > On Monday, November 12, 2012, Olivier Delalleau wrote: > >> 2012/11/12 Nathaniel Smith >> >>> On Mon, Nov 12, 2012 at 8:54 PM, Matthew Brett >>> wrote: >>> > Hi, >>> > >>> > I wanted to check that everyone knows about and is happy with the

Re: [Numpy-discussion] Do we want scalar casting to behave as it does at the moment?

2012-11-12 Thread Benjamin Root
On Monday, November 12, 2012, Olivier Delalleau wrote: > 2012/11/12 Nathaniel Smith 'n...@pobox.com');>> > >> On Mon, Nov 12, 2012 at 8:54 PM, Matthew Brett >> > 'matthew.br...@gmail.com');>> >> wrote: >> > Hi, >> > >> > I wanted to check that everyone knows about and is happy with the >> > scal

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Alan G Isaac
On 11/12/2012 8:18 PM, Sebastian Berg wrote: > I have created a pull request This is still a bit different than I thought you intended. With `size=None` we don't get an element, but rather a 0d array. I thought the idea was to return an element in this case? Alan __

[Numpy-discussion] RE : 1.7.0 release

2012-11-12 Thread Robert Lagacé
Congratulation. De : numpy-discussion-boun...@scipy.org [numpy-discussion-boun...@scipy.org] de la part de Ondřej Čertík [ondrej.cer...@gmail.com] Date d'envoi : 12 novembre 2012 17:27 À : Discussion of Numerical Python Objet : Re: [Numpy-discussion] 1.7.0

Re: [Numpy-discussion] Do we want scalar casting to behave as it does at the moment?

2012-11-12 Thread Olivier Delalleau
2012/11/12 Nathaniel Smith > On Mon, Nov 12, 2012 at 8:54 PM, Matthew Brett > wrote: > > Hi, > > > > I wanted to check that everyone knows about and is happy with the > > scalar casting changes from 1.6.0. > > > > Specifically, the rules for (array, scalar) casting have changed such > > that the

Re: [Numpy-discussion] Scipy dot

2012-11-12 Thread Nicolas SCHEFFER
Yep exactly. I just want to make sure that we talked enough on the principle first (ie. goals and technical approach), and that indeed the code is good enough to look at. I get it from your answer that it is, so I went ahead https://github.com/numpy/numpy/pull/2730 Thanks -nicolas On Mon, Nov

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Sebastian Berg
On Mon, 2012-11-12 at 18:36 -0500, Alan G Isaac wrote: > On 11/12/2012 5:46 PM, Nathaniel Smith wrote: > > Want to make a pull request? > > > Well, I'd be happy to help Sebastien to change the > code, but I'm not a git user. > I have created a pull request, but tests are still needed... If you

Re: [Numpy-discussion] Compiling NumPy on Windows for Python 3.3

2012-11-12 Thread Peter Cock
On Tue, Nov 13, 2012 at 12:36 AM, Peter Cock wrote: > > I've not yet run the numpy tests yet, but I think this means > my github branches are worth merging: > > https://github.com/peterjc/numpy/commits/msvc10 > Hi Ralf, Pull request filed, assuming this gets applied to the master could you also

Re: [Numpy-discussion] 1.7.0 release

2012-11-12 Thread Ondřej Čertík
On Mon, Nov 12, 2012 at 3:47 PM, Charles R Harris wrote: > > > On Mon, Nov 12, 2012 at 3:27 PM, Ondřej Čertík > wrote: >> >> Hi, >> >> On Mon, Nov 5, 2012 at 11:33 PM, Travis Oliphant >> wrote: >> > Hey all, >> > >> > Ondrej has been tied up finishing his PhD for the past several weeks. >> > He

Re: [Numpy-discussion] Compiling NumPy on Windows for Python 3.3

2012-11-12 Thread Peter Cock
On Mon, Nov 12, 2012 at 9:20 PM, Ralf Gommers wrote: >> ... >> Found executable C:\cygwin\usr\bin\gcc.exe >> g++ -mno-cygwin _configtest.o -lmsvcr100 -o _configtest.exe >> Could not locate executable g++ >> Executable g++ does not exist > > > A C++ compiler shouldn't be needed for numpy, so it sho

Re: [Numpy-discussion] 1.7.0 release

2012-11-12 Thread Charles R Harris
On Mon, Nov 12, 2012 at 3:27 PM, Ondřej Čertík wrote: > Hi, > > On Mon, Nov 5, 2012 at 11:33 PM, Travis Oliphant > wrote: > > Hey all, > > > > Ondrej has been tied up finishing his PhD for the past several weeks. > He is defending his work shortly and should be available to continue to > help wi

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Alan G Isaac
On 11/12/2012 5:46 PM, Nathaniel Smith wrote: > Want to make a pull request? Well, I'd be happy to help Sebastien to change the code, but I'm not a git user. And I'd have some questions. E.g., with `size=None`, couldn't we just call Python's random.choice? And for sampling without replacement,

Re: [Numpy-discussion] 1.7.0 release

2012-11-12 Thread David Cournapeau
On Mon, Nov 12, 2012 at 10:27 PM, Ondřej Čertík wrote: > Hi, > > On Mon, Nov 5, 2012 at 11:33 PM, Travis Oliphant wrote: >> Hey all, >> >> Ondrej has been tied up finishing his PhD for the past several weeks. He is >> defending his work shortly and should be available to continue to help with

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Nathaniel Smith
On Mon, Nov 12, 2012 at 11:34 PM, Alan G Isaac wrote: > On 11/12/2012 12:16 PM, Sebastian Berg wrote: >> So instead of taking a sequence of length 1, take an element as default. > > Sebastien has proposed that np.random.choice return > a single *element* by default, not a 1d array of length 1. > H

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Alan G Isaac
On 11/12/2012 12:16 PM, Sebastian Berg wrote: > So instead of taking a sequence of length 1, take an element as default. Sebastien has proposed that np.random.choice return a single *element* by default, not a 1d array of length 1. He proposes to associate this with a default value of `size=None`

Re: [Numpy-discussion] 1.7.0 release

2012-11-12 Thread Ondřej Čertík
Hi, On Mon, Nov 5, 2012 at 11:33 PM, Travis Oliphant wrote: > Hey all, > > Ondrej has been tied up finishing his PhD for the past several weeks. He is > defending his work shortly and should be available to continue to help with > the 1.7.0 release around the first of December.He and I hav

Re: [Numpy-discussion] Do we want scalar casting to behave as it does at the moment?

2012-11-12 Thread Nathaniel Smith
On Mon, Nov 12, 2012 at 10:27 PM, Matthew Brett wrote: > Hi, > > On Mon, Nov 12, 2012 at 1:11 PM, Nathaniel Smith wrote: >> On Mon, Nov 12, 2012 at 8:54 PM, Matthew Brett >> wrote: >>> Hi, >>> >>> I wanted to check that everyone knows about and is happy with the >>> scalar casting changes from

Re: [Numpy-discussion] Do we want scalar casting to behave as it does at the moment?

2012-11-12 Thread Matthew Brett
Hi, On Mon, Nov 12, 2012 at 1:11 PM, Nathaniel Smith wrote: > On Mon, Nov 12, 2012 at 8:54 PM, Matthew Brett > wrote: >> Hi, >> >> I wanted to check that everyone knows about and is happy with the >> scalar casting changes from 1.6.0. >> >> Specifically, the rules for (array, scalar) casting ha

Re: [Numpy-discussion] Compiling NumPy on Windows for Python 3.3

2012-11-12 Thread Ralf Gommers
On Mon, Nov 12, 2012 at 1:31 PM, Peter Cock wrote: > On Sun, Nov 11, 2012 at 11:20 PM, Peter Cock > wrote: > > On Sun, Nov 11, 2012 at 9:05 PM, Ralf Gommers > wrote: > >> > >> Those changes look correct, a PR would be great. > >> > > > > I'll do that later this week - but feel free to do it your

Re: [Numpy-discussion] Do we want scalar casting to behave as it does at the moment?

2012-11-12 Thread Nathaniel Smith
On Mon, Nov 12, 2012 at 8:54 PM, Matthew Brett wrote: > Hi, > > I wanted to check that everyone knows about and is happy with the > scalar casting changes from 1.6.0. > > Specifically, the rules for (array, scalar) casting have changed such > that the resulting dtype depends on the _value_ of the

Re: [Numpy-discussion] Scipy dot

2012-11-12 Thread Nathaniel Smith
On Mon, Nov 12, 2012 at 9:08 PM, Nicolas SCHEFFER wrote: > I've pushed my code to a branch here > https://github.com/leschef/numpy/tree/faster_dot > with the commit > https://github.com/leschef/numpy/commit/ea037770e03f23aca1a06274a1a8e8bf0e0e2ee4 > > Let me know if that's enough to create a pull

Re: [Numpy-discussion] Scipy dot

2012-11-12 Thread Nicolas SCHEFFER
I've pushed my code to a branch here https://github.com/leschef/numpy/tree/faster_dot with the commit https://github.com/leschef/numpy/commit/ea037770e03f23aca1a06274a1a8e8bf0e0e2ee4 Let me know if that's enough to create a pull request. Thanks, -nicolas On Sat, Nov 10, 2012 at 4:39 AM, George

[Numpy-discussion] Do we want scalar casting to behave as it does at the moment?

2012-11-12 Thread Matthew Brett
Hi, I wanted to check that everyone knows about and is happy with the scalar casting changes from 1.6.0. Specifically, the rules for (array, scalar) casting have changed such that the resulting dtype depends on the _value_ of the scalar. Mark W has documented these changes here: http://docs.sci

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Sebastian Berg
On Mon, 2012-11-12 at 17:52 +0100, Nathaniel Smith wrote: > On Mon, Nov 12, 2012 at 5:31 PM, Alan G Isaac wrote: > > In a comment on the issue https://github.com/numpy/numpy/issues/2724 > > Sebastian notes: > > "it could also be reasonable to have size=None as default and have it > > return a sc

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Nathaniel Smith
On Mon, Nov 12, 2012 at 5:31 PM, Alan G Isaac wrote: > In a comment on the issue https://github.com/numpy/numpy/issues/2724 > Sebastian notes: > "it could also be reasonable to have size=None as default and have it return > a scalar/the given axes removed in that case. That would be a real chang

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Alan G Isaac
In a comment on the issue https://github.com/numpy/numpy/issues/2724 Sebastian notes: "it could also be reasonable to have size=None as default and have it return a scalar/the given axes removed in that case. That would be a real change in functionality unfortunately, but it would make sense for

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Alan G Isaac
On 11/12/2012 10:00 AM, Nathaniel Smith wrote: > I don't really have an opinion on whether those > things should be supported, or what the right API should be; I haven't > really thought about it. Maybe others on the list have opinions. I was > just saying that we have plenty of time to decide abou

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Nathaniel Smith
On Mon, Nov 12, 2012 at 3:50 PM, Alan G Isaac wrote: > On 11/12/2012 8:59 AM, Sebastian Berg wrote: >> https://github.com/numpy/numpy/blob/master/numpy/random/mtrand/mtrand.pyx#L919 >> >> Sounds like it should be pretty simple to add axis=None which would >> change the current behavior very little

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Alan G Isaac
On 11/12/2012 8:59 AM, Sebastian Berg wrote: > https://github.com/numpy/numpy/blob/master/numpy/random/mtrand/mtrand.pyx#L919 > > Sounds like it should be pretty simple to add axis=None which would > change the current behavior very little, it would stop give an error > anymore for none 1-d arrays

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Nathaniel Smith
On Mon, Nov 12, 2012 at 2:48 PM, Alan G Isaac wrote: > On 11/9/2012 12:21 PM, Nathaniel Smith wrote: >> you might want to double-check that the >> np.random.choice in 1.7 actually*does* give an error if the input >> array is not 1-d > > Any idea where I can look at the code? > I browsed github af

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Sebastian Berg
Hey, On Mon, 2012-11-12 at 08:48 -0500, Alan G Isaac wrote: > On 11/9/2012 12:21 PM, Nathaniel Smith wrote: > > you might want to double-check that the > > np.random.choice in 1.7 actually*does* give an error if the input > > array is not 1-d > > > Any idea where I can look at the code? > I bro

Re: [Numpy-discussion] fix random.choice for 1.7?

2012-11-12 Thread Alan G Isaac
On 11/9/2012 12:21 PM, Nathaniel Smith wrote: > you might want to double-check that the > np.random.choice in 1.7 actually*does* give an error if the input > array is not 1-d Any idea where I can look at the code? I browsed github after failing to find a productive search string, but failed to f

Re: [Numpy-discussion] Compiling NumPy on Windows for Python 3.3

2012-11-12 Thread Peter Cock
On Sun, Nov 11, 2012 at 11:20 PM, Peter Cock wrote: > On Sun, Nov 11, 2012 at 9:05 PM, Ralf Gommers wrote: >> >> Those changes look correct, a PR would be great. >> > > I'll do that later this week - but feel free to do it yourself immediately > if more convenient. > Hi again Ralf, OK, new bran