code: def merge(src, tgt, hypos, log_probs, path):
      with open(path, "w") as f:
          for s, t, hs, lps in zip(src, tgt, hypos, log_probs):
              f.write(s + "\n")
              f.write(t + "\n")
              f.write("\n")
              for h, lp in zip(hs, lps):
                  f.write("\t%f\t%s\n" % (lp, h.strip()))
              f.write(
                  "------------------------------------------------------\n"
              )
  
file_path: fairseq/examples/translation_moe/score.py
imports: import argparse
  import random
  import sys
  from itertools import chain
  import numpy
  import sacrebleu
  from sacrebleu import corpus_bleu
label_desc: Use image node_id 5 for calling a global function with example usage: merge(src, tgt, hypos, log_probs, path) without return types