Syriac OCR in C# and .NET
O IronOCR é um componente de software C# que permite aos programadores .NET ler texto de imagens e documentos PDF em 126 idiomas, incluindo o siríaco.
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údo de IronOcr.Languages.Syriac
Este pacote contém 108 linguagens OCR for .NET:
- Siríaco
- SiríacoMelhor
- Siríaco Rápido
- Alfabeto Siríaco
- SiríacoAlphabetBest
- Alfabeto Siríaco Rápido
Baixar
Pacote de idioma siríaco [Siríaco]
Instalação
O primeiro passo é instalar o pacote OCR siríaco em seu projeto .NET.
Install-Package IronOcr.Languages.Syriac
Exemplo de código
Este exemplo de código C# lê texto siríaco de uma imagem ou documento PDF.
// Import the IronOcr library
using IronOcr;
class Program
{
static void Main()
{
// Instantiate the IronTesseract object
var Ocr = new IronTesseract();
// Set the language to Syriac
Ocr.Language = OcrLanguage.Syriac;
// Create an OCR input from an image file
using (var Input = new OcrInput(@"images\Syriac.png"))
{
// Read the image and extract the text
var Result = Ocr.Read(Input);
// Retrieve the full recognized text
var AllText = Result.Text;
// Output the text to the console
Console.WriteLine(AllText);
}
}
}
// Import the IronOcr library
using IronOcr;
class Program
{
static void Main()
{
// Instantiate the IronTesseract object
var Ocr = new IronTesseract();
// Set the language to Syriac
Ocr.Language = OcrLanguage.Syriac;
// Create an OCR input from an image file
using (var Input = new OcrInput(@"images\Syriac.png"))
{
// Read the image and extract the text
var Result = Ocr.Read(Input);
// Retrieve the full recognized text
var AllText = Result.Text;
// Output the text to the console
Console.WriteLine(AllText);
}
}
}
' Import the IronOcr library
Imports IronOcr
Friend Class Program
Shared Sub Main()
' Instantiate the IronTesseract object
Dim Ocr = New IronTesseract()
' Set the language to Syriac
Ocr.Language = OcrLanguage.Syriac
' Create an OCR input from an image file
Using Input = New OcrInput("images\Syriac.png")
' Read the image and extract the text
Dim Result = Ocr.Read(Input)
' Retrieve the full recognized text
Dim AllText = Result.Text
' Output the text to the console
Console.WriteLine(AllText)
End Using
End Sub
End Class
Neste exemplo:
- Criamos uma instância de
IronTesseractpara processar OCR. - O
Ocr.Languageé configurado paraSyriacpara garantir reconhecimento preciso de texto para este idioma. - Carregamos uma imagem contendo texto em siríaco em
OcrInpute a processamos usandoOcr.Read. - O texto reconhecido é então armazenado em
Result.Text, que pode ser utilizado posteriormente em sua aplicação.

