Hi;
I’m trying to understand how to implement a checkpoint in snakemake to handle infeasible solutions in a workflow. This could be relevant to many of us using snakemake and workflows in our work, and perhaps this problem is solved already?
When solving an optimisation problem using a solver, there are three main outcomes:
- a successful solve producing a .sol file
- an infeasible solve (or time out), no output produced
- an infeasible solve, but an analysis file is produced e.g. a .ILP from Gurobi or ISS from CPLEX
These three alternatives create a problem in a workflow, as outcomes 2 and 3 cause the entire workflow to fail. But a desirable outcome would be for the workflow to continue for successful solves (creating plots etc.) and another branch of tasks could set to work on providing useful debugging information on the failed solves.
One solution seems to be to use a snakemake checkpoint, which recomputes the workflow upon the completion of the solve step. The documentation (and concept) is not straightforward. Could anyone help me understand how to go about implementing this?