code: def get_parser_with_args():
      parser = argparse.ArgumentParser(
          description=("Export PyTorch-trained FBTranslate models")
      )
      parser.add_argument(
          "--path",
          "--checkpoint",
          metavar="FILE",
          help="path(s) to model file(s), colon separated",
      )
      parser.add_argument(
          "--output-file",
          default="",
          help="File name to which to save beam search network",
      )
      parser.add_argument(
          "--output-graph-file",
          default="",
          help="File name to which to save the beam search graph for debugging",
      )
      parser.add_argument(
          "--source-vocab-file",
          required=True,
          help="File encoding PyTorch dictionary for source language",
      )
      parser.add_argument(
          "--target-vocab-file",
          required=True,
          help="File encoding PyTorch dictionary for source language",
      )
      parser.add_argument(
          "--beam-size",
          type=int,
          default=6,
          help="Number of top candidates returned by each decoder step",
      )
      parser.add_argument(
          "--word-reward",
          type=float,
          default=0.0,
          help="Value to add for each word (besides EOS)",
      )
      parser.add_argument(
          "--unk-reward",
          type=float,
          default=0.0,
          help="Value to add for each word UNK token",
      )
  
      return parser
  
imports: import argparse
  from pytorch_translate import rnn
  from pytorch_translate.constants import CHECKPOINT_PATHS_DELIMITER
  from pytorch_translate.ensemble_export import BeamSearch
label_desc: Use image node_id 1 for calling a global function with example usage: get_parser_with_args() and returns: parser