code: def assert_and_infer_cfg(cache_urls=True, make_immutable=True):
      """Call this function in your script after you have finished setting all cfg
      values that are necessary (e.g., merging a config from a file, merging
      command line config options, etc.). By default, this function will also
      mark the global cfg as immutable to prevent changing the global cfg settings
      during script execution (which can lead to hard to debug errors or code
      that's harder to understand than is necessary).
      """
      if __C.MODEL.RPN_ONLY or __C.MODEL.FASTER_RCNN:
          __C.RPN.RPN_ON = True
      if __C.RPN.RPN_ON or __C.RETINANET.RETINANET_ON:
          __C.TEST.PRECOMPUTED_PROPOSALS = False
      if cache_urls:
          cache_cfg_urls()
      if make_immutable:
          cfg.immutable(True)
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  from __future__ import unicode_literals
  from ast import literal_eval
  from future.utils import iteritems
  from past.builtins import basestring
  import copy
  import logging
  import numpy
  import os
  import os.path
  import yaml
  from detectron.utils.collections import AttrDict
  from detectron.utils.io import cache_url
label_desc: Use image node_id 1 for calling a global function with example usage: assert_and_infer_cfg(cache_urls, make_immutable) without return types