Skip to content

[python] UHI Refactoring: Slicing Logic, Equality Operator, and Negative Indexing #18430

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

Merged
merged 1 commit into from
Apr 16, 2025

Conversation

siliataider
Copy link
Contributor

This Pull request:

This PR introduces some refactoring to the current UHI implementation in ROOT:

  • Updated the slicing logic to include or exclude flow bins as needed: setting with a scalar excludes flow bins; setting with an ndarray may or may not include flow bins depending on the shape of the array.
  • Added an equality operator to validate histogram shape and values (this is particularily needed for testing).
  • Implemented -1 to access the last valid bin in an axis.

Checklist:

  • tested changes locally

@siliataider siliataider self-assigned this Apr 16, 2025
@dpiparo dpiparo merged commit 96292fe into root-project:master Apr 16, 2025
20 of 21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants