Windows OCR Motoru vs Tesseract: Ayrıntılı Bir Karşılaştırma
Bugünün dijital çağında, Optik Karakter Tanıma (OCR) teknolojisi, görüntü ve taranmış belgeleri düzenlenebilir ve aranabilir metne dönüştürmeyi mümkün kılan çeşitli endüstriler için vazgeçilmez bir hale gelmiştir.
Google Cloud Vision (Cloud Vision API), Adobe Acrobat Pro DC, ABBYY Finereader, Windows OCR Motoru, Tesseract ve IronOCR gibi birçok OCR yazılımı arasında, her biri belge analizine yardımcı olmak için benzersiz özellikler ve kabiliyetler sunan önemli yarışmacılar olarak öne çıkıyor.
Bu makale, bu üç OCR motorunun kapsamlı bir karşılaştırmalı analizini sunarak, doğruluk, performans ve entegrasyon kolaylıklarını değerlendirmeyi amaçlamaktadır.
1. OCR Motorlarına Giriş
OCR motorları, görüntüler, PDF'ler ve diğer taranmış belgelerden metin tanımak ve çıkarmak için tasarlanmış yazılım araçlarıdır. Yazılı karakterleri doğru bir şekilde tanımlamak ve bunları makine tarafından okunabilir bir metin dosyasına dönüştürmek için sofistike algoritmalar ve makine öğrenimi teknikleri kullanırlar. Windows OCR Motoru, Tesseract ve IronOCR, her biri kendi güçlü yönleri ve uygulamaları ile yaygın olarak kullanılan üç OCR çözümünü temsil eder.
2. Windows OCR Motoru
Windows OCR Motoru, Windows işletim sistemine entegre edilmiş, giriş görüntülerinden ve taranmış belgelerden metin çıkarma için uygun ve kullanıcı dostu bir çözüm sunar. Gelişmiş görüntü işleme tekniklerinden yararlanarak, çeşitli dillerde ve yazı tiplerinde metni doğru bir şekilde tanıyabilir. Windows OCR Motoru, Windows Runtime API aracılığıyla erişilebilir, bir komut satırı aracının yetenekleri ile Windows uygulamalarına sorunsuz entegrasyon sağlar.
2.1 Windows OCR Motoru'nun Temel Özellikleri
- Dil Desteği: Windows OCR Motoru, birden çok dile destek vererek, çok dilli belgeler için uygundur.
- Görüntü İşleme: Basılı metin tanıma doğruluğunu artırmak için sofistike görüntü işleme algoritmaları kullanır; düşük kaliteli görüntülerde bile.
- Windows Uygulamaları ile Entegrasyon: Windows OCR Motoru, Windows uygulamalarına sorunsuz entegrasyon sağlar, geliştiricilere yazılımlarına tamamen OCR yeteneklerini dahil etme imkanı verir.
2.2 Kod Örneği
using System;
using System.IO;
using System.Text;
using System.Threading.Tasks;
using Windows.Graphics.Imaging;
using Windows.Media.Ocr;
class Program
{
static async Task Main(string[] args)
{
// Provide the path to the image file
string imagePath = "sample.png";
try
{
// Call the ExtractText method to extract text from the image
string extractedText = await ExtractText(imagePath);
// Display the extracted text
Console.WriteLine("Extracted Text:");
Console.WriteLine(extractedText);
}
catch (Exception ex)
{
Console.WriteLine("An error occurred: " + ex.Message);
}
}
public static async Task<string> ExtractText(string image)
{
// Initialize StringBuilder to store extracted text
StringBuilder text = new StringBuilder();
try
{
// Open the image file stream
using (var fileStream = File.OpenRead(image))
{
// Create a BitmapDecoder from the image file stream
var bmpDecoder = await BitmapDecoder.CreateAsync(fileStream.AsRandomAccessStream());
// Get the software bitmap from the decoder
var softwareBmp = await bmpDecoder.GetSoftwareBitmapAsync();
// Create an OCR engine from user profile languages
var ocrEngine = OcrEngine.TryCreateFromUserProfileLanguages();
// Recognize text from the software bitmap
var ocrResult = await ocrEngine.RecognizeAsync(softwareBmp);
// Append each line of recognized text to the StringBuilder
foreach (var line in ocrResult.Lines)
{
text.AppendLine(line.Text);
}
}
}
catch (Exception ex)
{
Console.WriteLine("Error during OCR process: " + ex.Message);
}
// Return the extracted text
return text.ToString();
}
}
using System;
using System.IO;
using System.Text;
using System.Threading.Tasks;
using Windows.Graphics.Imaging;
using Windows.Media.Ocr;
class Program
{
static async Task Main(string[] args)
{
// Provide the path to the image file
string imagePath = "sample.png";
try
{
// Call the ExtractText method to extract text from the image
string extractedText = await ExtractText(imagePath);
// Display the extracted text
Console.WriteLine("Extracted Text:");
Console.WriteLine(extractedText);
}
catch (Exception ex)
{
Console.WriteLine("An error occurred: " + ex.Message);
}
}
public static async Task<string> ExtractText(string image)
{
// Initialize StringBuilder to store extracted text
StringBuilder text = new StringBuilder();
try
{
// Open the image file stream
using (var fileStream = File.OpenRead(image))
{
// Create a BitmapDecoder from the image file stream
var bmpDecoder = await BitmapDecoder.CreateAsync(fileStream.AsRandomAccessStream());
// Get the software bitmap from the decoder
var softwareBmp = await bmpDecoder.GetSoftwareBitmapAsync();
// Create an OCR engine from user profile languages
var ocrEngine = OcrEngine.TryCreateFromUserProfileLanguages();
// Recognize text from the software bitmap
var ocrResult = await ocrEngine.RecognizeAsync(softwareBmp);
// Append each line of recognized text to the StringBuilder
foreach (var line in ocrResult.Lines)
{
text.AppendLine(line.Text);
}
}
}
catch (Exception ex)
{
Console.WriteLine("Error during OCR process: " + ex.Message);
}
// Return the extracted text
return text.ToString();
}
}
Imports System
Imports System.IO
Imports System.Text
Imports System.Threading.Tasks
Imports Windows.Graphics.Imaging
Imports Windows.Media.Ocr
Friend Class Program
Shared Async Function Main(ByVal args() As String) As Task
' Provide the path to the image file
Dim imagePath As String = "sample.png"
Try
' Call the ExtractText method to extract text from the image
Dim extractedText As String = Await ExtractText(imagePath)
' Display the extracted text
Console.WriteLine("Extracted Text:")
Console.WriteLine(extractedText)
Catch ex As Exception
Console.WriteLine("An error occurred: " & ex.Message)
End Try
End Function
Public Shared Async Function ExtractText(ByVal image As String) As Task(Of String)
' Initialize StringBuilder to store extracted text
Dim text As New StringBuilder()
Try
' Open the image file stream
Using fileStream = File.OpenRead(image)
' Create a BitmapDecoder from the image file stream
Dim bmpDecoder = Await BitmapDecoder.CreateAsync(fileStream.AsRandomAccessStream())
' Get the software bitmap from the decoder
Dim softwareBmp = Await bmpDecoder.GetSoftwareBitmapAsync()
' Create an OCR engine from user profile languages
Dim ocrEngine = OcrEngine.TryCreateFromUserProfileLanguages()
' Recognize text from the software bitmap
Dim ocrResult = Await ocrEngine.RecognizeAsync(softwareBmp)
' Append each line of recognized text to the StringBuilder
For Each line In ocrResult.Lines
text.AppendLine(line.Text)
Next line
End Using
Catch ex As Exception
Console.WriteLine("Error during OCR process: " & ex.Message)
End Try
' Return the extracted text
Return text.ToString()
End Function
End Class
2.2.1 Çıktı

3. Tesseract
Tesseract, Google tarafından geliştirilen açık kaynaklı bir OCR motoru olup, doğruluğu ve çok yönlülüğü ile geniş kabul görmüştür. Yüzden fazla dili destekler ve TIFF, JPEG ve PNG dahil çeşitli görüntü formatlarını işleyebilir. Tesseract OCR Motoru, yüksek düzeyde metin tanıma doğruluğu elde etmek için derin öğrenme algoritmaları ve sinir ağları kullanır, bu da onu çok çeşitli uygulamalar için uygun hale getirir.
3.1 Tesseract'ın Temel Özellikleri
- Dil Desteği: Tesseract motoru, Arapça ve Çince gibi karmaşık yazımlar dahil olmak üzere yüzden fazla dili destekler.
- Görüntü Ön İşleme: Tesseract, metin tanımama doğruluğunu artırmak için deskewing, ikili hale getirme ve gürültü azaltma gibi kapsamlı görüntü ön işleme yetenekleri sunar.
- Özelleştirme Seçenekleri: Tesseract, kullanıcıların OCR parametrelerini ince ayar yapmasına ve belirli kullanım durumları için özel modeller eğitmesine olanak tanır, bu da doğruluğu ve performansı artırır.
3.2 Kod Örneği
using Patagames.Ocr;
class TesseractExample
{
static void Main(string[] args)
{
// Create an OCR API instance
using (var api = OcrApi.Create())
{
// Initialize the OCR engine for the English language
api.Init(Patagames.Ocr.Enums.Languages.English);
// Extract text from the image
string plainText = api.GetTextFromImage(@"C:\Users\buttw\source\repos\ironqr\ironqr\bin\Debug\net5.0\Iron.png");
// Display the extracted text
Console.WriteLine(plainText);
}
}
}
using Patagames.Ocr;
class TesseractExample
{
static void Main(string[] args)
{
// Create an OCR API instance
using (var api = OcrApi.Create())
{
// Initialize the OCR engine for the English language
api.Init(Patagames.Ocr.Enums.Languages.English);
// Extract text from the image
string plainText = api.GetTextFromImage(@"C:\Users\buttw\source\repos\ironqr\ironqr\bin\Debug\net5.0\Iron.png");
// Display the extracted text
Console.WriteLine(plainText);
}
}
}
Imports Patagames.Ocr
Friend Class TesseractExample
Shared Sub Main(ByVal args() As String)
' Create an OCR API instance
Using api = OcrApi.Create()
' Initialize the OCR engine for the English language
api.Init(Patagames.Ocr.Enums.Languages.English)
' Extract text from the image
Dim plainText As String = api.GetTextFromImage("C:\Users\buttw\source\repos\ironqr\ironqr\bin\Debug\net5.0\Iron.png")
' Display the extracted text
Console.WriteLine(plainText)
End Using
End Sub
End Class
3.2.1 Çıktı

4. IronOCR
IronOCR, Iron Software tarafından geliştirilen güçlü bir OCR motoru olup, olağanüstü doğruluğu, kullanım kolaylığı ve çok yönlü dil desteği ile ayrılır. Yerinde OCR işlevselliği sunar ve küresel uygulamalar için uygun olan 125'ten fazla dili destekler. IronOCR, zorlu senaryolarda bile kesin metin tanıma sonuçları sunmak için gelişmiş makine öğrenimi algoritmalarından ve bulut görsel teknoloji'lerinden yararlanır.
4.1 IronOCR'nin Anahtar Özellikleri
- Yüksek Doğruluk: IronOCR, çeşitli belge türleri ve dillerde güvenilir sonuçlar garanti ederek sektörde lider doğruluk sağlar.
- Çok Yönlü Dil Desteği: 125'ten fazla dili destekler ve dört dörtlük çok dilli metin tanıma için kapsamlı dil paketleri sunar.
- Basit Entegrasyon: IronOCR, .NET uygulamaları ile kolay entegrasyon sunar; intuitive API'ler ve geliştirme sürecini basitleştirmek için kapsamlı belgelerle, orijinal görüntüleri metinleri çıkarmak için ön işleme ve sonrası işlemeyle.
4.2 IronOCR'yi Yükleyin
Kod örneğine geçmeden önce, NuGet Paket Yöneticisi kullanarak IronOCR'yi nasıl yükleyeceğimizi görelim.
- Visual Studio'da Araçlar Menüsüne gidin ve NuGet Paket Yöneticisi'ni Seçin.
- Yeni bir liste görünecek, burada çözümler için NuGet Paket Yöneticisi'ni seçin.

- Yeni bir pencere açılacak, 'Gözat' sekmesine gidin ve arama çubuğuna 'IronOCR' yazın.
- Bir paket listesi görünecek. En son IronOCR paketini seçin ve üzerine tıklayarak yükleyin.

4.3 Kod Örneği (C#)
using IronOcr;
class IronOCRExample
{
static void Main(string[] args)
{
// Create an IronTesseract instance
var ocr = new IronTesseract();
// Set the language for OCR recognition
ocr.Language = OcrLanguage.English;
// Perform OCR on the specified image
var result = ocr.Read(@"C:\Users\buttw\source\repos\ironqr\ironqr\bin\Debug\net5.0\Iron.png");
// Display the extracted text
Console.WriteLine(result.Text);
}
}
using IronOcr;
class IronOCRExample
{
static void Main(string[] args)
{
// Create an IronTesseract instance
var ocr = new IronTesseract();
// Set the language for OCR recognition
ocr.Language = OcrLanguage.English;
// Perform OCR on the specified image
var result = ocr.Read(@"C:\Users\buttw\source\repos\ironqr\ironqr\bin\Debug\net5.0\Iron.png");
// Display the extracted text
Console.WriteLine(result.Text);
}
}
Imports IronOcr
Friend Class IronOCRExample
Shared Sub Main(ByVal args() As String)
' Create an IronTesseract instance
Dim ocr = New IronTesseract()
' Set the language for OCR recognition
ocr.Language = OcrLanguage.English
' Perform OCR on the specified image
Dim result = ocr.Read("C:\Users\buttw\source\repos\ironqr\ironqr\bin\Debug\net5.0\Iron.png")
' Display the extracted text
Console.WriteLine(result.Text)
End Sub
End Class
4.3.1 Çıktı

5. Karşılaştırmalı Değerlendirme
5.1 Doğruluk ve Performans
- Windows OCR Motoru ve Tesseract makul doğruluk sağlar ancak karmaşık düzenlerle mücadele edebilir.
- IronOCR: Doğrulukta mükemmeldir, gürültülü görüntüler dahil çeşitli belge türleri ve dillerde güvenilir sonuçlar sunar.
5.2 Entegrasyon Kolaylığı
- Windows OCR Motoru: Windows uygulamalarıyla sorunsuz bir şekilde entegre olur ancak özelleştirme seçeneklerinden yoksundur.
- Tesseract: Entegrasyon için ek yapılandırma ve bağımlılık gerektirir ancak kapsamlı özelleştirme seçenekleri sunar.
- IronOCR: Sezgisel API'ler ve kapsamlı belgeleme ile .NET uygulamalarıyla basit entegrasyon sağlar.
5.3 Dil Desteği
Windows OCR Motoru Tesseract ve IronOCR'a kıyasla sınırlı sayıda dili destekler.
- Tesseract: 100'den fazla dil için destek sunar. IronOCR: Küresel uygulamalar için uygun hale getiren ve 125'in üzerinde dil desteği sağlayan bir araçtır.
6. Sonuç
Sonuç olarak, Windows OCR Engine ve Tesseract metin tanıma için popüler seçimler olsalar da, IronOCR en doğru ve çok yönlü OCR motoru olarak öne çıkar. Sektör lideri doğruluğu, kapsamlı dil desteği ve basit entegrasyonu, güvenilir OCR fonksiyonelliği arayan işletmeler ve geliştiriciler için öne çıkan bir çözüm haline getirir. IronOCR kullanarak, organizasyonlar belge işleme iş akışlarını kolaylaştırabilir, veri çıkarım doğruluğunu artırabilir ve taranmış belgeler ve görüntülerden değerli içgörüler elde edebilir.
IronOCR bir ücretsiz deneme sunar. IronOCR ve özellikleri hakkında daha fazla bilgi almak için buraya tıklayın.




