dddd_trainer 訓練完的模型,在ddddocr跑出來都是"",有解決辦法嗎?
Author: marcuskuo0623Created Mar 29, 2026Updated May 15, 2026
和這篇的情況一樣 https://github.com/sml2h3/ddddocr/issues/285 有參考(reference: https://global.v2ex.com/t/1172404)
但是可能因為版本不相同造成沒辦法正常匯出,下面是我目前的版本。 ddddocr: 1.5.6 NumPy: 1.26.4 Pillow: 12.1.1 ONNXRuntime: 1.23.2 PyTorch: 2.1.0
想問能成功使用訓練模型跑出資料的,版本都是多少呢?
目前訓練圖片張數40000張, acc 0.98 但是跑在ddddocr 完全不準確
ocr = ddddocr.DdddOcr(det=False, ocr=False,
import_onnx_path=onnx_path,
charsets_path=charsets_path)
with open('text.png', 'rb') as f:
image_bytes = f.read()
res = ocr.classification(image_bytes)
print(res)Source: sml2h3/ddddocr