intelligent_traffic_lights
intelligent_traffic_lights copied to clipboard
FileNotFoundError: [Errno 2] No such file or directory: './cfg/episode_routes.rou.xml'
Thank you for sharing your coding. When I ran python train.py -c config.yaml, it gave error FileNotFoundError: [Errno 2] No such file or directory: './cfg/episode_routes.rou.xml'
I checked that folder and I did not see episode_routes.rou.xml file.
Could you show me how to create this file or you can upload it to github for user convenience. Thank you
I tried to create the episode_routes.rou.xml file with the coding in generator.py as below
<vType accel="1.0" decel="4.5" id="standard_car" length="5.0" minGap="2.5" maxSpeed="25" sigma="0.5" />
<route id="W_N" edges="W2TL TL2N"/>
<route id="W_E" edges="W2TL TL2E"/>
<route id="W_S" edges="W2TL TL2S"/>
<route id="N_W" edges="N2TL TL2W"/>
<route id="N_E" edges="N2TL TL2E"/>
<route id="N_S" edges="N2TL TL2S"/>
<route id="E_W" edges="E2TL TL2W"/>
<route id="E_N" edges="E2TL TL2N"/>
<route id="E_S" edges="E2TL TL2S"/>
<route id="S_W" edges="S2TL TL2W"/>
<route id="S_N" edges="S2TL TL2N"/>
<route id="S_E" edges="S2TL TL2E"/>
After running train.py -c config.yaml, it had another error
(Hung3.7) osboxes@osboxes:~/Desktop/intelligent_traffic_lights-master$ python train.py -c config.yaml
{'learning_rate': 1e-05, 'gamma': 0.95, 'buffer_limit': 5000, 'batch_size': 128, 'sim_len': 4500, 'mem_refill': 1000, 'epochs': 1600, 'n_cars': 1000, 'weights_path': '', 'sumoBinary': '', 'sumoCmd': '', 'sumoTools': ''}
/home/osboxes/Desktop/intelligent_traffic_lights-master/src/training.py:16: UserWarning: nn.init.xavier_uniform is now deprecated in favor of nn.init.xavier_uniform_.
torch.nn.init.xavier_uniform(m.weight.data)
/home/osboxes/Desktop/intelligent_traffic_lights-master/src/training.py:17: UserWarning: nn.init.constant is now deprecated in favor of nn.init.constant_.
nn.init.constant(m.bias.data, 0)
No model weights found, initializing xavier_uniform
Traceback (most recent call last):
File "train.py", line 15, in