code: def fetch_val_for_key(key, delete_key=False):
      """Return the overriding config value for a key.
      A successful search returns a string value.
      An unsuccessful search raises a KeyError
  
      The (decreasing) priority order is:
      - THEANO_FLAGS
      - ~./theanorc
  
      """
  
      # first try to find it in the FLAGS
      try:
          if delete_key:
              return THEANO_FLAGS_DICT.pop(key)
          return THEANO_FLAGS_DICT[key]
      except KeyError:
          pass
  
      # next try to find it in the config file
  
      # config file keys can be of form option, or section.option
      key_tokens = key.rsplit(".", 1)
      if len(key_tokens) > 2:
          raise KeyError(key)
  
      if len(key_tokens) == 2:
          section, option = key_tokens
      else:
          section, option = "global", key
      try:
          try:
              return theano_cfg.get(section, option)
          except ConfigParser.InterpolationError:
              return theano_raw_cfg.get(section, option)
      except (ConfigParser.NoOptionError, ConfigParser.NoSectionError):
          raise KeyError(key)
  
imports: from __future__ import absolute_import, print_function, division
  import logging
  import os
  import shlex
  import sys
  import warnings
  from functools import wraps
  from six import StringIO, PY3, iteritems
  import theano
  from theano.compat import configparser
  from six import string_types
label_desc: Use image node_id 3 for calling a global function with example usage: fetch_val_for_key(key, delete_key) and returns: THEANO_FLAGS_DICT, THEANO_FLAGS_DICT, theano_cfg, theano_raw_cfg