code: def hausdorff_error(
      true_change_points: npt.ArrayLike,
      pred_change_points: npt.ArrayLike,
      symmetric: bool = True,
      seed: int = 0,
  ) -> float:
      """Compute the Hausdorff distance between two sets of change points.
  
      .. seealso::
  
         This function wraps :py:func:`scipy.spatial.distance.directed_hausdorff`
  
      Parameters
      ----------
      true_change_points: array_like
          Integer indexes (positions) of true change points
      pred_change_points: array_like
          Integer indexes (positions) of predicted change points
      symmetric: bool
          If `True` symmetric Hausdorff distance will be used
      seed: int, default=0
          Local numpy.random.RandomState seed. Default is 0, a random
          shuffling of u and v that guarantees reproducibility.
  
      Returns
      -------
          Hausdorff error.
      """
      a = np.array(true_change_points).reshape(-1, 1)
      b = np.array(pred_change_points).reshape(-1, 1)
  
      d = directed_hausdorff(a, b)[0]
  
      if symmetric:
          d = max(d, directed_hausdorff(b, a)[0])
  
      return d
  
imports: import numpy
  import numpy.typing
  from scipy.spatial.distance import directed_hausdorff
  from sklearn.utils import check_array
label_desc: Use image node_id 2 for calling a global function with example usage: hausdorff_error(true_change_points, pred_change_points, symmetric, seed) and returns: d