Skip to content

Commit

Permalink
fix(obstacle_avoidance_planner): fix optimization constraint for narr…
Browse files Browse the repository at this point in the history
…ow-road driving (autowarefoundation#3701)

Signed-off-by: Takayuki Murooka <takayuki5168@gmail.com>
  • Loading branch information
takayuki5168 committed Jun 29, 2023
1 parent ca59285 commit 0b33cd1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions planning/obstacle_avoidance_planner/src/mpt_optimizer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -921,7 +921,7 @@ void MPTOptimizer::keepMinimumBoundsWidth(std::vector<ReferencePoint> & ref_poin
// Only the Lower bound is cut out. Widen the bounds towards the lower bound since cut out too
// much.
b.lower_bound =
std::min(b.lower_bound, original_b.upper_bound + mpt_param_.min_drivable_width);
std::min(b.lower_bound, original_b.upper_bound - mpt_param_.min_drivable_width);
continue;
}
// extend longitudinal if it overlaps out_of_upper_bound_sections
Expand Down Expand Up @@ -971,7 +971,7 @@ void MPTOptimizer::keepMinimumBoundsWidth(std::vector<ReferencePoint> & ref_poin
// Only the Upper bound is cut out. Widen the bounds towards the upper bound since cut out too
// much.
b.upper_bound =
std::max(b.upper_bound, original_b.lower_bound - mpt_param_.min_drivable_width);
std::max(b.upper_bound, original_b.lower_bound + mpt_param_.min_drivable_width);
continue;
}
// extend longitudinal if it overlaps out_of_lower_bound_sections
Expand Down

0 comments on commit 0b33cd1

Please sign in to comment.