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

Print constants in scientific precision #8506

Merged
merged 1 commit into from
Dec 11, 2024

Conversation

antonysigma
Copy link
Contributor

When the absolute value of a floating point number is smaller than then default IRPrinter precision (6 decimal points), print the value in scientific format.

Use cases:

  • Normalizing the 2D/3D fft image by the total pixel count.
  • Algorithm problem scaling.
  • SI unit conversions, i.e. from nanometer to meter.

When the absolute value of a floating point number is smaller than then
default IRPrinter precision (6 decimal points), print the value in
scientific format.

Use cases:

- Normalizing the 2D/3D fft image by the total pixel count.
- Algorithm problem scaling.
- SI unit conversions, i.e. from nanometer to meter.
@steven-johnson steven-johnson merged commit 65adb9c into halide:main Dec 11, 2024
16 of 19 checks passed
@antonysigma antonysigma deleted the stmt-float-formatting branch December 11, 2024 16:06
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