[Numpy-discussion] Returning numpy scalars in cython functions

Francesc Alted faltet@pytables....
Thu Nov 18 12:12:19 CST 2010


A Thursday 18 November 2010 19:08:00 Francesc Alted escrigué:
> >>> type(np.int_(2))

Err, for maximum portability you can use the int64 constructor:

>>> type(np.int64(2))
<type 'numpy.int64'>

Cheers,

-- 
Francesc Alted


More information about the NumPy-Discussion mailing list