I have installed numpy-0.9.6 I haven't tried 0.9.8.
--
http://mail.python.org/mailman/listinfo/python-list
Once I vectorize a function it does not acccept scalars anymore. Es
def f(x): return x*2
vf = vectorize(f)
print vf(2)
AttributeError: 'int' object has no attribute 'astype'
Is this the intended behaviour?
--
http://mail.python.org/mailman/listinfo/python-list
ago wrote:
Once I vectorize a function it does not acccept scalars anymore. Es
def f(x): return x*2
vf = vectorize(f)
print vf(2)
AttributeError: 'int' object has no attribute 'astype'
Is this the intended behaviour?
More or less. It would be nice if it transparently handled the
ago wrote:
Once I vectorize a function it does not acccept scalars anymore. Es
def f(x): return x*2
vf = vectorize(f)
print vf(2)
AttributeError: 'int' object has no attribute 'astype'
Is this the intended behaviour?
Vectorize handles scalars in recent versions of NumPy. Which