caffe
caffe copied to clipboard
support "round_mode" in pooling layer with MKLDNN engine
Hi all,
I have a model which has a pooling layer with floor round mode. but i found that intel caffe do not support pooling parameter "round_mode" in pooling layer. it default use ceil round mode.
when i try to change the code in caffe/src/caffe/layers/mkl_pooling_layer.cpp
i get the follow error
how can we use model with floor round mode pooling layer in intel caffe with MKLDNN or MKL2017 engine?
pls don't touch mkl_xxx layer, it's deprecated.
hi ftian1, thanks for your reply.
i try mkdnn firstly, but it have a more strange result. After i init network, the first infer pass is correct, but the following infer pass no matter what i input, it output the same result as the first infer pass.
when i debug this question i remove the round mode, so the question seem has no relatation with the round mode of pooling layer.
with the same code and the same model, when i use caffe or mkl2017 engine, it work fine. but when i use mkldnn engine it has strange result.
p.s. the model i use is densenet121 and batch size is 1.
As for the pooling layer round-mode question, i had try to modify caffe/src/caffe/layers/mkldnn_pooling_layer.cpp
i work correct in the first infer pass. but no matter what i input, the follow infer pass have the same result as the first pass.