-
Notifications
You must be signed in to change notification settings - Fork 340
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
VRP with a single location #291
Comments
I went ahead and opened a pull-request just in case. |
Kind of an edge case, but definitely a bug. The A clean fix would be to add a boolean member along the line of |
I see the fix you suggested. I will modify the pull request accordingly. |
Sorry for the radio silence. I'll look into it now. |
Ready for review. |
The following VRP problem with a single location (note that all location indices are 0) but with a 2x2 matrix returns the expected solution with zero cost.
However, if the matrix is replaced by a 1x1 matrix, then vroom tries to connect to OSRM and fail with the following error
{"code":3,"error":"Failed to connect to 0.0.0.0:5000"}
(since there is no lat/lon, even if the connection succeeds, the query would fail anyway).I believe the offender is
if (_matrix.size() < 2) {
check on src/structures/vroom/input/input.cpp:332 inside solve function.Is the check against
2
is necessary? It seems to me that1
does the job well.The text was updated successfully, but these errors were encountered: