Software Bug Prediction Using Machine Learning Algorithms: An Empirical Study on Code Quality and Reliability

Authors

  • Elavarasi Kesavan Full Stack QA Architect, Company- Cognizant.

DOI:

https://doi.org/10.69968/ijisem.2025v4i3377-381

Keywords:

Software Bug Prediction, Machine learning, Deep Learning, CNN-LSTM, Code Quality, Software Reliability, Feature Selection, Class Imbalance, Software Metrics, Defect Detection

Abstract

This study examines the effectiveness of a hybrid Convolutional Neural Network (CNN) and Long Short-Term Memory (LSTM) model for predicting software bugs, with the objective of improving code quality and dependability.  The research leverages the JM1 dataset from the PROMISE Software Engineering Repository and utilizes sophisticated preprocessing approaches, including Borderline-SMOTE, SMOTETomek, RobustScaler, Yeo-Johnson transformation, and Recursive Feature Elimination, to mitigate class imbalance and feature redundancy.  The CNN-LSTM model attained a validation accuracy of 98.10%, a precision of 91.42%, and a recall of 99.53%, exhibiting a minimal false negative rate and indicating great sensitivity in detecting defect-prone modules.  The results underscore the model's capacity to identify spatial and sequential patterns in software metrics, providing a reliable instrument for early fault identification.  This work enhances software engineering by confirming deep learning's efficacy in defect prediction, offering practical insights for developers, and delineating future research avenues for cross-project generalization and model optimization.

References

[1] Hall, Tracy, et al. "A Systematic Literature Review on Fault Prediction Performance in Software Engineering." IEEE Transactions on Software Engineering, vol. 38, no. 6, 2012, pp. 117-137,https://doi.org/10.1109/TSE.2011.103

[2] Lessmann, Stefan, et al. "Benchmarking Classification Models for Software Defect Prediction: A Proposed Framework for Empirical Research." IEEE Transactions on Software Engineering, vol. 34, no. 5, 2008, pp. 645-658,https://doi.org/10.1109/TSE.2008.35

[3] Menzies, Tim, et al. "Implications of Ceiling Effects in Defect Predictors." Proceedings of the 4th International Workshop on Predictor Models in Software Engineering, 2008, pp. 1039-1047,https://doi.org/10.1145/1370788.1370801

[4] Kim, Sunghun, et al. "Classifying Software Changes: Clean or Buggy?" IEEE Transactions on Software Engineering, vol. 34, no. 2, 2008, pp. 131-145,https://doi.org/10.1109/TSE.2007.70773

[5] Wang, Song, et al. "Automatically Learning Semantic Features for Defect Prediction." Proceedings of the 38th International Conference on Software Engineering, 2016, pp. 74-85,https://doi.org/10.1145/2884781.2884804

[6] Miloudi, Chaymae, et al. "The impact of grid search on bug resolution prediction for open-source software." 2023 9th International Conference on Control, Decision and Information Technologies (CoDIT). IEEE, 2023.https://doi.org/10.1109/CoDIT58514.2023.10284124

[7] S. Chidamber and C. Kemerer, "Metric For OOD_Chidamber Kemerer 94.pdf," IEEE Transactions on Software Engineering, vol. 20, no. 6. pp. 476-493, 1994.https://doi.org/10.1109/32.295895

[8] T.N. Zimmermann, N. Nagappan, and Zeller, A. "Predicting bugs from history software evolution". Springer Berlin Heidelberg, pp 69,88, 2008.https://doi.org/10.1007/978-3-540-76440-3_4

[9] H. WANG, T. M. KHOSHGOFTAAR, J. VAN HULSE, and K. GAO, "Metric Selection for Software Defect Prediction," Int. J. Softw. Eng. Knowl. Eng., vol. 21, no. 2, pp. 237-257, 2011.https://doi.org/10.1142/S0218194011005256

[10] M. Singh and D.S. Salaria. "Software defect prediction tool based on neural network". International Journal of Computer Applications. Vol. 70 No. 22. pp- 22-28. 2013.https://doi.org/10.5120/12200-8368

[11] A. Okutan and O. T. Yildiz, "Software defect prediction using Bayesian networks," Empir. Softw. Eng., vol. 19, no. 1, pp. 154-181, 2014.https://doi.org/10.1007/s10664-012-9218-8

[12] V.G. Palaste and V.S. Nandedkar. "A Survey on software defect prediction using data mining techniques". International Journal of Innovative Research in Computer and Communication Engineering. Vol. 3 No. 11, 2015.

[13] Challagulla, Venkata U.B., Farokh B. Bastani, I. Ling Yen, and Raymond A. Paul, -Empirical assessment of machine learning based software defect prediction techniques, ‖ Proceedings - International Workshop on ObjectOriented Real-Time Dependable Systems, WORDS, pp. 263-270, 2005,https://doi.org/10.1109/WORDS.2005.32

[14] Lessmann, Stefan, Bart Baesens, Christophe Mues, and Swantje Pietsch, -Benchmarking classification models for software defect prediction: A proposed framework and novel findings, ‖ in IEEE Transactions on Software Engineering, 2008, vol. 34, no. 4, pp. 485-496.https://doi.org/10.1109/TSE.2008.35

[15] Yaojing Wang, Yuan Yao, Hanghang Tong, Xuan Huo, Ming Li, Feng Xu, and Jian Lu. Enhancing supervised bag localization with metadata and stack-trace. Knowledge and Information Systems, 62:2461-2484, 2020.https://doi.org/10.1007/s10115-019-01426-2

[16] [16] Kai Yang, Yi Cai, Ho-fung Leung, Raymond YK Lau, and Qing Li. Itwf: A framework to apply term weighting schemes in topic model. Neurocomputing, 350:248-260, 2019.https://doi.org/10.1016/j.neucom.2019.02.048

[17] Tse-Hsun Chen, Stephen W Thomas, and Ahmed E Hassan. A survey on the use of topic models when mining software repositories. Empirical Software Engineering, 21:1843-1919, 2016.https://doi.org/10.1007/s10664-015-9402-8

[18] Christopher S Corley, Kostadin Damevski, and Nicholas A Kraft. Changeset- based topic modeling of software repositories. IEEE Transactions on Software Engineering, 46(10):1068-1080, 2018.https://doi.org/10.1109/TSE.2018.2874960

[19] Boehm, Barry W., et al. Software Engineering Economics. Prentice-Hall, 1981.

[20] Hall, Tracy, et al. "A Systematic Literature Review on Fault Prediction Performance in Software Engineering." IEEE Transactions on Software Engineering, vol. 38, no. 6, 2012, pp. 117-137,https://doi.org/10.1109/TSE.2011.103

[21] Menzies, Tim, et al. "Reducing Features to Improve Bug Prediction." IEEE Transactions on Software Engineering, vol. 35, no. 6, 2009, pp. 775-787,https://doi.org/10.1109/TSE.2009.51

[22] McCall, J. A., et al. "Concepts and Definitions of Software Quality." Software Quality Assurance: A Guide for Developers and Managers, edited by J. A. McCall, Software Productivity Consortium, 1977, pp. 15-30.

[23] Kim, Sunghun, et al. "Classifying Software Changes: Clean or Buggy?" IEEE Transactions on Software Engineering, vol. 34, no. 2, 2008, pp. 131-145,https://doi.org/10.1109/TSE.2007.70773

[24] Wang, Song, et al. "Automatically Learning Semantic Features for Defect Prediction." Proceedings of the 38th International Conference on Software Engineering, 2016, pp. 74-85,https://doi.org/10.1145/2884781.2884804

[25] Sayyad Shirabad, Jelber, and Tim J. "The PROMISE Repository of Software Engineering Databases." School of Information Technology and Engineering, University of Ottawa, 2005.http://promise.site.uottawa.ca/SERepository.

[26] Alenezi, A., and M. Alshehri. "Software Defect Prediction Analysis Using Machine Learning Techniques." Sustainability, vol. 15, no. 6, 2023, pp. 5517,https://doi.org/10.3390/su15065517

[27] Chawla, Nitesh V., et al. "SMOTE: Synthetic Minority Over-sampling Technique." Journal of Artificial Intelligence Research, vol. 16, 2002, pp. 321-357,https://doi.org/10.1613/jair.953

Downloads

Published

15-09-2025

Issue

Section

Articles

How to Cite

[1]
Kesavan, E. 2025. Software Bug Prediction Using Machine Learning Algorithms: An Empirical Study on Code Quality and Reliability. International Journal of Innovations in Science, Engineering And Management. 4, 3 (Sep. 2025), 377–381. DOI:https://doi.org/10.69968/ijisem.2025v4i3377-381.