Feature transformation for improved software bug detection and commit classification

Sakib Mostafa, Shamse Tasnim Cynthia, Banani Roy, Debajyoti Mondal · Journal of Systems and Software · 2024

Testing and debugging software to fix bugs is considered one of the most important stages of the software life cycle. Many studies have investigated ways to predict bugs in software artifacts using machine learning techniques. It is important to consider the explanatory aspects of such models for reliable prediction. In this paper, we show how feature transformation can significantly improve prediction accuracy and provide insight into the inner workings of bug prediction models. We propose a new approach for bug prediction that first extracts the features, then finds a weighted transformation of these features using a genetic algorithm that best separates bugs from non-bugs when plotted in a low-dimensional space, and finally, trains predictive models using the transformed dataset. In our experiment using the proposed feature transformation, the traditional machine learning and deep learning classifiers achieved an average improvement of 4.25% and 9.6% in recall values for bug classification over 8 software systems compared to the models built on original data. We also examined the generalizability of our concept for multiclass classification tasks such as commit classification in software systems and found modest improvements in F1-scores (sometimes up to 3%) for traditional machine learning models and 4% with deep learning models. • Feature transformation techniques applied to bug detection in software systems. • Genetic algorithm based transformation and t-SNE based clustering in low dimensions. • Improved explainability and accuracy of machine learning based bug detection models. • Applicable to deep learning models and generalizable to commit classification.

Read the paper · More papers on PaperTik