Skip to content

Support DataTree in xarray.concat #9778

Open
@shoyer

Description

@shoyer

What is your issue?

Something like this works, but is a little awkward -- especially the skipping over dimensions that are only defined on some node levels:

def concat(*datasets, dim):
    if not all(dim in ds.dims for ds in datasets):
        return None
    return xarray.concat(*datasets, dim=dim)

xarray.map_over_datasets(concat, tree1, tree)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions