code: def main():
      init_args, call_args = parse_args()
      # TODO: Video and Webcam are currently not supported and
      #  may consume too much memory if your input folder has a lot of images.
      #  We will be optimized later.
      inferencer = DetInferencer(**init_args)
  
      chunked_size = call_args.pop("chunked_size")
      inferencer.model.test_cfg.chunked_size = chunked_size
  
      inferencer(**call_args)
  
      if call_args["out_dir"] != "" and not (
          call_args["no_save_vis"] and call_args["no_save_pred"]
      ):
          print_log(
              f'results have been saved at {call_args["out_dir"]}'
          )
  
imports: import ast
  from argparse import ArgumentParser
  from mmengine.logging import print_log
  from mmdet.apis import DetInferencer
  from mmdet.evaluation import get_classes
label_desc: Use image node_id 2 for calling a global function with example usage: main() without return types