[Numpy-discussion] Strange error taking log of PyObject array

Tom Denniston tom.denniston at alum.dartmouth.org
Mon Jul 10 19:59:25 CDT 2006


The following works on a float array but not an object array.  It
gives a very strange error message.

(Pdb) numpy.log(numpy.array([19155613843.7], dtype=object))
*** AttributeError: 'float' object has no attribute 'log'
(Pdb) numpy.log([19155613843.7])
array([ 23.67586166])




More information about the Numpy-discussion mailing list