10000 add CONSTRUCTION to RoadClass enum by caspg · Pull Request #3017 · graphhopper/graphhopper · GitHub
[go: up one dir, main page]

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add CONSTRUCTION to RoadClass enum #3017

Merged
merged 1 commit into from
Jun 10, 2024

Conversation

caspg
Copy link
Contributor
@caspg caspg commented Jun 10, 2024

This change will allow to route through highway=construction as discussed here #3016

For example, we could use map matching API to snap some older GPX track and get OSM informations. This would allow to maintain original GPX geometry without avoiding roads under construction.

To use highway=construction one need to update custom model server side, for exmaple like this:

{
  "priority":[
    { "if": "road_class != CONSTRUCTION", "multiply_by": "bike_priority" },
    { "if": "road_class == CONSTRUCTION", "multiply_by": "1" },
    { "else_if": "!bike_access && (!backward_bike_access || roundabout)", "multiply_by": "0" },
    { "else_if": "!bike_access && backward_bike_access", "multiply_by": "0.2" }
  ]
}

@karussell karussell merged commit 835f2a2 into graphhopper:master Jun 10, 2024
@karussell
Copy link
Member

Thanks!

@karussell karussell added this to the 10.0 milestone Jun 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0