imequalize
result = imequalize(img)
Input: img · Output: result
What it is
img is an Image of any size. Histogram equalisation, spreading the intensities to fill the range (identical operation to histeq above). Reveals detail in a flat image and exaggerates noise in a clean one.
Overloads
One call shape — this function is not overloaded.
| Code | Input | Output | Description |
result = imequalize(img) | img Imagenot documented yet | result Image | Returns a new Image, same dimensions as img. |
Examples
From the documentation, and run by the build -- the output and the figure below are what the engine actually produced. Simplest first.
m = [80, 90, 85, 95; 88, 92, 84, 91; 86, 89, 93, 87; 90, 85, 88, 92]
img = image_from_matrix(m)
eq = histeq(img)
eq2 = imequalize(img) # same result, other name
imshow(eq)
noisy_g = imnoise(img, "gaussian", sigma=0.05, seed=1)
noisy_sp = imnoise(img, "salt_pepper", density=0.1, seed=2)
imshow(noisy_sp)
print(eq.width, eq2.width, noisy_g.width, noisy_sp.width)
4 4 4 4
from images
How it works
and synthetic noise (§ contrast/rotation/noise pass, 2026-08-24). See image::Image's own doc comments (the "Contrast/intensity adjustment..." section, right after label_components) for the full per-function algorithm and design-decision writeups this comment block only summarizes. imequalize(img) (alias histeq) — global histogram equalization: RGB-preserving via BT.601-luma CDF remapping, NOT a grayscale-only fallback (the higher-quality option this feature was asked to prefer when time allowed).
From the note above this builtin in the interpreter, where the reasoning was written down as it was built.