-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
.sel method gives error with float32 values #3137
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
|
Sounds like a good idea to me! |
@hdsingh Any interest in sending in a PR? |
As of now I am a bit short on time due to GSOC project. I may not be able to look into this for next 2-3 weeks. |
@dcherian I would like to send a PR and work on this issue if there is no problem in this. |
@HasanAhmadQ7 go for it! |
.sel method gives error when it is used to select float32 values Resolves: pydata#3137
.sel method gives error when it is used to select float32 values Resolves: pydata#3137
.sel method gives error when it is used to select float32 values Resolves: pydata#3137
.sel method gives error when it is used to select float32 values Resolves: pydata#3137
@dcherian I sent a PR last week. Any feedback would be appreciated |
The case also arises if coords are float16. e.g.
|
* BUG fix +test .sel method gives error with float32 values .sel method gives error when it is used to select float32 values Resolves: #3137 * BUG .sel method gives error with float32 values avoid copying indexers for efficiency * BUG: .sel method fails when label is float differnt from coords float type casting at a lower level closer to pandas.Index methods * BUG: .sel method fails when label is float differnt from coords float type casting at a lower level closer to pandas.Index methods * Update xarray/core/indexing.py Co-Authored-By: Stephan Hoyer <[email protected]> * BUG: .sel method gives error when label is float different from coords float type generalizing to coerce numpy arrays in addtion to lists/floats * Black
.sel
method gives error when it is used to selectfloat32
values however it works fine forfloat64
Example:
Error Traceback:
xarray version: 0.12.1
numpy version: 1.16.3
The text was updated successfully, but these errors were encountered: