Struct rustfst::algorithms::tr_mappers::QuantizeMapper
source · pub struct QuantizeMapper { /* private fields */ }
Expand description
Mapper to quantize all weights.
Implementations§
Trait Implementations§
source§impl Clone for QuantizeMapper
impl Clone for QuantizeMapper
source§fn clone(&self) -> QuantizeMapper
fn clone(&self) -> QuantizeMapper
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for QuantizeMapper
impl Debug for QuantizeMapper
source§impl Default for QuantizeMapper
impl Default for QuantizeMapper
source§impl<S: WeightQuantize + Semiring> TrMapper<S> for QuantizeMapper
impl<S: WeightQuantize + Semiring> TrMapper<S> for QuantizeMapper
source§fn final_tr_map(&self, final_tr: &mut FinalTr<S>) -> Result<()>
fn final_tr_map(&self, final_tr: &mut FinalTr<S>) -> Result<()>
The mapper will be passed final weights as trs of the form
FinalTr(EPS_LABEL, EPS_LABEL, weight)
.source§fn final_action(&self) -> MapFinalAction
fn final_action(&self) -> MapFinalAction
Specifies final action the mapper requires (see above).
fn properties(&self, inprops: FstProperties) -> FstProperties
source§impl<S> WeightConverter<S, S> for QuantizeMapperwhere
S: WeightQuantize,
impl<S> WeightConverter<S, S> for QuantizeMapperwhere
S: WeightQuantize,
fn tr_map(&mut self, tr: &Tr<S>) -> Result<Tr<S>>
fn final_tr_map(&mut self, final_tr: &FinalTr<S>) -> Result<FinalTr<S>>
fn final_action(&self) -> MapFinalAction
fn properties(&self, iprops: FstProperties) -> FstProperties
impl Copy for QuantizeMapper
Auto Trait Implementations§
impl Freeze for QuantizeMapper
impl RefUnwindSafe for QuantizeMapper
impl Send for QuantizeMapper
impl Sync for QuantizeMapper
impl Unpin for QuantizeMapper
impl UnwindSafe for QuantizeMapper
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