def decode(toks, escape_unk=False):
    s = self.tgt_dict.string(toks.int().cpu(), self.args.eval_bleu_remove_bpe, unk_string=('UNKNOWNTOKENINREF' if escape_unk else 'UNKNOWNTOKENINHYP'))
    if self.tokenizer:
        s = self.tokenizer.decode(s)
    return s
def decode(toks, escape_unk=False):
    s = self.tgt_dict.string(toks.int().cpu(), self.args.eval_bleu_remove_bpe, unk_string=('UNKNOWNTOKENINREF' if escape_unk else 'UNKNOWNTOKENINHYP'))
    if self.tokenizer:
        s = self.tokenizer.decode(s)
    return s