IFunctionOptimizer<T>
Interfaces · AiDotNet.Interfaces
Interface for optimizing a scalar-valued function over a vector of parameters.
Known implementations: GradientBasedOptimizerBase<T, TInput, TOutput>
For Beginners
A function optimizer finds the parameter values that minimize a given function. For example, finding the weights that minimize a loss function. Different optimizers use different strategies: gradient descent follows the slope downhill, L-BFGS approximates the curvature for faster convergence, etc.
How It Works
This interface abstracts the optimization strategy so algorithms can swap optimizers without changing their structure. For example, NOTEARS can use L-BFGS (default) or gradient descent for experimentation.
Methods
| Method | Summary |
|---|---|
Vector<T> Minimize(Vector<T> initialParameters, Func<Vector<T>, ValueTuple<T, Vector<T>>> objectiveAndGradient, int maxIterations, T tolerance) |
Minimizes a function starting from the given initial parameters. |