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

SPERR 0.5 occasionally violates error tolerance #181

Closed
lindstro opened this issue Dec 14, 2022 · 2 comments
Closed

SPERR 0.5 occasionally violates error tolerance #181

lindstro opened this issue Dec 14, 2022 · 2 comments

Comments

@lindstro
Copy link

lindstro commented Dec 14, 2022

Describe the bug
In rare cases, SPERR violates the error tolerance set by --pwe.

To Reproduce
Steps to reproduce the behavior:

  1. Download the Nyx dark matter density field from SDRBench.
  2. Compress field with compressor_3d --dims 512 512 512 --pwe 0x1p-44 -o dmd.sperr dark_matter_density.f32.
  3. Decompress field with decompressor_3d -o dmd.bof dmd.sperr.

Expected and actual behavior
All values should differ by no more than 2-44. The observed maximum absolute error is 7.616e-14, which exceeds the error tolerance of 2-44 ≈ 5.684e-14.

Environment (please complete the following information):

  • OS: macOS 11.7.1
  • Compiler: AppleClang 13.0.0.13000029
  • SPERR Version:
SPERR version: 0.5
Based on code Branch: main
Based on code SHA1  : 48880dd-dirty
shaomeng added a commit that referenced this issue Dec 15, 2022
* header keeps the number of useful bits rather than bytes. Fix issue #181

* compressor_3d releases compressor resources before doing decompression

* bump version to 0.5.2

Co-authored-by: Samuel Li <Sam@Navada>
@shaomeng
Copy link
Contributor

Hi Peter, I've located this bug, and believe that it's fixed now (tag v0.5.2). Could you verify?
(I borrowed a header definition from my integer-based implementation, and that's a better definition ;) )

@lindstro
Copy link
Author

Thanks, Sam. Yes, that fixes this issue for me.

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

No branches or pull requests

2 participants