[v3] NoBadWordsLogitsProcessor
breaks when the size of bad_word_ids
exceeds the size of the input ids
#910
Labels
bug
Something isn't working
System Info
v3
Environment/Platform
Description
this block breaks for me with
mozilla/distilvit
where we have a long list of bad wordswith:
my input_ids has just one entry when I use the regular pipeline function with dtype=q4 and devide=wasm
The code is a bit confusing because
i
is reused in both the inner and outer loop.I fixed it by changing the inner loop with :
I am not sure if that is the correct fix. Happy to do a PR
Reproduction
.
The text was updated successfully, but these errors were encountered: