Directions with track/path with bicycle designated gone wrong

Hi there,

We see that in Germany many designated cycleways are not of the type “cycleway” but as “path” or “track” with a tag “bicycle:designated”. (i.e: Way: 52004103 | OpenStreetMap)

However we see that the directions API for both racingbike as bike does not seem to process the bicycle:designated correctly. However, it works perfectly for the type “cycleway”.

Example: GraphHopper Maps | Route Planner

Here it chooses the main road, which is very dangerous.

Shouldn’t the directions API follow designated tags for cycling?

In my fork I changed how this kind of roads are classified. I’m marking them as cycleway but this would break other, non bike profiles.

Is it possible to set RoadClass based on transportation mode?

However we see that the directions API for both racingbike as bike does not seem to process the bicycle:designated correctly.

I can reproduce this for racingbike which should be improved when there is highway=track with this surface (and especially with bicycle=designated).

But where do you see this problematic behaviour for bike?

Bike is better but starts on the road also before going back to the cycleway

I think that the avoidance of highway=path with bicycle=designated and absence of the segragated tag for racingbike is correct.
But I agree that for highway=track with good surface we should prefer this one and don’t take a parallel secondary. In the meantime I found out that the provided original example is made of such a good example. I will investigate this in detail.

@yo-han Please post the graphhopper maps link and not just a screenshot.

Sorry, it was the link from the TS but added to my to post too know.

The segment is this one: Way: 52004103 | OpenStreetMap. It is tagged as surface=sett, smoothness=good , segregated=no, and bicycle=designated.

The example was given in the initial post

1 Like

Another good example would be:

There is a bicycling:designated path after the roundabout: Way: 900877553 | OpenStreetMap

The reason in the original example with racebike is that we are assuming 20km/h speed for the highway=secondary and also 20km/h for the highway=track with the tracktype=grade1. This is OK,
I only found out that if there is no tracktype=grade1 but the surface tag still present that we would determine a lower speed. This needs to be improved.
The priority classification with “PREFER” is currently also the same. Here we need to classify good tracks with bike designation better.

@ratrun @karussell Is it possible to use country rules to prefer CYCLEWAYS more than all other roads? At least in Poland, cyclists are obliged by law to use cycleways even if they have poor surface :frowning:

@ratrun @karussell Is it possible to use country rules to prefer CYCLEWAYS more than all other roads? At least in Poland, cyclists are obliged by law to use cycleways even if they have poor surface

Via the java based car-centric CountryRule this currently does not seem possible. But I think that it will become possible when #3004 gets merged. @karussell please confirm.

The pull request 3004 is unrelated and basically makes it just simpler to write custom models.

But I plan to create separate bike related encoded values more so that the changes discussed here will be possible.

You could boost it like this:

{ "if": "country == POL && (road_class == CYCLEWAY || bike_network != MISSING)",
  "multiply_by": "1.2" }