argmin
argmin copied to clipboard
newton and newton cg freeze rather than stopping
I've seen a few times while developing that newton and newton cg will hang indefinitely sometimes in the case of non-convergence, pegging the CPU with no output.
Thank you for reporting! Could you provide a minimal example to reproduce the issue, please?
I think I've run into a similar issue with BFGS. I think the issue may be with the solvers starting a new optimization problem for the linesearch in the next_iter function, without passing on things like max_iters or timeout. So a single step may run essentially forever for more complex problems as the default of u64::MAX is used. I would think those options should be passed on even though the linesearch problem should be easier to solve.
In my case, changing the width tolerance of the linesearch also solved the issue, suggesting that this is in fact the root cause.