InputType
- Input class of the Evaluator that we are trying to minimize, such as VectorOutputType
- Output class of the Evaluator that we are trying to minimize, such as DoubleEvaluatorType
- Evaluator class that this minimization algorithm can handle, such as
Evaluator or DifferentiableEvaluator.public abstract class AbstractAnytimeFunctionMinimizer<InputType,OutputType,EvaluatorType extends Evaluator<? super InputType,? extends OutputType>> extends AbstractAnytimeBatchLearner<EvaluatorType,InputOutputPair<InputType,OutputType>> implements FunctionMinimizer<InputType,OutputType,EvaluatorType>
Modifier and Type | Field and Description |
---|---|
protected InputType |
initialGuess
Initial guess of the minimization routine
|
protected InputOutputPair<InputType,OutputType> |
result
Resulting minimum input-output pair
|
protected double |
tolerance
Tolerance of the minimization algorithm, must be >= 0.0
|
data, keepGoing
maxIterations
DEFAULT_ITERATION, iteration
Constructor and Description |
---|
AbstractAnytimeFunctionMinimizer(InputType initialGuess,
double tolerance,
int maxIterations)
Creates a new instance of AbstractStandardIterativeMinimizationAlgorithm
|
Modifier and Type | Method and Description |
---|---|
InputType |
getInitialGuess()
Getter for initialGuess
|
InputOutputPair<InputType,OutputType> |
getResult()
Getter for result
|
double |
getTolerance()
Getter for tolerance
|
void |
setInitialGuess(InputType initialGuess)
Setter for initialGuess
|
protected void |
setResult(InputOutputPair<InputType,OutputType> result)
Setter for result
|
void |
setTolerance(double tolerance)
Setter for tolerance
|
cleanupAlgorithm, clone, getData, getKeepGoing, initializeAlgorithm, learn, setData, setKeepGoing, step, stop
getMaxIterations, isResultValid, setMaxIterations
addIterativeAlgorithmListener, fireAlgorithmEnded, fireAlgorithmStarted, fireStepEnded, fireStepStarted, getIteration, getListeners, removeIterativeAlgorithmListener, setIteration, setListeners
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
learn
clone
getMaxIterations, setMaxIterations
addIterativeAlgorithmListener, getIteration, removeIterativeAlgorithmListener
isResultValid, stop
protected double tolerance
protected InputOutputPair<InputType,OutputType> result
protected InputType initialGuess
public AbstractAnytimeFunctionMinimizer(InputType initialGuess, double tolerance, int maxIterations)
initialGuess
- Initial guess of the minimization routinetolerance
- Tolerance of the minimization algorithm, must be >= 0.0maxIterations
- Maximum number of iterations to run before stoppingpublic InputOutputPair<InputType,OutputType> getResult()
getResult
in interface AnytimeAlgorithm<InputOutputPair<InputType,OutputType>>
protected void setResult(InputOutputPair<InputType,OutputType> result)
result
- Resulting minimum input-output pairpublic double getTolerance()
getTolerance
in interface FunctionMinimizer<InputType,OutputType,EvaluatorType extends Evaluator<? super InputType,? extends OutputType>>
public void setTolerance(double tolerance)
setTolerance
in interface FunctionMinimizer<InputType,OutputType,EvaluatorType extends Evaluator<? super InputType,? extends OutputType>>
tolerance
- Tolerance of the minimization algorithm, must be >= 0.0public InputType getInitialGuess()
getInitialGuess
in interface FunctionMinimizer<InputType,OutputType,EvaluatorType extends Evaluator<? super InputType,? extends OutputType>>
public void setInitialGuess(InputType initialGuess)
setInitialGuess
in interface FunctionMinimizer<InputType,OutputType,EvaluatorType extends Evaluator<? super InputType,? extends OutputType>>
initialGuess
- Initial guess of the minimization routine