Ok, that was an enlightening discussion, I guess I signed up for this
list a couple of days too late!
Thanks,
Eirik
On 09. feb. 2012 12:55, Olivier Delalleau wrote:
This was actually discussed very recently (for more details:
http://mail.scipy.org/pipermail/numpy-discussion/2012-February/06023
This was actually discussed very recently (for more details:
http://mail.scipy.org/pipermail/numpy-discussion/2012-February/060232.html).
It's caused by mixing slicing with advanced indexing. The resulting shape
is the concatenation of a first part obtained by broadcasting of the
non-slice items (
Hello,
(also sent to Scipy-User, sorry for duplicates).
This is (I think) a rather basic question about numpy slicing. I have
the following code:
In [29]: a.shape
Out[29]: (3, 4, 12288, 2)
In [30]: mask.shape
Out[30]: (3, 12288)
In [31]: mask.dtype
Out[31]: dtype('bool')
In [32]: sum(mask[0]