Python generator for MATSim signals xml files.
Florian 0b61f31cb5 xml namespaces | 7 years ago | |
---|---|---|
input | 7 years ago | |
README.md | 7 years ago | |
signals_gen.py | 7 years ago |
Python generator for MATSim signals xml files
venv
(https://github.com/juliendehos/venv).pbf
(http://download.geofabrik.de/).xml
(test files are available in input/
folder for Calais city)Extract OpenStreetMap data with osmosis .osm
(example for Calais):
cd osmosis/
./bin/osmosis --rbf nord-pas-de-calais-latest.osm.pbf --bounding-box top=50.9759 left=1.7965 bottom=50.9231 right=1.9222 --wx calais.osm
Extract traffic lights data .xml
:
./bin/osmosis --rb file=calais.osm --tf accept-nodes highway=traffic_signals --wx signals.osm.xml
venv i signals_gen
venv a signals_gen
pip install lxml
./signals_gen.py