- A classification model for covid-19 chest X-ray images using ResNet50 was built.
- Dataset used consists of four classes.
- Covid-19 Positive, Normal, Viral Pneumonia, Bacterial Pneumonia are the four classes used for building the model.
- Performed image preprocessing for all the training images.
- Trained and saved the model with prediction result of 70% accuracy.
- Deployed the model as web aplication using flask framework.
Python Version: 3.7
Packages: pandas, numpy, sklearn, matplotlib, seaborn, tensorflow, cv2, flask
Tutorial for Transfer learning: Dr. Ryan Ahmed (Udemy)
Tutorial for flask deployment: Dan We (Udemy)
- Two folders
- Train: 532 images
- Test: 40 images
- ResNet50 was used for transfer learning.
- Using ImageDataGenerator imported dataset and performed data augmentation to significantly increase the diversity of data available for training models.
- Dropout techniques were used to prevent the model from overfitting.
- Too many epochs can lead to overfitting of the training dataset, whereas too few may result in an underfit model. So, Early stopping is utilised which is a method that allows you to specify an arbitrary large number of training epochs and stop training once the model performance stops improving on a hold out validation dataset.
- After evaluating the model using Test dataset, the prediction results were 70% accurate.
- Using the flask framework, the model was deployed in web application.
- Model can be deployed using 'Flask Covid xray deploy.py'