DeepLineDP: Towards a Deep Learning Approach for Line-Level Defect Prediction
Top Cited Papers
- 21 January 2022
- journal article
- research article
- Published by Institute of Electrical and Electronics Engineers (IEEE) in IEEE Transactions on Software Engineering
- Vol. 49 (1) , 84-98
Abstract
Defect prediction is proposed to assist practitioners effectively prioritize limited Software Quality Assurance (SQA) resources on the most risky files that are likely to have post-release software defects. However, there exist two main limitations in prior studies: (1) the granularity levels of defect predictions are still coarse-grained and (2) the surrounding tokens and surrounding lines have not yet been fully utilized. In this paper, we perform a survey study to better understand how practitioners perform code inspection in modern code review process, and their perception on a line-level defect prediction. According to the responses from 36 practitioners, we found that 50% of them spent at least 10 minutes to more than one hour to review a single file, while 64% of them still perceived that code inspection activity is challenging to extremely challenging. In addition, 64% of the respondents perceived that a line-level defect prediction tool would potentially be helpful in identifying defective lines. Motivated by the practitioners' perspective, we present DeepLineDP, a deep learning approach to automatically learn the semantic properties of the surrounding tokens and lines in order to identify defective files and defective lines. Through a case study of 32 releases of 9 software projects, we find that the risk score of code tokens varies greatly depending on their location. Our DeepLineDP is 14%-24% more accurate than other file-level defect prediction approaches; is 50%-250% more cost-effective than other line-level defect prediction approaches; and achieves a reasonable performance when transferred to other software projects. These findings confirm that the surrounding tokens and surrounding lines should be considered to identify the fine-grained locations of defective files (i.e., defective lines).Keywords
Funding Information
- Australian Research Council
- Discovery Early Career Researcher Award (DE200100941)
This publication has 72 references indexed in Scilit:
- Toward Deep Learning Software Repositories2015
- Investigating Code Review Practices in Defective Files: An Empirical Study of the Qt System2015
- Mining Version Histories for Detecting Code SmellsIEEE Transactions on Software Engineering, 2014
- Using Pre-Release Test Failures to Build Early Post-Release Defect Prediction Models2014
- A systematic and comprehensive investigation of methods to build and evaluate fault prediction modelsJournal of Systems and Software, 2010
- Fault-prone module detection using large-scale text features based on spam filteringEmpirical Software Engineering, 2009
- Cross-project defect prediction2009
- On the relative value of cross-company and within-company data for defect predictionEmpirical Software Engineering, 2009
- Personal Opinion Surveys2008
- A validation of object-oriented design metrics as quality indicatorsIEEE Transactions on Software Engineering, 1996