Greek Alphabet OCR in C# and .NET
Outras versões deste documento:
IronOCR é um componente de software C# que permite a programadores .NET ler texto de imagens e documentos PDF em 126 idiomas, incluindo o Alfabeto Grego.
Trata-se de uma versão avançada do Tesseract, criada exclusivamente para desenvolvedores .NET e que supera regularmente outros mecanismos do Tesseract em termos de velocidade e precisão.
Conteúdos de IronOcr.Languages.Greek
Este pacote contém 102 linguagens de OCR for .NET:
- Grego
- GreekBest
- GreekFast
- GreekAlphabet
- GreekAlphabetBest
- GreekAlphabetFast
Baixar
Pacote de Idioma do Alfabeto Grego [ελληνικά]
Instalação
O primeiro passo é instalar o pacote OCR do Alfabeto Grego no seu projeto .NET.
Install-Package IronOcr.Languages.Greek
Exemplo de código
Este exemplo de código C# lê texto do Alfabeto Grego de uma imagem ou documento PDF.
// Import the IronOcr namespace
using IronOcr;
class GreekOcrExample
{
static void Main()
{
// Initialize the IronTesseract OCR engine
var Ocr = new IronTesseract();
// Set the OCR language to Greek
Ocr.Language = OcrLanguage.Greek;
// Load the image or PDF containing Greek text
using (var Input = new OcrInput(@"images\Greek.png"))
{
// Perform OCR and get the result
var Result = Ocr.Read(Input);
// Extract all recognized text
var AllText = Result.Text;
// Output the recognized text
System.Console.WriteLine(AllText);
}
}
}
// Import the IronOcr namespace
using IronOcr;
class GreekOcrExample
{
static void Main()
{
// Initialize the IronTesseract OCR engine
var Ocr = new IronTesseract();
// Set the OCR language to Greek
Ocr.Language = OcrLanguage.Greek;
// Load the image or PDF containing Greek text
using (var Input = new OcrInput(@"images\Greek.png"))
{
// Perform OCR and get the result
var Result = Ocr.Read(Input);
// Extract all recognized text
var AllText = Result.Text;
// Output the recognized text
System.Console.WriteLine(AllText);
}
}
}
' Import the IronOcr namespace
Imports IronOcr
Friend Class GreekOcrExample
Shared Sub Main()
' Initialize the IronTesseract OCR engine
Dim Ocr = New IronTesseract()
' Set the OCR language to Greek
Ocr.Language = OcrLanguage.Greek
' Load the image or PDF containing Greek text
Using Input = New OcrInput("images\Greek.png")
' Perform OCR and get the result
Dim Result = Ocr.Read(Input)
' Extract all recognized text
Dim AllText = Result.Text
' Output the recognized text
System.Console.WriteLine(AllText)
End Using
End Sub
End Class
- IronTesseract: Esta classe é responsável por executar a operação de OCR.
- OcrInput: Esta classe é usada para carregar as imagens ou arquivos PDF para processamento OCR.
- Ocr.Read(): Método para realizar o OCR nos dados de entrada e fornecer o texto reconhecido.
Antes de executar este código, assegure-se de que a biblioteca IronOcr e o pacote de idioma Grego estão devidamente instalados no seu projeto .NET. Este código irá extrair o texto da imagem localizada em images/Greek.png.

