OCR occitan en C# et .NET

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

126 autres langues

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'occitan. 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.Occitan

Ce package contient 46 langues OCR pour .NET :

  • Occitan
  • OccitanBest
  • OccitanFast

Télécharger

Pack de langue occitan

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

Installation

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

Install-Package IronOCR.Languages.Occitan

Exemple de code

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

// Importing the IronOCR namespace
using IronOcr;

class Program
{
    static void Main()
    {
        // Create a new instance of the OCR engine for Occitan language
        var Ocr = new IronTesseract();
        Ocr.Language = OcrLanguage.Occitan;

        // Use a using block for proper disposal of resources
        using (var Input = new OcrInput(@"images\Occitan.png"))
        {
            // Perform OCR on the input image
            var Result = Ocr.Read(Input);

            // Retrieve the recognized text
            var AllText = Result.Text;

            // Output the recognized text to the console
            Console.WriteLine(AllText);
        }
    }
}
// Importing the IronOCR namespace
using IronOcr;

class Program
{
    static void Main()
    {
        // Create a new instance of the OCR engine for Occitan language
        var Ocr = new IronTesseract();
        Ocr.Language = OcrLanguage.Occitan;

        // Use a using block for proper disposal of resources
        using (var Input = new OcrInput(@"images\Occitan.png"))
        {
            // Perform OCR on the input image
            var Result = Ocr.Read(Input);

            // Retrieve the recognized text
            var AllText = Result.Text;

            // Output the recognized text to the console
            Console.WriteLine(AllText);
        }
    }
}
' Importing the IronOCR namespace
Imports IronOcr

Friend Class Program
	Shared Sub Main()
		' Create a new instance of the OCR engine for Occitan language
		Dim Ocr = New IronTesseract()
		Ocr.Language = OcrLanguage.Occitan

		' Use a using block for proper disposal of resources
		Using Input = New OcrInput("images\Occitan.png")
			' Perform OCR on the input image
			Dim Result = Ocr.Read(Input)

			' Retrieve the recognized text
			Dim AllText = Result.Text

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

Cet exemple montre comment configurer la bibliothèque IronOCR pour lire du texte à partir d'un fichier image contenant du texte occitan. Il configure la langue de la reconnaissance optique de caractères (OCR) sur l'occitan et traite l'image, générant le texte reconnu.