專門閱讀
超越純文字。使用專用的高性能工具準確閱讀護照(MRZ)、支票(MICR)、車牌和條碼。
專門閱讀
1
閱讀車牌
為自動停車管理、安全門禁和車輛追蹤建立 robust的自動車牌識別(ANPR)系統。 我們的引擎接受各種角度、距離和光照條件下準確讀取車牌。
瞭解如何使用:使用IronOCR閱讀車牌using IronOcr;
using System;
var ocr = new IronTesseract();
ocr.Configuration.WhiteListCharacters = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_";
using var inputLicensePlate = new OcrInput();
inputLicensePlate.LoadImage("plate.jpeg");
// Read license plate
OcrLicensePlateResult result = ocr.ReadLicensePlate(inputLicensePlate);
// Retrieve license plate number and confidence value
string output = $"{result.Text}\nResult Confidence: {result.Confidence}";
Console.WriteLine(output);Imports IronOcr
Imports System
Dim ocr = New IronTesseract()
ocr.Configuration.WhiteListCharacters = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_"
Using inputLicensePlate = New OcrInput()
inputLicensePlate.LoadImage("plate.jpeg")
' Read license plate
Dim result As OcrLicensePlateResult = ocr.ReadLicensePlate(inputLicensePlate)
' Retrieve license plate number and confidence value
Dim output As String = $"{result.Text}{vbLf}Result Confidence: {result.Confidence}"
Console.WriteLine(output)
End Using2
閱讀護照
通過立即從國際護照和身份證的機器可讀區(MRZ)中提取資料來簡化身份驗證和客戶入職。消除手動輸入錯誤,加快您的登記或合規流程。
瞭解如何使用:在C#中閱讀護照using IronOcr;
using System;
// Instantiate OCR engine
var ocr = new IronTesseract();
using var inputPassport = new OcrInput();
inputPassport.LoadImage("passport.jpg");
// Perform OCR
OcrPassportResult result = ocr.ReadPassport(inputPassport);
// Output name and passport number
Console.WriteLine(result.PassportInfo.GivenNames);
Console.WriteLine(result.PassportInfo.PassportNumber);Imports IronOcr
Imports System
' Instantiate OCR engine
Dim ocr = New IronTesseract()
Using inputPassport = New OcrInput()
inputPassport.LoadImage("passport.jpg")
' Perform OCR
Dim result As OcrPassportResult = ocr.ReadPassport(inputPassport)
' Output name and passport number
Console.WriteLine(result.PassportInfo.GivenNames)
Console.WriteLine(result.PassportInfo.PassportNumber)
End Using3
MICR支票閱讀
// Import the IronOCR namespace
using IronOcr;
// Create a new instance of IronTesseract for performing OCR operations
var Ocr = new IronTesseract();
// Set the OCR language to MICR to recognize magnetic ink characters
// Must have MICR (IronOcr.Languages.MICR) installed beforehand
Ocr.Language = OcrLanguage.MICR;
// Specify the file path of the input image containing MICR text
using (var Input = new OcrInput())
{
Input.LoadImage("sampleChequeImage.png");
// Run the OCR engine to read the MICR text from the input image
var Result = Ocr.Read(Input);
// Output the recognized text to the console
Console.WriteLine(Result.Text);
}' Import the IronOCR namespace
Imports IronOcr
' Create a new instance of IronTesseract for performing OCR operations
Dim Ocr = New IronTesseract()
' Set the OCR language to MICR to recognize magnetic ink characters
' Must have MICR (IronOcr.Languages.MICR) installed beforehand
Ocr.Language = OcrLanguage.MICR
' Specify the file path of the input image containing MICR text
Using Input = New OcrInput()
Input.LoadImage("sampleChequeImage.png")
' Run the OCR engine to read the MICR text from the input image
Dim Result = Ocr.Read(Input)
' Output the recognized text to the console
Console.WriteLine(Result.Text)
End Using4
閱讀條碼和QR碼
檢測並解碼所有主要的一維和二維條碼格式,包括QR碼。這是一個用於庫存管理、物流追蹤、銷售點系統和移動票務應用程式的多功能解決方案。
瞭解如何使用:在.NET C#中閱讀條碼和QR碼using IronOcr;
// Instantiate IronTesseract
IronTesseract ocrTesseract = new IronTesseract();
// Enable barcode reading
ocrTesseract.Configuration.ReadBarCodes = true;
// Add PDF
using var imageInput = new OcrPdfInput("pdfWithBarcodes.pdf");
// Perform OCR
OcrResult ocrResult = ocrTesseract.Read(imageInput);
// Output detected barcodes and text values
Console.WriteLine(ocrResult.Text);
Console.WriteLine(ocrResult.Barcodes[0].Value);Imports IronOcr
' Instantiate IronTesseract
Dim ocrTesseract As New IronTesseract()
' Enable barcode reading
ocrTesseract.Configuration.ReadBarCodes = True
' Add PDF
Using imageInput = New OcrPdfInput("pdfWithBarcodes.pdf")
' Perform OCR
Dim ocrResult As OcrResult = ocrTesseract.Read(imageInput)
' Output detected barcodes and text values
Console.WriteLine(ocrResult.Text)
Console.WriteLine(ocrResult.Barcodes(0).Value)
End Using5
電腦視覺OCR
利用電腦視覺的力量檢測帶有我們先進模型的文字。IronOCR使用OpenCV來識別圖像中包含文字的區域,特別適合於噪聲較多和文件中散落的文字塊的圖像!
瞭解如何使用:電腦視覺OCR教程(許可證、字幕、發票)using IronOcr;
var ocr = new IronTesseract();
using var input = new OcrInput();
input.LoadImage("sample.png");
// Make sure to also install IronOcr.Extensions.AdvancedScan to use this method
input.FindTextRegion(Scale: 2.0, DilationAmount: 20, Binarize: true, Invert: true);
OcrResult result = ocr.Read(input);
string resultText = result.Text;Imports IronOcr
Dim ocr = New IronTesseract()
Using input = New OcrInput()
input.LoadImage("sample.png")
' Make sure to also install IronOcr.Extensions.AdvancedScan to use this method
input.FindTextRegion(Scale:=2.0, DilationAmount:=20, Binarize:=True, Invert:=True)
Dim result As OcrResult = ocr.Read(input)
Dim resultText As String = result.Text
End Using準備開始了嗎?
Nuget Downloads 6,236,385|版本:2026.9剛剛發布