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

Better documentation about what a "dictionary" is. #41

Open
inodentry opened this issue Mar 16, 2022 · 1 comment
Open

Better documentation about what a "dictionary" is. #41

inodentry opened this issue Mar 16, 2022 · 1 comment

Comments

@inodentry
Copy link

Looking at the documentation, I see that there are functions for compressing/decompressing "using an external dictionary". It is just a slice of bytes. What should those bytes be? How is it used by the algorithm?

I'm not super well versed in data compression theory and trying to learn...

My guess is that, since the algorithm works by finding back-references to previously-encountered data, the dictionary is just a bunch of bytes that will be treated as if they had come before the start of the actual data to compress? (to give the algorithm something it can refer to while it is still at the start of the compression sequence and hasn't encountered much "real" data yet)

Is my guess/assumption correct?

If so, would be nice if something about this gets added to the documentation...

@PSeitz
Copy link
Owner

PSeitz commented Jul 31, 2022

Sorry for the late reply, but yes that's exactly how the dictionary works.

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