-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not Freeing Gurobi Environment Between Calculations #43
Comments
The gurobi model should be freed when the JuMP model goes out of scope and is garbage collected. You could try forcing this by calling |
@mlubin This worked perfectly. Thanks so much. |
Hi @mlubin and @philipithomas . I'm not sure if I have the same issue as @philipithomas, but in my case I run a snakemake file with multiple jobs (lp file creation, solving, etc.), one of which is to use gurobi_cl to solve an lp file. It solves the model and provides me with a log of the work, see below:
However, as you see in the last row, I'm getting an error. This causes the workflow not to write out my solution file, under an error " This is after I set the " Looking forward to your comments! :) |
@EmiFej please contact Gurobi support directly: https://www.gurobi.com/support/gurobi-experts/ The Gurobi.jl repository is for the Julia wrapper of Gurobi, which is not an officially supported product, and you don't appear to be using JuMP or Gurobi.jl |
Background
We are using Gurobi.jl with JuMP.jl to run calculations. In a given script, we will run ~100 models. Rather than run the calculations locally, the Gurobi model connects to a Gurobi computation server. (If you're unfamiliar - the only change locally is that the license file says "instead of a license key, I actually point to a server". Everything else is basically the same).
Issue
When running the script, calculations are blocked until they complete on the server. However, when the calculation appears to have completed locally (because it receives a convergent result) - the computation server still shows it as a running calculation. The calculation is not consuming any resources, but it blocks additional calculations and causes the next calculation to block. So, if we limit the computation server to 2 simultaneous calculations - then two begin processing, finish, but continue to block, and all subsequent calculations enter a queued state. They do not get calculated until the original calculations time out.
Proposed Fix
Can we explicitly free the Gurobi environment after a calculation completes? Is there a way to explicitely do this using the JuMP interface?
Debugging
If you need a computation server for testing, I can spin one up - ping me (philip at staffjoy.com)
Gurobi Support Input
The text was updated successfully, but these errors were encountered: