Creating a 5*5 window around the initial seed point in a region growing algorithm?
2 views (last 30 days)
I am trying to implement a region growing algorithm to segment tumor in gastric. I would select the initial seed point manually. Then a 5*5 window would be created around the initial seed point. The minimum value inside the window would be selected as the first seed point of the region growing algorithm. Another new 5*5 window would be created around the the first seed point and the algorithm would be applied within that window. My problem is that I am unable to create the window around the initial seed point. I tried the code below but I don't get the correct result. The original image is attached as Original_Image.png and the tumor region would supposedly look as shown in Tumor.png. Any suggestions would be helpful. Thank you.
% gg = uint8(255 * mat2gray(i));
seg = region_seg(m, bw, 30);