Package pyvision :: Package face :: Module headdetector :: Class HeadDetector
[hide private]
[frames] | no frames]

Class HeadDetector

source code

object --+
         |
        HeadDetector

A detector that uses multiple detectors and quality measures to accuratly detect faces. The goal is to be slow but accurate.

Instance Methods [hide private]
 
__init__(self, prescale=0.25, weights=array([[ 5.62758656e+0..., default=True)
Initialize the detector with default parameters.
source code
 
detect(self, im, annotate=True)
This performs face detection and returns an ordered list of faces sorted by confidence scores.
source code
 
raw_detections(self, im)
Run the face detectors with additional quality parameters.
source code
 
train(self, image_dir, eye_data)
This function trains the logistic regression model to score the meta-detections.
source code
 
__call__(self, *args, **kwargs) source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, prescale=0.25, weights=array([[ 5.62758656e+0..., default=True)
(Constructor)

source code 

Initialize the detector with default parameters.

Overrides: object.__init__

train(self, image_dir, eye_data)

source code 

This function trains the logistic regression model to score the meta-detections.

Images must be oriented so that the face is upright.

Parameters:
  • image_dir - A pathname containing images.
  • eye_data - a list of tuples (from csv) filename,eye1x,eye1y,eye2x,eye2y