Hebrew OCR in C# and .NET

This article was translated from English: Does it need improvement?
Translated
View the article in English
Bu belgenin diğer versiyonları:

IronOCR, .NET kodlayıcılarının görüntülerden ve PDF belgelerinden, İbranice dahil 126 dilde metin okumasını sağlayan bir C# yazılım bileşenidir.

Tesseract'ın, yalnızca .NET geliştiricileri için özel olarak oluşturulmuş gelişmiş bir dalıdır ve hız ve doğruluk açısından diğer Tesseract motorlarını düzenli olarak geride bırakır.

IronOcr.Languages.Hebrew İçeriği

Bu paket, .NET için 108 OCR dilini içerir:

  • İbranice
  • İbraniceBest
  • İbraniceFast
  • İbranice Alfabe
  • İbraniceAlfabeEnİyi
  • İbranice AlfabeFast

İndir

İbranice Dil Paketi [עברית]

Kurulum

Yapmamız gereken ilk şey .NET projenize İbranice OCR paketini yüklemektir.

Install-Package IronOcr.Languages.Hebrew

Kod Örneği

Bu C# kod örneği, bir Görüntü veya PDF belgesinden İbranice metni okur.

// Include the IronOcr namespace to work with OCR features
using IronOcr;

// Create an OCR engine
var Ocr = new IronTesseract();

// Set the OCR engine language to Hebrew
Ocr.Language = OcrLanguage.Hebrew;

// Process the image and extract text using OCR
using (var Input = new OcrInput(@"images\Hebrew.png"))
{
    // Read the text from the input image
    var Result = Ocr.Read(Input);

    // Store the extracted text
    var AllText = Result.Text;

    // Output the extracted text to the console (optional)
    Console.WriteLine(AllText);
}
// Include the IronOcr namespace to work with OCR features
using IronOcr;

// Create an OCR engine
var Ocr = new IronTesseract();

// Set the OCR engine language to Hebrew
Ocr.Language = OcrLanguage.Hebrew;

// Process the image and extract text using OCR
using (var Input = new OcrInput(@"images\Hebrew.png"))
{
    // Read the text from the input image
    var Result = Ocr.Read(Input);

    // Store the extracted text
    var AllText = Result.Text;

    // Output the extracted text to the console (optional)
    Console.WriteLine(AllText);
}
' Include the IronOcr namespace to work with OCR features
Imports IronOcr

' Create an OCR engine
Private Ocr = New IronTesseract()

' Set the OCR engine language to Hebrew
Ocr.Language = OcrLanguage.Hebrew

' Process the image and extract text using OCR
Using Input = New OcrInput("images\Hebrew.png")
	' Read the text from the input image
	Dim Result = Ocr.Read(Input)

	' Store the extracted text
	Dim AllText = Result.Text

	' Output the extracted text to the console (optional)
	Console.WriteLine(AllText)
End Using
$vbLabelText   $csharpLabel
  • IronTesseract: Bu sınıf, OCR motorunu başlatmak için kullanılır.
  • OcrInput: OCR motorunun okuyacağı girdiyi temsil eder.
  • Ocr.Read: Bu yöntem girdiyi işler ve çıkarılan metni içeren sonucu döndürür.
  • Result.Text: Daha fazla işlem için kullanılabilecek çıkarılan metni saklar.