-
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
Heuristic route fix as a local search move #978
Conversation
The advantage of using a regular heuristic instead of the TSP code would have been that it embeds the validity check and could potentially work in all contexts regardless of the constraints. The limitations I saw when testing are:
The bottom line here is that applying the TSP code embeds the dedicated local search we have inside that code, so the solutions we come up with (if valid) are much better out of the box. The heuristic operator may provide solution that have a good potential for further improvements by other operators, but we don't know that and often discard these options based on not having any gain. So the state here is that I still think it's really helpful to apply the TSP-based operator on some specific use-cases, but we should not add a too high computing overhead for situations where this is not really efficient. Thus the next steps are:
|
I've run a few tests and we definitely don't want to pay the price for this operator in non-favorable situations such as the usual VRPTW benchmarks: the computing time overhead is significant but the change in solutions is marginal because the new operator is seldom applied. In this situation we spend most of the added time trying route changes that are bound to fail because of tight TW constraints preventing most of the reordering options. I went for a strong vehicle-level criterion to decide whether we should apply this operator or not: a vehicle has a "green light" flag if the intersection of all its compatible jobs TW contain the vehicle TW. This is quite demanding but does in particular cover any situation like CVRP, problems where all jobs have default TW or all jobs/vehicles have the same TW. Maybe this criterion could be refined at some point, for example by checking only jobs in the current vehicle route. This may allow to run the operator on most of the routes say if only a single job has a TW constraint. But then we'd have to make the flag dynamic and update it upon each modification. For now I'm happy with a demanding criterion which means we get the benefit on obviously interesting instances, but we don't pay any computing time price on tighter instances. |
Issue
This PR is a WIP toward fixing #737
Tasks
CHANGELOG.md