You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Max resolution of datetime.datetime is microsecond, so we need to assume the dtype of the datetime scalar is microsecond for our binary ops.
Steps/Code to reproduce bug
In [1]: importcudfIn [2]: importpandasaspdIn [4]: importdatetimeIn [5]: ser=pd.Series([pd.Timestamp(datetime.datetime(1993, 1, 7, 13, 30, 00))], dtype="M8[s]")
In [6]: dt=datetime.datetime(1993, 6, 22, 13, 30)
In [7]: serOut[7]:
01993-01-0713:30:00dtype: datetime64[s]
In [8]: dtOut[8]: datetime.datetime(1993, 6, 22, 13, 30)
In [9]: ser-dtOut[9]:
0-166daysdtype: timedelta64[us]
In [10]: ser=cudf.from_pandas(ser)
sIn [11]: serOut[11]:
01993-01-0713:30:00dtype: datetime64[s]
In [12]: ser-dtOut[12]:
0-166daysdtype: timedelta64[s] # expected `us`
The text was updated successfully, but these errors were encountered:
Describe the bug
Max resolution of
datetime.datetime
is microsecond, so we need to assume the dtype of the datetime scalar is microsecond for our binary ops.Steps/Code to reproduce bug
The text was updated successfully, but these errors were encountered: