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

floating point errors when adding parts of entropy #6

Open
micsthepick opened this issue Dec 12, 2024 · 1 comment
Open

floating point errors when adding parts of entropy #6

micsthepick opened this issue Dec 12, 2024 · 1 comment

Comments

@micsthepick
Copy link

because we are doing up to 255 sequential additions, and not in any particular sequence, files with the same real entropy will have slightly different entropies displayed on the program's output. I suppose to fix this issue (if you see it as a proper issue) you could sort the counts by size with an appropriate integer sorting algorithm, or maybe there's a fp-precise compiler option missing?

@micsthepick
Copy link
Author

and I'm happy if you don't care about this issue, it just bugs me seeing stuff that mathematically should be equal but has a few wrong digits :)

@micsthepick micsthepick changed the title floating point errors when adding probabilities floating point errors when adding parts of entropy Dec 12, 2024
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

1 participant