With the increasing integration of software in social structures, such as education and health, maintenance (e.g. debugging) of large software projects is becoming increasingly important. To this end, it is necessary to organize the source code into communities of artifacts (e.g. methods in classes, classes in packages, packages in libraries) to fa cilitate understandability and ease-of-navigation across implemented functionalities. If artifacts are organized into graphs whose edges reflect their dependencies, there ex ist commonly accepted software engineering principles of what constitutes high-quality source code organization, such as high connectivity of artifacts within groups and loose connectivity with artifacts of other groups. In this dissertation, we tackle the problem of automated reorganization of source code entities to optimize measures quantifying source code community organization quality. To this end, we apply community ex traction methods on dependency graphs. Our main hypothesis is that the existing hierarchical organization of source code comprises fragments of the optimal organiza tion and thus we use it as a first approximation that we refine with graph filters. This type of semi-supervised technique is compared to existing greedy optimization and un supervised genetic optimization approaches across 10 popular software projects. We find that, given a permutation of the ideal organization provided by developers, our approach derives the community organization closest to the ideal one. Additionally, it runs in near-linear times with respect to the number of dependencies that enable its application on dependency graphs of large projects.
12. Διαδικασία αξιολόγησης
Πραγματικό σεναρίο με γνωστή ιδανική οργάνωση (ground truth)
Μη-ιδανική οργάνωση με συνθετική διαδικασία διαστρέβλωσης
Είσοδος διαστρεβλωμένης οργάνωσης σε αλγόριθμους
(οι μη-επιβλεπόμενοι αλγόριθμοι δεν την εκμεταλλεύονται)
Σύγκριση αποτελέσματος με ιδανική οργάνωση
(MoJo, Precision, Recall, F-score)
12
13. Διαδικασία διαστρέβλωσης
• Τυχαία ανταλλαγή στοιχείων ομάδων
• Επιλογή αριθμού τυχαίων ανταλλαγών
Υπενθύμιση! Είσοδος της διαστρεβλωμένης ομαδοποίησης σε
αλγόριθμους ανίχνευσης κοινοτήτων για εκτίμηση ιδανικής
οργάνωσης.
13
14. Δεδομένα
• Δέκα έργα λογισμικού
• Υψηλής ποιότητας (τουλάχιστον μιας δεκαετίας)
• Γράφος κλήσης συναρτήσεων
• Οργάνωση σε κλάσεις = ground truth
14
15. Συγκρινόμενοι Αλγόριθμοι
None Διαστρεβλωμένη οργάνωση
PR Τυχαίος περίπατος Personalization Page Rank
ARW Τυχαίος περίπατος Absorbing Walk
HK Τυχαίος περίπατος Heat Kernel
Gmod Άπληστη ϐελτιστοποίηση του Modularity
Gen State-of-the-art υβριδικός γενετικός
αλγορίθμος
15
16. Πειραματικά Αποτελέσματα
• Μέση τιμή μετρικών για κάθε αλγόριθμο
(διαστρέβλωση 0-100%)
• Page Rank συνήθως καλύτερα
αποτελέσματα
(8/10 καλύτερο MoJo, 9/10 καλύτερη F-score)
• Γενετικός αλγόριθμος υψηλές τιμές στο
precision χαμηλές αλλού
(μεγάλος αριθμός ομάδων)
16