Skip to content

Commit

Permalink
fix the difference following gap keeping in dp st and speed opt
Browse files Browse the repository at this point in the history
  • Loading branch information
JasonZhou404 authored and xiaoxq committed Dec 18, 2019
1 parent 8a4a69e commit 4d324b6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ bool SpeedDecider::IsFollowTooClose(const Obstacle& obstacle) const {
}
const double distance =
obstacle.path_st_boundary().min_s() - FLAGS_min_stop_distance_obstacle;
static constexpr double lane_follow_max_decel = 1.0;
static constexpr double lane_follow_max_decel = 3.0;
static constexpr double lane_change_max_decel = 3.0;
auto* planning_status = PlanningContext::Instance()
->mutable_planning_status()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,6 @@ double DpStCost::GetObstacleCost(const StGraphPoint& st_graph_point) {
if (s > upper_bound || s < lower_bound) {
return kInf;
}
return cost * unit_t_;
}

for (const auto* obstacle : obstacles_) {
Expand Down Expand Up @@ -161,10 +160,7 @@ double DpStCost::GetObstacleCost(const StGraphPoint& st_graph_point) {
s_lower = boundary_cost_[boundary_index][st_graph_point.index_t()].second;
}
if (s < s_lower) {
const double follow_distance_s =
config_.is_lane_changing()
? config_.safe_distance()
: StGapEstimator::EstimateSafeFollowingGap(obstacle->speed());
const double follow_distance_s = config_.safe_distance();
if (s + follow_distance_s < s_lower) {
continue;
} else {
Expand Down

0 comments on commit 4d324b6

Please sign in to comment.