Detect image is blur or not

asked 2020-02-12 23:22:56 -0600

snehal gravatar image

updated 2020-11-08 05:57:21 -0600

hello,

I want to detect the image is a blur or sharp depending on the threshold value. I am using OpenCV with C++. I used the Laplacian method to calculate the variance, compare this variance and one threshold value and I get the image is a blur or not. (For same image content )

But now the issue is this threshold value is not working for all images. when the image contents change the variance is going out of range. (It's obvious)

So I want one threshold value to differentiate image is blurry or Sharpe without depending on the content of images. Is there any method/algorithm/logic for this problem statement? Please give the suggetion.

edit retag flag offensive close merge delete

Comments

I don't know. Just an idea: _If_ we can make the assumption that all images that are analysed have some areas that have high contrast, then the image could be split into a grid and all cell analysed separately. Then, if you find one cell with good contrast, the image is not blurred.

mvuori gravatar imagemvuori ( 2020-02-13 02:09:02 -0600 )edit

use tag blur and may be use this answer

There is no answer to your problem with a single image : a cloud in the sky is it a blur image?

LBerger gravatar imageLBerger ( 2020-02-13 02:20:34 -0600 )edit