Academic project — not intended for commercial use.
A deep-learning-powered desktop application that automatically diagnoses three types of knee injuries from MRI scans.
- Project Overview
- Diagnosed Conditions
- Model Architecture
- Dataset
- Training Results
- Desktop Application (GUI)
- Project Structure
- Installation & Usage
- Team
- License
I-MRI Scan is a graduation project that uses convolutional neural networks to help clinicians detect knee injuries from MRI scans. Users can load a patient's MRI series through the desktop application, and the system will predict the likelihood of each of the three supported injury types.
Key highlights:
- Three independent binary-classification models, one per injury type.
- PyTorch-based deep learning pipeline trained on the MRNet dataset.
- Cross-platform desktop GUI built with PyQt5.
- Patient record management backed by a local SQLite / MySQL database.
| # | Condition | Description |
|---|---|---|
| 1 | ACL (Anterior Cruciate Ligament) | Detects tears or damage to the ACL, one of the major knee ligaments. |
| 2 | Meniscus | Identifies meniscal tears, which are common sports-related cartilage injuries. |
| 3 | Abnormality | Flags any general abnormality present in the knee MRI. |
Each model outputs a binary prediction (positive / negative) along with a confidence score.
All three models share the same underlying architecture but are trained independently with their respective labels:
- Base network: AlexNet (pre-trained on ImageNet, fine-tuned on MRI data)
- Input: Series of 2-D MRI slices treated as a 3-D volume
- Output: Single sigmoid neuron → binary classification
- Training platform: Google Colaboratory (GPU runtime)
- Model storage: Google Drive
Detailed notebooks for each experiment are available in the notebook/ directory.
The project uses the publicly available MRNet dataset released by Stanford ML Group.
- Modality: Knee MRI (axial, coronal, sagittal planes)
- Labels: ACL tear, meniscal tear, general abnormality
- Task type: Binary classification per label
Note: You must agree to Stanford's terms of use and download the dataset separately. It is not included in this repository.
| Training Accuracy | Training Loss |
|---|---|
![]() |
![]() |
| Validation Accuracy | Validation Loss |
|---|---|
![]() |
![]() |
| Training Accuracy | Training Loss |
|---|---|
![]() |
![]() |
| Validation Accuracy | Validation Loss |
|---|---|
![]() |
![]() |
The desktop application is built with PyQt5 and provides the following features:
- Load and preview MRI scan files.
- Run inference using the three trained models simultaneously.
- Display diagnosis results with confidence scores.
- Save patient records to a local database.
- Export reports to Excel (
.xlsx) format.
Graduation-project/
│
├── GUI/ # Desktop application source code
│ ├── design.py # PyQt5 UI layout definitions
│ ├── init.py # Application entry point
│ ├── models.py # Model loading and inference helpers
│ ├── preprocessing.py # MRI preprocessing pipeline
│ ├── threads.py # Background worker threads for inference
│ ├── database.py # Database connection and queries
│ ├── exports.py # Excel report export utilities
│ ├── database/ # SQLite database files
│ ├── resources/ # Icons and UI assets
│ ├── screen shoots/ # Application screenshots
│ └── requirements.txt # Python dependencies for the GUI
│
├── notebook/ # Jupyter notebooks for training & EDA
│ ├── MRNet_exploratory_data_analysis.ipynb
│ ├── MRnet_Models_Alexnet.ipynb
│ ├── triple_MRInet.ipynb
│ ├── triple_MRInet_V2.ipynb
│ ├── triple_MRInet_last_version.ipynb
│ ├── predication_notebook.ipynb
│ ├── utils.py # Shared utility functions
│ └── scripts/ # Standalone Python scripts
│ ├── alexnet.py # AlexNet model definition
│ ├── Data loader.py # MRNet data loader
│ └── Dataset_creation.py # Dataset preparation helpers
│
├── training results/ # Saved training/validation plots
├── I-MRI-Scan-documentation.pdf
├── Graduation-presentation.pdf
└── README.md
- Python 3.7+
- A CUDA-capable GPU is recommended for training; CPU-only is supported for inference.
cd GUI
pip install -r requirements.txtcd GUI
python init.pyOpen any notebook inside the notebook/ directory in Jupyter Notebook or upload it to Google Colab for GPU-accelerated training.
| Name | Role |
|---|---|
| Mohammed Adry Ahmed | Deep Learning Engineering |
| Mohammed Abd-Elnaby Abd-Elwahab | System Analysis |
| Mohammed Mustafa Megahd El-Ewasy | Desktop Application Development |
| Muhammad Tarek Refaat | Deep Learning Engineering |
This project is licensed under the terms of the LICENSE file included in this repository. It is intended solely for academic and research purposes and must not be used in any clinical or commercial setting without proper validation and regulatory approval.












