pub struct AdaBoostValidParams<P, R> {
pub n_estimators: usize,
pub learning_rate: f64,
pub model_params: P,
pub rng: R,
}Expand description
The set of valid hyperparameters for the AdaBoost algorithm.
§Parameters
-
n_estimators: The maximum number of weak learners to train sequentially. More estimators generally improve performance but increase training time and risk overfitting. Typical values range from 50 to 500. Default: 50. -
learning_rate: Shrinks the contribution of each classifier. There is a trade-off betweenlearning_rateandn_estimators. Lower values require more estimators to achieve the same performance but may generalize better. Must be positive. Default: 1.0. -
model_params: The parameters for the base learner (weak classifier). Typically, shallow decision trees (stumps with max_depth=1 or max_depth=2) are used as weak learners. -
rng: Random number generator used for bootstrap sampling and reproducibility.
Fields§
§n_estimators: usizeThe maximum number of estimators to train
learning_rate: f64The learning rate (shrinkage parameter)
model_params: PThe base learner parameters
rng: RRandom number generator
Trait Implementations§
Source§impl<P: Clone, R: Clone> Clone for AdaBoostValidParams<P, R>
impl<P: Clone, R: Clone> Clone for AdaBoostValidParams<P, R>
Source§fn clone(&self) -> AdaBoostValidParams<P, R>
fn clone(&self) -> AdaBoostValidParams<P, R>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl<P: Copy, R: Copy> Copy for AdaBoostValidParams<P, R>
Source§impl<D, T, P, R> Fit<ArrayBase<OwnedRepr<D>, Dim<[usize; 2]>>, T, Error> for AdaBoostValidParams<P, R>
impl<D, T, P, R> Fit<ArrayBase<OwnedRepr<D>, Dim<[usize; 2]>>, T, Error> for AdaBoostValidParams<P, R>
Source§impl<P: PartialEq, R: PartialEq> PartialEq for AdaBoostValidParams<P, R>
impl<P: PartialEq, R: PartialEq> PartialEq for AdaBoostValidParams<P, R>
Source§fn eq(&self, other: &AdaBoostValidParams<P, R>) -> bool
fn eq(&self, other: &AdaBoostValidParams<P, R>) -> bool
self and other values to be equal, and is used by ==.impl<P, R> StructuralPartialEq for AdaBoostValidParams<P, R>
Auto Trait Implementations§
impl<P, R> Freeze for AdaBoostValidParams<P, R>
impl<P, R> RefUnwindSafe for AdaBoostValidParams<P, R>where
P: RefUnwindSafe,
R: RefUnwindSafe,
impl<P, R> Send for AdaBoostValidParams<P, R>
impl<P, R> Sync for AdaBoostValidParams<P, R>
impl<P, R> Unpin for AdaBoostValidParams<P, R>
impl<P, R> UnsafeUnpin for AdaBoostValidParams<P, R>where
P: UnsafeUnpin,
R: UnsafeUnpin,
impl<P, R> UnwindSafe for AdaBoostValidParams<P, R>where
P: UnwindSafe,
R: UnwindSafe,
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
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>
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>
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