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

Discourage Roads with tracks on them #76

Open
abhumbla opened this issue Apr 29, 2022 · 4 comments
Open

Discourage Roads with tracks on them #76

abhumbla opened this issue Apr 29, 2022 · 4 comments
Labels
feature not a bug

Comments

@abhumbla
Copy link

try not to route down them (if there's no protected bike infra) and be careful with turns. not quite sure how to formalize this, just don't like this routing down church
Screenshot_20220429-162835

@hcourt
Copy link

hcourt commented May 6, 2022

The way this is mapped on this stretch is with railway=level_crossing nodes.

image

@abhumbla
Copy link
Author

abhumbla commented May 6, 2022

Thinking about this, we don't need to discourage roads with tracks if there are other lanes like @graue was saying, but turning onto a road with tracks is potentially hazardous so maybe we could incorporate this into the turn cost stuff you were working on @hcourt ?

@hcourt
Copy link

hcourt commented May 6, 2022

@abhumbla yes, I think so. It's at least related and depending on how these crossings are processed into edges, might be easy to add into that code.

That and this issue kinda brings up something I've been thinking for turn costs, that in addition to ways having encoded penalties that affect the weight (BikeCommonFlagEncoder et al), nodes need that too.

Currently there is one (1) way that node tags affect routing, which is if the node is a barrier then don't route through it. And it's done pretty hackily, by creating artificial ways split at the barrier, adding artificial tags to that way, and then saying access=no or whatever on the way. We could replicate/piggyback on that hack for track crossings & signals (for turn costs). I'm a little eager (perhaps too much) to sink into the mud of adding per-node penalties though lol. Talk me down from writing that refactor?

@abhumbla
Copy link
Author

abhumbla commented May 6, 2022

I trust you, go for it if you think it'll make the code less hacky and conceptually easier to understand

@hcourt hcourt added the feature not a bug label Aug 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature not a bug
Projects
None yet
Development

No branches or pull requests

2 participants