Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/thanosKontos/gravelmap
A simple router for osm data with custom profilers
https://github.com/thanosKontos/gravelmap
Last synced: about 2 months ago
JSON representation
A simple router for osm data with custom profilers
- Host: GitHub
- URL: https://github.com/thanosKontos/gravelmap
- Owner: thanosKontos
- Created: 2019-04-06T20:09:23.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-12-29T14:53:35.000Z (9 months ago)
- Last Synced: 2024-05-10T13:46:26.109Z (5 months ago)
- Language: Go
- Homepage:
- Size: 4.16 MB
- Stars: 13
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
**WIP**
# Gravel map
Gravelmap is a routing engine made for off-road adventurers (hikers, mountain bikers, SUVs).
## Installation guide
**Prerequisites:** You need to have *osmium* installed in your system (https://osmcode.org/osmium-tool/). Also you need to have it set in $PATH.
Example of building and running in Ubuntu x64:
```bash
git clone [email protected]:thanosKontos/gravelmap.git
cd gravelmap
cp .env.dist .env
env GOOS=linux GOARCH=amd64 go build -o /tmp/gravelmap cmd/main.go && /tmp/gravelmap version
```## Import OSM data
The 2 commands below will extract the needed osm data for routing and create all the routing files.
```bash
go run cmd/main.go filter-osm --input ~/Downloads/bremen-latest.osm.pbf --output ~/Downloads/bremen_for_routing.osm.pbf
go run cmd/main.go import-routing-data -v info --input ~/Downloads/bremen_for_routing.osm.pbf
```Now you can start using the router!
If your system is suffering from high memory consumption you can use the flag `use-filesystem`. Beware, this will make data importing extremely slow.
## Create web-server
This is not part of the actual toolkit. It is just an example of how you may use the data from the above commands.
Plus is a nice way for me to debug the result in a nice interface.
```bash
env GOOS=linux GOARCH=amd64 go build -o /tmp/gravelmap cmd/main.go && /tmp/gravelmap create-web-server
```Open `example/route_from_to.html` to test routing
![](resources/example_website.png)