public class DefaultConfidenceWeightedBinaryCategorizer extends AbstractConfidenceWeightedBinaryCategorizer
ConfidenceWeightedBinaryCategorizer
that stores a full mean and covariance matrix.Modifier and Type | Field and Description |
---|---|
protected Matrix |
covariance
The covariance matrix.
|
bias, DEFAULT_BIAS, weights
BINARY_CATEGORIES
Constructor and Description |
---|
DefaultConfidenceWeightedBinaryCategorizer()
Creates a new, uninitialized
DefaultConfidenceWeightedBinaryCategorizer . |
DefaultConfidenceWeightedBinaryCategorizer(Vector mean,
Matrix covariance)
Creates a new
DefaultConfidenceWeightedBinaryCategorizer with
the given mean and covariance. |
Modifier and Type | Method and Description |
---|---|
UnivariateGaussian |
evaluateAsGaussian(Vectorizable input)
Returns the univariate Gaussian distribution over the output of
the distribution of weight vectors times the input, with the
confidence that the categorizer was trained using.
|
Matrix |
getCovariance()
Gets the covariance matrix of the categorizer.
|
void |
setCovariance(Matrix covariance)
Sets the covariance matrix.
|
createWeightDistribution, evaluateAsBernoulli, getMean, isInitialized, setMean
clone, evaluateAsDouble, evaluateAsDouble, getBias, getInputDimensionality, getThreshold, getWeights, setBias, setThreshold, setWeights, toString
evaluate, evaluateWithDiscriminant
getCategories
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getInputDimensionality
getThreshold, setThreshold
evaluateAsDouble
evaluateWithDiscriminant
getCategories
clone
protected Matrix covariance
public DefaultConfidenceWeightedBinaryCategorizer()
DefaultConfidenceWeightedBinaryCategorizer
.public DefaultConfidenceWeightedBinaryCategorizer(Vector mean, Matrix covariance)
DefaultConfidenceWeightedBinaryCategorizer
with
the given mean and covariance. The covariance matrix must be an d by d
matrix where d is the dimensionality of the mean.mean
- The mean vector.covariance
- The covariance matrix.public UnivariateGaussian evaluateAsGaussian(Vectorizable input)
ConfidenceWeightedBinaryCategorizer
input
- The input to evaluate.public Matrix getCovariance()
ConfidenceWeightedBinaryCategorizer
public void setCovariance(Matrix covariance)
covariance
- The covariance matrix.