-
Notifications
You must be signed in to change notification settings - Fork 16
Feature/to_xarray #23
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
Feature/to_xarray #23
Conversation
Allows reuse of functionality to (partially) convert IDSs to xarray Datasets.
Reuses most of the tensorization and metadata logic from the netCDF export.
olivhoenen
left a comment
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.
Works well!
But a minor improvement of the docstring would help the users IMO.
| In this lesson you will create a ``DataArray`` manually. In a future version of | ||
| IMAS-Python we plan to include functionality that will automatically do this for you. | ||
| That should further simplify working with data inside IDSs. | ||
| This lesson was written before :py:func:`imas.util.to_xarray` was |
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.
Is there still value in keeping this lesson if it's completely superceded by the new capabilities introduced by this PR?
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.
Some of the examples can still be useful for people, so I would not remove it: there's some practical use cases for accessing IDS metadata, and some examples for working with IMAS data in Xarray Datasets.
This Pull Request adds the functionality to directly convert (part of) an IDS to an Xarray
Dataset:imas.util.to_xarray.