# CoLight
CoLight is a reinforcement learning agent for network-level traffic signal control.
```
@inproceedings{colight,
author = {Wei, Hua and Xu, Nan and Zhang, Huichu and Zheng, Guanjie and Zang, Xinshi and Chen, Chacha and Zhang, Weinan and Zhu, Yamin and Xu, Kai and Li, Zhenhui},
title = {CoLight: Learning Network-level Cooperation for Traffic Signal Control},
booktitle = {Proceedings of the 28th ACM International Conference on Information and Knowledge Management},
series = {CIKM '19},
year = {2019},
location = {Beijing, China}
}
```
It shares the similar code structure with PressLight ([PressLight: Learning Max Pressure Control to Coordinate Traffic Signals in Arterial Network](http://personal.psu.edu/hzw77/publications/presslight-kdd19.pdf)) from KDD 2019.
Usage and more information can be found below.
## Usage
How to run the code:
We recommend to run the code through docker. Some brief documentation can be found at https://docs.docker.com/.
1. Please build a docker image using the dockerfile provided.
``sudo docker pull hzw77/colight:v0.1``
2. Pull the codes for CoLight.
``git clone https://github.com/wingsweihua/colight.git``
3. Please run the built docker image to initiate a docker container. Please remember to mount the code directory.
``sudo docker run -it -v /path/to/your/workspace/colight/:/colight/ --shm-size=8gb --name hua_colight hzw77/colight:v0.1 /bin/bash``
``cd colight``
(Alternatively, you can install the packages (included in the dockerfile) on your linux system)
Start an experiment by:
``python -O runexp.py``
Here, ``-O`` option cannot be omitted unless debug is necessary. In the file ``runexp.py``, the args can be changed.
* ``runexp.py``
Run the pipeline under different traffic flows. Specific traffic flow files as well as basic configuration can be assigned in this file. For details about config, please turn to ``config.py``.
For most cases, you might only modify traffic files and config parameters in ``runexp.py``.
## Dataset
* synthetic data
Traffic file and road networks can be found in ``data/1_3`` && ``data/3_3`` && ``data/6_6`` && ``data/10_10``.
* real-world data
Traffic file and road networks of New York City can be found in ``data/NewYork``, it contains two networks at different scale: 196 intersection and 48 intersections. Jinan and Hangzhou dataset are also included.
## Agent
* ``agent.py``
An abstract class of different agents.
* ``CoLight_agent.py``
Proposed CoLight agent
## Others
More details about this project are demonstrated in this part.
* ``config.py``
The whole configuration of this project. Note that some parameters will be replaced in ``runexp.py`` while others can only be changed in this file, please be very careful!!!
* ``pipeline.py``
The whole pipeline is implemented in this module:
Start a simulator environment, run a simulation for certain time(one round), construct samples from raw log data, update the model and model pooling.
* ``generator.py``
A generator to load a model, start a simulator enviroment, conduct a simulation and log the results.
* ``anon_env.py``
Define a simulator environment to interact with the simulator and obtain needed data like features.
* ``construct_sample.py``
* Construct training samples from original data. Select desired state features in the config and compute the corrsponding average/instant reward with specific measure time.
* ``updater.py``
Define a class of updater for model updating.
没有合适的资源?快使用搜索试试~ 我知道了~
CoLight:学习交通信号控制的网络级合作_Python_JavaScript_下载.zip
共434个文件
xml:237个
json:114个
py:32个
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
0 下载量 174 浏览量
2023-04-26
11:38:24
上传
评论
收藏 2.28MB ZIP 举报
温馨提示
CoLight:学习交通信号控制的网络级合作_Python_JavaScript_下载.zip
资源推荐
资源详情
资源评论
收起资源包目录
CoLight:学习交通信号控制的网络级合作_Python_JavaScript_下载.zip (434个子文件)
style.css 65B
simulator.dockerfile 579B
.gitignore 8B
index.html 3KB
index.html 773B
script.js 11KB
render.js 7KB
Point.js 1KB
roadnet_28_7.json 9.8MB
anon_28_7_newyork_real_triple.json 7.3MB
roadnet_10_10.json 4.98MB
anon_28_7_newyork_real_double.json 4.94MB
roadnet_16_3.json 2.41MB
anon_4_4_hangzhou_real_5816.json 2MB
anon_4_4_hangzhou_real_5734.json 1.88MB
roadnet_6_6.json 1.8MB
anon_3_4_jinan_real.json 1.79MB
anon_3_4_jinan_real_2500.json 1.56MB
anon_3_4_jinan_real_2000.json 1.24MB
anon_16_3_newyork_real.json 1.02MB
anon_4_4_hangzhou_real.json 878KB
roadnet_4_4.json 827KB
roadnet_3_4.json 622KB
roadnet_3_3.json 471KB
roadnet_3_3.json 452KB
roadnet_1_10.json 115KB
roadnet_1_3.json 36KB
roadnet_1_2.json 25KB
anon_10_10_300_0.3_bi.json 22KB
roadnet_1_1.json 19KB
roadnet_1_1.json 12KB
roadnet_1_1.json 12KB
anon_6_6_300_0.3_bi.json 11KB
anon_10_10_300_0.3_uni.json 11KB
anon_1_10_700_0.3.json 9KB
anon_1_10_700_0.6.json 9KB
anon_3_3_700_1.0.json 9KB
anon_1_10_100_0.3.json 8KB
anon_1_10_100_0.6.json 8KB
anon_1_10_300_0.6.json 8KB
anon_1_10_300_0.3.json 8KB
anon_1_10_200_0.3.json 8KB
anon_1_10_200_0.6.json 8KB
anon_1_10_400_0.6.json 8KB
anon_1_10_500_0.6.json 8KB
anon_1_10_600_0.6.json 8KB
anon_1_10_600_0.3.json 8KB
anon_1_10_400_0.3.json 8KB
anon_1_10_500_0.3.json 8KB
anon_3_3_100_1.0.json 8KB
anon_3_3_200_1.0.json 8KB
anon_3_3_300_1.0.json 8KB
anon_3_3_500_1.0.json 8KB
anon_3_3_600_1.0.json 8KB
anon_3_3_400_1.0.json 8KB
anon_6_6_300_0.3_uni.json 5KB
anon_3_3_300_0.3_bi.json 5KB
anon_1_3_700_0.3.json 3KB
anon_1_3_700_0.6.json 3KB
anon_1_3_100_0.3.json 3KB
anon_1_3_300_0.6.json 3KB
anon_1_3_100_0.6.json 3KB
anon_1_3_200_0.6.json 3KB
anon_1_3_200_0.3.json 3KB
anon_1_3_300_0.3.json 3KB
anon_1_3_400_0.3.json 3KB
anon_1_3_400_0.6.json 3KB
anon_1_3_600_0.3.json 3KB
anon_1_3_500_0.3.json 3KB
anon_1_3_600_0.6.json 3KB
anon_1_3_500_0.6.json 3KB
traffic_parameters_15min.json 3KB
flow_1_1_700.json 3KB
flow_1_1_100.json 3KB
flow_1_1_500.json 3KB
flow_1_1_600.json 3KB
flow_1_1_200.json 3KB
flow_1_1_400.json 3KB
flow_1_1_300.json 3KB
anon_3_3_300_0.3_uni.json 2KB
anon_1_2_700_0.3.json 2KB
anon_1_2_700_0.6.json 2KB
anon_1_2_700_1.0.json 2KB
anon_1_2_100_0.3.json 2KB
anon_1_2_300_0.3.json 2KB
anon_1_2_200_1.0.json 2KB
anon_1_2_300_1.0.json 2KB
anon_1_2_300_0.6.json 2KB
anon_1_2_100_0.6.json 2KB
anon_1_2_200_0.6.json 2KB
anon_1_2_100_1.0.json 2KB
anon_1_2_200_0.3.json 2KB
anon_1_2_500_0.6.json 2KB
anon_1_2_400_0.3.json 2KB
anon_1_2_400_0.6.json 2KB
anon_1_2_500_0.3.json 2KB
anon_1_2_600_0.6.json 2KB
anon_1_2_600_0.3.json 2KB
anon_1_2_400_1.0.json 2KB
anon_1_2_600_1.0.json 2KB
共 434 条
- 1
- 2
- 3
- 4
- 5
资源评论
快撑死的鱼
- 粉丝: 1w+
- 资源: 9154
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- python-leetcode面试题解之第157题用Read4读取N个字符-题解.zip
- python-leetcode面试题解之第156题上下翻转二叉树-题解.zip
- python-leetcode面试题解之第155题最小栈-题解.zip
- python-leetcode面试题解之第153题寻找旋转排序数组中的最小值-题解.zip
- python-leetcode面试题解之第152题乘积最大子数组-题解.zip
- python-leetcode面试题解之第151题反转字符串中的单词-题解.zip
- python-leetcode面试题解之第150题逆波兰表达式求值-题解.zip
- python-leetcode面试题解之第149题直线上最多的点数-题解.zip
- python-leetcode面试题解之第148题排序链表-题解.zip
- python-leetcode面试题解之第147题对链表进行插入排序-题解.zip
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功