A study of the interactive role of metamorphic testing and machine learning in the quality assurance of a deep learning forecasting application

Islam Nasr,Lobna Nassar,Fakhri Karray
DOI: https://doi.org/10.1007/s41870-023-01390-9
2023-08-18
International Journal of Information Technology
Abstract:One of the major problems in testing software code and assuring its quality is deriving test oracles. This problem becomes more evident when testing machine learning models. To overcome such problems, metamorphic testing is introduced. Metamorphic testing is built to test the presence of metamorphic relations; required relations that should hold for the program to be valid. Those metamorphic requirements are usually articulated by domain experts since they are application dependent which is a costly, complex, and error prone process. Therefore, the automatic detection of such relations can be more efficient for code verification. The novelty of this work is first emphasizing the two-way relationship between metamorphic testing and machine learning; where metamorphic testing is used to assess the effectiveness of machine learning models, while machine learning is used to automatically detect the main metamorphic relations in software code. Secondly, literature metamorphic relations are categorized into the eight main categories defined in literature, and three new metamorphic relations are introduced for the first time. Finally, all literature metamorphic relations are customized to fit the time series forecasting domain. An application is proposed consisting of a deep learning model for forecasting fresh produce yields along with a generalization framework to enable the proposed models to forecast other similar fresh produce yields. The interactive role played by metamorphic testing and machine learning is investigated through the quality assurance of the forecasting application. The datasets used to train and test the deep learning forecasting models as well as the forecasting models are verified using metamorphic tests and the metamorphic relations in the generalization code are automatically detected using support vector machine (SVM) models. Testing revealed the unmatched requirements that are fixed to have a valid application with sound data, effective models, and valid generalization code.
What problem does this paper attempt to address?