Skip to content

Commit 0d11810

Browse files
committed
few nits
1 parent 80df231 commit 0d11810

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

evaluation/generation/generate.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ def generate_from_text(model, text, tokenizer, max_length=200, greedy=False, top
2828
)
2929
return {
3030
"inputs": text,
31-
"outputs": tokenizer.decode(greedy_output, skip_special_tokens=True)
31+
"outputs": tokenizer.decode(greedy_output[0], skip_special_tokens=True)
3232
}
3333

3434
def main():
@@ -51,7 +51,7 @@ def main():
5151
while True:
5252
text = ''
5353
while True:
54-
dummy = input('''Enter the paragraph :''')+'\n'
54+
dummy = input('''Enter the paragraph :''')
5555
if dummy=='\n':
5656
break
5757
text += dummy

0 commit comments

Comments
 (0)