Metadata-Version: 2.1
Name: commonroad-reach
Version: 2025.2.1
Summary: A Toolbox for Computing Reachable Sets of Automated Vehicles
Keywords: autonomous vehicles,automated driving,motion planning,reachability analysis
Author-Email: Cyber-Physical Systems Group - Technical University of Munich <commonroad@lists.lrz.de>
License: Copyright (c) 2021, Cyber-Physical Systems Group, Technical University of Munich.
         All rights reserved.
         
         Redistribution and use in source and binary forms, with or without
         modification, are permitted provided that the following conditions are
         met:
         
             * Redistributions of source code must retain the above copyright
                notice, this list of conditions and the following disclaimer.
         
             * Redistributions in binary form must reproduce the above
                copyright notice, this list of conditions and the following
                disclaimer in the documentation and/or other materials provided
                with the distribution.
         
             * Neither the name of the copyright holder nor the names of its
                contributors may be used to endorse or promote products derived
                from this software without specific prior written permission.
         
         THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
         "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
         LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
         A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
         OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
         SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
         LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
         DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
         THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
         (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
         OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
         
Classifier: Programming Language :: C++
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: License :: OSI Approved :: BSD License
Classifier: Operating System :: POSIX :: Linux
Project-URL: Homepage, https://commonroad.in.tum.de/tools/commonroad-reach
Project-URL: Documentation, https://commonroad.in.tum.de/docs/commonroad-reach/
Project-URL: Forum, https://commonroad.in.tum.de/forum/c/commonroad-reach/19
Project-URL: Source, https://gitlab.lrz.de/tum-cps/commonroad-reach
Requires-Python: <3.12,>=3.10
Requires-Dist: commonroad-io>=2024.1
Requires-Dist: commonroad-route-planner>=2025.1.0
Requires-Dist: commonroad-drivability-checker>=2025.4.0
Requires-Dist: commonroad-clcs>=2025.2.0
Requires-Dist: cython>=3.0
Requires-Dist: imageio>=2.9
Requires-Dist: matplotlib>=3.3
Requires-Dist: networkx>=3.0
Requires-Dist: numpy>=1.19
Requires-Dist: omegaconf>=2.1
Requires-Dist: opencv-python>=4.5
Requires-Dist: scipy>=1.4
Requires-Dist: seaborn>=0.10
Requires-Dist: shapely>=2.0
Provides-Extra: test
Requires-Dist: pytest>=3.8.0; extra == "test"
Provides-Extra: docs
Requires-Dist: Sphinx>=4.5.0; extra == "docs"
Requires-Dist: sphinx-autodoc-typehints>=1.18.1; extra == "docs"
Requires-Dist: sphinx-rtd-theme>=2.0.0; extra == "docs"
Requires-Dist: m2r2>=0.3.0; extra == "docs"
Requires-Dist: docutils<0.21,>=0.18.1; extra == "docs"
Provides-Extra: build
Requires-Dist: scikit-build-core~=0.11.0; extra == "build"
Requires-Dist: nanobind~=2.2.0; extra == "build"
Requires-Dist: pathspec>=0.12.1; extra == "build"
Requires-Dist: pyproject-metadata>=0.7.1; extra == "build"
Requires-Dist: typing_extensions~=4.12.2; extra == "build"
Requires-Dist: cmake<4.0,>=3.24; extra == "build"
Description-Content-Type: text/markdown

# CommonRoad-Reach: A Toolbox for Reachability Analysis of Automated Vehicles

Reachability analysis has gained increasing popularity in motion planning and safeguarding of automated vehicles (AVs). 
While existing tools for reachability analysis mainly focus on general-purpose algorithms for formal verification 
of dynamical systems, a toolbox tailored to AV-specific applications is not yet available. 
The CommonRoad-Reach toolbox

- integrates different methods for computing reachable sets using polytopic set propagation and graph-based propagation;
- provides Python and C++ implementations of the algorithms, thus offering convenient prototyping and real-time computation for the users; and
- extracts driving corridors which can be used as planning constraints for motion planners.


## System Requirements

The software is written in Python 3.10 and C++17, and was tested on Ubuntu 18.04, 20.04 and 22.04.
It should be compatible with later versions.
For building the code, the following minimum versions are required:
  * **GCC and G++**: version 10 or above
  * **CMake**: version 3.20 or above.
  * **Pip**: version 21.3 or above

We further recommend using [Anaconda](https://www.anaconda.com/) to manage your virtual python environment.


## Installation options

We provide two installation options for CommonRoad-Reach: Installation as a Python package or building from source.

1. **Python Package**: Install the python package via `pip` in your Conda environment:
    ```bash
    pip install commonroad-reach
    ```

2. **Build from source**: To build the project from source and install it in your Conda environment, please refer to the [README_FOR_DEVS](./README_FOR_DEVS.md).
This option is only recommended for advanced users and those who are looking to contribute to the development of CommonRoad-Reach.

## Getting Started

Run the exemplary scripts to compute reachable sets and extract driving corridors.

* To compute reachable sets, run `compute_reachable_set.py`.

* To extract driving corridors, run `extract_driving_corridors.py`.

The outputs will be stored in the `./output/` folder. Default and scenario-specific configurations are stored in the `./configurations/` folder.


## Documentation

The documentation of our toolbox is available on our website: https://cps.pages.gitlab.lrz.de/commonroad/commonroad-reachable-set/.

In order to generate the documentation via Sphinx locally, run the following commands in the root directory:

```bash
pip install -r ./docs/requirements_doc.txt
cd docs/Sphinx
make html
```

The documentation can then be launched by browsing ``./docs/Sphinx/build/html/index.html/``.


## Citation
If you use our toolbox for your research, please cite our [paper](https://mediatum.ub.tum.de/doc/1684928/1684928.pdf):

```text
@InProceedings{iraniliu2022commonroad,
      title     = {{CommonRoad-Reach}: {A} toolbox for reachability analysis of automated vehicles},
      author    = {Irani Liu, Edmond and W\"ursching, Gerald and Klischat, Moritz and Althoff, Matthias},
      booktitle = {Proc. of the IEEE Int. Conf. Intell. Transp. Syst.},
      pages     = {2313--2320},
      year      = {2022},
   }
```
