未验证 提交 f3cf94a2 编写于 作者: D Double_V 提交者: GitHub

Merge pull request #18 from LDOUBLEV/fixocr

change the saved path of visualized image
...@@ -132,9 +132,11 @@ if __name__ == "__main__": ...@@ -132,9 +132,11 @@ if __name__ == "__main__":
draw_img = draw_ocr( draw_img = draw_ocr(
image, boxes, txts, scores, draw_txt=True, drop_score=0.5) image, boxes, txts, scores, draw_txt=True, drop_score=0.5)
draw_img_save = "./doc/imgs_results/" draw_img_save = "./inference_results/"
if not os.path.exists(draw_img_save): if not os.path.exists(draw_img_save):
os.makedirs(draw_img_save) os.makedirs(draw_img_save)
cv2.imwrite( cv2.imwrite(
os.path.join(draw_img_save, os.path.basename(image_file)), os.path.join(draw_img_save, os.path.basename(image_file)),
draw_img) draw_img)
print("The visualized image saved in {}".format(
os.path.join(draw_img_save, os.path.basename(image_file))))
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册