Skip to content

fastunfolding

kent edited this page Dec 24, 2019 · 3 revisions

Introduction

Fast Unfolding is a community detection algorithm that is based on modularity optimization. Modularity ( https://en.wikipedia.org/wiki/Modularity) is the degree to which a network's clusters may be separated or combined. It measures the quality of a community detection algorithm. The bigger modularity is, the better community structure will be. Fast Unfolding is a community detection algorithm that greedily maximizes the modularity of input graph by iteratively assigning nodes to different clusters.

(Paper:Fast unfolding of communities in large networks - https://arxiv.org/abs/0803.0476

image

image

Total delat Q can be get be adding delat Q_add and delat Q_remove.

image

Parameters

use --help param to view detailed help information.

Input Format

Input files should be formatted as follows:

<src>,<dst>,<weight>

where <src> and <dst> are integers of type uint32_t, representing the end nodes of an edge. <weight> is an optional input, indicating the weight of an edge. Note that Plato treats every input graph as undirected by default. For a directed graph, please ensure both <A, B> and <B, A> appear in the input file if they exist. Edges that appear more than once will be considered as multiple edges between the same pair of nodes.

Input example (Following numbers are synthetic and are for demonstration purpose only.):

4564,823192,0.12
1996,973033,0.88

Output Format

Output files are formatted as follows:

<vertex_id>,<cluster_id>

where <vertex_id> represents a node and <cluster_id> gives the id of the cluster that contains the node. Note that cluster ids may not start from 1 or be consecutive as some clusters are merged into bigger clusters hence their ids are ommited.

Output example (Following numbers are synthetic and are for demonstration purpose only.):

66720,827192
99086,639730

Code

https://github.com/Tencent/plato/tree/master/plato/algo/fast_unfolding

Algorithms to open source:

  • Network Embedding
    • LINE
    • Word2Vec
    • GraphVite
  • GNN
    • GCN
    • GraphSage
Clone this wiki locally