提交 baae8447 编写于 作者: W wanghaoshuang

Fix SwitchOrderLayer grad bugs by reshape output.grad

上级 a6c53fc2
......@@ -81,6 +81,7 @@ void SwitchOrderLayer::forward(PassType passType) {
resetOutput(outDims_[0], outDims_[1] * outDims_[2] * outDims_[3]);
if (heightAxis_.size() > 0) {
getOutputValue()->reshape(reshapeHeight_, reshapeWidth_);
getOutputGrad()->reshape(reshapeHeight_, reshapeWidth_);
}
// switch NCHW to NHWC
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册