public static final class OptimizationUtils.ExactLineSearch
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
double |
_alphai |
double |
_alphal |
double |
_alphar |
double |
_betaLS1 |
double |
_betaLS2 |
java.lang.String[] |
_coeffNames |
double |
_currGradDirIP |
double[] |
_direction |
GLM.GLMGradientInfo |
_ginfoOriginal |
double |
_lambdaLS |
int |
_maxIteration |
double[] |
_newBeta |
double[] |
_originalBeta |
Constructor and Description |
---|
ExactLineSearch(double[] betaCnd,
ComputationState state,
java.util.List<java.lang.String> coeffNames) |
Modifier and Type | Method and Description |
---|---|
boolean |
evaluateFirstWolfe(GLM.GLMGradientInfo ginfoNew)
Evaluate and make sure that step size alphi is not too big so that objective function is still decreasing.
|
boolean |
evaluateSecondWolfe(GLM.GLMGradientInfo ginfo)
Evaluate and make sure that step size alphi is not too small so that good progress is made in reducing the
loss function.
|
boolean |
findAlpha(double[] lambdaEqual,
double[] lambdaLessThan,
ComputationState state,
ConstrainedGLMUtils.LinearConstraints[] equalityConstraints,
ConstrainedGLMUtils.LinearConstraints[] lessThanEqualToConstraints,
GLM.GLMGradientSolver gradientSolver)
Implements the Line Search algorithm in the doc, Algorithm 11.5.
|
void |
reset(double[] betaCnd,
ComputationState state,
java.util.List<java.lang.String> coeffNames) |
boolean |
setAlphai(boolean firstWolfe,
boolean secondWolfe) |
void |
setBetaConstraintsDeriv(double[] lambdaEqual,
double[] lambdaLessThan,
ComputationState state,
ConstrainedGLMUtils.LinearConstraints[] equalityConstraints,
ConstrainedGLMUtils.LinearConstraints[] lessThanEqualToConstraints,
GLM.GLMGradientSolver gradientSolver,
double[] betaCnd) |
public final double _betaLS1
public final double _betaLS2
public final double _lambdaLS
public double _alphal
public double _alphar
public double _alphai
public double[] _direction
public int _maxIteration
public double[] _originalBeta
public double[] _newBeta
public GLM.GLMGradientInfo _ginfoOriginal
public double _currGradDirIP
public java.lang.String[] _coeffNames
public ExactLineSearch(double[] betaCnd, ComputationState state, java.util.List<java.lang.String> coeffNames)
public void reset(double[] betaCnd, ComputationState state, java.util.List<java.lang.String> coeffNames)
public boolean evaluateFirstWolfe(GLM.GLMGradientInfo ginfoNew)
public boolean evaluateSecondWolfe(GLM.GLMGradientInfo ginfo)
public boolean setAlphai(boolean firstWolfe, boolean secondWolfe)
public void setBetaConstraintsDeriv(double[] lambdaEqual, double[] lambdaLessThan, ComputationState state, ConstrainedGLMUtils.LinearConstraints[] equalityConstraints, ConstrainedGLMUtils.LinearConstraints[] lessThanEqualToConstraints, GLM.GLMGradientSolver gradientSolver, double[] betaCnd)
public boolean findAlpha(double[] lambdaEqual, double[] lambdaLessThan, ComputationState state, ConstrainedGLMUtils.LinearConstraints[] equalityConstraints, ConstrainedGLMUtils.LinearConstraints[] lessThanEqualToConstraints, GLM.GLMGradientSolver gradientSolver)