Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/trieutuanvnu/Raspberry-Face-Recognition
Use Python and Open CV to recognize multi face and show the name
https://github.com/trieutuanvnu/Raspberry-Face-Recognition
Last synced: 8 days ago
JSON representation
Use Python and Open CV to recognize multi face and show the name
- Host: GitHub
- URL: https://github.com/trieutuanvnu/Raspberry-Face-Recognition
- Owner: trieutuanvnu
- Created: 2017-07-23T07:19:41.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-10-16T15:03:26.000Z (about 7 years ago)
- Last Synced: 2024-08-01T13:32:53.910Z (3 months ago)
- Language: Python
- Size: 134 KB
- Stars: 89
- Watchers: 9
- Forks: 67
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Raspberry-Face-Recognition
Use Python and Open CV to recognize multi face and show the name
#Sample to get video from PiCam
# import the necessary packages
from picamera.array import PiRGBArray
from picamera import PiCamera
import time
import cv2
# initialize the camera and grab a reference to the raw camera capture
camera = PiCamera()
camera.resolution = (640, 480)
camera.framerate = 32
rawCapture = PiRGBArray(camera, size=(640, 480))
# allow the camera to warmup
time.sleep(0.1)
# capture frames from the camera
for frame in camera.capture_continuous(rawCapture, format="bgr", use_video_port=True):
# grab the raw NumPy array representing the image, then initialize the timestamp
# and occupied/unoccupied text
image = frame.array
# show the frame
cv2.imshow("Frame", image)
key = cv2.waitKey(1) & 0xFF
# clear the stream in preparation for the next frame
rawCapture.truncate(0)
# if the `q` key was pressed, break from the loop
if key == ord("q"):
break