OCR azerbaiyano en C# y .NET

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

IronOCR es un componente de software C# que permite a los programadores de .NET leer texto de imágenes y documentos PDF en 126 idiomas, incluido el azerbaiyano.

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.Azerbaiyano

Este paquete contiene 138 idiomas OCR para .NET:

  • Azerbaiyano
  • AzerbaiyanoBest
  • AzerbaiyanoFast
  • AzerbaiyanoCyrillic
  • AzerbaiyanoCyrillicBest
  • AzerbaiyanoCyrillicFast

Descargar

Paquete de idioma azerbaiyano [azərbaycan dili]

Instalación

Lo primero que tenemos que hacer es instalar nuestro paquete OCR Azerbaiyano en su proyecto .NET.

Install-Package IronOCR.Languages.Azerbaijani

Ejemplo de código

Este ejemplo de código en C# lee texto azerbaiyano de una imagen o documento PDF.

// Ensure the IronOCR Azerbaijani language package is installed
// PM> Install-Package IronOCR.Languages.Azerbaijani

using IronOcr;

class Program
{
    static void Main()
    {
        // Create a new instance of IronTesseract engine
        var Ocr = new IronTesseract();

        // Specify the language to be Azerbaijani
        Ocr.Language = OcrLanguage.Azerbaijani;

        // Provide the path to the image file containing Azerbaijani text
        using (var Input = new OcrInput(@"images\Azerbaijani.png"))
        {
            // Process the image to extract text
            var Result = Ocr.Read(Input);

            // Extracted text is stored in Result.Text
            var AllText = Result.Text;

            // Output the extracted text
            Console.WriteLine(AllText);
        }
    }
}
// Ensure the IronOCR Azerbaijani language package is installed
// PM> Install-Package IronOCR.Languages.Azerbaijani

using IronOcr;

class Program
{
    static void Main()
    {
        // Create a new instance of IronTesseract engine
        var Ocr = new IronTesseract();

        // Specify the language to be Azerbaijani
        Ocr.Language = OcrLanguage.Azerbaijani;

        // Provide the path to the image file containing Azerbaijani text
        using (var Input = new OcrInput(@"images\Azerbaijani.png"))
        {
            // Process the image to extract text
            var Result = Ocr.Read(Input);

            // Extracted text is stored in Result.Text
            var AllText = Result.Text;

            // Output the extracted text
            Console.WriteLine(AllText);
        }
    }
}
' Ensure the IronOCR Azerbaijani language package is installed
' PM> Install-Package IronOCR.Languages.Azerbaijani

Imports IronOcr

Friend Class Program
	Shared Sub Main()
		' Create a new instance of IronTesseract engine
		Dim Ocr = New IronTesseract()

		' Specify the language to be Azerbaijani
		Ocr.Language = OcrLanguage.Azerbaijani

		' Provide the path to the image file containing Azerbaijani text
		Using Input = New OcrInput("images\Azerbaijani.png")
			' Process the image to extract text
			Dim Result = Ocr.Read(Input)

			' Extracted text is stored in Result.Text
			Dim AllText = Result.Text

			' Output the extracted text
			Console.WriteLine(AllText)
		End Using
	End Sub
End Class
$vbLabelText   $csharpLabel

En este ejemplo, inicializamos el objeto IronTesseract y configuramos su idioma al azerbaiyano. La instancia OcrInput se utiliza para leer una imagen desde la ruta de archivo especificada. El método Ocr.Read procesa la imagen para extraer el texto, que es accesible a través de la propiedad Result.Text. Esto permite una fácil salida o procesamiento adicional.