Class ES814ScalarQuantizedVectorsFormat

java.lang.Object
org.apache.lucene.codecs.KnnVectorsFormat
org.apache.lucene.codecs.hnsw.FlatVectorsFormat
org.elasticsearch.index.codec.vectors.ES814ScalarQuantizedVectorsFormat
All Implemented Interfaces:
org.apache.lucene.util.NamedSPILoader.NamedSPI

public class ES814ScalarQuantizedVectorsFormat extends org.apache.lucene.codecs.hnsw.FlatVectorsFormat
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    final Float
    Controls the confidence interval used to scalar quantize the vectors the default value is calculated as `1-1/(vector_dimensions + 1)`

    Fields inherited from class org.apache.lucene.codecs.KnnVectorsFormat

    DEFAULT_MAX_DIMENSIONS, EMPTY
  • Constructor Summary

    Constructors
    Constructor
    Description
    ES814ScalarQuantizedVectorsFormat(Float confidenceInterval, int bits, boolean compress)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    org.apache.lucene.codecs.hnsw.FlatVectorsReader
    fieldsReader(org.apache.lucene.index.SegmentReadState state)
     
    org.apache.lucene.codecs.hnsw.FlatVectorsWriter
    fieldsWriter(org.apache.lucene.index.SegmentWriteState state)
     
    int
     
     

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

    availableKnnVectorsFormats, forName, getName, reloadKnnVectorsFormat

    Methods inherited from class java.lang.Object

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

    • confidenceInterval

      public final Float confidenceInterval
      Controls the confidence interval used to scalar quantize the vectors the default value is calculated as `1-1/(vector_dimensions + 1)`
  • Constructor Details

    • ES814ScalarQuantizedVectorsFormat

      public ES814ScalarQuantizedVectorsFormat(Float confidenceInterval, int bits, boolean compress)
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • fieldsWriter

      public org.apache.lucene.codecs.hnsw.FlatVectorsWriter fieldsWriter(org.apache.lucene.index.SegmentWriteState state) throws IOException
      Specified by:
      fieldsWriter in class org.apache.lucene.codecs.hnsw.FlatVectorsFormat
      Throws:
      IOException
    • fieldsReader

      public org.apache.lucene.codecs.hnsw.FlatVectorsReader fieldsReader(org.apache.lucene.index.SegmentReadState state) throws IOException
      Specified by:
      fieldsReader in class org.apache.lucene.codecs.hnsw.FlatVectorsFormat
      Throws:
      IOException
    • getMaxDimensions

      public int getMaxDimensions(String fieldName)
      Overrides:
      getMaxDimensions in class org.apache.lucene.codecs.hnsw.FlatVectorsFormat