What's the purpose of routing:bicycle?

https://wiki.openstreetmap.org/wiki/Key:routing:bicycle

explains that:

“This is different from the bicycle tag since this should be used for routing only. Example: if there is a cycling path separated from the road, but in the region where this cycling path and road are found, it is permitted to cycle in the street or in the cycling path: there should be a way to specify that routing must use the cycling path.”

However, this seems to be exactly what bicycle=use_sidepath does. What exactly makes something here need to be routing-specific?

There are only 7,983 uses of this internationally.

Why is it actually needed?

1 Like

I’d never heard of this before, but as far as I can see the difference is that bicycle=use_sidepath is intended to reflect a legal requirement (cyclists are not allowed to use the street). Whereas this tag seems more like a hint to routers about which to prefer among more than one legal option.

1 Like

Why must the routing use the cyclepath when it is allowed to drive on the road?

cycleway=separate is the way to give the router a hint that there is a separate line for the bicycle infrastructure. bicycle=yes/use_sidewalk is the way to tell the router that the use of the road is permited or forbitten.

The wiki entry exists since May 2024
The tag is used since 4 years
It’s only used in one area of US i guess by I very limited number of mappers
There is no link to any discussion
status: de-facto ?? (I would say: in use)

3 Likes

pinging @ChaireMobiliteKaligrafy who created the wiki page for routing:bicycle and is also on the forum

The bicycle tag is for official rule, so bicycle=no/dismount would mean it is forbidden to ride a bike there. Using bicycle=use_sidepath would mean it is mandatory to use the sidepath/cycleway alongside road. However, in some regions, it is not mandatory to use the sidepath/cycleway even when there is one present (Quebec is an example of that). So to make sure routing engines use the sidepaths/cycleways whenever possible, we added routing:bicycle tags to replace the bicycle tag. It works well with osrm (you just add routing:bicycle to the bicycle profiles as having priority over bicycle the tag). Same for routing:motor_vehicle which is mostly useful with the value “destination” to make sure routing engines use these streets for access/egress only, even if there is no law forbidding motor vehicles to reach these roads per se.

I don’t remember having set it to de-facto, but could be wrong, feel free to change to “in-use” as it is only useful where using the sidepaths are not mandatory.

This has been changed to “in-use” already. Thanks!

Could you explain further, referring to this way for example:

It is tagged as “routing_bicycle=use_sidepath”. From what you are saying, that would be used to tell a router to avoid this street in favour of the sidepath. But where is the sidepath mapped in OSM? I don’t see any tag on this way, or any parallel way, indicating that a sidepath exists.

The sidepath is the other direction, which have a bidirectional cycleway lane. So the router will use the other direction as an opposite cycleway. This is a bad design though! The view is northbound, so the southbound direction should force route bicycles on the northbound side, for both directions. However, in Quebec it would be ok to cycle on the southbound side but most cyclist would use the bidirectional lane on northbound car side.

The cycleway=lane tag is on the opposite oneway road

Why you do not use cycleway seperate or bicicle=optional_sidepath?

What should be the meaning of all th e other values of key routing:bicycle

I understand your frustration with this tag, but it saved our routing analysis. This tag is only useful in regions where it is not mandatory to use cycleways when available. We are doing a lot of research on transporation in Quebec and OSRM was routing most cycling trips on large highways where almost nobody would dare to cycle. At first, we used the bicycle tag=use_sidepath but it was reverted because it is permitted to ride a bike when cycle paths are present. Using the cycleway=separate is not recognized in most routing engines, while use_sidepath is. Feel free to not use it in your local area, but in Quebec, it makes cycling routing engines way more robust and realistic (it is just a matter of adding one line to the OSRM profile).

optional_sidepath is not implemented in OSRM, while use_sidepath is, and using a specific routing tag is more precise, it really means: routing engine should “use_sidepath”

I would be happy to update whenever OSRM implements optional_sidepath

routing:bicycle should be a “bicycle” tag specific for routing, so it should accept all bicycle tag values, isn’t it? However, I mostly use use_sidepath.

I still do not see the need of tagging this at all. You may simply use a routing profil that prefers cyleways a bit more than streets.

5 Likes

That’s not so clear. What does a value of private mean, for example? How would a way be private for routing but not otherwise?

This works with routing for personal purposes, but when we do research, we sometimes route thousands of trips and none of these trips should ever route bicycle on these kind of streets (see image). It is legal to ride on the road instead of using the cycleway, but 100% of cyclists will not do it. Doing so would also mean being harassed by car drivers. I wish it was like in Europe, but in North America, rules of the roads are not compatible with common sense most of the time. Using weights to prefer cycleways in routing engines are not working all the time and need careful calibration, which would change from place to place. Part of my day job is to calibrate these engines and the solutions using our custom tag is working 99% of the time, while other methods have failed in multiple areas.

Could you kindly give us all an example A-B route demonstrating this?

And preferably a photo of such a location so we can see how this is described in OSM tagging at that point.

What you say sounds like a highly suboptimal solution, frankly, and one wonders why you chose that particular routing engine, or didn’t improve its cycle routing profile by amending cycleway & related weightings rather than inventing a non-standard tag.

That tag should be removed, based on what you have said. It is “tagging for the router”.

5 Likes

See previous message for an example image. Also: weighting in routing engines is way slower. Algorithms used in OSRM are faster because weighing is kept as a minimum, and thus in a lot of our simulations, it saves us several hours of calculation. I just don’t understand why people not liking this tag just don’t ignore it altogether. There are thousands of custom tags all over the place in OSM and nobody have a problem with them. I added a WIKi page for transparency, but I guess I should just remove it.