Skip to content

arghadip2002/NeuroGuard-Web-Application

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

16 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🧠 NeuroGuard Web Application

Automated MRI Brain Tumor Detection System (HuggingFace Deployment Guide)


🌟 Introduction

The NeuroGuard Web Application is a state-of-the-art Deep Learning system built for automated, highly accurate classification of brain tumors from Magnetic Resonance Imaging (MRI) scans.

It uses a custom ResidualInceptionBlock Convolutional Neural Network (CNN) with over 50 layers, delivering real-time 4-class predictions:

  • Glioma
  • Meningioma
  • Pituitary
  • No Tumor

This repository contains the full-stack implementation using:

  • FastAPI (Backend + PyTorch Inference)
  • React + Vite (Frontend)
  • Docker + Docker Compose (Deployment)

It is optimized so that any user can deploy the full software directly on HuggingFace Spaces, without using their local machine.


πŸ–ΌοΈ Application UI

UI_0 UI_1 UI_2 UI_3


πŸš€ Deployment Instructions (HuggingFace Spaces)

This guide allows any user to deploy the full application inside HuggingFace Spaces using Docker β€” identical to running it on a production server.


βœ” 1. Clone the Repository from GitHub

git clone https://github.com/arghadip2002/NeuroGuard-Web-Application
cd NeuroGuard-Web-Application

βœ” 2. Download the Model File

The file backend/models/model.pth is intentionally empty in the repository.

You must download the trained model from the Google Drive link:

https://drive.google.com/drive/folders/17FJExilSleay1pIylXI1xIGx3oXhddzL?usp=sharing

Rename it to:

model_Full.pth

Then place it inside:

backend/models/

Final path:

backend/models/model_Full.pth

βœ” 3. Comment in the YAML Header at the Top

Before pushing to HuggingFace, comment in the following block:

<!--
---
title: ...
---
-->

It should look like this:

---
title: NeuroGuard Web Application
emoji: 🧠
colorFrom: blue
colorTo: purple
sdk: docker
app_port: 7860
pinned: false
---

These lines are required in HuggingFace.


βœ” 3.1 IMPORTANT: Delete Visualisation Folder & Reinitialize Git (NEW)

Before step 4 (pushing to your Space) you must remove the Visualisation folder (it contains local UI screenshots and is not required on the HuggingFace Space build), and then remove the repository history and reinitialize git to ensure a clean push to your new HuggingFace Space.

From the project root:

# delete the Visualisation folder
rm .\Visualisation\

# remove existing git history (hidden .git folder) manually

# reinitialize a fresh git repo
git init

# add all files and commit with the required message
git add .
git commit -m "all task completed as per instructions from the dev @arghadip2002"

Note: Removing .git and reinitializing gives you a clean commit history for the Space push. Make sure you have any remote backups you need before removing .git.

βœ” 4. Push to Your New HuggingFace Space

git remote add space https://huggingface.co/spaces/<your-username>/<your-space>
git push --force space main

HuggingFace will automatically:

  • Build the Docker container
  • Start the backend
  • Serve the frontend
  • Host the complete web application

Your app will be live at:

https://<your-username>-<your-space>.hf.space

πŸ› οΈ Technology Stack

Component Technology Version
Deep Learning PyTorch 2.1.0
Backend API FastAPI 0.104.1
Frontend React 18.2.0
Build Tool Vite 5.0.0
Containerization Docker Latest
Hosting Platform HuggingFace Spaces Latest

πŸ‘¨β€πŸ’» Developer & Credits


⭐ Notes

  • The project is fully functional once the correct model file is added.
  • HuggingFace spaces rebuild automatically on every push.

πŸ“œ Citation & Academic Acknowledgment

This repository provides the NeuroGuard Web Application, which is the deployment of the novel SAETCN and SAS-Net architectures detailed in our research paper.

If you use this deployed software or its code in your academic work, please cite the underlying paper to acknowledge the methodology and results:

✍️ Preferred Citation (BibTeX)

@article{das2025novel,
  title={Novel Deep Learning Architectures for Classification and Segmentation of Brain Tumors from MRI Images},
  author={Das, Sayan and Biswas, Arghadip},
  journal={arXiv preprint arXiv:2512.06531},
  year={2025}
}

πŸ”— Paper Link

The full paper is publicly available on the arXiv preprint server: arXiv:2512.06531

⭐ Note: Citing the paper is essential for the advancement of open science and ensures proper credit for the research that powers this application. Thank you for your support!

Releases

No releases published

Packages

 
 
 

Contributors