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

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

3.5 Further Implementation NotesIndexSpace+const_iterator: typedef+iterator: typedef+key_type: typedef = Key+index_type: typedef = size_t+SuperSpacePtr: typedef+contains_key(key:key_type): bool const+begin(): const_iterator const+end(): const_iterator const+size(): size_t const+upper_bound(): size_t const+lower_bound(): size_t const+get_key(idx:size_t): key_type const+get_index(key:key_type): size_t+super_space(): SuperSpacePtr const+root_space(): void* const+register_upper_bound(id:size_t,function)+unregister_upper_bound(id)FilterSubspace+map: IndexMap+filter: FilterFunctorSuperSpace:FilterFunctor:RangeSpaceGrowableSpace+new_key(): key_type+new_key(idx:size_t): key_typeBitSubspaceSuperSpace:RecycleSpacereuses removed keys laterDynamicSpace+add_key(key)+remove_key(key)+remove_all_keys()Figure 3.15: Index Spaces: Class and Concept Diagram3.5 Further Implementation NotesThis section provides additional hints on the implementation. These details are notdirectly important for the functioning of the clustering algorithm but describe crucialcomponents enabling and driving its implementation. Class diagrams and samplecode give a small insight into its structure and appearance. The next subsectionintroduces the concept of index spaces and shows how graphs and data are managedin the program. The second subsection describes how the data is externally stored.3.5.1 Index Spaces and <strong>Graph</strong>s<strong>Graph</strong> algorithms commonly deal <strong>with</strong> two different aspects: The adjacency structureof the graph and properties like vertex and edge weights. For navigation troughthe graph the structure is used. On the other hand calculations typically involveweights retrieved from the current vertex or edge. For example the implementationof the volume model stores vertex weights. At the same time the merge selectorstores the selection quality of each pair of adjacent vertices. These properties representdifferent aspects of the algorithm and should be managed separately. Oftenit is necessary to construct temporary properties in sub-algorithms not visible tothe outside. In addition a noteworthy observation is that in graph algorithms hugeamounts of 100, 000 and more small objects for vertices, edges and temporal propertiesexists. All these have no own life-cycle and do not need any garbage collectionas their existence is coupled to the graph and algorithm phases.53

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

Saved successfully!

Ooh no, something went wrong!