A complete Python + MySQL based attendance system that uses real-time facial recognition to automate and manage student attendance efficiently.
- 🧑🎓 Student Manager – Register, update, and delete student details via GUI.
- 📷 Face Dataset Generator – Capture multiple images per student using webcam.
- 🧠 Face Model Trainer – Train recognition model using OpenCV’s LBPH algorithm.
- 🧾 Real-Time Recognition – Detect and identify faces live from webcam.
- 📅 Attendance Logger – Automatically logs attendance with time and date.
- 📁 CSV Export – Save daily attendance in spreadsheet-friendly format.
- 🛢️ MySQL Backend – Securely store student and attendance data.
| Tech | Role |
|---|---|
| Python 3.x | Main Programming Language |
| OpenCV | Face Detection & Recognition |
| Tkinter | GUI Framework |
| MySQL | Backend Database |
| Pillow | Image Processing |
| NumPy | Numerical Operations |
| CSV, Datetime | Attendance Logging & Export |
git clone https://github.com/shivakantkurmi/Face-Recognition.git
cd Facial-Recognition-Attendancepip install opencv-python mysql-connector-python numpy pillow| Module File | Purpose |
|---|---|
main.py |
GUI Homepage for navigation |
student.py |
Add / Edit / Delete student info |
dataset_generator.py |
Capture facial images for training dataset |
trainer.py |
Train recognizer using LBPHFaceRecognizer |
recognizer.py |
Recognize faces and log attendance |
attendance.py |
View and export attendance records |
| Main Menu | Register Student | Face Detection |
|---|---|---|
![]() |
![]() |
![]() |
Licensed under the MIT License.
Pull requests are welcome! For major changes, open an issue to discuss improvements first.
Built with 💻 Python and ❤️ for smart automation in education.


