perf(velocity_smoother): not resample debug_trajectories is not used #8030
CodeScene PR Check
❌ Code Health Quality Gates: FAILED
Change in average Code Health of affected files: +0.04 (7.64 -> 7.68)
- Declining Code Health: 4 findings(s) 🚩
- Improving Code Health: 5 findings(s) ✅
Details
🚩 Declining Code Health (highest to lowest):
- Complex Method jerk_filtered_smoother.cpp: JerkFilteredSmoother::apply
- Complex Method linf_pseudo_jerk_smoother.cpp: LinfPseudoJerkSmoother::apply
- Complex Method l2_pseudo_jerk_smoother.cpp: L2PseudoJerkSmoother::apply
- Complex Method analytical_jerk_constrained_smoother.cpp: AnalyticalJerkConstrainedSmoother::apply
✅ Improving Code Health:
- Overall Code Complexity node.cpp
- Complex Method node.cpp: VelocitySmootherNode::smoothVelocity
- Deep, Nested Complexity node.cpp: VelocitySmootherNode::smoothVelocity
- Excess Number of Function Arguments l2_pseudo_jerk_smoother.cpp: L2PseudoJerkSmoother::apply
- Excess Number of Function Arguments linf_pseudo_jerk_smoother.cpp: LinfPseudoJerkSmoother::apply
Annotations
Check notice on line 679 in planning/autoware_velocity_smoother/src/node.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ Getting better: Complex Method
VelocitySmootherNode::smoothVelocity decreases in cyclomatic complexity from 14 to 13, 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 1 in planning/autoware_velocity_smoother/src/node.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ Getting better: Overall Code Complexity
The mean cyclomatic complexity decreases from 4.26 to 4.23, threshold = 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 notice on line 679 in planning/autoware_velocity_smoother/src/node.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ No longer an issue: Deep, Nested Complexity
VelocitySmootherNode::smoothVelocity is no longer above the threshold for nested complexity depth. This function contains deeply nested logic such as if statements and/or loops. The deeper the nesting, the lower the code health.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ Getting worse: Complex Method
AnalyticalJerkConstrainedSmoother::apply already has high cyclomatic complexity, and now it increases in Lines of Code from 116 to 117. 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.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ Getting worse: Complex Method
JerkFilteredSmoother::apply increases in cyclomatic complexity from 26 to 28, 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.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
ℹ Getting worse: Bumpy Road Ahead
JerkFilteredSmoother::apply increases from 3 to 4 logical blocks with deeply nested code, threshold is one single block 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.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
ℹ Getting worse: Overall Code Complexity
The mean cyclomatic complexity increases from 6.00 to 6.25, threshold = 4. This file has many conditional statements (e.g. if, for, while) across its implementation, leading to lower code health. Avoid adding more conditionals.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
ℹ Getting worse: Excess Number of Function Arguments
JerkFilteredSmoother::apply increases from 5 to 6 arguments, threshold = 4. This function has too many arguments, indicating a lack of encapsulation. Avoid adding more arguments.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ Getting worse: Complex Method
L2PseudoJerkSmoother::apply already has high cyclomatic complexity, and now it increases in Lines of Code from 123 to 124. 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.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ No longer an issue: Excess Number of Function Arguments
L2PseudoJerkSmoother::apply is no longer above the threshold for number of arguments
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ Getting worse: Complex Method
LinfPseudoJerkSmoother::apply already has high cyclomatic complexity, and now it increases in Lines of Code from 133 to 134. 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.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ No longer an issue: Excess Number of Function Arguments
LinfPseudoJerkSmoother::apply is no longer above the threshold for number of arguments