提交 65b8bb25 编写于 作者: L liaogang

Fix a bug

上级 1c9f6f7f
...@@ -179,25 +179,23 @@ TEST(Layer, BilinearInterpLayer) { ...@@ -179,25 +179,23 @@ TEST(Layer, BilinearInterpLayer) {
TestConfig config; TestConfig config;
config.layerConfig.set_type("bilinear_interp"); config.layerConfig.set_type("bilinear_interp");
config.biasSize = 0; config.biasSize = 0;
config.inputDefs.push_back({INPUT_DATA, "layer_0", 4096, 0}); config.inputDefs.push_back({INPUT_DATA, "layer_0", 4096, 0});
for (auto useGpu : {false, true}) { LayerInputConfig* input = config.layerConfig.add_inputs();
for (auto out_size : {32, 64}) { BilinearInterpConfig* bilinear = input->mutable_bilinear_interp_conf();
LOG(INFO) << " out_size_x=" << out_size bilinear->set_img_size_x(32);
<< " out_size_y=" << out_size; bilinear->set_img_size_y(32);
LayerInputConfig* input bilinear->set_num_channels(4);
= config.layerConfig.add_inputs();
BilinearInterpConfig* bilinear bilinear->set_out_size_x(32);
= input->mutable_bilinear_interp_conf(); bilinear->set_out_size_y(32);
bilinear->set_img_size_x(32); testLayerGrad(config, "bilinear_interp", 10, false, false);
bilinear->set_img_size_y(32); testLayerGrad(config, "bilinear_interp", 10, false, true);
bilinear->set_num_channels(4);
bilinear->set_out_size_x(out_size); bilinear->set_out_size_x(64);
bilinear->set_out_size_y(out_size); bilinear->set_out_size_y(64);
testLayerGrad(config, "bilinear_interp", 10, false, useGpu); testLayerGrad(config, "bilinear_interp", 10, false, false);
} testLayerGrad(config, "bilinear_interp", 10, false, true);
}
} }
TEST(Layer, concat) { TEST(Layer, concat) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册