|
trajectory_optimization v1.3.1
|
ROS 2 Trajectory Optimization for Automated Driving based on an Optimal Control Problem (OCP).
This repository provides a ROS 2 node for periodically solving a nonlinear optimal control problem to generate optimized trajectories for automated driving. The goal of the OCP is to follow a reference trajectory while respecting the dynamics of a given vehicle model and optimizing with respect to a configured cost function, all while not violating defined constraints such as collision avoidance and road boundaries. This results in a drivable trajectory that fulfils all these requirements.
The open-source framework acados is used to define the OCP and generate the libraries for solving it online in the ROS 2 node. Key features:
The ROS 2 node uses the open-source ROS 2 message definitions perception_interfaces and planning_interfaces for all inputs and outputs, making it easy to integrate into a larger ROS 2-based system. The node is designed to be flexible and configurable, with support for different driving modes, model variants, and execution modes.
🚀 Quick Start • 💻 Development • 📝 Documentation
Run the ready-made demo setup from demo, which starts the trajectory optimization together with dummy input generation, RViz and RQt. You can use the dynamic reconfigure options in RQt to change the parameters of the running nodes and see the effect on the generated trajectories in RViz.
Ctrl+C
docker compose downxhost -local: # revoke GUI forwarding permissions
.openads-dev-environment submodule containing development environment configuration. Ctrl+Shift+P / Extensions: Show Recommended Extensions / Install Workspace Recommended Extensions (Cloud Download Icon)
Ctrl+Shift+B
Ctrl+Shift+P / Tasks: Run Test Task
Package and node interfaces are documented in the respective package READMEs listed below. Implementation details are found in the Source Code Documentation.
| Package | Description |
|---|---|
| dummy_input_generation | Generates and publishes dummy input data for testing purposes of the trajectory optimization node. |
| trajectory_optimization | Periodically solves a nonlinear OCP to generate optimized trajectories for automated driving. |
| trajectory_optimization_ocp | Defines the OCP for trajectory optimization and generates the corresponding C code headers/libraries, which are then used by trajectory_optimization. |
The source code in this repository is licensed under Apache-2.0, see [LICENSE](LICENSE). Container images provided by this repository may contain third-party software shipped with their own license terms.
Development and maintenance of this repository are supported by the following projects. We acknowledge the funding of the respective institutions.
| Project | Funding Institution | Grant Number |
|---|---|---|
| AIGGREGATE | 🇪🇺 European Union | 101202457 |
| AIthena | 🇪🇺 European Union | 101076754 |
| autotech.agil | 🇩🇪 Federal Ministry for Research, Technology and Space (BMFTR) | 01IS22088A |
Funded by the European Union. Views and opinions expressed are however those of the author(s) only and do not necessarily reflect those of the European Union or the European Climate, Infrastructure and Environment Executive Agency (CINEA). Neither the European Union nor CINEA can be held responsible for them.