Skip to main content

A community detection package

Project description

Introduction

The community-detection module contains basic functions for find communities in a graph. Internally, community-detection uses simple-graph to hold the structure of a graph.

Install

pip install community-detection

or update

pip install --upgrade community-detection

Usage

from simple_graph import Graph
from community_detection import FastUnfolding
G = Graph({0: [1, 2], 1: [2]})
fu = FastUnfolding()
communities = fu.process(G)
Q = fu.modularity(G, communities)
print(communities)
print('Q:', Q)
ouput: 
[[0, 1, 2]]
Q: 0.0

License

community-detection is a free software. See the file LICENSE for the full text.

Authors

qrcode_for_wechat_official_account

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

community_detection-0.0.14-py3-none-any.whl (13.0 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