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

CDAT Migration TODO: Update logic in get_ref_climo_dataset when ref data not available #823

Open
chengzhuzhang opened this issue Jul 16, 2024 · 0 comments

Comments

@chengzhuzhang
Copy link
Contributor

chengzhuzhang commented Jul 16, 2024

There is one TODO item in most sets that is we'd like to change the logic when ref data is not available when getting the reference climatology dataset for the variable and season.

The current logic:
If the reference climatatology does not exist or could not be found, it
will be considered a model-only run. For this case the test dataset
is returned as a default value and subsequent metrics calculations will
only be performed on the original test dataset.

When refactor, it has been troublesome, e.g. it would be useful to provide explicit error info for trouble shooting, also it can be easily to use test data as ref by mistake based on my recent experience refactoring.

Reference TODO item logged by @tomvothecoder

        # TODO: This logic was carried over from legacy implementation. It
        # can probably be improved on by setting `ds_ref = None` and not
        # performing unnecessary operations on `ds_ref` for model-only runs,
        # since it is the same as `ds_test`. In addition, returning ds_test
        # makes it difficult for debugging.

I think we perhaps should prioritize this item before more sets are being converted.

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

No branches or pull requests

1 participant