forked from autowarefoundation/autoware.universe
-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fe85e3c
commit 3c94a64
Showing
208 changed files
with
6,432 additions
and
7,780 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
39 changes: 39 additions & 0 deletions
39
...d_converter/src/vehicle_adaptor/autoware_vehicle_adaptor/.github/actions/setup/action.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: setup environment | ||
description: setup environment for CI and install dependencies | ||
|
||
runs: | ||
using: "composite" | ||
steps: | ||
- name: checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: install dependencies | ||
run: > | ||
sudo apt-get -qq update && | ||
sudo apt-get -qq install -y | ||
software-properties-common && | ||
sudo add-apt-repository ppa:deadsnakes/ppa && | ||
sudo apt-get -qq update && | ||
sudo apt-get -qq install -y | ||
cmake | ||
jq | ||
gcc | ||
libyaml-cpp-dev | ||
python3.10 | ||
python3.10-venv | ||
python3-pip | ||
python3-pybind11 | ||
shell: bash | ||
|
||
- name: install eigen 3.4.0 | ||
run: | | ||
sudo bash .github/scripts/install_eigen.sh | ||
shell: bash | ||
|
||
- name: installation of this repository | ||
run: sudo pip3 install . | ||
shell: bash | ||
|
||
- name: install pip packages | ||
run: pip3 install -r requirements.txt | ||
shell: bash |
66 changes: 66 additions & 0 deletions
66
...d_converter/src/vehicle_adaptor/autoware_vehicle_adaptor/.github/scripts/install_eigen.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
#!/bin/bash | ||
|
||
function log() | ||
{ | ||
echo "::${1}::${*:2}" | ||
} | ||
|
||
function warning() | ||
{ | ||
log warning "${*}" | ||
} | ||
|
||
function debug() | ||
{ | ||
log debug "${*}" | ||
} | ||
|
||
version="3.4.0" | ||
project_id=15462818 | ||
gitlab="https://gitlab.com/api/v4/projects" | ||
|
||
releases=$(curl -s "${gitlab}/${project_id}/releases" | jq -cr '.[].tag_name') | ||
latest=$(echo "${releases}" | head -n 1) | ||
|
||
if [[ "${version}" == "latest" ]] | ||
then | ||
version=${latest} | ||
debug "Found ${version} latest release" | ||
elif ! grep -q "${version}" <<< "${releases}" | ||
then | ||
warning "Not found ${version} release" | ||
version=${latest} | ||
fi | ||
|
||
debug "Installing ${version} release..." | ||
|
||
release_source=$(curl -s "${gitlab}/${project_id}/releases/${version}" | jq -rc '.assets.sources[] | select( .format == "tar.gz" ).url') | ||
|
||
if ! command -v wget &> /dev/null | ||
then | ||
curl -L "${release_source}" | tar -xvz > /dev/null | ||
else | ||
wget -qO- "${release_source}" | tar -xvz > /dev/null | ||
fi | ||
|
||
eigen_install_dir="/usr" | ||
eigen_dir="eigen-${version}" | ||
|
||
cmake -E make_directory build | ||
cmake "${eigen_dir}" -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX="${eigen_install_dir}" -DEIGEN_BUILD_PKGCONFIG=ON | ||
cmake --install . --config Release | ||
|
||
cmake_module_path="${eigen_install_dir}/share/eigen3/cmake" | ||
pkg_config_path="${eigen_install_dir}/share/pkgconfig" | ||
|
||
# shellcheck disable=SC2046 | ||
cp $(ls -d "${eigen_dir}"/cmake/*.cmake) "${cmake_module_path}" | ||
|
||
{ | ||
echo "Eigen3_DIR=${cmake_module_path}" | ||
echo "Eigen3_Dir=${cmake_module_path}" | ||
echo "PKG_CONFIG_PATH=${pkg_config_path}" | ||
} >> "${GITHUB_ENV}" | ||
|
||
|
||
debug "Successfully setup Eigen3 of ${version} version" |
69 changes: 69 additions & 0 deletions
69
...hicle_cmd_converter/src/vehicle_adaptor/autoware_vehicle_adaptor/.github/workflows/ci.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
# see: https://github.com/rami3l/plfl/blob/master/.github/workflows/ci.yml | ||
name: CI | ||
|
||
# https://docs.github.com/en/actions/using-jobs/using-concurrency#example-only-cancel-in-progress-jobs-or-runs-for-the-current-workflow | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
push: | ||
branches: | ||
- main | ||
workflow_dispatch: | ||
|
||
jobs: | ||
build_test: | ||
runs-on: self-hosted | ||
steps: | ||
- name: checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: setup and install dependencies | ||
uses: ./.github/actions/setup | ||
|
||
- name: test for building `vehicle_adaptor_compensator.cpp` | ||
run: python3 build_test.py | ||
|
||
- name: test for building `actuation_map_2d.cpp` | ||
run: python3 build_actuation_map_2d_test.py | ||
|
||
run_simulator: | ||
runs-on: self-hosted | ||
needs: build_test | ||
steps: | ||
- name: checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: setup and install dependencies | ||
uses: ./.github/actions/setup | ||
|
||
- name: test for python simulator | ||
run: | | ||
cd autoware_vehicle_adaptor/python_simulator | ||
python3 run_vehicle_adaptor.py | ||
cd ../.. | ||
- name: test for calibration simulator | ||
run: | | ||
cd autoware_vehicle_adaptor/python_simulator | ||
python3 run_accel_brake_map_calibrator.py | ||
cd ../.. | ||
- name: Get current date and time | ||
env: | ||
TZ: "Asia/Tokyo" | ||
id: date | ||
run: echo "date=$(date +'%Y-%m-%d-%H-%M')" >> $GITHUB_OUTPUT | ||
|
||
- name: upload log to artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: "${{ steps.date.outputs.date }}-log-data" | ||
path: "autoware_vehicle_adaptor/python_simulator/log_data/" | ||
# artifact は一週間だけ保持 | ||
retention-days: 7 | ||
if-no-files-found: warn |
Oops, something went wrong.