From 788e1fa0cc2bde2456c04422ca852d1f46b26465 Mon Sep 17 00:00:00 2001 From: "shaohua.zhang" Date: Mon, 31 Aug 2020 11:37:45 +0800 Subject: [PATCH] add a param for func: process_image --- ppocr/data/rec/img_tools.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ppocr/data/rec/img_tools.py b/ppocr/data/rec/img_tools.py index 8b497e6b..3c33cddb 100755 --- a/ppocr/data/rec/img_tools.py +++ b/ppocr/data/rec/img_tools.py @@ -339,6 +339,7 @@ def warp(img, ang): def process_image(img, + img_path, image_shape, label=None, char_ops=None, @@ -362,8 +363,8 @@ def process_image(img, logger.info( "Warning in ppocr/data/rec/img_tools.py: Wrong data type." "Excepted string with length between 1 and {}, but " - "got '{}'. Label is '{}'".format(max_text_length, - len(text), label)) + "got '{}'. The image path is '{}'. Label is '{}'".format(max_text_length, + len(text), img_path, label)) return None else: if loss_type == "ctc": -- GitLab