code: def __init__(self):
      parser = argparse.ArgumentParser()
  
      parser.add_argument(
          "-p",
          "--preprocess",
          type=_text_type,
          help="Model Preprocess Type",
      )
  
      parser.add_argument(
          "-n",
          type=_text_type,
          default="kit_imagenet",
          help="Network structure file name.",
      )
  
      parser.add_argument(
          "-s",
          type=_text_type,
          help="Source Framework Type",
          choices=self.truth.keys(),
      )
  
      parser.add_argument(
          "-w",
          type=_text_type,
          required=True,
          help="Network weights file name",
      )
  
      parser.add_argument(
          "--image",
          "-i",
          type=_text_type,
          help="Test image path.",
          default="mmdnn/conversion/examples/data/seagull.jpg",
      )
  
      parser.add_argument(
          "-l",
          "--label",
          type=_text_type,
          default="mmdnn/conversion/examples/data/imagenet_1000.txt",
          help="Path of label.",
      )
  
      parser.add_argument(
          "--dump",
          type=_text_type,
          default=None,
          help="Target model path.",
      )
  
      parser.add_argument(
          "--detect",
          type=_text_type,
          default=None,
          help="Model detection result path.",
      )
  
      # tensorflow dump tag
      parser.add_argument(
          "--dump_tag",
          type=_text_type,
          default=None,
          help="Tensorflow model dump type",
          choices=["SERVING", "TRAINING"],
      )
  
      self.args = parser.parse_args()
      import imp
  
      self.MainModel = imp.load_source("MainModel", self.args.n)
  
file_path: MMdnn/mmdnn/conversion/examples/imagenet_test.py
imports: from __future__ import absolute_import
  import argparse
  import numpy
  from six import text_type
  from PIL import Image
label_desc: Use image node_id 1 to create a new TestKit object from inherited base classes: object with example: obj = TestKit()