potassco / clingo

🤔 A grounder and solver for logic programs.
https://potassco.org/clingo
MIT License
603 stars 80 forks source link

Progression update on USC #357

Closed MaxOstrowski closed 2 years ago

MaxOstrowski commented 2 years ago

When using clingo -t2 or --opt-strat=usc I do get "progression" updates which includes lower and upper bounds. Is there a way to intercept this information during a solve call?

The upper bound can easily be determined using the on_model callback. What about the lower bound ?

This would be useful to emulate features of solvers like cplex that have command line options to stop search if within i.e. 5% range of the optimum.

rkaminsk commented 2 years ago

242 :wink:

MaxOstrowski commented 2 years ago

Awesome, thanks, I haven't found this old Issue and wasn't aware that this is already possible. Thanks a lot guys.

rkaminsk commented 2 years ago

Awesome, thanks, I haven't found this old Issue and wasn't aware that this is already possible. Thanks a lot guys.

You opened it yourself. :smile: