Module org.apache.lucene.core
Class ScalarQuantizedRandomVectorScorerSupplier
java.lang.Object
org.apache.lucene.codecs.lucene99.ScalarQuantizedRandomVectorScorerSupplier
- All Implemented Interfaces:
RandomVectorScorerSupplier
final class ScalarQuantizedRandomVectorScorerSupplier
extends Object
implements RandomVectorScorerSupplier
Quantized vector scorer supplier
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.lucene.util.hnsw.RandomVectorScorerSupplier
RandomVectorScorerSupplier.ByteScoringSupplier, RandomVectorScorerSupplier.FloatScoringSupplier -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ScalarQuantizedVectorSimilarityprivate final RandomAccessQuantizedByteVectorValues -
Constructor Summary
ConstructorsModifierConstructorDescription(package private)ScalarQuantizedRandomVectorScorerSupplier(VectorSimilarityFunction similarityFunction, ScalarQuantizer scalarQuantizer, RandomAccessQuantizedByteVectorValues values) privateScalarQuantizedRandomVectorScorerSupplier(ScalarQuantizedVectorSimilarity similarity, RandomAccessQuantizedByteVectorValues values) -
Method Summary
Modifier and TypeMethodDescriptioncopy()Make a copy of the supplier, which will copy the underlying vectorValues so the copy is safe to be used in other threads.scorer(int ord) This creates aRandomVectorScorerfor scoring random nodes in batches against the given ordinal.
-
Field Details
-
values
-
similarity
-
-
Constructor Details
-
ScalarQuantizedRandomVectorScorerSupplier
ScalarQuantizedRandomVectorScorerSupplier(VectorSimilarityFunction similarityFunction, ScalarQuantizer scalarQuantizer, RandomAccessQuantizedByteVectorValues values) -
ScalarQuantizedRandomVectorScorerSupplier
private ScalarQuantizedRandomVectorScorerSupplier(ScalarQuantizedVectorSimilarity similarity, RandomAccessQuantizedByteVectorValues values)
-
-
Method Details
-
scorer
Description copied from interface:RandomVectorScorerSupplierThis creates aRandomVectorScorerfor scoring random nodes in batches against the given ordinal.- Specified by:
scorerin interfaceRandomVectorScorerSupplier- Parameters:
ord- the ordinal of the node to compare- Returns:
- a new
RandomVectorScorer - Throws:
IOException
-
copy
Description copied from interface:RandomVectorScorerSupplierMake a copy of the supplier, which will copy the underlying vectorValues so the copy is safe to be used in other threads.- Specified by:
copyin interfaceRandomVectorScorerSupplier- Throws:
IOException
-