Query Method Used for Automatic Method Parameter
AnsweredHello everyone,
is there a way to query after the solve, which method was actually used, when the model parameter Method is set to "automatic"?
Best,
Lukas
-
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 why not try our AI Gurobot?. -
Hi Lukas,
There is currently no method or attribute to retrieve the winner of the concurrent root relaxation solve. However, you could scan the log output, e.g., via the MESSAGE callback, for a line stating
Barrier solve interrupted - model solved by another algorithm
Solved with dual simplexThe output for primal simplex winning is the same. If Barrier wins then, you will see an output stating
Barrier solved model in ...
If the problem is solved too quickly by one of the Simplex algorithms and Barrier could not even start performing any computation. In this case, it is best (since the root relaxation solution time is so extremely low) to just run the model with Method=0|1|2 and find the winner. It is possible that for very simplex root relaxations time-wise primal and dual simplex are at same pace and only the number of iterations may differ.
Best regards,
Jaromił0 -
Thank you for the reply, I will look into the callback!
0 -
Hi Lukas,
In Gurobi v9.5.0, we introduced the ConcurrentWinMethod attribute which you can use.
Best regards,
Jaromił0
Post is closed for comments.
Comments
4 comments