Skip to content

Lightweight TinyVGG Inspired CNN 1.35M Parameter with Squeeze-and-Excitation blocks for ocular disease classification

Notifications You must be signed in to change notification settings

LuluW8071/TinyOcuNet

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TinyOcuNet

A Lightweight Deep Learning Model for Ocular Disease Classification

Model Design

Classification Type Architecture / Features Purpose
Binary Classification Derived from VGG, with fewer convolutional layers for efficiency Classify Cataract vs. Normal Eye
Multi-Class Classification Incorporates Squeeze-and-Excitation (SE) blocks at the end of each convolutional block; learns discriminative channel-level features Generalizes to multiple ocular diseases

Training uses mixed precision to reduce model size and training time while maintaining strong performance.


Usage

1. Install Dependencies

pip install -r requirements.txt

2. Run the Streamlit Demo

streamlit run ./demo/main.py

Loss and Accuracy Curves

Results for Multiple Ocular Eye Disease Classification.

Best Epoch Train Loss Test Loss Train Acc Test Acc
91 0.1931 0.1432 92.63 95.21

Training Curves:

Loss Curve Accuracy Curve
Loss curve Accuracy curve
Confusion Matrix ROC Curve
Confusion Matrix ROC Curve

Pretrained Models

Pre-trained weights are available in the models/ directory. To load the trained model (in Colab or locally):

model.load_state_dict(torch.load("models/MultipleEyeDiseaseDetectModel.pth"))

If you find this project useful, consider starring the repository to support further development.

About

Lightweight TinyVGG Inspired CNN 1.35M Parameter with Squeeze-and-Excitation blocks for ocular disease classification

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published