-
Notifications
You must be signed in to change notification settings - Fork 63
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
cbgetlpsolution returns assertionerror #171
Comments
Can you provide a complete exmaple that demonstrates the problem? See https://stackoverflow.com/help/mcve |
A simple MWE (based on knapsack.jl) of the problem I have. I want to get the fractional LP value of variable x at the root node. However, I get a warning here:
In the earlier case, I queried for the lpsolution instead of the values of x. That returned me an assertionerror. |
I haven't used the callbacks in CPLEX, however it looks like the solution is only available for You could try The new version of JuMP will not support solver independent callbacks. The behaviour is too solver-dependent. |
Is this behaviour independent of the solver? I mean if I switch to another solver, lets say Gurobi, the solution would still not be available? |
Presumably you're trying to follow https://discourse.julialang.org/t/accessing-the-root-node-solution/10371/7? This is not a CPLEX.jl issue. The infocallback only supports querying the LP solution in the following states The variable values are not available for I'm not sure what the story with Gurobi is, but according to |
I tried |
Closing this since it relates to the old JuMP callbacks, which we won't be fixing. The new MOI wrapper implements solver-independent MOI callbacks, and provides access to solver-specific generic CPLEX callbacks. |
I'm trying to collect some info using an
infocallback
illustrated in the callback section of the JuMP document. When I try to access the fractional lp solution at the root node usingcbgetlpsolution
within the infocallback function, I get an assertion error. This is the function I use to add the infocallback to the model.addinfocallback(mdl, infocallback, when = :Intermediate)
The objective is to access the fractional solution similar to this. How can I achieve this in JuMP?
The text was updated successfully, but these errors were encountered: