A deep learning model for brain tumor classification using MRI images.

π§ Classify brain tumors with NeuroTumorNet! π©» Powered by a CNN built with TensorFlow π€, this tool analyzes MRI scans to detect Glioma, Meningioma, Pituitary, or No Tumor. π Upload an image via the Streamlit UI π and get instant predictions with confidence scores! β¨ Download the model or explore the live demo and datasets below. π₯οΈ
NeuroTumorNet is a CNN-based tool that classifies brain MRI images into four categories:
- Glioma tumor
- Meningioma tumor
- No tumor
- Pituitary tumor
The model uses a convolutional neural network architecture built with TensorFlow and Keras to provide accurate tumor classification.
- Automatic detection and classification of brain tumors
- Support for multiple tumor types (glioma, meningioma, pituitary)
- User-friendly web interface for image upload and analysis
- High accuracy brain tumor classification using convolutional neural networks
- Python 3.7+
- pip (Python package installer)
- Clone the repository:
git clone https://github.com/haybnzz/NeuroTumorNet/
cd NeuroTumorNet- Install required dependencies:
pip install -r requirements.txt- Download the pre-trained model:
- Option 1: Download directly from Hugging Face:
wget "https://huggingface.co/haydenbanz/NeuroTumorNet/resolve/main/brain_tumor_model.h5?download=true" -O brain_tumor_model.h5 - Option 2: Use the provided script to download and prepare the model:
python data_to_model.py
- Option 1: Download directly from Hugging Face:
- Option 3: Download directly from Kaggle:
Donload from above Badge section
```
If you want to train the model yourself or test it with the original dataset, you can download the brain tumor MRI dataset from the provided data link in the repository.
## Usage
### Running the Web Application
1. After installation, start the web application:
```bash
python app.py- Open your browser and navigate to:
http://localhost:5000
- Upload an MRI image through the web interface to get the tumor classification result.
NeuroTumorNet/
βββ app.py # Web application for tumor classification
βββ data_to_model.py # Script to download and prepare the model
βββ requirements.txt # Dependencies list
βββ brain_tumor_model.h5 # Pre-trained model file
β
βββ README.md # This file
NeuroTumorNet uses a deep convolutional neural network architecture designed specifically for medical image classification. The model architecture consists of:
- Multiple convolutional layers with ReLU activation
- Max pooling layers for feature extraction
- Dropout layers to prevent overfitting
- Dense layers for classification
The pre-trained model achieves high accuracy in classifying the four categories of brain MRI images.
The model was trained on a dataset containing brain MRI images categorized into four classes:
- Glioma tumor
- Meningioma tumor
- Pituitary tumor
- No tumor (normal brain MRI)
To download the dataset for training or testing purposes, visit one of these sources:
After downloading, place the dataset in a folder named dataset with the following structure:
dataset/
βββ Training/
β βββ glioma_tumor/
β βββ meningioma_tumor/
β βββ no_tumor/
β βββ pituitary_tumor/
βββ Testing/
βββ glioma_tumor/
βββ meningioma_tumor/
βββ no_tumor/
βββ pituitary_tumor/
Here are the images from the repository:
This project is licensed under the Creative Commons Attribution-NonCommercial 4.0 International (CC BY-NC 4.0) License. See the LICENSE file for more details.
Unauthorized use is strictly prohibited.
π§ Contact: singularat@protn.me
Donate via Monero: 45PU6txuLxtFFcVP95qT2xXdg7eZzPsqFfbtZp5HTjLbPquDAugBKNSh1bJ76qmAWNGMBCKk4R1UCYqXxYwYfP2wTggZNhq
If you use NeuroTumorNet in your research, please cite:
@software{NeuroTumorNet2025,
author = {Haybnzz and Glitchesminds},
title = {NeuroTumorNet: Deep Learning for Brain Tumor Classification},
url = {https://github.com/haybnzz/NeuroTumorNet},
year = {2025},
}
@misc {hay.bnz_2025,
author = { {Hay.Bnz} },
title = { NeuroTumorNet (Revision 7f9585f) },
year = 2025,
url = { https://huggingface.co/haydenbanz/NeuroTumorNet },
doi = { 10.57967/hf/4899 },
publisher = { Hugging Face }
}
- Thanks to all contributors to the brain tumor MRI datasets used in training this model
- Built with TensorFlow and Keras


