1

I fed the network defined below with a hdf5 files

    name: "match_layers"
    layers {
      name: "data"
      type: HDF5_DATA
      top: "feat1"
      top: "feat2"
      hdf5_data_param {
        source: "vgg16_train_test_pair.h5list"
        batch_size: 50
      }
    }

    layers {
      name: "concat"
      bottom: "feat1"
      bottom: "feat2"
      top: "union"
      type: CONCAT
        concat_param{
        concat_dim: 1
      }
    }  

    layers {
      bottom: "union"
      top: "fc1"
      name: "fc1"
      type: INNER_PRODUCT
      inner_product_param {
      num_output: 1024
    }

    .......

What inside the vgg16_train_test_pair.h5list is:

     vgg16_train_test_pair.h5

and the hdf5 files is already exits, I want to get the output of fc1 using matlab interface, I tried:

     net = caffe.Net(model, weights, 'test');
     a = net.forward();
     fc1 = net.blobs('fc1').get_data();

but it didn't work, anyone can help me fix it?

medicine_man
  • 321
  • 3
  • 15
Fangxin
  • 781
  • 1
  • 7
  • 13
  • 1
    Can you elaborate on what error you got? Also, should the code be `net.blobs('fc1').get_data()` ? – Prophecies Oct 12 '16 at 14:28
  • @Prophecies I fix the wrong in `net.blobs('fc1').get_data()`. When it run to `net.forward()`, it reported a wrong that *not enough argument*, because my input is predefined in prototxt file with **vgg16_train_test_pair.h5list**, so I don't know how to give input to `net.forward()`. – Fangxin Oct 13 '16 at 05:57

0 Answers0