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 a nearestOsrmNodeNetworkDistance to access and egress steps #293

Open
kaligrafy opened this issue Apr 30, 2024 · 13 comments
Open

Add a nearestOsrmNodeNetworkDistance to access and egress steps #293

kaligrafy opened this issue Apr 30, 2024 · 13 comments

Comments

@kaligrafy
Copy link
Collaborator

We should be able to know what is the bird distance between the origin/destination and the nearest routing node. See #62 for possible implementation.

@greenscientist
Copy link
Contributor

@kaligrafy , can you specify to which API calls in https://chairemobilite.github.io/trRouting/APIv2/index.html this need to be added and details a little bit more with example the new data field ?

@kaligrafy
Copy link
Collaborator Author

kaligrafy commented Apr 30, 2024

This should appear in any result step data that is access or egress.
result.routes[].accessOriginBirdDistanceToNearestRoutingNode
result.routes[].egressDestinationBirdDistanceToNearestRoutingNode

Also in TripStep: access/egress, but tripStep is not yet documented in v2

@greenscientist
Copy link
Contributor

So this distance is the distance to the closest point in OSM that is connected to our route? could be any kind of point ?

@kaligrafy
Copy link
Collaborator Author

kaligrafy commented Apr 30, 2024

This should be a coordinate in a osm way, this would be the first/last coordinate of the OSRM route. This could be a OSM node but could also be a point interpolated between nodes on a way

@kaligrafy
Copy link
Collaborator Author

kaligrafy commented Apr 30, 2024

If you route from/to the middle of a large field, the starting/ending point will be snapped to the nearest way and an interpolated point will be added on the first/last way if it does not match a specific OSM node. At least that is how OSRM works. You can get this interpolated coordinate by using the nearest API route in OSRM: https://project-osrm.org/docs/v5.24.0/api/#nearest-service
However, the nearest api route does not seem to interpolate in between nOSM nodes when the nearest point on a way is between actual nodes. We should use the exact nearest coordinate, even if it is an interpolation.

@greenscientist
Copy link
Contributor

Shoud we really add new fields or just have that as a tripStep ?

@kaligrafy
Copy link
Collaborator Author

Both please

@kaligrafy
Copy link
Collaborator Author

This is a quite important information to assess the quality of the geocoding for origin and destination, and can explain some difference between calculated routing and bird distances.

@greenscientist
Copy link
Contributor

Why is having the information just is the trip not enough? I'm trying to keep the API as simple as possible.

@greenscientist
Copy link
Contributor

Also, if possible, could you point to an issue, maybe in transition, that would make use this feature ?

@kaligrafy
Copy link
Collaborator Author

This information must be available in the summary, since we may not always need the steps data for analysis, especially in big simulations. However, this info is mandatory to find possible errors in OSM data or in geocoding results.

@kaligrafy
Copy link
Collaborator Author

See chairemobilite/transition#373

@kaligrafy
Copy link
Collaborator Author

This must be done for all mode routings (not only transit/walking)

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

No branches or pull requests

2 participants