Calculating the amount of blurriness on glass image
조회 수: 2 (최근 30일)
이전 댓글 표시
Hello all. I need a help regarding the calculation of blurriness on the glass. Actually, I have to estimate the amount of fog present on the glass in a gray image which in otherwords called as blurriness. For this I have two images out of which one is with fog on glass and the other is without fog on glass.
I tried image subtraction method but it does not seem to give the difference image perfectly. Please help me in the methods or steps that I should follow in order to get the image showing the difference in intensity pixels and also in calculating the amount of fog or blurriness present in the image.
Thanks in advance.
댓글 수: 0
답변 (2개)
Image Analyst
2017년 8월 9일
You're asking for us to give image analysis advice on an image but you didn't show us the image. But I don't have the crystal Ball Toolbox, so I don't know what your image looks like and can only give very general advice, which is to use a texture filter like stdfilt(), threshold it, and compute the area fraction. The SD image will be dark in blurry areas and bright in detailed areas.
sdImage = stdfilt(grayImage, true(5));
binaryImage = sdImage < somethresholdValue; % Whatever works, like 5 or 20 or whatever.
blurAreaFraction = nnz(binaryImage) / numel(binaryImage);
댓글 수: 3
Image Analyst
2017년 8월 9일
I don't know what a fog free glass looks like. If the glass is transparent, I suggest you use scattered light (darkfield, light coming in from a high angle and scattering off the glass into the lens). I ought to know - I image glass in my job (among dozens of other things).
참고 항목
카테고리
Help Center 및 File Exchange에서 Detection에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!