[Numpy-discussion] numpy.max(0, 1e-6) == 0 (!?)

James Bergstra bergstrj at iro.umontreal.ca
Tue Jan 18 17:19:28 EST 2011


I find that "numpy.max(0, 1e-6) == 0" is confusing, because it makes bugs
hard to spot. The doc says that the second argument to max is an optional
integer.  My bad.

But could the function raise an error if it is passed an invalid 'axis'
argument?  That would have helped.

James
-- 
http://www-etud.iro.umontreal.ca/~bergstrj<http://www-etud.iro.umontreal.ca/%7Ebergstrj>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20110118/581af1f1/attachment.html>


More information about the NumPy-Discussion mailing list