Skip to content

Commit 0461798

Browse files
author
Takumi Ito
committed
modify astar for standalone running
move clearNoe() from setMap to makePlan(). Signed-off-by: Takumi Ito <takumi.ito@tier4.jp>
1 parent 909004e commit 0461798

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

planning/autoware_freespace_planning_algorithms/src/astar_search.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -130,9 +130,7 @@ AstarSearch::AstarSearch(
130130
void AstarSearch::setMap(const nav_msgs::msg::OccupancyGrid & costmap)
131131
{
132132
AbstractPlanningAlgorithm::setMap(costmap);
133-
134-
clearNodes();
135-
133+
136134
x_scale_ = costmap_.info.height;
137135
graph_.reserve(100000);
138136
}
@@ -143,6 +141,8 @@ bool AstarSearch::makePlan(
143141
start_pose_ = global2local(costmap_, start_pose);
144142
goal_pose_ = global2local(costmap_, goal_pose);
145143

144+
clearNodes();
145+
146146
if (!setStartNode()) {
147147
return false;
148148
}

0 commit comments

Comments
 (0)