Skip to content

Reducing over a subset of axes#248

Merged
valeriupredoi merged 12 commits intopyfivefrom
axis-subset-2
Mar 13, 2025
Merged

Reducing over a subset of axes#248
valeriupredoi merged 12 commits intopyfivefrom
axis-subset-2

Conversation

@davidhassell
Copy link
Collaborator

Description

Implement reductions over a subset of axes, i.e. emulating numpy's the axis keyword argument to is reduction functions (e.g. np.sum(x, axis=(0, 2)))

Closes #247

Before you get started

Checklist

  • This pull request has a descriptive title and labels
  • This pull request has a minimal description (most was discussed in the issue, but a two-liner description is still desirable)
  • Unit tests have been added (if codecov test fails)
  • Any changed dependencies have been added or removed correctly (if need be)
  • All tests pass

@valeriupredoi
Copy link
Collaborator

@davidhassell - looks great, you mind fixing the tests pls (axis is confused with storage_type since we need to correctly arg that in the test call), or I can do it? 🍺

Copy link
Collaborator

@valeriupredoi valeriupredoi left a comment

Choose a reason for hiding this comment

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

OK I fixed the unit tests, could you please add tests/test_data/test1.nc since it's missing 🍺

Copy link
Collaborator

@valeriupredoi valeriupredoi left a comment

Choose a reason for hiding this comment

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

many thanks @davidhassell - this is going in now 🍺

@valeriupredoi valeriupredoi merged commit 5d26a97 into pyfive Mar 13, 2025
5 checks passed
@valeriupredoi valeriupredoi deleted the axis-subset-2 branch March 13, 2025 16:25
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.

2 participants