Package qupath.opencv.ml
Class OpenCVClassifiers
java.lang.Object
qupath.opencv.ml.OpenCVClassifiers
QuPath wrappers for OpenCV classifiers, which are instances of StatModel.
There are two main reasons to use these wrappers rather than StatModel directly:
- Improved API consistency when exchanging between classifiers. For example, some require training data to be in a specified form (labels or one-hot encoding).
- Easier serialization to JSON along with other QuPath objects via
GsonTools
.
- Author:
- Pete Bankhead
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Classifier based onBoost
.static class
Classifier based onDTrees
.static class
Clusterer based onEM
.static class
Classifier based onLogisticRegression
.static class
Classifier based onNormalBayesClassifier
.static class
Wrapper class for aStatModel
, which standardizes how training may be performed and parameters can be set.static class
Classifier based onRTrees
.static class
Classifier based onSVM
.static class
Classifier based onSVMSGD
. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncreateStatModel
(Class<? extends StatModel> cls) Create anOpenCVClassifiers.OpenCVStatModel
for a specific class ofStatModel
.wrapStatModel
(StatModel statModel) Create anOpenCVClassifiers.OpenCVStatModel
by wrapping an existingStatModel
.
-
Constructor Details
-
OpenCVClassifiers
public OpenCVClassifiers()
-
-
Method Details
-
createStatModel
Create anOpenCVClassifiers.OpenCVStatModel
for a specific class ofStatModel
.- Parameters:
cls
-- Returns:
-
wrapStatModel
Create anOpenCVClassifiers.OpenCVStatModel
by wrapping an existingStatModel
.- Parameters:
statModel
-- Returns:
-