提交 3a793501 编写于 作者: K kechxu 提交者: Kecheng Xu

Prediction: narrow the range of caution in cruise

上级 63a2de46
......@@ -62,6 +62,8 @@ DEFINE_bool(enable_all_junction, false,
"If consider all junction with junction_mlp_model.");
DEFINE_double(caution_search_distance_ahead, 50.0,
"The distance ahead to search caution-level obstacles");
DEFINE_double(caution_search_distance_backward, 50.0,
"The distance backward to search caution-level obstacles");
DEFINE_double(caution_search_distance_backward_for_merge, 60.0,
"The distance backward to search caution-lebel obstacles "
"in the case of merging");
......
......@@ -46,6 +46,7 @@ DECLARE_int32(road_graph_max_search_horizon);
DECLARE_double(junction_distance_threshold);
DECLARE_bool(enable_all_junction);
DECLARE_double(caution_search_distance_ahead);
DECLARE_double(caution_search_distance_backward);
DECLARE_double(caution_search_distance_backward_for_merge);
DECLARE_double(caution_search_distance_backward_for_overlap);
DECLARE_double(caution_pedestrian_approach_time);
......
......@@ -59,7 +59,8 @@ int NearestFrontObstacleIdOnLaneSequence(const LaneSequence& lane_sequence) {
int nearest_front_obstacle_id = std::numeric_limits<int>::min();
double smallest_relative_s = std::numeric_limits<double>::max();
for (const auto& nearby_obs : lane_sequence.nearby_obstacle()) {
if (nearby_obs.s() < 0.0) {
if (nearby_obs.s() < 0.0 ||
nearby_obs.s() > FLAGS_caution_search_distance_ahead) {
continue;
}
if (nearby_obs.s() < smallest_relative_s) {
......@@ -74,7 +75,8 @@ int NearestBackwardObstacleIdOnLaneSequence(const LaneSequence& lane_sequence) {
int nearest_backward_obstacle_id = std::numeric_limits<int>::min();
double smallest_relative_s = std::numeric_limits<double>::max();
for (const auto& nearby_obs : lane_sequence.nearby_obstacle()) {
if (nearby_obs.s() > 0.0) {
if (nearby_obs.s() > 0.0 ||
nearby_obs.s() < -FLAGS_caution_search_distance_backward) {
continue;
}
if (-nearby_obs.s() < smallest_relative_s) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册