Gurobi with WorkLimit and pyomo
AnsweredHi,
I am using gurobi with a defined WorkLimit to solve a pyomo MILP.
In case the MILP is infeasible I can nicely access the solver status, which indicates "termination condition: infeasibleOrUnbounded".
But in case gurobi stops because it hits the WorkLimit I could not figure out how to access any solver status. Pyomo just states: ValueError: Cannot load a SolverResults object with bad status: error
Is there any way to access in this case the gurobi solver status?
Thanks for your support.
Fabian
-
Official comment
This post is more than two 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. -
Which version of Pyomo are you using? I could reproduce that error with Pyomo 6.4.2, but not Pyomo 6.4.3 and later. It looks like Pyomo 6.4.3 fixed a bug with how Pyomo handled Gurobi's WORK_LIMIT status. See Pyomo/pyomo#2530.
0 -
Thanks a lot for this hint, this solved my issue!
0
Post is closed for comments.
Comments
3 comments