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

More flexible sampled_indicators #220

Merged
merged 7 commits into from
Nov 5, 2024
Merged

More flexible sampled_indicators #220

merged 7 commits into from
Nov 5, 2024

Conversation

RondeauG
Copy link
Collaborator

@RondeauG RondeauG commented Oct 28, 2024

Pull Request Checklist:

  • This PR addresses an already opened issue (for bug fixes / features)
    • This PR fixes #xyz
  • (If applicable) Documentation has been added / updated (for bug fixes / features).
  • (If applicable) Tests have been added.
  • CHANGELOG.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?

  • Multiple additions to sampled_indicators to make it more flexible:
    • delta_kind can now be a dictionary and change per variable. It can also be None, in which case it will search for a delta_kind attribute in the variables (which is automatically added by xh.cc.compute_deltas.
    • Weights can be given along a time or horizon dimension. These weights will be broadcast, but the dimension will not be stacked.
    • Added a bunch of missing attributes.

Does this PR introduce a breaking change?

  • delta_type was renamed delta_kind to be more consistent with xh.cc.compute_deltas. It is now also no longer a positional argument since it can be None.

Other information:

Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@github-actions github-actions bot added notebooks Run tests against notebooks docs labels Oct 28, 2024
Copy link
Collaborator

@essicolo essicolo left a comment

Choose a reason for hiding this comment

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

J'ai seulement trouvé une petite coquille dans le notebook, où delta_type n'a pas été modifié dans le markdown.

@github-actions github-actions bot added the approved Approved for additional tests label Nov 5, 2024
@RondeauG RondeauG merged commit 113a0ab into main Nov 5, 2024
17 checks passed
@RondeauG RondeauG deleted the sampled_better_deltas branch November 5, 2024 21:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Approved for additional tests docs notebooks Run tests against notebooks
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants