Mammogram - Detecting Skin Line need help

2 次查看(过去 30 天)
ws
ws 2011-10-7
Hi
I'm trying to find the skin line from the mammogram and replace the pixel to remove unwanted area.
Below is my code to replace pixels, and metrix y is count from right because image is from right view:
-------------------------------------------------
for i=1:x
for j=y:-1:1
if (LMLO_result(i,j)==255)
LMLO_result(i,j:1024)=255;
LMLO_result(i,1:j)=0;
end
end
end
-------------------------------------------------
Question:
1. Why the pixel looks like replaced from left to right? Since metrix y counted from right.
2. Why some black pixels with cover over white pixels?
Thank you.

回答(1 个)

Sean de Wolski
Sean de Wolski 2011-10-7
1) It may start from right to left, but it traverses all of the way across. Thus the furthest left point turns everything to the right white.
2) I'm not sure to the answer of your second question. Post the original binary image as a standalone file so we can run it.
Why are you setting the values to 255? Why not just use logicals (0/1) since there appear to only be two colors:
result = logical(cumsum(original,2));
Everything after the first true to the right will be white (1, i.e. logical true) everything else, to the left of the first true will be left black (0, i.e. logical false)
  1 个评论
ws
ws 2011-10-7
Thanks for your reply. I have fix my problem :)
BTW, may I ask you another question?
How to differenciate the input mammogram is left or right side view by using mean?
For example:
Mean_right=mean (RMLO) %right side view
Mean_Left=mean (LMLO) %left side view
If Mean_Left> Mean_right then mammogram is LMLO & (Mask1=LMLO),View=Left
Else given mammogram is RMLO & (Mask1=RMLO),View=Right
Thank you.

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 AI for Signals 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by