PaddleOCR icon indicating copy to clipboard operation
PaddleOCR copied to clipboard

StructSystem的rec结果在某些case图片上与TextSystem的rec结果不一致;StructSystem的region可能重复

Open hermitgreen opened this issue 2 years ago • 5 comments

  • 系统环境/System Environment:

CentOS 7.9 Python 3.8.11

  • 版本号/Version:

Paddle 2.2.2: PaddleOCR 2.6.0: 问题相关组件/Related components:PP Structure v2

  • 运行指令/Command Code: 我的用例代码:
from paddleocr import PPStructure, PaddleOCR, draw_structure_result
import cv2

image = cv2.imread('./output/DeepImpact-pptx_raw_1.png')
pps = PPStructure(lang='ch', use_gpu=True)
pocr = PaddleOCR(lang='ch', use_gpu=True)

res = pocr.ocr(image)
for i in res:
    print(i[1][0])

res = pps(image)
for i in res:
    for j in i['res']:
        print(j['text'])
    print('')

image = draw_structure_result(image, res, '../fonts/simfang.ttf')
cv2.imwrite('./output/example.png', image)

第一部分输出: image

第二部分输出,可以看到红框部分被重复识别: image

case图片输入: image

case图片输出,可以看到重影部分为重复识别: image

hermitgreen avatar Oct 09 '22 08:10 hermitgreen

想知道,这是模型问题还是代码实现问题?官方可以给出解决方案指导吗 : )

hermitgreen avatar Oct 09 '22 08:10 hermitgreen

这个是因为版面分析检测的结果重复了

WenmuZhou avatar Oct 09 '22 10:10 WenmuZhou

这个是因为版面分析检测的结果重复了

  • 有没有方法对其进行去重呢?
  • 重复的子图,在多次OCR过程中,recognize的文字是不稳定的吗?

hermitgreen avatar Oct 09 '22 10:10 hermitgreen

如果只进行ocr的话,直接使用paddleocr就好了。目前这个可以通过iou过滤一下

WenmuZhou avatar Oct 09 '22 11:10 WenmuZhou

如果只进行ocr的话,直接使用paddleocr就好了。目前这个可以通过iou过滤一下

  • IoU过滤有配置项可以启动么?or需要自行实现
  • 如果我需要将不同layout的文字识别到同一字符串内,在保障效果的前提下是否只能用PaddleOCR整图识别,然后用layout再进行group?

hermitgreen avatar Oct 10 '22 07:10 hermitgreen

如果只进行ocr的话,直接使用paddleocr就好了。目前这个可以通过iou过滤一下

  • IoU过滤有配置项可以启动么?or需要自行实现
  • 如果我需要将不同layout的文字识别到同一字符串内,在保障效果的前提下是否只能用PaddleOCR整图识别,然后用layout再进行group?

您好,可以礼貌问一下您解决了吗 🙇

shawjintran avatar Feb 06 '23 06:02 shawjintran

如果只进行ocr的话,直接使用paddleocr就好了。目前这个可以通过iou过滤一下

  • IoU过滤有配置项可以启动么?or需要自行实现
  • 如果我需要将不同layout的文字识别到同一字符串内,在保障效果的前提下是否只能用PaddleOCR整图识别,然后用layout再进行group?

您好,可以礼貌问一下您解决了吗 🙇

通过自行实现了IoU过滤解决了

hermitgreen avatar Feb 08 '23 06:02 hermitgreen