This project is a facial attendance system that utilizes Flask for the backend, Bootstrap 5 for the frontend, and OpenCV for face detection and recognition.
📦 facial-attendance-system ├─ backend │ ├─ app.py │ ├─ instance │ │ └─ face_recognition_db.sqlite │ └─ templates │ └─ index.html ├─ dataset.py ├─ face_recognizer.py ├─ haarcascade_frontalface_default.xml ├─ trainer.py ├─ trainer │ └─ trainer.yml └─ webcam_dataset.py
- 🔧 Backend developed with Flask
- 🎨 Webpage styled using Bootstrap 5
- 👤 Facial detection and recognition using OpenCV
- 📸 Dataset gathering through webcam or images
- 📊 Model training for accurate recognition
- 📝 Attendance marking based on recognized faces
- 📸 Run dataset.py to gather photos from a video or webcam_dataset.py to capture photos from a live camera feed for the dataset.
- 🚀 Run
trainer.py
to train the model using the gathered dataset. - ⚙️ Ensure that the Flask server is running by executing
python3 app.py
. - 👀 Run
face_recognizer.py
to recognize faces and mark attendance.
To run the Flask server:
python3 app.py
Access the web interface at http://localhost:5000.
You can install the required packages using pip3. Run the following command:
pip3 install Flask opencv-python opencv-contrib-python requests
🤝 Contributions are welcome! If you find any bugs or have suggestions for improvements, please open an issue or submit a pull request.
This project is licensed under the MIT License - see the LICENSE file for details.