mirror of
https://github.com/zhm-real/PathPlanning.git
synced 2026-08-29 16:40:46 +08:00
update
This commit is contained in:
@@ -21,12 +21,12 @@ class DFS:
|
||||
self.Env = env.Env()
|
||||
self.plotting = plotting.Plotting(self.s_start, self.s_goal)
|
||||
|
||||
self.u_set = self.Env.motions # feasible input set
|
||||
self.obs = self.Env.obs # position of obstacles
|
||||
self.u_set = self.Env.motions # feasible input set
|
||||
self.obs = self.Env.obs # position of obstacles
|
||||
|
||||
self.OPEN = deque() # OPEN set: visited nodes
|
||||
self.PARENT = dict() # recorded parent
|
||||
self.CLOSED = [] # CLOSED set / visited order
|
||||
self.OPEN = deque() # OPEN set: visited nodes
|
||||
self.PARENT = dict() # recorded parent
|
||||
self.CLOSED = [] # CLOSED set / visited order
|
||||
|
||||
def searching(self):
|
||||
"""
|
||||
@@ -47,7 +47,7 @@ class DFS:
|
||||
for s_n in self.get_neighbor(s):
|
||||
if self.is_collision(s, s_n):
|
||||
continue
|
||||
if s_n not in self.PARENT: # node not explored
|
||||
if s_n not in self.PARENT: # node not explored
|
||||
self.OPEN.append(s_n)
|
||||
self.PARENT[s_n] = s
|
||||
|
||||
|
||||
Reference in New Issue
Block a user