From 0452f27cba16b6e152ec3a39b581e5588ec74d2b Mon Sep 17 00:00:00 2001 From: Zhang Zheng <32410583+ZzSean@users.noreply.github.com> Date: Sat, 16 Oct 2021 12:48:38 +0800 Subject: [PATCH] fix the initializer of resnet unit op (#36483) * fix the initializer of resnet unit op * fix the initializer of resnet unit op --- python/paddle/incubate/operators/resnet_unit.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/python/paddle/incubate/operators/resnet_unit.py b/python/paddle/incubate/operators/resnet_unit.py index cba1d4863c..f2f391bdca 100644 --- a/python/paddle/incubate/operators/resnet_unit.py +++ b/python/paddle/incubate/operators/resnet_unit.py @@ -187,9 +187,7 @@ class ResNetUnit(Layer): filter_z_shape = [num_filters, filter_size, filter_size, num_channels_z] self.filter_x = self.create_parameter( - shape=filter_x_shape, - attr=filter_x_attr, - default_initializer=_get_default_param_initializer(num_channels_x)) + shape=filter_x_shape, attr=filter_x_attr, default_initializer=None) self.scale_x = self.create_parameter( shape=bn_param_shape, attr=scale_x_attr, @@ -220,8 +218,7 @@ class ResNetUnit(Layer): self.filter_z = self.create_parameter( shape=filter_z_shape, attr=filter_z_attr, - default_initializer=_get_default_param_initializer( - num_channels_z)) + default_initializer=None) self.scale_z = self.create_parameter( shape=bn_param_shape, attr=scale_z_attr, -- GitLab