Fourier Properties Face Detection
Fourier Properties Face Detection
Fourier Properties Face Detection
Project Description:
In this project we are using OpenCv in Raspberry pi. This project is used to detect
the human Face with the help of OpenCv tool. In order to do object detection with
cascade files, you first need cascade files. For the extremely popular tasks, these
file already exist.
Software Required:
OpenCv
Raspian OS
Hardware Used:
Raspberry Pi
Camera
Power Supply
OpenCv:
Circuit Diagram:
Python Code:
import io
import picamera
import cv2
import numpy
stream = io.BytesIO()
#Here you can also specify other parameters (e.g.:rotate the image)
camera.capture(stream, format='jpeg')
image = cv2.imdecode(buff, 1)
#Convert to grayscale
gray = cv2.cvtColor(image,cv2.COLOR_BGR2GRAY)
#Look for faces in the image using the loaded cascade file
cv2.rectangle(image,(x,y),(x+w,y+h),(255,255,0),2)
cv2.imwrite('result.jpg',image)