Error while using file

I am working on the Machine Translation task,
The command I gave for translation:
python3 -model -src data/fr_test.txt -fp32 -tgt data/eng_test.txt -output pred.txt -replace_unk -verbose -batch_size 32

It throws an Error:
File “”, line 6, in
File “/home/ravneet/Documents/MT/onmt/bin/”, line 48, in main
File “/home/ravneet/Documents/MT/onmt/bin/”, line 32, in translate
File “/home/ravneet/Documents/MT/onmt/translate/”, line 354, in translate
translations = xlation_builder.from_batch(batch_data)
File “/home/ravneet/Documents/MT/onmt/translate/”, line 100, in from_batch
for n in range(self.n_best)]
File “/home/ravneet/Documents/MT/onmt/translate/”, line 100, in
for n in range(self.n_best)]
File “/home/ravneet/Documents/MT/onmt/translate/”, line 51, in _build_target_tokens
_, max_index = attn[i][:len(src_raw)].max(0)
RuntimeError: cannot perform reduction function max on tensor with no elements because the operation does not have an identity

Duplicate of