code: def geodesic(actor, start, end):
      
  
      dijkstra = vtk.vtkDijkstraGraphGeodesicPath()
  
      if vu.isSequence(start):
          cc = actor.coordinates()
          pa = vs.Points(cc)
          start = pa.closestPoint(start, returnIds=True)
          end = pa.closestPoint(end, returnIds=True)
          dijkstra.SetInputData(pa.polydata())
      else:
          dijkstra.SetInputData(actor.polydata())
  
      dijkstra.SetStartVertex(start)
      dijkstra.SetEndVertex(end)
      dijkstra.Update()
  
      weights = vtk.vtkDoubleArray()
      dijkstra.GetCumulativeWeights(weights)
  
      length = weights.GetMaxId() + 1
      arr = np.zeros(length)
      for i in range(length):
          arr[i] = weights.GetTuple(i)[0]
  
      dactor = Actor(dijkstra.GetOutput())
      prop = vtk.vtkProperty()
      prop.DeepCopy(actor.GetProperty())
      prop.SetLineWidth(3)
      prop.SetOpacity(1)
      dactor.SetProperty(prop)
      dactor.info["CumulativeWeights"] = arr
      return dactor
docs: Dijkstra algorithm to compute the graph geodesic.
      Takes as input a polygonal mesh and performs a single source shortest path calculation.
  
      :param start: start vertex index or close point `[x,y,z]`
      :type start: int, list
      :param end: end vertex index or close point `[x,y,z]`
      :type start: int, list
  
      .. hint:: |geodesic| |geodesic.py|_