code: def init_to_value(
      site: Optional[dict] = None,
      values: dict = {},
      *,
      fallback: Optional[Callable] = init_to_uniform,
  ):
      """
      Initialize to the value specified in ``values``. Fallback to ``fallback``
      (defaults to :func:`init_to_uniform`) strategy for sites not appearing in
      ``values``.
  
      :param dict values: dictionary of initial values keyed by site name.
      :param callable fallback: Fallback init strategy, for sites not specified
          in ``values``.
      :raises ValueError: If ``fallback=None`` and no value for a site is given
          in ``values``.
      """
      if site is None:
          return functools.partial(
              init_to_value, values=values, fallback=fallback
          )
  
      if site["name"] in values:
          return values[site["name"]]
      if fallback is not None:
          return fallback(site)
      raise ValueError(
          f"No init strategy specified for site {repr(site['name'])}"
      )
  
imports: import functools
  from typing import Callable, Optional
  import torch
  from torch.distributions import transform_to
  from pyro.distributions.torch import Independent
  from pyro.distributions.torch_distribution import MaskedDistribution
  from pyro.infer.util import is_validation_enabled
  from pyro.poutine.messenger import Messenger
  from pyro.util import torch_isnan
  from .utils import helpful_support_errors
label_desc: Use image node_id 7 for calling a global function with example usage: init_to_value(site, values) and returns: functools, values, fallback