pydseamslib.cyoda.shortestPath#
- pydseamslib.cyoda.shortestPath(fullGraph: primitive::Graph, v: int, visited: int, maxDepth: List[int], depth: List[int], path: int, goal: int) int #
Calculates the shortest path
- Parameters:
fullGraph (The Graph object for the current frame.)
v (The current vertex being checked.)
visited (This vector contains the indices of the vertices visited or checked [for book-keeping].)
maxDepth (The maximum depth or maximum length of the rings.)
depth (The current depth. When this function is called from primitive::removeNonSPrings, the depth is initialized as 0)
path (The path or length of the visited points [This basically contains all the indices in the visited vector, excluding the current vertex])
goal (The first element of the candidate ring being checked [the root node])