Deep learning based feature envy detection

Hui Liu*, Zhifeng Xu, Yanzhen Zou

*Corresponding author for this work

Research output: Chapter in Book/Report/Conference proceedingConference contributionpeer-review

86 Citations (Scopus)
Plum Print visual indicator of research metrics
  • Citations
    • Citation Indexes: 85
  • Captures
    • Readers: 77
see details

Abstract

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.

Original languageEnglish
Title of host publicationASE 2018 - Proceedings of the 33rd ACM/IEEE International Conference on Automated Software Engineering
EditorsChristian Kastner, Marianne Huchard, Gordon Fraser
PublisherAssociation for Computing Machinery, Inc
Pages385-396
Number of pages12
ISBN (Electronic)9781450359375
DOIs
Publication statusPublished - 3 Sept 2018
Event33rd IEEE/ACM International Conference on Automated Software Engineering, ASE 2018 - Montpellier, France
Duration: 3 Sept 20187 Sept 2018

Publication series

NameASE 2018 - Proceedings of the 33rd ACM/IEEE International Conference on Automated Software Engineering

Conference

Conference33rd IEEE/ACM International Conference on Automated Software Engineering, ASE 2018
Country/TerritoryFrance
CityMontpellier
Period3/09/187/09/18

Keywords

  • Code smells
  • Deep learning
  • Feature envy
  • Software refactoring

Fingerprint

Dive into the research topics of 'Deep learning based feature envy detection'. Together they form a unique fingerprint.

Cite this

Liu, H., Xu, Z., & Zou, Y. (2018). Deep learning based feature envy detection. In C. Kastner, M. Huchard, & G. Fraser (Eds.), ASE 2018 - Proceedings of the 33rd ACM/IEEE International Conference on Automated Software Engineering (pp. 385-396). (ASE 2018 - Proceedings of the 33rd ACM/IEEE International Conference on Automated Software Engineering). Association for Computing Machinery, Inc. https://doi.org/10.1145/3238147.3238166