[NumPy-Tickets] [NumPy] #2012: Creating an array from a sequence of arrays of datetime64's gives error
NumPy Trac
numpy-tickets@scipy....
Thu Jan 5 22:18:38 CST 2012
#2012: Creating an array from a sequence of arrays of datetime64's gives error
------------------------+---------------------------------------------------
Reporter: jsalvatier | Owner: somebody
Type: defect | Status: new
Priority: normal | Milestone: Unscheduled
Component: numpy.core | Version: 1.6.1
Keywords: |
------------------------+---------------------------------------------------
Comment(by charris):
The problem is that conversion from python datetime to numpy datetime64 is
not currently supported. They are different types. Note that this works
{{{
In [17]: d = datetime(2009, 1, 1, 0, 0)
In [18]: array([str(d)]*2, datetime64)
Out[18]: array(['2009-01-01T00:00:00-0700', '2009-01-01T00:00:00-0700'],
dtype='datetime64[s]')
}}}
I'll admit that the error message isn't very helpful. There is a pull
request to fix some of these issues, I'll take a closer look this weekend.
--
Ticket URL: <http://projects.scipy.org/numpy/ticket/2012#comment:1>
NumPy <http://projects.scipy.org/numpy>
My example project
More information about the NumPy-Tickets
mailing list