在 IronOCR 中使用阿拉伯数字

This article was translated from English: Does it need improvement?
Translated
View the article in English

阿拉伯语、波斯语和乌尔都语语言包无法识别阿拉伯数字吗?

这是一个已知的问题,与Tesseract语言包有关。

以下语言包可能有助于解决与阿拉伯数字相关的问题:

https://github.com/Shreeshrii/tessdata_arabic

然后就可以使用 IronOCR 功能加载自定义语言包:

https://ironsoftware.com/csharp/ocr/languages/#custom-language-example

using IronOcr; var Ocr = new IronTesseract();
    Ocr.UseCustomTesseractLanguageFile("custom_tesseract_files/custom.traineddata");
    using (var Input = new OcrInput(@"images\image.png"))
    {
    var Result = Ocr.Read(Input);
    Console.WriteLine(Result.Text);
    }
using IronOcr; var Ocr = new IronTesseract();
    Ocr.UseCustomTesseractLanguageFile("custom_tesseract_files/custom.traineddata");
    using (var Input = new OcrInput(@"images\image.png"))
    {
    var Result = Ocr.Read(Input);
    Console.WriteLine(Result.Text);
    }
Imports IronOcr
Private Ocr = New IronTesseract()
	Ocr.UseCustomTesseractLanguageFile("custom_tesseract_files/custom.traineddata")
	Using Input = New OcrInput("images\image.png")
	Dim Result = Ocr.Read(Input)
	Console.WriteLine(Result.Text)
	End Using
VB   C#