Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(learned_model): create package #6395

Merged
merged 104 commits into from
Apr 24, 2024

add cpell:ignore pymodel

48379dc
Select commit
Loading
Failed to load commit list.
Merged

feat(learned_model): create package #6395

add cpell:ignore pymodel
48379dc
Select commit
Loading
Failed to load commit list.
CodeScene Delta Analysis / CodeScene Cloud Delta Analysis (main) failed Apr 5, 2024 in 48s

CodeScene PR Check

Code Health Quality Gates: FAILED

  • Declining Code Health: 5 findings(s) 🚩

View detailed results in CodeScene

Details

🚩 Declining Code Health (highest to lowest):

  • Complex Conditional simple_planning_simulator_core.cpp: SimplePlanningSimulator::set_input
  • Bumpy Road Ahead interconnected_model.cpp: InterconnectedModel::initState
  • Complex Method simple_planning_simulator_core.cpp: SimplePlanningSimulator::set_input
  • Complex Method simple_planning_simulator_core.cpp: SimplePlanningSimulator::initialize_vehicle_model
  • Complex Method simple_planning_simulator_core.cpp: SimplePlanningSimulator::set_initial_state

Annotations

Check warning on line 495 in simulator/simple_planning_simulator/src/simple_planning_simulator/simple_planning_simulator_core.cpp

See this annotation in the file changed.

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

❌ Getting worse: Complex Method

SimplePlanningSimulator::set_input increases in cyclomatic complexity from 11 to 12, 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 296 in simulator/simple_planning_simulator/src/simple_planning_simulator/simple_planning_simulator_core.cpp

See this annotation in the file changed.

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

❌ Getting worse: Complex Method

SimplePlanningSimulator::initialize_vehicle_model increases in cyclomatic complexity from 11 to 12, 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 601 in simulator/simple_planning_simulator/src/simple_planning_simulator/simple_planning_simulator_core.cpp

See this annotation in the file changed.

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

❌ New issue: Complex Method

SimplePlanningSimulator::set_initial_state 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 warning on line 495 in simulator/simple_planning_simulator/src/simple_planning_simulator/simple_planning_simulator_core.cpp

See this annotation in the file changed.

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

❌ Getting worse: Complex Conditional

SimplePlanningSimulator::set_input increases from 1 complex conditionals with 2 branches to 2 complex conditionals with 4 branches, threshold = 2. A complex conditional is an expression inside a branch (e.g. if, for, while) which consists of multiple, logical operators such as AND/OR. The more logical operators in an expression, the more severe the code smell.

Check warning on line 106 in simulator/learning_based_vehicle_model/src/interconnected_model.cpp

See this annotation in the file changed.

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

❌ New issue: Bumpy Road Ahead

InterconnectedModel::initState has 2 blocks with nested conditional logic. Any nesting of 2 or deeper is considered. Threshold is one single, nested 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.