[NumPy-Tickets] [NumPy] #1387: Undefined behavior for bincount for empty array

NumPy Trac numpy-tickets@scipy....
Fri Apr 1 14:49:19 CDT 2011


#1387: Undefined behavior for bincount for empty array
-----------------------+----------------------------------------------------
 Reporter:  cdavid     |       Owner:  somebody   
     Type:  defect     |      Status:  new        
 Priority:  normal     |   Milestone:  Unscheduled
Component:  numpy.lib  |     Version:             
 Keywords:             |  
-----------------------+----------------------------------------------------

Comment(by rgommers):

 The desired behavior would be to just return the empty array (similar to
 histogram), or if bins are given to return an array of the right size with
 all zeros.

 Same issue for digitize(), it also gives a ValueError.

-- 
Ticket URL: <http://projects.scipy.org/numpy/ticket/1387#comment:1>
NumPy <http://projects.scipy.org/numpy>
My example project


More information about the NumPy-Tickets mailing list