public class TransformInverseGradientDescent extends Object
Modifier and Type | Field and Description |
---|---|
protected static org.apache.log4j.Logger |
logger |
Constructor and Description |
---|
TransformInverseGradientDescent(int ndims,
ThinPlateR2LogRSplineKernelTransform xfm) |
Modifier and Type | Method and Description |
---|---|
boolean |
armijoCondition(double c,
double t)
Returns true if the armijo condition is satisfied.
|
double |
backtrackingLineSearch(double c,
double beta,
int maxtries,
double t0)
Uses Backtracking Line search to determine a step size.
|
void |
computeDirection() |
void |
computeDirectionSteepest()
Computes 2A^T(Ax - b ) using the current matrix as A, the current error
vector as b, and the current estimate as x
|
static void |
copyVectorIntoArray(org.ejml.data.DenseMatrix64F vec,
double[] array) |
org.ejml.data.DenseMatrix64F |
getDirection() |
double |
getError() |
org.ejml.data.DenseMatrix64F |
getErrorVector() |
org.ejml.data.DenseMatrix64F |
getEstimate() |
org.ejml.data.DenseMatrix64F |
getJacobian() |
void |
oneIteration() |
void |
oneIteration(boolean updateError) |
void |
setEps(double eps) |
void |
setEstimate(double[] est) |
void |
setEstimateXfm(double[] est) |
void |
setJacobian(double[][] mtx) |
void |
setStepSize(double stepSize) |
void |
setTarget(double[] tgt) |
double |
squaredError(double[] x) |
static double |
sumSquaredErrors(double[] y,
double[] x) |
void |
updateError() |
void |
updateEstimate(double stepSize) |
void |
updateEstimateNormBased(double stepSize) |
public TransformInverseGradientDescent(int ndims, ThinPlateR2LogRSplineKernelTransform xfm)
public void setEps(double eps)
public void setStepSize(double stepSize)
public void setJacobian(double[][] mtx)
public void setTarget(double[] tgt)
public org.ejml.data.DenseMatrix64F getErrorVector()
public org.ejml.data.DenseMatrix64F getDirection()
public org.ejml.data.DenseMatrix64F getJacobian()
public void setEstimate(double[] est)
public void setEstimateXfm(double[] est)
public org.ejml.data.DenseMatrix64F getEstimate()
public double getError()
public void oneIteration()
public void oneIteration(boolean updateError)
public void computeDirectionSteepest()
public void computeDirection()
public double backtrackingLineSearch(double c, double beta, int maxtries, double t0)
c
- the armijoCondition parameterbeta
- the fraction to multiply the step size at each iteration ( less than 1 )maxtries
- max number of triest0
- initial step sizepublic boolean armijoCondition(double c, double t)
c
- the c parametert
- the step sizepublic double squaredError(double[] x)
public void updateEstimate(double stepSize)
public void updateEstimateNormBased(double stepSize)
public void updateError()
public static double sumSquaredErrors(double[] y, double[] x)
public static void copyVectorIntoArray(org.ejml.data.DenseMatrix64F vec, double[] array)
Copyright © 2015–2021 Fiji. All rights reserved.