Configuration options¶
The configuration options are provided when the engine is initialized and they are case-sensitive.
Sample (default) config:
{
"debug_level": "info",
"debug_write_input_image_enabled": false,
"debug_internal_data_path": ".",
"gpu_ctrl_memory_enabled": true,
"num_threads": -1,
"max_latency": -1,
"max_batchsize": -1,
"asm_enabled": true,
"intrin_enabled": true,
"cuda_activation": "auto",
"backend": "onnx",
"detect_target_size": 640,
"detect_size_threshold": 16,
"detect_score_threshold": 0.5,
"detect_iou_threshold": 0.4,
"detect_topk": 1000,
"avantgarde_score_threshold": 0.5,
"liveness_genuine_threshold": 0.85,
"liveness_disputed_threshold": 0.60,
"deepfake_genuine_threshold": 0.4,
"disguise_genuine_threshold": 0.4,
"inject_similarity_threshold": 0.35,
"inject_genuine_threshold": 0.90,
"inject_smartpass_enabled": true
}
assets_folder¶
Path to the folder containing the configuration files and deep learning models. |
|
type |
string |
pattern |
folder path |
default |
“” |
debug_level¶
Defines the debug level to output on the console. You should use “verbose” for diagnostic, “info” in development stage and “warn” in production. |
|
type |
string |
pattern |
“verbose” | “info” | “warn” | “error” | “fatal” |
default |
“info” |
debug_write_input_image_enabled¶
Whether to write the transformed input image to the disk. |
|
type |
bool |
pattern |
true | false |
default |
False |
debug_internal_data_path¶
Path to the folder where to write the transformed input image. |
|
type |
string |
pattern |
folder path |
default |
“” |
license_token_file¶
Path to the file containing the license token. |
|
type |
string |
pattern |
file path |
default |
“” |
license_token_data¶
Base64 string representing the license token. |
|
type |
string |
pattern |
base64 |
default |
“” |
num_threads¶
Defines the maximum number of threads to use. You should not change this value unless you know what you’re doing. |
|
type |
int |
pattern |
[-1, +inf[ |
default |
-1 |
gpu_ctrl_memory_enabled¶
Whether to control the GPU memory usage. This option applies to ONNX RT only and doesn’t apply to TensorRT. |
|
type |
bool |
pattern |
true | false |
default |
True |
cuda_activation¶
Defines the CUDA activation mode. |
|
type |
string |
pattern |
“auto” | “on” | “off” |
default |
“auto” |
backend¶
Defines the inference engine to use. |
|
type |
string |
pattern |
“onnx” | “trt” | “vino” |
default |
“onnx” |
max_latency¶
The parallel processing method could introduce delay/latency in the delivery callback on low-end CPUs. |
|
type |
int |
pattern |
[0, +inf[ |
default |
-1 |
max_batchsize¶
Defines the maximum batch size to use for the inference. |
|
type |
int |
pattern |
[-1, +inf[ |
default |
-1 |
asm_enabled¶
Whether to enable assembler code to use SIMD acceleration (SSE, AVX, NEON). |
|
type |
bool |
pattern |
true | false |
default |
true |
intrin_enabled¶
Whether to enable intrinsic code to use SIMD acceleration (SSE, AVX, NEON). |
|
type |
bool |
pattern |
true | false |
default |
true |
detect_target_size¶
The face detection modules is a fully convolution neural network which means it accepts any image size as input. |
|
type |
int |
pattern |
[-1, +inf[ |
default |
640 |
detect_size_threshold¶
The face detector may produce false positives on objects looking like very small faces. |
|
type |
int |
pattern |
[-1, +inf[ |
default |
16 |
detect_score_threshold¶
Any face detection score (percentage) lower than this threshold will be discarded and and tagged as false-positive. |
|
type |
float |
pattern |
[0, 1] |
default |
0.5 |
detect_iou_threshold¶
Defines the maximum IoU (Intersection Over Union) to be used by the NMS (Non Maximal Suppression) module to deal with the overlapping face detection boxes. |
|
type |
float |
pattern |
[0, 1] |
default |
0.4 |
detect_topk¶
The faces in the image are sorted from the largest to the smallest. |
|
type |
int |
pattern |
]0, +inf[ |
default |
1000 |
avantgarde_score_threshold¶
Avant-garde is the first module to be invoked to check whether we need to perform liveness detection or not. |
|
type |
float |
pattern |
[0, 1] |
default |
0.5 |
liveness_genuine_threshold¶
Threshold for genuine faces. |
|
type |
float |
pattern |
[0, 1] |
default |
0.85 |
liveness_disputed_threshold¶
Any non-genuine face with a score higher than or equal to this threshold will be tagged as disputed. |
|
type |
float |
pattern |
[0, 1] |
default |
0.6 |
deepfake_genuine_threshold¶
Threshold for deepfake faces. Any face with deepfake score higher than or equal to this threshold will be tagged as a deepfake. |
|
type |
float |
pattern |
[0, 1] |
default |
0.5 |
disguise_genuine_threshold¶
Any face with disguise score higher than or equal to this threshold will be tagged as disguise (identity concealed). |
|
type |
float |
pattern |
[0, 1] |
default |
0.5 |
inject_similarity_threshold¶
The stream injection module requires a stereo image. |
|
type |
float |
pattern |
[-1, 1] |
default |
0.35 |
inject_genuine_threshold¶
Any stereo image with injection score lower than this threshold will be tagged as a “injected”. |
|
type |
float |
pattern |
[0, 1] |
default |
0.9 |
inject_smartpass_enabled¶
Whether to enabled smart-pass module. |
|
type |
bool |
pattern |
true | false |
default |
True |