Predicts response for the input sample
Namespace: OpenCvSharp.CPlusPlus
Assembly: OpenCvSharp.CPlusPlus (in OpenCvSharp.CPlusPlus.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax
public float Predict( Mat sample, Mat missing = null, Nullable<Range> slice = null, bool rawMode = false, bool returnSum = false )
Parameters
- sample
- Type: OpenCvSharp.CPlusPlusMat
The input sample. - missing (Optional)
- Type: OpenCvSharp.CPlusPlusMat
The optional mask of missing measurements. To handle missing measurements, the weak classifiers must include surrogate splits. - slice (Optional)
- Type: SystemNullableRange
The continuous subset of the sequence of weak classifiers to be used for prediction. By default, all the weak classifiers are used. - rawMode (Optional)
- Type: SystemBoolean
The last parameter is normally set to false that implies a regular input. If it is true, the method assumes that all the values of the discrete input variables have been already normalized to 0..<num_of_categoriesi>-1 ranges. (as the decision tree uses such normalized representation internally). It is useful for faster prediction with tree ensembles. For ordered input variables the flag is not used. - returnSum (Optional)
- Type: SystemBoolean
[Missing <param name="returnSum"/> documentation for "M:OpenCvSharp.CPlusPlus.CvBoost.Predict(OpenCvSharp.CPlusPlus.Mat,OpenCvSharp.CPlusPlus.Mat,System.Nullable{OpenCvSharp.CPlusPlus.Range},System.Boolean,System.Boolean)"]
Return Value
Type: Singlethe output class label based on the weighted voting.
See Also