Skip to content

remove unused parm

175051c
Select commit
Loading
Failed to load commit list.
Merged

feat(autoware_planning_evaluator): new obstacle metrics #11761

remove unused parm
175051c
Select commit
Loading
Failed to load commit list.
CodeScene Delta Analysis / CodeScene Code Health Review (main) failed Jan 16, 2026 in 42s

CodeScene PR Check

Quality Gate Failed

Code Health Improved (1 files improve in Code Health)

Gates Failed
New code is healthy (1 new file with code health below 9.00)
Enforce critical code health rules (2 files with Bumpy Road Ahead, Deep, Nested Complexity)
Enforce advisory code health rules (3 files with Complex Method, Overall Code Complexity)

Gates Passed
1 Quality Gates Passed

See analysis details in CodeScene

Reason for failure
New code is healthy Violations Code Health Impact
obstacle_metrics_calculator.cpp 4 rules 6.68 Suppress
Enforce critical code health rules Violations Code Health Impact
obstacle_metrics_calculator.cpp 2 critical rules 6.68 Suppress
planning_evaluator_node.cpp 1 critical rule 7.94 → 7.52 Suppress
Enforce advisory code health rules Violations Code Health Impact
obstacle_metrics_calculator.cpp 2 advisory rules 6.68 Suppress
planning_evaluator_node.cpp 1 advisory rule 7.94 → 7.52 Suppress
metrics_utils.cpp 1 advisory rule 9.69 → 9.39 Suppress
View Improvements
File Code Health Impact Categories Improved
metrics_calculator.cpp 9.45 → 9.50 Complex Method

Quality Gate Profile: Clean Code Collective
Want more control? Customize Code Health rules or catch issues early with our IDE extension and CLI tool.

Details

🚩 Declining Code Health (highest to lowest):

  • Complex Method obstacle_metrics_calculator.cpp: ObstacleMetricsCalculator::ProcessObstaclesTrajectory
  • Overall Code Complexity obstacle_metrics_calculator.cpp
  • Deep, Nested Complexity obstacle_metrics_calculator.cpp: ObstacleMetricsCalculator::ProcessObstaclesTrajectory
  • Bumpy Road Ahead obstacle_metrics_calculator.cpp: ObstacleMetricsCalculator::ProcessObstaclesTrajectory
  • Complex Method obstacle_metrics_calculator.cpp: ObstacleMetricsCalculator::PreprocessEgoTrajectory
  • Complex Method obstacle_metrics_calculator.cpp: ObstacleMetricsCalculator::CollectWorstMetrics
  • Complex Method planning_evaluator_node.cpp: PlanningEvaluatorNode::onTrajectory
  • Complex Method metrics_utils.cpp: polygon_intersects
  • Bumpy Road Ahead obstacle_metrics_calculator.cpp: ObstacleMetricsCalculator::PreprocessEgoTrajectory
  • Bumpy Road Ahead planning_evaluator_node.cpp: PlanningEvaluatorNode::onTrajectory
  • Bumpy Road Ahead obstacle_metrics_calculator.cpp: ObstacleMetricsCalculator::CollectWorstMetrics

✅ Improving Code Health:

  • Complex Method metrics_calculator.cpp: MetricsCalculator::calculate

Annotations

Check warning on line 149 in evaluator/autoware_planning_evaluator/src/metrics/metrics_utils.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Complex Method

polygon_intersects has a cyclomatic complexity of 9, threshold = 9. 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.

Check notice on line 74 in evaluator/autoware_planning_evaluator/src/metrics_calculator.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

✅ Getting better: Complex Method

MetricsCalculator::calculate decreases in cyclomatic complexity from 20 to 18, threshold = 9. 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.

Check warning on line 441 in evaluator/autoware_planning_evaluator/src/obstacle_metrics_calculator.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Complex Method

ObstacleMetricsCalculator::ProcessObstaclesTrajectory has a cyclomatic complexity of 38, threshold = 9. 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.

Check warning on line 183 in evaluator/autoware_planning_evaluator/src/obstacle_metrics_calculator.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Complex Method

ObstacleMetricsCalculator::PreprocessEgoTrajectory has a cyclomatic complexity of 15, threshold = 9. 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.

Check warning on line 480 in evaluator/autoware_planning_evaluator/src/obstacle_metrics_calculator.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Complex Method

ObstacleMetricsCalculator::CollectWorstMetrics has a cyclomatic complexity of 14, threshold = 9. 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.

Check warning on line 441 in evaluator/autoware_planning_evaluator/src/obstacle_metrics_calculator.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Bumpy Road Ahead

ObstacleMetricsCalculator::ProcessObstaclesTrajectory has 9 blocks with nested conditional logic. Any nesting of 2 or deeper is considered. Threshold is 2 blocks per function. The Bumpy Road code smell is a function that contains multiple chunks of nested conditional logic. The deeper the nesting and the more bumps, the lower the code health.

Check warning on line 183 in evaluator/autoware_planning_evaluator/src/obstacle_metrics_calculator.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Bumpy Road Ahead

ObstacleMetricsCalculator::PreprocessEgoTrajectory has 4 blocks with nested conditional logic. Any nesting of 2 or deeper is considered. Threshold is 2 blocks per function. The Bumpy Road code smell is a function that contains multiple chunks of nested conditional logic. The deeper the nesting and the more bumps, the lower the code health.

Check warning on line 480 in evaluator/autoware_planning_evaluator/src/obstacle_metrics_calculator.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Bumpy Road Ahead

ObstacleMetricsCalculator::CollectWorstMetrics has 2 blocks with nested conditional logic. Any nesting of 2 or deeper is considered. Threshold is 2 blocks per function. The Bumpy Road code smell is a function that contains multiple chunks of nested conditional logic. The deeper the nesting and the more bumps, the lower the code health.

Check warning on line 1 in evaluator/autoware_planning_evaluator/src/obstacle_metrics_calculator.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Overall Code Complexity

This module has a mean cyclomatic complexity of 7.17 across 12 functions. The mean complexity threshold is 4. This file has many conditional statements (e.g. if, for, while) across its implementation, leading to lower code health. Avoid adding more conditionals.

Check warning on line 441 in evaluator/autoware_planning_evaluator/src/obstacle_metrics_calculator.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Deep, Nested Complexity

ObstacleMetricsCalculator::ProcessObstaclesTrajectory has a nested complexity depth of 6, threshold = 4. This function contains deeply nested logic such as if statements and/or loops. The deeper the nesting, the lower the code health.

Check warning on line 434 in evaluator/autoware_planning_evaluator/src/planning_evaluator_node.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Complex Method

PlanningEvaluatorNode::onTrajectory has a cyclomatic complexity of 14, threshold = 9. 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.

Check warning on line 434 in evaluator/autoware_planning_evaluator/src/planning_evaluator_node.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Bumpy Road Ahead

PlanningEvaluatorNode::onTrajectory has 3 blocks with nested conditional logic. Any nesting of 2 or deeper is considered. Threshold is 2 blocks per function. The Bumpy Road code smell is a function that contains multiple chunks of nested conditional logic. The deeper the nesting and the more bumps, the lower the code health.