public class GradientDescentUpdater extends Object implements WeightUpdater
| Constructor and Description |
|---|
GradientDescentUpdater() |
| Modifier and Type | Method and Description |
|---|---|
de.jungblut.math.minimize.CostGradientTuple |
computeGradient(de.jungblut.math.DoubleVector theta,
de.jungblut.math.DoubleVector gradient,
double learningRate,
long iteration,
double lambda,
double cost)
Computes the gradient.
|
CostWeightTuple |
computeNewWeights(de.jungblut.math.DoubleVector theta,
de.jungblut.math.DoubleVector gradient,
double learningRate,
long iteration,
double lambda,
double cost)
Simplistic gradient descent without regularization.
|
public CostWeightTuple computeNewWeights(de.jungblut.math.DoubleVector theta, de.jungblut.math.DoubleVector gradient, double learningRate, long iteration, double lambda, double cost)
computeNewWeights in interface WeightUpdatertheta - the old weights.gradient - the gradient.learningRate - the learning rate.iteration - the number of the current iteration.lambda - the regularization parameter.cost - the computed cost for this gradient update.public de.jungblut.math.minimize.CostGradientTuple computeGradient(de.jungblut.math.DoubleVector theta,
de.jungblut.math.DoubleVector gradient,
double learningRate,
long iteration,
double lambda,
double cost)
WeightUpdatercomputeGradient in interface WeightUpdatertheta - the old weights.gradient - the gradient.learningRate - the learning rate.iteration - the number of the current iteration.lambda - the regularization parameter.cost - the computed cost for this gradient update.Copyright © 2015. All rights reserved.