-
Notifications
You must be signed in to change notification settings - Fork 18
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
compatibility with xr.DataTree #607
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #607 +/- ##
==========================================
- Coverage 80.40% 80.26% -0.14%
==========================================
Files 49 50 +1
Lines 3082 3121 +39
==========================================
+ Hits 2478 2505 +27
- Misses 604 616 +12
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
The upstream packages seem flaky |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wow thanks, that is a lot of work! I think it's okay not to support xarray-datatree
at all then, since it is not recommended to use it anyway.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks. It was mostly annoying because 98 % I did not understand what is happening 🤷♂️
As long as we need to patch xr.map_over_datasets
we can just as well support datatree (because we need to import from _datatreecompat anyway.
It's annoying that the new version has become so bothersome to work with 😒
|
||
# https://github.com/pydata/xarray/issues/10013 | ||
# tas_anoms = dt - ref.ds | ||
tas_anoms = map_over_datasets(operator.sub, dt, ref.ds) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This takes all the fun out of using xr.DataTree
and cannot be expected from a user. The other 'issues' (missing methods) will probably be fixed in time but this seems to be a design decision. 👎
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes I agree.
I have not yet updated the example scripts and we need to fix the pin for xarray (so it's not only tested in upstream-dev ci). |
CHANGELOG.rst
Adds compatibility with
xr.DataTree
. Works (at least locally) but is not finished and needs some ugly workarounds due to some design decisions in the new version... The new code path is only tested in upstream-dev ci.I am not sure we should support both, datatree and xarray datatree, but this was actually the smaller part of the whole operation.