Decision Optimization

Expand all | Collapse all

Cplex 20.1: terminate soltion process in candidate context from a generic callback

  • 1.  Cplex 20.1: terminate soltion process in candidate context from a generic callback

    Posted Mon August 02, 2021 03:42 PM
    Hello everyone,

    I would like to terminate the solution process from the candidate context based on some conditions. I've tried using context.abort() but this seems to result in "unknown" cplex status. I wondering why it is this way because being in the candidate context means that cplex has found a feasible solution and the status should be "feasible" (or even "optimal"). Or am I missing something here?

    Best regards,
    Viktor

    ------------------------------
    Viktor Bindewald
    ------------------------------


  • 2.  RE: Cplex 20.1: terminate soltion process in candidate context from a generic callback

    Community Leadership
    Posted Tue August 03, 2021 04:26 AM
    Edited by Xavier Nodet Tue August 03, 2021 04:31 AM
    Hello Viktor,

    Your hypothesis that 

    > the candidate context means that cplex has found a feasible solution 

    is actually incorrect.  The CANDIDATE context is intended to allow the user to reject the solution, but as the documentation says in https://www.ibm.com/docs/en/icos/20.1.0?topic=context-cpx-callbackcontext-candidate: If the callback is invoked for a feasible point and does not reject the candidate, this is no guarantee that the candidate will become the new incumbent. The callback is only one of many feasibility tests that are performed on a candidate solution.

    In other words, the CANDIDATE context is a tool to ensure the soundness of the results, it's not a tool to measure progress.

    I hope this helps.


    ------------------------------
    Xavier
    ------------------------------