code: def GetArgumentParser():
      parser = argparse.ArgumentParser(description="Caffe2 benchmark.")
      parser.add_argument(
          "--batch_size", type=int, default=128, help="The batch size."
      )
      parser.add_argument(
          "--model", type=str, help="The model to benchmark."
      )
      parser.add_argument(
          "--order",
          type=str,
          default="NCHW",
          help="The order to evaluate.",
      )
      parser.add_argument(
          "--cudnn_ws", type=int, help="The cudnn workspace size."
      )
      parser.add_argument(
          "--iterations",
          type=int,
          default=10,
          help="Number of iterations to run the network.",
      )
      parser.add_argument(
          "--warmup_iterations",
          type=int,
          default=10,
          help="Number of warm-up iterations before benchmarking.",
      )
      parser.add_argument(
          "--forward_only",
          action="store_true",
          help="If set, only run the forward pass.",
      )
      parser.add_argument(
          "--layer_wise_benchmark",
          action="store_true",
          help="If True, run the layer-wise benchmark as well.",
      )
      parser.add_argument(
          "--cpu",
          action="store_true",
          help="If True, run testing on CPU instead of GPU.",
      )
      parser.add_argument(
          "--engine",
          type=str,
          default="",
          help="If set, blindly prefer the given engine(s) for every op.",
      )
      parser.add_argument(
          "--dump_model",
          action="store_true",
          help="If True, dump the model prototxts to disk.",
      )
      parser.add_argument("--net_type", type=str, default="dag")
      parser.add_argument("--num_workers", type=int, default=2)
      parser.add_argument(
          "--use-nvtx", default=False, action="store_true"
      )
      parser.add_argument("--htrace_span_log_path", type=str)
      return parser
  
file_path: pytorch/caffe2/python/convnet_benchmarks.py
imports: import argparse
  from caffe2.python import workspace, brew, model_helper
label_desc: Use image node_id 9 for calling a global function with example usage: GetArgumentParser() and returns: parser