mayya-sharipova commented on a change in pull request #649: URL: https://github.com/apache/lucene/pull/649#discussion_r802152096
########## File path: lucene/core/src/java/org/apache/lucene/codecs/lucene91/Lucene91HnswVectorsWriter.java ########## @@ -140,7 +142,10 @@ public void writeField(FieldInfo fieldInfo, KnnVectorsReader knnVectorsReader) // build the graph using the temporary vector data Lucene91HnswVectorsReader.OffHeapVectorValues offHeapVectors = new Lucene91HnswVectorsReader.OffHeapVectorValues( - vectors.dimension(), docIds, vectorDataInput); + vectors.dimension(), + docsWithField.cardinality(), + null, // graph construction doesn't need to know docIds Review comment: Good comment. I've tried to address this in 6bf1aea543ddb3d19909a5bc3d9ccbb1b4fcf9e4. For the sparse case, I fill this array `docIds` in memory as was before. Later, when we decouple the random vector values access and iterator, we can remove this part. -- 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