Package opennlp.tools.ml.model
Class UniformPrior
java.lang.Object
opennlp.tools.ml.model.UniformPrior
- All Implemented Interfaces:
Prior
Provide a maximum entropy model with a uniform
Prior.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleaninthashCode()voidlogPrior(double[] dist, int[] context) Populates the specified array with the log of the distribution for the specified context.voidlogPrior(double[] dist, int[] context, float[] values) Populates the specified array with the log of the distribution for the specified context.voidPopulates the specified array with the log of the distribution for the specified context.voidMethod to specify the label for the outcomes and contexts.
-
Constructor Details
-
UniformPrior
public UniformPrior()
-
-
Method Details
-
logPrior
public void logPrior(double[] dist, int[] context, float[] values) Description copied from interface:PriorPopulates the specified array with the log of the distribution for the specified context. The returned array will be overwritten and needs to be re-initialized with every call to this method. -
logPrior
Description copied from interface:PriorPopulates the specified array with the log of the distribution for the specified context. The returned array will be overwritten and needs to be re-initialized with every call to this method. -
logPrior
public void logPrior(double[] dist, int[] context) Description copied from interface:PriorPopulates the specified array with the log of the distribution for the specified context. The returned array will be overwritten and needs to be re-initialized with every call to this method. -
setLabels
Description copied from interface:PriorMethod to specify the label for the outcomes and contexts. This is used to map integer outcomes and contexts to their string values. This method is called prior to any call toPrior.logPrior(double[], int[]). -
hashCode
public int hashCode() -
equals
-