Skip to content

perf(out_of_lane): downsample the trajectory to improve performance

CodeScene Delta Analysis / CodeScene Cloud Delta Analysis (main) failed Jun 25, 2024 in 43s

CodeScene PR Check

Code Health Quality Gates: FAILED

  • Declining Code Health: 1 findings(s) 🚩

View detailed results in CodeScene

Details

🚩 Declining Code Health (highest to lowest):

  • Complex Method out_of_lane_module.cpp: OutOfLaneModule::plan

Annotations

Check warning on line 166 in planning/motion_velocity_planner/autoware_motion_velocity_out_of_lane_module/src/out_of_lane_module.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)

❌ Getting worse: Complex Method

OutOfLaneModule::plan already has high cyclomatic complexity, and now it increases in Lines of Code from 150 to 152. This function has many conditional statements (e.g. if, for, while), leading to lower code health. Avoid adding more conditionals and code to it without refactoring.