Saturday 10 October 2015

image processing - How is the Laplacian used for Unsharp Mask?


Some unsharp algorithms (e.g. Matlab's fspecial) use a Laplacian kernel to achieve sharpening of the image.


From what I know, the image needs to be blurred first, and then the blurred image is subtracted from the original to get a sharper image. The Laplacian part comes exactly where alleged smoothing should take place. Correct me if I'm wrong, but Laplacian doesn't do any smoothing.


So how does the Laplacian help in sharpening the image?



Answer



The regular sharpening i.e. high pass filter, essentially applies the inverse filter of blurring.


Basically, when you do unsharp masking - instead of subtracting the blurred image, you add the edge image as a portion of it. we can have $g(x,y)$


$$g(x,y)=f(x,y)-f_{smooth}(x,y)$$



which is nothing but an edge image using LoG.


The sharp image is produced by adding portion of this is added back to original image and hence contrast near edge increases drastically. This is how you produce the sharp image $f_{sharp}$


$$f_{sharp}(x,y)=f(x,y)+k*g(x,y)$$


Courtesy http://homepages.inf.ed.ac.uk/rbf/HIPR2/unsharp.htm.


More details are given in that page.


No comments:

Post a Comment

readings - Appending 内 to a company name is read ない or うち?

For example, if I say マイクロソフト内のパートナーシップは強いです, is the 内 here read as うち or ない? Answer 「内」 in the form: 「Proper Noun + 内」 is always read 「ない...