Deep Learning Based Feature Envy Detection

被引:58
|
作者
Liu, Hui [1 ]
Xu, Zhifeng [1 ]
Zou, Yanzhen [2 ,3 ]
机构
[1] Beijing Inst Technol, Sch Comp Sci & Technol, Beijing, Peoples R China
[2] Peking Univ, Minist Educ, Key Lab High Confidence Software Technol, Beijing, Peoples R China
[3] Peking Univ, Sch Elect Engn & Comp Sci, Beijing, Peoples R China
基金
中国国家自然科学基金;
关键词
Feature Envy; Deep Learning; Software Refactoring; Code Smells; SMELLS; REFACTORINGS;
D O I
10.1145/3238147.3238166
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Software refactoring is widely employed to improve software quality. A key step in software refactoring is to identify which part of the software should be refactored. To facilitate the identification, a number of approaches have been proposed to identify certain structures in the code (called code smells) that suggest the possibility of refactoring. Most of such approaches rely on manually designed heuristics to map manually selected source code metrics to predictions. However, it is challenging to manually select the best features, especially textual features. It is also difficult to manually construct the optimal heuristics. To this end, in this paper we propose a deep learning based novel approach to detecting feature envy, one of the most common code smells. The key insight is that deep neural networks and advanced deep learning techniques could automatically select features (especially textual features) of source code for feature envy detection, and could automatically build the complex mapping between such features and predictions. We also propose an automatic approach to generating labeled training data for the neural network based classifier, which does not require any human intervention. Evaluation results on open-source applications suggest that the proposed approach significantly improves the state-of-the-art in both detecting feature envy smells and recommending destinations for identified smelly methods.
引用
收藏
页码:385 / 396
页数:12
相关论文
共 50 条
  • [1] Deep Learning Based Feature Envy Detection Boosted by Real-World Examples
    Liu, Bo
    Liu, Hui
    Li, Guangjie
    Niu, Nan
    Xu, Zimao
    Wang, Yifan
    Xia, Yunni
    Zhang, Yuxia
    Jiang, Yanjie
    [J]. PROCEEDINGS OF THE 31ST ACM JOINT MEETING EUROPEAN SOFTWARE ENGINEERING CONFERENCE AND SYMPOSIUM ON THE FOUNDATIONS OF SOFTWARE ENGINEERING, ESEC/FSE 2023, 2023, : 908 - 920
  • [2] Local and Global Feature Based Explainable Feature Envy Detection
    Yin, Xin
    Shi, Chongyang
    Zhao, Shuxin
    [J]. 2021 IEEE 45TH ANNUAL COMPUTERS, SOFTWARE, AND APPLICATIONS CONFERENCE (COMPSAC 2021), 2021, : 942 - 951
  • [3] Feature Envy Factor A Metric for Automatic Feature Envy Detection
    Nongpong, Kwankamol
    [J]. 2015 7TH INTERNATIONAL CONFERENCE ON KNOWLEDGE AND SMART TECHNOLOGY (KST), 2015, : 7 - 12
  • [4] Deep semantic-Based Feature Envy Identification
    Guo, Xueliang
    Shi, Chongyang
    Jiang, He
    [J]. 11TH ASIA-PACIFIC SYMPOSIUM ON INTERNETWARE (INTERNETWARE 2019), 2019,
  • [5] Automatic Feature Learning for Glaucoma Detection Based on Deep Learning
    Chen, Xiangyu
    Xu, Yanwu
    Yan, Shuicheng
    Wong, Damon Wing Kee
    Wong, Tien Yin
    Liu, Jiang
    [J]. MEDICAL IMAGE COMPUTING AND COMPUTER-ASSISTED INTERVENTION, PT III, 2015, 9351 : 669 - 677
  • [6] A Feature Envy Detection Method Based on Dataflow Analysis
    Chen, Woei-Kae
    Liu, Chien-Hung
    Li, Bo-Hong
    [J]. 2018 IEEE 42ND ANNUAL COMPUTER SOFTWARE AND APPLICATIONS CONFERENCE (COMPSAC 2018), VOL 2, 2018, : 14 - 19
  • [7] Pre-trained Model Based Feature Envy Detection
    Ma, Wenhao
    Yu, Yaoxiang
    Ruan, Xiaoming
    Cai, Bo
    [J]. 2023 IEEE/ACM 20TH INTERNATIONAL CONFERENCE ON MINING SOFTWARE REPOSITORIES, MSR, 2023, : 430 - 440
  • [8] Deep learning based latent feature extraction for intrusion detection
    Mighan, Soosan Naderi
    Kahani, Mohsen
    [J]. 26TH IRANIAN CONFERENCE ON ELECTRICAL ENGINEERING (ICEE 2018), 2018, : 1511 - 1516
  • [9] Detection Mechanism of FDI attack feature based on Deep Learning
    Pu, Qiang
    Qin, Hao
    Han, Hu
    Xia, Yuanyi
    Li, Zhihao
    Xie, Kejun
    Wang, Wenqing
    [J]. 2018 IEEE SMARTWORLD, UBIQUITOUS INTELLIGENCE & COMPUTING, ADVANCED & TRUSTED COMPUTING, SCALABLE COMPUTING & COMMUNICATIONS, CLOUD & BIG DATA COMPUTING, INTERNET OF PEOPLE AND SMART CITY INNOVATION (SMARTWORLD/SCALCOM/UIC/ATC/CBDCOM/IOP/SCI), 2018, : 1761 - 1765
  • [10] Research on Feature Selection of Intrusion Detection Based on Deep Learning
    Xin, Mingyuan
    Wang, Yong
    [J]. 2020 16TH INTERNATIONAL WIRELESS COMMUNICATIONS & MOBILE COMPUTING CONFERENCE, IWCMC, 2020, : 1431 - 1434