|
NuriKit v0.1.0b2
|
L-BFGS(-B) minimizer. More...
#include <nuri/algo/optim.h>


Public Member Functions | |
| LBfgs (MutRef< ArrayXd > x, Impl &&impl, const int m=10) | |
| Prepare L-BFGS(-B) minimization algorithm. | |
| template<class FuncGrad> | |
| LbfgsResult | minimize (FuncGrad fg, double factr=1e+7, double pgtol=1e-5, int maxiter=15000, int maxls=20) |
| Minimize a function using L-BFGS(-B) algorithm. | |
L-BFGS(-B) minimizer.
References:
This implementation is based on the C implementation of L-BFGS-B in the SciPy library, which is a translation of the original Fortran code by Ciyou Zhu, Richard Byrd, and Jorge Noceda. Both are released under the BSD 3-Clause License and the original license is included below.
|
inline |
Prepare L-BFGS(-B) minimization algorithm.
| x | Initial guess. Will be modified in-place. |
| impl | Implementation object. |
| m | The maximum number of variable metric corrections used to define the limited memory matrix. |
| LbfgsResult nuri::LBfgs< Impl >::minimize | ( | FuncGrad | fg, |
| double | factr = 1e+7, | ||
| double | pgtol = 1e-5, | ||
| int | maxiter = 15000, | ||
| int | maxls = 20 ) |
Minimize a function using L-BFGS(-B) algorithm.
| FuncGrad | Function object that computes the function value and gradient. Function value should be returned and gradient should be updated in the input gradient vector. |
| fg | Function object. |
| factr | Stop when function value changes by less than this factor times the machine precision. |
| pgtol | Stop when the projected gradient is less than this value. |
| maxiter | Maximum number of iterations. |
| maxls | Maximum number of line search steps. |