pub enum OptimizerKind {
Sgd,
Momentum,
Adam,
RmsProp,
Adagrad,
}Expand description
The optimizer families the zero-shot selector can recommend.
Variants§
Sgd
Plain stochastic gradient descent.
Momentum
SGD with classical (heavy-ball) momentum.
Adam
Adam (adaptive moments with bias correction).
RmsProp
RMSProp (root-mean-square propagation).
Adagrad
Adagrad (per-parameter accumulated-gradient scaling).
Implementations§
Source§impl OptimizerKind
impl OptimizerKind
Sourcepub fn all() -> [OptimizerKind; 5]
pub fn all() -> [OptimizerKind; 5]
All optimizer kinds in canonical (class-index) order.
Sourcepub fn from_index(index: usize) -> Result<OptimizerKind>
pub fn from_index(index: usize) -> Result<OptimizerKind>
Inverse of OptimizerKind::index; errors on an out-of-range index.
Sourcepub fn default_hyperparameters(self) -> OptimizerHyperparameters
pub fn default_hyperparameters(self) -> OptimizerHyperparameters
Canonical hyper-parameters for this optimizer family.
The learning rate is predicted separately by the regressor; these momentum / beta / epsilon values are the well-established defaults for the selected family.
Trait Implementations§
Source§impl Clone for OptimizerKind
impl Clone for OptimizerKind
impl Copy for OptimizerKind
Source§impl Debug for OptimizerKind
impl Debug for OptimizerKind
Source§impl<'de> Deserialize<'de> for OptimizerKind
impl<'de> Deserialize<'de> for OptimizerKind
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
impl Eq for OptimizerKind
Source§impl Hash for OptimizerKind
impl Hash for OptimizerKind
Source§impl PartialEq for OptimizerKind
impl PartialEq for OptimizerKind
Source§impl Serialize for OptimizerKind
impl Serialize for OptimizerKind
impl StructuralPartialEq for OptimizerKind
Auto Trait Implementations§
impl Freeze for OptimizerKind
impl RefUnwindSafe for OptimizerKind
impl Send for OptimizerKind
impl Sync for OptimizerKind
impl Unpin for OptimizerKind
impl UnsafeUnpin for OptimizerKind
impl UnwindSafe for OptimizerKind
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
impl<T> Scalar for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.