class_docstr: Class for affine connections.
  
  Parameters
  ----------
  space : Manifold object
      M in the tuple (M, g).
class_docstr_tok: ["Class","for","affine","connections",".","Parameters","--","--","--","--","--","space",":","Manifold","object","M","in","the","tuple","(","M",",","g",")","."]
docstr: Approximate parallel transport using the pole ladder scheme.
  
  Approximate Parallel transport using either the pole ladder or the
  Schild's ladder scheme [LP2013b]_. Pole ladder is exact in symmetric
  spaces and of order two in general while Schild's ladder is a first
  order approximation [GP2020]_. Both schemes are available on any affine
  connection manifolds whose exponential and logarithm maps are
  implemented. `tangent_vec` is transported along the geodesic starting
  at the base_point with initial tangent vector `direction`.
  
  Parameters
  ----------
  tangent_vec : array-like, shape=[..., dim]
      Tangent vector at base point to transport.
  direction : array-like, shape=[..., dim]
      Tangent vector at base point, initial speed of the geodesic along
      which to transport.
  base_point : array-like, shape=[..., dim]
      Point on the manifold, initial position of the geodesic along
      which to transport.
  n_rungs : int
      Number of steps of the ladder.
      Optional, default: 1.
  scheme : str, {'pole', 'schild'}
      The scheme to use for the construction of the ladder at each step.
      Optional, default: 'pole'.
  alpha : float
      Exponent for the scaling of the vector to transport. Must be
      greater or equal to 1, 2 is optimal. See [GP2020]_.
      Optional, default: 2
  
  Returns
  -------
  ladder : dict of array-like and callable with following keys
      transported_tangent_vector : array-like, shape=[..., dim]
          Approximation of the parallel transport of tangent vector a.
      trajectory : list of list of callable, len=n_steps
          List of lists containing the geodesics of the
          construction, only if `return_geodesics=True` in the step
          function. The geodesics are methods of the class connection.
  
  References
  ----------
  .. [LP2013b] Lorenzi, Marco, and Xavier Pennec. “Efficient Parallel
      Transport of Deformations in Time Series of Images: From Schild to
      Pole Ladder.” Journal of Mathematical Imaging and Vision 50, no. 1
      (September 1, 2014): 5–17.
      https://doi.org/10.1007/s10851-013-0470-3.
  
  .. [GP2020] Guigui, Nicolas, and Xavier Pennec. “Numerical Accuracy
      of Ladder Schemes for Parallel Transport on Manifolds.”
      Foundations of Computational Mathematics, June 18, 2021.
      https://doi.org/10.1007/s10208-021-09515-x.
docstr_tok: ["Approximate","parallel","transport","using","the","pole","ladder","scheme",".","Approximate","Parallel","transport","using","either","the","pole","ladder","or","the","Schild","'s","ladder","scheme","[","LP2013b","]","_",".","Pole","ladder","is","exact","in","symmetric","spaces","and","of","order","two","in","general","while","Schild","'s","ladder","is","a","first","order","approximation","[","GP2020","]","_",".","Both","schemes","are","available","on","any","affine","connection","manifolds","whose","exponential","and","logarithm","maps","are","implemented",".","`","tangent_vec","`","is","transported","along","the","geodesic","starting","at","the","base_point","with","initial","tangent","vector","`","direction","`",".","Parameters","--","--","--","--","--","tangent_vec",":","array-like",",","shape=","[","...",",","dim","]","Tangent","vector","at","base","point","to","transport",".","direction",":","array-like",",","shape=","[","...",",","dim","]","Tangent","vector","at","base","point",",","initial","speed","of","the","geodesic","along","which","to","transport",".","base_point",":","array-like",",","shape=","[","...",",","dim","]","Point","on","the","manifold",",","initial","position","of","the","geodesic","along","which","to","transport",".","n_rungs",":","int","Number","of","steps","of","the","ladder",".","Optional",",","default",":","1.","scheme",":","str",",","{","'pole","'",",","'schild","'","}","The","scheme","to","use","for","the","construction","of","the","ladder","at","each","step",".","Optional",",","default",":","'pole","'",".","alpha",":","float","Exponent","for","the","scaling","of","the","vector","to","transport",".","Must","be","greater","or","equal","to","1",",","2","is","optimal",".","See","[","GP2020","]","_",".","Optional",",","default",":","2","Returns","--","--","--","-","ladder",":","dict","of","array-like","and","callable","with","following","keys","transported_tangent_vector",":","array-like",",","shape=","[","...",",","dim","]","Approximation","of","the","parallel","transport","of","tangent","vector","a.","trajectory",":","list","of","list","of","callable",",","len=n_steps","List","of","lists","containing","the","geodesics","of","the","construction",",","only","if","`","return_geodesics=True","`","in","the","step","function",".","The","geodesics","are","methods","of","the","class","connection",".","References","--","--","--","--","--","..","[","LP2013b","]","Lorenzi",",","Marco",",","and","Xavier","Pennec",".","\u201c","Efficient","Parallel","Transport","of","Deformations","in","Time","Series","of","Images",":","From","Schild","to","Pole","Ladder.","\u201d","Journal","of","Mathematical","Imaging","and","Vision","50",",","no",".","1","(","September","1",",","2014",")",":","5\u201317",".","https",":","\/\/doi.org\/10.1007\/s10851-013-0470-3",".","..","[","GP2020","]","Guigui",",","Nicolas",",","and","Xavier","Pennec",".","\u201c","Numerical","Accuracy","of","Ladder","Schemes","for","Parallel","Transport","on","Manifolds.","\u201d","Foundations","of","Computational","Mathematics",",","June","18",",","2021.","https",":","\/\/doi.org\/10.1007\/s10208-021-09515-x","."]
code: def ladder_parallel_transport(
      self,
      tangent_vec,
      base_point,
      direction,
      n_rungs=1,
      scheme="pole",
      alpha=1,
      return_geodesics=False,
  ):
      """Approximate parallel transport using the pole ladder scheme.
  
      Approximate Parallel transport using either the pole ladder or the
      Schild's ladder scheme [LP2013b]_. Pole ladder is exact in symmetric
      spaces and of order two in general while Schild's ladder is a first
      order approximation [GP2020]_. Both schemes are available on any affine
      connection manifolds whose exponential and logarithm maps are
      implemented. `tangent_vec` is transported along the geodesic starting
      at the base_point with initial tangent vector `direction`.
  
      Parameters
      ----------
      tangent_vec : array-like, shape=[..., dim]
          Tangent vector at base point to transport.
      direction : array-like, shape=[..., dim]
          Tangent vector at base point, initial speed of the geodesic along
          which to transport.
      base_point : array-like, shape=[..., dim]
          Point on the manifold, initial position of the geodesic along
          which to transport.
      n_rungs : int
          Number of steps of the ladder.
          Optional, default: 1.
      scheme : str, {'pole', 'schild'}
          The scheme to use for the construction of the ladder at each step.
          Optional, default: 'pole'.
      alpha : float
          Exponent for the scaling of the vector to transport. Must be
          greater or equal to 1, 2 is optimal. See [GP2020]_.
          Optional, default: 2
  
      Returns
      -------
      ladder : dict of array-like and callable with following keys
          transported_tangent_vector : array-like, shape=[..., dim]
              Approximation of the parallel transport of tangent vector a.
          trajectory : list of list of callable, len=n_steps
              List of lists containing the geodesics of the
              construction, only if `return_geodesics=True` in the step
              function. The geodesics are methods of the class connection.
  
      References
      ----------
      .. [LP2013b] Lorenzi, Marco, and Xavier Pennec. “Efficient Parallel
          Transport of Deformations in Time Series of Images: From Schild to
          Pole Ladder.” Journal of Mathematical Imaging and Vision 50, no. 1
          (September 1, 2014): 5–17.
          https://doi.org/10.1007/s10851-013-0470-3.
  
      .. [GP2020] Guigui, Nicolas, and Xavier Pennec. “Numerical Accuracy
          of Ladder Schemes for Parallel Transport on Manifolds.”
          Foundations of Computational Mathematics, June 18, 2021.
          https://doi.org/10.1007/s10208-021-09515-x.
      """
      geomstats.errors.check_integer(n_rungs, "n_rungs")
      if alpha < 1:
          raise ValueError("alpha must be greater or equal to one")
      current_point = base_point
      next_tangent_vec = tangent_vec / (n_rungs**alpha)
      methods = {
          "pole": self._pole_ladder_step,
          "schild": self._schild_ladder_step,
      }
      single_step = methods[scheme]
      base_shoot = self.exp(
          base_point=current_point, tangent_vec=next_tangent_vec
      )
      trajectory = []
      for i_point in range(n_rungs):
          frac_tan_vector_b = (i_point + 1) / n_rungs * direction
          next_point = self.exp(
              base_point=base_point, tangent_vec=frac_tan_vector_b
          )
          next_step = single_step(
              base_point=current_point,
              next_point=next_point,
              base_shoot=base_shoot,
              return_geodesics=return_geodesics,
          )
          current_point = next_point
          base_shoot = next_step["end_point"]
          trajectory.append(next_step["geodesics"])
      transported_tangent_vec = self.log(base_shoot, current_point)
      if n_rungs % 2 == 1 and scheme == "pole":
          transported_tangent_vec *= -1.0
      transported_tangent_vec *= n_rungs**alpha
      return {
          "transported_tangent_vec": transported_tangent_vec,
          "end_point": current_point,
          "trajectory": trajectory,
      }
  
imports: from abc import ABC
  import geomstats.backend
  import geomstats.errors
label_desc: Use image node_id 8 for calling the Connection obj's underlying member method code with example usage: obj.ladder_parallel_transport(tangent_vec, base_point, direction, n_rungs, scheme, alpha, return_geodesics) and returns: dict