code: def add_split_rng_error(f):
      """Adds a nice error message when split_rng is missing."""
  
      @functools.wraps(f)
      def wrapper(*args, **kwargs):
          if (
              "split_rng" not in kwargs
              and not wrapper.require_split_rng
          ):
              kwargs["split_rng"] = False
  
          if "split_rng" not in kwargs:
              try:
                  return f(*args, **kwargs)
              except TypeError as e:
                  raise TypeError(
                      "Haiku now requires the split_rng argument to be "
                      "passed to hk.vmap. If you have code using the old "
                      "API which you cannot change, you can opt-out of this "
                      "requirement by using "
                      "`hk.vmap.require_split_rng = False`."
                  ) from e
  
          return f(*args, **kwargs)
  
      wrapper.require_split_rng = True
      return wrapper
  
imports: import collections
  import collections.abc
  from collections.abc import Mapping, MutableMapping
  import functools
  import inspect
  from typing import Any, Callable, Optional, TypeVar
  from haiku._src import base
  import jax
  import jax.numpy
label_desc: Use image node_id 24 for calling a global function with example usage: add_split_rng_error(f) and returns: wrapper, f, f