Offline navigation - GraphHopper - preparation

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

0 Members and 6 Guests are viewing this topic.

silvermapper

menion
I thank you for providing the new generator so quickly in response to my request.  I look forward to the same success I had with version 0.1.7 when I try it.  With reference to your comment 'Anyway suggest to read "how to" on pages of graphhopper', I executed that particular process with much patient assistance from karussell here: https://discuss.graphhopper.com/t/graphhopper-locus-map-add-on/207/8 but as I wrote there, the resulting .osm-gh file was not liked by Locus Map.  The one produced using your generator was liked, however, to my immense satisfaction.
  •  

Marcus Aurelius

Graphhopper works fine, changed to it from Brouter to it, and I see that the routes are more convenient to my own experience...
But I do have a problem now. Lately I noticed a problem with Locus. When I shut off the smartphone, and I go into Locus, Locus does not find the vectormaps, directory. So no maps. Setting up the standard vector maps again, Problem solved. Setting Brouter later on, and setting Graphhopper again, and I get the message 'no data found' ... Playing a bit with the standard directory settings again, and okay ... it works again, Dont know if it's a graphhopper or locus problem in general or smartphone or SDcard..... Experience ?
  •  

poutnikl

#167
Quote from: Marcus Aurelius on December 07, 2015, 08:27:30Graphhopper works fine, changed to it from Brouter to it, and I see that the routes are more convenient to my own experience...

GraphHopper is for obvious reasons the preferred option for offline car navigation.

For bike and cars, you have just experienced Brouter profiles that do not suits you. As Brouter route quality raises and falls with level of matching the profile to user preferences. And that is the reason why for many users is Graphhopper better=easier solution.

silvermapper

#168
I wish to create GraphHopper routing data updates frequently to reflect my recent OSM input and assist me in checking further OSM paths and their attributes in my area.  I downloaded GH addon 0.2 - based v0.5.apk and associated routing data following menion's announcement in Reply #150.  My Reply #151 confirmed everything worked.
I have tried two methods to create routing data that Locus Map will accept.  Both failed.

1. menion's generator:  I downloaded graphHopper.zip and extracted it; downloaded an england.osm.pbf file to the same location as graphhopper.sh and ran the command in Cygwin.  Here is the result:
Bob@Dellcomputer /cygdrive/c/users/bob/downloads/graphhopper/data/version_0.2.0/graphhopper/graphhopper
$ export JAVA_OPTS="-Xmx1g -Xms1g"
Bob@Dellcomputer /cygdrive/c/users/bob/downloads/graphhopper/data/version_0.2.0/graphhopper/graphhopper
$ ./graphhopper.sh import england-20151215.osm.pbf
./graphhopper.sh: line 2: $'\r': command not found
./graphhopper.sh: line 25: syntax error near unexpected token `$'{\r''
'/graphhopper.sh: line 25: `function printUsage {
I note some files are named differently and the file content is different between version 0.1.7 and 0.2.0, as can be seen in my two attachments (in case this is relevant)

2. GraphHopper Quickstart: I ran this as laid out here: https://github.com/graphhopper/graphhopper/blob/master/docs/web/quickstart.md.  The operation completed as it should with the final statement, "Started server at HTTP 8989" and a *.osm-gh folder with its content was created.  I placed the folder in Locus>mapsVector and selected it in Locus Map - add-on GraphHopper.  I opened Locus Map and tapped the 'Navigate' tab but received the message, "Unfortunately, Locus Pro has stopped" after the 'SELECT LOCATION' box appeared very briefly.
I note some files are different and file sizes of what I created here are significantly smaller compared with the 'england.osm-gh' I downloaded from menion's site, as can be seen in my two attachments (in case this is relevant).

I am not clever enough to pursue this issue and should be grateful if someone could take me forward.
  •  

tommi

ad 1): Sounds like graphhopper.sh contains carriage return characteers (\r). This could be the result of editing this file with a windows editor.
  •  

voldapet

@silvermapper
As tommi wrote the first issue is very likely caused due to wrong character in sh script. There is for example more information: https://danieladeniji.wordpress.com/2013/03/07/microsoft-windows-cygwin-error-r-command-not-found/

To your second question: have you really used the latest graphHopper.zip package for generation the routing data?
  •  

silvermapper

#171
tommi
I compared the text of the graphhopper.sh file in menion's versions 0.1.7 and 0.2.0.  It was continuous in 0.1.7 but separated into lines in 0.2.0 which confirms what you wrote, perhaps.  I could not see significant differences in the text content, however.  I decided to use graphhopper.sh version 0.1.7 file in place of graphhopper.sh in version 0.2.0, everything else being 0.2.0.  It is successful, so far as I can tell.  The command ran to completion and created a new *.osm-gh file that is accepted by Locus Map.
I thank you for helping me to progress to a solution.
petr
I used graphhopper-web-0.5.0-bin.zip from https://oss.sonatype.org/content/groups/public/com/graphhopper/graphhopper-web/0.5.0/.
Even though I appear to have had success using menion's 0.2.0 generator from what I wrote above, I should like to make this method work, also.
I thank you for your interest and hope you can help further.
  •  

poutnikl

Quote from: tommi on December 16, 2015, 14:18:00
ad 1): Sounds like graphhopper.sh contains carriage return characteers (\r). This could be the result of editing this file with a windows editor.
Or rather being saved with Windows line breaks,
as good Windows editors support Windows, UNIX  or even ( said old ) Mac way of line breaks,  like e.g. Notepad++.

silvermapper

petr
I referred to the link you kindly provided regarding the structure of the graphhopper.sh file.  I downloaded Notepad++ and carried out the instructions in the link.  It worked!  Furthermore, with the aid of the Compare plugin, I was able to determine there was very little difference between the 0.1.7 and 0.2.0 graphhopper.sh files.
I thank you, and post this reply for the further reason it might be of use to others.
Bob
  •  

voldapet

Great, thank you for feedback.
I guess that graphhopper 0.5.0 you have downloaded is the correct. However I suggest to use combination of plugin and generator that is available at https://drive.google.com/folderview?id=0B7v_sPhHE6RgOUtXajZHVk9BSVU&usp=sharing&tid=0B7v_sPhHE6RgfjJZbEtsS1VnSWRMTDZUZGw3TlN4WTZLMHVUbTUtUGwtVUFvVlFVWlN6MDA
  •  

Haggi

Spotted this: -May be in near future we'll see much more... when is near future and what are we gonna see?  ;D

Ref: http://www.locusmap.eu/locus-map-can-navigate-offline/
  •  

tommi

@Locus-Team: GraphHopper 0.6.0 was released some days ago. Could we get an update of the Locus plugin?
  •  

devo

#177
Im trying to get Graphhopper working... on Android 5 it works fine.
On Samsung S5 Android 6 (cyanogenmod 13) I get an error: No Content... But Graphhopper data to Storage... (see screenshot)
. .

Any Idea???
  •  

Menion

@tommi: as I see, there are no serious changes in new version. But I would like to generate new data as well, so hope ...

@devo: hard to say. Do you have graphopper data next to vector maps in correct folder?
- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 Release download
  •  

devo

menion, thanks for your answer... I think so (see screenshots)
  •