Update goai_helpers/goai_traduction.py
Browse files
goai_helpers/goai_traduction.py
CHANGED
@@ -51,7 +51,7 @@ def goai_traduction(text, src_lang, tgt_lang):
|
|
51 |
print(f"Token ID de la langue cible ({tgt_lang}): {tgt_lang_id}")
|
52 |
bad_words_ids = [[tokenizer.eos_token_id]]
|
53 |
|
54 |
-
for length_penalty in [1.0, 1.5, 2.0]:
|
55 |
for num_beams in [5, 10]:
|
56 |
print(f"\nTest avec length_penalty={length_penalty}, num_beams={num_beams}")
|
57 |
|
|
|
51 |
print(f"Token ID de la langue cible ({tgt_lang}): {tgt_lang_id}")
|
52 |
bad_words_ids = [[tokenizer.eos_token_id]]
|
53 |
|
54 |
+
for length_penalty in [1.0, 1.5, 2.0, 2.5, 3]:
|
55 |
for num_beams in [5, 10]:
|
56 |
print(f"\nTest avec length_penalty={length_penalty}, num_beams={num_beams}")
|
57 |
|