Skip to content

Commit

Permalink
Fix typo in comment (#10156)
Browse files Browse the repository at this point in the history
  • Loading branch information
mrm8488 committed Feb 13, 2021
1 parent c969366 commit 698c9e2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/transformers/generation_tf_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -551,7 +551,7 @@ def _generate_no_beam_search(
# unfinished_sents is set to zero if eos in sentence
unfinished_sents -= is_sents_unfinished_and_token_to_add_is_eos

# stop when there is a </s> in each sentence, or if we exceed the maximul length
# stop when there is a </s> in each sentence, or if we exceed the maximum length
if tf.math.reduce_max(unfinished_sents) == 0:
break

Expand Down

0 comments on commit 698c9e2

Please sign in to comment.