class_docstr: Ingredients are reusable parts of experiments.
  
  Each Ingredient can have its own configuration (visible as an entry in the
  parents configuration), named configurations, captured functions and
  commands.
  
  Ingredients can themselves use ingredients.
docstr: Decorator to add a function to the configuration of the Experiment.
  
  The decorated function is turned into a
  :class:`~sacred.config_scope.ConfigScope` and added to the
  Ingredient/Experiment.
  
  When the experiment is run, this function will also be executed and
  all json-serializable local variables inside it will end up as entries
  in the configuration of the experiment.
docstr_tok: ["Decorator","to","add","a","function","to","the","configuration","of","the","Experiment",".","The","decorated","function","is","turned","into","a",":","class",":","`","~sacred.config_scope.ConfigScope","`","and","added","to","the","Ingredient\/Experiment",".","When","the","experiment","is","run",",","this","function","will","also","be","executed","and","all","json-serializable","local","variables","inside","it","will","end","up","as","entries","in","the","configuration","of","the","experiment","."]
code: def config(self, function):
      """
      Decorator to add a function to the configuration of the Experiment.
  
      The decorated function is turned into a
      :class:`~sacred.config_scope.ConfigScope` and added to the
      Ingredient/Experiment.
  
      When the experiment is run, this function will also be executed and
      all json-serializable local variables inside it will end up as entries
      in the configuration of the experiment.
      """
      self.configurations.append(ConfigScope(function))
      return self.configurations[-1]
  
imports: from typing import Generator, Tuple, Union
  import inspect
  import os.path
  from sacred.utils import PathType
  from typing import Sequence, Optional
  from collections import OrderedDict
  from sacred.config import ConfigDict, ConfigScope, create_captured_function, load_config_file
  from sacred.dependencies import PEP440_VERSION_PATTERN, PackageDependency, Source, gather_sources_and_dependencies
  from sacred.utils import CircularDependencyError, optional_kwargs_decorator, join_paths
label_desc: Use image node_id 6 for calling the Ingredient obj's underlying member method code with example usage: obj.config(function) and returns: self