osmandapp / OsmAnd

OsmAnd
https://osmand.net
Other
4.62k stars 1.01k forks source link

Insignificant roundabout exits are counted for turn instructions #10028

Open martenjj opened 3 years ago

martenjj commented 3 years ago

This is not really a routing issue, but a problem with the turn instructions counting roundabout exits when passing one which is insignificant. Here "insignificant" means a service road, no-access road or stub, which joins the roundabout but could not be sensibly counted as an exit and is not shown on road signs. For illustration:

Start: 51.49261 -0.28213 A406 Gunnersbury Avenue southbound, Chiswick, GB End: 51.49096 -0.28340 A205 Chiswick High Road, Chiswick, GB Routing profile: Internal, Car, prefer motorways, no vehicle parameters, no avoid roads OsmAnd version: 3.8.3 Device: Samsung S10, Android 10 Map: UK England 1 Sep 2020

The route is calculated and shown on the map correctly, but the turn instructions say "Roundabout: Take 5 exit and go A205 Chiswick High Road". However, the exits are counted to arrive at the "5th" by including the small service road on the inside of the roundabout, OSM way https://www.openstreetmap.org/way/644060010. No driver on the ground would consider this to be an exit from the roundabout, and it is not marked on any signs. The correct exit from the roundabout should be the 4th (1st A315 eastbound, 2nd Surrey Crescent, 3rd A4 Great West Road, 4th A205 Chiswick High Road westbound).

Unfortunately it is not possible to reliably deduce from OSM whether a road joining the roundabout is "significant" or not. However, a useful heuristic for counting roundabout exits may be to not count "highway=service" or "highway=track", or any road tagged with "access=private" or "access=no" - unless the calculated route is along such a way. It would not be a good idea to look at specialised access restrictions for the type of vehicle according to the routing profile, though - even if, for example, Surrey Crescent were tagged "hgv=no" it should still be counted as an exit because it is shown on road signs and would be seen on the ground, the directions should not change to "take the 3rd exit" just because the lorry routing profile is in use.

I have recently marked the service road access=private in OSM, and will check next month's map update to see if the same happens. With current OSM, OSRM (Car) correctly identifies the 4th exit, but GraphHopper (Car) still considers it to be the 5th.

A similar problem can be seen at the St.Margarets roundabout, where the private service road https://www.openstreetmap.org/way/609639115 is counted as an exit. Approaching the roundabout from the west and continuing eastwards along The Avenue says "Take the 3rd exit" although it should be the 2nd. Also the service road https://www.openstreetmap.org/way/645061341.

vshcherb commented 3 years ago

Very tricky issue, I don't see any solution yet. It should be somehow specially marked with data to not allow that road for roundabout. I guess to discount all service roads will lead to other issues in different places

aceman444 commented 3 years ago

Indeed, if the road is physically there, is it hard to discount it. You can't just say it isn't on the traffic sign and go by the sign, many signs do not show the real shape of the roundabout.

travnick commented 5 months ago

I have the same thing here and getting very confused, when it says to left at 7th exit, while technically there are only 3 and others are defined as

highway=service
service=driveway

~Maybe to not break the whole world, then it's possible to have a switch for that?~ ~* "Do not count service as a roundabout exit".~

~Then it's possible to have it tested before making permanent change (if it will work everywhere).~

On the other hand, there is another roundabout with service road as a "real" exit https://www.openstreetmap.org/#map=19/50.22774/19.17100 I guess the difference is that there is no curb here, and the road is properly shaped that you visually see the exit.

Also, is that true that there is no such service=driveway that can be considered as roundabout exit? If not then provide an example please :)

https://www.openstreetmap.org/#map=19/50.37356/19.27501

DmitryAlexei commented 5 months ago

Looks similar to https://github.com/osmandapp/OsmAnd/issues/18279 highway=service are treated as exits https://osmand.net/map/?start=50.374040,19.272997&end=50.374252,19.275319&profile=car#19/50.37356/19.27393