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

Implement set_value_as_xarray #185

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

Implement set_value_as_xarray #185

wants to merge 1 commit into from

Conversation

Peter9192
Copy link
Collaborator

Made a start, but there's some bumps in the road.

        # TODO: what if data is NaN? Model-specific back-conversion? Don't convert to NaN in getters?
        # TODO: wflow not settable (rank mismatch, should be 2???!)
        # TODO: pcrglob discharge not settable (but works for temperature)
        # TODO: add tests like so:
        """
        name = 'temperature'
        da = model.get_value_as_xarray(name)
        orig = model.get_value(name)
        model.set_value_as_xarray(name, da)
        new = model.get_value(name)
        assert all(orig == new)
        """

Closes #182

@sonarcloud
Copy link

sonarcloud bot commented Jul 16, 2021

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.

Add set_value_as_xarray to models
1 participant