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

fix(lidar_centerpoint): fix constexpr related bugs #7686

Merged
merged 1 commit into from
Jun 25, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions perception/lidar_centerpoint/test/test_postprocess_kernel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,12 @@
constexpr float detection_x = 70.f;
constexpr float detection_y = -38.4f;
constexpr float detection_z = 1.0;
constexpr float detection_log_w = std::log(7.0);
constexpr float detection_log_l = std::log(1.0);
constexpr float detection_log_h = std::log(2.0);
const float detection_log_w = std::log(7.0);
const float detection_log_l = std::log(1.0);
const float detection_log_h = std::log(2.0);

Check warning on line 99 in perception/lidar_centerpoint/test/test_postprocess_kernel.cpp

View check run for this annotation

Codecov / codecov/patch

perception/lidar_centerpoint/test/test_postprocess_kernel.cpp#L97-L99

Added lines #L97 - L99 were not covered by tests
constexpr float detection_yaw = M_PI_4;
constexpr float detection_yaw_sin = std::sin(detection_yaw);
constexpr float detection_yaw_cos = std::sin(detection_yaw);
const float detection_yaw_sin = std::sin(detection_yaw);
const float detection_yaw_cos = std::sin(detection_yaw);

Check warning on line 102 in perception/lidar_centerpoint/test/test_postprocess_kernel.cpp

View check run for this annotation

Codecov / codecov/patch

perception/lidar_centerpoint/test/test_postprocess_kernel.cpp#L101-L102

Added lines #L101 - L102 were not covered by tests
constexpr float detection_vel_x = 5.0;
constexpr float detection_vel_y = -5.0;

Expand Down Expand Up @@ -240,9 +240,9 @@
constexpr float detection_x = 70.f;
constexpr float detection_y = -38.4f;
constexpr float detection_z = 1.0;
constexpr float detection_log_w = std::log(7.0);
constexpr float detection_log_l = std::log(1.0);
constexpr float detection_log_h = std::log(2.0);
const float detection_log_w = std::log(7.0);
const float detection_log_l = std::log(1.0);
const float detection_log_h = std::log(2.0);

Check warning on line 245 in perception/lidar_centerpoint/test/test_postprocess_kernel.cpp

View check run for this annotation

Codecov / codecov/patch

perception/lidar_centerpoint/test/test_postprocess_kernel.cpp#L243-L245

Added lines #L243 - L245 were not covered by tests
constexpr float detection_yaw1_sin = 0.0;
constexpr float detection_yaw1_cos = 1.0;
constexpr float detection_yaw2_sin = 1.0;
Expand Down
Loading