Re: [Numpy-discussion] NumPy date/time types and the resolution concept

2008-07-17 Thread Francesc Alted
A Tuesday 15 July 2008, Pierre GM escrigué: On Tuesday 15 July 2008 07:30:09 Francesc Alted wrote: Maybe is only that. But by using the term 'frequency' I tend to think that you are expecting to have one entry (observation) in your array for each time 'tick' since time start. OTOH, the

Re: [Numpy-discussion] NumPy date/time types and the r esolution concept

2008-07-17 Thread Francesc Alted
A Thursday 17 July 2008, Matt Knox escrigué: Maybe you are right, but by providing many resolutions we are trying to cope with the needs of people that are using them a lot. In particular, we are willing that the authors of the timseries scikit can find on these new dtype a fair

Re: [Numpy-discussion] Ticket #837

2008-07-17 Thread Pauli Virtanen
Wed, 16 Jul 2008 15:43:00 -0600, Charles R Harris wrote: On Wed, Jul 16, 2008 at 3:05 PM, Pauli Virtanen [EMAIL PROTECTED] wrote: http://scipy.org/scipy/numpy/ticket/837 Infinite loop in fromfile and fromstring with sep=' ' and malformed input. I committed a fix to trunk. Does this

Re: [Numpy-discussion] Numpy Advanced Indexing Question

2008-07-17 Thread Stéfan van der Walt
Hi Robert 2008/7/17 Robert Kern [EMAIL PROTECTED]: In [42]: smallcube = cube[idx_i,idx_j,idx_k] Fantastic -- a good way to warm up the brain-circuit in the morning! Is there an easy-to-remember rule that predicts the output shape of the operation above? I'm trying to imaging how the output

[Numpy-discussion] Buildbot failures since r5443

2008-07-17 Thread Pauli Virtanen
Hi, Since r5443 the Sparc buildbots show a Bus error in the test phase: http://buildbot.scipy.org/builders/Linux_SPARC_64_Debian/ builds/102/steps/shell_2/logs/stdio while the one on FreeBSD-64 passes. -- Pauli Virtanen ___ Numpy-discussion

[Numpy-discussion] Testing -heads up with #random

2008-07-17 Thread Fernando Perez
Hi Alan, I was trying to reuse your #random checker for ipython but kept running into problems. Is it working for you in numpy in actual code? Because in the entire SVN tree I only see it mentioned here: maqroll[numpy] grin #random ./numpy/testing/nosetester.py: 43 : if

Re: [Numpy-discussion] Masked arrays and pickle/unpickle

2008-07-17 Thread Stéfan van der Walt
Hi Anthony 2008/7/16 Anthony Floyd [EMAIL PROTECTED]: Unfortunately, when we try to unpickle the data saved with Numpy 1.0.3 in the new code using Numpy 1.1.0, it chokes because it can't import numpy.core.ma for the masked arrays. A check of Numpy 1.1.0 shows that this is now numpy.ma.core.

Re: [Numpy-discussion] Numpy Advanced Indexing Question

2008-07-17 Thread Robert Kern
On Thu, Jul 17, 2008 at 03:16, Stéfan van der Walt [EMAIL PROTECTED] wrote: Hi Robert 2008/7/17 Robert Kern [EMAIL PROTECTED]: In [42]: smallcube = cube[idx_i,idx_j,idx_k] Fantastic -- a good way to warm up the brain-circuit in the morning! Is there an easy-to-remember rule that predicts

Re: [Numpy-discussion] Buildbot failures since r5443

2008-07-17 Thread Robert Kern
On Thu, Jul 17, 2008 at 03:51, Robert Kern [EMAIL PROTECTED] wrote: On Thu, Jul 17, 2008 at 03:19, Pauli Virtanen [EMAIL PROTECTED] wrote: Hi, Since r5443 the Sparc buildbots show a Bus error in the test phase: http://buildbot.scipy.org/builders/Linux_SPARC_64_Debian/

Re: [Numpy-discussion] Ticket #837

2008-07-17 Thread Charles R Harris
On Thu, Jul 17, 2008 at 2:14 AM, Pauli Virtanen [EMAIL PROTECTED] wrote: Wed, 16 Jul 2008 15:43:00 -0600, Charles R Harris wrote: On Wed, Jul 16, 2008 at 3:05 PM, Pauli Virtanen [EMAIL PROTECTED] wrote: http://scipy.org/scipy/numpy/ticket/837 Infinite loop in fromfile and fromstring

Re: [Numpy-discussion] Buildbot failures since r5443

2008-07-17 Thread Charles R Harris
On Thu, Jul 17, 2008 at 3:51 AM, Neil Muller [EMAIL PROTECTED][EMAIL PROTECTED] wrote: On Thu, Jul 17, 2008 at 10:51 AM, Robert Kern [EMAIL PROTECTED] wrote: On Thu, Jul 17, 2008 at 03:19, Pauli Virtanen [EMAIL PROTECTED] wrote: Hi, Since r5443 the Sparc buildbots show a Bus error in

Re: [Numpy-discussion] Testing -heads up with #random

2008-07-17 Thread Alan McIntyre
On Thu, Jul 17, 2008 at 4:25 AM, Fernando Perez [EMAIL PROTECTED] wrote: I was trying to reuse your #random checker for ipython but kept running into problems. Is it working for you in numpy in actual code? Because in the entire SVN tree I only see it mentioned here: maqroll[numpy] grin

[Numpy-discussion] proposal: add a header and footer function to numpy.savetxt

2008-07-17 Thread Tim Michelsen
Hello, sometime scripts and programs create a lot of data output. For the programmer and also others not involved in the scripting but in the evaluation of the output it would be very nice the output files could be prepended with a file header describing what is written in the columns below and to

Re: [Numpy-discussion] Masked arrays and pickle/unpickle

2008-07-17 Thread Stéfan van der Walt
2008/7/17 Anthony Floyd [EMAIL PROTECTED]: What I need to know is how I can trick pickle or Numpy to put the old class into the new class. If you have an example data-file, send it to me off-list and I'll figure out what to do. Maybe it is as simple as np.core.ma = np.oldnumeric.ma It's

Re: [Numpy-discussion] Masked arrays and pickle/unpickle

2008-07-17 Thread Pierre GM
On Thursday 17 July 2008 12:54:10 Stéfan van der Walt wrote: I don't know if renaming things in np.core counts as an API change. Pickling is notoriously unreliable for storing arrays, which is why Robert wrote `load` and `save`. I hope that Pierre can get around to implementing MaskedArray

Re: [Numpy-discussion] Masked arrays and pickle/unpickle

2008-07-17 Thread Anthony Floyd
What I need to know is how I can trick pickle or Numpy to put the old class into the new class. If you have an example data-file, send it to me off-list and I'll figure out what to do. Maybe it is as simple as np.core.ma = np.oldnumeric.ma Yes, pretty much. We've put ma.py into

[Numpy-discussion] Documtation updates for 1.1.1

2008-07-17 Thread Charles R Harris
Hi Stephan, I'm thinking it would nice to backport as many documentation updates to 1.1.1 as possible. It looks like the following steps should do the trick. 1) Make ptvirtan's changes for ufunc documentation. 2) Copy add_newdocs.py 3) Copy fromnumeric.py Does that look reasonable to you?

[Numpy-discussion] Numpy Trac malfunctions

2008-07-17 Thread Pauli Virtanen
Hi, Trac seems to malfunction again with permission problems. At http://projects.scipy.org/scipy/numpy/changeset/5447 there is Traceback (most recent call last): File /usr/lib/python2.4/site-packages/trac/web/main.py, line 387, in dispatch_request dispatcher.dispatch(req) File

Re: [Numpy-discussion] Numpy Trac malfunctions

2008-07-17 Thread Jarrod Millman
On Thu, Jul 17, 2008 at 11:34 AM, Pauli Virtanen [EMAIL PROTECTED] wrote: Trac seems to malfunction again with permission problems. At http://projects.scipy.org/scipy/numpy/changeset/5447 there is Fixed. -- Jarrod Millman Computational Infrastructure for Research Labs 10 Giannini Hall, UC

Re: [Numpy-discussion] Documtation updates for 1.1.1

2008-07-17 Thread Pauli Virtanen
Thu, 17 Jul 2008 12:00:28 -0600, Charles R Harris wrote: Hi Stephan, I'm thinking it would nice to backport as many documentation updates to 1.1.1 as possible. It looks like the following steps should do the trick. 1) Make ptvirtan's changes for ufunc documentation. 2) Copy

[Numpy-discussion] Removing some warnings from numpy.i

2008-07-17 Thread Matthieu Brucher
Hi, I've enclosed a patch for numpy.i (against the trunk). Its goal is to add const char* instead of char* in some functions (pytype_string and typecode_string). The char* use raises some warnings in GCC 4.2.3 (and it is indeed not type safe IMHO). Matthieu -- French PhD student Website :

Re: [Numpy-discussion] Masked arrays and pickle/unpickle

2008-07-17 Thread Stéfan van der Walt
Hi Pierre, 2008/7/17 Pierre GM [EMAIL PROTECTED]: Otherwise, you can already save the array and mask separately. An other possibility is to store the MaskedArray as a record array, with one field for the data and one field for the mask. What about the other parameters, such as fill value?

Re: [Numpy-discussion] Documtation updates for 1.1.1

2008-07-17 Thread Stéfan van der Walt
2008/7/17 Charles R Harris [EMAIL PROTECTED]: I'm thinking it would nice to backport as many documentation updates to 1.1.1 as possible. It looks like the following steps should do the trick. 1) Make ptvirtan's changes for ufunc documentation. 2) Copy add_newdocs.py 3) Copy fromnumeric.py

Re: [Numpy-discussion] Documtation updates for 1.1.1

2008-07-17 Thread Jarrod Millman
On Thu, Jul 17, 2008 at 1:34 PM, Stéfan van der Walt [EMAIL PROTECTED] wrote: I don't mind, but did we make changes to those files? As Pauli mentioned, we haven't yet merged back the edited docstrings. They haven't been reviewed, but are probably better than what we currently have; would

Re: [Numpy-discussion] Masked arrays and pickle/unpickle

2008-07-17 Thread Anthony Floyd
Further, could we rename numpy.ma.core to numpy.ma._core? I think we should make it clear that users should not import from core directly. Just to add a bit of noise here, it's not that we were importing directly from .core, it's that pickle was telling us that the actual class associated with

Re: [Numpy-discussion] Ticket review: #848, leak in PyArray_DescrFromType

2008-07-17 Thread Charles R Harris
On Tue, Jul 15, 2008 at 9:28 AM, Michael Abbott [EMAIL PROTECTED] wrote: On Tue, 15 Jul 2008, Michael Abbott wrote: Only half of my patch for this bug has gone into trunk, and without the rest of my patch there remains a leak. I think I might need to explain a little more about the reason

Re: [Numpy-discussion] Documtation updates for 1.1.1

2008-07-17 Thread Charles R Harris
On Thu, Jul 17, 2008 at 2:34 PM, Stéfan van der Walt [EMAIL PROTECTED] wrote: 2008/7/17 Charles R Harris [EMAIL PROTECTED]: I'm thinking it would nice to backport as many documentation updates to 1.1.1 as possible. It looks like the following steps should do the trick. 1) Make ptvirtan's

Re: [Numpy-discussion] arccosh for complex numbers, goofy choice of branch

2008-07-17 Thread Pauli Virtanen
Mon, 17 Mar 2008 08:07:38 -0600, Charles R Harris wrote: [clip] OK, that does it. I'm going to change it's behavior. The problem with bad arccosh branch cuts is still present: import numpy as np numpy.__version__ '1.2.0.dev5436.e45a7627a39d' np.arccosh(-1e-9 + 0.1j)

Re: [Numpy-discussion] Masked arrays and pickle/unpickle

2008-07-17 Thread Pierre GM
On Thursday 17 July 2008 16:29:48 Stéfan van der Walt wrote: An other possibility is to store the MaskedArray as a record array, with one field for the data and one field for the mask. What about the other parameters, such as fill value? Dang, forgot about that. Having a dictionary of

Re: [Numpy-discussion] arccosh for complex numbers, goofy choice of branch

2008-07-17 Thread Charles R Harris
On Thu, Jul 17, 2008 at 3:56 PM, Pauli Virtanen [EMAIL PROTECTED] wrote: Mon, 17 Mar 2008 08:07:38 -0600, Charles R Harris wrote: [clip] OK, that does it. I'm going to change it's behavior. The problem with bad arccosh branch cuts is still present: import numpy as np numpy.__version__

Re: [Numpy-discussion] Masked arrays and pickle/unpickle

2008-07-17 Thread Mark Miller
On Thu, Jul 17, 2008 at 3:18 PM, Pierre GM [EMAIL PROTECTED] wrote: Dang, forgot about that. Having a dictionary of options would be cool, but we can't store it inside a regular ndarray. If we write to a file, we may want to write a header first that would store all the metadata we need.