mayya-sharipova commented on code in PR #17047:
URL: https://github.com/apache/lucene/pull/17047#discussion_r4647359825


##########
lucene/core/src/java/org/apache/lucene/codecs/lucene99/Lucene99FlatVectorsWriter.java:
##########
@@ -332,6 +342,141 @@ public void mergeOneFlatVectorField(FieldInfo fieldInfo, 
MergeState mergeState)
         docsWithField);
   }
 
+  /**
+   * Merges a field by copying the stored bytes of each source segment's 
vectors, without decoding
+   * and re-encoding them. Every source must expose the field through one of 
the off-heap value
+   * classes that this format's reader creates, which read vector {@code ord} 
as the {@code
+   * vectorByteLength} little-endian bytes at {@code ord * vectorByteLength} 
of their slice: exactly
+   * what the per-vector path would write.
+   *
+   * <p>Documents are visited in the same order as {@code 
KnnVectorsWriter.MergedVectorValues}, and
+   * runs of consecutive live ordinals are copied in one call.
+   *
+   * @return the merged documents with a vector, or {@code null}, having 
written nothing, if the
+   *     merge sorts documents or any source does not qualify
+   */
+  private DocsWithFieldSet copyRawVectorData(FieldInfo fieldInfo, MergeState 
mergeState)

Review Comment:
   Great comment! 
   Addressed in 419058758fbbb8a0fa4f6c70950b4403f4e63c3f



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to