[ANN] Benchmark networks/graphs with LFRBenchmarkGraphs.jl

This is a package for generating Lancichinetti-Fortunato-Radicchi model benchmarks graphs. Such graphs are widely used in benchmarking community detection algorithms. The LFRBenchmarkGraphs.jl package is a simple wrapper to the original C/C++ implementation by the authors [1],[2].

Example usage

Dependencies for this demo

Import the necessary packages.

using GraphMakie, CairoMakie, LFRBenchmarkGraphs, Graphs

Graph generation

Generate an example LFR graph using the LFRBenchmarkGraphs.jl package. The output is a tuple with the graph and the membership/community ID of each vertex.

g,cid = lancichinetti_fortunato_radicchi(1000, 15, 40);

Visualize graph

We use the GraphMakie.jl package to visualize the graph, with the default layout algorithm.

f = Figure()
ax = Axis(f[1, 1], title = "LFR graph", xticklabelsvisible = false, yticklabelsvisible = false)
graphplot!(ax, g; edge_width = 0.1, node_color = cid, node_size = 6)
colsize!(f.layout, 1, Aspect(1, 1.0))



[1] Benchmarks for testing community detection algorithms on directed and weighted graphs with overlapping communities, Andrea Lancichinetti and Santo Fortunato, 2009. https://doi.org/10.1103/PhysRevE.80.016118
[2] Benchmark graphs for testing community detection algorithms, Andrea Lancichinetti, Santo Fortunato, and Filippo Radicchi, 2008. https://doi.org/10.1103/PhysRevE.78.046110