benwtrent commented on code in PR #12413: URL: https://github.com/apache/lucene/pull/12413#discussion_r1253620162
########## lucene/core/src/java/org/apache/lucene/util/hnsw/HnswGraphSearcher.java: ########## @@ -204,26 +204,26 @@ private static <T> NeighborQueue search( if (initialEp == -1) { return new NeighborQueue(1, true); } - NeighborQueue results; - results = new NeighborQueue(1, false); - int[] eps = new int[] {graph.entryNode()}; - int numVisited = 0; - for (int level = graph.numLevels() - 1; level >= 1; level--) { - results.clear(); - graphSearcher.searchLevel(results, query, 1, level, eps, vectors, graph, null, visitedLimit); - - numVisited += results.visitedCount(); - visitedLimit -= results.visitedCount(); - - if (results.incomplete()) { - results.setVisitedCount(numVisited); Review Comment: @msokolov there shouldn't be. but commit https://github.com/apache/lucene/commit/22da1e4f88a8124f390f572ef5ea89202c70a347 did exactly this. Only keeping track of the single best candidate and result, but my recall numbers were different. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org