Decision Optimization

 View Only
  • 1.  Pause CPLEX

    Posted Tue June 22, 2021 06:50 PM
    Hi everyone.

    Sorry for my ignorance. I'm trying to follow the instructions at

    https://www.ibm.com/support/pages/stop-cplex-optimization-run-and-resume-it-later-time

    I'm optimizing a problem in LP format using CPLEX_Studio128, where all variables are binary. CPLEX is running for a long time after the following standard shell commands:

    CPLEX> read filename.lp
    CPLEX> optimize

    I was told that in a day or two there will be a power interruption at my place of work. So before that happens I will need to stop CPLEX, apply some appropriate shell commands, and exit CPLEX. Once the power comes back on I would like to resume optimization from where it stopped.

    I've run some test examples to try and follow the instructions in the above link and got the following error:

    CPLEX> write filename.bas
    CPLEX Error 1262: No basis exists.

    I also tried:

    CPLEX> write filename.mst

    CPLEX Error  3020: No MIP start exists.
    No file written.

    Can someone please tell me the explicit commands I need to enter before exiting CPLEX so that I can resume where I was during the optimization procedure?

    Thank you,

    Marcus.

    ------------------------------
    Marcus Garvie
    ------------------------------

    #DecisionOptimization


  • 2.  RE: Pause CPLEX
    Best Answer

    IBM Champion
    Posted Wed June 23, 2021 04:21 PM
    Since your problem is an integer program, trying to write a basis file at the point of interruption would make no sense. Writing the current integer solution to an MST file and then loading it as a MIP start (after loading the problem) when you are ready to resume would be a valid approach. The catch is that this works only if CPLEX has found an integer feasible solution at the point that the first run is interrupted. I'm pretty sure error 3020 is being thrown because you do not yet have a feasible solution. Try your second approach after running long enough to have an incumbent.

    ------------------------------
    Paul Rubin
    Professor Emeritus
    Michigan State University
    ------------------------------