Finding the contrast ratio of a grayscale image
Show older comments
So as the title says, I want to find the contrast ratio of a grayscale image by Michelson contrast definition. I'm thankful for any help! I'm not sure how to do this. Am I supposed to find the max and min value in each columns or row or the whole matrix?
% Michelson contrast definition
% Imax : the largest value in the image's matrix
% Imin : the smallest value in the image's matrix
contrast = (Imax-Imin)(Imax+Imin)

Accepted Answer
More Answers (1)
royed
on 6 Sep 2020
0 votes
if the question is about just comapring the max and min in the images. You can find it quite simply by using (max(max(image)) and the same for the minimum which would return the pixel with the max and minimum intensity value.
Categories
Find more on Contrast Adjustment in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
