pub struct CMConfig {Show 16 fields
pub order1_size: usize,
pub order2_size: usize,
pub order3_size: usize,
pub order4_size: usize,
pub order5_size: usize,
pub order6_size: usize,
pub order7_size: usize,
pub order8_size: usize,
pub order9_size: usize,
pub match_ring_size: usize,
pub match_hash_size: usize,
pub word_size: usize,
pub sparse_size: usize,
pub run_size: usize,
pub json_size: usize,
pub ppm_config: PpmConfig,
}Expand description
Configuration for the CM engine – controls memory/quality trade-off.
Each field specifies the ContextMap size in bytes for the corresponding model. Larger sizes reduce hash collisions and improve prediction accuracy at the cost of more memory and slightly slower cache performance.
Fields§
§order1_size: usizeOrder-1 ContextMap size (default: 32MB).
order2_size: usizeOrder-2 ContextMap size (default: 16MB).
order3_size: usizeOrder-3 ChecksumContextMap size (default: 32MB).
order4_size: usizeOrder-4 ChecksumContextMap size (default: 32MB).
order5_size: usizeOrder-5 AssociativeContextMap size (default: 32MB).
order6_size: usizeOrder-6 AssociativeContextMap size (default: 16MB).
order7_size: usizeOrder-7 AssociativeContextMap size (default: 32MB).
order8_size: usizeOrder-8 AssociativeContextMap size (default: 32MB).
order9_size: usizeOrder-9 AssociativeContextMap size (default: 16MB).
match_ring_size: usizeMatch model ring buffer size in bytes (default: 16MB). Must be power of 2.
match_hash_size: usizeMatch model hash table entry count (default: 8M). Must be power of 2.
word_size: usizeWord model ContextMap size (default: 16MB).
sparse_size: usizeSparse model ContextMap size per gap context (default: 8MB, 16MB total).
run_size: usizeRun model ContextMap size (default: 4MB).
json_size: usizeJSON model ContextMap size (default: 8MB).
ppm_config: PpmConfigPPM model table sizes configuration.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for CMConfig
impl RefUnwindSafe for CMConfig
impl Send for CMConfig
impl Sync for CMConfig
impl Unpin for CMConfig
impl UnsafeUnpin for CMConfig
impl UnwindSafe for CMConfig
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
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