add draft version of propsoed changes for ROGUE score

This commit is contained in:
patrickvonplaten authored and Patrick von Platen committed 2020-03-11 11:06:56 +01:00
1 parent a5751f7578
commit 41b437ea3a
2 files changed
+14 -9

No files matched your search

+5 -1
View File
@@ -214,6 +214,9 @@ class BartHeadTests(unittest.TestCase):
decoder_ffn_dim=32,
max_position_embeddings=48,
output_past=output_past,
eos_token_id=2,
pad_token_id=1,
bos_token_id=0,
)
return config, input_ids, batch_size
@@ -468,7 +471,8 @@ class BartModelIntegrationTest(unittest.TestCase):
attention_mask=dct["attention_mask"].to(torch_device),
num_beams=4,
length_penalty=2.0,
max_length=max_length + 2,
# max_length=max_length + 2,
max_length=max_length + 1,
min_length=min_length + 1,
no_repeat_ngram_size=3,
do_sample=False,