From: Nadav H. <na...@vi...> - 2003-12-31 11:06:42
|
It works excellent. I see also that there is a corresponding update in = the CVS. Happy new (and peaceful) year, Nadav. -----Original Message----- From: Todd Miller [mailto:jm...@st...] Sent: Tue 30-Dec-03 16:34 To: Nadav Horesh Cc: numpy-discussion Subject: Re: [Numpy-discussion] Slow conversion from list to arrays On Thu, 2003-12-25 at 03:27, Nadav Horesh wrote:=20 > The conversion for a list of large arrays into a matrix is very slow = in > numarray while reasonably fast: >=20 > >>> from numarray import * > >>> a =3D [arange(200000), arange(200000), arange(200000), = arange(200000)] > >>> aa =3D array(a) # Very slow >=20 > -------------------------------- >=20 > >>> from Numeric import * > >>> a =3D [arange(200000), arange(200000), arange(200000), = arange(200000)] > >>> aa =3D array(a) # Fast >=20 > Python version: 2.3.3 > numarray version: Official 0.8 >=20 > Tested under WinXP and RH9 linux. >=20 > Any workaround? >=20 Try concatenate. For the array sizes you're looking at, numarray does OK. You may have to adjust the result shape. Todd=20 > Nadav >=20 >=20 >=20 >=20 >=20 > ------------------------------------------------------- > This SF.net email is sponsored by: IBM Linux Tutorials. > Become an expert in LINUX or just sharpen your skills. Sign up for = IBM's > Free Linux Tutorials. Learn everything from the bash shell to sys = admin. > Click now! = http://ads.osdn.com/?ad_id=3D1278&alloc_id=3D3371&op=3Dclick > _______________________________________________ > Numpy-discussion mailing list > Num...@li... > https://lists.sourceforge.net/lists/listinfo/numpy-discussion --=20 Todd Miller =09 Space Telescope Science Institute 3700 San Martin Drive Baltimore MD, 21030 (410) 338 - 4576 |