-
Notifications
You must be signed in to change notification settings - Fork 41
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
Data container reductions #1515
Conversation
I had a chat with @paskino about this. We decided that:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks almost good to me: small changes and additions to docstrings
Co-authored-by: Edoardo Pasca <edo.paskino@gmail.com> Signed-off-by: hrobarts <77114597+hrobarts@users.noreply.github.com>
…ing/CIL into DataContainer_reductions
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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.
Co-authored-by: Gemma Fardell <47746591+gfardell@users.noreply.github.com> Signed-off-by: Hannah Robarts <77114597+hrobarts@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See suggestion, otherwise it looks good to me.
Co-authored-by: Edoardo Pasca <edo.paskino@gmail.com> Signed-off-by: Hannah Robarts <77114597+hrobarts@users.noreply.github.com>
Signed-off-by: Hannah Robarts <77114597+hrobarts@users.noreply.github.com>
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.