Skip to main content

A class to compute the Generalised Forman-Ricci curvature for a Simplicial Complex from a given point cloud data.

Project description

License

GeneralisedFormanRicci

This code computes the Forman Ricci Curvature for simplicial complex generated from a given point cloud data. The implementation is based on the combinatorial definition of Forman Ricci curvature defined by Robin Forman. This implementation generalises beyond the simplified version implemented in saibalmars/GraphRicciCurvature github.

Many thanks to stephenhky and saibalmars for their packages MoguTDA and GraphRicciCurvature respectively. Partial code was modified from MoguTDA for the computation of the boundary matrices.

Installation

pip install GeneralisedFormanRicci

Upgrading via pip install --upgrade GeneralisedFormanRicci

Package Requirement

Simple Example

from GeneralisedFormanRicci.frc import GeneralisedFormanRicci

data = [[0.8, 2.6], [0.2, 1.0], [0.9, 0.5], [2.7, 1.8], [1.7, 0.5], [2.5, 2.5], [2.4, 1.0], [0.6, 0.9], [0.4, 2.2]]
for f in [0, 0.5, 1, 2, 3]:
    sc = GeneralisedFormanRicci(data, method = "rips", epsilon = f)
    sc.compute_forman()

References

Cite

If you use this code in your research, please considering cite our paper:

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

GeneralisedFormanRicci-0.0.4.tar.gz (4.2 kB view hashes)

Uploaded Source

Built Distribution

GeneralisedFormanRicci-0.0.4-py3-none-any.whl (9.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page