[NumPy-Tickets] [NumPy] #2069: boolean indexing with no matches should leave shape same
NumPy Trac
numpy-tickets@scipy....
Thu Mar 1 20:54:44 CST 2012
#2069: boolean indexing with no matches should leave shape same
--------------------+-------------------------------------------------------
Reporter: shaunc | Owner: somebody
Type: defect | Status: new
Priority: normal | Milestone: Unscheduled
Component: Other | Version: 1.6.1
Keywords: |
--------------------+-------------------------------------------------------
>>> a = array( [ [ 1, 1 ] ] )
>>> a[ a == 0 ].shape
(0, )
This is also puzzling as:
>>> aa == 0
array([[False, False]], dtype=bool)
>>> b = [ [ False, False ] ]
>>> a [ b ]
>>> aa[ bb ]
array([[1, 1],
[1, 1]])
--
Ticket URL: <http://projects.scipy.org/numpy/ticket/2069>
NumPy <http://projects.scipy.org/numpy>
My example project
More information about the NumPy-Tickets
mailing list