OCR de malayalam en C# y .NET

This article was translated from English: Does it need improvement?
Translated
View the article in English

126 idiomas más

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 malayalam. Es una versión avanzada de Tesseract, construida exclusivamente para desarrolladores de .NET y que supera regularmente a otros motores Tesseract tanto en velocidad como en precisión.

Contenido de IronOcr.Languages.Malayalam

Este paquete contiene 126 idiomas de OCR para .NET:

  • Malayalam
  • MalayalamBest
  • MalayalamFast
  • MalayalamAlphabet
  • MalayalamAlphabetBest
  • MalayalamAlphabetFast

Descargar

Paquete de idioma malayalam [മലയാളം]

Instalación

Lo primero que tenemos que hacer es instalar el paquete OCR Malayalam en tu proyecto .NET.

Install-Package IronOCR.Languages.Malayalam

Ejemplo de código

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

// Import the IronOcr namespace
using IronOcr;

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

        // Set the language to Malayalam
        Ocr.Language = OcrLanguage.Malayalam;

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

            // Extract and store the recognized text
            var AllText = Result.Text;

            // Output the recognized text
            Console.WriteLine(AllText);
        }
    }
}
// Import the IronOcr namespace
using IronOcr;

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

        // Set the language to Malayalam
        Ocr.Language = OcrLanguage.Malayalam;

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

            // Extract and store the recognized text
            var AllText = Result.Text;

            // Output the recognized text
            Console.WriteLine(AllText);
        }
    }
}
' Import the IronOcr namespace
Imports IronOcr

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

		' Set the language to Malayalam
		Ocr.Language = OcrLanguage.Malayalam

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

			' Extract and store the recognized text
			Dim AllText = Result.Text

			' Output the recognized text
			Console.WriteLine(AllText)
		End Using
	End Sub
End Class
$vbLabelText   $csharpLabel
  • El código demuestra cómo configurar IronOCR para realizar OCR en una imagen especificada con el idioma malayalam.
  • El objeto OcrInput se utiliza para introducir el archivo de imagen.
  • La función Ocr.Read procesa la imagen y extrae el texto.
  • El texto extraído se almacena en AllText y se imprime en la consola.