MATLAB Answers

How to calculate image intensities of two different images for differentiation purposes

7 views (last 30 days)
Haseeb Hassan
Haseeb Hassan on 9 Jan 2020
Commented: Selva Karna on 13 Jan 2020
Hi everyone,
I have an input image, i have processed the same orignal image (input) by applying some contrast based algorithm. After that i applied the max operator to each image (oringnal image and processed image) for the extraction of highest pixels values which can be known as bright channel of the image. After calculating the bright channels of each orignal image and processed image now i want to calcultae the intensity of the each image to decide which image has more intensity or have more number of bright pixel. One of the method which i already know is the histogram calculation. I am interested for some another method as because in histogram i can not decide which one have more brighten. Or what is the best way by using the histogram method from which we can easily diffrentiate the high intensity image..Here i am providing the code and images. The code and all the images are attached.
Thanks in advance!

  0 Comments

Sign in to comment.

Answers (1)

Selva Karna
Selva Karna on 9 Jan 2020
share your image?

  4 Comments

Show 1 older comment
Selva Karna
Selva Karna on 10 Jan 2020
image_folder='your images';
filepath=fullfile(image_folder,'*jpeg');
jpegfile=dir(filepath);
flen=length(jpegfile);
for k=1:flen
basefile=jpegfile(k).name;
fullfilename=fullfile(image_folder,basefile);
image=imread(fullfilename);
imag_inten(k)=max(image(:));
%% as struct formate
img_inten{k}=imag_inten;
end
Haseeb Hassan
Haseeb Hassan on 10 Jan 2020
Thank you so much for your time and help. I think your code is just trying to find the highest intensity value in the whole image, which is probably not my requirements. I want to compare the two images intensities, and want to decide which image has more pixels intensities. I will suggest you kindly read my question again and help me accordingly.
Once again a humble thanks for your kind response!

Sign in to comment.

Community Treasure Hunt

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

Start Hunting!