Ukrainian OCR in C# and .NET

This article was translated from English: Does it need improvement?
Translated
View the article in English
Other versions of this document:

IronOCR ist eine C# Softwarekomponente, die es .NET-Entwicklern ermöglicht, Text aus Bildern und PDF-Dokumenten in 126 Sprachen, einschließlich Ukrainisch, zu lesen.

Es ist eine erweiterte Abspaltung von Tesseract, die exklusiv für .NET-Entwickler entwickelt wurde und regelmäßig andere Tesseract-Engines sowohl in Bezug auf Geschwindigkeit als auch Genauigkeit übertrifft.

Inhalt von IronOcr.Languages.Ukrainian

Dieses Paket enthält 52 OCR-Sprachen für .NET:

  • Ukrainisch
  • UkrainischBest
  • UkrainischSchnell

Download

Ukrainisches Sprachpaket style='white-space:default'>[українська мова]

Installation

Das Erste, was Sie tun müssen, ist, das Ukrainian OCR-Paket in Ihrem .NET-Projekt zu installieren.

Install-Package IronOCR.Languages.Ukrainian

Beispielcode

Dieses C#-Beispiel liest ukrainischen Text aus einem Bild oder PDF-Dokument.

// Ensure you have the IronOCR.Languages.Ukrainian package installed.
// Using IronOcr namespace to access OCR functionalities.
using IronOcr;

// Initialize a new instance of IronTesseract
var Ocr = new IronTesseract();

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

// Use an OcrInput object for image input
using (var Input = new OcrInput(@"images\Ukrainian.png"))
{
    // Perform OCR operation on the image
    var Result = Ocr.Read(Input);

    // Get the extracted text from the result
    var AllText = Result.Text;

    // Output or use the extracted text as needed
    Console.WriteLine(AllText);
}
// Ensure you have the IronOCR.Languages.Ukrainian package installed.
// Using IronOcr namespace to access OCR functionalities.
using IronOcr;

// Initialize a new instance of IronTesseract
var Ocr = new IronTesseract();

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

// Use an OcrInput object for image input
using (var Input = new OcrInput(@"images\Ukrainian.png"))
{
    // Perform OCR operation on the image
    var Result = Ocr.Read(Input);

    // Get the extracted text from the result
    var AllText = Result.Text;

    // Output or use the extracted text as needed
    Console.WriteLine(AllText);
}
' Ensure you have the IronOCR.Languages.Ukrainian package installed.
' Using IronOcr namespace to access OCR functionalities.
Imports IronOcr

' Initialize a new instance of IronTesseract
Private Ocr = New IronTesseract()

' Set the OCR language to Ukrainian
Ocr.Language = OcrLanguage.Ukrainian

' Use an OcrInput object for image input
Using Input = New OcrInput("images\Ukrainian.png")
	' Perform OCR operation on the image
	Dim Result = Ocr.Read(Input)

	' Get the extracted text from the result
	Dim AllText = Result.Text

	' Output or use the extracted text as needed
	Console.WriteLine(AllText)
End Using
$vbLabelText   $csharpLabel
  • Stellen Sie sicher, dass Sie den Pfad "images\Ukrainian.png" durch den Pfad zu Ihrem eigenen Bild oder PDF-Dokument ersetzen.
  • Dieses Beispiel zeigt, wie IronOCR eingerichtet wird, um ukrainischen Text zu erkennen und den extrahierten Text auszugeben.