Dragonscypher commited on
Commit
564280d
Β·
verified Β·
1 Parent(s): 2b2e13e

Create README.md

Browse files

⚠️ Bias, Risks, and Limitations
🚧 Potential Biases

Trained primarily on US-based patient data
May not generalize well to different demographics & imaging techniques
Model confidence does not equal correctness

πŸš‘ Limitations

Not a diagnostic tool: AI cannot replace radiologists
Best suited for frontal X-rays (not lateral)
Cannot detect rare conditions not in the dataset

βœ… Recommendations

Always consult a radiologist for diagnosis.
Fine-tune the model on regional hospital data if needed.
Use ensemble learning for higher accuracy.

πŸ“– Training Details

Dataset 1: NIH Chest X-ray Dataset (~100,000 images)
Dataset 2: NLMCXR Dataset (Radiology Reports + X-ray images)
Loss Function: Cross-Entropy Loss
Optimizer: Adam with Learning Rate Scheduling
Batch Size: 32
Epochs: 20
Hardware Used: NVIDIA V100 GPU (AWS Cloud)

πŸ“Š Evaluation Metrics

AUROC (Area Under Receiver Operating Curve)
Precision / Recall
F1 Score
Accuracy across conditions

🌱 Environmental Impact

This model was trained on cloud GPUs with optimizations to reduce energy consumption.

Hardware Type: NVIDIA V100 GPU
Total Training Time: ~20 GPU Hours
Cloud Provider: AWS (US-East)
Estimated Carbon Emissions: ~15 kg COβ‚‚

🀝 Acknowledgments

NIH & NLMCXR datasets
Hugging Face & PyTorch for model training
Community support & AI healthcare initiatives
---

### **What This Model Card Covers:**
βœ… **Full project backstory** (False TB result β†’ AI model solution)
βœ… **EfficientNet_B0 vs. Other models** (Why it was chosen)
βœ… **How to use it** (Code + Dependencies)
βœ… **Evaluation metrics & Dataset details**
βœ… **Bias, Risks, & Future Work**


Let me know if you need **further refinements** before uploading.

Files changed (1) hide show
  1. README.md +67 -0
README.md ADDED
@@ -0,0 +1,67 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language: []
3
+ license: mit
4
+ tags:
5
+ - chest-xray
6
+ - efficientnet-b0
7
+ - medical-ai
8
+ - radiology
9
+ - deep-learning
10
+ datasets:
11
+ - nih-chest-xray
12
+ - nlmcxr
13
+ model-index:
14
+ - name: AI-Powered Chest X-ray Analysis (EfficientNet_B0)
15
+ results:
16
+ - task:
17
+ type: image-classification
18
+ dataset:
19
+ name: nih-chest-xray
20
+ type: medical-image
21
+ metrics:
22
+ - name: AUROC Score
23
+ type: accuracy
24
+ value: 0.72 - 0.93
25
+ ---
26
+
27
+ # AI-Powered Chest X-ray Analysis (EfficientNet_B0)
28
+
29
+ ## 🩺 Overview
30
+
31
+ This model analyzes **chest X-rays** to detect **14 potential lung conditions** using **EfficientNet_B0**, a lightweight yet high-performing CNN. It was trained on **NIH Chest X-ray Dataset & NLMCXR Dataset**, providing reliable multi-class classification for various lung diseases.
32
+
33
+ ### πŸš€ Motivation
34
+ This project began when I received a **false-positive tuberculosis (TB) report** and had to wait for **delayed X-ray results** due to a holiday. Not knowing how to interpret X-rays, I **built this AI tool** to **help others in similar situations**.
35
+
36
+ ## πŸ“œ Model Details
37
+
38
+ - **Model type**: Image Classification (Chest X-ray Analysis)
39
+ - **Architecture**: EfficientNet_B0
40
+ - **Trained on**: NIH Chest X-ray & NLMCXR Datasets
41
+ - **Input format**: Chest X-ray images (`.png`, `.jpg`)
42
+ - **Output**: Probabilities for 14 lung conditions
43
+ - **License**: MIT
44
+ - **Compute Requirement**: Can run on CPU, optimized for **GPU (CUDA)**
45
+
46
+ ## πŸ’‘ Why EfficientNet_B0?
47
+ I tested multiple models, including **DenseNet121, ViT, and CNNs**, but **EfficientNet_B0_best_93.44** outperformed the others in terms of:
48
+ - **High Accuracy (AUROC: 0.72 - 0.93)**
49
+ - **Lower Computational Cost**
50
+ - **Faster Inference Speed**
51
+ - **Better Generalization across datasets**
52
+
53
+ ## πŸ“Š Model Performance
54
+
55
+ | Model | AUROC Score (Avg) |
56
+ |--------------------|------------------|
57
+ | **EfficientNet_B0** | **0.72 - 0.93** |
58
+ | DenseNet121 | 0.55 - 0.95 |
59
+ | ViT_Base | 0.32 - 0.65 |
60
+
61
+ ---
62
+
63
+ ## πŸ”§ How to Use the Model
64
+
65
+ ### **1️⃣ Install Dependencies**
66
+ ```bash
67
+ pip install torch torchvision transformers pillow numpy matplotlib seaborn