def knn_classifier(train_features, train_labels, test_features, test_labels, k, T, num_classes=2),The function is given a parameter of num_classes of 1000, when this value is changed to 2 and the binary classification problem is performed, an error is reported: RuntimeError: start (0) + length (5) exceeds dimension size (2). How should I use knn for binary classification problem?
def knn_classifier(train_features, train_labels, test_features, test_labels, k, T, num_classes=2),The function is given a parameter of num_classes of 1000, when this value is changed to 2 and the binary classification problem is performed, an error is reported: RuntimeError: start (0) + length (5) exceeds dimension size (2). How should I use knn for binary classification problem?