OCR ukrainien en C# et .NET

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

IronOCR est un composant logiciel C# permettant aux développeurs .NET de lire du texte à partir d'images et de documents PDF dans 126 langues, dont l'ukrainien.

Il s'agit d'une version avancée de Tesseract, conçue exclusivement pour les développeurs .NET et qui surpasse régulièrement les autres moteurs Tesseract en termes de vitesse et de précision.

Contenu de IronOcr.Languages.Ukrainien

Ce package contient 52 langues OCR pour .NET :

  • Ukrainien
  • UkrainianBest
  • UkrainianFast

Télécharger

Pack de langue ukrainienne [langue ukrainienne]

  • Télécharger au format Zip
  • Installer avec NuGet

Installation

La première chose à faire est d'installer le package OCR ukrainien dans votre projet .NET.

Install-Package IronOCR.Languages.Ukrainian

Exemple de code

Cet exemple de code C# lit du texte ukrainien à partir d'une image ou d'un document PDF.

// 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
  • Veillez à remplacer le chemin "images\Ukrainian.png" par le chemin d'accès à votre propre image ou document PDF.
  • Cet exemple montre comment configurer IronOCR pour reconnaître du texte ukrainien et afficher le texte extrait.