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
Finally we could just not support this at all, in which case the only way for users to concatenate contents of datatrees node-wise is via something like
This was actually already something we partly discussed in the datatree design meeting (#8747), but I forgot what the conclusion was (do you remember @keewis@flamingbear@owenlittlejohns?).
Is your feature request related to a problem?
Sometimes you might want to map one of the xarray top-level functions (especially
xr.concat
orxr.merge
) overDataTree
objects.Whilst this could potentially be done manually, we could also imagine generalizing top-level functions to handle this out of the box.
Describe the solution you'd like
For this to work
returning a single
DataTree
, withxr.concat
applied to sets of datasets in corresponding nodes.Describe alternatives you've considered
We could instead not change xarray's top-level functions but still ensure that its relatively easy to achieve using
map_over_subtree
, i.e.This would still require generalizing
map_over_subtree
to understand iterables ofDataTree
objects though (see zarr-developers/VirtualiZarr#84 (comment)).Finally we could just not support this at all, in which case the only way for users to concatenate contents of datatrees node-wise is via something like
but called for every node in the tree.
Additional context
See zarr-developers/VirtualiZarr#84 (comment) for an example of wanting to do this in
VirtualiZarr
(cc @jonas-spaeth).This was actually already something we partly discussed in the datatree design meeting (#8747), but I forgot what the conclusion was (do you remember @keewis @flamingbear @owenlittlejohns?).
Checklist
apply_ufunc
- Support DataTree in apply_ufunc #9789concat
- Support DataTree in xarray.concat #9778merge
- Support DataTree in xarray.merge #9790align
- Support DataTree in xarray.align #9791broadcast
combine_by_coords
combine_nested
map_blocks
The text was updated successfully, but these errors were encountered: