Mongolian OCR in C# and .NET

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

IronOCR ist eine C#-Softwarekomponente, die es .NET-Entwicklern ermöglicht, Text aus Bildern und PDF-Dokumenten in 126 Sprachen, einschließlich Mongolisch, zu lesen.

Es ist eine fortschrittliche Abspaltung von Tesseract, die ausschließlich für .NET-Entwickler gebaut wurde und regelmäßig andere Tesseract-Engines sowohl in Geschwindigkeit als auch Genauigkeit übertrifft.

Inhalte von IronOcr.Languages.Mongolian

Dieses Paket enthält 52 OCR-Sprachen für .NET:

  • Mongolisch
  • MongolianBest
  • MongolianFast

Download

Mongolisches Sprachpaket style='white-space:default'>[монгол]

Installation

Der erste Schritt besteht darin, das Mongolian OCR-Paket in Ihrem .NET-Projekt zu installieren.

Install-Package IronOCR.Languages.Mongolian

Beispielcode

Dieses C#-Codebeispiel liest mongolischen Text aus einem Bild oder PDF-Dokument.

using IronOcr;

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

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

        // Define the input as an image located in the "images" directory
        using (var Input = new OcrInput(@"images\Mongolian.png"))
        {
            // Perform OCR on the input image
            var Result = Ocr.Read(Input);

            // Extract all recognized text
            var AllText = Result.Text;

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

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

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

        // Define the input as an image located in the "images" directory
        using (var Input = new OcrInput(@"images\Mongolian.png"))
        {
            // Perform OCR on the input image
            var Result = Ocr.Read(Input);

            // Extract all recognized text
            var AllText = Result.Text;

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

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

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

		' Define the input as an image located in the "images" directory
		Using Input = New OcrInput("images\Mongolian.png")
			' Perform OCR on the input image
			Dim Result = Ocr.Read(Input)

			' Extract all recognized text
			Dim AllText = Result.Text

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

Dieses Beispiel zeigt, wie man IronOCR verwendet, um Texterkennung auf einem mongolischen Textbild durchzuführen. Es initialisiert die OCR-Engine, legt die Sprache fest und verarbeitet das Bildeingangssignal, um den erkannten Text abzurufen und anzuzeigen.