Is there a simple Optimizer-independent way to set tolerances in JuMP? I searched the documentation and couldn’t find anything on setting tolerances [I’m tired of multiplying my objective functions by large numbers ]
This is probably trivial if you know how to do it, and probably easy to find if you know where to look
Because if my objective is 1000 times larger, this is equivalent but will automatically make my answer more precise. It is admittedly a clumsy way, but I don’t know another convenient way to achieve this.
Note that this will only affect absolute tolerances. Some solvers use relative tolerances (e.g., the relative gap when solving a MIP).
The bigger question to think about is why this is necessary. Solvers don’t use exact arithmetic, so you should always anticipate some tolerance. Instead of changing the tolerance, you’re usually better off reformulating the model to use different units. So if your objective value comes out to be much less than 1, you should probably use variables with units of millimeters instead of meters, for example.