pub struct ModuleLearningRate { /* private fields */ }Available on crate feature
std only.Expand description
Determines what learning rate to use for a given trainable parameter.
Implementations§
Source§impl ModuleLearningRate
impl ModuleLearningRate
Sourcepub fn lr_from_param(&self, id: ParamId, path: Option<&str>) -> LearningRate
pub fn lr_from_param(&self, id: ParamId, path: Option<&str>) -> LearningRate
Get the effective learning rate for the given parameter.
Sourcepub fn base(&self) -> LearningRate
pub fn base(&self) -> LearningRate
Get the base learning rate value which’s group matches all parameters.
Trait Implementations§
Source§impl Clone for ModuleLearningRate
impl Clone for ModuleLearningRate
Source§fn clone(&self) -> ModuleLearningRate
fn clone(&self) -> ModuleLearningRate
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Default for ModuleLearningRate
impl Default for ModuleLearningRate
Source§fn default() -> ModuleLearningRate
fn default() -> ModuleLearningRate
Returns the “default value” for a type. Read more
Source§impl From<f64> for ModuleLearningRate
impl From<f64> for ModuleLearningRate
Source§fn from(value: LearningRate) -> Self
fn from(value: LearningRate) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ModuleLearningRate
impl RefUnwindSafe for ModuleLearningRate
impl Send for ModuleLearningRate
impl Sync for ModuleLearningRate
impl Unpin for ModuleLearningRate
impl UnsafeUnpin for ModuleLearningRate
impl UnwindSafe for ModuleLearningRate
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> CloneExpand for Twhere
T: Clone,
impl<T> CloneExpand for Twhere
T: Clone,
fn __expand_clone_method(&self, _: &Scope) -> T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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