This is a Streamlit app for performing object detection on images and webcam streams using the YOLOv8 model.
The aim of this project is to perform object detection on images and webcam streams to classify them as either device
, live
, photo
, or spoof
.
To use the app, follow these steps:
- Clone the repository:
git clone https://github.com/your-username/your-repo-name.git
- Install the dependencies:
pip install -r requirements.txt
- Run the app:
streamlit run app.py
-
Select an option from the radio button:
-
Upload an image: Upload an image from your local machine to perform object detection on.
-
Use webcam: Use your webcam to perform object detection on a live stream.
-
Provide image URL: Provide a URL of an image to perform object detection on.
-
-
Follow the instructions based on your selected option.
The following dependencies are required to run the app:
- streamlit
- Pillow
- ultralytics
- opencv-python-headless
- requests
- streamlit-webrtc
These dependencies can be installed by running the following command:
pip install -r requirements.txt
The YOLOv8 model used for object detection can be found in the models
directory. The best_real_face_detection.pt
file is used for real face detection.
This project is licensed under the terms of the MIT license.