Difference of Gaussian vs LoG

5 views (last 30 days)
RuiQi
RuiQi on 9 Apr 2016
Edited: RuiQi on 9 Apr 2016
Hello
I am trying to approximate the log using the dog but i am not getting the right results. The notes here mention that it can be approximated by setting the sigma as shown below. I did a surf plot of the log and dog i constructed but they were not close. Also, the log generated by fspecial does not sum up to zero.
sigma = 5;
sigma1 = sigma/sqrt(2);
sigma2 = sigma*sqrt(2);
LoG = fspecial('log', 2*floor(3*sigma)+1, sigma);
% Generate LoG
DoG1 = fspecial('gaussian', 2*floor(3*sigma1)+1, sigma1);
DoG2 = fspecial('gaussian', 2*floor(3*sigma2)+1, sigma2);
DoG = DoG1 - DoG2;
I hope someone can help me on this

Answers (0)

Categories

Find more on MATLAB in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!