Using aggregation#
To eliminate occasional neural network faults when determining eye statuses and the presence of glasses to get the best shot, you can use aggregation.
How it works#
LUNA ID collects 10 frames and checks that all of them do not have glasses. Also, among these frames there should not be more than two frames with closed eyes. If these conditions are met, LUNA ID considers such a frame to be the best shot.
If one of the frames has glasses, such frame cannot be considered the best shot and the "Take off the glasses" error message is sent.
If 10 frames has no glasses, but more than two frames are with closed eyes, the "Eyes closed" error message is sent.
Enable aggregation#
In LUNA ID for Android#
In LUNA ID for Android, aggregation is enabled by default and cannot be disabled.
In LUNA ID for iOS#
To enable aggregation, do either of the following:
- In your code, set the
LCLunaConfiguration.glassesCheckEnabled
andLCLunaConfiguration.aggregationEnabled
properties totrue
. - In the LCLunaConfiguration.plist configuration file, set
glassesCheckEnabled
andaggregationEnabled
parameters totrue
.
By default, glassesCheckEnabled
and aggregationEnabled
are set to false
.