Skip to content

Commit f7d386a

Browse files
authored
fix(intersection_occlusion): fix for PR6273 without traffic light (#6335)
Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp>
1 parent 7a53913 commit f7d386a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

planning/behavior_velocity_intersection_module/src/scene_intersection_occlusion.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@ IntersectionModule::getOcclusionStatus(
4141

4242
// ==========================================================================================
4343
// for the convenience of Psim user, this module ignores occlusion if there has not been any
44-
// information published for the associated traffic light, and only runs collision checking on
45-
// that intersection lane.
44+
// information published for the associated traffic light even if occlusion.enable is true,
45+
// and only runs collision checking on that intersection lane.
4646
//
4747
// this is because Psim-users/scenario-files do not set traffic light information perfectly
4848
// most of the times, and they just set bare minimum traffic information only for traffic lights
@@ -53,7 +53,7 @@ IntersectionModule::getOcclusionStatus(
5353
// or in the simulation, then it should be kept in last_tl_valid_observation_ and this variable
5454
// becomes false
5555
// ==========================================================================================
56-
const bool no_tl_info_ever = !last_tl_valid_observation_.has_value();
56+
const bool no_tl_info_ever = (has_traffic_light_ && !last_tl_valid_observation_.has_value());
5757
const bool is_amber_or_red_or_no_tl_info_ever =
5858
(traffic_prioritized_level == TrafficPrioritizedLevel::PARTIALLY_PRIORITIZED) ||
5959
(traffic_prioritized_level == TrafficPrioritizedLevel::FULLY_PRIORITIZED) || no_tl_info_ever;

0 commit comments

Comments
 (0)