Map matching with elevation data

Dear community,

I would like to get elevation data along with the regular map matching. According to the documentation, it should be quite easy. However, I do not understand, where I have to put the required line “graph.elevation.provider=srtm”. I copied this line to a new file, but I am not sure where this one has to go.

Can you help me?

Kind regards,

Yes, you put this in the and a new import is necessary:, which requires to remove the area-gh folder

  1. The is a new file that did not exist before. Is that correct? If so, in which subfolder does it have to go?
  2. For a new import, I execute “mvn clean” in the terminal and then I re-execute “./ action=import datasource=./some-dir/osm-file.pbf vehicle=car” with the area I am interested in. Is that correct?

Re 2: ah yes, this seems to be a mismatching between the GH core and map matching repo that we have to fix
Re 2: remove the graph-cache and no mvn clean is necessary

@karussell I have tried to use the elevation information but without success.

I copied the configuration I have on graphhopper API to the one for the map-matching library. And the result is:

  datareader.file: map-data/leipzig_germany.osm.pbf
  graph.location: graph-cache
  graph.flag_encoders: hike no
  graph.elevation.provider: multi
  graph.elevation.calc_mean: true
  graph.elevation.smoothing: true
  graph.elevation.cache_dir: ./srtmprovider/
  graph.elevation.dataaccess: RAM_STORE

  - type: http
    port: 8989
    # for security reasons bind to localhost
    bindHost: localhost
  - type: http
    port: 8990
    bindHost: localhost

However, after removing the graph-cache folder, I run the map-matching import (no errors here) and I try to match a GPX file, but there is no elevation data added to the result GPX.

This is how I import:

java -jar -Xms8G -Xmx8G matching-web/target/graphhopper-map-matching-web-0.12-SNAPSHOT.jar import ../main_maps/andorra_france_spain.osm.pbf --vehicle hike

This is how I match:

java -jar matching-web/target/graphhopper-map-matching-web-0.12-SNAPSHOT.jar match camino-de-santiago-del-baztan.gpx

Thanks in advance!

In fact, the srtmprovider folder is never created. I have tried to copy the one I have in graphhopper main library, but it seems to ignore it.