google-research / FirstOrderLp.jl

Experimental first-order solvers for linear and quadratic programming.
Apache License 2.0
103 stars 19 forks source link

Default tolerances #111

Open ohinder opened 1 year ago

ohinder commented 1 year ago

There appears to be no defaults for

absolute_optimality_tol relative_optimality_tol eps_primal_infeasible eps_dual_infeasible

However if these values are not specified the solver does not throw an error.

mlubin commented 1 year ago

Looks like the defaults are here: https://github.com/google-research/FirstOrderLp.jl/blob/e2792c8dd7edde6d6d20da16954dfeb2db42eca8/src/termination.jl#L102-L105

ohinder commented 1 year ago

Thanks! I think I might have even written that code. Haha. Do you think we should point to this in solver_qp.jl?

ohinder commented 1 year ago

I got a little confused when looking at solver_qp.jl at the command line arguments help descriptions to understand what happens by default.

ohinder commented 1 year ago

Maybe we could add something to the --help?

mlubin commented 1 year ago

We have this: https://github.com/google-research/FirstOrderLp.jl/blob/4ccab200d4247dec930754fa47e6517860dd45ec/scripts/solve_qp.jl#L367-L370

What do you propose to add to --help?

ohinder commented 1 year ago

Oh I missed that. I guess I was suggesting adding to --help the default value for each of these parameters or a pointer to termination.jl. Admittedly, I missed this comment so maybe it is fine as it is.

mlubin commented 1 year ago

Copying the default values in the help message is a bad idea because they will become stale if the defaults change. Other tweaks to --help would be fine.