diskann_quantization/binary/mod.rs
1/*
2 * Copyright (c) Microsoft Corporation.
3 * Licensed under the MIT license.
4 */
5
6//! Binary quantization compression and distance comparisions.
7//!
8//! Binary quantization works by compressing each dimension of a vector to just 1 bit,
9//! where that bit is "1" is that value is positive and "0" if negative.
10//!
11//! The main quantizer is [`BinaryQuantizer`].
12//!
13//! Distances are computed using the [`crate::distances::Hamming`] distance function where
14//! [`crate::bits::BitSlice::<1, crate::bits::Binary>`] is the compressed-representation
15//! for binary vectors.
16
17mod quantizer;
18
19/////////////
20// Exports //
21/////////////
22
23pub use quantizer::BinaryQuantizer;