Hierarchical Graph Analysis
Project description
# Higra: Hierarchical Graph Analysis
[![Build Status](https://travis-ci.org/PerretB/Higra.svg?branch=master)](https://travis-ci.org/PerretB/Higra) [![Build status](https://ci.appveyor.com/api/projects/status/5op4qm2cddm7iuj2/branch/master?svg=true)](https://ci.appveyor.com/project/PerretB/higra/branch/master) [![codecov](https://codecov.io/gh/PerretB/Higra/branch/master/graph/badge.svg)](https://codecov.io/gh/PerretB/Higra) [![Documentation Status](https://readthedocs.org/projects/higra/badge/?version=latest)](https://higra.readthedocs.io/en/latest/?badge=latest)
Higra is a C++/Python library for efficient graph analysis with a special focus on hierarchical methods. Some of the main features are:
efficient methods and data structures to handle the dual representation of hierarchical clustering: dendrograms (trees) and ultra-metric distances (saliency maps);
hierarchical clustering algorithms: agglomerative clustering (single-linkage, average-linkage, complete-linkage, or custom rule), quasi-flat zones hierarchy, hierarchical watersheds;
component trees: min and max trees;
various algorithms to manipulate and explore hierarchical clustering: accumulators, filtering/simplification, cluster extraction, partitioning, horizontal and non-horizontal cuts, alignment;
optimization on hierarchies: optimal cuts, energy hierarchies;
algorithms on graphs: accumulators, computation of dissimilarities, partitioning;
assessment: supervised assessment of graph clustering and hierarchical clustering;
image toolbox: special methods for grid graphs, hierarchical clustering methods dedicated to image analysis, optimization of Mumford-Shah energy.
Higra is thought for modularity, performance and seamless integration with classical data analysis pipelines. The data structures (graphs and trees) are decoupled from data (vertex and edge weights ) which are simply arrays ([xtensor](https://github.com/QuantStack/xtensor) arrays in C++ and [numpy](https://github.com/numpy/numpy) arrays in Python).
## Installation
### Python frontend
The Python frontend can be installed with Pypi:
`bash pip install higra `
Supported systems:
Python 3.4, 3.5, 3.6, 3.7
Linux 64 bits, macOS, Windows 64 bits
### C++ backend
The C++ backend is an header only library. No facilities for system wide installation is currently provided: just copy/past where you need it!
## Demonstration and tutorials
Check the dedicated repository [Higra-Notebooks](https://github.com/PerretB/Higra-Notebooks) for a collection of Jupyter Notebooks dedicated to Higra.
## Build
### With cmake
Requires:
cmake
Python + Numpy
Google Benchmark (optional for benchmarking of the C++ backend)
Commands:
`bash git clone https://github.com/PerretB/Higra.git mkdir build cd build cmake ../Higra/ make `
Sometimes, cmake gets confused when several Python versions are installed on the system. You can specify which version to use with -DPYTHON_EXECUTABLE:FILEPATH=/PATH-TO-PYTHON/python, e.g.
` cmake -DPYTHON_EXECUTABLE:FILEPATH=/anaconda3/bin/python ../Higra/ `
The python package is build in the directory
` build/higra/ `
### With setup.py
The setup.py is a thin wrapper around the cmake script to provide compatibility with python setuptools.
` pip install cmake python setup.py bdist_wheel cd dist pip install higra*.whl `
## Third-party libraries
Higra bundles several third-party libraries (inside the lib folder):
[pybind11](https://github.com/pybind/pybind11) helps to create Python bindings of c++ method and classes - [BSD-style license](https://github.com/pybind/pybind11/blob/master/LICENSE)
[xtensor](https://github.com/QuantStack/xtensor) (with [xtl](https://github.com/QuantStack/xtl), [xsimd](https://github.com/QuantStack/xsimd), and [xtensor-python](https://github.com/QuantStack/xtensor-python) provides numpy like arrays for c++ with seamless integration with Python - all under the [BSD-3-Clause license](https://github.com/QuantStack/xtensor/blob/master/LICENSE)
[Catch2](https://github.com/catchorg/Catch2) is a unit test framework - [Boost Software License 1.0](https://github.com/catchorg/Catch2/blob/master/LICENSE.txt)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Hashes for higra-0.2.7-cp37-cp37m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7fd1449e540d45204879d45fc68dda378dc97180b56185628442ec6f1bd191cf |
|
MD5 | ec3e6d45f775ae7399881da25dd00c5c |
|
BLAKE2b-256 | ec3f5afa879a4da847e8aa92fbacfeff6cf4079226d31e1833006264912bb10e |
Hashes for higra-0.2.7-cp37-cp37m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2202884d967284e7be70adb2390d74458be6404a617ac404a4edf7e6cd3ada0a |
|
MD5 | ae709d656fd816e89b4d12a9f8153ebc |
|
BLAKE2b-256 | 44a25950c5531c62a63f380401e011f665e0edbeb151e933facc1205f1c763ea |
Hashes for higra-0.2.7-cp37-cp37m-macosx_10_6_intel.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 299702e364c958a402823cbedf6c4343f7b40cccd4e41ae67ee9975356f9f1b9 |
|
MD5 | ace30887d97bc22d3d724dc3e0b12394 |
|
BLAKE2b-256 | 756f70604172897080034fb8355066dcb21a2bab96a8ac2b3fc05b669c9d6f21 |
Hashes for higra-0.2.7-cp36-cp36m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 35e66164d4042ec01ade227d5fd123ba4e08e8dcf1fb0c26f4d3700496912332 |
|
MD5 | 9d720a57e4fdf563a8de3af788443c5c |
|
BLAKE2b-256 | b5983b4f84a3cb5f74e3e516302959f9000f0aa5549200121f2f90debeb809a5 |
Hashes for higra-0.2.7-cp36-cp36m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f64824b2dd5daa1494adaa88073a017d44404d0061f3a708ed694d5a5bc79d14 |
|
MD5 | 6a86646509b441ba18712295045c9f89 |
|
BLAKE2b-256 | 2f3b117edf7db7da638523494aa65be3869ce510d1460f4cef1bf35c2ea61072 |
Hashes for higra-0.2.7-cp36-cp36m-macosx_10_6_intel.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a90b625ee705f923d29a5e962ba4a17a277a0ef929f3ed6b6ad76a81d7484861 |
|
MD5 | d1ff21e059281965aca21d31a210270a |
|
BLAKE2b-256 | f9335e123c84dad543a0367db2a21c4fe6fce00290f31d59d4bc03497d4d4cb5 |
Hashes for higra-0.2.7-cp35-cp35m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bd73e326e548c67544ea3e979401bf2ce362bc0a07bf982721bb8a0b1d0272cd |
|
MD5 | 7c5b917a51d54ea25b234c191725e352 |
|
BLAKE2b-256 | 5a69ed80eabd606f6d5763b8b9c0628ef3e2ecb08573477db6f08f488c82d810 |
Hashes for higra-0.2.7-cp35-cp35m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4a02d02d8201efa7116886d2afba3d9fd442d3dd7dd761120f7dd365694dfcd7 |
|
MD5 | 0463d7b1b600850591b5508acfbfec16 |
|
BLAKE2b-256 | 53b3d72fa8c9541638710d599653b2c5629807ca446dfb0c11b5b1fb2f3c9a78 |
Hashes for higra-0.2.7-cp35-cp35m-macosx_10_6_intel.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0fef1990457426947c8646fb89f669e37ce21725feafcc4d2e99d6fcd5adc725 |
|
MD5 | 7afb4a4a4fbd8fa6007686ba0997a2ee |
|
BLAKE2b-256 | f029627b74c14f18a74126df543abb83f2888dfee9b26bab1afbbd980a5d8e63 |
Hashes for higra-0.2.7-cp34-cp34m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | cd86c29e788cc498f9e01333fd4167ff7d8d7368a54cf554e6039e2c958ee6a2 |
|
MD5 | d373c0c17ea797473eecfaee9d53d61d |
|
BLAKE2b-256 | 29a6b05591461433a5ae040b98ae7dd0770588d1ea38684efa507a9d66420d2c |
Hashes for higra-0.2.7-cp34-cp34m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5f5792dc7b3b390c00456dd738ffe05da5e3e9a26a71e2da05a917464a2a512f |
|
MD5 | 6f316d317822d6643e5a4fa81e48356b |
|
BLAKE2b-256 | 1c85f0abb6fec83402e2c8a6e9745c99f63439f992c59329bca97749a8f58b3e |
Hashes for higra-0.2.7-cp34-cp34m-macosx_10_6_intel.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8c0bd2060b0c88af13fc2f341bd5c5c66146620d46b6e95d7ba84756c54ff431 |
|
MD5 | 4b088497acf34e933b072a52002def04 |
|
BLAKE2b-256 | dea24fb9dfe1a040187168e49fb72d313267695beb7b1fecd3c6adae83fca534 |