Abstract
Code Smell, similar to a bad smell, is a surface indication of something tainted but in terms of software writing practices. This metric is an indication of a deeper problem lies within the code and is associated with an issue which is prominent to experienced software developers with acceptable coding practices. Recent studies have often observed that codes having code smells are often prone to a higher probability of change in the software development cycle. In this paper, we developed code smell prediction models with the help of features extracted from source code to predict eight types of code smell. Our work also presents the application of data sampling techniques to handle class imbalance problem and feature selection techniques to find relevant feature sets. Previous studies had made use of techniques such as Naive Bayes and Random forest but had not explored deep learning methods to predict code smell. A total of 576 distinct Deep Learning models were trained using the features and datasets mentioned above. The study concluded that the deep learning models which used data from Synthetic Minority Oversampling Technique gave better results in terms of accuracy, AUC with the accuracy of some models improving from 88.47 to 96.84.
H. Gupta and T. G. Kulkarni—The work was done when authors were students in BITS Pilani, Hyderabad Campus.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
References
Azeem, M.I., Palomba, F., Shi, L., Wang, Q.: Machine learning techniques for code smell detection: a systematic literature review and meta-analysis. Inf. Softw. Technol. 108, 115–138 (2019)
Yamashita, A., Moonen, L.: Do code smells reflect important maintainability aspects? In: 2012 28th IEEE International Conference on Software Maintenance (ICSM), pp. 306–315. IEEE (2012)
Khomh, F., Di Penta, M., Gueheneuc, Y.-G.: An exploratory study of the impact of code smells on software change-proneness. In: 2009 16th Working Conference on Reverse Engineering, pp. 75–84. IEEE (2009)
Hecht, G., Moha, N., Rouvoy, R.: An empirical study of the performance impacts of android code smells. In: Proceedings of the International Conference on Mobile Software Engineering and Systems, pp. 59–69 (2016)
Wilcoxon, F., Katti, S.K., Wilcox, R.A.: Critical values and probability levels for the Wilcoxon rank sum test and the Wilcoxon signed rank test. Sel. Tables Math. Stat. 1, 171–259 (1970)
Podobnik, B., Stanley, H.E.: Detrended cross-correlation analysis: a new method for analyzing two nonstationary time series. Phys. Rev. Lett. 100(8), 084102 (2008)
He, H., Bai, Y., Garcia, E.A., Li, S.: ADASYN: adaptive synthetic sampling approach for imbalanced learning. In: 2008 IEEE International Joint Conference on Neural Networks (IEEE World Congress on Computational Intelligence), pp. 1322–1328. IEEE (2008)
Bowyer, K.W., Kegelmeyer, W.P., Chawla, N.V., Hall, L.O.: SMOTE : synthetic minority over-sampling technique. Technical report (2011)
Coleman, D., Ash, D., Lowther, B., Oman, P.: Using metrics to evaluate software system maintainability. Computer 27(8), 44–49 (1994)
Wang, T., Li, W.: Naive bayes software defect prediction model. In: 2010 International Conference on Computational Intelligence and Software Engineering, pp. 1–4. IEEE (2010)
Turhan, B., Bener, A.B.: Software defect prediction: heuristics for weighted naïve bayes. In: ICSOFT (SE), pp. 244–249 (2007)
Fontana, F.A., Mäntylä, M.V., Zanoni, M., Marino, A.: Comparing and experimenting machine learning techniques for code smell detection. Empir. Softw. Eng. 21(3), 1143–1191 (2016)
Abdi, L., Hashemi, S.: To combat multi-class imbalanced problems by means of over-sampling techniques. IEEE Trans. Knowl. Data Eng. 28(1), 238–251 (2015)
Abd-El-Hafiz, S.K.: A metrics-based data mining approach for software clone detection. In: 2012 IEEE 36th Annual Computer Software and Applications Conference, pp. 35–41. IEEE (2012)
Harrison, R., Counsell, S.J., Nithi, R.V.: An evaluation of the mood set of object-oriented software metrics. IEEE Trans. Softw. Eng. 24(6), 491–496 (1998)
Agarap, A.F.: Deep learning using rectified linear units (ReLU). arXiv preprint arXiv: 1803.08375 (2018)
Wang, M., Lu, S., Zhu, D., Lin, J., Wang, Z.: A high-speed and low-complexity architecture for softmax function in deep learning. In: 2018 IEEE Asia Pacific Conference on Circuits and Systems (APCCAS), pp. 223–226. IEEE (2018)
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2021 The Author(s), under exclusive license to Springer Nature Switzerland AG
About this paper
Cite this paper
Gupta, H., Kulkarni, T.G., Kumar, L., Neti, L.B.M., Krishna, A. (2021). An Empirical Study on Predictability of Software Code Smell Using Deep Learning Models. In: Barolli, L., Woungang, I., Enokido, T. (eds) Advanced Information Networking and Applications. AINA 2021. Lecture Notes in Networks and Systems, vol 226. Springer, Cham. https://doi.org/10.1007/978-3-030-75075-6_10
Download citation
DOI: https://doi.org/10.1007/978-3-030-75075-6_10
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-030-75074-9
Online ISBN: 978-3-030-75075-6
eBook Packages: Intelligent Technologies and RoboticsIntelligent Technologies and Robotics (R0)