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: Generate parameterized function for the geodesic curve.
  
  Geodesic curve defined by either:
  
  - an initial point and an initial tangent vector,
  - an initial point and an end point.
  
  Parameters
  ----------
  initial_point : array-like, shape=[..., dim]
      Point on the manifold, initial point of the geodesic.
  end_point : array-like, shape=[..., dim], optional
      Point on the manifold, end point of the geodesic. If None,
      an initial tangent vector must be given.
  initial_tangent_vec : array-like, shape=[..., dim],
      Tangent vector at base point, the initial speed of the geodesics.
      Optional, default: None.
      If None, an end point must be given and a logarithm is computed.
  
  Returns
  -------
  path : callable
      Time parameterized geodesic curve. If a batch of initial
      conditions is passed, the output array's first dimension
      represents the different initial conditions, and the second
      corresponds to time.
docstr_tok: ["Generate","parameterized","function","for","the","geodesic","curve",".","Geodesic","curve","defined","by","either",":","-","an","initial","point","and","an","initial","tangent","vector",",","-","an","initial","point","and","an","end","point",".","Parameters","--","--","--","--","--","initial_point",":","array-like",",","shape=","[","...",",","dim","]","Point","on","the","manifold",",","initial","point","of","the","geodesic",".","end_point",":","array-like",",","shape=","[","...",",","dim","]",",","optional","Point","on","the","manifold",",","end","point","of","the","geodesic",".","If","None",",","an","initial","tangent","vector","must","be","given",".","initial_tangent_vec",":","array-like",",","shape=","[","...",",","dim","]",",","Tangent","vector","at","base","point",",","the","initial","speed","of","the","geodesics",".","Optional",",","default",":","None",".","If","None",",","an","end","point","must","be","given","and","a","logarithm","is","computed",".","Returns","--","--","--","-","path",":","callable","Time","parameterized","geodesic","curve",".","If","a","batch","of","initial","conditions","is","passed",",","the","output","array","'s","first","dimension","represents","the","different","initial","conditions",",","and","the","second","corresponds","to","time","."]
code: def geodesic(
      self, initial_point, end_point=None, initial_tangent_vec=None
  ):
      """Generate parameterized function for the geodesic curve.
  
      Geodesic curve defined by either:
  
      - an initial point and an initial tangent vector,
      - an initial point and an end point.
  
      Parameters
      ----------
      initial_point : array-like, shape=[..., dim]
          Point on the manifold, initial point of the geodesic.
      end_point : array-like, shape=[..., dim], optional
          Point on the manifold, end point of the geodesic. If None,
          an initial tangent vector must be given.
      initial_tangent_vec : array-like, shape=[..., dim],
          Tangent vector at base point, the initial speed of the geodesics.
          Optional, default: None.
          If None, an end point must be given and a logarithm is computed.
  
      Returns
      -------
      path : callable
          Time parameterized geodesic curve. If a batch of initial
          conditions is passed, the output array's first dimension
          represents the different initial conditions, and the second
          corresponds to time.
      """
      if end_point is None and initial_tangent_vec is None:
          raise ValueError(
              "Specify an end point or an initial tangent "
              "vector to define the geodesic."
          )
      if end_point is not None:
          if initial_tangent_vec is not None:
              raise ValueError(
                  "Cannot specify both an end point and an initial tangent vector."
              )
  
          out = self._geodesic_bvp(initial_point, end_point)
          if out is not NotImplemented:
              return out
  
          initial_tangent_vec = self.log(end_point, initial_point)
  
      return self._geodesic_ivp(initial_point, initial_tangent_vec)
  
imports: from abc import ABC
  import geomstats.backend
  import geomstats.errors
label_desc: Use image node_id 18 for calling the Connection obj's underlying member method code with example usage: obj.geodesic(initial_point, end_point, initial_tangent_vec) and returns: self, out