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

Add diagnostics.health_checks #238

Merged
merged 21 commits into from
Aug 17, 2023
Merged

Add diagnostics.health_checks #238

merged 21 commits into from
Aug 17, 2023

Conversation

RondeauG
Copy link
Collaborator

@RondeauG RondeauG commented Aug 16, 2023

Pull Request Checklist:

  • This PR addresses an already opened issue (for bug fixes / features)
    • No.
  • (If applicable) Documentation has been added / updated (for bug fixes / features).
  • (If applicable) Tests have been added.
  • This PR does not seem to break the templates.
  • HISTORY.rst has been updated (with summary of main changes).
    • Link to issue (:issue:number) and pull request (:pull:number) has been added.

What kind of change does this PR introduce?

  • New function diagnostics.health_checks that performs a bunch of checkups on a dataset.
    • You have full control on which checkup should return a warning and which should raise and Exception.
    • By default, the function returns nothing. However, you can set return_flags=True to retrieve the dataset created by xclim's data_flags (as long as the function does not raise an Exception elsewhere).
  • Added 2D lon-lat and grid_mapping to datablock_3d when the grid is not regular.

Does this PR introduce a breaking change?

  • Removed diagnostics.fix_unphysical_values, although I seriously doubt that anyone was using it.

Other information:

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

Copy link
Collaborator

@aulemahal aulemahal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! Très complète et utile fonction.

Plusieurs commentaires, mais ce sont surtout des suggestions pour simplifier.

@RondeauG
Copy link
Collaborator Author

I should have answered all comments. Did you want to check again before we merge?

@RondeauG RondeauG merged commit 3bbd47b into main Aug 17, 2023
@RondeauG RondeauG deleted the datachecks branch August 17, 2023 20:40
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.

3 participants