Obsolote parameter `min_num_lns_workers`
Closed this issue · 4 comments
Hi @d-krupke, great work on the CP-SAT primer! It's easy to read, and the interleaved code examples make it very practical. I'm definitely going to recommend your book to others who are interested in CP-SAT.
I was reading chapter 5 and this part stood out to me:
If you want to use more workers heuristically searching for good solutions, you can specify solver.parameters.min_num_lns_workers.
In the proto specification for parameters, there's a comment about min_num_lns_workers
being a no-op:
This changed about eight months ago:
https://github.com/google/or-tools/blame/v9.8/ortools/sat/sat_parameters.proto#L571
My suggestion would be to remove the line about this parameter in chapter 5 or to replace it with another parameter, but I'm not familiar enough yet with CP-SAT know which one.
Hi Leon,
Thanks for the kind words: that really motivates me keep doing it!
Good catch! I will check it out and update it accordingly as soon as I have a few minutes to spare. This has been one of the more popular parameters in the past (AFAIK), so I should document that properly.
If you notice anything further, please let me know. CP-SAT is currently developing so fast that it is hard to keep everything up to date.
Bets,
Dominik
Sounds good! I'm diving into CP-SAT myself right now for some scheduling problems, so I will do my best to help update.
Finally found some time: Simply deleting the line is indeed the best solution. While there are options to reproduce the parameter's behavior, they are not pretty and use_lns_only
should actually suffice for most use cases, as usually you either want a systematic search of the solution space, or you just want to optimize until you run out of time (though, use_only_lns
will not always give a benefit in this case).
If one has the time/need to do elaborate tuning, specifying the concrete strategies manually would be the best option.
Thanks again! Closing this issue.