I am having some trouble with routing through Ped zone where the Buses are allowed to route based on the tag bus=yes in OpenStreetMaps.
I am using ‘roads’ as vehicle type and ‘BUS,car’ as transportation mode.
This is what I have in my custom model for bus:
“if”: “bus != YES && car_access == false”,
“else_if”: "bus == YES,
Unfortunately it does not work, and it can’t route through the ped_zone. Am I doing something wrong here? Please help.
Do you have an example coordinate where this does not work? Maybe another tag or bollard is restricting the access.
This is the OSM way on which I am trying to route:
Start Point: 8.399646609986064, 49.00979533082912
End Point: 8.401039594143924, 49.00972359399361
is there any update on this issue?
I have tried routing on other streets too, where highway=pedestrian and bus=yes are set, but it still does not route through these streets.
What exactly does not work? This custom model rule
“if”: “bus != YES && car_access == false”, should give an error, because there is no
bus encoded value (?), or did you modify the Java code accordingly?
I already have implemented the “bus” encoded value. See this: Except=bus OR except=psv tags are not considered for "vehicle":"car" - #4 by karussell
But then I am unable to route on the streets which have tags highway=pedestrian and bus=yes. My Bus Profile should be able to route through the pedestrian zone, where the buses have permission because of the bus=yes tag in OSM.
Does graphhopper-7.0 support this?
My custom model looks like this:
“limit_to”: “car_average_speed * 0.9”
"if": "car_access == false && bus!=YES",
"else_if": "foot_access == true && bus==YES",
Try enabling the ‘Show Routing Graph’ option in the Web UIs layer menu. You can then hover the roads in question to see all the encoded values. Maybe from this you can figure out if and why they are still not accessible. If you are unsure maybe paste the encoded values here.
If there is just a gate, bollard etc. it should be possible to create a short route on the road by moving the markers very close to each other. This way you can exclude such gates as the cause of the issue.
I am not using any Web UI from graphhopper (if that you mean). I am using graphhopper’s Java API (graphhopper-core-7.0)
Ok, I’m just saying for debugging it would probably help to use the UI in the way I described it. Using the Java API only you could also try to get hold of the single edges, inspect the encoded values and debug the weighting of course.