Re: [Numpy-discussion] construction of object arrays

2010-06-30 Thread Keith Goodman
On Wed, Jun 30, 2010 at 10:56 AM, Neal Becker wrote: > What are ways to construct object arrays?  I want an array of objects, each > element default constructed of a particular object type. > > Say my object is class A.  I want a multi-dimensional array, each element > constructed as A(). > > Righ

[Numpy-discussion] construction of object arrays

2010-06-30 Thread Neal Becker
What are ways to construct object arrays? I want an array of objects, each element default constructed of a particular object type. Say my object is class A. I want a multi-dimensional array, each element constructed as A(). Right now, I use np.empty ((a,b,c...), dtype=object) and then itera