Persistent Homology

See the Gudhi documentation for more information on persistent homology and its applications [gudhi] .

orbithunter.persistent_homology.orbit_complex(orbit_instance, **kwargs)[source]

Wrapper for Gudhi persistent homology package’s PeriodicCubicalComplex

Parameters
orbit_instanceOrbit

The orbit for which to compute the complex.

kwargs :

periodic_dimensions : tuple Contains bools which flag which axes of the orbit’s field are assumed to be periodic for the persistence calculations. Defaults to Orbit defaults.

Returns
cubical_complexPeriodicCubicalComplex
orbithunter.persistent_homology.orbit_persistence(orbit_instance, **kwargs)[source]

Evaluate the persistence of an orbit complex; returns betti numbers and persistence intervals.

Parameters
orbit_instanceOrbit
Returns
ndarray or list :

NumPy or Gudhi format. Numpy format returns an array of shape (N, 3). Gudhi format is a list whose elements are of the form (int, (float, float)).

kwargs :

min_persistence : float Minimum persistence interval size for returned values. periodic_dimensions : tuple of bool Flags the dimensions of Orbit.state which are periodic.

Notes

Mainly a convenience function because of how Gudhi structures its output.

orbithunter.persistent_homology.persistence_plot(orbit_instance, gudhi_method='diagram', **kwargs)[source]
Parameters
orbit_instanceOrbit

Iterable of length N that contains elements of length 2 (i.e. N x 2 array) containing the persistence intervals (birth, death)

gudhi_methodstr

Plotting gudhi_method. Takes one of the following values: ‘diagram’, ‘barcode’, ‘density’.

kwargs :

kwargs related to gudhi plotting functions. See Gudhi docs for details.

orbithunter.persistent_homology.persistence_distance(orbit_or_array, second_orbit_or_array, gudhi_metric='bottleneck', **kwargs)[source]

Compute the distance between two Orbits’ persistence diagrams.

Parameters
orbit1Orbit

Orbit whose persistence creates the first diagram

orbit2Orbit

Orbit whose persistence creates the second diagram

gudhi_metricstr

The persistence diagram distance metric to use. Takes values ‘bottleneck’ and ‘wasserstein’.

kwargs :

Keyword arguments for orbit persistence and orbit complex computations.