Skip to content

FaceRecognizerSF_create

objdetectfunctionOpenCV 5.0.0
import { FaceRecognizerSF_create } from '@banou/opencv-wasm'

Use after await initOpenCV(). See the initialization and named imports guide.

ARGUMENTSmodel, config, backend_id, target_id
FUNCTIONFaceRecognizerSF_create
RETURN TYPEFaceRecognizerSF | null
Call structure. A void return can still write to destination arguments. The parameter descriptions define inputs, outputs and ownership.

Creates an instance of this class with given parameters

FaceRecognizerSF_create(model: EmbindString, config: EmbindString, backend_id: number, target_id: number): FaceRecognizerSF | null;
3 available overloads
FaceRecognizerSF_create(model: EmbindString, config: EmbindString): FaceRecognizerSF | null;
FaceRecognizerSF_create(model: EmbindString, config: EmbindString, backend_id: number): FaceRecognizerSF | null;
FaceRecognizerSF_create(model: EmbindString, config: EmbindString, backend_id: number, target_id: number): FaceRecognizerSF | null;
model

the path of the onnx model used for face recognition

config

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

backend_id

the id of backend

target_id

the id of target device

Returns

The FaceRecognizerSF | null result.

These signatures describe this package. Upstream documentation can mention optional backends that are absent from this build. Check runtime compatibility before choosing a backend or file format.