Package se.hb.jcp.cp
Interface IConformalClassifier
-
- All Superinterfaces:
IClassifierInformation,java.io.Serializable
- All Known Implementing Classes:
ConformalMultiProbabilisticClassifier,InductiveConformalClassifier,TransductiveConformalClassifier
public interface IConformalClassifier extends IClassifierInformation, java.io.Serializable
Represents an instance of a specific conformal classification algorithm. Contract for JCP use: 1. The ConformalClassifier must be serializable, both as untrained and as trained. 2. The predict* methods must be reentrant.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description IClassificationNonconformityFunctiongetNonconformityFunction()Returns the associated nonconformity function.ConformalClassificationpredict(cern.colt.matrix.DoubleMatrix1D x)Makes a prediction for the instance x.ConformalClassification[]predict(cern.colt.matrix.DoubleMatrix2D x)Makes a prediction for each instance in x.cern.colt.matrix.DoubleMatrix1DpredictPValues(cern.colt.matrix.DoubleMatrix1D x)Computes the predicted p-values for the instance x.voidpredictPValues(cern.colt.matrix.DoubleMatrix1D x, cern.colt.matrix.DoubleMatrix1D pValues)Computes the predicted p-values for the instance x.cern.colt.matrix.DoubleMatrix2DpredictPValues(cern.colt.matrix.DoubleMatrix2D x)Computes the predicted p-values for each target and instance in x.-
Methods inherited from interface se.hb.jcp.ml.IClassifierInformation
getAttributeCount, getLabels, isTrained, nativeStorageTemplate
-
-
-
-
Method Detail
-
predict
ConformalClassification[] predict(cern.colt.matrix.DoubleMatrix2D x)
Makes a prediction for each instance in x. The method is parallellized over the instances.- Parameters:
x- the instances.- Returns:
- an array containing a ConformalClassification for each instance.
-
predict
ConformalClassification predict(cern.colt.matrix.DoubleMatrix1D x)
Makes a prediction for the instance x.- Parameters:
x- the instance.- Returns:
- a prediction in the form of a ConformalClassification.
-
predictPValues
cern.colt.matrix.DoubleMatrix2D predictPValues(cern.colt.matrix.DoubleMatrix2D x)
Computes the predicted p-values for each target and instance in x. The method is parallellized over the instances.- Parameters:
x- the instances.- Returns:
- an DoubleMatrix2D containing the predicted p-values for each instance.
-
predictPValues
cern.colt.matrix.DoubleMatrix1D predictPValues(cern.colt.matrix.DoubleMatrix1D x)
Computes the predicted p-values for the instance x.- Parameters:
x- the instance.- Returns:
- an DoubleMatrix1D containing the predicted p-values.
-
predictPValues
void predictPValues(cern.colt.matrix.DoubleMatrix1D x, cern.colt.matrix.DoubleMatrix1D pValues)Computes the predicted p-values for the instance x.- Parameters:
x- the instance.pValues- an initialized DoubleMatrix1D to store the p-values.
-
getNonconformityFunction
IClassificationNonconformityFunction getNonconformityFunction()
Returns the associated nonconformity function.- Returns:
- the associated IClassificationNonconformityFunction.
-
-