Breast Density in Mammography Dicom Images

조회 수: 4 (최근 30일)
Ann G
Ann G 2019년 5월 15일
편집: Walter Roberson 2024년 7월 27일
Is there a way to extract the breast density of a mammography through Matlab code?
  댓글 수: 1
Adam Danz
Adam Danz 2019년 5월 15일
편집: Adam Danz 2019년 5월 15일
I've seen this come up several times in the forum. Browse the question/answers that appear in the link above.

댓글을 달려면 로그인하십시오.

채택된 답변

Said Pertuz
Said Pertuz 2019년 11월 14일
I hope is not too late an answer. Please take a look at the following tool:https://www.mathworks.com/matlabcentral/fileexchange/73360-breast-density-segmentation.
Beware that this implementation has been tested on digital mammograms (such as those from the INbreast dataset) and has not been tested on digitized mammograms (e.g. MIAS).
  댓글 수: 1
Ann G
Ann G 2019년 11월 15일
I have already found a software for breast density, but I will also like to try yours in order to compare the results.
I will let you know of the outcome.
Thank you very much!

댓글을 달려면 로그인하십시오.

추가 답변 (1개)

Doaa
Doaa 2024년 7월 27일
  댓글 수: 2
Doaa
Doaa 2024년 7월 27일
편집: Walter Roberson 2024년 7월 27일
% Load the mammogram image
img = imread('mammogram.jpg');
% Display the original image
figure;
imshow(img);
title('Original Mammogram Image');
% Convert the image to grayscale if it is not already
if size(img, 3) == 3
img = rgb2gray(img);
end
% Display the grayscale image
figure;
imshow(img);
title('Grayscale Mammogram Image');
% Apply median filter to reduce noise
filtered_img = medfilt2(img);
% Display the filtered image
figure;
imshow(filtered_img);
title('Filtered Mammogram Image');
% Binarize the image using a threshold
level = graythresh(filtered_img);
bw = imbinarize(filtered_img, level);
% Display the binary image
figure;
imshow(bw);
title('Binary Mammogram Image');
% Calculate the breast density
density = sum(bw(:)) / numel(bw) * 100;
% Display the breast density
fprintf('Breast density: %.2f%%\n', density);
% Classify the breast density
if density < 25
density_type = 'Fatty';
elseif density < 50
density_type = 'Scattered';
elseif density < 75
density_type = 'Heterogeneously dense';
else
density_type = 'Extremely dense';
end
fprintf('Breast density type: %s\n', density_type);
Doaa
Doaa 2024년 7월 27일
편집: Walter Roberson 2024년 7월 27일
% Load the mammogram image
img = imread('mammogram.jpg');
% Display the original image
figure;
imshow(img);
title('Original Mammogram Image');
% Convert the image to grayscale if it is not already
if size(img, 3) == 3
img = rgb2gray(img);
end
% Display the grayscale image
figure;
imshow(img);
title('Grayscale Mammogram Image');
% Apply median filter to reduce noise
filtered_img = medfilt2(img);
% Display the filtered image
figure;
imshow(filtered_img);
title('Filtered Mammogram Image');
% Binarize the image using a threshold
level = graythresh(filtered_img);
bw = imbinarize(filtered_img, level);
% Display the binary image
figure;
imshow(bw);
title('Binary Mammogram Image');
% Calculate the breast density
density = sum(bw(:)) / numel(bw) * 100;
% Display the breast density
fprintf('Breast density: %.2f%%\n', density);
% Classify the breast density
if density < 25
density_type = 'Fatty';
elseif density < 50
density_type = 'Scattered';
elseif density < 75
density_type = 'Heterogeneously dense';
else
density_type = 'Extremely dense';
end
fprintf('Breast density type: %s\n', density_type);

댓글을 달려면 로그인하십시오.

Community Treasure Hunt

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

Start Hunting!

Translated by