OpenCV 4.12.0
开源计算机视觉
加载中...
搜索中...
无匹配项

Layer 工厂允许创建已注册层的实例。 更多...

#include <opencv2/dnn/layer.hpp>

cv::dnn::LayerFactory 的协作图

公共类型

typedef Ptr< Layer >(*) 构造函数(LayerParams &params)
 每个 Layer 类必须为此工厂提供此函数。
 

静态公共成员函数

static Ptr< LayercreateLayerInstance (const String &type, LayerParams &params)
 创建已注册层的实例。
 
static bool isLayerRegistered (const std::string &type)
 检查层是否已注册。
 
static void registerLayer (const String &type, Constructor constructor)
 使用类型名称 type 和指定的 constructor 注册层类。线程安全。
 
static void unregisterLayer (const String &type)
 取消注册具有指定类型名称的已注册层。线程安全。
 

详细描述

Layer 工厂允许创建已注册层的实例。

成员 Typedef 文档

◆ 构造函数

Ptr< Layer >(*) cv::dnn::LayerFactory::Constructor(LayerParams &params)

每个 Layer 类必须为此工厂提供此函数。

成员函数文档

◆ createLayerInstance()

static Ptr< Layer > cv::dnn::LayerFactory::createLayerInstance ( const String & type,
LayerParams & params )
static

创建已注册层的实例。

参数
type正在创建的层的类型名称。
params将用于层初始化的参数。
注意
线程安全。

◆ isLayerRegistered()

static bool cv::dnn::LayerFactory::isLayerRegistered ( const std::string & type)
static

检查层是否已注册。

◆ registerLayer()

static void cv::dnn::LayerFactory::registerLayer ( const String & type,
构造函数 constructor )
static

使用类型名称 type 和指定的 constructor 注册层类。线程安全。

◆ unregisterLayer()

static void cv::dnn::LayerFactory::unregisterLayer ( const String & type)
static

取消注册具有指定类型名称的已注册层。线程安全。


此类文档由以下文件生成