Offline navigation - GraphHopper - preparation

Started by Menion, July 16, 2014, 20:43:19

0 Members and 7 Guests are viewing this topic.

Bucky Kid

  •  

Menion

Oki guys, hopefully I understand.
Try new generated plugin ( https://github.com/asamm/locus-addon-graphhopper/releases/tag/0.5 ), with your latest routing data. Should work.
- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 Release download
  •  
    The following users thanked this post: Bucky Kid

Bucky Kid

  •  

TrulloF

Yes. I can confirm it works with routing data created with latest 0.10 RC1 (didn't test 0.11 nightly yet).
  •  

develar

Thanks a lot for add-on.

My PR https://github.com/asamm/locus-addon-graphhopper/pull/1 to update GH to 0.11.0-pre1 is merged, thanks (updated to 0.10 because it is latest release).

GH vs Brouter:

1) better routes (at least for racing bike).
2) much, much faster. Instant result (of course, if contraction hierarchies (CH) were prepared for routing data).
3) GH is everywhere - Komoot uses GH, Locus uses online GH API. So, you get nearly the same route regardless of online status.

@menion Could you please add note to first topic about recommended (I would say even required) options to build routing data:

```
  graph.flag_encoders: bike2,racingbike,mtb,hike
  graph.bytes_for_flags: 8
  graph.elevation.provider: cgiar
```

(add `car|turn_costs=true` if need car routing)

(`prepare.ch.weightings: fastest` is set by default, should be not set to no)

I shared correct and up to date routing data for Germany+Austria+Switzerland (dach osm map) (keep in mind that GH doesn't support multiple files, so, if you need to cross borders, you have to use not country routing data, but some merged) — https://github.com/develar/gh-routing-data/blob/master/README.md#germany-austria-and-switzerland

Route calculation time is instant even for large distance with prepared CH. But size of routing data... (e.g. shortcuts_fastest_bike2 for DASH 929MB). Maybe a new " landmark algorithm" is an option, but "Still the speed of contraction hierarchies is ~10 times faster on average". In any case SD card is cheap and modern phones have enough internal space in any case.
  •  

develar

I published locus action files to simplify routing data installing and updating — https://graphhopper.develar.org As for openandromaps, now you can simply click "Locus" link to install or update.
  •  
    The following users thanked this post: 0709, erfi

john_percy

#231
For me, Graphhopper online in Locus provides six options for mode of travel, including car, while the offline version provides four, with no car mode.
Is this intentional?
Voluntary and Velocity themes - https://voluntary.nichesite.org
  •  

develar

> while the offline version provides four, with no car mode

@ john_percy  Please see "Which vehicles are supported?"  https://graphhopper.develar.org/#maps

> Is this intentional?

Mode list depends on supported vehicles in a routing graph. I decided to not support car (for car probably better to use another app) and foot (hike is enough) to reduce size of graph. If you need "car", I can add it (or as separate files or include into graph if size will be acceptable).
  •  

john_percy

#233
Thanks for the explanation. Personally I find access to offline routing for cars invaluable. There are times when I need car routing and there is no mobile signal.

As to which of Brouter and Graphhopper is best for offline car routing, I don't know!


Voluntary and Velocity themes - https://voluntary.nichesite.org
  •  

develar

@john_percy I will add CH data to support car mode, it seems as separate graph routing data because of https://github.com/graphhopper/graphhopper/issues/1398
  •  
    The following users thanked this post: john_percy

tannenzäpfle

Quote from: develar on June 14, 2018, 20:56:53
I published locus action files to simplify routing data installing and updating — https://graphhopper.develar.org As for openandromaps, now you can simply click "Locus" link to install or update.

Hello,
when downloading d.ch-at I receive always a fault report as per enclosed screen-shot. I have tried on two separate tablets and with different Internet connections.
  •  

develar

@john_percy Car routing with turn restrictions is not possible at the moment — https://github.com/graphhopper/graphhopper/issues/1401

Without discussion with GraphHopper developers I don't want to publish car routing using CH because I think that turn restrictions (https://github.com/graphhopper/graphhopper/blob/master/docs/core/turn-restrictions.md) is very important. If will be confirmed that landmarks algo is very slow and it is not possible to speed up on mobile, CH will be published with a warning that  turn restrictions not supported (well, you have to always follow actual road signs, but people are people).
  •  
    The following users thanked this post: john_percy

develar

It is Locus bug, I have filed http://help.locusmap.eu/topic/locus-action-extract-doesnt-support-large-files

As workaround, please download and extract manually (btw, it will be cool if Locus can download in parallel, as https://play.google.com/store/apps/details?id=com.dv.adm&hl=en does).

Routing data only for Baern/Austria/CZ is available to avoid the whole Germany.

PS. To avoid polluting this topic, I suggest report bugs about routing data to https://github.com/develar/gh-routing-data/issues
  •  

Bucky Kid

Is it somehow possible to generate single custom .pbf file based on own region in order to seamlessly cross the borders?
  •  

develar

> generate single custom .pbf file based on own region in order to seamlessly cross the borders?

You can specify required for you countries and I will add specified region to https://graphhopper.develar.org

In general, you need to draw wanted region using http://geojson.io, download europe.pbf from some public  source (http://download.geofabrik.de/index.html),  and then

```
osmium extract --overwrite --config=extracts.json --strategy=smart europe-latest.osm.pbf
```

where extracts.json something like https://github.com/develar/gh-routing-data/blob/master/configs/extracts.json

and then build graph for result pbf file.

Since Locus is so awesome, I think it is not good that users need to do such low-level tasks to enjoy offline navigation, that's why I suggest you to file issue to https://github.com/develar/gh-routing-data/issues and I will add wanted region to provided list (main problem not first import, but keep it up to date).
  •  
    The following users thanked this post: Bucky Kid