Running map matching using a custom road network (not OSM)


While searching for an open source implementation of the HMM-based map-matching algorithm, I found GraphHopper’s implementation.

We’re not using OSM but a custom road network each line of which looks like


For example,

“150525009781009783,150525009781,150525009783,LINESTRING(169618 450000,169558 449917),0,9,1”

Are these fields are enough to construct a road network on which I can run GraphHopper’s map-matching implementation?


You could convert your data into the OSM format and then use the standard GH OSM import. Mapping your ‘road_category’ to OSM road_class might be the easiest way to go, but you could also use your own FlagEncoder implementation. GraphHopper routing also allows using CustomWeighting that makes it much easier to use your own road categories, but unfortunately this is not supported for map-matching yet. With some Java knowledge this should be possible though.

1 Like
Powered by Discourse