A real-time classroom comprehension analysis platform built for educators. StudySphere uses computer vision and deep learning to analyze student facial expressions during live sessions — giving teachers instant, data-driven insights into how well their class is following along.
- Real-Time Video Monitoring — Live webcam feed with per-face comprehension labels updated every frame
- Snapshot Evaluation — Upload a classroom photo for instant comprehension analysis across all detected faces
- Session Reports — Auto-generated reports with comprehension timeline logged every 30 seconds, concentration trend graph, and final verdict
- Multi-Theme UI — Switch between Lilac, Yellow, and Blue themes
- Faces are detected in each webcam frame using OpenCV Haar Cascades
- Each face crop is passed to a MobileNetV2 model fine-tuned on FER2013
- The model outputs a confidence score mapped to:
- 🟢 Understood (≥ 0.65)
- 🟡 Uncertain (0.40 – 0.65)
- 🔴 Not Understood (< 0.40)
- Scores are aggregated using a weighted formula grounded in Cognitive Load Theory
- Every 30 seconds, a window report is logged and pushed to the frontend dashboard
| Layer | Technologies |
|---|---|
| Frontend | React, Vite, Recharts, Custom CSS |
| Backend | Python, Flask, flask-cors |
| ML & Vision | TensorFlow/Keras, OpenCV, MobileNetV2 |
| Dataset | FER2013 (binary: Understood / Not Understood) |
The trained model is not included in this repo due to file size. Download it here: studysphere_model.keras
After downloading, place it at:
backend/studysphere_model.keras
| Metric | Value |
|---|---|
| Test Accuracy | 66.94% |
| Test Loss | 0.6065 |
| Validation Accuracy | 66.21% |
The model is a MobileNetV2 fine-tuned on a binary-restructured FER2013 dataset (Understood / Not Understood). Accuracy reflects the challenge of real-world classroom facial expression analysis under varying lighting, angles, and occlusions.
- Python 3.10 (conda
cnnenvironment) - Node.js 18+
- Webcam access
git clone https://github.com/parinaB/StudySphere.git
cd studysphereconda activate cnn
cd backend
python app.pyBackend runs at http://localhost:5050
cd frontend
npm install
npm run devFrontend runs at http://localhost:5173
| Method | Endpoint | Description |
|---|---|---|
| POST | /evaluate |
Upload image, returns comprehension breakdown |
| GET | /stream |
Live MJPEG webcam stream |
| GET | /comprehension |
Latest real-time comprehension score |
| POST | /start-video |
Start session processing thread |
| POST | /stop-video |
Stop session cleanly |
| GET | /session-report |
Full 30-sec timeline + final verdict |
Built by Parina — ML student, edutech researcher.



