[LUCENE-4345] - adding kNN score as count / k but no need to retrieve it from the map

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1403799 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Tommaso Teofili 2012-10-30 17:42:37 +00:00
parent 010c5f8d98
commit 52ef9d2752
1 changed files with 1 additions and 1 deletions

View File

@ -77,7 +77,7 @@ public class KNearestNeighborClassifier implements Classifier {
assignedClass = cl;
}
}
double score = classCounts.get(assignedClass) / k;
double score = max / k;
return new ClassificationResult(assignedClass, score);
}