在生產環境中測試且無浮水印。
在您需要的地方運行。
獲得30天的全功能產品。
在幾分鐘內啟動並運行。
您的產品試用期間可完全接觸我們的支援工程團隊
改善低品質掃描和照片的輸入。使用我們的預處理濾鏡來清潔、拉直和增強困難的圖像,以達到最大的OCR精度。
在IronOCR中輕鬆二值化您的輸入,將圖像轉換為清晰的黑白版本。這個濾鏡有效地將文字從複雜的背景中隔離出來,降低噪聲,使文字提取更輕鬆、更可靠。
瞭解如何使用:修正.NET C#中的閱讀圖像顏色using IronOcr;
// Instantiate IronTesseract
IronTesseract ocrTesseract = new IronTesseract();
// Add image
using var imageInput = new OcrImageInput("sample.jpg");
// Apply binarize affect
imageInput.Binarize();
// Export the modified image
imageInput.SaveAsImages("binarize.jpg");
將彩色圖像轉換為灰度 - 是為更先進的預處理濾鏡準備圖像的重要步驟。
瞭解如何使用:修正.NET C#中的閱讀圖像顏色using IronOcr;
// Instantiate IronTesseract
IronTesseract ocrTesseract = new IronTesseract();
// Add image
using var imageInput = new OcrImageInput("sample.jpg");
// Apply grayscale affect
imageInput.ToGrayScale();
// Export the modified image
imageInput.SaveAsImages("grayscale.jpg");
替換圖像中的特定顏色范圍,使您可以在OCR之前去除水印、彩色背景或其他分心元素。
瞭解如何使用:修正.NET C#中的閱讀圖像顏色using IronOcr;
// Instantiate IronTesseract
IronTesseract ocrTesseract = new IronTesseract();
// Add image
using var imageInput = new OcrImageInput("sample.jpg");
IronSoftware.Drawing.Color currentColor = new IronSoftware.Drawing.Color("#DB645C");
IronSoftware.Drawing.Color newColor = IronSoftware.Drawing.Color.DarkCyan;
// Replace color
imageInput.ReplaceColor(currentColor, newColor, 80);
// Export the modified image
imageInput.SaveAsImages("replaceColor");
加厚圖像中的字元,這有助於連接文字中的斷線,提高對淡或細字體的識別。
瞭解如何使用:使用濾鏡修正圖像以供閱讀using IronOcr;
// Instantiate IronTesseract
IronTesseract ocrTesseract = new IronTesseract();
// Add image
using var imageInput = new OcrImageInput("sample.jpg");
// Apply Dilate filter
imageInput.Dilate();
// Export filtered image
imageInput.SaveAsImages("dilate.jpg");
削弱圖像中的字元,這對分隔接觸或混合的字元很有用。
瞭解如何使用:使用濾鏡修正圖像以供閱讀using IronOcr;
// Instantiate IronTesseract
IronTesseract ocrTesseract = new IronTesseract();
// Add image
using var imageInput = new OcrImageInput("sample.jpg");
// Apply Erode filter
imageInput.Erode();
// Export filtered image
imageInput.SaveAsImages("erode.jpg");
替換圖像中的特定顏色范圍,使您可以在OCR之前去除水印、彩色背景或其他分心元素。
瞭解如何使用:修正.NET C#中的閱讀圖像顏色using IronOcr;
// Instantiate IronTesseract
IronTesseract ocrTesseract = new IronTesseract();
// Add image
using var imageInput = new OcrImageInput("sample.jpg");
IronSoftware.Drawing.Color currentColor = new IronSoftware.Drawing.Color("#DB645C");
IronSoftware.Drawing.Color newColor = IronSoftware.Drawing.Color.DarkCyan;
// Replace color
imageInput.ReplaceColor(currentColor, newColor, 80);
// Export the modified image
imageInput.SaveAsImages("replaceColor");
自動檢測和拉直傾斜或歪斜的圖像,極大地提高了對不完美掃描的OCR準確率。
瞭解如何使用:修正.NET C#中的閱讀圖像方向using IronOcr;
// Instantiate IronTesseract
IronTesseract ocrTesseract = new IronTesseract();
// Add image
using var imageInput = new OcrImageInput("paragraph_skewed.png");
// Apply Deskew filter
imageInput.Deskew();
以任何角度程式化旋轉圖像,以確保文字正確定向供OCR引擎使用。
瞭解如何使用:修正.NET C#中的閱讀圖像方向using IronOcr;
// Instantiate IronTesseract
IronTesseract ocrTesseract = new IronTesseract();
// Add image
using var imageInput = new OcrImageInput("paragraph_skewed.png");
// Rotate the image 180 degrees clockwise
imageInput.Rotate(180);
// Export the modified image
imageInput.SaveAsImages("rotate");
自動確定頁面方向(0、90、180、270度),這在OCR之前的方向矯正中很有用。即使文件是上下顛倒掃描的,也能保證高精度。
瞭解如何使用:檢測頁面旋轉using IronOcr;
using var input = new OcrInput();
// Load PDF document
input.LoadPdf("Clockwise90.pdf");
// Detect page rotation
var results = input.DetectPageOrientation();
// Ouput result
foreach(var result in results)
{
Console.WriteLine(result.PageNumber);
Console.WriteLine(result.HighConfidence);
Console.WriteLine(result.RotationAngle);
}
將圖像重新設置為OCR的最佳解析度,顯著提高低解析度原始文件的準確性。
瞭解如何使用:修正.NET C#中的閱讀圖像方向using IronOcr;
// Instantiate IronTesseract
IronTesseract ocrTesseract = new IronTesseract();
// Add image
using var imageInput = new OcrImageInput("paragraph_skewed.png");
// Apply scale
imageInput.Scale(70);
// Export the modified image
imageInput.SaveAsImages("rotate");
手動設置低解析圖像或缺少元資料的掃描的每英寸點數(DPI)。提供DPI值可引導OCR引擎,顯著提高識別質量。
瞭解如何使用:C# Tesseract圖像DPIusing IronOcr;
using System;
var ocrTesseract = new IronTesseract();
using var ocrInput = new OcrInput();
ocrInput.TargetDPI = 300;
ocrInput.LoadImage(@"images\image.png");
var ocrResult = ocrTesseract.Read(ocrInput);
Console.WriteLine(ocrResult.Text);
通過算法有效提高低解析度圖像的清晰度和清晰度,以從模糊或像素化的輸入中恢復文字。
瞭解如何使用:使用濾鏡修正圖像以供閱讀using IronOcr;
// Instantiate IronTesseract
IronTesseract ocrTesseract = new IronTesseract();
// Add image
using var imageInput = new OcrImageInput("sample.jpg");
// Apply enhance resolution filter
imageInput.EnhanceResolution();
// Export filtered image
imageInput.SaveAsImages("sharpen.jpg");
使用一個智能方法應用預處理濾鏡的精選鏈。 濾鏡向導會自動分析輸入圖像並應用最佳的更正序列以達到最佳的OCR結果。
瞭解如何使用:濾鏡嚮導using IronOcr;
var ocrTesseract = new IronTesseract();
// WIZARD - If you are unsure which filters to use,
// use the debug-wizard to test all combinations:
string codeToRun = OcrInputFilterWizard.Run(@"images\image.png", out double confidence, ocrTesseract);
Console.WriteLine($"Confidence: {confidence}");
Console.WriteLine(codeToRun);
通過僅針對包含文字的圖像的特定區域來節省處理時間。 只需定義一個矩形區域即可從表單、表格或雜亂背景中隔離並提取文字。
瞭解如何使用:在C#中指定圖像區域的Tesseract OCRusing IronOcr;
using IronSoftware.Drawing;
var ocrTesseract = new IronTesseract();
using var ocrInput = new OcrInput();
var ContentArea = new Rectangle(x: 215, y: 1250, width: 1335, height: 280);
ocrInput.LoadImage("img/example.png", ContentArea);
var ocrResult = ocrTesseract.Read(ocrInput);
Console.WriteLine(ocrResult.Text);