argmin icon indicating copy to clipboard operation
argmin copied to clipboard

newton and newton cg freeze rather than stopping

Open 0xAlcibiades opened this issue 1 year ago • 3 comments

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.

0xAlcibiades avatar Apr 26 '24 05:04 0xAlcibiades

Thank you for reporting! Could you provide a minimal example to reproduce the issue, please?

stefan-k avatar May 01 '24 15:05 stefan-k

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.

gmanthey avatar Sep 28 '24 11:09 gmanthey

In my case, changing the width tolerance of the linesearch also solved the issue, suggesting that this is in fact the root cause.

gmanthey avatar Sep 28 '24 12:09 gmanthey