code: def _get_baseline_options(site):
      """
      Extracts baseline options from ``site["infer"]["baseline"]``.
      """
      # XXX default for baseline_beta currently set here
      options_dict = site["infer"].get("baseline", {}).copy()
      options_tuple = (
          options_dict.pop("nn_baseline", None),
          options_dict.pop("nn_baseline_input", None),
          options_dict.pop("use_decaying_avg_baseline", False),
          options_dict.pop("baseline_beta", 0.90),
          options_dict.pop("baseline_value", None),
      )
      if options_dict:
          raise ValueError(
              "Unrecognized baseline options: {}".format(
                  options_dict.keys()
              )
          )
      return options_tuple
  
imports: import weakref
  from collections import defaultdict
  from operator import itemgetter
  import torch
  import pyro
  import pyro.ops.jit
  from pyro.distributions.util import detach, is_identically_zero
  from pyro.infer import ELBO
  from pyro.infer.enum import get_importance_trace
  from pyro.infer.util import MultiFrameTensor, get_plate_stacks, is_validation_enabled, torch_backward, torch_item
  from pyro.ops.provenance import detach_provenance, get_provenance, track_provenance
  from pyro.poutine.messenger import Messenger
  from pyro.poutine.subsample_messenger import _Subsample
  from pyro.util import check_if_enumerated, warn_if_nan
label_desc: Use image node_id 1 for calling a global function with example usage: _get_baseline_options(site) and returns: options_tuple