Skip to content

Commit 83d146c

Browse files
committed
Merge branch 'main' into feature/simulator_py_model
2 parents 2f4ca6d + efe4e16 commit 83d146c

File tree

92 files changed

+1810
-5223
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

92 files changed

+1810
-5223
lines changed

.github/CODEOWNERS

+3-3
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ evaluator/kinematic_evaluator/** dominik.jargot@robotec.ai fumiya.watanabe@tier4
7777
evaluator/localization_evaluator/** dominik.jargot@robotec.ai koji.minoda@tier4.jp
7878
evaluator/perception_online_evaluator/** fumiya.watanabe@tier4.jp kosuke.takeuchi@tier4.jp kotaro.uetake@tier4.jp kyoichi.sugahara@tier4.jp shunsuke.miura@tier4.jp yoshi.ri@tier4.jp
7979
evaluator/planning_evaluator/** kyoichi.sugahara@tier4.jp maxime.clement@tier4.jp
80-
evaluator/tier4_metrics_rviz_plugin/** kyoichi.sugahara@tier4.jp maxime.clement@tier4.jp satoshi.ota@tier4.jp
80+
evaluator/tier4_metrics_rviz_plugin/** fumiya.watanabe@tier4.jp kosuke.takeuchi@tier4.jp kyoichi.sugahara@tier4.jp maxime.clement@tier4.jp satoshi.ota@tier4.jp
8181
launch/tier4_autoware_api_launch/** isamu.takagi@tier4.jp ryohsuke.mitsudome@tier4.jp
8282
launch/tier4_control_launch/** takamasa.horibe@tier4.jp takayuki.murooka@tier4.jp
8383
launch/tier4_localization_launch/** anh.nguyen.2@tier4.jp kento.yabuuchi.2@tier4.jp koji.minoda@tier4.jp masahiro.sakamoto@tier4.jp ryu.yamamoto@tier4.jp shintaro.sakoda@tier4.jp taiki.yamada@tier4.jp yamato.ando@tier4.jp
@@ -121,7 +121,7 @@ perception/detected_object_feature_remover/** tomoya.kimura@tier4.jp
121121
perception/detected_object_validation/** dai.nguyen@tier4.jp shintaro.tomie@tier4.jp shunsuke.miura@tier4.jp yukihiro.saito@tier4.jp
122122
perception/detection_by_tracker/** taekjin.lee@tier4.jp yoshi.ri@tier4.jp yukihiro.saito@tier4.jp
123123
perception/elevation_map_loader/** kosuke.takeuchi@tier4.jp shintaro.tomie@tier4.jp taichi.higashide@tier4.jp
124-
perception/euclidean_cluster/** yukihiro.saito@tier4.jp
124+
perception/euclidean_cluster/** dai.nguyen@tier4.jp yukihiro.saito@tier4.jp
125125
perception/ground_segmentation/** abrahammonrroy@yahoo.com dai.nguyen@tier4.jp shunsuke.miura@tier4.jp yukihiro.saito@tier4.jp
126126
perception/image_projection_based_fusion/** dai.nguyen@tier4.jp koji.minoda@tier4.jp kotaro.uetake@tier4.jp shunsuke.miura@tier4.jp tao.zhong@tier4.jp yoshi.ri@tier4.jp yukihiro.saito@tier4.jp
127127
perception/lidar_apollo_instance_segmentation/** yukihiro.saito@tier4.jp
@@ -212,7 +212,7 @@ sensing/image_diagnostics/** dai.nguyen@tier4.jp
212212
sensing/image_transport_decompressor/** yukihiro.saito@tier4.jp
213213
sensing/imu_corrector/** koji.minoda@tier4.jp taiki.yamada@tier4.jp yamato.ando@tier4.jp
214214
sensing/livox/livox_tag_filter/** ryohsuke.mitsudome@tier4.jp
215-
sensing/pointcloud_preprocessor/** abrahammonrroy@yahoo.com kyoichi.sugahara@tier4.jp shunsuke.miura@tier4.jp yukihiro.saito@tier4.jp
215+
sensing/pointcloud_preprocessor/** abrahammonrroy@yahoo.com dai.nguyen@tier4.jp kyoichi.sugahara@tier4.jp shunsuke.miura@tier4.jp yukihiro.saito@tier4.jp
216216
sensing/radar_scan_to_pointcloud2/** satoshi.tanaka@tier4.jp shunsuke.miura@tier4.jp taekjin.lee@tier4.jp yoshi.ri@tier4.jp
217217
sensing/radar_static_pointcloud_filter/** satoshi.tanaka@tier4.jp shunsuke.miura@tier4.jp taekjin.lee@tier4.jp yoshi.ri@tier4.jp
218218
sensing/radar_threshold_filter/** satoshi.tanaka@tier4.jp shunsuke.miura@tier4.jp taekjin.lee@tier4.jp yoshi.ri@tier4.jp

.github/workflows/build-and-test-self-hosted.yaml .github/workflows/build-and-test-arm64.yaml

+9-3
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
name: build-and-test-self-hosted
1+
name: build-and-test-arm64
22

33
on:
44
schedule:
55
- cron: 0 0 * * *
66
workflow_dispatch:
77

88
jobs:
9-
build-and-test-self-hosted:
9+
build-and-test-arm64:
1010
runs-on: [self-hosted, linux, ARM64]
1111
container: ${{ matrix.container }}${{ matrix.container-suffix }}
1212
strategy:
@@ -19,12 +19,15 @@ jobs:
1919
- -cuda
2020
include:
2121
- rosdistro: humble
22-
container: ghcr.io/autowarefoundation/autoware-universe:humble-latest
22+
container: ghcr.io/autowarefoundation/autoware-openadk:latest-prebuilt
2323
build-depends-repos: build_depends.repos
2424
steps:
2525
- name: Check out repository
2626
uses: actions/checkout@v3
2727

28+
- name: Show disk space before the tasks
29+
run: df -h
30+
2831
- name: Remove exec_depend
2932
uses: autowarefoundation/autoware-github-actions/remove-exec-depend@v1
3033

@@ -47,3 +50,6 @@ jobs:
4750
rosdistro: ${{ matrix.rosdistro }}
4851
target-packages: ${{ steps.get-self-packages.outputs.self-packages }}
4952
build-depends-repos: ${{ matrix.build-depends-repos }}
53+
54+
- name: Show disk space after the tasks
55+
run: df -h

.github/workflows/build-and-test-differential-self-hosted.yaml .github/workflows/build-and-test-differential-arm64.yaml

+10-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: build-and-test-differential-self-hosted
1+
name: build-and-test-differential-arm64
22

33
on:
44
pull_request:
@@ -12,9 +12,9 @@ jobs:
1212
prevent-no-label-execution:
1313
uses: autowarefoundation/autoware-github-actions/.github/workflows/prevent-no-label-execution.yaml@v1
1414
with:
15-
label: ARM64
15+
label: type:arm64
1616

17-
build-and-test-differential-self-hosted:
17+
build-and-test-differential-arm64:
1818
needs: prevent-no-label-execution
1919
if: ${{ needs.prevent-no-label-execution.outputs.run == 'true' }}
2020
runs-on: [self-hosted, linux, ARM64]
@@ -29,14 +29,17 @@ jobs:
2929
- -cuda
3030
include:
3131
- rosdistro: humble
32-
container: ghcr.io/autowarefoundation/autoware-universe:humble-latest
32+
container: ghcr.io/autowarefoundation/autoware-openadk:latest-prebuilt
3333
build-depends-repos: build_depends.repos
3434
steps:
3535
- name: Check out repository
3636
uses: actions/checkout@v3
3737
with:
3838
fetch-depth: 0
3939

40+
- name: Show disk space before the tasks
41+
run: df -h
42+
4043
- name: Remove exec_depend
4144
uses: autowarefoundation/autoware-github-actions/remove-exec-depend@v1
4245

@@ -59,3 +62,6 @@ jobs:
5962
rosdistro: ${{ matrix.rosdistro }}
6063
target-packages: ${{ steps.get-modified-packages.outputs.modified-packages }}
6164
build-depends-repos: ${{ matrix.build-depends-repos }}
65+
66+
- name: Show disk space after the tasks
67+
run: df -h

.github/workflows/build-and-test-differential.yaml

+5-4
Original file line numberDiff line numberDiff line change
@@ -16,26 +16,27 @@ jobs:
1616
build-and-test-differential:
1717
needs: prevent-no-label-execution
1818
if: ${{ needs.prevent-no-label-execution.outputs.run == 'true' }}
19-
runs-on: [self-hosted, linux, X64]
19+
runs-on: ubuntu-latest
2020
container: ${{ matrix.container }}${{ matrix.container-suffix }}
2121
strategy:
2222
fail-fast: false
2323
matrix:
2424
rosdistro:
2525
- humble
2626
container-suffix:
27+
- ""
2728
- -cuda
2829
include:
2930
- rosdistro: humble
30-
container: ghcr.io/autowarefoundation/autoware-universe:humble-latest
31+
container: ghcr.io/autowarefoundation/autoware-openadk:latest-prebuilt
3132
build-depends-repos: build_depends.repos
3233
steps:
3334
- name: Check out repository
3435
uses: actions/checkout@v3
3536
with:
3637
fetch-depth: 0
3738

38-
- name: Check disk space before build
39+
- name: Show disk space before the tasks
3940
run: df -h
4041

4142
- name: Remove exec_depend
@@ -71,5 +72,5 @@ jobs:
7172
verbose: true
7273
flags: differential
7374

74-
- name: Check disk space after build
75+
- name: Show disk space after the tasks
7576
run: df -h

.github/workflows/build-and-test.yaml

+8-2
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99
jobs:
1010
build-and-test:
1111
if: ${{ github.event_name != 'push' || github.ref_name == github.event.repository.default_branch }}
12-
runs-on: [self-hosted, linux, X64]
12+
runs-on: ubuntu-latest
1313
container: ${{ matrix.container }}${{ matrix.container-suffix }}
1414
strategy:
1515
fail-fast: false
@@ -21,12 +21,15 @@ jobs:
2121
- -cuda
2222
include:
2323
- rosdistro: humble
24-
container: ghcr.io/autowarefoundation/autoware-universe:humble-latest
24+
container: ghcr.io/autowarefoundation/autoware-openadk:latest-prebuilt
2525
build-depends-repos: build_depends.repos
2626
steps:
2727
- name: Check out repository
2828
uses: actions/checkout@v3
2929

30+
- name: Show disk space before the tasks
31+
run: df -h
32+
3033
- name: Remove exec_depend
3134
uses: autowarefoundation/autoware-github-actions/remove-exec-depend@v1
3235

@@ -59,3 +62,6 @@ jobs:
5962
fail_ci_if_error: false
6063
verbose: true
6164
flags: total
65+
66+
- name: Show disk space after the tasks
67+
run: df -h

control/mpc_lateral_controller/src/mpc.cpp

+5-1
Original file line numberDiff line numberDiff line change
@@ -355,12 +355,15 @@ std::pair<bool, VectorXd> MPC::updateStateForDelayCompensation(
355355
MatrixXd Wd(DIM_X, 1);
356356
MatrixXd Cd(DIM_Y, DIM_X);
357357

358+
const double sign_vx = m_is_forward_shift ? 1 : -1;
359+
358360
MatrixXd x_curr = x0_orig;
359361
double mpc_curr_time = start_time;
360362
for (size_t i = 0; i < m_input_buffer.size(); ++i) {
361363
double k, v = 0.0;
362364
try {
363-
k = interpolation::lerp(traj.relative_time, traj.k, mpc_curr_time);
365+
// NOTE: When driving backward, the curvature's sign should be reversed.
366+
k = interpolation::lerp(traj.relative_time, traj.k, mpc_curr_time) * sign_vx;
364367
v = interpolation::lerp(traj.relative_time, traj.vx, mpc_curr_time);
365368
} catch (const std::exception & e) {
366369
RCLCPP_ERROR(m_logger, "mpc resample failed at delay compensation, stop mpc: %s", e.what());
@@ -446,6 +449,7 @@ MPCMatrix MPC::generateMPCMatrix(
446449
const double ref_vx = reference_trajectory.vx.at(i);
447450
const double ref_vx_squared = ref_vx * ref_vx;
448451

452+
// NOTE: When driving backward, the curvature's sign should be reversed.
449453
const double ref_k = reference_trajectory.k.at(i) * sign_vx;
450454
const double ref_smooth_k = reference_trajectory.smooth_k.at(i) * sign_vx;
451455

control/mpc_lateral_controller/src/mpc_lateral_controller.cpp

+5-1
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,11 @@ trajectory_follower::LateralOutput MpcLateralController::run(
243243
Trajectory predicted_traj;
244244
Float32MultiArrayStamped debug_values;
245245

246-
if (!m_is_ctrl_cmd_prev_initialized) {
246+
const bool is_under_control = input_data.current_operation_mode.is_autoware_control_enabled &&
247+
input_data.current_operation_mode.mode ==
248+
autoware_adapi_v1_msgs::msg::OperationModeState::AUTONOMOUS;
249+
250+
if (!m_is_ctrl_cmd_prev_initialized || !is_under_control) {
247251
m_ctrl_cmd_prev = getInitialControlCommand();
248252
m_is_ctrl_cmd_prev_initialized = true;
249253
}

evaluator/perception_online_evaluator/include/perception_online_evaluator/metrics_calculator.hpp

+4-3
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
#include "perception_online_evaluator/metrics/metric.hpp"
2020
#include "perception_online_evaluator/parameters.hpp"
2121
#include "perception_online_evaluator/stat.hpp"
22+
#include "perception_online_evaluator/utils/objects_filtering.hpp"
2223

2324
#include <rclcpp/time.hpp>
2425

@@ -118,9 +119,9 @@ class MetricsCalculator
118119
void deleteOldObjects(const rclcpp::Time stamp);
119120

120121
// Calculate metrics
121-
MetricStatMap calcLateralDeviationMetrics(const PredictedObjects & objects) const;
122-
MetricStatMap calcYawDeviationMetrics(const PredictedObjects & objects) const;
123-
MetricStatMap calcPredictedPathDeviationMetrics(const PredictedObjects & objects) const;
122+
MetricStatMap calcLateralDeviationMetrics(const ClassObjectsMap & class_objects_map) const;
123+
MetricStatMap calcYawDeviationMetrics(const ClassObjectsMap & class_objects_map) const;
124+
MetricStatMap calcPredictedPathDeviationMetrics(const ClassObjectsMap & class_objects_map) const;
124125
Stat<double> calcPredictedPathDeviationMetrics(
125126
const PredictedObjects & objects, const double time_horizon) const;
126127

evaluator/perception_online_evaluator/include/perception_online_evaluator/utils/objects_filtering.hpp

+10
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,8 @@ using autoware_auto_perception_msgs::msg::ObjectClassification;
3737
using autoware_auto_perception_msgs::msg::PredictedObject;
3838
using autoware_auto_perception_msgs::msg::PredictedObjects;
3939

40+
using ClassObjectsMap = std::unordered_map<uint8_t, PredictedObjects>;
41+
4042
std::uint8_t getHighestProbLabel(const std::vector<ObjectClassification> & classification);
4143

4244
/**
@@ -105,6 +107,14 @@ void filterObjects(PredictedObjects & objects, Func filter)
105107
filterObjects(objects, removed_objects, filter);
106108
}
107109

110+
/**
111+
* @brief Separates the provided objects based on their classification.
112+
*
113+
* @param objects The predicted objects to be separated.
114+
* @return A map of objects separated by their classification.
115+
*/
116+
ClassObjectsMap separateObjectsByClass(const PredictedObjects & objects);
117+
108118
/**
109119
* @brief Filters the provided objects based on their classification.
110120
*

evaluator/perception_online_evaluator/package.xml

+1
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
<depend>libgoogle-glog-dev</depend>
2525
<depend>motion_utils</depend>
2626
<depend>nav_msgs</depend>
27+
<depend>object_recognition_utils</depend>
2728
<depend>pluginlib</depend>
2829
<depend>rclcpp</depend>
2930
<depend>rclcpp_components</depend>

0 commit comments

Comments
 (0)