optimizationscipylinear-programming

How to get final attempted solutions from scipy.optimize.linprog when problem is infeasible


Per scipy.optimize.linprog documentation:

Callback functions are not currently supported by the HiGHS methods.

This is not good for my use case, where the final "attemped" solution is valuable even if the problem itself is infeasible.

For now I can resort to one of the legacy methods ("simplex", "revised simplex", "interior-point") to get the final attempted output. Problem is the legacy ones will soon be deprecated.

Does anyone know if there is any plan to add the callback functionality for the "HiGHS" method, or is it that this method in theory doesn't have an "interim" stage at all?


Solution

  • There is a plan to add a callback to HiGHS, and the legacy methods will not be removed until that is complete. The first step is to change from the custom Python bindings to those provided by the developers of HiGHS. This was attempted in gh-19255, but that was temporarily reverted due to some issues. When those are resolved, gh-19420 will be updated and merged to add callback support to HiGHS. More context is available in gh-19451 and gh-15707