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

wrong node number in route #6016

Closed
milos106 opened this issue Apr 21, 2021 · 1 comment · Fixed by #6020
Closed

wrong node number in route #6016

milos106 opened this issue Apr 21, 2021 · 1 comment · Fixed by #6020

Comments

@milos106
Copy link

I would like to note you for a small mistake in your api.
When you run your api:
http://router.project-osrm.org/route/v1/driving/14.89857049,50.4026181;14.9366725,50.3229582?alternatives=false&annotations=nodes

All nodes are right from the same area in Czech Republic, but node nr.34819412 is from Norway!!!

I've treated it in my application, but it can be unpleasantly for others...

@danpat
Copy link
Member

danpat commented Apr 21, 2021

This looks like an overflow bug - we've got the coordinate correct here, at lon,lat 14.933584,50.327384 - the correct node is https://www.openstreetmap.org/node/8624754004

We're currently only allowing 33 bits for storing OSM node IDs -

using PackedOSMIDs = util::detail::PackedVector<OSMNodeID, 33, Ownership>;

8624754004 is 34 bits wide (1000000010000100110100110101010100 or 0x202134D54). Looks like we need to bump up the hardcoded 33 value in packed_osm_ids if we want newly mapped regions to have correct annotations.

We support the full 64 bit number space during graph generation, so I don't think this will lead to weird routing errors, just incorrect node annotation values for newly mapped locations.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants