期刊文献+

Telecontext-Enhanced Recursive Interactive Attention Fusion Method for Line-Level Defect Prediction

在线阅读 下载PDF
导出
摘要 Software defect prediction aims to use measurement data of code and historical defects to predict potential problems,optimize testing resources and defect management.However,current methods face challenges:(1)Coarse-grained file level detection cannot accurately locate specific defects.(2)Fine-grained line-level defect prediction methods rely solely on local information of a single line of code,failing to deeply analyze the semantic context of the code line and ignoring the heuristic impact of line-level context on the code line,making it difficult to capture the interaction between global and local information.Therefore,this paper proposes a telecontext-enhanced recursive interactive attention fusion method for line-level defect prediction(TRIA-LineDP).Firstly,using a bidirectional hierarchical attention network to extract semantic features and contextual information from the original code lines as the basis.Then,the extracted contextual information is forwarded to the telecontext capture module to aggregate the global context,thereby enhancing the understanding of broader code dynamics.Finally,a recursive interaction model is used to simulate the interaction between code lines and line-level context,passing information layer by layer to enhance local and global information exchange,thereby achieving accurate defect localization.Experimental results from within-project defect prediction(WPDP)and cross-project defect prediction(CPDP)conducted on nine different projects(encompassing a total of 32 versions)demonstrated that,within the same project,the proposed methods will respectively recall at top 20%of lines of code(Recall@Top20%LOC)and effort at top 20%recall(Effort@Top20%Recall)has increased by 11%–52%and 23%–77%.In different projects,improvements of 9%–60%and 18%–77%have been achieved,which are superior to existing advanced methods and have good detection performance.
出处 《Computers, Materials & Continua》 2025年第2期2077-2108,共32页 计算机、材料和连续体(英文)
基金 supported by National Natural Science Foundation of China(no.62376240).
  • 相关文献

相关作者

内容加载中请稍等...

相关机构

内容加载中请稍等...

相关主题

内容加载中请稍等...

浏览历史

内容加载中请稍等...
;
使用帮助 返回顶部