pub struct FittedGradientBoostingClassifier<F: Float> { /* private fields */ }Expand description
Fitted gradient boosting classifier.
Implementations§
Source§impl<F: Float> FittedGradientBoostingClassifier<F>
impl<F: Float> FittedGradientBoostingClassifier<F>
Sourcepub fn n_estimators(&self) -> usize
pub fn n_estimators(&self) -> usize
Number of estimators per class set.
Sourcepub fn predict_proba(&self, x: &Array2<F>) -> Result<Array2<F>>
pub fn predict_proba(&self, x: &Array2<F>) -> Result<Array2<F>>
Predict class probabilities for each sample.
For binary classification, returns shape (n_samples, 2) with columns
[P(class_0), P(class_1)]. For multi-class, returns (n_samples, n_classes)
using softmax over the OVR log-odds.
Sourcepub fn feature_importances(&self) -> Array1<F>
pub fn feature_importances(&self) -> Array1<F>
Feature importances averaged across all tree sets, normalized to sum to 1.
Each tree’s importances are accumulated and weighted by the number of boosting rounds.
Trait Implementations§
Source§impl<F: Clone + Float> Clone for FittedGradientBoostingClassifier<F>
impl<F: Clone + Float> Clone for FittedGradientBoostingClassifier<F>
Source§fn clone(&self) -> FittedGradientBoostingClassifier<F>
fn clone(&self) -> FittedGradientBoostingClassifier<F>
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<'de, F> Deserialize<'de> for FittedGradientBoostingClassifier<F>where
F: DeserializeOwned + Float,
impl<'de, F> Deserialize<'de> for FittedGradientBoostingClassifier<F>where
F: DeserializeOwned + Float,
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<F: Float> Predict<F> for FittedGradientBoostingClassifier<F>
impl<F: Float> Predict<F> for FittedGradientBoostingClassifier<F>
Source§impl<F: Float> PredictProba<F> for FittedGradientBoostingClassifier<F>
impl<F: Float> PredictProba<F> for FittedGradientBoostingClassifier<F>
Auto Trait Implementations§
impl<F> Freeze for FittedGradientBoostingClassifier<F>where
F: Freeze,
impl<F> RefUnwindSafe for FittedGradientBoostingClassifier<F>where
F: RefUnwindSafe,
impl<F> Send for FittedGradientBoostingClassifier<F>
impl<F> Sync for FittedGradientBoostingClassifier<F>
impl<F> Unpin for FittedGradientBoostingClassifier<F>where
F: Unpin,
impl<F> UnsafeUnpin for FittedGradientBoostingClassifier<F>where
F: UnsafeUnpin,
impl<F> UnwindSafe for FittedGradientBoostingClassifier<F>where
F: 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
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 more