Skip to content
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

Encode Dataset attributes containing Datasets as JSON #10

Merged
merged 3 commits into from
Sep 11, 2024

Conversation

sjperkins
Copy link
Member

@sjperkins sjperkins commented Sep 11, 2024

MSv4 specifies that the main_xds Dataset contains a number of Datasets in the attributes.

For example, antenna_xds and source_xds.

xarray's default xarray.Dataset.to_zarr refuses to write these to disk as they are compound objects.

In this PR, we encode Datasets in attributes as JSON and use xds_{from,to}_zarr and xdt_{from,to}_zarr methods to perform the encoding/decoding of these attributes.


📚 Documentation preview 📚: https://xarray-ms--10.org.readthedocs.build/en/10/

@sjperkins sjperkins merged commit 94b6630 into main Sep 11, 2024
6 checks passed
@sjperkins sjperkins deleted the encode-dataset-attributes-as-json branch September 11, 2024 07:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant