fix momentum bug

This commit is contained in:
xiaoyisd 2020-11-18 14:39:04 +08:00
parent 27f274f566
commit 490e86be27
1 changed files with 1 additions and 1 deletions

View File

@ -842,7 +842,7 @@ class Conv2dBnWithoutFoldQuant(Cell):
channel_axis=channel_axis,
num_channels=out_channels,
quant_dtype=quant_dtype)
self.batchnorm = BatchNorm2d(out_channels, eps=eps, momentum=1-momentum)
self.batchnorm = BatchNorm2d(out_channels, eps=eps, momentum=momentum)
def construct(self, x):
weight = self.fake_quant_weight(self.weight)