Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Implement exclude flags for CH #6821

Unanswered
hahaking119 asked this question in Q&A
Discussion options

Hello, I would like to know if the CH algorithm already supports the exclude parameter.
I set exclude = ferry when using it. If there is only one route and it contains a link with the ferry attribute, then this route will be recalled.
Is this normal? thank you.

You must be logged in to vote

Replies: 5 comments

Comment options

Yes, it's supported by the CH algorithm. You need to make sure that excludable is set in the Lua profile, like it is by default here:

https://github.com/Project-OSRM/osrm-backend/blob/master/profiles/car.lua#L123-L128

That setting will cause OSRM to generate multiple versions of the CH graph, each graph will have those edges removed. At query time, you can do exclude=ferry or exclude=motorway or exclude=toll and OSRM will perform the route calculation on the graph prepared for that option.

Every excludable you add to the Lua script makes the dataset bigger and causes processing to take longer.

You must be logged in to vote
0 replies
Comment options

But I set the excludable parameter in bicycle.profile and specified exclude = ferry when calling the interface, and the engine still returns a result containing ferry. What is the reason for this?
image

You must be logged in to vote
0 replies
Comment options

Did you re-run osrm-contract after updating the bicycle.lua file? That is a required step.

You must be logged in to vote
0 replies
Comment options

yes,I already run osrm-contract with the bicycle.lua file.
I also want to know the key of ferry is route or highway?

You must be logged in to vote
0 replies
Comment options

Hi @hahaking119 , Did you manage to do this? Because i'm trying to exclude unpaved, but is not working.

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
Converted from issue

This discussion was converted from issue #6732 on March 05, 2024 16:56.

AltStyle によって変換されたページ (->オリジナル) /