mirror of
https://github.com/huggingface/transformers.git
synced 2025-07-31 02:02:21 +06:00
Replace // operator with / operator + long() (#13013)
This commit is contained in:
parent
a6d62aaba0
commit
33929448a1
@ -1835,7 +1835,7 @@ class GenerationMixin:
|
||||
next_token_scores, 2 * num_beams, dim=1, largest=True, sorted=True
|
||||
)
|
||||
|
||||
next_indices = next_tokens // vocab_size
|
||||
next_indices = (next_tokens / vocab_size).long()
|
||||
next_tokens = next_tokens % vocab_size
|
||||
|
||||
# stateless
|
||||
|
Loading…
Reference in New Issue
Block a user