From: Torgil S. <tor...@gm...> - 2006-08-31 06:15:42
|
I'm using windows datetimes (100nano-seconds since 0001,1,1) as time in a numpy array and was hit by this behaviour. >>> numpy.__version__ '1.0b4' >>> a=numpy.array([632925394330000000L],numpy.uint64) >>> t=a[0] >>> t 632925394330000000L >>> type(t) <type 'numpy.uint64'> >>> t+1 6.3292539433e+017 >>> type(t+1) <type 'numpy.float64'> >>> t==(t+1) True I was trying to set t larger than any time in an array. Is there any reason for the scalar to upcast in this case? //Torgil |