Beyond Accuracy: An Empirical Study on Unit Testing in Open-source Deep Learning Projects
arXiv:2402.16546 · doi:10.1145/3638245
Abstract
Deep Learning (DL) models have rapidly advanced, focusing on achieving high performance through testing model accuracy and robustness. However, it is unclear whether DL projects, as software systems, are tested thoroughly or functionally correct when there is a need to treat and test them like other software systems. Therefore, we empirically study the unit tests in open-source DL projects, analyzing 9,129 projects from GitHub. We find that: 1) unit tested DL projects have positive correlation with the open-source project metrics and have a higher acceptance rate of pull requests, 2) 68% of the sampled DL projects are not unit tested at all, 3) the layer and utilities (utils) of DL models have the most unit tests. Based on these findings and previous research outcomes, we built a mapping taxonomy between unit tests and faults in DL projects. We discuss the implications of our findings for developers and researchers and highlight the need for unit testing in open-source DL projects to ensure their reliability and stability. The study contributes to this community by raising awareness of the importance of unit testing in DL projects and encouraging further research in this area.
arXiv commentACM Transactions on Software Engineering and Methodology (2023)
References in corpus (13)
- SpecAugment: A Simple Data Augmentation Method for Automatic Speech Recognition
- Activation Functions: Comparison of trends in Practice and Research for Deep Learning
- DeepXplore: Automated Whitebox Testing of Deep Learning Systems
- DeepGauge: Multi-Granularity Testing Criteria for Deep Learning Systems
- Understanding the Factors that Impact the Popularity of GitHub Repositories
- DLFuzz: Differential Fuzzing Testing of Deep Learning Systems
- Software Engineering Challenges of Deep Learning
- On Empirical Comparisons of Optimizers for Deep Learning
- Testing Deep Neural Networks
- Automated Unit Test Generation for Python
- Software Engineering Practice in the Development of Deep Learning Applications
- Exploring ML testing in practice -- Lessons learned from an interactive rapid review with Axis Communications
- What Do Users Ask in Open-Source AI Repositories? An Empirical Study of GitHub Issues