code: def main():
      parser = get_parser_with_args()
      args = parser.parse_args()
  
      if args.output_file == "":
          print("No action taken. Need output_file to be specified.")
          parser.print_help()
          return
  
      checkpoint_filenames = args.path.split(CHECKPOINT_PATHS_DELIMITER)
  
      beam_search = BeamSearch.build_from_checkpoints(
          checkpoint_filenames=checkpoint_filenames,
          src_dict_filename=args.src_dict,
          dst_dict_filename=args.dst_dict,
          beam_size=args.beam_size,
          word_reward=args.word_reward,
          unk_reward=args.unk_reward,
      )
      beam_search.save_to_pytorch(output_path=args.output_file)
      if args.output_graph_file:
          with open(args.output_graph_file.path, "w") as f:
              f.write(str(beam_search.graph))
  
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 2 for calling a global function with example usage: main() without return types