osmandapp / OsmAnd

OsmAnd
https://osmand.net
Other
4.68k stars 1.02k forks source link

Default bicycle routing settings use highway=footway too often #9361

Open Kars-de-Jong opened 4 years ago

Kars-de-Jong commented 4 years ago

What version of OsmAnd are you using, on what device and Android/iOS version?

OsmAnd+ 3.7.4, Samsung Galaxy S8, Android 9.

Do you use the offline maps offered within the OsmAnd app for download, or online (tile / raster) maps?

Offline maps.

Tell us whether you have used OsmAnd's in-app offline routing, or any online routing provider like YOURS, OpenRouteService or OSRM.

The in-app offline engine.

What routing profile is chosen in OsmAnd app? (car, bike, pedestrian, fastest or shortest)

The bike routing profile, "Balanced" style. Other settings are at their defaults.

Please specify as exactly as possible the start and end point of your route by telling us city name and street name so that we can find it via in-app address search easily. Also, a permalink from openstreetmap.org can be helpful.

start: Parallelweg LS 55, Hengelo end: Adriaansweg 8, Hengelo

There are more examples I could give if so desired, including ones with barrier=cycle_barrier nodes.

Tell us your expected routing, and how OsmAnd routes, or add screenshots here.

This routes over these footways: https://www.openstreetmap.org/way/241045169 and https://www.openstreetmap.org/way/733072820, which is not nice since you're not allowed to ride your bicycle on footways: routed over footways

I noticed that the maximum speed for footways is set to 15 km/h, which seems quite fast since you're not allowed to actually ride your bicycle on a footway...

What is even more puzzling: if I set the profile to pedestrian, I am routed over the main road: routed over the main road

gdt commented 4 years ago

Are these footways marked bicycle=no? In the US, we do not have a 'no bicycles on footways' general rule. There is often 'no bicycles on sidewalk in the central business district'.

If there is a regional/national rule "highway=footway implies bicycle=no" then there needs to be a machine-readable representation of these rules and then it's fair to ask osmand to follow it.

vshcherb commented 4 years ago

There is no special rule in OsmAnd for Netherlands not to use footway, in general in the Netherlands it's forbidden to ride on footway but you can pass with bicycle itself. So we will need to put special limitation per country and deprioritize footways.

I would say it is a known bug for pedestrian routing rather than bicycle where it looks expected to current state of the data

manuelVo commented 4 years ago

The open street maps wiki (https://wiki.openstreetmap.org/wiki/OSM_tags_for_routing/Access_restrictions) suggests that highway=footpath should imply bicycle=no if bicycle isn't set explicitly - both for the global default as well as for most of the countries listed on that wiki page. As such I'd like to suggest by default disallowing (or penalizing by accounting for dismount time and reducing the speed to that of a pedestrian) and enabling routing there on a per-country basis.

vshcherb commented 4 years ago

@manuelVo we need to spend some time and create rules specific for each country with rendering_types.xml. I think this is quite difficult cause it will need to be maintained, so we need to make sure that Wiki is stable and Wiki is followed by mappers in these countries

gdt commented 4 years ago

And, the right fix - much harder - is for mappers to tag bicycle=yes or bicycle=no on footways, as the actual local rules say. The notion that there are defaults, when there isn't a machine-readable configuration-managed defaults file -- is just too unreliable.

mephinet commented 4 years ago

I've seen identical issues in the inner city of Vienna, Austria (which is a pedestrian zone (mapped as highway=pedestrian with bicycle=dismount) - cf https://www.openstreetmap.org/way/30322134 Osmand chooses a route right through the inner city, not being aware that you would have to push your bike, making 3km/h instead of 15.

scaidermern commented 4 years ago

OsmAnd should put a penalty on bicycle=dismount, reducing the speed to walking speed.

NotSoImportant commented 2 years ago

OsmAnd should put a penalty on bicycle=dismount, reducing the speed to walking speed.

Where can the bicycle routing/penalty calculation be found in the code?

vshcherb commented 2 years ago

@NotSoImportant in routing.xml obviously https://docs.osmand.net/docs/technical-documentation/osmand-file-formats/osmand-routing-xml

NotSoImportant commented 2 years ago

After readimg through it, it is not easy to determine the outcome of a change without trying it out because of the amount of factors. Is there a tool to evaluate it or is the only current way to copy it to OsmAnd and find streets that match the conditions?

vshcherb commented 2 years ago

OsmAnd or OsmAndMapCreator works with custom routing.xml.