CvKNearest Constructor (CvMat, CvMat, CvMat, Boolean, Int32) OpenCvSharp Class Library
Training constructor

Namespace:  OpenCvSharp.CPlusPlus
Assembly:  OpenCvSharp.CPlusPlus (in OpenCvSharp.CPlusPlus.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax

public CvKNearest(
	CvMat trainData,
	CvMat responses,
	CvMat sampleIdx = null,
	bool isRegression = false,
	int maxK = 32
)

Parameters

trainData
Type: OpenCvSharpCvMat
Known samples (m*n)
responses
Type: OpenCvSharpCvMat
Classes for known samples (m*1)
sampleIdx (Optional)
Type: OpenCvSharpCvMat

[Missing <param name="sampleIdx"/> documentation for "M:OpenCvSharp.CPlusPlus.CvKNearest.#ctor(OpenCvSharp.CvMat,OpenCvSharp.CvMat,OpenCvSharp.CvMat,System.Boolean,System.Int32)"]

isRegression (Optional)
Type: SystemBoolean

[Missing <param name="isRegression"/> documentation for "M:OpenCvSharp.CPlusPlus.CvKNearest.#ctor(OpenCvSharp.CvMat,OpenCvSharp.CvMat,OpenCvSharp.CvMat,System.Boolean,System.Int32)"]

maxK (Optional)
Type: SystemInt32
Maximum number of neighbors to return
See Also

Reference