gudhi.representations.metrics.PersistenceFisherDistance Class Reference

Public Member Functions

def __init__ (self, bandwidth=1., kernel_approx=None, n_jobs=None)
 
def fit (self, X, y=None)
 
def transform (self, X)
 
def __call__ (self, diag1, diag2)
 

Detailed Description

This is a class for computing the persistence Fisher distance matrix from a list of persistence diagrams. The persistence Fisher distance is obtained by computing the original Fisher distance between the probability distributions associated to the persistence diagrams given by convolving them with a Gaussian kernel. See http://papers.nips.cc/paper/8205-persistence-fisher-kernel-a-riemannian-manifold-kernel-for-persistence-diagrams for more details. 

Constructor & Destructor Documentation

◆ __init__()

def gudhi.representations.metrics.PersistenceFisherDistance.__init__ (   self,
  bandwidth = 1.,
  kernel_approx = None,
  n_jobs = None 
)
Constructor for the PersistenceFisherDistance class.

Parameters:
    bandwidth (double): bandwidth of the Gaussian kernel used to turn persistence diagrams into probability distributions (default 1.).
    kernel_approx (class): kernel approximation class used to speed up computation (default None). Common kernel approximations classes can be found in the scikit-learn library (such as RBFSampler for instance).   
    n_jobs (int): number of jobs to use for the computation. See :func:`pairwise_persistence_diagram_distances` for details.

Member Function Documentation

◆ __call__()

def gudhi.representations.metrics.PersistenceFisherDistance.__call__ (   self,
  diag1,
  diag2 
)
Apply PersistenceFisherDistance on a single pair of persistence diagrams and outputs the result.

Parameters:
    diag1 (n x 2 numpy array): first input persistence diagram.
    diag2 (n x 2 numpy array): second input persistence diagram.

Returns:
    float: persistence Fisher distance.

◆ fit()

def gudhi.representations.metrics.PersistenceFisherDistance.fit (   self,
  X,
  y = None 
)
Fit the PersistenceFisherDistance class on a list of persistence diagrams: persistence diagrams are stored in a numpy array called **diagrams** and the kernel approximation class (if not None) is applied on them.

Parameters:
    X (list of n x 2 numpy arrays): input persistence diagrams.
    y (n x 1 array): persistence diagram labels (unused).

◆ transform()

def gudhi.representations.metrics.PersistenceFisherDistance.transform (   self,
  X 
)
Compute all persistence Fisher distances between the persistence diagrams that were stored after calling the fit() method, and a given list of (possibly different) persistence diagrams.

Parameters:
    X (list of n x 2 numpy arrays): input persistence diagrams.

Returns:
    numpy array of shape (number of diagrams in **diagrams**) x (number of diagrams in X): matrix of pairwise persistence Fisher distances.

The documentation for this class was generated from the following file:
GUDHI  Version 3.3.0  - C++ library for Topological Data Analysis (TDA) and Higher Dimensional Geometry Understanding.  - Copyright : MIT Generated on Tue Aug 11 2020 11:58:59 for GUDHI by Doxygen 1.8.18