This model uses a combination of Haar cascade for face detection, Face Recognition API for face recognition, and KNN (K-Nearest Neighbor) for classification.
- Python 3
- Haar cascade
- Face Recognition API
- KNN (K-Nearest Neighbor)
- numpy
- opencv
- Preprocess the input data using Haar cascade and Face Recognition API.
- Train the KNN (K-Nearest Neighbor) model using the preprocessed data.
- Clone the repo:
git clone https://github.com/rishav-dahal/Attendance_system_KNN.git
- Make a virtual environment inside server dir. Eg:
python -m venv venv
- Activate the virtual environment. Eg:
source ./venv/bin/activate
- Install the dependencies from the repo's requirements.txt file.
pip install -r requirements.txt
- Run the following code:
python train.py
to train - Run the server.
python app.py
- Go to the url
localhost:8000
on your browser.