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
I'm not quite sure exactly what happened, but whereas np.datetime64('NaT') == np.datetime64('NaT', 'us') is True on NumPy 1.9, it's False on NumPy 1.10.
I tested this out on a few NumPy/Python versions, and in some cases this comparison results in warnings. In particular:
Python 2.7, NumPy 1.9: True / No warning
Python 3.4, NumPy 1.9: True / DeprecationWarning: Implicitly casting between incompatible kinds. In a future numpy release, this will raise an error. Use casting="unsafe" if this is intentional.
Python 2.7, NumPy 1.10: False / DeprecationWarning: elementwise == comparison failed; this will raise an error in the future.
Fixes lots of ambiguous calls to `np.full` where the result value was
float but the input was an integer, all of which were throwing
FutureWarnings.
Also works around numpy/numpy#6452 by using
NaT values with explicit units.
ssanderson
pushed a commit
to quantopian/zipline
that referenced
this issue
Jan 22, 2016
Fixes lots of ambiguous calls to `np.full` where the result value was
float but the input was an integer, all of which were throwing
FutureWarnings.
Also works around numpy/numpy#6452 by using
NaT values with explicit units.
shoyer
added a commit
to shoyer/numpy
that referenced
this issue
May 24, 2018
I'm not quite sure exactly what happened, but whereas
np.datetime64('NaT') == np.datetime64('NaT', 'us')
isTrue
on NumPy 1.9, it'sFalse
on NumPy 1.10.I tested this out on a few NumPy/Python versions, and in some cases this comparison results in warnings. In particular:
True
/ No warningTrue
/DeprecationWarning: Implicitly casting between incompatible kinds. In a future numpy release, this will raise an error. Use casting="unsafe" if this is intentional.
False
/DeprecationWarning: elementwise == comparison failed; this will raise an error in the future.
False
/ No warningBased on git blame, it looks like the latest deprecation warning introduced by @njsmith in #5964.
xref pydata/xarray#618
The text was updated successfully, but these errors were encountered: