pub struct HCVScore<T> { /* private fields */ }
Expand description
Homogeneity, completeness and V-Measure scores.
Implementations§
Source§impl<T: Number + Ord> HCVScore<T>
impl<T: Number + Ord> HCVScore<T>
Sourcepub fn homogeneity(&self) -> Option<f64>
pub fn homogeneity(&self) -> Option<f64>
return homogenity score
Sourcepub fn completeness(&self) -> Option<f64>
pub fn completeness(&self) -> Option<f64>
return completeness score
Sourcepub fn compute(
&mut self,
y_true: &dyn ArrayView1<T>,
y_pred: &dyn ArrayView1<T>,
)
pub fn compute( &mut self, y_true: &dyn ArrayView1<T>, y_pred: &dyn ArrayView1<T>, )
run computation for measures
Trait Implementations§
Source§impl<T: Number + Ord> Metrics<T> for HCVScore<T>
impl<T: Number + Ord> Metrics<T> for HCVScore<T>
Source§fn get_score(
&self,
_y_true: &dyn ArrayView1<T>,
_y_pred: &dyn ArrayView1<T>,
) -> f64
fn get_score( &self, _y_true: &dyn ArrayView1<T>, _y_pred: &dyn ArrayView1<T>, ) -> f64
Computes Homogeneity, completeness and V-Measure scores at once.
y_true
- ground truth class labels to be used as a reference.y_pred
- cluster labels to evaluate.
Auto Trait Implementations§
impl<T> Freeze for HCVScore<T>
impl<T> RefUnwindSafe for HCVScore<T>where
T: RefUnwindSafe,
impl<T> Send for HCVScore<T>where
T: Send,
impl<T> Sync for HCVScore<T>where
T: Sync,
impl<T> Unpin for HCVScore<T>where
T: Unpin,
impl<T> UnwindSafe for HCVScore<T>where
T: 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