Skip to content

A large-scale traffic optimization using reinforcement learning on virtual traffic networks

License

Notifications You must be signed in to change notification settings

higotenda/landru

Repository files navigation

Introduction

Landru is a repository housing the codebase for creating and training a machine learning model that utilizes traffic simulation data for large-scale traffic optimization. The primary objectives of this project are to understand traffic patterns, predict traffic conditions, and optimize traffic flow through the application of reinforcement learning techniques on virtual traffic networks.

Goals

The overarching goals of Landru include:

  1. Understanding Traffic Patterns: Analyzing simulated traffic flow to gain insights into vehicle behavior, congestion dynamics, and potential bottlenecks.

  2. Predicting Traffic Conditions: Developing a trained model capable of forecasting future traffic states, allowing for proactive management and mitigation of congestion.

  3. Optimizing Traffic Flow: Utilizing the model's insights to design and evaluate strategies for optimizing traffic signal timing, route planning, and infrastructure improvements.

Approach

The Landru project employs the following approach:

  1. Data Collection: Utilizing OpenStreetMap (OSM) data as the primary source, we extract relevant traffic information. This involves accessing road networks, traffic signals, and other pertinent details from OSM. Subsequently, the extracted data is processed to convert it into UXSIM-compatible traffic data. This process ensures compatibility and alignment with the simulation framework while retaining the integrity and accuracy of the original data.

  2. Model Training: Training a machine learning model using reinforcement learning techniques to understand and predict traffic patterns.

  3. Evaluation: Assessing the model's performance in predicting traffic conditions and optimizing traffic flow through simulation-based experiments.

  4. Deployment: Integrating the trained model into real-world traffic management systems for practical applications.

Dependencies

The Landru project relies on the following libraries, frameworks, and tools:

  1. UXSim: This library serves as the foundation for traffic simulation, providing essential functionalities for modeling traffic scenarios, including vehicle movement, traffic signals, and road networks.

  2. Tianshou: Tianshou is utilized as the core framework for implementing reinforcement learning algorithms. It provides a comprehensive set of tools and utilities for building and training reinforcement learning agents. In the context of Landru, Tianshou forms the basis for developing an intelligent agent capable of learning and optimizing traffic flow in real-time based on collected data.

Demo

This demonstration showcases the traffic flow optimization achieved through the Gradio application. It illustrates the effective management and optimization of traffic flow for enhanced efficiency. Demo Image

Usage

Getting Started

Follow these steps to set up the project:

  1. Clone the Repository:

    git clone https://github.com/higotenda/landru.git
  2. Create a Directory: Create a directory named "osm" in the root directory.

  3. Create a CSV File: Create a new CSV file named "raw_demands.csv" in the root directory.

  4. Run the Script: Run the view.py file, and the Gradio interface will start working.

To utilize Landru for traffic optimization, follow these steps:

  1. Clone the repository to your local environment.
  2. Install the necessary dependencies listed in the documentation.
  3. Explore the provided examples to understand the workflow and usage of the model.
  4. Customize the codebase and model parameters according to your specific requirements.
  5. Train the model using your own traffic simulation data.
  6. Evaluate the trained model's performance and fine-tune as necessary.
  7. Deploy the optimized traffic management strategies in real-world scenarios.

Conclusion

Landru aims to revolutionize traffic management by leveraging machine learning and reinforcement learning techniques to understand, predict, and optimize traffic flow. By utilizing simulated traffic data and advanced modeling approaches, Landru has the potential to significantly reduce congestion, improve transportation efficiency, and enhance overall urban mobility.

About

A large-scale traffic optimization using reinforcement learning on virtual traffic networks

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •