Dear all,
Is there a small bug in following?
In [2]: b
Out[2]:
array([[ 0, 1, 2, 3, 4, 5],
[ 6, 7, 8, 9, 10, 11],
[12, 13, 14, 15, 16, 17],
[18, 19, 20, 21, 22, 23]])
In [3]: b.flatten(order='C')
It works for me, which version of numpy are you using?
What do you get when you type help(b.flatten)?
-=- Olivier
Le 5 avril 2012 04:45, Chao YUE chaoyue...@gmail.com a écrit :
Dear all,
Is there a small bug in following?
In [2]: b
Out[2]:
array([[ 0, 1, 2, 3, 4, 5],
[ 6,
Hi,
Le 05/04/2012 15:00, Olivier Delalleau a écrit :
Ok, it looks weird indeed. I was using numpy 1.6.1 myself, not sure if
it's a bug that's been fixed in 1.6.
Try without the keyword argument (b.flatten('C')), see if at least
that works.
I can reproduce Chao's bug with my numpy 1.5.
As
nice to know this. can also use b.transpose().flatten() to circumvent it.
thanks,
Chao
2012/4/5 Pierre Haessig pierre.haes...@crans.org
Hi,
Le 05/04/2012 15:00, Olivier Delalleau a écrit :
Ok, it looks weird indeed. I was using numpy 1.6.1 myself, not sure if
it's a bug that's been
Hi Chao,
Le 05/04/2012 17:17, Chao YUE a écrit :
nice to know this. can also use b.transpose().flatten() to circumvent it.
Just a short remark : b.T is a shorcut for b.transpose() ;-)
Best,
Pierre
signature.asc
Description: OpenPGP digital signature
Sorry for the noise on the ML, I thougt I had made a private reply...
--
Pierre
Le 05/04/2012 18:53, Pierre Haessig a écrit :
Hi Chao,
Le 05/04/2012 17:17, Chao YUE a écrit :
nice to know this. can also use b.transpose().flatten() to circumvent it.
Just a short remark : b.T is a shorcut