code: def __dtw_backtracking(
      steps: np.ndarray,
      step_sizes_sigma: np.ndarray,
      subseq: bool,
      start: Optional[int] = None,
  ) -> List[Tuple[int, int]]:  # pragma: no cover
      """Backtrack optimal warping path.
  
      Uses the saved step sizes from the cost accumulation
      step to backtrack the index pairs for an optimal
      warping path.
  
      Parameters
      ----------
      steps : np.ndarray [shape=(N, M)]
          Step matrix, containing the indices of the used steps from the cost
          accumulation step.
      step_sizes_sigma : np.ndarray [shape=[n, 2]]
          Specifies allowed step sizes as used by the dtw.
      subseq : bool
          Enable subsequence DTW, e.g., for retrieval tasks.
      start : int
          Start column index for backtraing (only allowed for ``subseq=True``)
  
      Returns
      -------
      wp : list [shape=(N,)]
          Warping path with index pairs.
          Each list entry contains an index pair
          (n, m) as a tuple
  
      See Also
      --------
      dtw
      """
      if start is None:
          cur_idx = (steps.shape[0] - 1, steps.shape[1] - 1)
      else:
          cur_idx = (steps.shape[0] - 1, start)
  
      wp = []
      # Set starting point D(N, M) and append it to the path
      wp.append((cur_idx[0], cur_idx[1]))
  
      # Loop backwards.
      # Stop criteria:
      # Setting it to (0, 0) does not work for the subsequence dtw,
      # so we only ask to reach the first row of the matrix.
  
      while (subseq and cur_idx[0] > 0) or (
          not subseq and cur_idx != (0, 0)
      ):
          cur_step_idx = steps[(cur_idx[0], cur_idx[1])]
  
          # save tuple with minimal acc. cost in path
          cur_idx = (
              cur_idx[0] - step_sizes_sigma[cur_step_idx][0],
              cur_idx[1] - step_sizes_sigma[cur_step_idx][1],
          )
  
          # If we run off the side of the cost matrix, break here
          if min(cur_idx) < 0:
              break
  
          # append to warping path
          wp.append((cur_idx[0], cur_idx[1]))
  
      return wp
  
imports: from __future__ import annotations
  import numpy
  from scipy.spatial.distance import cdist
  from numba import jit
  from .util import pad_center, fill_off_diagonal, is_positive_int, tiny, expand_to
  from .util.exceptions import ParameterError
  from .filters import get_window
  from typing import Any, Iterable, List, Optional, Tuple, Union, overload
  from typing_extensions import Literal
  from ._typing import _WindowSpec, _IntLike_co
label_desc: Use image node_id 11 for calling a global function with example usage: __dtw_backtracking(steps, step_sizes_sigma, subseq, start) and returns: wp