Added MVN layer. Renamed layer test data.

pull/265/head
Vitaliy Lyudvichenko 10 years ago
parent f8119ea058
commit df5eec6844
  1. 21
      modules/dnn/test/test_layers.cpp
  2. 0
      modules/dnn/testdata/dnn/layers/layer_convolution.prototxt
  3. 0
      modules/dnn/testdata/dnn/layers/layer_deconvolution.prototxt
  4. 0
      modules/dnn/testdata/dnn/layers/layer_inner_product.prototxt
  5. 0
      modules/dnn/testdata/dnn/layers/layer_lrn_channels.prototxt
  6. 0
      modules/dnn/testdata/dnn/layers/layer_lrn_spatial.prototxt
  7. 21
      modules/dnn/testdata/dnn/layers/layer_mvn.prototxt
  8. 0
      modules/dnn/testdata/dnn/layers/layer_pooling_ave.prototxt
  9. 0
      modules/dnn/testdata/dnn/layers/layer_pooling_max.prototxt
  10. 0
      modules/dnn/testdata/dnn/layers/layer_softmax.prototxt
  11. BIN
      modules/dnn/testdata/dnn/layers/lrn_channels.prototxt.caffe.npy
  12. BIN
      modules/dnn/testdata/dnn/layers/lrn_spatial.prototxt.caffe.npy
  13. 2
      modules/dnn/testdata/dnn/layers/run.py
  14. BIN
      modules/dnn/testdata/dnn/layers/softmax.prototxt.caffe.npy

@ -54,42 +54,47 @@ static void testLayer(String basename, bool useCaffeModel = false)
TEST(Layer_Test_Softmax, Accuracy)
{
testLayer("softmax");
testLayer("layer_softmax");
}
TEST(Layer_Test_LRN_spatial, Accuracy)
{
testLayer("lrn_spatial");
testLayer("layer_lrn_spatial");
}
TEST(Layer_Test_LRN_channels, Accuracy)
{
testLayer("lrn_channels");
testLayer("layer_lrn_channels");
}
TEST(Layer_Test_Convolution, Accuracy)
{
testLayer("convolution", true);
testLayer("layer_convolution", true);
}
TEST(Layer_Test_InnerProduct, Accuracy)
{
testLayer("inner_product", true);
testLayer("layer_inner_product", true);
}
TEST(Layer_Test_Pooling_max, Accuracy)
{
testLayer("pooling_max");
testLayer("layer_pooling_max");
}
TEST(Layer_Test_Pooling_ave, Accuracy)
{
testLayer("pooling_ave");
testLayer("layer_pooling_ave");
}
TEST(Layer_Test_DeConvolution, Accuracy)
{
testLayer("deconvolution", true);
testLayer("layer_deconvolution", true);
}
TEST(Layer_Test_MVN, Accuracy)
{
testLayer("layer_mvn");
}
TEST(Layer_Test_Reshape, squeeze)

@ -0,0 +1,21 @@
name: "test_MVN_channels"
input: "input"
input_dim: 2
input_dim: 6
input_dim: 75
input_dim: 113
layer {
type: "MVN"
mvn_param {
eps: 0.1
across_channels: false
normalize_variance: true
}
name: "output"
bottom: "input"
top: "output"
}

@ -30,7 +30,7 @@ def get_cafe_output(inp_blob, proto_name, caffemodel_name):
return out_blob
if __name__ == '__main__':
proto_filenames = glob.glob("*.prototxt")
proto_filenames = glob.glob("layer_*.prototxt")
inp_blob = np.load('blob.npy')
print inp_blob.shape

Loading…
Cancel
Save