Re: [Numpy-discussion] Should object arrays have a buffer interface?

2008-12-29 Thread Andreas Klöckner
On Montag 29 Dezember 2008, Robert Kern wrote: You could wrap the wrappers in Python and check the dtype. You'd have a similar bug if you passed a wrong non-object dtype, too. Checking/communicating the dtype is something you always have to do when using the 2.x buffer protocol. I'm inclined

[Numpy-discussion] Alternative to record array

2008-12-29 Thread Jean-Baptiste Rudant
Hello, I like to use record arrays to access fields by their name, and because they are esay to use with pytables. But I think it's not very effiicient for what I have to do. Maybe I'm misunderstanding something. Example : import numpy as np age = np.random.randint(0, 99, 10e6) weight =

Re: [Numpy-discussion] Alternative to record array

2008-12-29 Thread Jim Vickroy
Jean-Baptiste Rudant wrote: Hello, I like to use record arrays to access fields by their name, and because they are esay to use with pytables. But I think it's not very effiicient for what I have to do. Maybe I'm misunderstanding something. Example : import numpy as np age =

Re: [Numpy-discussion] Alternative to record array

2008-12-29 Thread Ryan May
Jean-Baptiste Rudant wrote: Hello, I like to use record arrays to access fields by their name, and because they are esay to use with pytables. But I think it's not very effiicient for what I have to do. Maybe I'm misunderstanding something. Example : import numpy as np age =

Re: [Numpy-discussion] Alternative to record array

2008-12-29 Thread Pierre GM
Jean-Baptiste, As you stated, everything depends on what you want to do. If you need to keep the correspondence ageweight for each entry, then yes, record arrays, or at least flexible-type arrays, are the best. (The difference between a recarray and a flexible-type array is that fields can

Re: [Numpy-discussion] Thoughts on persistence/object tracking in scientific code

2008-12-29 Thread Luis Pedro Coelho
Hello, I coincidently started my own implementation of a system to manage intermediate results last week, which I called jug. I wasn't planning to make such an alpha version public just now, but it seems to be on topic. The main idea is to use hashes to map function arguments to paths on the

Re: [Numpy-discussion] Thoughts on persistence/object tracking in scientific code

2008-12-29 Thread Luis Pedro Coelho
On Monday 29 December 2008 14:51:48 Luis Pedro Coelho wrote: I will make the git repository publicly available once I figure out how to do that. You can get my code with: git clone http://coupland.cbi.cmu.edu/jug As I said, I consider this alpha code and am only making it publicly available

Re: [Numpy-discussion] Thoughts on persistence/object tracking in scientific code

2008-12-29 Thread Zachary Pincus
This looks really cool -- thanks Luis. Definitely keep us posted as this progresses, too. Zach On Dec 29, 2008, at 4:41 PM, Luis Pedro Coelho wrote: On Monday 29 December 2008 14:51:48 Luis Pedro Coelho wrote: I will make the git repository publicly available once I figure out how to do

Re: [Numpy-discussion] Thoughts on persistence/object tracking in scientific code

2008-12-29 Thread Gael Varoquaux
Hi Luis, On Mon, Dec 29, 2008 at 02:51:48PM -0500, Luis Pedro Coelho wrote: I coincidently started my own implementation of a system to manage intermediate results last week, which I called jug. I wasn't planning to make such an alpha version public just now, but it seems to be on topic.

Re: [Numpy-discussion] Alternative to record array

2008-12-29 Thread Francesc Alted
A Monday 29 December 2008, Jean-Baptiste Rudant escrigué: Hello, I like to use record arrays to access fields by their name, and because they are esay to use with pytables. But I think it's not very effiicient for what I have to do. Maybe I'm misunderstanding something. Example : import

Re: [Numpy-discussion] Thoughts on persistence/object tracking in scientific code

2008-12-29 Thread Luis Pedro Coelho
Hello all, On Monday 29 December 2008 17:40:07 Gael Varoquaux wrote: It is interesting to see that you take a slightly different approach than the others already discussed. This probably stems from the fact that you are mostly interested by parallelism, whereas there are other adjacent

Re: [Numpy-discussion] formatting issues, locale and co

2008-12-29 Thread David Cournapeau
On Mon, Dec 29, 2008 at 4:36 PM, Charles R Harris charlesr.har...@gmail.com wrote: On Sun, Dec 28, 2008 at 10:35 PM, David Cournapeau da...@ar.media.kyoto-u.ac.jp wrote: Charles R Harris wrote: I put my yesterday work in the fix_float_format branch: - it fixes the locale

Re: [Numpy-discussion] formatting issues, locale and co

2008-12-29 Thread Charles R Harris
On Mon, Dec 29, 2008 at 8:12 PM, David Cournapeau courn...@gmail.comwrote: On Mon, Dec 29, 2008 at 4:36 PM, Charles R Harris charlesr.har...@gmail.com wrote: On Sun, Dec 28, 2008 at 10:35 PM, David Cournapeau da...@ar.media.kyoto-u.ac.jp wrote: Charles R Harris wrote:

Re: [Numpy-discussion] formatting issues, locale and co

2008-12-29 Thread David Cournapeau
Charles R Harris wrote: Yes, I meant that I did not understand the code path in that case. I realize that I don't know how to get the (C) call graph between two code points in python, that would be useful. Where are you dtrace on linux when I need you :) I'm not sure we