Package cc.mallet.classify
Class PRAuxClassifierOptimizable
- java.lang.Object
-
- cc.mallet.classify.PRAuxClassifierOptimizable
-
- All Implemented Interfaces:
Optimizable
,Optimizable.ByGradientValue
public class PRAuxClassifierOptimizable extends java.lang.Object implements Optimizable.ByGradientValue
Optimizable for training auxiliary model (q) for E-step/I-projection in PR training.- Author:
- Gregory Druck gdruck@cs.umass.edu
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface cc.mallet.optimize.Optimizable
Optimizable.ByBatchGradient, Optimizable.ByCombiningBatchGradient, Optimizable.ByGISUpdate, Optimizable.ByGradient, Optimizable.ByGradientValue, Optimizable.ByHessian, Optimizable.ByValue, Optimizable.ByVotedPerceptron
-
-
Constructor Summary
Constructors Constructor Description PRAuxClassifierOptimizable(InstanceList trainingData, double[][] baseDistribution, PRAuxClassifier classifier)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getNumParameters()
double
getParameter(int index)
void
getParameters(double[] buffer)
double
getValue()
double
getValueAndGradient(double[] gradient)
void
getValueGradient(double[] gradient)
void
setParameter(int index, double value)
void
setParameters(double[] params)
-
-
-
Constructor Detail
-
PRAuxClassifierOptimizable
public PRAuxClassifierOptimizable(InstanceList trainingData, double[][] baseDistribution, PRAuxClassifier classifier)
-
-
Method Detail
-
getNumParameters
public int getNumParameters()
- Specified by:
getNumParameters
in interfaceOptimizable
-
getParameters
public void getParameters(double[] buffer)
- Specified by:
getParameters
in interfaceOptimizable
-
getParameter
public double getParameter(int index)
- Specified by:
getParameter
in interfaceOptimizable
-
setParameters
public void setParameters(double[] params)
- Specified by:
setParameters
in interfaceOptimizable
-
setParameter
public void setParameter(int index, double value)
- Specified by:
setParameter
in interfaceOptimizable
-
getValueAndGradient
public double getValueAndGradient(double[] gradient)
-
getValue
public double getValue()
- Specified by:
getValue
in interfaceOptimizable.ByGradientValue
-
getValueGradient
public void getValueGradient(double[] gradient)
- Specified by:
getValueGradient
in interfaceOptimizable.ByGradientValue
-
-