Giter Site home page Giter Site logo
DeTraffic logo

DeTraffic

DeTraffic is a multi-agent deep reinforcement learning model to de-traffic our lives.

Table Of Contents

  1. Installation
  2. Development
  3. Running experiments
  4. Acknowledgement
  5. License

Installation

SUMO

You have to install SUMO beforehand.

sudo add-apt-repository ppa:sumo/stable
sudo apt-get update
sudo apt-get install sumo sumo-tools sumo-doc

Don't forget to set SUMO_HOME variable (default sumo installation path is /usr/share/sumo)

echo 'export SUMO_HOME="/usr/share/sumo"' >> ~/.bashrc
source ~/.bashrc

Important: for a huge performance boost (~8x) with Libsumo, you can declare the variable:

export LIBSUMO_AS_TRACI=1

Notice that you will not be able to run with sumo-gui or with multiple simulations in parallel if this is active (more details).

DeTraffic

If you do not have poetry installed:

pip install poetry

For testing:

poetry install --without-dev # for newer versions of poetry
poetry install --no-dev # for older versions of poetry

For development purposes:

poetry install

And then you can dive into the environment with:

poetry shell

Development

After the installation, there are several steps to follow for development.

pdoc

pre-commit

pre-commit install

pytest

mypy

ruff

refurb

Running experiments

You can check predefined experiments at experiments and models at models, or define your own experiments or models.

poetry shell
python detraffic/benchmark.py

Acknowledgement

This repository contains code from PyTorch Reinforcement Learning (DQN) Tutorial and efficient-kan. Also containts SUMO installation steps from sumo-rl.

detraffic's Projects

detraffic icon detraffic

A multi-agent deep reinforcement learning model to de-traffic our lives

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.