pub struct WassersteinDistance {
pub p: f64,
}Expand description
Wasserstein distance between persistence diagrams
W_p(D1, D2) = (inf_γ Σ ||p - γ(p)||_∞^p)^{1/p}
Fields§
§p: f64Power p (usually 1 or 2)
Implementations§
Source§impl WassersteinDistance
impl WassersteinDistance
Sourcepub fn compute(
&self,
d1: &PersistenceDiagram,
d2: &PersistenceDiagram,
dim: usize,
) -> f64
pub fn compute( &self, d1: &PersistenceDiagram, d2: &PersistenceDiagram, dim: usize, ) -> f64
Compute W_p distance for dimension d
Trait Implementations§
Source§impl Clone for WassersteinDistance
impl Clone for WassersteinDistance
Source§fn clone(&self) -> WassersteinDistance
fn clone(&self) -> WassersteinDistance
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for WassersteinDistance
impl RefUnwindSafe for WassersteinDistance
impl Send for WassersteinDistance
impl Sync for WassersteinDistance
impl Unpin for WassersteinDistance
impl UnwindSafe for WassersteinDistance
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