Transfer Learning based Low Shot Classifier for Software Defect Prediction
Downloads
Background: The rapid growth and increasing complexity of software applications are causing challenges in maintaining software quality within constraints of time and resources. This challenge led to the emergence of a new field of study known as Software Defect Prediction (SDP), which focuses on predicting future defect in advance, thereby reducing costs and improving productivity in software industry.
Objective: This study aimed to address data distribution disparities when applying transfer learning in multi-project scenarios, and to mitigate performance issues resulting from data scarcity in SDP.
Methods: The proposed approach, namely Transfer Learning based Low Shot Classifier (TLLSC), combined transfer learning and low shot learning approaches to create an SDP model. This model was designed for application in both new projects and those with minimal historical defect data.
Results: Experiments were conducted using standard datasets from projects within the National Aeronautics and Space Administration (NASA) and Software Research Laboratory (SOFTLAB) repository. TLLSC showed an average increase in F1-Measure of 31.22%, 27.66%, and 27.54% for project AR3, AR4, and AR5, respectively. These results surpassed those from Transfer Component Analysis (TCA+), Canonical Correlation Analysis (CCA+), and Kernel Canonical Correlation Analysis plus (KCCA+).
Conclusion: The results of the comparison between TLLSC and state-of-the-art algorithms, namely TCA+, CCA+, and KCCA+ from the existing literature consistently showed that TLLSC performed better in terms of F1-Measure.
Keywords: Just-in-time, Defect Prediction, Deep Learning, Transfer Learning, Low Shot Learning
J. Ott, A. Atchison, and E. J. Linstead, "Exploring the applicability of low-shot learning in mining software repositories,” Journal of Big Data, vol. 6, no. 1, p. 35, Dec. 2019, doi: 10.1186/s40537-019-0198-z.
W. Y. Chen, Y. C. F. Wang, Y. C. Liu, Z. Kira, and J. B. Huang, "A closer look at few-shot classification,” 7th International Conference on Learning Representations, ICLR 2019, no. 2018, pp. 1–17, 2019.
M. M. U. Chowdhury, F. Hammond, G. Konowicz, C. Xin, H. Wu, and J. Li, "A few-shot deep learning approach for improved intrusion detection,” 2017 IEEE 8th Annual Ubiquitous Computing, Electronics and Mobile Communication Conference, UEMCON 2017, vol. 2018-Janua, pp. 1–7, 2018, doi: 10.1109/UEMCON.2017.8249084.
J. Chen, Y. Yang, K. Hu, Q. Xuan, Y. Liu, and C. Yang, "Multiview transfer learning for software defect prediction,” IEEE Access, vol. 7, pp. 8901–8916, 2019, doi: 10.1109/ACCESS.2018.2890733.
J. Bai, J. Jia, and L. F. Capretz, "A three-stage transfer learning framework for multi-source cross-project software defect prediction,” Information and Software Technology, vol. 150, Oct. 2022, doi: 10.1016/j.infsof.2022.106985.
C. Liu, D. Yang, X. Xia, M. Yan, and X. Zhang, "A two-phase transfer learning model for cross-project defect prediction,” Information and Software Technology, vol. 107, no. September 2018, pp. 125–136, Mar. 2019, doi: 10.1016/j.infsof.2018.11.005.
S. Tang, S. Huang, C. Zheng, E. Liu, C. Zong, and Y. Ding, "A Novel Cross-Project Software Defect Prediction Algorithm Based on Transfer Learning,” 2022.
Z. Lu, R. H. Kazi, L. Y. Wei, M. Dontcheva, and K. Karahalios, "Software Visualization and Deep Transfer Learning for Effective Software Defect Prediction,” Proceedings of the ACM on Human-Computer Interaction, vol. 5, no. CSCW1, Apr. 2021, doi: 10.1145/1122445.1122456.
A. Wang, Y. Zhang, H. Wu, K. Jiang, and M. Wang, "Few-Shot Learning Based Balanced Distribution Adaptation for Heterogeneous Defect Prediction,” IEEE Access, vol. 8, pp. 32989–33001, 2020, doi: 10.1109/ACCESS.2020.2973924.
Q. Yu, S. Jiang, and Y. Zhang, "A feature matching and transfer approach for cross-company defect prediction,” Journal of Systems and Software, vol. 132, pp. 366–378, 2017, doi: 10.1016/j.jss.2017.06.070.
Y. Ma, G. Luo, X. Zeng, and A. Chen, "Transfer learning for cross-company software defect prediction,” Information and Software Technology, vol. 54, no. 3, pp. 248–256, 2012, doi: 10.1016/j.infsof.2011.09.007.
P. Usherwood and S. Smit, "Low-Shot Classification: A Comparison of Classical and Deep Transfer Machine Learning Approaches,” Jul. 2019, [Online]. Available: http://arxiv.org/abs/1907.07543
X. Yu, M. Wu, Y. Jian, K. E. Bennin, M. Fu, and C. Ma, "Cross-company defect prediction via semi-supervised clustering-based data filtering and MSTrA-based transfer learning,” Soft Computing, vol. 22, no. 10, pp. 3461–3472, 2018, doi: 10.1007/s00500-018-3093-1.
W. Wen, B. Zhang, X. Gu, and X. Ju, "An Empirical Study on Combining Source Selection and Transfer Learning for Cross-Project Defect Prediction,” IBF 2019 - 2019 IEEE 1st International Workshop on Intelligent Bug Fixing, pp. 29–38, 2019, doi: 10.1109/IBF.2019.8665492.
Y. Chen and X. Ding, "Research on cross - Project software defect prediction based on transfer learning,” in AIP Conference Proceedings, 2018, p. 040083. doi: 10.1063/1.5033747.
H. Qing, L. Biwen, S. Beijun, and Y. Xia, "Cross-Project Software Defect Prediction Using Feature-Based Transfer Learning,” in Proceedings of the 7th Asia-Pacific Symposium on Internetware - Internetware '15, New York, New York, USA: ACM Press, 2015, pp. 74–82. doi: 10.1145/2875913.2875944.
K. Li, Z. Xiang, T. Chen, S. Wang, and K. C. Tan, "Understanding the automated parameter optimization on transfer learning for cross-project defect prediction,” in Proceedings of the ACM/IEEE 42nd International Conference on Software Engineering, New York, NY, USA: ACM, Jun. 2020, pp. 566–577. doi: 10.1145/3377811.3380360.
X. Du, Z. Zhou, B. Yin, and G. Xiao, "Cross-project bug type prediction based on transfer learning,” Software Quality Journal, vol. 28, no. 1, pp. 39–57, Mar. 2020, doi: 10.1007/s11219-019-09467-0.
Y. Li et al., "Incremental Few-Shot Object Detection for Robotics,” pp. 1–11, May 2020.
Q. Sun, Y. Liu, T. S. Chua, and B. Schiele, "Meta-transfer learning for few-shot learning,” in Proceedings of the IEEE Computer Society Conference on Computer Vision and Pattern Recognition, Dec. 2019, pp. 403–412. doi: 10.1109/CVPR.2019.00049.
A. Li, W. Huang, X. Lan, J. Feng, Z. Li, and L. Wang, "Boosting Few-Shot Learning with Adaptive Margin Loss.”
O. Melamud, M. Bornea, and K. Barker, "Combining unsupervised pre-training and annotator rationales to improve low-shot text classification,” EMNLP-IJCNLP 2019 - 2019 Conference on Empirical Methods in Natural Language Processing and 9th International Joint Conference on Natural Language Processing, Proceedings of the Conference, no. 2011, pp. 3884–3893, 2020, doi: 10.18653/v1/d19-1401.
J. Nam, S. J. Pan, and S. Kim, "Transfer defect learning,” Proceedings - International Conference on Software Engineering, pp. 382–391, 2013, doi: 10.1109/ICSE.2013.6606584.
X. Jing, F. Wu, X. Dong, F. Qi, and B. Xu, "Heterogeneous cross-company defect prediction by unified metric representation and CCA-based transfer learning,” in Proceedings of the 2015 10th Joint Meeting on Foundations of Software Engineering - ESEC/FSE 2015, New York, New York, USA: ACM Press, 2015, pp. 496–507. doi: 10.1145/2786805.2786813.
Y. Ma, S. Zhu, Y. Chen, and J. Li, "Kernel CCA based transfer learning for software defect prediction,” IEICE Transactions on Information and Systems, vol. E100D, no. 8, pp. 1903–1906, 2017, doi: 10.1587/transinf.2016EDL8238.
Copyright (c) 2023 The Authors. Published by Universitas Airlangga.
This work is licensed under a Creative Commons Attribution 4.0 International License.
Authors who publish with this journal agree to the following terms:
All accepted papers will be published under a Creative Commons Attribution 4.0 International (CC BY 4.0) License. Authors retain copyright and grant the journal right of first publication. CC-BY Licenced means lets others to Share (copy and redistribute the material in any medium or format) and Adapt (remix, transform, and build upon the material for any purpose, even commercially).