code: def get_parser():
      parser = argparse.ArgumentParser(
          description="Detectron2 demo for builtin models"
      )
      parser.add_argument(
          "--config-file",
          default="configs/quick_schedules/mask_rcnn_R_50_FPN_inference_acc_test.yaml",
          metavar="FILE",
          help="path to config file",
      )
      parser.add_argument(
          "--webcam",
          action="store_true",
          help="Take inputs from webcam.",
      )
      parser.add_argument("--video-input", help="Path to video file.")
      parser.add_argument(
          "--input",
          nargs="+",
          help="A list of space separated input images; "
          "or a single glob pattern such as 'directory/*.jpg'",
      )
      parser.add_argument(
          "--output",
          help="A file or directory to save output visualizations. "
          "If not given, will show output in an OpenCV window.",
      )
  
      parser.add_argument(
          "--confidence-threshold",
          type=float,
          default=0.5,
          help="Minimum score for instance predictions to be shown",
      )
      parser.add_argument(
          "--opts",
          help="Modify config options using the command-line 'KEY VALUE' pairs",
          default=[],
          nargs=argparse.REMAINDER,
      )
      return parser
  
file_path: guildai/examples/detectron2/demo.py
imports: import argparse
  import glob
  import multiprocessing
  import os
  import time
  import cv2
  import tqdm
  from detectron2.config import get_cfg
  from detectron2.data.detection_utils import read_image
  from detectron2.utils.logger import setup_logger
  from predictor import VisualizationDemo
label_desc: Use image node_id 2 for calling a global function with example usage: get_parser() and returns: parser