A tool for hierarchical graph clustering and succint representation of graphs, supporting three different methods.
Check example.sh for some examples of usage.
Compile using make
.
This tool depends on Python, javac and g++.
Command | Arguments |
---|---|
create-dataset | <raw-data> <graph-out> options |
creates a Webgraph graph, with .graph, .properties and .offsets files, given the data file and the output base file <raw-data>: path to a file containing one line <graph-out>: base path to the webgraph files: .graph, .properties and .offsets. Options: --sub0: vertex numbering starts at 0 --directed: edge ( |
|
clusters | faststep/louvain/LLP <graph> <output-folder> |
generates the clustering for a graph using some method faststep/louvain/LLP: available methods for clustering <graph>: graph base path <output-folder>: output folder where communities file will be written |
|
labels | faststep/louvain/LLP <graph> <output-file> |
generates the reordering for a graph using some method faststep/louvain/LLP: available methods for reordering. <graph>: graph base path. <output-file>: output file where the reordering will be written. |
|
clusterings2labels | <graph> <clusterings-prefix> <output-file> |
generates the reordering for a graph using a set of clusterings (which may or may not be hierarchical), provided externally <graph>: graph base path <clusterings-prefix>: the prefix of the files containing the clusterings. Each clustering file provided must have a <output-file>: output file where the reordering will be written. |
|
reorder | <graph-in> <graph-out> <indexes> |
reorders a graph using the provided reordering file <graph-in>: input graph base path. <graph-out>: output graph base path. <indexes>: output file where the reordering will be written. |
|
compare-clusters | <cluster-file-1> <cluster-file-2> [Options] |
compares clusterings using a metric: either Jaccard distance or NMI (default metric) <cluster-file-1>: clustering file path. The clustering file provided must have a <cluster-file-2>: output graph base path. Same file format. Options: --nmi: Uses NMI as clustering metric --jaccard: Uses Jaccard Distance as clustering metric |
|
compare-clusters-list | <cluster-file-1> <cluster-file-2> [Options] |
compares a set of clusterings with another set of clusterings, using a metric: either Jaccard distance or NMI (default metric) regex-clusters-1: multiple clustering files. This argument supports regex (using the same syntax of the command line tool "ls"), which must be defined between quotation marks. Each clustering file provided must have a regex-clusters-2: multiple clustering files. Same file format. Options: --nmi: Uses NMI as clustering metric --jaccard: Uses Jaccard Distance as clustering metric |
|
size | <graph> <more graphs> |
Returns the size of one or more graph files <graph>: graph base path <more graphs>: base paths of more graph files |
|
help | |
Show usage information |