cc.mallet.grmm.learning
Class PwplACRFTrainer.Maxable
java.lang.Object
cc.mallet.grmm.util.CachingOptimizable.ByGradient
cc.mallet.grmm.learning.PwplACRFTrainer.Maxable
- All Implemented Interfaces:
- Optimizable, Optimizable.ByGradientValue
- Enclosing class:
- PwplACRFTrainer
public class PwplACRFTrainer.Maxable
- extends CachingOptimizable.ByGradient
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
infiniteValues
protected java.util.BitSet infiniteValues
PwplACRFTrainer.Maxable
protected PwplACRFTrainer.Maxable(ACRF acrf,
InstanceList ilist)
getGaussianPriorVariance
public double getGaussianPriorVariance()
setGaussianPriorVariance
public void setGaussianPriorVariance(double gaussianPriorVariance)
getNumParameters
public int getNumParameters()
getParameters
public void getParameters(double[] buf)
setParametersInternal
protected void setParametersInternal(double[] params)
getExpectations
public SparseVector[] getExpectations(int cnum)
getConstraints
public SparseVector[] getConstraints(int cnum)
printParameters
public void printParameters()
- print weights
computeValue
protected double computeValue()
- Specified by:
computeValue
in class CachingOptimizable.ByGradient
computeValueGradient
protected void computeValueGradient(double[] grad)
- Computes the gradient of the penalized log likelihood of the
ACRF, and places it in cachedGradient[].
Gradient is
constraint - expectation - parameters/gaussianPriorVariance
- Specified by:
computeValueGradient
in class CachingOptimizable.ByGradient
collectConstraints
public void collectConstraints(InstanceList ilist)