Debugging in JuMP

(Soft Question):

If I try to solve a problem in JuMP, and I get an error or a solution that doesn’t make sense, it usually means I incorrectly coded or misspecified the problem I was trying to solve. I can try to proofread my code or check my math, but sometimes this is hard. I would like to be able to get some feedback from JuMP about what is going wrong.

In general, is there a way I can see (in various levels of detail) the steps of the algorithm its doing on my problem, with actual numbers? That may give me a sense of what the problem is.

The regular output (see below) does show me some info for each iteration such as objective value, but I would like to see a bit more detail such as decision variables at each iteration.

1 Like

I recently wrote a tutorial on this sort of thing;

In general, is there a way I can see (in various levels of detail) the steps of the algorithm its doing on my problem, with actual numbers?

No, because most solvers do not have this capability.

If you want specific advice, please post a reproducible example. Your screenshot just shows up as a grey screen for me. (Take a read of Debugging · JuMP as well.)

1 Like