【问题标题】:Extract filters and biases using caffe使用 caffe 提取过滤器和偏差
【发布时间】:2015-06-22 13:37:35
【问题描述】:

我想从我自己的 caffemodel 中提取过滤器和偏差,(无需可视化该功能)并且我想将它们保存到 .mat 文件中以供 MATLAB 使用。 我用matcaffe 来做这个问题:

我的解决方法:

addpath('/home/jensen810814/code/caffe/matlab/caffe/');
addpath('/home/jensen810814/code/caffe/examples/super_resolution/');
addpath('/home/jensen810814/code/caffe/examples/super_resolution/Model/');
caffe('init','deploy.prototxt','super_resolution_iter_1000.caffemodel');
caffe('forward',{});
weights = caffe('get_weights');
save('/home/jensen810814/code/caffe/examples/super_resolution/filter_data.mat','weights');

但是发生了一些错误:

Error using caffe
Expected 3 arguments, got 2
Error in model (line 4)
caffe('init','supe_resolution_train_test.prototxt','super_resolution_iter_1000.caffemodel');

我不知道如何解决这个问题。 谁能帮我?请和谢谢。

【问题讨论】:

    标签: matlab machine-learning neural-network deep-learning caffe


    【解决方案1】:

    您需要为'init' 提供一个附加参数作为阶段名称。
    我相信你的情况

     caffe('init',...
           'supe_resolution_train_test.prototxt',...
           'super_resolution_iter_1000.caffemodel',...
           'test');
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2021-01-31
      • 1970-01-01
      • 2016-11-12
      • 2015-11-20
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多