From f2b48a1803eed1512962ee80e0f4c9718f40d44b Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Mon, 25 Oct 2021 23:47:12 -0700 Subject: [PATCH] always show lane lines on HUD (#22693) * always show lane lines on HUD * update refs --- selfdrive/controls/controlsd.py | 8 ++++---- selfdrive/test/process_replay/ref_commit | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/selfdrive/controls/controlsd.py b/selfdrive/controls/controlsd.py index fd43d65b01..aff6e1abdf 100755 --- a/selfdrive/controls/controlsd.py +++ b/selfdrive/controls/controlsd.py @@ -565,10 +565,8 @@ class Controls: CC.hudControl.lanesVisible = self.enabled CC.hudControl.leadVisible = self.sm['longitudinalPlan'].hasLead - right_lane_visible = self.sm['lateralPlan'].rProb > 0.5 - left_lane_visible = self.sm['lateralPlan'].lProb > 0.5 - CC.hudControl.rightLaneVisible = bool(right_lane_visible) - CC.hudControl.leftLaneVisible = bool(left_lane_visible) + CC.hudControl.rightLaneVisible = True + CC.hudControl.leftLaneVisible = True recent_blinker = (self.sm.frame - self.last_blinker_frame) * DT_CTRL < 5.0 # 5s blinker cooldown ldw_allowed = self.is_ldw_enabled and CS.vEgo > LDW_MIN_SPEED and not recent_blinker \ @@ -576,6 +574,8 @@ class Controls: meta = self.sm['modelV2'].meta if len(meta.desirePrediction) and ldw_allowed: + right_lane_visible = self.sm['lateralPlan'].rProb > 0.5 + left_lane_visible = self.sm['lateralPlan'].lProb > 0.5 l_lane_change_prob = meta.desirePrediction[Desire.laneChangeLeft - 1] r_lane_change_prob = meta.desirePrediction[Desire.laneChangeRight - 1] l_lane_close = left_lane_visible and (self.sm['modelV2'].laneLines[1].y[0] > -(1.08 + CAMERA_OFFSET)) diff --git a/selfdrive/test/process_replay/ref_commit b/selfdrive/test/process_replay/ref_commit index 45e6b7d9f9..cdec6acf61 100644 --- a/selfdrive/test/process_replay/ref_commit +++ b/selfdrive/test/process_replay/ref_commit @@ -1 +1 @@ -d616c135e470264dbc40e77b25a4dab1fc449d75 \ No newline at end of file +c4c4030e5039cc96870857aed08ad132a2d67497 \ No newline at end of file