Skip to content

Commit

Permalink
fix(avoidance): ignore objects whose shift length is less than execut…
Browse files Browse the repository at this point in the history
…ion threshold

Signed-off-by: satoshi-ota <satoshi.ota928@gmail.com>
  • Loading branch information
satoshi-ota committed May 8, 2023
1 parent de8afd7 commit a2abc68
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3314,6 +3314,7 @@ void AvoidanceModule::updateDebugMarker(
add(createOtherObjectsMarkerArray(data.other_objects, std::string("MovingObject")));
add(createOtherObjectsMarkerArray(data.other_objects, std::string("OutOfTargetArea")));
add(createOtherObjectsMarkerArray(data.other_objects, std::string("NotNeedAvoidance")));
add(createOtherObjectsMarkerArray(data.other_objects, std::string("LessThanExecutionThreshold")));

add(makeOverhangToRoadShoulderMarkerArray(data.target_objects, "overhang"));
add(createOverhangFurthestLineStringMarkerArray(
Expand Down
6 changes: 6 additions & 0 deletions planning/behavior_path_planner/src/utils/avoidance/utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -716,6 +716,12 @@ void filterTargetObjects(
data.other_objects.push_back(o);
continue;
}

if (std::abs(shift_length) < parameters->avoidance_execution_lateral_threshold) {
o.reason = "LessThanExecutionThreshold";
data.other_objects.push_back(o);
continue;
}
}

// force avoidance for stopped vehicle
Expand Down

0 comments on commit a2abc68

Please sign in to comment.