feat(ndt_scan_matcher): add grid_search initial pose estimation #6790
CodeScene PR Check
❌ Code Health Quality Gates: FAILED
- Declining Code Health: 2 findings(s) 🚩
- Improving Code Health: 1 findings(s) ✅
Details
🚩 Declining Code Health (highest to lowest):
- Deep, Nested Complexity ndt_scan_matcher_core.cpp: NDTScanMatcher::align_pose_by_grid_search
- Complex Method ndt_scan_matcher_core.cpp: NDTScanMatcher::align_pose_by_grid_search
✅ Improving Code Health:
- Large Method ndt_scan_matcher_core.cpp: NDTScanMatcher::align_pose
Annotations
Check warning on line 1126 in localization/ndt_scan_matcher/src/ndt_scan_matcher_core.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ New issue: Complex Method
NDTScanMatcher::align_pose_by_grid_search 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 1126 in localization/ndt_scan_matcher/src/ndt_scan_matcher_core.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ No longer an issue: Large Method
NDTScanMatcher::align_pose is no longer above the threshold for lines of code. Large functions with many lines of code are generally harder to understand and lower the code health. Avoid adding more lines to this function.
Check notice on line 899 in localization/ndt_scan_matcher/src/ndt_scan_matcher_core.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
ℹ New issue: Large Method
NDTScanMatcher::align_pose_by_random_search has 93 lines, threshold = 70. Large functions with many lines of code are generally harder to understand and lower the code health. Avoid adding more lines to this function.
Check warning on line 1126 in localization/ndt_scan_matcher/src/ndt_scan_matcher_core.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ New issue: Deep, Nested Complexity
NDTScanMatcher::align_pose_by_grid_search has a nested complexity depth of 7, threshold = 4. This function contains deeply nested logic such as if statements and/or loops. The deeper the nesting, the lower the code health.