Skip to content

Performing Offline OneShotLiveness estimation#

With LUNA ID, you can check liveness directly on your device. Unlike Online OneShotLiveness estimation, you do not have to send requests to the LUNA PLATFORM 5 /liveness endpoint to determine if the person in the image is a living person or a photograph.

In LUNA ID for Android#

To perform Offline OneShotLiveness estimation:

1․ Specify the neural network used for Offline OneShotLiveness estimation:

    implementation("ai.visionlabs.lunaid:oslm:1.7.0@aar")

2․ Specify the estimation type in LunaConfig:

LunaConfig.create(
    LivenessType.Offline
)

In LUNA ID for iOS#

To perform Offline OneShotLiveness estimation:

1․ Make sure that you have the following .plan files in your deploy:

  • sdk.framework/data/oslm_v4_model_1_arm.plan
  • fsdk.framework/data/oslm_v4_model_2_arm.plan

2․ In the LCLunaConfiguration structure, set the useOfflineLiveness parameter to true:

LCLunaConfiguration.useOfflineLiveness = true