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

Nonreducing #1993

Open
wants to merge 12 commits into
base: master
Choose a base branch
from
Open

Nonreducing #1993

wants to merge 12 commits into from

Conversation

andrewgsavage
Copy link
Collaborator

  • Closes # (insert issue number)
  • Executed pre-commit run --all-files with no errors
  • The change is fully covered by automated unit tests
  • Documented in docs/ as appropriate
  • Added an entry to the CHANGES file

Copy link

codspeed-hq bot commented May 22, 2024

CodSpeed Performance Report

Merging #1993 will not alter performance

Comparing andrewgsavage:nonreducing (3e5bfba) with master (62046f0)

Summary

✅ 437 untouched benchmarks

@andrewgsavage
Copy link
Collaborator Author

I think support for this can be added in a few functions, eg

mm_per_mm = ureg.NonReducingUnitsContainer([ureg.mm, 1/ureg.mm])
Quantity(1, mm_per_mm)
Quantity(1,"").to(mm_per_mm)

I am unsure on using this in more places as it would change behaviour where units currently cancel out.

@andrewgsavage
Copy link
Collaborator Author

I am unsure on using this in more places as it would change behaviour where units currently cancel out.

Could set behaviour with a registry setting like auto_reduce_dimensions

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.

1 participant