code: def main():
      args = parse_args()
  
      cfg = Config.fromfile(args.config)
  
      # replace the ${key} with the value of cfg.key
      cfg = replace_cfg_vals(cfg)
  
      # update data root according to MMDET_DATASETS
      update_data_root(cfg)
  
      if args.cfg_options is not None:
          cfg.merge_from_dict(args.cfg_options)
      print(f"Config:\n{cfg.pretty_text}")
  
      if args.save_path is not None:
          save_path = args.save_path
  
          suffix = os.path.splitext(save_path)[-1]
          assert suffix in [".py", ".json", ".yml"]
  
          if not os.path.exists(os.path.split(save_path)[0]):
              os.makedirs(os.path.split(save_path)[0])
          cfg.dump(save_path)
          print(f"Config saving at {save_path}")
  
imports: import argparse
  import os
  from mmengine import Config, DictAction
  from mmdet.utils import replace_cfg_vals, update_data_root
label_desc: Use image node_id 2 for calling a global function with example usage: main() without return types