问题
In my application I receive GPS coordinates which I use to draw route using HERE
's calculateRoute
method and polyline. But results are poor and rarely accurate probably due to low accuracy of the measurements.
Example of this behavior on the picture below - actual route should be only on the biggest, diagonal street.
So my idea to circumvent this problem is to first 'normalize' these coordinates by approximating them to nearest street.
My question is: does HERE API
provides such method and if so what it is called?
I have searched documentation and googled for it but to no avail.
As a last resort I can switch my whole app to Google Maps
which I know that have the method in its API to do exactly what I need.
If this will help anyone to answer this question, here are my parameters for drawing this route:
mode: 'fastest;truck',
representation: 'display',
routeattributes: 'waypoints,shape,summary',
maneuverattributes: 'direction',
waypoints: [/* too much to show here*/],
avoidLinks: '',
avoidSeasonalClosures: true,
alternatives: 1,
回答1:
The HERE Route matching API is for what you want to achieve. Check out this developer documentation:
https://developer.here.com/documentation/route-match/topics/quick-start-gps-trace-route.html
来源:https://stackoverflow.com/questions/55474350/normalization-of-coordinates-to-closest-route