bob.ip.FaceEyesNorm¶
-
class
bob.ip.
FaceEyesNorm
((object)self, (float)eyes_distance, (int)crop_height, (int)crop_width, (float)crop_eyecenter_offset_h, (float)crop_eyecenter_offset_w) → None :¶ Bases:
Boost.Python.instance
Objects of this class, after configuration, can extract and normalize faces, given their eye center coordinates.
Constructs a FaceEyeNorm object.
- __init__( (object)self, (int)crop_height, (int)crop_width, (int)re_y, (int)re_x, (int)le_y, (int)le_x) -> None :
- Creates a FaceEyesNorm class that will put the eyes to the given locations and crop the image to the desired size.
__init__( (object)self, (FaceEyesNorm)other) -> None
-
__init__
((object)self, (float)eyes_distance, (int)crop_height, (int)crop_width, (float)crop_eyecenter_offset_h, (float)crop_eyecenter_offset_w) → None :¶ Constructs a FaceEyeNorm object.
- __init__( (object)self, (int)crop_height, (int)crop_width, (int)re_y, (int)re_x, (int)le_y, (int)le_x) -> None :
- Creates a FaceEyesNorm class that will put the eyes to the given locations and crop the image to the desired size.
__init__( (object)self, (FaceEyesNorm)other) -> None
Methods
__init__
((object)self, (float)eyes_distance, …)Constructs a FaceEyeNorm object. Attributes
crop_height
Height of the cropping area after the geometric normalization. crop_offset_h
y-coordinate of the point in the cropping area which is the middle of the segment defined by the eyes after the geometric normalization. crop_offset_w
x-coordinate of the point in the cropping area which is the middle of the segment defined by the eyes after the geometric normalization. crop_width
Width of the cropping area after the geometric normalization. eyes_distance
Expected distance between the eyes after the geometric normalization. last_angle
The angle value (in degrees) used by the rotation involved in the last call of the operator () last_scale
The scaling factor used by the scaling involved in the last call of the operator () -
__call__
((FaceEyesNorm)self, (object)input, (object)output, (float)re_y, (float)re_x, (float)le_y, (float)le_x) → None :¶ Extracts a face given the coordinates of the left (le_y, le_x) and right (re_y, re_x) eye centers. Please note that the horizontal position le_x of the left eye is usually larger than the position re_x of the right eye.
- __call__( (FaceEyesNorm)self, (object)input, (float)re_y, (float)re_x, (float)le_y, (float)le_x) -> object :
- Extracts a face given the coordinates of the left (le_y, le_x) and right (re_y, re_x) eye centers. Please note that the horizontal position le_x of the left eye is usually larger than the position re_x of the right eye. The output is allocated and returned.
- __call__( (FaceEyesNorm)self, (object)input, (object)input_mask, (object)output, (object)output_mask, (float)re_y, (float)re_x, (float)le_y, (float)le_x) -> None :
- Extracts a face given the coordinates of the left (le_y, le_x) and right (re_y, re_x) eye centers, taking mask into account.
-
crop_height
¶ Height of the cropping area after the geometric normalization.
-
crop_offset_h
¶ y-coordinate of the point in the cropping area which is the middle of the segment defined by the eyes after the geometric normalization.
-
crop_offset_w
¶ x-coordinate of the point in the cropping area which is the middle of the segment defined by the eyes after the geometric normalization.
-
crop_width
¶ Width of the cropping area after the geometric normalization.
-
eyes_distance
¶ Expected distance between the eyes after the geometric normalization.
-
last_angle
¶ The angle value (in degrees) used by the rotation involved in the last call of the operator ()
-
last_scale
¶ The scaling factor used by the scaling involved in the last call of the operator ()