Obtain information on lazy constraint and user cut introduced
AnsweredHi,
May I know how to obtain the corresponding information after applying lazy constraint/user cut for an optimization problem?
such as how much time does it take, or the number of lazy constraints actually activated/inserted etc.
Thank you!
-
Official comment
This post is more than three years old. Some information may not be up to date. For current information, please check the Gurobi Documentation or Knowledge Base. If you need more help, please create a new post in the community forum, or try Gurobot, our chatbot interface offering instant, expert-level support. -
such as how much time does it take, or the number of lazy constraints actually activated/inserted etc.
It is not possible to retrieve information on how long did Gurobi take to insert and process a lazy constraint. However, you can track this yourself in your callback code. Gurobi reports time spent in callbacks at the end of its log.
It is also not possible to get the number of lazy cuts inserted/activated, cf. Get numbers of lazy constraints added. Again, you can track it on your own. Please note that it is not guaranteed that one a lazy constraints is inserted into your model, that it will be used throughout the whole optimization process, cf. User cuts are not counted in the MIP log and Callback cut count and cut count in the MIP log are not equal.
Best regards,
Jaromił0
Post is closed for comments.
Comments
2 comments