3DiVi Face SDK  3.21.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Groups
FacerecService

Classes

class  face_sdk.modules.facerec_service.FacerecService
 Interface object for creating other interface objects. More...
 

Functions

def face_sdk.modules.facerec_service.FacerecService.__init__
 
def face_sdk.modules.facerec_service.FacerecService.create_context
 
def face_sdk.modules.facerec_service.FacerecService.create_processing_block
 
def face_sdk.modules.facerec_service.FacerecService.create_service
 Initializes the facerec lib (can be called only once). More...
 
def face_sdk.modules.facerec_service.FacerecService.get_version
 Get version of face recognition library. More...
 
def face_sdk.modules.facerec_service.FacerecService.create_capturer
 Creates a Capturer object. More...
 
def face_sdk.modules.facerec_service.FacerecService.create_age_gender_estimator
 Creates a AgeGenderEstimator object. More...
 
def face_sdk.modules.facerec_service.FacerecService.create_emotions_estimator
 Creates a EmotionsEstimator object. More...
 
def face_sdk.modules.facerec_service.FacerecService.create_face_quality_estimator
 Creates a FaceQualityEstimator object. More...
 
def face_sdk.modules.facerec_service.FacerecService.create_quality_estimator
 Creates a QualityEstimator object. More...
 
def face_sdk.modules.facerec_service.FacerecService.create_depth_liveness_estimator
 Creates a DepthLivenessEstimator object. More...
 
def face_sdk.modules.facerec_service.FacerecService.create_ir_liveness_estimator
 Creates an IRLivenessEstimator object. More...
 
def face_sdk.modules.facerec_service.FacerecService.create_liveness_2d_estimator
 Liveness2DEstimator object. More...
 
def face_sdk.modules.facerec_service.FacerecService.create_face_attributes_estimator
 Creates an FaceAttributesEstimator object. More...
 
def face_sdk.modules.facerec_service.FacerecService.create_recognizer
 Creates a Recognizer object. More...
 
def face_sdk.modules.facerec_service.FacerecService.create_video_worker
 Creates a VideoWorker object. More...
 
def face_sdk.modules.facerec_service.FacerecService.load_raw_sample_without_image
 Loads a RawSample object that was saved with the RawSample.save_without_image member function. More...
 
def face_sdk.modules.facerec_service.FacerecService.load_raw_sample
 Loads a RawSample object that was saved with the RawSample.save member function. More...
 

Detailed Description

Function Documentation

def face_sdk.modules.facerec_service.FacerecService.create_age_gender_estimator (   self,
  ini_file 
)

Creates a AgeGenderEstimator object.

Thread-safe.

Parameters
[in]ini_fileName of the config file.
Returns
Created AgeGenderEstimator object.
def face_sdk.modules.facerec_service.FacerecService.create_capturer (   self,
  config 
)

Creates a Capturer object.

Type and features depend on the content of the configuration file. Thread-safe.

Parameters
[in]configName of the configuration file or configuration file with optionally overridden parameters.
Returns
Created Capturer object.
def face_sdk.modules.facerec_service.FacerecService.create_depth_liveness_estimator (   self,
  config 
)

Creates a DepthLivenessEstimator object.

Thread-safe.

Parameters
[in]ini_fileName of the configuration file or configuration file with optionally overridden parameters.
Returns
Created DepthLivenessEstimator object.
def face_sdk.modules.facerec_service.FacerecService.create_emotions_estimator (   self,
  ini_file 
)

Creates a EmotionsEstimator object.

Thread-safe.

Parameters
[in]ini_fileName of the config file.
Returns
Created EmotionsEstimator object.
def face_sdk.modules.facerec_service.FacerecService.create_face_attributes_estimator (   self,
  config 
)

Creates an FaceAttributesEstimator object.

Thread-safe.

Parameters
[in]ini_fileName of the configuration file.
Returns
Created FaceAttributesEstimator object.
def face_sdk.modules.facerec_service.FacerecService.create_face_quality_estimator (   self,
  ini_file 
)

Creates a FaceQualityEstimator object.

Thread-safe.

Parameters
[in]ini_fileName of the config file.
Returns
Created FaceQualityEstimator object.
def face_sdk.modules.facerec_service.FacerecService.create_ir_liveness_estimator (   self,
  config 
)

Creates an IRLivenessEstimator object.

Thread-safe.

Parameters
[in]ini_fileName of the configuration file or configuration file with optionally overridden parameters.
Returns
Created IRLivenessEstimator object.
def face_sdk.modules.facerec_service.FacerecService.create_liveness_2d_estimator (   self,
  config 
)

Liveness2DEstimator object.

Thread-safe.

Parameters
[in]ini_fileName of the configuration file or configuration file with optionally overridden parameters.
Returns
Created Liveness2DEstimator object.
def face_sdk.modules.facerec_service.FacerecService.create_quality_estimator (   self,
  ini_file 
)

Creates a QualityEstimator object.

Thread-safe.

Parameters
[in]ini_fileName of the config file.
Returns
Created QualityEstimator object.
def face_sdk.modules.facerec_service.FacerecService.create_recognizer (   self,
  recognizer_config 
)

Creates a Recognizer object.

Thread-safe.

Parameters
[in]recognizer_configName of the config file or recognizer configuration file with optionally overridden parameters.
[in]processingFlag to toggle the Recognizer.processing method in the created recognizer.
[in]matchingFlag to toggle the Recognizer.verify_match method in the created recognizer.
[in]processing_less_memory_consumptionFlag to toggle the Recognizer.processing member function optimizations that consume a lot of RAM when creating the recognizer (see the docs).
Returns
Created Recognizer object.
def face_sdk.modules.facerec_service.FacerecService.create_service (   cls,
  dll_path 
)

Initializes the facerec lib (can be called only once).

Parameters
[in]dll_pathAn absolute or a relative path to libfacerec.so on Linux or facerec.dll on Windows.
[in]facerec_conf_dirAn absolute or a relative path to the directory with config files (the 'face_sdk_3divi/conf/facerec/' directory).
[in]license_dirIf you need to specify the directory containing the license file, then it's an absolute or a relative path to this directory, otherwise, it's an empty string. In case of an empty string, a license file is searched first in the 'face_sdk_3divi/license/' directory. If it's not found, it's searched in the 'face_sdk_3divi/conf/facerec/' directory.
Returns
Created FacerecService object.
def face_sdk.modules.facerec_service.FacerecService.create_video_worker (   self,
  params 
)

Creates a VideoWorker object.

Thread-safe.
When VideoWorker is created with matching_thread=0 and processing_thread=0, then the standard Capturer license is used.
Depending on the settings, VideoWorker uses either the VideoClient license (face tracking on video streams) or the VideoClientExt license (face tracking, template creation and matching with the database).

Parameters
[in]paramsParameters of the VideoWorker constructor.
Returns
Created VideoWorker object.
def face_sdk.modules.facerec_service.FacerecService.get_version (   self,
  str 
)

Get version of face recognition library.

Thread-safe.

Returns
The name of the method.
def face_sdk.modules.facerec_service.FacerecService.load_raw_sample (   self,
  binary_stream 
)

Loads a RawSample object that was saved with the RawSample.save member function.

The format is platform-independent. Thread-safe.

Parameters
[in]binary_streamInput stream object. The file stream (std::ifstream) must be opened with the set flag std::ios_base::binary.
Returns
Loaded RawSample object.
def face_sdk.modules.facerec_service.FacerecService.load_raw_sample_without_image (   self,
  binary_stream 
)

Loads a RawSample object that was saved with the RawSample.save_without_image member function.

If you transformed the image in some way, you can set the parameters of coordinate space transformation: (x, y) -> ( (x + space_translation_x) * space_scale, (y + space_translation_y) * space_scale ) that will be applied to the information abour face position. Note that you must set the same transformation only once - either during serialization or during deserialization, otherwise transformation will be applied twice, which is wrong. The format is platform-independent. Thread-safe.

Parameters
[in]binary_streamInput stream object. The file stream (std::ifstream) must be opened with the set flag std::ios_base::binary.
[in]imageImage.
[in]space_translation_xCoordinate space transform parameter.
[in]space_translation_yCoordinate space transform parameter.
[in]space_scaleCoordinate space transform parameter.
Returns
Loaded RawSample object.