I hereby claim:
- I am nshaud on github.
- I am nshaud (https://keybase.io/nshaud) on keybase.
- I have a public key ASCbRkNTCjELUE8rt6NXWedrW0guBXY58SVghAwYAZwe6Qo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
FROM debian:7 | |
ENV DEBIAN_FRONTEND noninteractive | |
RUN apt-get -qq update \ | |
&& apt-get -qq -y --no-install-recommends install \ | |
autoconf \ | |
automake \ | |
build-essential \ | |
curl \ |
from __future__ import print_function | |
import sys | |
import time | |
import random | |
def timeme(func): | |
# Decorator to time the various solutions | |
def timed(*args, **kwargs): | |
start = time.time() | |
res = func(*args, **kwargs) |
import cv2 # OpenCV | |
from PIL import Image | |
# Detect the bouding box of the faces | |
def detect_face(image): | |
# See http://docs.opencv.org/modules/objdetect/doc/cascade_classification.html | |
face_cascade = cv2.CascadeClassifier('haarcascade_frontalface_alt.xml') | |
# We ask a minimum size of 150px*150px for the face | |
# Helps remove false positives | |
min_size = (150,150) |