Eye glasses Detection

SDK.detect_glasses(self: tfsdk.SDK, face_box_and_landmarks: tfsdk.FaceBoxAndLandmarks)Tuple[tfsdk.ERRORCODE, tfsdk.GLASSESLABEL, float]

“Detect if there are eye glasses on the face in the given image.

Parameters

face_box_and_landmarkstfsdk.FaceBoxAndLandmarks returned by tfsdk.SDK.detect_faces() or tfsdk.SDK.detect_largest_face().

Returns

The ERRORCODE, the tfsdk.GLASSESLABEL, and the glasses score, in that order. The glasses score can be used for setting a custom threshold that works better for the use case. By default, we use a glasses score greater than 0.0 to determine that glasses were detected.

class tfsdk.GLASSESLABEL

Members:

GLASSES : There are glasses on the face

NO_GLASSES : There are no glasses on the face