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

chore: sync tier4/autoware.universe:awf-latest #1416

Merged
merged 164 commits into from
Jul 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
164 commits
Select commit Hold shift + click to select a range
3d3118a
fix(radar_fusion_to_detected_object): fix knownConditionTrueFalse (#7…
veqcc Jul 4, 2024
3abdced
fix(autoware_behavior_velocity_intersection_module): fix shadowFuncti…
veqcc Jul 4, 2024
9ee408d
feat(obstacle_cruise_planner): add diagnostics publishing to cruise p…
danielsanchezaran Jul 4, 2024
8769544
fix(diagnostic_graph_aggregator): fix shadowFunction (#7838)
veqcc Jul 4, 2024
8df4b4c
feat(safety_check): filter safety check targe objects by yaw deviatio…
satoshi-ota Jul 4, 2024
5df28cc
feat(goal_planner): prioritize pull over path by curvature (#7791)
kosuke55 Jul 4, 2024
99c7c57
fix(static_obstacle_avoidance): fix issues in target object filtering…
satoshi-ota Jul 4, 2024
2acd484
refactor(occupancy_grid_map_outlier_filter)!: fix namespace and direc…
technolojin Jul 4, 2024
fd5a064
chore(motion_velocity_planner): add new codeowners (#7757)
maxime-clem Jul 4, 2024
a195201
refactor(detected_object_feature_remover)!: fix namespace and directo…
technolojin Jul 4, 2024
4f754f8
fix(motion_velocity_planner): use the slowdown velocity (instead of 0…
maxime-clem Jul 4, 2024
fcc838e
refactor(map_height_fitter): apply static analysis (#7837)
a-maumau Jul 4, 2024
a4aed87
refactor(velocity_smoother): change method to take data for external …
go-sakayori Jul 4, 2024
f29d560
fix: adapi vehicle topic qos (#7847)
isamu-takagi Jul 4, 2024
0176961
refactor(static_avoidance): modify getAdjacentLane function (#7843)
go-sakayori Jul 4, 2024
a1ed6c2
fix(pointcloud_preprocessor): fix preprocessorErrorDirective (#7786)
veqcc Jul 4, 2024
2705eff
fix(probabilistic_occupancy_grid_map): fix noExplicitConstructor (#7811)
veqcc Jul 4, 2024
7cbf2f5
chore(ci): remove unnecessary cppcheck suppressions (#7848)
veqcc Jul 4, 2024
55bedee
fix(imu_corrector): fix shadowFunction (#7839)
veqcc Jul 5, 2024
2dbf8e4
fix(control_launch): fix control launch control_evaluator plugin name…
danielsanchezaran Jul 5, 2024
037bcdd
fix(traffic_light_occlusion_predictor): fix cppcheck warnings (#7826)
veqcc Jul 5, 2024
b233929
fix(autoware_planning_validator): fix knownConditionTrueFalse (#7817)
veqcc Jul 5, 2024
268f374
chore(ci): remove unnecessary cppcheck suppression (#7854)
veqcc Jul 5, 2024
5c48933
fix(tensorrt_yolox): fix knownConditionTrueFalse (#7823)
veqcc Jul 5, 2024
ad38061
refactor(lane_change): move struct to lane change namespace (#7841)
zulfaqar-azmi-t4 Jul 5, 2024
5eb577e
fix(image_projection_based_fusion): segmentation pointcloud fusion pa…
badai-nguyen Jul 5, 2024
134b5c2
fix(static_obstacle_avoidance): ignore pedestrian/cyclist who is not …
satoshi-ota Jul 5, 2024
0f60c62
feat(planning_evaluator): add planning evaluator polling sub (#7827)
danielsanchezaran Jul 5, 2024
6c944bf
perf(map_based_prediction): remove query on all fences linestrings (#…
maxime-clem Jul 5, 2024
589c88b
fix(yabloc_image_processing): fix shadowFunction (#7865)
veqcc Jul 5, 2024
22daaeb
chore(ci): remove unnecessary cppcheck suppression (#7862)
veqcc Jul 5, 2024
3627afc
fix(fake_test_node, osqp_interface, qp_interface): remove unnecessary…
veqcc Jul 5, 2024
5be7627
feat(mission_planner): reroute in manual driving (#7842)
rej55 Jul 5, 2024
859da5a
refactor(map_loader): apply static analysis (#7845)
a-maumau Jul 5, 2024
3c615a6
fix(system_monitor): apply cppcheck-suppress for cstyleCast (#7867)
Koichi98 Jul 5, 2024
b61db78
feat(tier4_perception_launch): add image segmentation based pointclou…
badai-nguyen Jul 5, 2024
cc1ab05
fix(bluetooth_monitor): apply cppcheck-suppress for cstyleCast (#7869)
Koichi98 Jul 5, 2024
71fc4c3
feat(ndt_scan_matcher): estimate the covariance of ndt scan matching …
SaltUhey Jul 5, 2024
5ebaed7
feat(pointpainting_fusion): add test for painting util (#7169)
tzhong518 Jul 5, 2024
26e87ea
refactor(shape_estimation)!: fix namespace and directory structure (…
technolojin Jul 5, 2024
07e226c
fix(pointcloud_preprocessor): temporarily remove distortion corrector…
vividf Jul 7, 2024
e1cd1da
refactor(gnss_poser): apply static analysis (#7874)
a-maumau Jul 8, 2024
4dc3080
fix(pointcloud_preprocessor): fix documentation (#7878)
vividf Jul 8, 2024
fa6d8c5
chore: update CODEOWNERS (#7819)
awf-autoware-bot[bot] Jul 8, 2024
598d937
fix(motion_planning): fix processing time topic names (#7885)
maxime-clem Jul 8, 2024
45a0c3a
refactor(probabilistic_occupancy_grid_map)!: fix namespace and direct…
technolojin Jul 8, 2024
0c20459
refactor(lanelet2_map_preprocessor): apply static analysis (#7870)
a-maumau Jul 8, 2024
deef7c4
fix(pointcloud_preprocessor): fix the bug where the geometry message …
vividf Jul 8, 2024
094f2e2
refactor(multi_object_tracker)!: fix namespace and directory structur…
technolojin Jul 8, 2024
f28ccd8
refactor(detected_object_validation)!: fix namespace and directory st…
technolojin Jul 8, 2024
1cbd11d
feat(autoware_universe_utils): add TimeKeeper to track function's pro…
takayuki5168 Jul 8, 2024
a70aa0e
fix(multi_object_tracker): fix publish interval adjust timing (#7904)
technolojin Jul 9, 2024
7dcdd67
refactor(tier4_perception_launch): add maintainer to tier4_perception…
technolojin Jul 9, 2024
6d0247e
refactor(euclidean_cluster)!: fix namespace and directory structure (…
technolojin Jul 9, 2024
03877b0
chore(radar_object_tracker): delete maintainer (#7898)
scepter914 Jul 9, 2024
458dbe5
chore(autoware_behavior_velocity_planner): remove no_prefix function …
esteve Jul 9, 2024
f716b5b
fix(euclidean_cluster): include autoware_universe_utils headers (#7908)
technolojin Jul 9, 2024
d2f2fd9
feat(autonomous_emergency_braking): add virtual stop wall to aeb (#7894)
danielsanchezaran Jul 9, 2024
48b7cee
docs(goal_planner): update parameter description (#7889)
KeisukeShima Jul 9, 2024
f386fa8
fix(start/goal_planner): fix addition of duplicate segments in calcBe…
kosuke55 Jul 9, 2024
1654a57
fix(frenet_planner): fix mistake in the curvature calculation (#7920)
maxime-clem Jul 9, 2024
9b20ced
fix(pointcloud_preprocessor): fix distortion corrector unit test (#7833)
vividf Jul 9, 2024
54a0c57
feat: migrating pointcloud types (#6996)
knzo25 Jul 9, 2024
951d4cc
feat(map_loader, route_handler)!: add format_version validation (#7074)
soblin Jul 9, 2024
12b31ab
chore: add missing dependency (#7919)
miursh Jul 9, 2024
050fa29
fix(static_obstacle_avoidance): stop position is unstable (#7880)
satoshi-ota Jul 9, 2024
5e5ad0b
feat(blind_spot): consider road_shoulder if exist (#7925)
soblin Jul 10, 2024
6dc805e
feat(planning_evaluator,control_evaluator, evaluator utils): add diag…
danielsanchezaran Jul 10, 2024
9c559e6
refactor(image_diagnostics): fix namespace and directory structure (#…
technolojin Jul 10, 2024
b43cffb
fix(controller): revival of dry steering (#7903)
takayuki5168 Jul 10, 2024
a39cfb7
fix(autoware_behavior_velocity_no_drivable_lane_module): fix bug of u…
yhisaki Jul 10, 2024
6b9f164
fix: added temporary retrocompatibility to old perception data (#7929)
knzo25 Jul 10, 2024
fc9fce0
feat(lidar_transfusion): intensity as uint8 and tests (#7745)
amadeuszsz Jul 10, 2024
73febbd
fix(autoware_universe_utils): fix constParameterReference (#7882)
kobayu858 Jul 10, 2024
ea0276a
refactor(compare_map_segmentation)!: fix namespace and directory stru…
technolojin Jul 10, 2024
cfbf040
refactor(radar_threshold_filter): fix namespace and directory structu…
technolojin Jul 10, 2024
651d75b
refactor(radar_scan_to_pointcloud2): fix namespace and directory stru…
technolojin Jul 10, 2024
0db8f67
refactor(radar_tracks_noise_filter)!: fix namespace and directory str…
technolojin Jul 10, 2024
f2fa715
refactor(radar_static_pointcloud_filter): fix namespace and directory…
technolojin Jul 10, 2024
038a71c
feat(lidar_transfusion): update TransFusion-L model (#7890)
scepter914 Jul 10, 2024
defce44
refactor(radar)!: add package name prefix of autoware_ (#7892)
technolojin Jul 10, 2024
b1d7fcd
fix(tensorrt_common): fix shadowVariable (#7906)
kobayu858 Jul 10, 2024
08deb78
feat(tensorrt_yolox): change CMakeLists to be able to build cuda func…
MasatoSaeki Jul 10, 2024
f65af78
chore(localization, map): remove maintainer (#7940)
kminoda Jul 10, 2024
aaf465f
fix(object_merger): fix shadowVariable (#7941)
kobayu858 Jul 10, 2024
74e70b4
fix(multi_object_tracker): fix shadowVariable (#7939)
kobayu858 Jul 10, 2024
2e76976
fix(static_obstacle_avoidance): don't automatically avoid ambiguous v…
satoshi-ota Jul 10, 2024
d45a7e5
fix(lidar_apollo_segmentation_tvm): fix shadowVariable (#7938)
kobayu858 Jul 10, 2024
4cec645
test(euclidean_cluster): add unit tests (#7735)
badai-nguyen Jul 10, 2024
1a8f6f3
fix(autoware_radar_object_tracker): fix shadowVariable (#7945)
kobayu858 Jul 11, 2024
0f79b65
fix(tensorrt_yolox): fix shadowVariable (#7947)
kobayu858 Jul 11, 2024
f388b54
fix(tracking_object_merger): fix shadowVariable (#7948)
kobayu858 Jul 11, 2024
1c7e462
fix(lidar_transfusion): install lib (#7953)
amadeuszsz Jul 11, 2024
4b26093
fix(autoware_external_cmd_converter): fix check_topic_state (#7921)
shtokuda Jul 11, 2024
53bd126
feat(obstacle_cruise_planner): prevent chattering when using point cl…
mitukou1109 Jul 11, 2024
82aea7b
feat(duplicated_node_checker): add duplicate nodes to ignore (#7959)
dkoldaev Jul 11, 2024
bb2fdcd
perf(dynamic_obstacle_stop): construct rtree nodes in place (#7753)
maxime-clem Jul 11, 2024
5e8899d
fix(ci): ignore only-hpp-package in cppcheck-differential (#7961)
veqcc Jul 11, 2024
3e6b5c0
chore(perception_utils): delete maintainer (#7899)
scepter914 Jul 11, 2024
833deea
fix(tensorrt_yolox): fix cstyleCast to reinterpret_cast (#7873)
Koichi98 Jul 11, 2024
19e1945
fix(autoware_behavior_path_planner_common): fix shadowVariable (#7965)
kobayu858 Jul 11, 2024
0479f04
fix(autoware_behavior_path_sampling_planner_module): fix shadowVariab…
kobayu858 Jul 11, 2024
24aa499
fix(autoware_behavior_path_lane_change_module): fix shadowVariable (#…
kobayu858 Jul 11, 2024
9aedc68
fix(probabilistic_occupancy_grid_map): fix shadowVariable (#7942)
kobayu858 Jul 11, 2024
9f41bf1
feat(cruise_planner,planning_evaluator): add cruise and slow down dia…
danielsanchezaran Jul 11, 2024
b038006
refactor(dummy_infrastructure): rework parameters (#5275)
yuntianyi-chen Jul 11, 2024
fec446a
chore(cppcheck): delete cstyleCast from .cppcheck_suppressions (#7978)
Koichi98 Jul 12, 2024
b1eeb68
fix(autoware_behavior_velocity_intersection_module): fix shadowVariab…
kobayu858 Jul 12, 2024
18e2648
fix(autoware_motion_velocity_obstacle_velocity_limiter_module): fix s…
kobayu858 Jul 12, 2024
8c20fcc
fix(system_monitor): fix shadowVariable (#7981)
kobayu858 Jul 12, 2024
dc864d3
feat(processing_time_checker): add a new package (#7957)
takayuki5168 Jul 12, 2024
65c039d
docs(localization_error_monitor): fix input description of localizati…
SakodaShintaro Jul 12, 2024
9c94b7a
fix(system_error_monitor): fix shadowVariable (#7979)
kobayu858 Jul 12, 2024
7de0ec0
chore(autoware_universe_utils): update document (#7907)
yhisaki Jul 12, 2024
19c1d03
ci(build-and-test-differential): limit ccache size for cuda builds (#…
xmfcx Jul 12, 2024
511e5c7
fix(autoware_stop_filter): fix funcArgNamesDifferent (#8008)
kobayu858 Jul 12, 2024
f1dff45
fix(detection_by_tracker): fix funcArgNamesDifferent (#8010)
kobayu858 Jul 12, 2024
771f71d
feat(autoware_behavior_path_planner_common,autoware_behavior_path_lan…
yhisaki Jul 12, 2024
d571fc4
refactor(lane_change): update lanes and its polygons only when it's …
zulfaqar-azmi-t4 Jul 12, 2024
0a3e6d8
feat(system): create a package to monitor component containers (#7094)
mebasoglu Jul 12, 2024
2251ae5
chore: update CODEOWNERS (#7926)
awf-autoware-bot[bot] Jul 12, 2024
0d504f7
feat(velocity_smoother): add time_keeper (#8026)
takayuki5168 Jul 13, 2024
0eae67c
refactor(qp_interface): clean up the code (#8029)
takayuki5168 Jul 13, 2024
36a1d14
feat(autoware_behavior_path_planner): prevent infinite loop in approv…
kyoichi-sugahara Jul 16, 2024
544f6e7
feat(static_obstacle_avoidance): show markers when system requests op…
satoshi-ota Jul 16, 2024
13f3073
fix(object_merger): fix funcArgNamesDifferent (#8012)
kobayu858 Jul 16, 2024
a22e9c4
fix(autoware_radar_object_tracker): fix funcArgNamesDifferent (#8015)
kobayu858 Jul 16, 2024
e3aa2a3
fix(tracking_object_merger): fix funcArgNamesDifferent (#8016)
kobayu858 Jul 16, 2024
034d565
fix(autoware_mission_planner): fix funcArgNamesDifferent (#8017)
kobayu858 Jul 16, 2024
b31c9c7
fix(autoware_motion_velocity_dynamic_obstacle_stop_module): fix funcA…
kobayu858 Jul 16, 2024
77cb05c
fix(static_obstacle_avoidance): fix issues in target filtiering logic…
satoshi-ota Jul 16, 2024
3f47d51
feat(ndt_scan_matcher): warn if the lidar scan has gone out of the ra…
anhnv3991 Jul 16, 2024
ee097c5
perf(probabilistic_occupancy_grid_map): performance tuning for pointc…
taisa1 Jul 16, 2024
93f6aea
fix(predicted_path_checker): fix constParameterReference (#8038)
kobayu858 Jul 16, 2024
ea4d381
fix(image_projection_based_fusion): fix invalidPointerCast (#7927)
Koichi98 Jul 16, 2024
106625a
feat(static_obstacle_avoidance): integrate time keeper to major funct…
satoshi-ota Jul 16, 2024
e332d4f
fix(autoware_behavior_velocity_run_out_module): fix constParameterRef…
kobayu858 Jul 16, 2024
42e466a
fix(autoware_motion_velocity_out_of_lane_module): fix constParameterR…
kobayu858 Jul 16, 2024
6322d53
fix(autoware_behavior_path_planner_common): fix constParameterReferen…
kobayu858 Jul 16, 2024
aa5118c
fix(autoware_behavior_velocity_crosswalk_module): fix shadowVariable …
kobayu858 Jul 16, 2024
6bca8e8
fix(autoware_motion_velocity_obstacle_velocity_limiter_module): fix f…
kobayu858 Jul 16, 2024
a6c709e
refactor(cluster_merger): add package name prefix of autoware_ (#8001)
badai-nguyen Jul 16, 2024
a8ea14e
refactor(raindrop_cluster_filter): add package name prefix of autowar…
badai-nguyen Jul 16, 2024
6aab3e3
refactor(detection_by_tracker): add package name prefix of autoware_ …
badai-nguyen Jul 17, 2024
258b1fb
chore(cppcheck): delete invalidPointerCast from .cppcheck_suppression…
Koichi98 Jul 17, 2024
e5712a5
fix(steer_offset_estimator): fix link to json schema in README (#7655)
maxime-clem Jul 17, 2024
3c49692
fix(autoware_universe_utils): fix constVariableReference (#7883)
kobayu858 Jul 17, 2024
074a717
fix(learning_based_vehicle_model): fix constVariableReference (#8061)
kobayu858 Jul 17, 2024
df65edf
fix(mrm_handler): add check for autonomous mode and do some refactori…
danielsanchezaran Jul 17, 2024
1c80083
feat(autoware_behavior_velocity_planner_common,autoware_behavior_velo…
yhisaki Jul 17, 2024
f0efe85
fix: ml detector buffer capacity and parameterization (#7936)
knzo25 Jul 17, 2024
5212714
fix(multi_object_tracker): fix shadowVariable (#8074)
kobayu858 Jul 17, 2024
49dab18
fix(detected_object_validation): fix constParameterReference (#8075)
kobayu858 Jul 17, 2024
6e74c19
perf(dynamic_obstacle_avoidance): decrease the computation time with …
takayuki5168 Jul 17, 2024
3d566f7
feat(mrm_handler): input gear command (#8080)
veqcc Jul 18, 2024
57c6973
fix(autoware_pure_pursuit): fix shadowVariable (#7932)
kobayu858 Jul 18, 2024
b46734f
fix(autoware_map_based_prediction): fix shadowVariable (#7934)
kobayu858 Jul 18, 2024
16e19c7
fix(autoware_velocity_smoother): fix shadowVariablefix:shadowVariable…
kobayu858 Jul 18, 2024
5ba3e6e
fix(autoware_behavior_path_goal_planner_module): fix shadowVariable (…
kobayu858 Jul 18, 2024
91751d2
fix(tensorrt_common): fix constParameterReference (#8037)
kobayu858 Jul 18, 2024
9a7f886
fix(ground_segmentation): fix constParameterReference (#8039)
kobayu858 Jul 18, 2024
9413e29
fix(detected_object_validation): fix funcArgNamesDifferent (#8078)
kobayu858 Jul 18, 2024
b4947a4
fix(compare_map_segmentation): fix funcArgNamesDifferent (#8077)
kobayu858 Jul 18, 2024
2ee831e
Merge remote-tracking branch 'origin/beta/v0.31.0' into sync-upstream
rej55 Jul 18, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
7 changes: 0 additions & 7 deletions .cppcheck_suppressions
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,15 @@
checkersReport
constParameterReference
constVariableReference
// cspell: ignore cstyle
cstyleCast
funcArgNamesDifferent
functionConst
functionStatic
invalidPointerCast
knownConditionTrueFalse
missingInclude
missingIncludeSystem
noConstructor
noExplicitConstructor
noValidConfiguration
passedByValue
preprocessorErrorDirective
redundantInitialization
shadowFunction
shadowVariable
// cspell: ignore uninit
uninitMemberVar
Expand Down
61 changes: 31 additions & 30 deletions .github/CODEOWNERS

Large diffs are not rendered by default.

8 changes: 8 additions & 0 deletions .github/workflows/build-and-test-differential.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,21 @@
restore-keys: |
ccache-main-${{ runner.arch }}-${{ matrix.rosdistro }}-

# Limit ccache size only for CUDA builds to avoid running out of disk space
- name: Limit ccache size
if: ${{ matrix.container-suffix == '-cuda' }}
run: |
rm -f "${CCACHE_DIR}/ccache.conf"
echo -e "# Set maximum cache size\nmax_size = 1MB" >> "${CCACHE_DIR}/ccache.conf"
shell: bash

- name: Show ccache stats before build
run: du -sh ${CCACHE_DIR} && ccache -s
shell: bash

- name: Export CUDA state as a variable for adding to cache key
run: |
build_type_cuda_state=nocuda

Check warning on line 87 in .github/workflows/build-and-test-differential.yaml

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (nocuda)
if [[ "${{ matrix.container-suffix }}" == "-cuda" ]]; then
build_type_cuda_state=cuda
fi
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cppcheck-differential.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ jobs:
run: |
filtered_paths=""
for dir in ${{ steps.get-full-paths.outputs.full-paths }}; do
if [ -d "$dir" ] && find "$dir" -name "*.cpp" -o -name "*.hpp" | grep -q .; then
if [ -d "$dir" ] && find "$dir" -name "*.cpp" | grep -q .; then
filtered_paths="$filtered_paths $dir"
fi
done
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ struct VehicleKinematics
using Message = autoware_adapi_v1_msgs::msg::VehicleKinematics;
static constexpr char name[] = "/api/vehicle/kinematics";
static constexpr size_t depth = 1;
static constexpr auto reliability = RMW_QOS_POLICY_RELIABILITY_RELIABLE;
static constexpr auto reliability = RMW_QOS_POLICY_RELIABILITY_BEST_EFFORT;
static constexpr auto durability = RMW_QOS_POLICY_DURABILITY_VOLATILE;
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -991,34 +991,51 @@ calcCurvature<std::vector<autoware_planning_msgs::msg::TrajectoryPoint>>(
* curvature calculation
*/
template <class T>
std::vector<std::pair<double, double>> calcCurvatureAndArcLength(const T & points)
std::vector<std::pair<double, std::pair<double, double>>> calcCurvatureAndSegmentLength(
const T & points)
{
// Note that arclength is for the segment, not the sum.
std::vector<std::pair<double, double>> curvature_arc_length_vec;
curvature_arc_length_vec.emplace_back(0.0, 0.0);
// segment length is pair of segment length between {p1, p2} and {p2, p3}
std::vector<std::pair<double, std::pair<double, double>>> curvature_and_segment_length_vec;
curvature_and_segment_length_vec.reserve(points.size());
curvature_and_segment_length_vec.emplace_back(0.0, std::make_pair(0.0, 0.0));
for (size_t i = 1; i < points.size() - 1; ++i) {
const auto p1 = autoware::universe_utils::getPoint(points.at(i - 1));
const auto p2 = autoware::universe_utils::getPoint(points.at(i));
const auto p3 = autoware::universe_utils::getPoint(points.at(i + 1));
const double curvature = autoware::universe_utils::calcCurvature(p1, p2, p3);
const double arc_length =
autoware::universe_utils::calcDistance2d(points.at(i - 1), points.at(i)) +
autoware::universe_utils::calcDistance2d(points.at(i), points.at(i + 1));
curvature_arc_length_vec.emplace_back(curvature, arc_length);

// The first point has only the next point, so put the distance to that point.
// In other words, assign the first segment length at the second point to the
// second_segment_length at the first point.
if (i == 1) {
curvature_and_segment_length_vec.at(0).second.second =
autoware::universe_utils::calcDistance2d(p1, p2);
}

// The second_segment_length of the previous point and the first segment length of the current
// point are equal.
const std::pair<double, double> arc_length{
curvature_and_segment_length_vec.back().second.second,
autoware::universe_utils::calcDistance2d(p2, p3)};

curvature_and_segment_length_vec.emplace_back(curvature, arc_length);
}
curvature_arc_length_vec.emplace_back(0.0, 0.0);

return curvature_arc_length_vec;
// set to the last point
curvature_and_segment_length_vec.emplace_back(
0.0, std::make_pair(curvature_and_segment_length_vec.back().second.second, 0.0));

return curvature_and_segment_length_vec;
}

extern template std::vector<std::pair<double, double>>
calcCurvatureAndArcLength<std::vector<autoware_planning_msgs::msg::PathPoint>>(
extern template std::vector<std::pair<double, std::pair<double, double>>>
calcCurvatureAndSegmentLength<std::vector<autoware_planning_msgs::msg::PathPoint>>(
const std::vector<autoware_planning_msgs::msg::PathPoint> & points);
extern template std::vector<std::pair<double, double>>
calcCurvatureAndArcLength<std::vector<tier4_planning_msgs::msg::PathPointWithLaneId>>(
extern template std::vector<std::pair<double, std::pair<double, double>>>
calcCurvatureAndSegmentLength<std::vector<tier4_planning_msgs::msg::PathPointWithLaneId>>(
const std::vector<tier4_planning_msgs::msg::PathPointWithLaneId> & points);
extern template std::vector<std::pair<double, double>>
calcCurvatureAndArcLength<std::vector<autoware_planning_msgs::msg::TrajectoryPoint>>(
extern template std::vector<std::pair<double, std::pair<double, double>>>
calcCurvatureAndSegmentLength<std::vector<autoware_planning_msgs::msg::TrajectoryPoint>>(
const std::vector<autoware_planning_msgs::msg::TrajectoryPoint> & points);

/**
Expand Down
12 changes: 6 additions & 6 deletions common/autoware_motion_utils/src/trajectory/trajectory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -238,14 +238,14 @@ calcCurvature<std::vector<autoware_planning_msgs::msg::TrajectoryPoint>>(
const std::vector<autoware_planning_msgs::msg::TrajectoryPoint> & points);

//
template std::vector<std::pair<double, double>>
calcCurvatureAndArcLength<std::vector<autoware_planning_msgs::msg::PathPoint>>(
template std::vector<std::pair<double, std::pair<double, double>>>
calcCurvatureAndSegmentLength<std::vector<autoware_planning_msgs::msg::PathPoint>>(
const std::vector<autoware_planning_msgs::msg::PathPoint> & points);
template std::vector<std::pair<double, double>>
calcCurvatureAndArcLength<std::vector<tier4_planning_msgs::msg::PathPointWithLaneId>>(
template std::vector<std::pair<double, std::pair<double, double>>>
calcCurvatureAndSegmentLength<std::vector<tier4_planning_msgs::msg::PathPointWithLaneId>>(
const std::vector<tier4_planning_msgs::msg::PathPointWithLaneId> & points);
template std::vector<std::pair<double, double>>
calcCurvatureAndArcLength<std::vector<autoware_planning_msgs::msg::TrajectoryPoint>>(
template std::vector<std::pair<double, std::pair<double, double>>>
calcCurvatureAndSegmentLength<std::vector<autoware_planning_msgs::msg::TrajectoryPoint>>(
const std::vector<autoware_planning_msgs::msg::TrajectoryPoint> & points);

//
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,23 @@ enum ReturnType : uint8_t {
DUAL_ONLY,
};

struct PointXYZIRC
{
float x{0.0F};
float y{0.0F};
float z{0.0F};
std::uint8_t intensity{0U};
std::uint8_t return_type{0U};
std::uint16_t channel{0U};

friend bool operator==(const PointXYZIRC & p1, const PointXYZIRC & p2) noexcept
{
return float_eq<float>(p1.x, p2.x) && float_eq<float>(p1.y, p2.y) &&
float_eq<float>(p1.z, p2.z) && p1.intensity == p2.intensity &&
p1.return_type == p2.return_type && p1.channel == p2.channel;
}
};

struct PointXYZIRADRT
{
float x{0.0F};
Expand All @@ -75,25 +92,97 @@ struct PointXYZIRADRT
}
};

enum class PointIndex { X, Y, Z, Intensity, Ring, Azimuth, Distance, ReturnType, TimeStamp };
struct PointXYZIRCAEDT
{
float x{0.0F};
float y{0.0F};
float z{0.0F};
std::uint8_t intensity{0U};
std::uint8_t return_type{0U};
std::uint16_t channel{0U};
float azimuth{0.0F};
float elevation{0.0F};
float distance{0.0F};
std::uint32_t time_stamp{0U};

friend bool operator==(const PointXYZIRCAEDT & p1, const PointXYZIRCAEDT & p2) noexcept
{
return float_eq<float>(p1.x, p2.x) && float_eq<float>(p1.y, p2.y) &&
float_eq<float>(p1.z, p2.z) && p1.intensity == p2.intensity &&
p1.return_type == p2.return_type && p1.channel == p2.channel &&
float_eq<float>(p1.azimuth, p2.azimuth) && float_eq<float>(p1.distance, p2.distance) &&
p1.time_stamp == p2.time_stamp;
}
};

enum class PointXYZIIndex { X, Y, Z, Intensity };
enum class PointXYZIRCIndex { X, Y, Z, Intensity, ReturnType, Channel };
enum class PointXYZIRADRTIndex {
X,
Y,
Z,
Intensity,
Ring,
Azimuth,
Distance,
ReturnType,
TimeStamp
};
enum class PointXYZIRCAEDTIndex {
X,
Y,
Z,
Intensity,
ReturnType,
Channel,
Azimuth,
Elevation,
Distance,
TimeStamp
};

LIDAR_UTILS__DEFINE_FIELD_GENERATOR_FOR_MEMBER(azimuth);
LIDAR_UTILS__DEFINE_FIELD_GENERATOR_FOR_MEMBER(elevation);
LIDAR_UTILS__DEFINE_FIELD_GENERATOR_FOR_MEMBER(distance);
LIDAR_UTILS__DEFINE_FIELD_GENERATOR_FOR_MEMBER(return_type);
LIDAR_UTILS__DEFINE_FIELD_GENERATOR_FOR_MEMBER(time_stamp);

LIDAR_UTILS__DEFINE_FIELD_GENERATOR_FOR_MEMBER(channel);

using PointXYZIRCGenerator = std::tuple<
point_cloud_msg_wrapper::field_x_generator, point_cloud_msg_wrapper::field_y_generator,
point_cloud_msg_wrapper::field_z_generator, point_cloud_msg_wrapper::field_intensity_generator,
field_return_type_generator, field_channel_generator>;

using PointXYZIRADRTGenerator = std::tuple<
point_cloud_msg_wrapper::field_x_generator, point_cloud_msg_wrapper::field_y_generator,
point_cloud_msg_wrapper::field_z_generator, point_cloud_msg_wrapper::field_intensity_generator,
point_cloud_msg_wrapper::field_ring_generator, field_azimuth_generator, field_distance_generator,
field_return_type_generator, field_time_stamp_generator>;

using PointXYZIRCAEDTGenerator = std::tuple<
point_cloud_msg_wrapper::field_x_generator, point_cloud_msg_wrapper::field_y_generator,
point_cloud_msg_wrapper::field_z_generator, point_cloud_msg_wrapper::field_intensity_generator,
field_return_type_generator, field_channel_generator, field_azimuth_generator,
field_elevation_generator, field_distance_generator, field_time_stamp_generator>;

} // namespace autoware_point_types

POINT_CLOUD_REGISTER_POINT_STRUCT(
autoware_point_types::PointXYZIRC,
(float, x, x)(float, y, y)(float, z, z)(std::uint8_t, intensity, intensity)(
std::uint8_t, return_type, return_type)(std::uint16_t, channel, channel))

POINT_CLOUD_REGISTER_POINT_STRUCT(
autoware_point_types::PointXYZIRADRT,
(float, x, x)(float, y, y)(float, z, z)(float, intensity, intensity)(std::uint16_t, ring, ring)(
float, azimuth, azimuth)(float, distance, distance)(std::uint8_t, return_type, return_type)(
double, time_stamp, time_stamp))

POINT_CLOUD_REGISTER_POINT_STRUCT(
autoware_point_types::PointXYZIRCAEDT,
(float, x, x)(float, y, y)(float, z, z)(std::uint8_t, intensity, intensity)(
std::uint8_t, return_type,
return_type)(std::uint16_t, channel, channel)(float, azimuth, azimuth)(
float, elevation, elevation)(float, distance, distance)(std::uint32_t, time_stamp, time_stamp))
#endif // AUTOWARE_POINT_TYPES__TYPES_HPP_
9 changes: 9 additions & 0 deletions common/autoware_point_types/test/test_point_types.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,15 @@ TEST(PointEquality, PointXYZIRADRT)
EXPECT_EQ(pt0, pt1);
}

TEST(PointEquality, PointXYZIRCAEDT)
{
using autoware_point_types::PointXYZIRCAEDT;

PointXYZIRCAEDT pt0{0, 1, 2, 3, 4, 5, 6, 7, 8, 9};
PointXYZIRCAEDT pt1{0, 1, 2, 3, 4, 5, 6, 7, 8, 9};
EXPECT_EQ(pt0, pt1);
}

TEST(PointEquality, FloatEq)
{
// test template
Expand Down
25 changes: 25 additions & 0 deletions common/autoware_universe_utils/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
cmake_minimum_required(VERSION 3.14)
project(autoware_universe_utils)

option(BUILD_EXAMPLES "Build examples" OFF)

find_package(autoware_cmake REQUIRED)
autoware_package()

find_package(Boost REQUIRED)

find_package(fmt REQUIRED)

ament_auto_add_library(autoware_universe_utils SHARED
src/geometry/geometry.cpp
src/geometry/pose_deviation.cpp
Expand All @@ -16,6 +20,11 @@ ament_auto_add_library(autoware_universe_utils SHARED
src/ros/marker_helper.cpp
src/ros/logger_level_configure.cpp
src/system/backtrace.cpp
src/system/time_keeper.cpp
)

target_link_libraries(autoware_universe_utils
fmt::fmt
)

if(BUILD_TESTING)
Expand All @@ -30,4 +39,20 @@ if(BUILD_TESTING)
)
endif()

if(BUILD_EXAMPLES)
message(STATUS "Building examples")
file(GLOB_RECURSE example_files examples/*.cpp)

foreach(example_file ${example_files})
get_filename_component(example_name ${example_file} NAME_WE)
add_executable(${example_name} ${example_file})
target_link_libraries(${example_name}
autoware_universe_utils
)
install(TARGETS ${example_name}
DESTINATION lib/${PROJECT_NAME}
)
endforeach()
endif()

ament_auto_package()
Loading
Loading