Code for Multimodal Histogram Segmentation of images
2 次查看(过去 30 天)
显示 更早的评论
This is the code that I found on Multimodal histogram segmentation... I ran the code but however I have 2 doubts..
1. How do we form a loop to run steps 2 through 4.
2. Where is our final segmented output image
% 1)Select an initial estimate for T T = 128; T0 = .5;
% 2)Segment the image using T. This will produce two % groups of pixels. G1 consisting of all pixels with gray % level values >T and G2 consisting of pixels with values <=T.
G1 = grayImage > T; G2 = grayImage <= T;
% 3)Compute the average gray level values mean1 and % mean2 for the pixels in regions G1 and G2.
meanGL1 = mean(grayImage(G1)) meanGL2 = mean(grayImage(G2))
% 4)Compute a new threshold value
Tnew=(1/2) * (meanGL1 +meanGL2)
if (Tnew - T) < T0 then run steps 2 through 4 until (Tnew - T) > T0
Some one plzzz help...its urgent
0 个评论
回答(1 个)
Sean de Wolski
2014-10-15
doc multithresh
doc imquantize
2 个评论
Sean de Wolski
2014-10-17
If you run those two commands, they will lead you to the documentation for the functions in MATLAB that find thresholds and apply them to images.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Histograms 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!