[SCIP] No objective value after presolving was interrupted

Gerwin Gamrath gerwin.gamrath at complevo.de
Thu Nov 7 15:55:18 CET 2019


Hello,

I am optimizing a model via pyscipopt.

Right after
self.model.optimize()

I want to
objective_value = self.model.getObjVal()

but (in some cases) I get the following warning:
"Warning: method cannot be called before problem is solved"

(because of:
if not self.getStage() >= SCIP_STAGE_SOLVING: )


But for me it looks like, there should be an objective value (=primal bound) existent at this time...
(See below for the relevant log)

Thanks,
Gerwin
--------------


# SCIP version 6.0.1

# solving stops, if the relative gap = |primal - dual|/MIN(|dual|,|primal|) is below the given value
# [type: real, advanced: FALSE, range: [0,1.79769313486232e+308], default: 0]
limits/gap = 0.0001

# maximal number of presolving rounds the presolver participates in (-1: no limit)
# [type: int, advanced: FALSE, range: [-1,2147483647], default: -1]
presolving/symbreak/maxrounds = 0

wrote parameter settings to file param.set
solution violates original bounds of variable <x1> [0,0] solution value <100000>
solution violates original bounds of variable <x2> [0,0] solution value <1>
solution violates original bounds of variable <x3> [0,0] solution value <1>
1/4 feasible solution given by solution candidate storage, new primal bound 8.503167e+02

presolving:
(round 1, fast)       601 del vars, 2619 del conss, 0 add conss, 2807 chg bounds, 0 chg sides, 0 chg coeffs, 0 upgd conss, 0 impls, 0 clqs
(round 2, fast)       3282 del vars, 2619 del conss, 0 add conss, 2946 chg bounds, 0 chg sides, 0 chg coeffs, 0 upgd conss, 0 impls, 1 clqs
(round 3, fast)       3287 del vars, 2624 del conss, 0 add conss, 2948 chg bounds, 0 chg sides, 0 chg coeffs, 0 upgd conss, 0 impls, 2 clqs
(round 4, fast)       3289 del vars, 2722 del conss, 0 add conss, 2948 chg bounds, 0 chg sides, 0 chg coeffs, 0 upgd conss, 0 impls, 2 clqs
(round 5, fast)       3396 del vars, 2722 del conss, 0 add conss, 2948 chg bounds, 0 chg sides, 0 chg coeffs, 0 upgd conss, 0 impls, 2 clqs
(round 6, exhaustive) 3396 del vars, 2777 del conss, 0 add conss, 2948 chg bounds, 6 chg sides, 0 chg coeffs, 0 upgd conss, 0 impls, 2 clqs
(round 7, fast)       3401 del vars, 2779 del conss, 0 add conss, 2948 chg bounds, 6 chg sides, 0 chg coeffs, 0 upgd conss, 0 impls, 0 clqs
(round 8, fast)       3404 del vars, 2779 del conss, 0 add conss, 2951 chg bounds, 6 chg sides, 0 chg coeffs, 0 upgd conss, 0 impls, 1 clqs
presolving (8 rounds: 8 fast, 1 medium, 1 exhaustive):
3404 deleted vars, 2779 deleted constraints, 0 added constraints, 2951 tightened bounds, 0 added holes, 6 changed sides, 0 changed coefficients
0 implications, 1 cliques
presolving was interrupted.
Presolving Time: 0.00

SCIP Status        : solving was interrupted [gap limit reached]
Solving Time (sec) : 0.00
Solving Nodes      : 0
Primal Bound       : +8.50316660000000e+02 (2 solutions)



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listserv.zib.de/pipermail/scip/attachments/20191107/727efd01/attachment.html>


More information about the Scip mailing list