pyomo icon indicating copy to clipboard operation
pyomo copied to clipboard

SCIP Solver Results undefined/unknown/inf

Open goghino opened this issue 5 years ago • 5 comments

After solving a model (code here) using SCIP (SCIP version 7.0.1 [precision: 8 byte] [memory: block] [mode: optimized] [LP solver: SoPlex 5.0.1] [GitHash: b41d526acf]), the results components (i.e. gap, bounds, sense) remain undefined or inf, as shown below. The solution is correct though, the same as found with Gurobi (version 9.0.1 build v9.0.1rc0 (mac64)). The bounds and gap shown in the solver output (tee=True) is also the same as in case of Gurobi. What can be done about correctly setting the results object?

solver = pyo.SolverFactory('scip')
results = solver.solve(m, keepfiles=True, tee=True, load_solutions=False)

results.write()

if results.solver.termination_condition == pyo.TerminationCondition.optimal:
    m.solutions.load_from(results)

m.pprint()
# ==========================================================
# = Solver Results                                         =
# ==========================================================
# ----------------------------------------------------------
#   Problem Information
# ----------------------------------------------------------
Problem: 
- Lower bound: -inf
  Upper bound: inf
  Number of objectives: 1
  Number of constraints: 0
  Number of variables: 20
  Sense: unknown

goghino avatar Sep 08 '20 12:09 goghino

I have the same issue with SCIP 8.0.0 and Pyomo 6.2.

pmlpm1986 avatar May 17 '22 13:05 pmlpm1986

I also have this same issue with Pyomo 6.6.2 and SCIP 8.0.4.

Problem: 
- Lower bound: -inf
  Upper bound: 46259048.8645032
  Number of objectives: 1
  Number of constraints: 0
  Number of variables: 97146
  Sense: unknown
Solver: 
- Status: ok
  Message: optimal solution found
  Termination condition: optimal
  Id: 0
  Error rc: 0
  Time: 143.75
  Gap: 0.0
  Primal bound: 46259048.8645032
  Dual bound: 46259048.8645032
Solution: 
- number of solutions: 0
  number of solutions displayed: 0

hygorxaraujo avatar Oct 30 '23 16:10 hygorxaraujo