Algorithm 5. The CXR-Score ensemble description. |
Input: CXR images of dimension 500 × 500 pixels from the Testing CXR Dataset Output: prediction probabilities for each diagnosis class (Normal, Mild, Moderate, Severe) 1. for each image in the dataset do 2. resize the image to 224 × 224 pixels 3. normalize the image pixels values from (0,255) to (0,1) 4. end 5. Load the trained VGG-19 model 6. Load the trained InceptionV3 model 7. Load the trained ResNet50 model 8. Load the trained DenseNet121 model 9. Predict the images with VGG-19 resulting in a list of probabilities (P11, P12, P13, P14) 10. Predict the images with InceptionV3 resulting in a list of probabilities (P21, P22, P23, P24) 11. Predict the images with ResNet50 resulting in a list of probabilities (P31, P32, P33, P34) 12. Predict the images with DenseNet121 resulting in a list of probabilities (P41, P42, P43, P44) 13. Average the four lists of predictions of the four models. 14. for each class in the set of diagnoses do 15. output prediction probability 16. end |