![]() |
Face SDK
1.10.0 Mozart release
Face Recognition Software Development Kit
|
Modules | |
Fir list | |
Fir list removed item | |
Fir matcher factory c interface | |
Match | |
Classes | |
struct | face_sdk__fir_matcher |
Fir matcher compares FIRs against each other. Matcher can perform 1:1 and 1:N matching. More... | |
struct | face_sdk__fir_matching_score_table |
Typedefs | |
typedef struct face_sdk__fir_matcher | face_sdk__fir_matcher_t |
Fir matcher compares FIRs against each other. Matcher can perform 1:1 and 1:N matching. More... | |
typedef struct face_sdk__fir_matching_score_table | face_sdk__fir_matching_score_table_t |
Enumerations | |
enum | face_sdk__architecture_type_t : uint32_t { COMMON = 0, NUMA } |
Matcher architecture type. | |
Functions | |
bool | face_sdk__fir_matcher__get_addr (const face_sdk__fir_matcher_t *fir_matcher, uint64_t *addr) |
Retrieves face_sdk__fir_matcher_t object address. More... | |
bool | face_sdk__fir_matcher__match (const face_sdk__fir_matcher_t *fir_matcher, const face_sdk__fir_t *fir_a, const face_sdk__fir_t *fir_b, float *value) |
Performs 1:1 matching operations for specified FIRs. More... | |
bool | face_sdk__fir_matcher__match_1 (const face_sdk__fir_matcher_t *fir_matcher, const face_sdk__fir_list_t *fir_list, uint32_t index, const face_sdk__fir_t *fir, float *value) |
Performs 1:1 matching operations for specified FIRs. {#matcher_1_1_with_idx}. More... | |
bool | face_sdk__fir_matcher__match_2 (const face_sdk__fir_matcher_t *fir_matcher, const face_sdk__fir_t *fir, const face_sdk__fir_list_t *fir_list, float **values, uint64_t *values_size) |
Performs 1:N matching operations for specified FIRs. More... | |
bool | face_sdk__fir_matcher__best_matches (const face_sdk__fir_matcher_t *fir_matcher, const face_sdk__fir_t *fir, const face_sdk__fir_list_t *fir_list, float threshold, uint32_t max_matches, face_sdk__match_set_t **match_set) |
Performs 1:N matching operations for specified FIRs and retrieves top matches results. More... | |
bool | face_sdk__fir_matcher__best_matches_1 (const face_sdk__fir_matcher_t *fir_matcher, const face_sdk__fir_set_t *fir_set, const face_sdk__fir_list_t *fir_list, float threshold, uint32_t max_matches, face_sdk__match_set_t **match_set) |
Performs 1:N, 2:N, 3:N and 4:N matching operations for specified FIRs and returns top matches results. Only matcher 104 supports this method. More... | |
bool | face_sdk__fir_matcher__get_builder_version (const face_sdk__fir_matcher_t *fir_matcher, uint32_t *value) |
Retrieves builder algorithm version which was selected for FIRs matcher initialization. More... | |
bool | face_sdk__fir_matcher__get_far_table_code (const face_sdk__fir_matcher_t *fir_matcher, uint8_t **table_code, uint64_t *table_code_size) |
Retrieves builder algorithm version which was selected for FIRs matcher initialization. More... | |
bool | face_sdk__is_architecture_available (face_sdk__architecture_type_t type, bool *value) |
Checks if architecture is available. More... | |
bool | face_sdk__make_fir_matcher (uint32_t builder_version, const uint8_t *table_code, uint64_t table_code_size, const face_sdk__license_t *license, const face_sdk__data_container_t *container, face_sdk__architecture_type_t type, face_sdk__fir_matcher_t **fir_matcher) |
Makes FIRs matcher with needed builder version, FAR table code, license object, data container and architecture type. More... | |
bool | face_sdk__make_fir_matcher_1 (uint32_t builder_version, const uint8_t *table_code, uint64_t table_code_size, const face_sdk__license_t *license, const face_sdk__data_container_t *container, face_sdk__fir_matcher_t **fir_matcher) |
Makes FIRs matcher with needed builder version, FAR table code, license object and data container. More... | |
bool | face_sdk__make_fir_matcher_2 (uint32_t builder_version, const uint8_t *table_code, uint64_t table_code_size, const face_sdk__license_t *license, face_sdk__fir_matcher_t **fir_matcher) |
Makes FIRs matcher with needed builder version, FAR table code and license object. Data container will be loaded from known paths (see Known paths). More... | |
bool | face_sdk__make_fir_matcher_3 (uint32_t builder_version, const uint8_t *table_code, uint64_t table_code_size, const face_sdk__data_container_t *container, face_sdk__fir_matcher_t **fir_matcher) |
Makes FIRs matcher with needed builder version, FAR table code and data container. License will be loaded from known paths (see Known paths). More... | |
bool | face_sdk__make_fir_matcher_4 (uint32_t builder_version, const uint8_t *table_code, uint64_t table_code_size, face_sdk__fir_matcher_t **fir_matcher) |
Makes FIRs matcher with needed builder version and FAR table code. License and data container will be loaded from known paths (see Known paths). More... | |
bool | face_sdk__score_to_percentage (float score, float *percentage) |
Converts score to percentage. {#fir_matcher_score_to_percentage}. More... | |
bool | face_sdk__percentage_to_score (float percentage, float *score) |
Converts score to percentage. {#fir_matcher_score_to_percentage}. More... | |
void | face_sdk__fir_matcher_free (face_sdk__fir_matcher_t *fir_matcher) |
Destroys fir matcher object. More... | |
bool | face_sdk__fir_matching_score_table__get_addr (const face_sdk__fir_matching_score_table_t *fir_matching_score_table, uint64_t *addr) |
Retrieves face_sdk__fir_matching_score_table_t object address. More... | |
bool | face_sdk__fir_matching_score_table__distance_to_score (const face_sdk__fir_matching_score_table_t *handle, double distance, uint32_t firs_num, float *score) |
bool | face_sdk__make_fir_matching_score_table (uint32_t builder_version, const uint8_t *table_code, uint64_t table_code_size, face_sdk__fir_matching_score_table_t **handle) |
bool | face_sdk__make_fir_matching_score_table1 (face_sdk__data_container_t *data_container, uint32_t builder_version, const uint8_t *table_code, uint64_t table_code_size, face_sdk__fir_matching_score_table_t **handle) |
Makes face_sdk__fir_matching_score_table with specified data_container for specified builder and table code. See Matching table codes. More... | |
bool | face_sdk__make_fir_matching_score_table2 (face_sdk__license_t *license, face_sdk__data_container_t *data_container, uint32_t builder_version, const uint8_t *table_code, uint64_t table_code_size, face_sdk__fir_matching_score_table_t **handle) |
Makes face_sdk__fir_matching_score_table with specified with specified license, data_container for specified builder and table code. See Matching table codes. More... | |
bool | face_sdk__make_fir_matching_score_table3 (face_sdk__license_t *license, uint32_t builder_version, const uint8_t *table_code, uint64_t table_code_size, face_sdk__fir_matching_score_table_t **handle) |
Makes face_sdk__fir_matching_score_table with specified with specified license for specified builder and table code. See Matching table codes. More... | |
bool | face_sdk__make_fir_matching_score_table_r (face_sdk__remote_license_t *license, face_sdk__data_container_t *data_container, uint32_t builder_version, const uint8_t *table_code, uint64_t table_code_size, face_sdk__fir_matching_score_table_t **handle) |
Makes face_sdk__fir_matching_score_table with specified with specified remote license, data_container for specified builder and table code. See Matching table codes. More... | |
bool | face_sdk__make_fir_matching_score_table_r1 (face_sdk__remote_license_t *license, uint32_t builder_version, const uint8_t *table_code, uint64_t table_code_size, face_sdk__fir_matching_score_table_t **handle) |
Makes face_sdk__fir_matching_score_table with specified with specified remote license for specified builder and table code. See Matching table codes. More... | |
void | face_sdk__fir_matching_score_table_free (face_sdk__fir_matching_score_table_t *handle) |
Destroys face_sdk__fir_matching_score_table. More... | |
Module compares FIRs and returns the result, which the coefficient equivalent -logFAR.
typedef struct face_sdk__fir_matcher face_sdk__fir_matcher_t |
Fir matcher compares FIRs against each other. Matcher can perform 1:1 and 1:N matching.
Use face_sdk__make_fir_matcher() or face_sdk__fir_matcher_factory__make_fir_matcher() function to instantiate of face_sdk__fir_matcher object.
The object translates L2 distance between FIRs to -logFAR score which is used in FaceSDK. Note, that for translation you should use different translation table for every version of Builder. See Matching table codes. Note, FaceSDK doesn't expose functions to calculate L2 distance, you can only calculate it yourself and validate against -logFAR score provided in the FaceSDK.
bool face_sdk__fir_matcher__best_matches | ( | const face_sdk__fir_matcher_t * | fir_matcher, |
const face_sdk__fir_t * | fir, | ||
const face_sdk__fir_list_t * | fir_list, | ||
float | threshold, | ||
uint32_t | max_matches, | ||
face_sdk__match_set_t ** | match_set | ||
) |
Performs 1:N matching operations for specified FIRs and retrieves top matches results.
[in] | fir_matcher | Fir matcher object |
[in] | fir | Fir to compare |
[in] | fir_list | Fir list object |
[in] | threshold | Comparison threshold |
[in] | max_matches | Maximum number of matches to store |
[out] | match_set | Set of matches |
bool face_sdk__fir_matcher__best_matches_1 | ( | const face_sdk__fir_matcher_t * | fir_matcher, |
const face_sdk__fir_set_t * | fir_set, | ||
const face_sdk__fir_list_t * | fir_list, | ||
float | threshold, | ||
uint32_t | max_matches, | ||
face_sdk__match_set_t ** | match_set | ||
) |
Performs 1:N, 2:N, 3:N and 4:N matching operations for specified FIRs and returns top matches results. Only matcher 104 supports this method.
[in] | fir_matcher | Fir matcher object |
[in] | fir_set | Set of firs to compare |
[in] | fir_list | Fir list object |
[in] | threshold | Comparison threshold |
[in] | max_matches | Maximum number of matches to store |
[out] | match_set | Set of matches |
bool face_sdk__fir_matcher__get_addr | ( | const face_sdk__fir_matcher_t * | fir_matcher, |
uint64_t * | addr | ||
) |
Retrieves face_sdk__fir_matcher_t object address.
[in] | fir_matcher | face_sdk__fir_matcher_t object |
[out] | addr | Object address |
bool face_sdk__fir_matcher__get_builder_version | ( | const face_sdk__fir_matcher_t * | fir_matcher, |
uint32_t * | value | ||
) |
Retrieves builder algorithm version which was selected for FIRs matcher initialization.
[in] | fir_matcher | Fir matcher object |
[out] | value | Builder version |
bool face_sdk__fir_matcher__get_far_table_code | ( | const face_sdk__fir_matcher_t * | fir_matcher, |
uint8_t ** | table_code, | ||
uint64_t * | table_code_size | ||
) |
Retrieves builder algorithm version which was selected for FIRs matcher initialization.
[in] | fir_matcher | Fir matcher object |
[out] | table_code | String containing far table code. See text_encoding |
[out] | table_code_size | Size in bytes of far_buffer string |
bool face_sdk__fir_matcher__match | ( | const face_sdk__fir_matcher_t * | fir_matcher, |
const face_sdk__fir_t * | fir_a, | ||
const face_sdk__fir_t * | fir_b, | ||
float * | value | ||
) |
Performs 1:1 matching operations for specified FIRs.
[in] | fir_matcher | Fir matcher object |
[in] | fir_a | Fir to compare |
[in] | fir_b | Fir to compare |
[out] | value | -log(FAR). See How to interpet matching results. |
bool face_sdk__fir_matcher__match_1 | ( | const face_sdk__fir_matcher_t * | fir_matcher, |
const face_sdk__fir_list_t * | fir_list, | ||
uint32_t | index, | ||
const face_sdk__fir_t * | fir, | ||
float * | value | ||
) |
Performs 1:1 matching operations for specified FIRs. {#matcher_1_1_with_idx}.
[in] | fir_matcher | Fir matcher object |
[in] | fir_list | Fir list object |
[in] | index | Fir index in fir_list |
[in] | fir | Fir to compare |
[out] | value | -log(FAR). See How to interpet matching results. |
bool face_sdk__fir_matcher__match_2 | ( | const face_sdk__fir_matcher_t * | fir_matcher, |
const face_sdk__fir_t * | fir, | ||
const face_sdk__fir_list_t * | fir_list, | ||
float ** | values, | ||
uint64_t * | values_size | ||
) |
Performs 1:N matching operations for specified FIRs.
[in] | fir_matcher | Fir matcher object |
[in] | fir | Fir to compare |
[in] | fir_list | Fir list object |
[out] | values | -log(FAR). Array of result values. Each element is the -log(FAR) value for each FIR comparison. See How to interpet matching results. |
[out] | values_size | Number of items stored in values |
void face_sdk__fir_matcher_free | ( | face_sdk__fir_matcher_t * | fir_matcher | ) |
Destroys fir matcher object.
[in] | fir_matcher | Fir matcher object |
bool face_sdk__fir_matching_score_table__distance_to_score | ( | const face_sdk__fir_matching_score_table_t * | handle, |
double | distance, | ||
uint32_t | firs_num, | ||
float * | score | ||
) |
Translates L2 distance between FIRs to -log(FAR) score.
[in] | hadle | face_sdk__fir_matching_score_table made by face_sdk__make_fir_matching_score_table* functions |
[in] | distance | distance between FIRs. |
[in] | firs_num | Warning! Use 1 by default. Do not use any other values unless you work with M:1 matching, use Builder 104 and have a clear understanding of these features. |
[out] | score | -log(FAR) score for specified distance |
bool face_sdk__fir_matching_score_table__get_addr | ( | const face_sdk__fir_matching_score_table_t * | fir_matching_score_table, |
uint64_t * | addr | ||
) |
Retrieves face_sdk__fir_matching_score_table_t object address.
[in] | fir_matching_score_table | face_sdk__fir_matching_score_table_t object |
[out] | addr | Object address |
void face_sdk__fir_matching_score_table_free | ( | face_sdk__fir_matching_score_table_t * | handle | ) |
Destroys face_sdk__fir_matching_score_table.
[in] | handle | face_sdk__fir_matching_score_table object |
bool face_sdk__is_architecture_available | ( | face_sdk__architecture_type_t | type, |
bool * | value | ||
) |
Checks if architecture is available.
[in] | type | Architecture type to check |
[out] | value | True if architecture is available, false if it is not available |
bool face_sdk__make_fir_matcher | ( | uint32_t | builder_version, |
const uint8_t * | table_code, | ||
uint64_t | table_code_size, | ||
const face_sdk__license_t * | license, | ||
const face_sdk__data_container_t * | container, | ||
face_sdk__architecture_type_t | type, | ||
face_sdk__fir_matcher_t ** | fir_matcher | ||
) |
Makes FIRs matcher with needed builder version, FAR table code, license object, data container and architecture type.
[in] | builder_version | Required version of the Builder algorithm. See Builder versions |
[in] | table_code | String containing far table code. See text_encoding, Matching table codes |
[in] | table_code_size | Size in bytes of far_buffer string |
[in] | license | License object |
[in] | container | The container with algorithm data. |
[in] | type | architecture type. Use face_sdk__is_architecture_available to check architecture availability. |
[out] | fir_matcher | Fir matcher object |
bool face_sdk__make_fir_matcher_1 | ( | uint32_t | builder_version, |
const uint8_t * | table_code, | ||
uint64_t | table_code_size, | ||
const face_sdk__license_t * | license, | ||
const face_sdk__data_container_t * | container, | ||
face_sdk__fir_matcher_t ** | fir_matcher | ||
) |
Makes FIRs matcher with needed builder version, FAR table code, license object and data container.
[in] | builder_version | Required version of the Builder algorithm. See Builder versions |
[in] | table_code | String containing far table code. See text_encoding, Matching table codes |
[in] | table_code_size | Size in bytes of far_buffer string |
[in] | license | License object |
[in] | container | The container with algorithm data. |
[out] | fir_matcher | Fir matcher object |
bool face_sdk__make_fir_matcher_2 | ( | uint32_t | builder_version, |
const uint8_t * | table_code, | ||
uint64_t | table_code_size, | ||
const face_sdk__license_t * | license, | ||
face_sdk__fir_matcher_t ** | fir_matcher | ||
) |
Makes FIRs matcher with needed builder version, FAR table code and license object. Data container will be loaded from known paths (see Known paths).
[in] | builder_version | Required version of the Builder algorithm. See Builder versions |
[in] | table_code | String containing far table code. See text_encoding, Matching table codes |
[in] | table_code_size | Size in bytes of far_buffer string |
[in] | license | License object |
[out] | fir_matcher | Fir matcher object |
bool face_sdk__make_fir_matcher_3 | ( | uint32_t | builder_version, |
const uint8_t * | table_code, | ||
uint64_t | table_code_size, | ||
const face_sdk__data_container_t * | container, | ||
face_sdk__fir_matcher_t ** | fir_matcher | ||
) |
Makes FIRs matcher with needed builder version, FAR table code and data container. License will be loaded from known paths (see Known paths).
[in] | builder_version | Required version of the Builder algorithm. See Builder versions |
[in] | table_code | String containing far table code. See text_encoding, Matching table codes |
[in] | table_code_size | Size in bytes of far_buffer string |
[in] | container | The container with algorithm data. |
[out] | fir_matcher | Fir matcher object |
bool face_sdk__make_fir_matcher_4 | ( | uint32_t | builder_version, |
const uint8_t * | table_code, | ||
uint64_t | table_code_size, | ||
face_sdk__fir_matcher_t ** | fir_matcher | ||
) |
Makes FIRs matcher with needed builder version and FAR table code. License and data container will be loaded from known paths (see Known paths).
[in] | builder_version | Required version of the Builder algorithm. See Builder versions |
[in] | table_code | String containing far table code. See text_encoding, Matching table codes |
[in] | table_code_size | Size in bytes of far_buffer string |
[out] | fir_matcher | Fir matcher object |
bool face_sdk__make_fir_matching_score_table1 | ( | face_sdk__data_container_t * | data_container, |
uint32_t | builder_version, | ||
const uint8_t * | table_code, | ||
uint64_t | table_code_size, | ||
face_sdk__fir_matching_score_table_t ** | handle | ||
) |
Makes face_sdk__fir_matching_score_table with specified data_container for specified builder and table code. See Matching table codes.
[in] | container | The container with algorithm data. |
[in] | builder_version | Required version of the Builder algorithm. See Builder versions |
[in] | table_code | String containing far table code. See text_encoding, Matching table codes |
[in] | table_code_size | Size in bytes of table_code string |
[out] | handle | face_sdk__fir_matching_score_table object |
bool face_sdk__make_fir_matching_score_table2 | ( | face_sdk__license_t * | license, |
face_sdk__data_container_t * | data_container, | ||
uint32_t | builder_version, | ||
const uint8_t * | table_code, | ||
uint64_t | table_code_size, | ||
face_sdk__fir_matching_score_table_t ** | handle | ||
) |
Makes face_sdk__fir_matching_score_table with specified with specified license, data_container for specified builder and table code. See Matching table codes.
[in] | license | License object |
[in] | container | The container with algorithm data. |
[in] | builder_version | Required version of the Builder algorithm. See Builder versions |
[in] | table_code | String containing far table code. See text_encoding, Matching table codes |
[in] | table_code_size | Size in bytes of table_code string |
[out] | handle | face_sdk__fir_matching_score_table object |
bool face_sdk__make_fir_matching_score_table3 | ( | face_sdk__license_t * | license, |
uint32_t | builder_version, | ||
const uint8_t * | table_code, | ||
uint64_t | table_code_size, | ||
face_sdk__fir_matching_score_table_t ** | handle | ||
) |
Makes face_sdk__fir_matching_score_table with specified with specified license for specified builder and table code. See Matching table codes.
[in] | license | License object |
[in] | builder_version | Required version of the Builder algorithm. See Builder versions |
[in] | table_code | String containing far table code. See text_encoding, Matching table codes |
[in] | table_code_size | Size in bytes of table_code string |
[out] | handle | face_sdk__fir_matching_score_table object |
bool face_sdk__make_fir_matching_score_table_r | ( | face_sdk__remote_license_t * | license, |
face_sdk__data_container_t * | data_container, | ||
uint32_t | builder_version, | ||
const uint8_t * | table_code, | ||
uint64_t | table_code_size, | ||
face_sdk__fir_matching_score_table_t ** | handle | ||
) |
Makes face_sdk__fir_matching_score_table with specified with specified remote license, data_container for specified builder and table code. See Matching table codes.
[in] | license | Remote license object |
[in] | container | The container with algorithm data. |
[in] | builder_version | Required version of the Builder algorithm. See Builder versions |
[in] | table_code | String containing far table code. See text_encoding, Matching table codes |
[in] | table_code_size | Size in bytes of table_code string |
[out] | handle | face_sdk__fir_matching_score_table object |
bool face_sdk__make_fir_matching_score_table_r1 | ( | face_sdk__remote_license_t * | license, |
uint32_t | builder_version, | ||
const uint8_t * | table_code, | ||
uint64_t | table_code_size, | ||
face_sdk__fir_matching_score_table_t ** | handle | ||
) |
Makes face_sdk__fir_matching_score_table with specified with specified remote license for specified builder and table code. See Matching table codes.
[in] | license | Remote license object |
[in] | builder_version | Required version of the Builder algorithm. See Builder versions |
[in] | table_code | String containing far table code. See text_encoding, Matching table codes |
[in] | table_code_size | Size in bytes of table_code string |
[out] | handle | face_sdk__fir_matching_score_table object |
bool face_sdk__percentage_to_score | ( | float | percentage, |
float * | score | ||
) |
Converts score to percentage. {#fir_matcher_score_to_percentage}.
[in] | percentage | Percentage to convert |
[out] | score | Converted percentage |
bool face_sdk__score_to_percentage | ( | float | score, |
float * | percentage | ||
) |
Converts score to percentage. {#fir_matcher_score_to_percentage}.
[in] | score | Score to convert |
[out] | percentage | Converted score |