python - 去除验证码干扰线用什么算法好
大家讲道理
大家讲道理 2017-04-17 17:51:25
0
1
966

去除诸如以上验证码干扰线,采用 灰度图 → rof算法 → ImageEnhance.Sharpness → 二值图 产生如下效果

部分孤立噪点难以去除干净,这也对tesseract的识别产生影响,上面的方式只有30%识别率。

大家讲道理
大家讲道理

光阴似箭催人老,日月如移越少年。

reply all(1)
小葫芦

For this kind of verification code:
1. The interference line is thin, only about 1px-2px
2. The font is thicker than the interference line

You can filter points like this after binarization:
1. There are less than 2 1 points among the 8 surrounding points

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template