Package opennlp.tools.ml.model
Class UniformPrior
- java.lang.Object
-
- opennlp.tools.ml.model.UniformPrior
-
-
Constructor Summary
Constructors Constructor Description UniformPrior()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
int
hashCode()
void
logPrior(double[] dist, int[] context)
Populates the specified array with the the log of the distribution for the specified context.void
logPrior(double[] dist, int[] context, float[] values)
Populates the specified array with the the log of the distribution for the specified context.void
logPrior(double[] dist, Context[] context, float[] values)
Populates the specified array with the the log of the distribution for the specified context.void
setLabels(java.lang.String[] outcomeLabels, java.lang.String[] contextLabels)
Method to specify the label for the outcomes and contexts.
-
-
-
Method Detail
-
logPrior
public void logPrior(double[] dist, int[] context, float[] values)
Description copied from interface:Prior
Populates the specified array with the 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, Context[] context, float[] values)
Description copied from interface:Prior
Populates the specified array with the 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:Prior
Populates the specified array with the 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
public void setLabels(java.lang.String[] outcomeLabels, java.lang.String[] contextLabels)
Description copied from interface:Prior
Method 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 to #logPrior.
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
-