pub enum GlobalModularState {
Huffman {
depths: Vec<u8>,
codes: Vec<u16>,
max_token: u32,
},
Ans {
code: OwnedAnsEntropyCode,
},
AnsWithTree {
code: OwnedAnsEntropyCode,
tree: Tree,
wp_params: WeightedPredictorParams,
},
}Expand description
Result of writing the global modular section. Contains the entropy codes needed to encode pixel data in group sections.
Variants§
Huffman
Huffman entropy coding state.
Fields
Ans
ANS entropy coding state (single-context gradient tree).
Fields
§
code: OwnedAnsEntropyCodeThe ANS entropy code (distributions, context map, etc.)
AnsWithTree
ANS entropy coding with learned MA tree (multi-context).
Fields
§
code: OwnedAnsEntropyCodeThe ANS entropy code (multiple distributions, context map).
§
wp_params: WeightedPredictorParamsWP parameters used during tree learning and residual collection.
Auto Trait Implementations§
impl Freeze for GlobalModularState
impl RefUnwindSafe for GlobalModularState
impl Send for GlobalModularState
impl Sync for GlobalModularState
impl Unpin for GlobalModularState
impl UnsafeUnpin for GlobalModularState
impl UnwindSafe for GlobalModularState
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
Mutably borrows from an owned value. Read more
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>
Converts
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>
Converts
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