osrm-backend
osrm-backend copied to clipboard
car profile - Parse width as float and make a multi-step penalty out of it
Currently we only have one step for penaltys of width which is <3m or lanes=1 on a bidirectional way.
It makes a difference if a higher class road is 4m or 6m as with 4m you wont be able to pass other cars so you will have some reduction in average speed.
So introduce more steps in the penalty for width e.g. <6m which is a small penalty as there be issues with trucks passing, below 5m which is you wont be able to pass trucks without going out to the shoulder 4m which is you wont be able t o pass a truck with a car, and 3m where basically one has to go back to let the other pass, or find some passing spot.
I ran this change with >1 Mio routes on top of changes in issue #6762 #6757 and checked for issues.
Overall observation is that now routes tend to slightly stay longer on the higher class road network.
Route quality in areas where width has been tagged more increases.
Here is a commit on top of the other changes - see branch
https://github.com/flohoff/osrm-backend/tree/routeqa
and this addon change
https://github.com/flohoff/osrm-backend/tree/width-penalty
Here is the commit:
https://github.com/flohoff/osrm-backend/commit/7a2b089430bcf05034aa218a5be57016c52cdad5
Flo