-
-
Notifications
You must be signed in to change notification settings - Fork 12.1k
Closed
Description
On windows 7:
>>> np.cint, np.cint is np.int32
(numpy.int32, False)
>>> np.int_, np.int_ is np.int32
(numpy.int32, True)On 64-bit linux:
>>> np.int_, np.int_ is np.int64
(numpy.int64, True)
>>> np.longlong, np.longlong is np.int64
(numpy.int64, False)(original title: intc displays wrong class name)
The string representation of numpy.intc is <class 'numpy.int32'>. This would fine if this were true--just a name pointing to the same object. But at least on Windows 7, numpy.intc is not the same object as numpy.int32; it's not even a subclass. This is very confusing for debugging objects of this type, as objects inexplicably fail an isinstance test.
Could one of these two small changes be made:
- Either make
intcjust be another name pointing to the object behindint32 - Or make
intcprint out<class 'numpy.intc'>
Reactions are currently unavailable