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(autoware_pointcloud_preprocessor): cuda-accelerated pointcloud concatenation #9455

Draft
wants to merge 103 commits into
base: main
Choose a base branch
from

chore: updated schemaand tests

7fc85e9
Select commit
Loading
Failed to load commit list.
Draft

feat(autoware_pointcloud_preprocessor): cuda-accelerated pointcloud concatenation #9455

chore: updated schemaand tests
7fc85e9
Select commit
Loading
Failed to load commit list.
CodeScene Delta Analysis / CodeScene Cloud Delta Analysis (main) failed Nov 25, 2024 in 1m 7s

CodeScene PR Check

Code Health Quality Gates: FAILED

Change in average Code Health of affected files: +0.26 (7.20 -> 7.47)

  • Declining Code Health: 27 findings(s) 🚩

View detailed results in CodeScene

Details

🚩 Declining Code Health (highest to lowest):

  • Complex Method concatenate_and_time_sync_node.cpp: PointCloudConcatenateDataSynchronizerComponent::PointCloudConcatenateDataSynchronizerComponent
  • Complex Method test_concatenate_node_unit.cpp: TEST:ConcatenateCloudTest:TestConcatenateClouds
  • Complex Method combine_cloud_handler.cpp: combine_pointclouds
  • Code Duplication cloud_collector.cpp
  • Code Duplication combine_cloud_handler.cpp
  • Overall Code Complexity combine_cloud_handler.cpp
  • Code Duplication concatenate_and_time_sync_node.cpp
  • Bumpy Road Ahead concatenate_and_time_sync_node.cpp: PointCloudConcatenateDataSynchronizerComponent::PointCloudConcatenateDataSynchronizerComponent
  • Overall Code Complexity concatenate_and_time_sync_node.cpp
  • Code Duplication memory.cpp
  • Lines of Code in a Single File test_concatenate_node_component.py
  • Code Duplication test_concatenate_node_component.py
  • Code Duplication test_concatenate_node_unit.cpp
  • Large Method test_concatenate_node_component.py: TestConcatenateNode.test_8_abnormal_pointcloud_drop_continue_normal
  • Large Method test_concatenate_node_component.py: TestConcatenateNode.test_7_abnormal_pointcloud_delay
  • Complex Method combine_cloud_handler.cpp: combine_pointclouds
  • Complex Method combine_cloud_handler.cpp: convert_to_xyzirc_cloud
  • Complex Conditional combine_cloud_handler.cpp: convert_to_xyzirc_cloud
  • Excess Number of Function Arguments test_concatenate_node_component.py: generate_transform_msg
  • Primitive Obsession test_concatenate_node_unit.cpp
  • Excess Number of Function Arguments test_concatenate_node_unit.cpp: generate_transform_msg
  • Complex Method concatenate_and_time_sync_node.cpp: PointCloudConcatenateDataSynchronizerComponent::check_concat_status
  • Bumpy Road Ahead combine_cloud_handler.cpp: combine_pointclouds
  • Bumpy Road Ahead combine_cloud_handler.cpp: CombineCloudHandlerBase::process_twist
  • Bumpy Road Ahead combine_cloud_handler.cpp: CombineCloudHandlerBase::process_odometry
  • Bumpy Road Ahead combine_cloud_handler.cpp: convert_to_xyzirc_cloud
  • Bumpy Road Ahead combine_cloud_handler.cpp: combine_pointclouds

Annotations

Check warning on line 131 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/cloud_collector.cpp

See this annotation in the file changed.

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

❌ New issue: Code Duplication

The module contains 2 functions with similar structure: concatenate_callback,concatenate_callback. Avoid duplicated, aka copy-pasted, code inside the module. More duplication lowers the code health.

Check warning on line 108 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/combine_cloud_handler.cpp

See this annotation in the file changed.

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

❌ New issue: Code Duplication

The module contains 2 functions with similar structure: CombineCloudHandlerBase::process_odometry,CombineCloudHandlerBase::process_twist. Avoid duplicated, aka copy-pasted, code inside the module. More duplication lowers the code health.

Check warning on line 593 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/combine_cloud_handler.cpp

See this annotation in the file changed.

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

❌ New issue: Complex Method

combine_pointclouds 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 384 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/combine_cloud_handler.cpp

See this annotation in the file changed.

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

❌ New issue: Complex Method

combine_pointclouds 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 272 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/combine_cloud_handler.cpp

See this annotation in the file changed.

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

❌ New issue: Complex Method

convert_to_xyzirc_cloud 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 248 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/combine_cloud_handler.cpp

See this annotation in the file changed.

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

❌ New issue: Complex Conditional

convert_to_xyzirc_cloud has 1 complex conditionals with 2 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 593 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/combine_cloud_handler.cpp

See this annotation in the file changed.

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

❌ New issue: Bumpy Road Ahead

combine_pointclouds has 3 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.

Check warning on line 108 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/combine_cloud_handler.cpp

See this annotation in the file changed.

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

❌ New issue: Bumpy Road Ahead

CombineCloudHandlerBase::process_twist 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.

Check warning on line 135 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/combine_cloud_handler.cpp

See this annotation in the file changed.

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

❌ New issue: Bumpy Road Ahead

CombineCloudHandlerBase::process_odometry 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.

Check warning on line 272 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/combine_cloud_handler.cpp

See this annotation in the file changed.

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

❌ New issue: Bumpy Road Ahead

convert_to_xyzirc_cloud 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.

Check warning on line 384 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/combine_cloud_handler.cpp

See this annotation in the file changed.

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

❌ New issue: Bumpy Road Ahead

combine_pointclouds 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.

Check warning on line 1 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/combine_cloud_handler.cpp

See this annotation in the file changed.

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

❌ New issue: Overall Code Complexity

This module has a mean cyclomatic complexity of 5.55 across 11 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 326 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/concatenate_and_time_sync_node.cpp

See this annotation in the file changed.

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

❌ New issue: Code Duplication

The module contains 4 functions with similar structure: PointCloudConcatenateDataSynchronizerComponent::cloud_callback,PointCloudConcatenateDataSynchronizerComponent::cuda_cloud_callback,PointCloudConcatenateDataSynchronizerComponent::delete_collector,PointCloudConcatenateDataSynchronizerComponent::delete_collector. Avoid duplicated, aka copy-pasted, code inside the module. More duplication lowers the code health.

Check warning on line 213 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/concatenate_and_time_sync_node.cpp

See this annotation in the file changed.

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

❌ New issue: Complex Method

PointCloudConcatenateDataSynchronizerComponent::PointCloudConcatenateDataSynchronizerComponent has a cyclomatic complexity of 29, 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 646 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/concatenate_and_time_sync_node.cpp

See this annotation in the file changed.

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

❌ New issue: Complex Method

PointCloudConcatenateDataSynchronizerComponent::check_concat_status 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 213 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/concatenate_and_time_sync_node.cpp

See this annotation in the file changed.

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

❌ New issue: Bumpy Road Ahead

PointCloudConcatenateDataSynchronizerComponent::PointCloudConcatenateDataSynchronizerComponent has 5 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.

Check warning on line 1 in sensing/autoware_pointcloud_preprocessor/src/concatenate_data/concatenate_and_time_sync_node.cpp

See this annotation in the file changed.

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

❌ New issue: Overall Code Complexity

This module has a mean cyclomatic complexity of 4.82 across 17 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 1 in sensing/autoware_pointcloud_preprocessor/test/test_concatenate_node_component.py

See this annotation in the file changed.

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

❌ New issue: Lines of Code in a Single File

This module has 691 lines of code, improve code health by reducing it to 600. The number of Lines of Code in a single file. More Lines of Code lowers the code health.

Check warning on line 910 in sensing/autoware_pointcloud_preprocessor/test/test_concatenate_node_component.py

See this annotation in the file changed.

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

❌ New issue: Code Duplication

The module contains 7 functions with similar structure: TestConcatenateNode.test_1_normal_inputs,TestConcatenateNode.test_2_normal_inputs_with_noise,TestConcatenateNode.test_3_abnormal_null_pointcloud,TestConcatenateNode.test_5_abnormal_multiple_pointcloud_drop and 3 more functions. Avoid duplicated, aka copy-pasted, code inside the module. More duplication lowers the code health.

Check warning on line 910 in sensing/autoware_pointcloud_preprocessor/test/test_concatenate_node_component.py

See this annotation in the file changed.

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

❌ New issue: Large Method

TestConcatenateNode.test_8_abnormal_pointcloud_drop_continue_normal has 89 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 806 in sensing/autoware_pointcloud_preprocessor/test/test_concatenate_node_component.py

See this annotation in the file changed.

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

❌ New issue: Large Method

TestConcatenateNode.test_7_abnormal_pointcloud_delay has 81 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 235 in sensing/autoware_pointcloud_preprocessor/test/test_concatenate_node_component.py

See this annotation in the file changed.

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

❌ New issue: Excess Number of Function Arguments

generate_transform_msg has 9 arguments, threshold = 4. This function has too many arguments, indicating a lack of encapsulation. Avoid adding more arguments.

Check warning on line 202 in sensing/autoware_pointcloud_preprocessor/test/test_concatenate_node_unit.cpp

See this annotation in the file changed.

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

❌ New issue: Code Duplication

The module contains 2 functions with similar structure: TEST:ConcatenateCloudTest:TestProcessOdometry,TEST:ConcatenateCloudTest:TestProcessTwist. Avoid duplicated, aka copy-pasted, code inside the module. More duplication lowers the code health.

Check warning on line 449 in sensing/autoware_pointcloud_preprocessor/test/test_concatenate_node_unit.cpp

See this annotation in the file changed.

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

❌ New issue: Complex Method

TEST:ConcatenateCloudTest:TestConcatenateClouds 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 1 in sensing/autoware_pointcloud_preprocessor/test/test_concatenate_node_unit.cpp

See this annotation in the file changed.

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

❌ New issue: Primitive Obsession

In this module, 93.3% of all function arguments are primitive types, threshold = 30.0%. The functions in this file have too many primitive types (e.g. int, double, float) in their function argument lists. Using many primitive types lead to the code smell Primitive Obsession. Avoid adding more primitive arguments.