pub struct GradScalerStats {
pub scale: f32,
pub consecutive_good_steps: u32,
pub enabled: bool,
}Expand description
Statistics from the GradScaler for logging/monitoring.
Fields§
§scale: f32Current loss scale.
consecutive_good_steps: u32Good steps since the last change.
enabled: boolWhether scaling is on.
Trait Implementations§
Source§impl Clone for GradScalerStats
impl Clone for GradScalerStats
Source§impl Debug for GradScalerStats
impl Debug for GradScalerStats
Auto Trait Implementations§
impl Freeze for GradScalerStats
impl RefUnwindSafe for GradScalerStats
impl Send for GradScalerStats
impl Sync for GradScalerStats
impl Unpin for GradScalerStats
impl UnsafeUnpin for GradScalerStats
impl UnwindSafe for GradScalerStats
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> 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