I have come across this strange behaviour of NumPy 1.0.1 under a 64 bit AMD Opteron:
>>> import numpy >>> numpy.__version__ '1.0.1' >>> numpy.dtype(int).type <type 'numpy.int64'> >>> numpy.dtype(int).type is numpy.int64 True >>> numpy.dtype('int64').type <type 'numpy.int64'> >>> numpy.dtype('int64').type is numpy.int64 True >>> numpy.dtype(long).type <type 'numpy.int64'> >>> numpy.dtype(long).type is numpy.int64 # strange, but ok False >>> issubclass(numpy.dtype(long).type, numpy.int64) # what? False I.e. the NumPy type used for ``long`` is not the same than for ``int`` or explicit ``'int64'``, not even an instance. Is this a bug or is this kind of type comparisons discouraged? Thanks! :: Ivan Vilata i Balaguer >qo< http://www.carabos.com/ Cárabos Coop. V. V V Enjoy Data ""
signature.asc
Description: Digital signature
_______________________________________________ Numpy-discussion mailing list Numpy-discussion@scipy.org http://projects.scipy.org/mailman/listinfo/numpy-discussion