-
Notifications
You must be signed in to change notification settings - Fork 0
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
Codes beyond 255 #2
Comments
Hi, this a very good question, I'm sorry for the lack of documentation :) The VQ-VAE really uses only 256 codes, but for practical reasons (LM training), the tokenizer has special tokens in addition. This is defined on these lines, there are 8 special tokens and the total vocabulary size is therefore 256+8. Thanks for letting me know about that example in the paper, I believe subtracting 8 from all these codes will make it less confusing for the reader? |
Thanks for the quick response David! I agree a first example without this special case would be good for the readers. Quick clarifications:
|
The special ids are in [0:8] for all factors. Then the actual codes are in [8:264] for all factors. The special symbols are currently defined to always use zero index for the G and B factors, the indices in [1:8] are unused. |
Thank you for releasing code and pretrained tokenizers!
Could you please elaborate why the codes sometimes are greater than 255? The simplest example is directly in the paper: melons → [261, 255, 209] - if the codebook size is 256 then shouldn't 255 be the maximum possible?
We found codes as far as 263 in practice.
The text was updated successfully, but these errors were encountered: