Instructions to use starpreeda/BrainTumorTest with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Keras
How to use starpreeda/BrainTumorTest with Keras:
# Available backend options are: "jax", "torch", "tensorflow". import os os.environ["KERAS_BACKEND"] = "jax" import keras model = keras.saving.load_model("hf://starpreeda/BrainTumorTest") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -1,3 +1,56 @@
|
|
| 1 |
---
|
| 2 |
license: mit
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 3 |
---
|
|
|
|
| 1 |
---
|
| 2 |
license: mit
|
| 3 |
+
base_model: google/efficientnet-b0
|
| 4 |
+
tags:
|
| 5 |
+
- medical
|
| 6 |
+
- mri
|
| 7 |
+
- brain-tumor-detection
|
| 8 |
+
- computer-vision
|
| 9 |
+
- image-classification
|
| 10 |
+
- tensorflow
|
| 11 |
+
- keras
|
| 12 |
+
pipeline_tag: image-classification
|
| 13 |
+
library_name: keras
|
| 14 |
+
---
|
| 15 |
+
|
| 16 |
+
# 🧠 Brain Tumor MRI Classification Model (Fine-Tuned EfficientNetB0)
|
| 17 |
+
|
| 18 |
+
This model is a fine-tuned version of **EfficientNetB0** trained to classify Brain Tumor types from MRI images into 4 distinct classes.
|
| 19 |
+
|
| 20 |
+
## 📋 Model Overview
|
| 21 |
+
|
| 22 |
+
- **Base Architecture:** EfficientNetB0 (Pre-trained on ImageNet)
|
| 23 |
+
- **Task:** Multi-class Image Classification (4 Classes)
|
| 24 |
+
- **Input Image Size:** 224 x 224 x 3
|
| 25 |
+
- **Framework:** TensorFlow 2.x / Keras
|
| 26 |
+
|
| 27 |
+
## 🏷️ Target Classes
|
| 28 |
+
|
| 29 |
+
1. **Glioma Tumor**
|
| 30 |
+
2. **Meningioma Tumor**
|
| 31 |
+
3. **No Tumor**
|
| 32 |
+
4. **Pituitary Tumor**
|
| 33 |
+
|
| 34 |
+
## ⚙️ Training Details & Hyperparameters
|
| 35 |
+
|
| 36 |
+
- **Optimizer:** Adam (Learning Rate = `1e-4`)
|
| 37 |
+
- **Loss Function:** Categorical Crossentropy
|
| 38 |
+
- **Batch Size:** 16
|
| 39 |
+
- **Data Augmentation:**
|
| 40 |
+
- Rotation Range: 15°
|
| 41 |
+
- Width & Height Shift: 10%
|
| 42 |
+
- Zoom Range: 15%
|
| 43 |
+
- Horizontal Flip: True
|
| 44 |
+
- **Fine-Tuning Strategy:** Unfroze top 40 layers of EfficientNetB0 for fine-tuning.
|
| 45 |
+
|
| 46 |
+
## 📊 Model Architecture Summary
|
| 47 |
+
|
| 48 |
+
```text
|
| 49 |
+
Input (224, 224, 3)
|
| 50 |
+
↳ EfficientNetB0 Base (Top 40 layers unfrozen)
|
| 51 |
+
↳ GlobalAveragePooling2D
|
| 52 |
+
↳ BatchNormalization
|
| 53 |
+
↳ Dense(256, activation='relu')
|
| 54 |
+
↳ Dropout(0.4)
|
| 55 |
+
↳ Dense(4, activation='softmax')
|
| 56 |
---
|