From 0f5fb9bd351b44fedede30094d25040f6ee4b3a9 Mon Sep 17 00:00:00 2001 From: WenmuZhou Date: Tue, 12 Apr 2022 19:39:50 +0800 Subject: [PATCH] rm to tensor --- ppocr/modeling/heads/det_fce_head.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ppocr/modeling/heads/det_fce_head.py b/ppocr/modeling/heads/det_fce_head.py index 5d5e9205..9503989f 100644 --- a/ppocr/modeling/heads/det_fce_head.py +++ b/ppocr/modeling/heads/det_fce_head.py @@ -63,7 +63,7 @@ class FCEHead(nn.Layer): weight_attr=ParamAttr( name='cls_weights', initializer=Normal( - mean=paddle.to_tensor(0.), std=paddle.to_tensor(0.01))), + mean=0., std=0.01)), bias_attr=True) self.out_conv_reg = nn.Conv2D( in_channels=self.in_channels, @@ -75,7 +75,7 @@ class FCEHead(nn.Layer): weight_attr=ParamAttr( name='reg_weights', initializer=Normal( - mean=paddle.to_tensor(0.), std=paddle.to_tensor(0.01))), + mean=0., std=0.01)), bias_attr=True) def forward(self, feats, targets=None): -- GitLab