c# - IronOCR (tesseract) unable to extract the data - Stack Overflow

I am using IronOCR to extract the content from a scanned image and trying to read the data as per need

I am using IronOCR to extract the content from a scanned image and trying to read the data as per need but I am unable to do so.

I am expecting the results to be

Name Of Student : HELLOUSER
Aadhar : 123456789

and other information as per need, I tried the following code but no luck

var ocr = new IronTesseract();

 using (var ocrInput = new OcrInput())
 {
     ocrInput.LoadImage(@"C:\Tools\stud.png");
     var ocrResult = ocr.Read(ocrInput);
     string[] lines = ocrResult.Text.Split('\n');

     foreach (string line in lines)
     {
         if (line.Contains(":"))
         {
             var parts = line.Split(':');
             Console.WriteLine($"Key: {parts[0]}, Value: {parts[1]}");
         }
     }
 }

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1744316083a4568189.html

相关推荐

  • c# - IronOCR (tesseract) unable to extract the data - Stack Overflow

    I am using IronOCR to extract the content from a scanned image and trying to read the data as per need

    7天前
    30

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信