Skip to content

Commit 43e399c

Browse files
authored
Merge pull request #5518 from tensor-tang/ds2
fix typo
2 parents 41d0533 + 0f6a7a6 commit 43e399c

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

paddle/gserver/layers/MKLDNNBatchNormLayer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ void MKLDNNBatchNormLayer::reshape(
119119
int& bs, int& ic, int& ih, int& iw, int oc, int& oh, int& ow) {
120120
reshapeInput(bs, ih, iw);
121121
oh = ih;
122-
ow = ow;
122+
ow = iw;
123123
// ic_ and oc can not be changed
124124
CHECK_EQ(inputElemenCnt_ / bs / ih / iw, (size_t)ic)
125125
<< "Input channel can not be changed";

paddle/gserver/tests/test_MKLDNN.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -269,6 +269,7 @@ void testBatchNormLayer(const testBatchNormDesc& pm) {
269269
TEST(MKLDNNLayer, BatchNormLayer) {
270270
testBatchNormLayer({4, 10, 6, 6});
271271
testBatchNormLayer({16, 32, 16, 16});
272+
testBatchNormLayer({4, 16, 8, 10});
272273
}
273274

274275
struct testImageDesc {

0 commit comments

Comments
 (0)