12.07.2015 Views

Multilevel Graph Clustering with Density-Based Quality Measures

Multilevel Graph Clustering with Density-Based Quality Measures

Multilevel Graph Clustering with Density-Based Quality Measures

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

3.2 <strong>Graph</strong> CoarseningData: graph,selector,reduction factorResult: clusteringmerge count ← reduction factor ∗ num vertices(graph ) + 1;while merge count > 0 do// (a, b) ← selector best edge() in two steps:a ← selector best vertex();b ← selector best neighbor(a);if found (a, b) thenclustering.merge(a,b), update graph and selector;merge count ← merge count − 1;elsebreak;Figure 3.4: Coarsening Method: Greedy Grouping3.2.1 Greedy GroupingIn each step greedy grouping searches the globally best ranked pair of clusters andmerges both <strong>with</strong>out compromises. Figure 3.4 summarizes the algorithm in pseudocode.To quickly find the best ranked pair the clustering is also represented by atemporary coarse graph. There each cluster is a vertex and the best neighbor of eachvertex is stored by the selector. Thus just the vertex <strong>with</strong> the best ranked neighboris searched and then its internally stored best neighbor is retrieved. The coarseningends if either no good pair is found or enough clusters were merged.During each merge the best-neighbor information has to be updated. This requiresto visit the neighbors of the two merged clusters for updating the selectionqualities between them. Thus the temporary coarse graph is used to cache mergedvertex and edge weights and the merged adjacency lists. Incrementally updatingthis graph leads to complex data structures and interactions but still is much fasterthan collecting the information in the original fine graph each time.Implementation Notes Computing selection quality and updating the modularityrequires to access edge and vertex weights. With each merge these weights have tobe updated. This is achieved by informing the container data structures during themerge operation about elementary operations like merging and moving edges. Additionallythe merge selector is informed in order to update the best merge neighborlike described in [76]: For finding the best merge neighbor of a vertex the selectionquality to all adjacent vertices has to be evaluated. But a new best neighbor has tobe searched only when the selection quality to the old best neighbor decreases. Inall other cases it is sufficient to compare the changed selection quality of a vertexpair to the current best neighborWith greedy grouping the next best merge pair has to be found repeatedly. Thisis efficiently done <strong>with</strong> a binary heap stored in a supplementary array. The heap isupdated when the best merge neighbor of a vertex changes. In this case the merge29

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!