Predicting Code Smells and Analysis of Predictions: Using Machine Learning Techniques and Software Metrics

被引:0
|
作者
Mohammad Y. Mhawish
Manjari Gupta
机构
[1] Banaras Hindu University,Computer Science, Centre for Interdisciplinary Mathematical Sciences, Institute of Science
关键词
code smell; code smell detection; feature selection; prediction explanation; parameter optimization;
D O I
暂无
中图分类号
学科分类号
摘要
Code smell detection is essential to improve software quality, enhancing software maintainability, and decrease the risk of faults and failures in the software system. In this paper, we proposed a code smell prediction approach based on machine learning techniques and software metrics. The local interpretable model-agnostic explanations (LIME) algorithm was further used to explain the machine learning model’s predictions and interpretability. The datasets obtained from Fontana et al. were reformed and used to build binary-label and multi-label datasets. The results of 10-fold cross-validation show that the performance of tree-based algorithms (mainly Random Forest) is higher compared with kernel-based and network-based algorithms. The genetic algorithm based feature selection methods enhance the accuracy of these machine learning algorithms by selecting the most relevant features in each dataset. Moreover, the parameter optimization techniques based on the grid search algorithm significantly enhance the accuracy of all these algorithms. Finally, machine learning techniques have high potential in predicting the code smells, which contribute to detect these smells and enhance the software’s quality.
引用
收藏
页码:1428 / 1445
页数:17
相关论文
共 50 条
  • [1] Predicting Code Smells and Analysis of Predictions: Using Machine Learning Techniques and Software Metrics
    Mhawish, Mohammad Y.
    Gupta, Manjari
    [J]. JOURNAL OF COMPUTER SCIENCE AND TECHNOLOGY, 2020, 35 (06): : 1428 - 1445
  • [2] Severity classification of software code smells using machine learning techniques: A comparative study
    Abdou, Ashraf
    Darwish, Nagy
    [J]. JOURNAL OF SOFTWARE-EVOLUTION AND PROCESS, 2024, 36 (01)
  • [3] Predicting Software Cohesion Metrics with Machine Learning Techniques
    Haner Kirgil, Elif Nur
    Ercelebi Ayyildiz, Tulin
    [J]. APPLIED SCIENCES-BASEL, 2023, 13 (06):
  • [4] Evaluation of Sampling Techniques in Software Fault Prediction Using Metrics and Code Smells
    Kaur, Kamaldeep
    Kaur, Parmeet
    [J]. 2017 INTERNATIONAL CONFERENCE ON ADVANCES IN COMPUTING, COMMUNICATIONS AND INFORMATICS (ICACCI), 2017, : 1377 - 1386
  • [5] Detecting Code Smells using Machine Learning Techniques: Are We There Yet?
    Di Nucci, Dario
    Palomba, Fabio
    Tamburri, Damian A.
    Serebrenik, Alexander
    De Lucia, Andrea
    [J]. 2018 25TH IEEE INTERNATIONAL CONFERENCE ON SOFTWARE ANALYSIS, EVOLUTION AND REENGINEERING (SANER 2018), 2018, : 612 - 621
  • [6] A Systematic Literature Survey of Software Metrics, Code Smells and Refactoring Techniques
    Agnihotri, Mansi
    Chug, Anuradha
    [J]. JOURNAL OF INFORMATION PROCESSING SYSTEMS, 2020, 16 (04): : 915 - 934
  • [7] Code Review Analysis of Software System using Machine Learning Techniques
    Lal, Harsh
    Pahwa, Gaurav
    [J]. PROCEEDINGS OF 2017 11TH INTERNATIONAL CONFERENCE ON INTELLIGENT SYSTEMS AND CONTROL (ISCO 2017), 2017, : 8 - 13
  • [8] Vulnerable Code Detection Using Software Metrics and Machine Learning
    Medeiros, Nadia
    Ivaki, Naghmeh
    Costa, Pedro
    Vieira, Marco
    [J]. IEEE ACCESS, 2020, 8 : 219174 - 219198
  • [9] Predicting Software Anomalies using Machine Learning Techniques
    Alonso, Javier
    Belanche, Lluis
    Avresky, Dimiter R.
    [J]. 2011 10TH IEEE INTERNATIONAL SYMPOSIUM ON NETWORK COMPUTING AND APPLICATIONS (NCA), 2011,
  • [10] Improving accuracy of code smells detection using machine learning with data balancing techniques
    Khleel, Nasraldeen Alnor Adam
    Nehez, Karoly
    [J]. JOURNAL OF SUPERCOMPUTING, 2024, 80 (14): : 21048 - 21093