[Scipy-tickets] [SciPy] #1162: Allow int64 index type in sum() of measurements.py

SciPy Trac scipy-tickets@scipy....
Wed Apr 21 20:25:15 CDT 2010


#1162: Allow int64 index type in sum() of measurements.py
--------------------+-------------------------------------------------------
 Reporter:  lmwang  |       Owner:  somebody
     Type:  defect  |      Status:  new     
 Priority:  normal  |   Milestone:  0.8.0   
Component:  Other   |     Version:  0.7.0   
 Keywords:          |  
--------------------+-------------------------------------------------------
 The sum method in ndimage/measurements.py checks dtype of the index
 argument.  It only allows [numpy.int8, numpy.int16,
 numpy.int32,numpy.uint8, numpy.uint16, numpy.bool] and excludes
 numpy.int64, which is the defautl dtype for numeric numpy array on 64 bit
 systems.  Can it be added to the list?

 Code snippet (Line 215 - 217 of ndimage/measurements.py, 0.8.0.dev6310):
         if T not in [numpy.int8, numpy.int16, numpy.int32,
                      numpy.uint8, numpy.uint16, numpy.bool]:
             raise ValueError("Invalid index type")

-- 
Ticket URL: <http://projects.scipy.org/scipy/ticket/1162>
SciPy <http://www.scipy.org>
SciPy is open-source software for mathematics, science, and engineering.


More information about the Scipy-tickets mailing list