Skip to main content

a hierachical clustering algorithm based on information theory

Project description

Travis Appveyor

Python binding

PyPI

How to build

The binding uses Cython. To package the library, use python setup.py bdist_wheel. Install the package by pip install --user pspartition. Below is the pre-built binary packages:

Platform py3.6 py3.7
Windows T T
MacOS T T
Linux T T

Demo code

import pspartition # classify the three data points shown in the above figure
g = pspartion.PsPartition(3, [(0,1,1),(1,2,1),(0,2,5)]) # index started from zero, similarity is 5 for vertex 0 and 2
g.run() # default to use psp_i algorithm to classify them
print(g.get_critical_values()) # [2,5]
print(g.get_partitions()) # get the result which has at least 2 categories, which is [0,1,0]

ChangeLog

  • Version 0.2: expose PSP (C++) class, which is high customizable in python.
  • Version 0.3: expose PyGraphPDT (C++) class, which has similar API as PyGraph but different inner implementation.
  • Version 0.5: expose run_psp_i for InfoCluster.
  • Version 0.7: change the python binding name from info_cluster to pspartition.

Project details


Download files

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

Files for pspartition, version 0.7.post5
Filename, size File type Python version Upload date Hashes
Filename, size pspartition-0.7.post5-cp36-cp36m-macosx_10_13_x86_64.whl (136.6 kB) File type Wheel Python version cp36 Upload date Hashes View
Filename, size pspartition-0.7.post5-cp36-cp36m-manylinux2010_x86_64.whl (220.3 kB) File type Wheel Python version cp36 Upload date Hashes View
Filename, size pspartition-0.7.post5-cp36-cp36m-win_amd64.whl (114.2 kB) File type Wheel Python version cp36 Upload date Hashes View
Filename, size pspartition-0.7.post5-cp37-cp37m-macosx_10_14_x86_64.whl (135.2 kB) File type Wheel Python version cp37 Upload date Hashes View
Filename, size pspartition-0.7.post5-cp37-cp37m-manylinux2010_x86_64.whl (220.3 kB) File type Wheel Python version cp37 Upload date Hashes View
Filename, size pspartition-0.7.post5-cp37-cp37m-win_amd64.whl (114.1 kB) File type Wheel Python version cp37 Upload date Hashes View
Filename, size pspartition-0.7.post5-py3.6-macosx-10.13-x86_64.egg (137.3 kB) File type Egg Python version 3.6 Upload date Hashes View
Filename, size pspartition-0.7.post5-py3.7-macosx-10.14-x86_64.egg (135.9 kB) File type Egg Python version 3.7 Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page