pub struct Observer { /* private fields */ }Expand description
Observer for collecting statistics during calibration
Implementations§
Source§impl Observer
impl Observer
Sourcepub fn new(momentum: f64, histogram_bins: usize) -> Self
pub fn new(momentum: f64, histogram_bins: usize) -> Self
Create a new observer with the given EMA momentum and histogram resolution
Sourcepub fn update<T: FloatBounds>(&mut self, data: &Array2<T>)
pub fn update<T: FloatBounds>(&mut self, data: &Array2<T>)
Update observer with new data
Sourcepub fn get_quantization_params(
&self,
method: &CalibrationMethod,
symmetric: bool,
n_levels: u32,
) -> QuantizationParams
pub fn get_quantization_params( &self, method: &CalibrationMethod, symmetric: bool, n_levels: u32, ) -> QuantizationParams
Get quantization parameters based on calibration method
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Observer
impl RefUnwindSafe for Observer
impl Send for Observer
impl Sync for Observer
impl Unpin for Observer
impl UnsafeUnpin for Observer
impl UnwindSafe for Observer
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
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>
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