Struct burn_core::optim::AdaGradConfig
source · pub struct AdaGradConfig { /* private fields */ }Expand description
AdaGrad configuration.
Implementations§
source§impl AdaGradConfig
impl AdaGradConfig
source§impl AdaGradConfig
impl AdaGradConfig
sourcepub fn with_lr_decay(self, lr_decay: f64) -> Self
pub fn with_lr_decay(self, lr_decay: f64) -> Self
Set the default value for the field.
sourcepub fn with_epsilon(self, epsilon: f32) -> Self
pub fn with_epsilon(self, epsilon: f32) -> Self
Set the default value for the field.
sourcepub fn with_weight_decay(self, weight_decay: Option<WeightDecayConfig>) -> Self
pub fn with_weight_decay(self, weight_decay: Option<WeightDecayConfig>) -> Self
Set the default value for the field.
sourcepub fn with_grad_clipping(
self,
grad_clipping: Option<GradientClippingConfig>
) -> Self
pub fn with_grad_clipping( self, grad_clipping: Option<GradientClippingConfig> ) -> Self
Set the default value for the field.
source§impl AdaGradConfig
impl AdaGradConfig
sourcepub fn init<B: AutodiffBackend, M: AutodiffModule<B>>(
&self
) -> impl Optimizer<M, B>
pub fn init<B: AutodiffBackend, M: AutodiffModule<B>>( &self ) -> impl Optimizer<M, B>
Trait Implementations§
source§impl Clone for AdaGradConfig
impl Clone for AdaGradConfig
source§impl Config for AdaGradConfig
impl Config for AdaGradConfig
source§fn save<P: AsRef<Path>>(&self, file: P) -> Result<()>
fn save<P: AsRef<Path>>(&self, file: P) -> Result<()>
Saves the configuration to a file. Read more
source§fn load<P: AsRef<Path>>(file: P) -> Result<Self, ConfigError>
fn load<P: AsRef<Path>>(file: P) -> Result<Self, ConfigError>
Loads the configuration from a file. Read more
source§fn load_binary(data: &[u8]) -> Result<Self, ConfigError>
fn load_binary(data: &[u8]) -> Result<Self, ConfigError>
Loads the configuration from a binary buffer. Read more
source§impl<'de> Deserialize<'de> for AdaGradConfig
impl<'de> Deserialize<'de> for AdaGradConfig
source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Display for AdaGradConfig
impl Display for AdaGradConfig
Auto Trait Implementations§
impl RefUnwindSafe for AdaGradConfig
impl Send for AdaGradConfig
impl Sync for AdaGradConfig
impl Unpin for AdaGradConfig
impl UnwindSafe for AdaGradConfig
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