[Python] Disabling Crossover using HiGHS Solver and Linopy

Discussão em 'Python' iniciado por Stack, Março 3, 2025.

  1. Stack

    Stack Membro Participativo

    I have implemented a linear programme using Linopy and use the HiGHS solver to solve it with the interior point method.

    For this application, I don't need to run crossover on the solution. When I pass the run_crossover='off' option to HiGHS through linopy, HiGHS behaves as expected and skips the crossover step, however, linopy does not consider the model optimised when this step is omitted. Do you know how to obtain the solution from linopy in this scenario?

    Example log message from HiGHS:

    Ipx: IPM optimal
    WARNING: LP solver residuals: primal = 0.0710581; dual = 0.0473415 yield num/max/sum primal (391784/0.0710581/6.24267) and dual (463677/0.0473415/3.47325) corrections
    WARNING: Unwelcome IPX status of Unknown: basis is not valid; solution is valid; run_crossover is "off"
    Model name : linopy-problem-m_vf1rkb
    Model status : Unknown
    IPM iterations: 48
    Objective value : -2.8809874134e+07
    Relative P-D gap : 7.5484672674e-01
    HiGHS run time : 141.71
    Writing the solution to /private/var/folders/4p/qywpknvj5qx89qh1g6vy1qlc0000gn/T/linopy-solve-28b76k6g.sol


    And the following log message from linopy:

    Solution status unknown. Trying to parse solution.
    Optimization failed:
    Status: unknown
    Termination condition: unknown
    Solution: 1786176 primals, 1456848 duals
    Objective: -2.88e+07
    Solver model: available
    Solver message: unknown

    Continue reading...

Compartilhe esta Página