code: def initialize_logging(experiment, scaffolding, log_level=None):
      if experiment.logger is None:
          root_logger = create_basic_stream_logger()
      else:
          root_logger = experiment.logger
  
      for sc_path, scaffold in scaffolding.items():
          if sc_path:
              scaffold.logger = root_logger.getChild(sc_path)
          else:
              scaffold.logger = root_logger
  
      # set log level
      if log_level is not None:
          try:
              lvl = int(log_level)
          except ValueError:
              lvl = log_level
          root_logger.setLevel(lvl)
  
      return root_logger, root_logger.getChild(experiment.path)
  
imports: import os
  from collections import OrderedDict, defaultdict
  from copy import copy, deepcopy
  from sacred.config import ConfigDict, chain_evaluate_config_scopes, dogmatize, load_config_file, undogmatize
  from sacred.config.config_summary import ConfigSummary
  from sacred.config.custom_containers import make_read_only
  from sacred.host_info import get_host_info
  from sacred.randomness import create_rnd, get_seed
  from sacred.run import Run
  from sacred.utils import convert_to_nested_dict, create_basic_stream_logger, get_by_dotted_path, is_prefix, rel_path, iterate_flattened, set_by_dotted_path, recursive_update, iter_prefixes, join_paths, NamedConfigNotFoundError, ConfigAddedError
  from sacred.settings import SETTINGS
label_desc: Use image node_id 3 for calling a global function with example usage: initialize_logging(experiment, scaffolding, log_level) and returns: root_logger,  root_logger