# Performance Analysis for COVID-19 Diagnosis Using Custom and State-of-the-Art Deep Learning Models
## 5 Discussion  
This study, firstly compared three deep learning models to evaluate their performance on a dataset with the highest number of COVID-19 chest X-ray images, to the best of the authors' knowledge. The first model, Custom-Model, was developed by the authors. Secondly, the MobileNetV2-based model [23], which comprised the MobileNetV2 model with added layers, and finally, the Xception model with added layers were evaluated using different metrics, specifically, accuracy, precision, recall, and F1 score. Moreover, ROC, AUC, and macro and weighted averages were also compared. The Xception model was found to exceed the other models in terms of performance percentages. However, the confusion matrix demonstrated that the MobileNetV2 model correctly identified two more COVID-19 cases than did the Xception model. Also, it should be added that MobileNetV2 misclassified a far higher number of the other classes as COVID-19. In terms of precision, the custom-developed Custom-Model performed better than the MobileNetV2 model by a difference of 4%, making it the best performer compared with various state-of-the-art models in a previous study [50]. The difference in precision values of the MobileNetV2 model and the Xception model is 5%. From the confusion matrix, it can be seen that MobileNetV2 wrongly predicted 60 non-COVID-19 cases to be positive, while this number was 12 for Xception, and 25 for Custom-Model. Precision gives more weighting \begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Architecture** & **Average Scheme** & **Precision** & **Recall** & **F1 Score** \\ \hline Custom-Model & & 0.93 & 0.92 & 0.92 \\ MobileNetV2 Model & Macro Average & 0.94 & 0.93 & 0.93 \\ Xception Model & & 0.95 & 0.94 & 0.94 \\ \hline Custom-Model & & 0.92 & 0.92 & 0.92 \\ MobileNetV2 Model & Weighted Average & 0.93 & 0.94 & 0.93 \\ Xception Model & & 0.94 & 0.94 & 0.94 \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Macro and weighted averages of different scores. Figure 16: ROC curve for Xception model. to Custom-Model and Xception when compared with MobileNetV2 because if more people are wrongly identified as positive for COVID-19 and sent to treatment facilities (hospitals). Further, as reported by The New York Times in the USA, the COVID-19 pandemic led to the flooding of hospitals with patients causing a lack of available beds, and of doctors and nurses. Therefore, in such an alarming situation, it is critical for the diagnostic tests to be more accurate in diagnosing positive results for COVID-19. The MobileNetV2 model, however, exceeds slightly-by 2 cases-in recall (i.e., sensitivity) when compared with the Xception model. Custom-Model misclassified 85 COVID-19 cases as normal and lung opacity, Xception misclassified 59, and MobileNetV2 misclassified 57 COVID-19 cases. This reflects the case where false negatives are also important, as accrediting COVID-19 to other classes will deprive the patients of treatment and will also result in non-isolation of the patient, therefore, possibly causing an increase in the spread of the virus. Overall, the Xception model with some added layers outperformed the two other models well and exceeds both of them in terms of F1 score. The ROC curves for the three models are comparable; however, MobileNetV2 and Xception exceed the third model in terms of the AUC. The number of COVID-19 images from the literature, as covered by the authors, contained a minimum of 127 images to a maximum of 850 and few are high imbalance in terms of class. The highest accuracy found in the literature surveyed was a maximum of 99.9% for binary classification where the number of images of the other classes (400) were kept equal to the number of images of the subject virus. The maximum accuracy achieved on binary classification from the literature was 99.90%, while on multi-class classification, it was 99.658% on the test set.