i am trying to optimize a quadratic objective function in pyomo with cplex solver and i get this CPLEX Error 5002: objective is not convex. QP with an indefinite objective can be solved to local optimality with optimality target 2, or to global optimality with optimality target 3. From IBM manual i got to know that we should Set optimalitytarget parameter in pythonI have this globalqpex1.py and now how can i set the parameter can someone explain how to set up this parameter
it is given that i can run python globalqpex1.py g global optimum but i dont have any .sav or .lp files and i dont know what they are...furthur more I found in the manual that I can solve this problem by seting parameters.optimalitytarget in python how and where should i add c.parameters.optimalitytarget.set(1)
this is the error i get CPLEX Error 5002: objective is not convex. QP with an indefinite objective can be solved to local optimality with optimality target 2, or to global optimality with optimality target 3. Presolve time = 0.00 sec. (0.00 ticks) Barrier time = 0.00 sec. (0.00 ticks)
Error termination, CPLEX Error 5002. Solution time = 0.00 sec. Deterministic time = 0.00 ticks (0.49 ticks/sec)
CPLEX> CPLEX Error 1217: No solution exists. No file written. CPLEX> [ 0.05] Pyomo Finished ERROR: Unexpected exception while loading model: Cannot load a SolverResults object with bad status: error