Maori OCR in C# and .NET
IronOCR는 C# 소프트웨어 구성 요소로, .NET 코더가 마오리어를 포함한 126개 언어로 된 이미지와 PDF 문서에서 텍스트를 읽을 수 있도록 합니다.
이는 .NET 개발자 전용으로 제작된 Tesseract의 고급 포크 버전으로, 속도와 정확도 면에서 다른 Tesseract 엔진보다 뛰어난 성능을 보여줍니다.
IronOcr.Languages.Maori의 내용
이 패키지에는 .NET 용 OCR 언어 40개가 포함되어 있습니다.
- 마오리어
- MaoriBest
- MaoriFast
다운로드
마오리어 언어 팩 [te reo Māori]
설치
첫 번째로 해야 할 일은 .NET 프로젝트에 마오리어 OCR 패키지를 설치하는 것입니다.
Install-Package IronOcr.Languages.Maori
코드 예제
이 C# 코드 예제는 이미지나 PDF 문서에서 마오리어 텍스트를 읽습니다.
// Install the IronOCR Maori language package using NuGet
// PM> Install-Package IronOcr.Languages.Maori
using IronOcr;
var Ocr = new IronTesseract();
// Specify the language to be Maori
Ocr.Language = OcrLanguage.Maori;
using (var Input = new OcrInput(@"images\Maori.png"))
{
// Perform OCR to extract text
var Result = Ocr.Read(Input);
// Retrieve the recognized text
var AllText = Result.Text;
// Optionally, print the extracted text
// Console.WriteLine(AllText);
}
// Install the IronOCR Maori language package using NuGet
// PM> Install-Package IronOcr.Languages.Maori
using IronOcr;
var Ocr = new IronTesseract();
// Specify the language to be Maori
Ocr.Language = OcrLanguage.Maori;
using (var Input = new OcrInput(@"images\Maori.png"))
{
// Perform OCR to extract text
var Result = Ocr.Read(Input);
// Retrieve the recognized text
var AllText = Result.Text;
// Optionally, print the extracted text
// Console.WriteLine(AllText);
}
' Install the IronOCR Maori language package using NuGet
' PM> Install-Package IronOcr.Languages.Maori
Imports IronOcr
Private Ocr = New IronTesseract()
' Specify the language to be Maori
Ocr.Language = OcrLanguage.Maori
Using Input = New OcrInput("images\Maori.png")
' Perform OCR to extract text
Dim Result = Ocr.Read(Input)
' Retrieve the recognized text
Dim AllText = Result.Text
' Optionally, print the extracted text
' Console.WriteLine(AllText);
End Using
설명
- IronTesseract는 OCR을 수행할 수 있는 인스턴스입니다.
- Ocr.Language는 우리가 읽고 있는 텍스트의 언어를 마오리어로 지정하기 위해 설정되어 있습니다.
- OcrInput는 지정된 파일 경로의 이미지에서 입력을 잡는데 사용됩니다.
- Ocr.Read()은 OCR을 수행하고 결과를 가져옵니다.
- Result.Text는 필요한 대로 저장하거나 처리할 수 있는 이미지에서 추출된 텍스트를 포함합니다.
이 코드 설정은 정확한 텍스트 인식을 달성하기 위해 올바른 OCR 언어 팩을 사용하도록 보장합니다.

