增加分段回归

pull/57/head
lidapeng 4 years ago
parent cdeea5bcec
commit 01564d389f

@ -22,6 +22,13 @@ public class Knn {//KNN分类器
featureMap.remove(type); featureMap.remove(type);
} }
public void revoke(int type, int nub) {//撤销一个类别最新的
List<Matrix> list = featureMap.get(type);
for (int i = 0; i < nub; i++) {
list.remove(list.size() - 1);
}
}
public void insertMatrix(Matrix vector, int tag) throws Exception { public void insertMatrix(Matrix vector, int tag) throws Exception {
if (vector.isVector() && vector.isRowVector()) { if (vector.isVector() && vector.isRowVector()) {
if (featureMap.size() == 0) { if (featureMap.size() == 0) {

Loading…
Cancel
Save