code: def maybe_create_mean_fn(mean_fn, dtype):
      """Create a default mean function if one is not provided."""
      if mean_fn is not None:
          if not callable(mean_fn):
              raise ValueError("`mean_fn` must be a Python callable")
          return mean_fn
  
      # Default to a constant zero function, borrowing the dtype from
      # index_points to ensure consistency.
      return lambda _: tf.zeros([1], dtype=dtype)
  
file_path: probability/tensorflow_probability/python/distributions/internal/stochastic_process_util.py
imports: import functools
  import tensorflow.compat.v2
  from tensorflow_probability.python.internal import distribution_util
  from tensorflow_probability.python.internal import dtype_util
  from tensorflow_probability.python.internal import prefer_static
  from tensorflow_probability.python.internal import tensorshape_util
  from tensorflow_probability.python.math.psd_kernels.internal import util
  from tensorflow.python.util import nest
label_desc: Use image node_id 9 for calling a global function with example usage: maybe_create_mean_fn(mean_fn, dtype) and returns: function, mean_fn