-
Notifications
You must be signed in to change notification settings - Fork 401
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
Performance Degradation in Distance/Time Matrix Calculation with Avoid Areas when Handling Many Locations #1815
Comments
@TiagoDelatorre Thanks for opening this. Please share your openrouteservice config/setup with us so we can better understand what is going on. |
Thank you very much for your attention. I work in Brazil, where unfortunately cargo theft is a constant concern, especially in certain regions considered high-risk. For this reason, it is essential for our operation to use avoidance areas (avoid_polygons), as we need to avoid these zones when routing and generating distance matrices. I noticed that with a few areas to avoid, the matrix generation works correctly. However, when I specify a larger number of areas in the avoid_polygons parameter, there is a significant drop in performance. Knowing that this feature is not yet officially available on the Matrix endpoint, I would like to ask if there is any way to optimize the use of multiple avoidance areas, or if you have any suggestions to improve this point without compromising the performance of the service. Thank you again for your willingness to help, and I look forward to your guidance. Best regards, ########docker-compose######## services: ########ors-config######## |
Unfortunately, there is no solution for this issue yet. To account for avoid areas, ORS must fall back to a more flexible, but slower routing algorithm. We are in the process of investigating alternative algorithms but this is rather a long-term project. Depending on your programming skills you might preprocess your OSM dataset and set a very low speed limit in the areas to avoid. |
Is there an existing issue for this?
Where did you encounter this issue?
self-hosted instance
Request URL
/v2/matrix/driving-car
POST Request Body
Response
Not responding
Current behavior
I am experiencing significant performance issues when calculating distance/time matrices using the service that supports avoid areas, particularly when dealing with many locations. Initially, the processing time to generate the matrix between specific points is approximately 2.3 seconds. However, when including designated avoid areas, the processing time increases drastically.
Expected behavior
The distance/time matrix calculation service, which supports avoid areas, is expected to maintain consistent and efficient performance regardless of the inclusion of these additional areas
Openrouteservice Version
8.1.0
Build date
2024-06-05T10:07:23Z
Graph date
2024-07-15T23:16:52Z
Forum Topic Link
No response
The text was updated successfully, but these errors were encountered: