You are here: Start » AVL.NET » AVL.KNN_Classify Method
AVL.KNN_Classify Method
Classify data using the KNN classifier.
Namespace: | AvlNet |
---|---|
Assembly: | AVL.NET.dll |
Syntax
public static void KNN_Classify( AvlNet.KNNModel inKNNModel, float[] inFeature, int inK, AvlNet.Metric inDistanceType, out int outClass )
Parameters
Name | Type | Range | Default | Description | |
---|---|---|---|---|---|
inKNNModel | AvlNet.KNNModel | Trained KNN model. | |||
inFeature | float | Vector of features. | |||
inK | int | <1, +INF> | Numbers of neighbors. | ||
inDistanceType | AvlNet.Metric | Geometry distance type used to calculate neighbors. | |||
outClass | int |
Errors
Error type | Description |
---|---|
DomainError | Using not trained classifier in KNN_Classify. |
DomainError | The inFeature has different dimensions count than KNNModel in KNN_Classify. |
DomainError | The inK is bigger than data samples count in KNN_Classify. |