使用 C# 和 .NET 實作維吾爾語 OCR
This article was translated from English: Does it need improvement?
TranslatedView the article in English
Other versions of this document:
IronOCR 是一個 C# 軟體元件,允許 .NET 程式設計師從圖像和 PDF 文件中讀取 126 種語言(包括維吾爾語)的文字。
它是 Tesseract 的一個高級分支,專為 .NET 開發人員構建,在速度和準確性方面通常優於其他 Tesseract 引擎。
IronOcr.Languages.Uyghur 的內容
此軟體包包含 43 種適用於 .NET 的 OCR 語言:
- 維吾爾族
- UyghurBest
- 維吾爾快速
下載
維吾爾語語言包[Uyƣurqə]
安裝
我們首先需要做的就是將我們的維吾爾語OCR 套件安裝到您的 .NET 專案中。
Install-Package IronOCR.Languages.Uyghur
程式碼範例
這段 C# 程式碼範例從圖像或 PDF 文件中讀取維吾爾文本。
using IronOcr;
var Ocr = new IronTesseract();
// Set the OCR language to Uyghur. This is necessary to correctly read Uyghur text.
Ocr.Language = OcrLanguage.Uyghur;
// Create an OCR input object from a file. This can be an image or a PDF.
using (var Input = new OcrInput(@"images\Uyghur.png"))
{
// Perform text recognition on the input data.
var Result = Ocr.Read(Input);
// Extract the recognized text from the OCR result.
var AllText = Result.Text;
// Additional processing of AllText can be done here.
}using IronOcr;
var Ocr = new IronTesseract();
// Set the OCR language to Uyghur. This is necessary to correctly read Uyghur text.
Ocr.Language = OcrLanguage.Uyghur;
// Create an OCR input object from a file. This can be an image or a PDF.
using (var Input = new OcrInput(@"images\Uyghur.png"))
{
// Perform text recognition on the input data.
var Result = Ocr.Read(Input);
// Extract the recognized text from the OCR result.
var AllText = Result.Text;
// Additional processing of AllText can be done here.
}Imports IronOcr
Private Ocr = New IronTesseract()
' Set the OCR language to Uyghur. This is necessary to correctly read Uyghur text.
Ocr.Language = OcrLanguage.Uyghur
' Create an OCR input object from a file. This can be an image or a PDF.
Using Input = New OcrInput("images\Uyghur.png")
' Perform text recognition on the input data.
Dim Result = Ocr.Read(Input)
' Extract the recognized text from the OCR result.
Dim AllText = Result.Text
' Additional processing of AllText can be done here.
End Using$vbLabelText $csharpLabel





