VectorEncoding.scalarQuantizer constructor

VectorEncoding.scalarQuantizer(
  1. ScalarQuantizerType type
)

Creates a scalar quantizer encoding of the given type.

This reduces the number of bits used for each number in a vector. The number of bits per component can be set to 4, 6, or 8 bits. The default setting in Couchbase Lite is 8 bits Scalar Quantizer or SQ-8.

Implementation

factory VectorEncoding.scalarQuantizer(ScalarQuantizerType type) =>
    VectorEncodingImpl(scalarQuantizerType: type);