Module org.elasticsearch.server
Class OffHeapBFloat16VectorValues
java.lang.Object
org.apache.lucene.index.KnnVectorValues
org.apache.lucene.index.FloatVectorValues
org.elasticsearch.index.codec.vectors.es93.BFloat16VectorValues
org.elasticsearch.index.codec.vectors.es93.OffHeapBFloat16VectorValues
- All Implemented Interfaces:
org.apache.lucene.codecs.lucene95.HasIndexSlice
- Direct Known Subclasses:
OffHeapBFloat16VectorValues.DenseOffHeapVectorValues
public abstract class OffHeapBFloat16VectorValues
extends BFloat16VectorValues
implements org.apache.lucene.codecs.lucene95.HasIndexSlice
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classDense vector values that are stored off-heap.Nested classes/interfaces inherited from class org.apache.lucene.index.KnnVectorValues
org.apache.lucene.index.KnnVectorValues.DocIndexIterator -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final byte[]protected final intprotected final intprotected final org.apache.lucene.codecs.hnsw.FlatVectorsScorerprotected intprotected intprotected final org.apache.lucene.index.VectorSimilarityFunctionprotected final intprotected final org.apache.lucene.store.IndexInputprotected final float[] -
Method Summary
Modifier and TypeMethodDescriptionbyte[]bfloat16VectorBytes(int targetOrd) Returns the bfloat16 vector bytes for the given ordinal.intorg.apache.lucene.store.IndexInputgetSlice()intintsize()float[]vectorValue(int targetOrd) Methods inherited from class org.apache.lucene.index.FloatVectorValues
checkField, copy, fromFloats, getEncoding, rescorer, scorerMethods inherited from class org.apache.lucene.index.KnnVectorValues
createDenseIterator, createSparseIterator, fromDISI, getAcceptOrds, iterator, ordToDoc
-
Field Details
-
dimension
protected final int dimension -
size
protected final int size -
slice
protected final org.apache.lucene.store.IndexInput slice -
byteSize
protected final int byteSize -
lastBFloat16Ord
protected int lastBFloat16Ord -
bfloatBytes
protected final byte[] bfloatBytes -
lastFloatOrd
protected int lastFloatOrd -
value
protected final float[] value -
similarityFunction
protected final org.apache.lucene.index.VectorSimilarityFunction similarityFunction -
flatVectorsScorer
protected final org.apache.lucene.codecs.hnsw.FlatVectorsScorer flatVectorsScorer
-
-
Method Details
-
dimension
public int dimension()- Specified by:
dimensionin classorg.apache.lucene.index.KnnVectorValues
-
size
public int size()- Specified by:
sizein classorg.apache.lucene.index.KnnVectorValues
-
getSlice
public org.apache.lucene.store.IndexInput getSlice()- Specified by:
getSlicein interfaceorg.apache.lucene.codecs.lucene95.HasIndexSlice
-
getVectorByteLength
public int getVectorByteLength()- Overrides:
getVectorByteLengthin classorg.apache.lucene.index.KnnVectorValues
-
vectorValue
- Specified by:
vectorValuein classorg.apache.lucene.index.FloatVectorValues- Throws:
IOException
-
bfloat16VectorBytes
Description copied from class:BFloat16VectorValuesReturns the bfloat16 vector bytes for the given ordinal.- Specified by:
bfloat16VectorBytesin classBFloat16VectorValues- Throws:
IOException
-