ILU - (I)ntegrative (L)earning from (U)rban Data: Reinforcement Learning-based Adaptive Traffic Signal Control
This experimental project researches the development of RL-based adaptive traffic signal controllers.
This project requires the installation of the computational framework for reinforcement learning (RL) in traffic control FLOW and the RL framework acme.
Locally install the flow package. An installation guide can be found here.
-
Create a python 3 virtual environment for flow installation (tested with python 3.6.10)
virtualenv -p python3 env_flow source env_flow/bin/activate
-
Clone the FLOW-Project repository
git clone https://github.com/flow-project/flow
-
Install FLOW (checkout to 50be2d074027fb465fc4a9103b3cc09fb1123ede)
pip install -e flow/
Depending on the operating system run:
- For Ubuntu 14.04:
flow/scripts/setup_sumo_ubuntu1404.sh
- For Ubuntu 16.04:
flow/scripts/setup_sumo_ubuntu1604.sh
- For Ubuntu 18.04:
flow/scripts/setup_sumo_ubuntu1804.sh
- For Mac:
flow/scripts/setup_sumo_osx.sh
- For Ubuntu 14.04:
-
Test installation
which sumo sumo --version sumo-gui python flow/examples/simulate.py ring
Note that, if the above commands did not work, you may need to run
source ~/.bashrc
or open a new terminal to update your $PATH variable. -
Exit virtual env
deactivate
Locally install the ILU-RL package.
- Create a python 3 virtual environment for flow installation (tested with python 3.6.10)
virtualenv -p python3 env_ILU-RL source env_ILU-RL/bin/activate
- Clone the ILU-RL repository
git clone https://github.com/GAIPS/ILU-RL
- Install packages
pip install -r ILU-RL/requirements.txt pip install -e flow/ pip install -e ILU-RL/
- Install acme framework (checkout to b7340da4fbd1bde7d39a99e7379d1f2ce5e70965)
git clone https://github.com/deepmind/acme.git pip install -e acme/ pip install dm-acme[reverb] pip install dm-acme[tf] pip install dm-acme[jax]
- Export root ILU-RL directory enviroment variable (configure .bashrc file)
export ILURL_HOME=path/to/ILU-RL/root/dir
- Test installation
python ILU-RL/models/train.py