A project for probabilistic data structures and large data sets.
The aabel-hash crate defines several traits.
- HashExt trait. The trait exposes functionality that extends the std::Hash functionality.
- Hash128Ext trait. The trait exposes functionality available when the hasher is 128bits one.
- HasherExt trait. The trait exposes std::Hasher functionality.
The aabel-hash crate also implements or re-exports several common hash functions:
- CityHash (source city64.rs)
- FarmHash (source farm64.rs)
- Fowler-Noll-Vo (source fnv64.rs)
- Murmur3 (source murmur3.rs)
- SipHash (source sip24.rs)
For more details please check the crate's readme file.
The aabel-membership crate implements several probabilistic data structures which determine if a given elements is present in a collection.
- Bloom Filter (source filter.rs)
- Bloom Counter (source counter.rs)
- Cuckoo Filter (source filter.rs)
For more details please check the crate's readme file.
The aabel-cardinality crate implements several probabilistic algorithms which determine the cardinality of a large data set.
- Flajolet-Martin (source fm.rs)
The aabel-frequency crate implements several probabilistic algorithms which determine the majority, heavy-hitters:
- Boyer-Moore majority voting (source majority.rs)
- Misra-Gries heavy hitters (source frequent.rs)
- Count-Min Sketch (source cms.rs)
The aabe-bits crate implements a bit-vector. You are able to set and get a specific bit from the store. It is used in the counting algorithms.
// Create a stored based on u8 slots, the store has 2 slots.
let mut bits = Bits8::<2>::default();
bits.merge_u16(10 << 8);
assert!(!bits.get(0));
assert!(!bits.get(8));
assert!(bits.get(9));
assert!(!bits.get(10));
assert!(bits.get(11));
bits.reset(9);
println!("After reset: bits={:?}", bits.pretty());
bits.set(9);
println!("After set: bits={:?}", bits.pretty());
assert_eq!(16, bits.bits());
assert_eq!(2, bits.slots());
assert_eq!(9, bits.lsb());
Code designed and written on the beautiful island of Saaremaa, Estonia.