how to calculate entropy of colored image?

how to calculate entropy of colored image?

1 Comment

You can calculate entropy for each color channel separately.

Sign in to comment.

Answers (2)

A. P. B.
A. P. B. on 23 Jun 2017
Edited: A. P. B. on 23 Jun 2017
Assuming input_image is the name of the input. Entropy of each channel can be found using : Entropy_Red_Channel=Entropy(input_image(:,:,1)).
For each channel R,G and B you can calculate them separately. You can calculate entropy for multidimensional image but the function entropy will consider each of them as gray scale not RGB. Finally you can average the per channel entropy.
Unless you account for the mutual information between channels, the solutions posted here will overestimate the total entropy.

2 Comments

How can you take into consideration the mutual information between channels?
https://en.wikipedia.org/wiki/Mutual_information#Relation_to_conditional_and_joint_entropy
The calculations include many more terms as you increase the number of channels.

Sign in to comment.

Asked:

on 29 Dec 2015

Commented:

on 23 Oct 2018

Community Treasure Hunt

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

Start Hunting!