Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion PathPlanning/Dijkstra/dijkstra.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ def calc_xy_index(self, position, minp):
return round((position - minp) / self.resolution)

def calc_index(self, node):
return (node.y - self.min_y) * self.x_width + (node.x - self.min_x)
return node.y * self.x_width + node.x

def verify_node(self, node):
px = self.calc_position(node.x, self.min_x)
Expand Down