Re: [Numpy-discussion] Home for pyhdf5io?

2009-05-23 Thread Albert Thuswaldner
Thank you pauli for your input. I agree with you that our projects have different goals, even if they touch on the same subject. The goal of pyhdf5io is to provide a very simple interface, so that the user can save his/her data. The reasone for picking hdf5 was of course also to enable the use of

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Stéfan van der Walt
2009/5/23 Charles R Harris charlesr.har...@gmail.com: In [9]: fromfile(empty.dat, count=10) 10 items requested but only 0 read --- MemoryError   Traceback (most recent call last)

Re: [Numpy-discussion] Home for pyhdf5io?

2009-05-23 Thread David Warde-Farley
On 23-May-09, at 5:36 AM, Albert Thuswaldner wrote: So i guess in the long term i have to also add pickling support. In the short term i will add warnings for the data types that are not supported. In order to ensure optimal division of labour, I'd suggest simply basing your pickling

[Numpy-discussion] Ticket #1113, change title?

2009-05-23 Thread David Warde-Farley
Can someone with the requisite permissions change the title of ticket #1113 to reflect the fact that it affects both ppc and ppc64? Alternately, if you know why the bug is happening, you could file a patch ;) David ___ Numpy-discussion mailing list

Re: [Numpy-discussion] Ticket #1113, change title?

2009-05-23 Thread David Cournapeau
David Warde-Farley wrote: Can someone with the requisite permissions change the title of ticket #1113 to reflect the fact that it affects both ppc and ppc64? Done. Alternately, if you know why the bug is happening, you could file a patch ;) I have not looked at the code, but if

Re: [Numpy-discussion] Ticket #1113, change title?

2009-05-23 Thread David Warde-Farley
On 23-May-09, at 8:54 AM, David Cournapeau wrote: I have not looked at the code, but if the precision is indeed single precision, a tolerance of 1e-15 may not make much sense (single precision has 7 significant digits in normal representation) Yes, I was wondering about that too, though

[Numpy-discussion] numpy.choose question

2009-05-23 Thread Mark Wendell
I have a question about the numpy.choose method. I'm working with rgb image arrays (converted using PIL's 'asarray'), and would like to combine data from multiple images. The choose method seemed just the thing for what i want to do: creating new images from multiple source images and an index

Re: [Numpy-discussion] Ticket #1113, change title?

2009-05-23 Thread Pauli Virtanen
Sat, 23 May 2009 09:28:08 -0400, David Warde-Farley wrote: On 23-May-09, at 8:54 AM, David Cournapeau wrote: I have not looked at the code, but if the precision is indeed single precision, a tolerance of 1e-15 may not make much sense (single precision has 7 significant digits in normal

Re: [Numpy-discussion] Ticket #1113, change title?

2009-05-23 Thread David Warde-Farley
On 23-May-09, at 2:33 PM, Pauli Virtanen wrote: Yes, I was wondering about that too, though notably the tests pass on x86, and in fact the result on ppc was nowhere near 0 when I checked it. What do you mean by nowhere near? What does the following output for you:

Re: [Numpy-discussion] numpy.choose question

2009-05-23 Thread Christopher Barker
Mark Wendell wrote: I'm working with rgb image arrays (converted using PIL's 'asarray'), and would like to combine data from multiple images. The choose method seemed just the thing for what i want to do: creating new images from multiple source images and an index mask. However, it looks like

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Christopher Barker
Stéfan van der Walt wrote: 2009/5/23 Charles R Harris charlesr.har...@gmail.com: In [9]: fromfile(empty.dat, count=10) Instead of throwing errors in these scenarios, we could just return the elements read and raise a warning? This is consistent with most other file APIs I know and allows

Re: [Numpy-discussion] Home for pyhdf5io?

2009-05-23 Thread Albert Thuswaldner
Actually my vision with pyhdf5io is to have hdf5 to replace numpy's own binary file format (.npy, npz). Pyhdf5io (or an incarnation of it) should be the standard (binary) way to store data in scipy/numpy. A bold statement, I know, but I think that it would be an improvement, especially for those

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Charles R Harris
On Sat, May 23, 2009 at 2:02 PM, Christopher Barker chris.bar...@noaa.govwrote: Stéfan van der Walt wrote: 2009/5/23 Charles R Harris charlesr.har...@gmail.com: In [9]: fromfile(empty.dat, count=10) Instead of throwing errors in these scenarios, we could just return the elements read

Re: [Numpy-discussion] Home for pyhdf5io?

2009-05-23 Thread Charles R Harris
On Sat, May 23, 2009 at 2:25 PM, Albert Thuswaldner albert.thuswald...@gmail.com wrote: Actually my vision with pyhdf5io is to have hdf5 to replace numpy's own binary file format (.npy, npz). Pyhdf5io (or an incarnation of it) should be the standard (binary) way to store data in scipy/numpy.

Re: [Numpy-discussion] Home for pyhdf5io?

2009-05-23 Thread David Warde-Farley
On 23-May-09, at 4:25 PM, Albert Thuswaldner wrote: Actually my vision with pyhdf5io is to have hdf5 to replace numpy's own binary file format (.npy, npz). Pyhdf5io (or an incarnation of it) should be the standard (binary) way to store data in scipy/numpy. A bold statement, I know, but I

Re: [Numpy-discussion] Home for pyhdf5io?

2009-05-23 Thread Robert Kern
On Sat, May 23, 2009 at 06:47, David Warde-Farley d...@cs.toronto.edu wrote: On 23-May-09, at 5:36 AM, Albert Thuswaldner wrote: So i guess in the long term i have to also add pickling support. In the short term i will add warnings for the data types that are not supported. In order to

Re: [Numpy-discussion] Home for pyhdf5io?

2009-05-23 Thread Robert Kern
On Sat, May 23, 2009 at 15:41, David Warde-Farley d...@cs.toronto.edu wrote: On 23-May-09, at 4:25 PM, Albert Thuswaldner wrote: Actually my vision with pyhdf5io is to have hdf5 to replace numpy's own binary file format (.npy, npz). Pyhdf5io (or an incarnation of it) should be the standard

Re: [Numpy-discussion] numpy.choose question

2009-05-23 Thread Robert Kern
On Sat, May 23, 2009 at 10:14, Mark Wendell mark.wend...@gmail.com wrote: I have a question about the numpy.choose method. I'm working with rgb image arrays (converted using PIL's 'asarray'), and would like to combine data from multiple images. The choose method seemed just the thing for what

Re: [Numpy-discussion] Home for pyhdf5io?

2009-05-23 Thread David Warde-Farley
On 23-May-09, at 4:59 PM, Robert Kern wrote: Otherwise it will just work the way it does now. That would cause difficulties. Now the format of your data depends on whether or not you have a package installed. That's not a very good level of control. Sorry, I wasn't clear. What I meant

Re: [Numpy-discussion] Home for pyhdf5io?

2009-05-23 Thread Robert Kern
On Sat, May 23, 2009 at 16:47, David Warde-Farley d...@cs.toronto.edu wrote: On 23-May-09, at 4:59 PM, Robert Kern wrote:  Otherwise it will just work the way it does now. That would cause difficulties. Now the format of your data depends on whether or not you have a package installed.

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Stéfan van der Walt
Hi Chris and Charles 2009/5/23 Charles R Harris charlesr.har...@gmail.com: Robert thought that should be the default, but I think that means everyone would be forced to check how many items they got every time they read, which is too much code and likely to be forgotten and lead to errors. So

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Charles R Harris
2009/5/23 Stéfan van der Walt ste...@sun.ac.za Hi Chris and Charles 2009/5/23 Charles R Harris charlesr.har...@gmail.com: Robert thought that should be the default, but I think that means everyone would be forced to check how many items they got every time they read, which is too much

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Robert Kern
On Sat, May 23, 2009 at 18:43, Charles R Harris charlesr.har...@gmail.com wrote: Warnings used to warn once and then never again. I once hacked the module to make it work right but I don't know if it has been officially fixed. Do you know if it's been fixed? Warning once per location then

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Charles R Harris
On Sat, May 23, 2009 at 5:51 PM, Robert Kern robert.k...@gmail.com wrote: On Sat, May 23, 2009 at 18:43, Charles R Harris charlesr.har...@gmail.com wrote: Warnings used to warn once and then never again. I once hacked the module to make it work right but I don't know if it has been

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Robert Kern
On Sat, May 23, 2009 at 18:57, Charles R Harris charlesr.har...@gmail.com wrote: On Sat, May 23, 2009 at 5:51 PM, Robert Kern robert.k...@gmail.com wrote: On Sat, May 23, 2009 at 18:43, Charles R Harris charlesr.har...@gmail.com wrote: Warnings used to warn once and then never again. I once

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Robert Kern
On Sat, May 23, 2009 at 18:57, Charles R Harris charlesr.har...@gmail.com wrote: You were supposed to be able to change the default behaviour, but it didn't used to work. I think if you are going to use a warning as a flag then it has to always be raised when a failure occurs, not just the

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Charles R Harris
On Sat, May 23, 2009 at 6:03 PM, Robert Kern robert.k...@gmail.com wrote: On Sat, May 23, 2009 at 18:57, Charles R Harris charlesr.har...@gmail.com wrote: You were supposed to be able to change the default behaviour, but it didn't used to work. I think if you are going to use a warning as

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Eric Firing
Charles R Harris wrote: On Sat, May 23, 2009 at 6:03 PM, Robert Kern robert.k...@gmail.com mailto:robert.k...@gmail.com wrote: On Sat, May 23, 2009 at 18:57, Charles R Harris charlesr.har...@gmail.com mailto:charlesr.har...@gmail.com wrote: You were supposed to be able to

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Stéfan van der Walt
2009/5/24 Eric Firing efir...@hawaii.edu: OK, that would work. Although I think a named argument might be a more transparent way to specify behaviour than setting the warnings. I agree; using a warning strikes me as an abuse of the warnings mechanism.  Instead of a strict flag, which I find

Re: [Numpy-discussion] Inconsistent error messages.

2009-05-23 Thread Charles R Harris
On Sat, May 23, 2009 at 6:37 PM, Eric Firing efir...@hawaii.edu wrote: Charles R Harris wrote: On Sat, May 23, 2009 at 6:03 PM, Robert Kern robert.k...@gmail.com mailto:robert.k...@gmail.com wrote: On Sat, May 23, 2009 at 18:57, Charles R Harris charlesr.har...@gmail.com