问题描述
我一直在使用Tesseract 3.0.2 OCR SDK进行图像文本提取。但是,如果我使用中文文本图像并通过OCR,那么Tesseract不会提供中文字符而不是我获得数字和英文字符。但是我需要在我正在使用的图像中显示中文字符。
I have been using Tesseract 3.0.2 OCR SDK for image text extraction. But if I use Chinese text images and pass through OCR then Tesseract doesn't provide me the Chinese characters instead of that I am getting numeric and english characters. But I need Chinese characters as displayed in the image I am using.
我怎样才能做到这一点?有什么方法可以获得中文字符而不是任何其他字符吗?
How can I achieve this? Is there any way I can obtain Chinese characters rather than any other characters?
推荐答案
你需要下载中文训练数据(它会是一个像 chi_sim.traineddata 这样的文件,并将其添加到您的 tessdata 文件夹。
You need to download chinese trained data (it will be a file like chi_sim.traineddata) and add it to your tessdata folder.
下载文件
并像这样使用
Tesseract* tesseract= [[Tesseract alloc] initWithDataPath:@"tessdata" language:@"chi_sim"];
如果您有任何问题,可以从$ b下载tessaract(带中文支持)的实验$ b
if you have any problem you can download my experiment with tessaract (with chinese language support) fromhttps://github.com/aryansbtloe/ExperimentWithTesseract.git
我测试过这个...希望你会发现这个很有用。
I have tested this one...Hope you will find this useful.
这篇关于使用Tesseract OCR进行汉字识别的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!