Data container reductions - #1515
Merged
Merged
Conversation
Member
|
I had a chat with @paskino about this. We decided that:
|
hrobarts
marked this pull request as ready for review
October 6, 2023 15:49
Contributor
Author
paskino
requested changes
Oct 17, 2023
paskino
left a comment
Contributor
There was a problem hiding this comment.
Looks almost good to me: small changes and additions to docstrings
Co-authored-by: Edoardo Pasca <[email protected]> Signed-off-by: hrobarts <[email protected]>
…ing/CIL into DataContainer_reductions
gfardell
requested changes
Oct 18, 2023
gfardell
left a comment
Member
There was a problem hiding this comment.
It's looking very neat now! A few suggestions for unit tests and some areas you can reuse code, but we can discuss in person too.
gfardell
approved these changes
Nov 6, 2023
gfardell
reviewed
Nov 6, 2023
gfardell
reviewed
Nov 6, 2023
gfardell
reviewed
Nov 6, 2023
Co-authored-by: Gemma Fardell <[email protected]> Signed-off-by: Hannah Robarts <[email protected]>
Member
Contributor
Author
paskino
requested changes
Nov 6, 2023
paskino
left a comment
Contributor
There was a problem hiding this comment.
See suggestion, otherwise it looks good to me.
Co-authored-by: Edoardo Pasca <[email protected]> Signed-off-by: Hannah Robarts <[email protected]>
paskino
approved these changes
Nov 8, 2023
Signed-off-by: Hannah Robarts <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Describe your changes
Updated reduction functions on the DataContainer class to accept a direction argument as a string or tuple of strings which match values in dimension_labels
Added a function _directional_reduction_unary() which:
The _directional_rediction_unary function is called by DataContainer.mean(), DataContainer.min(), DataContainer.max() and DataContainer.sum()
Describe any testing you have performed
Added tests passing different direction arguments to DataContainer.mean(), DataContainer.min(), DataContainer.max() and DataContainer.sum()
Link relevant issues
#1507
Checklist when you are ready to request a review
Contribution Notes
Please read and adhere to the developer guide and local patterns and conventions.