pub enum Compression {
None,
Gzip(u8),
}Expand description
How an HDF5 event dataset is stored on disk.
Events are the one thing eventcv writes in bulk, and they compress far better than their raw
width suggests: t is monotonically increasing and p is one bit wearing a whole byte, so a
byte shuffle followed by deflate typically more than halves a recording. Uncompressed is still
offered because a live capture would rather spend the bytes than the CPU.
Variants§
None
Chunked but unfiltered — the fastest to write.
Gzip(u8)
Byte-shuffled, then deflated at this level (1..=9).
Implementations§
Trait Implementations§
Source§impl Clone for Compression
impl Clone for Compression
Source§fn clone(&self) -> Compression
fn clone(&self) -> Compression
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for Compression
Source§impl Debug for Compression
impl Debug for Compression
Source§impl Default for Compression
Gzip level 1, because on event columns almost all of the win comes from the byte shuffle rather
than from how hard deflate then looks. Measured on a 167 M-event simulation: unfiltered
2.18 GB / 22 s, level 1 429 MB / 35 s, level 4 408 MB / 42 s. Level 4 spends a fifth more time
to save a twentieth more space, which is the wrong side of the trade for a default.
impl Default for Compression
Gzip level 1, because on event columns almost all of the win comes from the byte shuffle rather than from how hard deflate then looks. Measured on a 167 M-event simulation: unfiltered 2.18 GB / 22 s, level 1 429 MB / 35 s, level 4 408 MB / 42 s. Level 4 spends a fifth more time to save a twentieth more space, which is the wrong side of the trade for a default.
impl Eq for Compression
Source§impl PartialEq for Compression
impl PartialEq for Compression
impl StructuralPartialEq for Compression
Auto Trait Implementations§
impl Freeze for Compression
impl RefUnwindSafe for Compression
impl Send for Compression
impl Sync for Compression
impl Unpin for Compression
impl UnsafeUnpin for Compression
impl UnwindSafe for Compression
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more