[Numpy-discussion] np.dtype(int) 64bit
Sun Oct 24 11:48:30 CDT 2010
On 10/24/2010 1:41 AM, Peter Butterworth wrote:
> thanks for the clarification.
> I haven't found any complete guide on the subject, but it does appear
> there are a some potential gotchas with using numpy 64bit on windows
> (result type is not what the user might expect).
>>>> np.shape([1, 5, 4])
Correct and expected. Anyway, long integers and integer types have been
unified in Python 3 (PEP 237).
> Is there a clear performance advantage for numpy 64bit over numpy
> 32bit on 64 bit windows ? I might be tempted to go back to 32bit
> python to
It depends. You would have to benchmark your code. 64 bit code can
actually be slower. But meeting wrong user expectations is not a
comprehensible reason to me.
> <quote author="Christoph Gohlke">
> Looks correct. CPython's 'int' is implemented as 'long' in C, which is
> 32 bit on Windows (LLP64 model) and 64 bit on other systems (LP64, etc).
> The function argmin() returns an index, which is implemented as
> 'Py_ssize_t' in C and is 64 bit on all 64 bit systems.
More information about the NumPy-Discussion