IronOCR'da Arap Rakamları ile Çalışmak
Arapça, Farsça ve Urdu Dili Paketleri Arap Rakamlarını Tanımıyor mu?
Bu, Tesseract dil paketlerinin bilinen bir sorunudur.
Aşağıdaki dil paketi, Arap rakamları ile ilgili bu sorunu çözmeye yardımcı olabilir: Shreeshrii'nin Tessdata Arabic
Bu dil paketi daha sonra IronOCR özelliği ile özel dil paketlerini yüklemek için kullanılabilir: IronOCR Özel Dil Örneği
using IronOcr;
class ArabicNumeralOCR
{
static void Main(string[] args)
{
// Initialize a new instance of IronTesseract for OCR
var Ocr = new IronTesseract();
// Load the custom Tesseract language file for better numeral recognition
Ocr.UseCustomTesseractLanguageFile("custom_tesseract_files/custom.traineddata");
// Specify the image input for OCR processing
using (var Input = new OcrInput(@"images\image.png"))
{
// Execute the OCR process on the input image
var Result = Ocr.Read(Input);
// Output the recognized text
Console.WriteLine(Result.Text);
}
}
}
using IronOcr;
class ArabicNumeralOCR
{
static void Main(string[] args)
{
// Initialize a new instance of IronTesseract for OCR
var Ocr = new IronTesseract();
// Load the custom Tesseract language file for better numeral recognition
Ocr.UseCustomTesseractLanguageFile("custom_tesseract_files/custom.traineddata");
// Specify the image input for OCR processing
using (var Input = new OcrInput(@"images\image.png"))
{
// Execute the OCR process on the input image
var Result = Ocr.Read(Input);
// Output the recognized text
Console.WriteLine(Result.Text);
}
}
}
Imports IronOcr
Friend Class ArabicNumeralOCR
Shared Sub Main(ByVal args() As String)
' Initialize a new instance of IronTesseract for OCR
Dim Ocr = New IronTesseract()
' Load the custom Tesseract language file for better numeral recognition
Ocr.UseCustomTesseractLanguageFile("custom_tesseract_files/custom.traineddata")
' Specify the image input for OCR processing
Using Input = New OcrInput("images\image.png")
' Execute the OCR process on the input image
Dim Result = Ocr.Read(Input)
' Output the recognized text
Console.WriteLine(Result.Text)
End Using
End Sub
End Class
Not: Bu C# örneği, IronOCR'de Arap rakamlarının tanınmasını geliştirmek için özel bir Tesseract dil dosyasının nasıl kullanılacağını göstermektedir. Uygun dil paketini indirdiğinizi ve belirtilen konuma yerleştirdiğinizi varsayar. IronOCR'yi kurun ve üretim kodunda gerekli hata işlemlerini eklemeyi unutmayın.

