JuliaSmoothOptimizers / LinearOperators.jl

Linear Operators for Julia
Other
150 stars 32 forks source link

Improve DiagonalQN stability when s is close to zero #271

Closed geoffroyleconte closed 1 year ago

geoffroyleconte commented 1 year ago

This PR essentially consists of dividing the equation

$$s^T B s = s^T y$$

in the QN update by $||s||_2^2$ to handle better small $s$ values. I put some storage vectors in the DiagonalQN struct to avoid allocating them at every push! call.

codecov[bot] commented 1 year ago

Codecov Report

Patch coverage: 85.71% and project coverage change: +0.01 :tada:

Comparison is base (106f083) 97.42% compared to head (0806b02) 97.43%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #271 +/- ## ========================================== + Coverage 97.42% 97.43% +0.01% ========================================== Files 14 14 Lines 1009 1013 +4 ========================================== + Hits 983 987 +4 Misses 26 26 ``` | [Impacted Files](https://codecov.io/gh/JuliaSmoothOptimizers/LinearOperators.jl/pull/271?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaSmoothOptimizers) | Coverage Δ | | |---|---|---| | [src/DiagonalHessianApproximation.jl](https://codecov.io/gh/JuliaSmoothOptimizers/LinearOperators.jl/pull/271?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaSmoothOptimizers#diff-c3JjL0RpYWdvbmFsSGVzc2lhbkFwcHJveGltYXRpb24uamw=) | `95.74% <85.71%> (+0.39%)` | :arrow_up: | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaSmoothOptimizers). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaSmoothOptimizers)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

github-actions[bot] commented 1 year ago
Package name latest stable
CaNNOLeS.jl
DCISolver.jl
FletcherPenaltySolver.jl
JSOSolvers.jl
Krylov.jl
NLPModels.jl
NLPModelsModifiers.jl
PROPACK.jl
Percival.jl
QuadraticModels.jl
SolverTools.jl