[Numpy-discussion] code review/build & test for datetime business day API

Benjamin Root ben.root at ou.edu
Mon Jul 25 17:19:10 EDT 2011


On Monday, July 25, 2011, Gael Varoquaux <gael.varoquaux at normalesup.org>
wrote:
> On Mon, Jul 25, 2011 at 03:52:48PM -0500, Mark Wiebe wrote:
>>    Can't use numpy.datetime, since that conflicts with Python's datetime
>>    library, especially in pylab.
>
> I don't understand that: isn't the point of namespaces to avoid those
> naming conflicts. To me that's just like saying that numpy.sum shouldn't
> be named sum because it would conflict with the sum builtin.
>
> My 2 euro cents (a endangered currency)
>
> Gael
>

I think the problem is that numpy's datetime might not be a drop-in
replacement for python's datetime.  For operations in python where one would
use python's sum, numpy's sum would produce effectively identical results.

We even have a few bug reports in our tracker for the use of all and any
being ever-so-slightly different than python's, and it can cause some
confusion in pylab mode.

Admittedly, though, I can't come up with a better name, either.

My two cents (also endangered)...

Ben Root
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20110725/2e1680b5/attachment.html>


More information about the NumPy-Discussion mailing list