Ukrainian OCR in C# and .NET
Otras versiones de este documento:
IronOCR es un componente de software en C# que permite a los programadores de .NET leer texto de imágenes y documentos PDF en 126 idiomas, incluido el ucraniano.
Es una rama avanzada de Tesseract, construida exclusivamente para desarrolladores de .NET y supera regularmente a otros motores de Tesseract tanto en velocidad como en precisión.
Contenido de IronOcr.Languages.Ukrainian
Este paquete contiene 52 idiomas de OCR for .NET:
- Ucraniano
- UkrainianBest
- UkrainianFast
Descargar
Paquete de idioma ucraniano [українська мова]
Instalación
Lo primero que hay que hacer es instalar el paquete OCR Ucraniano en tu proyecto .NET.
Install-Package IronOcr.Languages.Ukrainian
Ejemplo de código
Este ejemplo de código C# lee texto ucraniano de una imagen o documento 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);
}
Imports IronOcr
' Initialize a new instance of IronTesseract
Dim Ocr As New IronTesseract()
' Set the OCR language to Ukrainian
Ocr.Language = OcrLanguage.Ukrainian
' Use an OcrInput object for image input
Using Input As 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
- Asegúrese de reemplazar la ruta
"images\Ukrainian.png"con la ruta a su propia imagen o documento PDF. - Este ejemplo demuestra cómo configurar IronOCR para reconocer texto en ucraniano y producir el texto extraído.

