无法使用DummyData图层加载Caffe模型 [英] Can't load Caffe model with DummyData layer

查看:85
本文介绍了无法使用DummyData图层加载Caffe模型的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我尝试使用OpenCV 3.4.3加载caffe模型时,出现错误

when I try to load a caffe model with OpenCV 3.4.3, I get the error

what(): OpenCV(3.4.3) /home/schneider/libs/opencv-3.4.3/modules/dnn/src/dnn.cpp:412: error: (-2:Unspecified error) Can't create layer "DummyData1" of type "DummyData" in function 'getLayerInstance'*

prototxt文件中的图层如下所示:

The layer in the prototxt file looks like this:

layer {
name: "DummyData1"
type: "DummyData"
top: "DummyData1"
dummy_data_param {
    shape {
    dim: 1
    dim: 32
    dim: 125
    dim: 100
          }
   }
} 

似乎OpenCV中缺少该层.Caffe层在Caffe网页上已在此处进行了描述,但是我不确定如何在OpenCV中实现这一层.它已经在某个地方实现了吗?我该如何解决这个问题?

It appears that the layer is missing in OpenCV. The caffe layer is described here on the Caffe webpage, but I am not sure how to implement this layer in OpenCV. Has it already been implemented somewhere? How can I solve this problem?

推荐答案

如果您可以更改 .protptxxt 文件,则可以将这些行替换为以下行.尝试一下gys

if you able to change a .protptxxt the file you can replace these line to the following ones. Try this gys

layer {
    type: "Input"
    name: "DummyData1"
    top: "DummyData1"
    input_param {
     shape {
     dim: 1
     dim: 32
     dim: 125
     dim: 100
          }
        }
     }

input: "DummyData1"
input_dim: 1
input_dim: 32
input_dim: 125
input_dim: 100

这篇关于无法使用DummyData图层加载Caffe模型的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆