The dataset is organized into 3 folders (train, test, val) and contains subfolders for each image category (Pneumonia/Normal). There are 5,863 X-Ray images (JPEG) and 2 categories (Pneumonia/Normal).
Chest X-ray images (anterior-posterior) were selected from retrospective cohorts of pediatric patients of one to five years old from Guangzhou Women and Children’s Medical Center, Guangzhou. All chest X-ray imaging was performed as part of patients’ routine clinical care.
For the analysis of chest x-ray images, all chest radiographs were initially screened for quality control by removing all low quality or unreadable scans. The diagnoses for the images were then graded by two expert physicians before being cleared for training the AI system. In order to account for any grading errors, the evaluation set was also checked by a third expert.
The for the network used dataset was downloaded from Kaggle
The original dataset can be found here
git clone https://github.com/JanMarcelKezmann/Pneumonia-Detection-InceptionV3-Transfer-Learning.git
pip install -r requirements.txt
Just open the .ipynb code in a Notebook of your choice and run it.
Training the model with a on the imagenet dataset pretrained InceptionV3 model gives the follwing scores:
- Accuracy: 0.7131
- F1 Score: 0.7954
- Precision Score: 0.7175
- Recall Score: 0.8923
We get a lot better results if we use only the untrained InceptionV3 as a base model and train all of it.
Here we got the following results:
- Accuracy: 0.8413
- F1 Score: 0.8871
- Precision Score: 0.7988
- Recall Score: 0.9974
The Confusion Matrix of the Second Model
My work was partially inspired by this Kaggle Kernel and this Github Repository.
Just write me an E-Mail: j-m.kezmann@t-online.de
Or contact we via facebook.