Class IVFVectorsReader

java.lang.Object
org.apache.lucene.codecs.KnnVectorsReader
org.elasticsearch.index.codec.vectors.IVFVectorsReader
All Implemented Interfaces:
Closeable, AutoCloseable
Direct Known Subclasses:
DefaultIVFVectorsReader

public abstract class IVFVectorsReader extends org.apache.lucene.codecs.KnnVectorsReader
Reader for IVF vectors. This reader is used to read the IVF vectors from the index.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    protected static final record 
     
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected final org.apache.lucene.internal.hppc.IntObjectHashMap<IVFVectorsReader.FieldEntry>
     
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    IVFVectorsReader(org.apache.lucene.index.SegmentReadState state, org.apache.lucene.codecs.hnsw.FlatVectorsReader rawVectorsReader)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    final void
     
    void
     
    final org.apache.lucene.index.ByteVectorValues
     
    final org.apache.lucene.index.FloatVectorValues
     
    final void
    search(String field, byte[] target, org.apache.lucene.search.KnnCollector knnCollector, org.apache.lucene.util.Bits acceptDocs)
     
    final void
    search(String field, float[] target, org.apache.lucene.search.KnnCollector knnCollector, org.apache.lucene.util.Bits acceptDocs)
     

    Methods inherited from class org.apache.lucene.codecs.KnnVectorsReader

    finishMerge, getMergeInstance

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

    • IVFVectorsReader

      protected IVFVectorsReader(org.apache.lucene.index.SegmentReadState state, org.apache.lucene.codecs.hnsw.FlatVectorsReader rawVectorsReader) throws IOException
      Throws:
      IOException
  • Method Details

    • checkIntegrity

      public final void checkIntegrity() throws IOException
      Specified by:
      checkIntegrity in class org.apache.lucene.codecs.KnnVectorsReader
      Throws:
      IOException
    • getFloatVectorValues

      public final org.apache.lucene.index.FloatVectorValues getFloatVectorValues(String field) throws IOException
      Specified by:
      getFloatVectorValues in class org.apache.lucene.codecs.KnnVectorsReader
      Throws:
      IOException
    • getByteVectorValues

      public final org.apache.lucene.index.ByteVectorValues getByteVectorValues(String field) throws IOException
      Specified by:
      getByteVectorValues in class org.apache.lucene.codecs.KnnVectorsReader
      Throws:
      IOException
    • search

      public final void search(String field, float[] target, org.apache.lucene.search.KnnCollector knnCollector, org.apache.lucene.util.Bits acceptDocs) throws IOException
      Specified by:
      search in class org.apache.lucene.codecs.KnnVectorsReader
      Throws:
      IOException
    • search

      public final void search(String field, byte[] target, org.apache.lucene.search.KnnCollector knnCollector, org.apache.lucene.util.Bits acceptDocs) throws IOException
      Specified by:
      search in class org.apache.lucene.codecs.KnnVectorsReader
      Throws:
      IOException
    • close

      public void close() throws IOException
      Throws:
      IOException