Awesome
OSM-Contraction-Hierarchies
by Felix Bühler
This project was part of "Lab Course: Algorithms for OSM Data".
This project implements "Contraction Hierarchies". Which is one of the best known speed-up techniques for shortest path calculations. As data source OpenStreetMap-data is used.
This repository consists of two programms:
pre
This will parse the *.osm.pbf
file into a *.osm.pbf.fmi
file, which is needed for the web
-program
Cropped OSM-data can be downloaded from Geofabrik.de
dependecies
bincode
= exporting serializationnum_cpus
= get number of threadsosmpbfreader
= parsing the pbf filerayon
= parallelizationserde
= serialization
Compilation
cargo build --release -p osm_ch_pre
Usage
cargo run --release -p osm_ch_pre ./germany-latest.osm.pbf
Info
from different grahps the best performance was using two cores (taskset -c 0,1 cargo run ...
). This may vary between grahps.
web
is the webserver which provides the web-interface. (it needs the *.osm.pbf.fmi
-file from the pre
-programm.)
dependecies
actix-files
= serving static filesactix-rt
= running actixactix-web
= webserverbincode
= exporting serializationenv_logger
= logging the webserverrayon
= parallelizationserde
= serializationserde_json
= serialization json
Compilation
cargo build --release -p osm_ch_web
Usage
cargo run --release -p osm_ch_web ./germany-latest.osm.pbf.