Skip to content

Changing best shot image quality estimation thresholds#

In LUNA ID, you can change thresholds of the image quality estimation according to your needs.

Important: The threshold values are set to optimal by default. We do not recommend that you change the values, unless you are certain of what you are doing.

To change image quality estimation thresholds:

1․ Download the corresponding faceengine.conf file and open it in a text editor:

OS Download link
Android faceengine.conf
iOS (for devices) faceengine.conf
iOS (for simulators) faceengine.conf

2․ Change the required parameter values in the QualityEstimator::Settings section.

Important: When editing the faceengine.conf file, make sure that you change only the required values and do not remove any sections.

Parameter Description Default value
blurThreshold Determines whether the image is blurred. 0.61
lightThreshold Determines whether the image is overexposed, that is, too light. 0.57
darknessThreshold Determines whether the image is underexposed, that is, too dark. 0.50
illuminationThreshold Determines whether the face in the image is illuminated unevenly and there is a great difference between dark and light regions. 0.1
specularityThreshold Determines whether the image contains flares on face, that is, too specular. 0.1

3․ Place the faceengine.conf file in the corresponding directory:

OS Directory
Android assets/data/
iOS (for devices) fsdk.xcframework/ios-arm64/fsdk.framework/data
iOS (for simulators) fsdk.xcframework/ios-arm64_x86_64-simulator/fsdk.framework/data

4․ Rebuild and reinstall your app.