using IronOcr;
using System;
var ocrTesseract = new IronTesseract();
// Fast Dictionary
ocrTesseract.Language = OcrLanguage.EnglishFast;
// Turn off unneeded options
ocrTesseract.Configuration.ReadBarCodes = false;
// Assume text is laid out neatly in an orthogonal document
ocrTesseract.Configuration.PageSegmentationMode = TesseractPageSegmentationMode.Auto;
using var ocrInput = new OcrInput();
ocrInput.LoadImage(@"images\image.png");
var ocrResult = ocrTesseract.Read(ocrInput);
Console.WriteLine(ocrResult.Text);
Imports IronOcr
Imports System
Private ocrTesseract = New IronTesseract()
' Fast Dictionary
ocrTesseract.Language = OcrLanguage.EnglishFast
' Turn off unneeded options
ocrTesseract.Configuration.ReadBarCodes = False
' Assume text is laid out neatly in an orthogonal document
ocrTesseract.Configuration.PageSegmentationMode = TesseractPageSegmentationMode.Auto
Dim ocrInput As New OcrInput()
ocrInput.LoadImage("images\image.png")
Dim ocrResult = ocrTesseract.Read(ocrInput)
Console.WriteLine(ocrResult.Text)
Install-Package IronOcr
빠른 OCR 구성
이 예제는 35% 이상의 속도 향상을 기본 설정보다 0.2%의 정확도를 희생하면서 제공합니다.
이미지 내 특정 영역을 OCR하는 방법에도 관심이 있을 수 있습니다. 이는 속도를 크게 향상시킬 수 있습니다.