Replies: 6 comments
-
可以提供一张测试图片吗 |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
部署过很多次gpu版paddleocr,只有这台机器不知道为什么重启后识别突然有问题了。请问可能需要从哪个方向排查这个问题。 |
Beta Was this translation helpful? Give feedback.
-
用的是什么显卡,旧显卡和太新的显卡有可能会有问题 |
Beta Was this translation helpful? Give feedback.
-
NVIDIA H800 算新么?但问题是服务器崩了重启之前是可用的QwQ |
Beta Was this translation helpful? Give feedback.
-
from paddleocr import PaddleOCR
from PIL import Image, ImageDraw, ImageFont
ocr = PaddleOCR(use_angle_cls=True, lang="ch_doc")
img_path = "./425257841-44fe3112-ae09-4ba4-afdb-bfbc89be1d72.png"
results = ocr.ocr(img_path, cls=True)
image = Image.open(img_path).convert("RGB")
draw = ImageDraw.Draw(image)
font = ImageFont.truetype("./doc/fonts/simfang.ttf", size=10)
for res in results:
for line in res:
box = [tuple(point) for point in line[0]]
box = [(min(point[0] for point in box), min(point[1] for point in box)),
(max(point[0] for point in box), max(point[1] for point in box))]
txt = line[1][0]
draw.rectangle(box, outline="red", width=2)
draw.text((box[0][0], box[0][1] - 15), txt, fill="blue", font=font)
image.save("result.jpg") 我这是ok的,检查一下驱动和环境吧。 |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
paddleocr gpu运行时识别不出结果,cpu正常
之前出现过cudnn不匹配等问题,后来通过命令解决了。当时gpu也是正常的,但后来机器重启,重启后gpu出现问题,添加cudnn后gpu识别不出结果。
尝试版本:
1.
paddleocr 2.8.0
paddlepaddle-gpu 2.6.2
2.
paddleocr 2.10.0
paddlepaddle-gpu 3.0.0rc1
代码:
gpu结果:
cpu:
Beta Was this translation helpful? Give feedback.
All reactions