Understanding the Louvain algorithm