[Numpy-discussion] Dates and times and Datetime64 (again)

Alexander Belopolsky ndarray at mac.com
Thu Mar 20 20:53:10 EDT 2014


On Thu, Mar 20, 2014 at 7:16 AM, Nathaniel Smith <njs at pobox.com> wrote:

> Your NEP suggests making all datetime64s be in UTC, and treating string
> representations from unknown timezones as UTC.


I recall that it was at some point suggested that epoch be part of dtype.
 I was not able to find the reasons for a rejection, but it would make
perfect sense to keep timezone offset in dtype and treat it effectively as
an alternative epoch.

The way I like to think about datetime is that YYYY-MM-DD hh:mm:ss.nnn is
just a fancy way to represent numbers which is more convoluted than decimal
notation, but conceptually not so different.  So different units, epochs or
timezones are just different ways to convert an abstract notion of a point
in time to a specific series of bits inside an array.  This is what dtype
is for - a description of how abstract numbers are stored in memory.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20140320/45a993f4/attachment.html>


More information about the NumPy-Discussion mailing list