Merge pull request #11649 from rockzhan:dnn_dw_prelu
authorrockzhan <rock8zhan@gmail.com>
Thu, 7 Jun 2018 13:45:54 +0000 (21:45 +0800)
committerAlexander Alekhin <alexander.a.alekhin@gmail.com>
Thu, 7 Jun 2018 13:45:54 +0000 (13:45 +0000)
commit1187a7fa345b98b49d366fb6f8857486168f636f
treeef325154285d916d438f6977ab3537c2c0ac0797
parent7175f257b513fd1e45d108dda2d1f56575d839e8
Merge pull request #11649 from rockzhan:dnn_dw_prelu

dnn: Fix output mismatch when forward dnn model contain [depthwise conv(group=1) + bn + prelu]  (#11649)

* this can make sure [depthwise conv(group=1) + bn + prelu] output not shift

* add TEST to show the output mismatch in [DWconv+Prelu]

* fix typo

* change loading image to init cvMat directly

* build runtime model, without loading external model

* remove whitespace

* change way to create a cvmat

* add bias_term, add target output

* fix [dwconv + prelu] value mismatch when no optimizations

* fix Test error when change output channels

* add parametric test

* change num_output to group value

* change conv code and change test back
modules/dnn/src/layers/convolution_layer.cpp
modules/dnn/src/layers/layers_common.simd.hpp
modules/dnn/test/test_layers.cpp