Skip to content
New issue

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

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

Already on GitHub? # to your account

Routing from exact node location #5073

Closed
ZsoltMedgyesi-Itineris opened this issue May 9, 2018 · 5 comments
Closed

Routing from exact node location #5073

ZsoltMedgyesi-Itineris opened this issue May 9, 2018 · 5 comments
Labels

Comments

@ZsoltMedgyesi-Itineris
Copy link

The problem is , when i try routing from a position, which is an exact location of an intersection node, not all the ways from that node are taken into account (in the example case, the link).

Like such:
Relavant OSM segment

Planning schematic

Notes:

  • The green arrow marks the prefered outcome.
  • Black line is the actual outcome (does a turn-around , when its possible, several km-s away).
  • I tried with both routability and duration weight settings, same outcome
  • The profile is based on car.lua
  • Multiple alternatives are turned on, but it does not produce the prefered outcome.
  • All the turn-restrictions and one-ways are checked
@oxidase
Copy link
Contributor

oxidase commented May 9, 2018

@ZsoltMedgyesi-Itineris OSRM uses the nearest OSM way segment to the input location as a starting point of the route. If the input location is exactly at an intersection node and distances from the input point to ways segments are 0 then the first allowed segment in will be used. The order of segments is fixed during generation of the R-tree for segments lookup and can not be changed at the query phase.

A possible solution can be in adding a small delta to the input coordinate in the required direction.

@ZsoltMedgyesi-Itineris
Copy link
Author

ZsoltMedgyesi-Itineris commented May 9, 2018

@oxidase Thanks for the clarification. The problem is, that in the given application waypoints can be 1-10 minutes apart. Which means the direction of the delta in the required way cannot be defined reliably. Trying in multiple directions probably would be a solution, but not an elegant/efficient one.

May you have any other suggestion, or should we close this issue?

@oxidase
Copy link
Contributor

oxidase commented May 11, 2018

@ZsoltMedgyesi-Itineris sorry, i don't know other "easy" solution without OSRM modifications. The correct fix would be to use multiple source/target nodes that have the same distances to the input location that sounds like an easy fix, but the devil is in the detail:

So almost all parts of osrm::engine that are related to the initialization of routing plugins must be modified.

The current issue duplicates #2167, but the previous issue was about synthetic feature tests and the current one presents a real use case.

So I think it is ok to keep it open and close #2167 instead.

@danpat
Copy link
Member

danpat commented May 11, 2018

Also related is #4465, where the fix is basically the same.

Copy link

github-actions bot commented Jul 8, 2024

This issue seems to be stale. It will be closed in 30 days if no further activity occurs.

@github-actions github-actions bot added the Stale label Jul 8, 2024
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Aug 10, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants