cityflow-project / CityFlow

A Multi-Agent Reinforcement Learning Environment for Large Scale City Traffic Scenario
https://cityflow-project.github.io
Apache License 2.0
785 stars 171 forks source link

Converter.py error #127

Open mcolavita opened 3 years ago

mcolavita commented 3 years ago

I'm trying to convert osm.net.xml file with the converter.py and I have this error:

Traceback (most recent call last): File "converter.py", line 537, in main(args) File "converter.py", line 516, in main final_intersections = get_final_intersections(net,tls_dict,edge_dict) File "converter.py", line 452, in get_final_intersections intersection = node_to_intersection(node,tls_dict,edge_dict) File "converter.py", line 397, in node_to_intersection for connec in tls_dict[nodeid]._connections: KeyError: '1298408173'

what I have to do?

mbkorecki commented 3 years ago

I am experiencing the same problem. I looked into sumo net.xml files and it seems to me the converter.py assumes the traffic light controlled junction id is the same as traffic plan id which is true for some sumo scenarios and not true for many others.

thesneakerhead commented 1 year ago

I am experiencing the same problem. I looked into sumo net.xml files and it seems to me the converter.py assumes the traffic light controlled junction id is the same as traffic plan id which is true for some sumo scenarios and not true for many others.

Did you find a solution for this?