[OSRM-talk] Fixing routing with tags

Richard Fairhurst richard at systemed.net
Wed Dec 13 09:49:33 UTC 2023


Florian Lohoff wrote:
> The route uses "Im Kracht" where it should stay on K22 and L775:
> [...]
> The route uses "Westerweg" but it should stay on K27, L876, L803:
> [...]
> So my idea would be to create a tag like **relative_route_cost=**

First, you seem to be assuming that "fast car routing" is the only sort of routing. It really isn't. If you're riding a bike then going via quieter roads like Westerweg or Im Kracht is greatly preferable:

https://cycle.travel/map?from=&to=&fromLL=52.234035,8.513781&toLL=52.238110,8.483742
https://cycle.travel/map?from=&to=&fromLL=52.280323,8.696529&toLL=52.289005,8.709464

Second, this is trivially fixable. As Nils says, you just change the routing weight of minor roads and/or add a greater turn penalty when turning off a major road onto a minor road.

Routing engines are opinionated. There is no single right or wrong answer for "the best route from A to B"; they each have their own preferences. Those preferences can be tweaked. What you seem to be advocating is a tag in OSM for "roads Florian likes to drive on", but at that point we also need one for "roads Richard likes to cycle on" and so on, and that's going to get very messy very quickly.

I note that, in the second example, Google Maps also chooses a quieter road (though in this case Wittekindstraße rather than Westerweg). Google Maps (and Waze, and Apple Maps) using minor roads to save a few seconds is a massive issue, and has caused traffic authorities in the UK and elsewhere to spend millions putting up bollards to block former cut-throughs. But the way to fix that is not to break the map data, the way to fix it is for routing engine developers to be responsible citizens. (Google? Good luck with that.)

FWIW, I'm not convinced that it's possible to do good quality car routing on OSM data without external datasets, principally traffic. (The situation with cycling and walking is slightly different.) The engines featured on osm.org are essentially tech demos for testing connectivity and demonstrating a use of OSM data, but they won't give you the best real-world results.

Richard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/osrm-talk/attachments/20231213/045b645d/attachment.htm>


More information about the OSRM-talk mailing list