Does histogram equalization change the pixel intensity range? (16-bit)

72 views Asked by At

Currently, I am doing histogram equalization on a 16 bit image, would the range change from [0, 65536] after the process?

import numpy as np
hist, bins = np.histogram(img.flatten(), 65536, [0, 65536])  # Collect 16 bits histogram (65536 = 2^16)
1

There are 1 answers

0
maximus On

The range of pixel intensities would stay [0, 65536] due to the weight factor of 65536 in the transform map. More details in link below.

transform_map = np.floor(65536* chistogram_array).astype(np.uint8)

https://levelup.gitconnected.com/introduction-to-histogram-equalization-for-digital-image-enhancement-420696db9e43