From: Andrew S. <str...@as...> - 2006-08-28 20:15:55
|
The following code indicates there is a problem adding a numpy scalar type to a Numeric array. Is this expected behavior or is there a bug somewhere? This bit me in the context of updating some of my code to numpy, while part of it still uses Numeric. import Numeric import numpy print 'Numeric.__version__',Numeric.__version__ print 'numpy.__version__',numpy.__version__ a = Numeric.zeros( (10,2), Numeric.Float ) b = numpy.float64(23.39) a[0,1] = a[0,1] + b assert a[0,1]==b |