tanmlh / Optimal-Neighboring-Reconstruction-for-Hyperspectral-Band-Selection

20 stars 6 forks source link

你好,运行 evaluation.m出错,能否指点一二? #2

Closed coco1994 closed 3 years ago

coco1994 commented 4 years ago

evaluation 函数或变量 'knnclassify' 无法识别。

出错 test_bs_accu (line 50) predict_label = knnclassify(bs_test_X, bs_train_X, train_labels, 3, 'euclidean');

出错 evaluation (line 75) cur_accu = test_bs_accu(Methods{1, 1}.band_set{dataset_id, 1}, Dataset, classifier_names{classifier_id});

tanmlh commented 3 years ago

这个应该是Matlab版本不同的原因,可以吧knnclassify换成你这个版本的Matlab对应的knn分类函数

coco1994 commented 3 years ago

evaluation 函数或变量 'knnclassify' 无法识别。

出错 test_bs_accu (line 50) predict_label = knnclassify(bs_test_X, bs_train_X, train_labels, 3, 'euclidean');

出错 evaluation (line 75) cur_accu = test_bs_accu(Methods{1, 1}.band_set{dataset_id, 1}, Dataset, classifier_names{classifier_id});