Skip to main content

vortex_btrblocks/schemes/integer/
mod.rs

1// SPDX-License-Identifier: Apache-2.0
2// SPDX-FileCopyrightText: Copyright the Vortex contributors
3
4//! Integer compression schemes.
5
6mod bitpacking;
7mod for_;
8mod rle;
9mod runend;
10mod sequence;
11mod sparse;
12mod zigzag;
13
14#[cfg(feature = "pco")]
15mod pco;
16
17pub use bitpacking::BitPackingScheme;
18pub use for_::FoRScheme;
19#[cfg(feature = "pco")]
20pub use pco::PcoScheme;
21pub use rle::IntRLEScheme;
22pub(crate) use rle::rle_compress;
23#[cfg(feature = "unstable_encodings")]
24pub(crate) use rle::try_compress_delta;
25pub use runend::RunEndScheme;
26pub use sequence::SequenceScheme;
27pub use sparse::SparseScheme;
28// Re-export builtin schemes from vortex-compressor.
29pub use vortex_compressor::builtins::IntConstantScheme;
30pub use vortex_compressor::builtins::IntDictScheme;
31pub use vortex_compressor::stats::IntegerStats;
32pub use zigzag::ZigZagScheme;
33
34/// Threshold for the average run length in an array before we consider run-length encoding.
35pub(crate) const RUN_LENGTH_THRESHOLD: u32 = 4;
36
37#[cfg(test)]
38mod scheme_selection_tests;
39#[cfg(test)]
40mod tests;