使用OCR识别的文本对图像进行模糊处理 [英] Deblur image with text to be recognized by OCR

查看:479
本文介绍了使用OCR识别的文本对图像进行模糊处理的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个模糊的图像:
这是名片的一部分,是相机拍摄的没有适当聚焦的镜框之一.

I have an image which is blurred:
This is a part of the business card and it is one of the frames taken by the camera and without proper focus.

清晰的图像看起来像这样 我正在寻找可以为我提供质量更好的图像的方法,以使图像可以被OCR识别,但也应该非常快.图像不会太模糊(我认为是),但对OCR不利.我试过了:

The clear image looks like this I'm looking for the method which could give me an image of better quality, so that image could be recognized by OCR, but also should be quite fast. Image is not blurred too much (I think so) but isn't good for OCR. I tried:

  • 各种HPF,
  • 拉普拉斯语
  • Canny检测器
  • 形态学操作的组合(打开,关闭).

我也尝试过:

  • 使用维纳滤波器进行反卷积
  • 反卷积和Lucy-Richardson方法.

但是要找到正确的PSF(点扩展功能)并不容易.这些方法被认为是有效的,但是不够快.我还尝试了FFT,然后尝试使用高斯掩码进行IFFT,但结果并不令人满意.我正在寻找一种将文本与图像去模糊的通用方法,不仅限于此图像.有人可以帮我解决这个问题吗?如有任何建议,我将不胜感激.我正在使用OpenCV 3(C ++,有时是Python).

But it was not easy to find the right PSF (Point Spread Function). These methods are considered effective, but not so fast enough. I also tried FFT and then IFFT with a Gaussian mask, but results were not satisfactory. I'm looking for some kind general method of deblurring images with text, not only this image. Could someone help me with this problem? I'll be grateful for any advice. I'm working with OpenCV 3 (C++ and sometimes Python).

推荐答案

您是否了解盲解卷积?

盲卷积是恢复天文图像的一项众所周知的技术.这对于难以找到PSF的应用程序特别有用.

Blind deconvolution is a well-known technique in restoring astronomical images. This is specially useful for your application, where finding a PSF is difficult.

此处是该技术的一种C ++实现.这份> 纸也与您要寻找的东西非常相关.这是他们算法的示例输出:

Here is one C++ implementation of this technique. This paper is also very related to what you are looking for. Here is a sample output of their algorithm:

这篇关于使用OCR识别的文本对图像进行模糊处理的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆