Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
65 commits
Select commit Hold shift + click to select a range
c04be7e
fix(cosim): add SUMO_HOME config and fix CoScenarioManager initializa…
lgcyaxi Nov 16, 2025
ca4fb05
feat(sumo-marl): implement SUMO pre-training with CARLA fine-tuning p…
lgcyaxi Nov 16, 2025
e7e68f0
fix(sumo): improve vtype mapping and SUMO GUI auto-start
lgcyaxi Nov 17, 2025
d274d11
refactor(sumo): relocate SUMO assets to opencda_marl and improve inte…
lgcyaxi Nov 17, 2025
5e153fe
fix(marl): improve SUMO integration and agent ID handling
lgcyaxi Nov 17, 2025
2016e39
feat(sumo): integrate MARLTrafficManager with SUMO adapter layer
lgcyaxi Nov 17, 2025
d5af896
fix(sumo): improve network topology and intersection center detection
lgcyaxi Nov 17, 2025
15af86c
feat(sumo): implement CARLA-SUMO coordinate transformation system
lgcyaxi Nov 18, 2025
e508383
refactor(sumo): simplify vehicle type handling to use SUMO defaults
lgcyaxi Nov 18, 2025
d154e1c
feat(sumo): improve edge compatibility checking for vehicle spawning
lgcyaxi Nov 18, 2025
f449389
fix(sumo): reset traffic manager on episode reset
lgcyaxi Nov 18, 2025
417d49b
fix(sumo): improve collision handling for realistic training
lgcyaxi Nov 18, 2025
e130f77
fix(marl): resolve TD3 warmup stuck at 0 and memory leak issues
lgcyaxi Nov 25, 2025
b224ad1
refactor(marl): move TensorBoard to BaseAlgorithm and fix CARLA key m…
lgcyaxi Nov 25, 2025
84a25a8
fix(marl): add memory cleanup and TensorBoard to DQN/Q-Learning
lgcyaxi Nov 25, 2025
5cbf11f
feat(marl): add learning quality metrics for RA-L paper
lgcyaxi Nov 26, 2025
c9a2e8a
feat(marl): add traffic performance metrics for RA-L paper
lgcyaxi Nov 26, 2025
f15edb3
perf(marl): fix training slowdown with O(1) replay buffer and memory …
lgcyaxi Nov 26, 2025
dbb83e8
fix(marl): clean up TensorBoard metrics and fix max_speed tracking
lgcyaxi Nov 26, 2025
4656c57
Add CARLA world reset manager to prevent training slowdown
lgcyaxi Nov 26, 2025
84b736b
Add exploration noise decay to TD3 algorithm
lgcyaxi Nov 26, 2025
7a2c30c
Enhance MARL with 44D state, TTC and progress rewards
lgcyaxi Nov 26, 2025
7136f80
Add stop penalty and target speed metrics for MARL
lgcyaxi Nov 26, 2025
d822adc
Override run_step to apply RL target speed in MARLAgent
lgcyaxi Nov 26, 2025
39b7557
Improve TD3 actor stability and metrics handling
lgcyaxi Nov 26, 2025
ae409bd
Add MARL-specific PID controller and improve speed control
lgcyaxi Nov 26, 2025
8efcec9
Remove MARL-specific actuation module and update related code
lgcyaxi Nov 27, 2025
3491496
Update vehicle_adapter.py
lgcyaxi Nov 27, 2025
5b1569a
Fix speed unit consistency and PID control bugs
lgcyaxi Nov 27, 2025
3f415e0
Improve throughput calculation and waypoint updates
lgcyaxi Nov 27, 2025
90ad420
Update TD3 checkpoint and improve waypoint handling
lgcyaxi Nov 27, 2025
b37e286
Env: Ubuntu
JiahaoTang Nov 27, 2025
2f4ead9
Add script to fix Open3D TensorBoard plugin issue
lgcyaxi Nov 28, 2025
1652ba8
Improve training and evaluation mode handling
lgcyaxi Dec 1, 2025
56585ba
Add near-miss tracking and paper experiment configs
lgcyaxi Dec 2, 2025
0671332
Refactor MARL configs and add agent-specific YAMLs
lgcyaxi Dec 2, 2025
838e4fa
Add TTC violation rate metric and update configs
lgcyaxi Dec 2, 2025
8faf65d
Update fix_tensorboard_open3d.py
JiahaoTang Dec 2, 2025
cae13a1
Enhance TD3 exploration and safety reward logic
lgcyaxi Dec 2, 2025
5519a14
Add improvement metrics and episode length tracking
lgcyaxi Dec 2, 2025
fbb9fc2
Update traffic config and recordings, remove TD3 checkpoints
lgcyaxi Dec 2, 2025
ba412bd
Refactor sensor cleanup and update MARL reward logic
lgcyaxi Dec 3, 2025
94ba6b7
Add MAPPO algorithm and rollout buffer
lgcyaxi Dec 3, 2025
a5b1302
Add MAPPO feature config and extraction support
lgcyaxi Dec 3, 2025
73fb56f
Improve safe cleanup of vehicles and sensors to prevent crashes
lgcyaxi Dec 4, 2025
b8ce971
Update world_reset_manager.py
lgcyaxi Dec 4, 2025
1b2d93e
Add stop method to MARLCollisionSensor and improve sensor shutdown
lgcyaxi Dec 4, 2025
71721f9
Improve sensor and vehicle destruction sequence
lgcyaxi Dec 4, 2025
f689b9c
Refactor MARL safety manager for proper sensor cleanup
lgcyaxi Dec 4, 2025
337ba25
Update localization_manager.py
lgcyaxi Dec 4, 2025
38591b7
Add SAC and simple TD3 algorithms with 8D state configs
lgcyaxi Dec 5, 2025
55f8502
Simplify sensor cleanup to fix streaming client errors
lgcyaxi Dec 6, 2025
086fcbd
Update vehicle_adapter.py
lgcyaxi Dec 6, 2025
95bd617
Update configs and improve CARLA cleanup logic
lgcyaxi Dec 10, 2025
cc6dbb8
Update MARL config files for training and stability
lgcyaxi Dec 11, 2025
72df00b
Add timeout tracking to metrics and evaluation
lgcyaxi Dec 11, 2025
6034f33
Update checkpoint handling and add latest model files
lgcyaxi Dec 14, 2025
5302a6a
Enhance evaluation plots with timeout stats and update config
lgcyaxi Dec 15, 2025
93bf3fa
Add TD3 43D and simple v3 configs, rename 44D config
lgcyaxi Dec 15, 2025
8ce6198
Update td3_simple_v3.yaml
lgcyaxi Dec 15, 2025
2c24be9
Add TD3 v4 config, update v3, and refactor buffers
lgcyaxi Dec 17, 2025
b2687a7
docs: clean up
lgcyaxi Jan 30, 2026
7706032
docs: updated documentation to latest
lgcyaxi Jan 30, 2026
7147795
docs: finalize v1.0.0 release documentation
lgcyaxi Jan 30, 2026
fd50f5d
Update about.md
lgcyaxi Jan 30, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -152,5 +152,10 @@ ready*

!/recordings/*.json
/checkpoints/*/*episode_*.*
/checkpoints/*/latest_checkpoint.*
checkpoints/**/best_checkpoint.*
!/checkpoints/**/latest_checkpoint.*
/archived_docs
/.spec-workflow
/runs
/metrics_history
/.pixi
28 changes: 9 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,38 +15,28 @@ The key features of OpenCDA-MARL are:
* <strong>Scalability</strong>: Distributed training infrastructure supporting large-scale multi-agent scenarios with hundreds of vehicles.
* <strong>Mixed Autonomy</strong>: Support for mixed traffic with human-driven vehicles, rule-based AVs, and learning-based agents.

Users can refer to our [documentation](#) for detailed guides on MARL integration, training procedures, and API references. For the original OpenCDA documentation, visit [OpenCDA documentation](https://opencda-documentation.readthedocs.io/en/latest/).
Users can refer to our [documentation](https://radar-lab.github.io/OpenCDA-MARL/) for detailed guides on MARL integration, training procedures, and API references. For the original OpenCDA documentation, visit [OpenCDA documentation](https://opencda-documentation.readthedocs.io/en/latest/).

## What's New in OpenCDA-MARL

### August 2025

* **MARL Framework Integration**: Full integration of Multi-Agent Reinforcement Learning capabilities with support for PPO, SAC, QMIX, and MADDPG algorithms.
* **Distributed Training**: Scalable training infrastructure using Ray/RLlib for large-scale multi-agent scenarios.
* **Mixed Autonomy Support**: Seamless integration of learning-based agents with rule-based vehicles and human-driven traffic.

### Key Updates from Original OpenCDA

* **Environment Changes**: Changed Conda environment to Pixi for easy installation.
* **Enhanced Configuration System**: Clean YAML-based configuration with `default.yaml` template
* **Docker Support**: Easy deployment and reproducibility
* **Windows Compatibility**: Full support for Windows with Python 3.10.x and CUDA 12.8
* **HD Map Manager**: Real-time rasterization maps for RL planning
* **CARLA 0.9.15**: Latest CARLA version support with improved stability
* **MARL Framework Integration**: Core Multi-Agent Reinforcement Learning framework with implemented algorithms including Q-learning, DQN, and TD3 for intersection management and cooperative driving tasks.
* **Training Infrastructure**: Single-agent training capabilities with experience replay and checkpoint management, with distributed Ray/RLlib training planned for future releases.
* **Mixed Autonomy Support**: Seamless integration of learning-based MARL agents with rule-based vehicles, vanilla behavior agents, and human-driven traffic.

## Major Components

![teaser](docs/images/OpenCDA_MARL_architecture.png)

OpenCDA-MARL extends the original four components with MARL-specific modules:

* <strong>MARL Training Framework</strong>: Distributed training infrastructure with multiple RL algorithms
* <strong>Cooperative Driving System</strong>: Enhanced with learning-based decision making
* <strong>Co-Simulation Tools</strong>: CARLA + SUMO integration with RL environment wrapper
* <strong>MARL Training Framework</strong>: Core training infrastructure with Q-learning, DQN, and TD3 algorithms for single-agent and multi-agent scenarios
* <strong>Cooperative Driving System</strong>: Enhanced with learning-based decision making for cooperative driving tasks
* <strong>Data Manager and Repository</strong>: Training data collection and replay buffer management
* <strong>Scenario Manager</strong>: MARL-specific training and evaluation scenarios

Check our [documentation](#) for detailed architecture and MARL integration.
Check our [documentation](https://radar-lab.github.io/OpenCDA-MARL/marl/architecture/) for detailed architecture and MARL integration.

## Get Started

Expand All @@ -62,8 +52,8 @@ Note: We continuously improve the performance of OpenCDA-MARL. Currently, it is

### Developer Guide

* [Class Design](https://radar-lab.github.io/OpenCDA-MARL/architecture/)
* [Customize Your Algorithms](#)
* [Class Design](https://radar-lab.github.io/OpenCDA-MARL/marl/architecture/)
* [Customize Your Algorithms](https://radar-lab.github.io/OpenCDA-MARL/marl/algorithms/)
* [API Reference](https://radar-lab.github.io/OpenCDA-MARL/api/opencda-marl/overview/) <br>

### Contributing
Expand Down
Binary file added checkpoints/dqn_300vph/latest_checkpoint.pth
Binary file not shown.
Binary file not shown.
Binary file added checkpoints/mappo_300vph/latest_checkpoint.pth
Binary file not shown.
Binary file added checkpoints/sac_300vph/latest_checkpoint.pth
Binary file not shown.
Binary file added checkpoints/td3_43d_300vph/latest_checkpoint.pth
Binary file not shown.
Binary file added checkpoints/td3_44d_300vph/latest_checkpoint.pth
Binary file not shown.
Binary file added checkpoints/td3_44d_400vph/latest_checkpoint.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
9 changes: 9 additions & 0 deletions configs/marl/behavior.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
description: |-
Behavior-based agent for intersection scenario.
Traditional agent using OpenCDA BehaviorAgent - no training required.

agents:
agent_type: "behavior"

# Uses agents.vehicle.behavior config from default.yaml
# BehaviorAgent inherits vehicle behavior settings
Loading