mirror of
https://github.com/karpathy/nanochat.git
synced 2025-12-06 04:12:13 +00:00
add back comment
This commit is contained in:
parent
1d719a7c94
commit
2f4f20862d
|
|
@ -77,7 +77,7 @@ vocab_size = tokenizer.get_vocab_size()
|
|||
special_set = set(tokenizer.get_special_tokens())
|
||||
token_strings = [tokenizer.decode([token_id]) for token_id in range(vocab_size)]
|
||||
token_bytes = []
|
||||
for token_str in token_strings:
|
||||
for token_str in token_strings: # the Python string representation of this token
|
||||
if token_str in special_set:
|
||||
token_bytes.append(0) # special characters are not counted
|
||||
else:
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user