Tibetan Alphabet OCR in C# and .NET

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

Mais 126 idiomas

O IronOCR é um componente de software C# que permite aos programadores .NET ler texto de imagens e documentos PDF em 126 idiomas, incluindo o alfabeto tibetano.

Trata-se de uma versão avançada do Tesseract, criada exclusivamente para desenvolvedores .NET , e que supera regularmente outros mecanismos do Tesseract tanto em velocidade quanto em precisão.

Conteúdo de IronOcr.Languages.Tibetan

Este pacote contém 114 idiomas OCR for .NET:

  • Tibetano
  • TibetanoBest
  • Jejum Tibetano
  • Alfabeto Tibetano
  • Melhor Alfabeto Tibetano
  • Alfabeto TibetanoRápido

Baixar

Pacote de Alfabeto Tibetano [Padrão Tibetano]

Instalação

A primeira coisa que você precisa fazer é instalar o pacote OCR do alfabeto tibetano em seu projeto .NET.

Install-Package IronOcr.Languages.Tibetan

Exemplo de código

Este exemplo de código C# lê texto em alfabeto tibetano a partir de uma imagem ou documento PDF.

// Import the IronOcr namespace to use its components
using IronOcr;

class Program
{
    static void Main()
    {
        // Initialize a new IronTesseract object for OCR
        var Ocr = new IronTesseract();

        // Set the OCR language to Tibetan
        Ocr.Language = OcrLanguage.Tibetan;

        // Use a using statement for automatic resource disposal
        using (var Input = new OcrInput(@"images\Tibetan.png"))
        {
            // Perform OCR to read text from the input image
            var Result = Ocr.Read(Input);

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

            // Output the recognized text to the console
            // Note: Ensure that the console supports Tibetan script for correct display
            Console.WriteLine(AllText);
        }
    }
}
// Import the IronOcr namespace to use its components
using IronOcr;

class Program
{
    static void Main()
    {
        // Initialize a new IronTesseract object for OCR
        var Ocr = new IronTesseract();

        // Set the OCR language to Tibetan
        Ocr.Language = OcrLanguage.Tibetan;

        // Use a using statement for automatic resource disposal
        using (var Input = new OcrInput(@"images\Tibetan.png"))
        {
            // Perform OCR to read text from the input image
            var Result = Ocr.Read(Input);

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

            // Output the recognized text to the console
            // Note: Ensure that the console supports Tibetan script for correct display
            Console.WriteLine(AllText);
        }
    }
}
$vbLabelText   $csharpLabel

Notas

  • A biblioteca OCR (IronTesseract) está configurada para ler o idioma tibetano a partir da imagem fornecida.
  • OcrInput lida com o carregamento da imagem de entrada e garante o descarte adequado dos recursos usando a declaração using.
  • Result.Text contém o texto processado por OCR que pode ser impresso ou usado dentro do aplicativo.