Skip to content

dnn_readNet1

Deep neural networksfunctionOpenCV 5.0.0
import { dnn_readNet1 } from '@banou/opencv-wasm'

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

ARGUMENTSframework, bufferModel, bufferConfig, engine
FUNCTIONdnn_readNet1
RETURN TYPEdnn_Net
Call structure. A void return can still write to destination arguments. The parameter descriptions define inputs, outputs and ownership.

Read deep learning network represented in one of the supported formats. This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

dnn_readNet1(framework: EmbindString, bufferModel: ucharVector, bufferConfig: ucharVector, engine: number): dnn_Net;
3 available overloads
dnn_readNet1(framework: EmbindString, bufferModel: ucharVector): dnn_Net;
dnn_readNet1(framework: EmbindString, bufferModel: ucharVector, bufferConfig: ucharVector): dnn_Net;
dnn_readNet1(framework: EmbindString, bufferModel: ucharVector, bufferConfig: ucharVector, engine: number): dnn_Net;
framework

Name of origin framework.

bufferModel

A buffer with a content of binary file with weights

bufferConfig

A buffer with a content of text file contains network configuration.

engine

select DNN engine to be used. With auto selection the new engine is used first and falls back to classic. Please pay attention that the new DNN does not support non-CPU back-ends for now. Use ENGINE_CLASSIC if you want to use other back-ends.

Returns

Net object.

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.