Table of Contents

Method Create

Namespace
OpenCvSharp
Assembly
OpenCvSharp.dll

Create(string, string, Backend, Target)

Creates an instance of this class with given parameters.

public static FaceRecognizerSF Create(string model, string config, Backend backendId = Backend.DEFAULT, Target targetId = Target.CPU)

Parameters

model string

the path of the onnx model used for face recognition

config string

the path to the config file for compatibility, which is not requested for ONNX models

backendId Backend

the id of backend

targetId Target

the id of target device

Returns

FaceRecognizerSF

Create(string, byte[], byte[], Backend, Target)

Creates an instance of this class from a buffer containing the model weights and configuration.

public static FaceRecognizerSF Create(string framework, byte[] bufferModel, byte[] bufferConfig, Backend backendId = Backend.DEFAULT, Target targetId = Target.CPU)

Parameters

framework string

Name of the framework (ONNX, etc.)

bufferModel byte[]

A buffer containing the binary model weights.

bufferConfig byte[]

A buffer containing the network configuration.

backendId Backend

the id of backend

targetId Target

the id of target device

Returns

FaceRecognizerSF