IronOCR OCR 프로그램에서 아라비아 숫자 이미지 텍스트 변환 문제 해결
아랍어, 페르시아어, 우르두어 언어 팩에서 아라비아 숫자를 인식하지 못하나요?
이는 Tesseract 언어 팩에서 발생하는 알려진 문제입니다.
다음 언어 팩은 아라비아 숫자와 관련된 이 문제를 해결하는 데 도움이 될 수 있습니다. Shreeshrii의 Tessdata 아랍어
이렇게 생성된 언어 팩은 IronOCR 기능을 이용하여 사용자 지정 언어 팩을 불러오는 데 사용할 수 있습니다. IronOCR 사용자 정의 언어 예시
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
참고: 이 C# 예제는 IronOCR 에서 사용자 지정 Tesseract 언어 파일을 사용하여 이미지 내 아라비아 숫자 인식률을 향상시키는 방법을 보여줍니다. 이 기능은 사용자가 이미 해당 언어 팩을 다운로드하여 지정된 위치에 배치했다고 가정합니다. IronOCR 설치하고 프로덕션 코드에 필요한 오류 처리를 추가했는지 확인하십시오.

