- name: "LeNet"
- layer {
- name: "input"
- type: "Input"
- top: "data"
- input_param {
- shape {
- dim: 1
- dim: 3
- dim: 32
- dim: 32
- }
- }
- }
- layer {
- name: "conv1"
- type: "Convolution"
- bottom: "data"
- top: "conv1"
- param {
- lr_mult: 1
- }
- param {
- lr_mult: 2
- }
- convolution_param {
- num_output: 20
- kernel_size: 5
- stride: 1
- weight_filler {
- type: "xavier"
- }
- bias_filler {
- type: "constant"
- }
- }
- }
复制代码
执行rknn.load_caffe(model='./lenet_train_test.prototxt', proto='caffe', blobs='./lenet_iter_10000.caffemodel')- E Catch exception when loading caffe model: /home/lwd/bak/model/lenet_train_test.prototxt!
- E Traceback (most recent call last):
- E File "rknn/api/rknn_base.py", line 404, in rknn.api.rknn_base.RKNNBase.load_caffe
- E File "rknn/base/RKNNlib/converter/caffeloader.py", line 1042, in rknn.base.RKNNlib.converter.caffeloader.CaffeLoader.load_blobs
- E File "rknn/base/RKNNlib/converter/caffeloader.py", line 935, in rknn.base.RKNNlib.converter.caffeloader.CaffeLoader.parse_blobs
- E File "rknn/base/RKNNlib/converter/caffeloader.py", line 358, in rknn.base.RKNNlib.converter.caffeloader.proc_blobs_convolution
- E File "/home/lwd/.local/lib/python3.5/site-packages/numpy/core/fromnumeric.py", line 292, in reshape
- E return _wrapfunc(a, 'reshape', newshape, order=order)
- E File "/home/lwd/.local/lib/python3.5/site-packages/numpy/core/fromnumeric.py", line 56, in _wrapfunc
- E return getattr(obj, method)(*args, **kwds)
- E ValueError: cannot reshape array of size 500 into shape (20,3,5,5)
复制代码
这个500是哪里出来的?caffemodel转rknn有教程吗?给个链接,感谢!欢迎光临 Toybrick (https://t.rock-chips.com/) | Powered by Discuz! X3.3 |