TIEVisionFaceDetector.setRefineLandmarks
Declaration
procedure setRefineLandmarks(value: bool32); safecall;
Description
The neural network places the landmarks (eyes, nose tip and mouth corners) of a tilted face as if the head were tilted only about 20 degrees, and for some small or dim faces as if it were not tilted at all, so for tilted faces the landmarks are in the wrong place.
When enabled, each face is detected again on copies of it rotated in 15 degree steps, to find the angle at which it is most clearly upright, and the landmarks are then measured on the upright copy. The result is within about 3 degrees for clear faces tilted up to 70 degrees (and within about 8 degrees for small faces). Upright faces keep their original landmarks.
This makes
getRollAngle,
alignFace and anything else that uses the landmarks reliable for tilted faces. The face rectangle and score are not changed.
Detection takes about 10 to 20 milliseconds longer per face.
Faces tilted by more than about 70 degrees are not found at all, unless you enable
setDetectRotated.
Default: True
Example
// Use the landmarks exactly as the network returns them (faster)
detector.setRefineLandmarks( False );
See Also
◼getRefineLandmarks
◼setDetectRotated
◼getLandmark