Merge pull request #16063 from YashasSamaga:cuda4dnn-shortcut-unequal
authorYashas Samaga B L <yashas_2010@yahoo.com>
Thu, 16 Jan 2020 18:54:00 +0000 (00:24 +0530)
committerAlexander Alekhin <alexander.a.alekhin@gmail.com>
Thu, 16 Jan 2020 18:54:00 +0000 (21:54 +0300)
commitd85e67d3ecf425f0ffbf643e7fa8323e289bfff0
tree7981d0c7c4538ef06bc673d79d8e7b39af9207cb
parentc30af724effc4100acd0d32ff35266ca61c6c172
Merge pull request #16063 from YashasSamaga:cuda4dnn-shortcut-unequal

support eltwise sum with different number of input channels in CUDA backend

* add shortcut primitive

* add offsets in shortcut kernel

* skip tests involving more than two inputs

* remove redundant modulus operation

* support multiple inputs

* remove whole file indentation

* skip acc in0 trunc test if weighted

* use shortcut iff channels are unequal
modules/dnn/src/cuda/shortcut.cu [new file with mode: 0644]
modules/dnn/src/cuda4dnn/kernels/shortcut.hpp [new file with mode: 0644]
modules/dnn/src/cuda4dnn/primitives/shortcut.hpp [new file with mode: 0644]
modules/dnn/src/layers/eltwise_layer.cpp
modules/dnn/test/test_darknet_importer.cpp
modules/dnn/test/test_layers.cpp