From 9c59ae1cd53f0d8bf3232728226ab5dcbe48e1ef Mon Sep 17 00:00:00 2001 From: tink2123 Date: Mon, 17 Aug 2020 01:43:59 +0800 Subject: [PATCH] fix bug --- ppocr/modeling/architectures/rec_model.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ppocr/modeling/architectures/rec_model.py b/ppocr/modeling/architectures/rec_model.py index 91f778ce..fe2d4c16 100755 --- a/ppocr/modeling/architectures/rec_model.py +++ b/ppocr/modeling/architectures/rec_model.py @@ -58,7 +58,7 @@ class RecModel(object): self.loss_type = global_params['loss_type'] self.image_shape = global_params['image_shape'] self.max_text_length = global_params['max_text_length'] - if "num_heads" in params: + if "num_heads" in global_params: self.num_heads = global_params["num_heads"] else: self.num_heads = None -- GitLab