i.colors.enhance(1)
β¨ i.colors.enhance β¨ (the GRASS GIS User's Manual era) π
okay bestie, gather round, because this is the manual page for i.colors.enhance, and she is that girl π
NAME
i.colors.enhance β Performs auto-balancing of colors for RGB images. π¦
KEYWORDS
imagery, RGB, satellite, colors π
πΈ SYNOPSIS πΈ
i.colors.enhance
i.colors.enhance --help
i.colors.enhance [-fprs] red=name green=name blue=name [strength=float]
[--help] [--verbose] [--quiet] [--ui]
π Flags:
-fβ Extend colors to full range of data on each channel π₯-pβ Preserve relative colors, adjust brightness only β¨-rβ Reset to standard color range π-sβ Process bands serially (default: run in parallel) π’--helpβ Print usage summary π--verboseβ Verbose module output π£οΈ--quietβ Quiet module output π€«--uiβ Force launching GUI dialog π₯οΈ
π Parameters:
red=name[required] β Name of red channel πgreen=name[required] β Name of green channel π§blue=name[required] β Name of blue channel πstrength=floatβ Cropping intensity (upper brightness level) βοΈ- Options:
0-100 - Default:
98
- Options:
π« DESCRIPTION π«
i.colors.enhance auto-balances and enhances the color channels of a RGB image (e.g. from Landsat) to provide a more natural color mixture. Only the color table of each image band is modified, the base data remains untouched. π«Ά no cap, your actual pixels are safe.
The module works by calculating a histogram for each color channel and removing an adjustable amount of outliers from either end before recalibrating the color scale with r.colors. πβ¨
It will work with any 8-bit RGB imagery set and the script is easily modified to work with other datasets of greater band-depth. π
π NOTES π
Depending on the image, it may or may not be advantageous to use the -p flag to preserve the relative color scaling. You will have to experiment with the different options to find a setting that works best for your particular imagery. π¬ lowkey a vibe-check-your-own-data situation.
The strength option should generally be set in the 90-99 range. The lower the number, the more saturated the image becomes. It represents the percentage cut-off for the top end of the color histogram curve. The lower end is fixed at 2% of the area under the curve. ππ
For quicker execution of this module on large images you can achieve largely similar results by switching to a coarser resolution before the running of the module (using g.region) and then back to the original resolution afterwards. πβοΈπ¨
π EXAMPLE π
North Carolina sample dataset example with Landsat data: π°οΈ
g.region raster=lsat7_2002_10 -p
d.rgb blue=lsat7_2002_10 green=lsat7_2002_20 red=lsat7_2002_30
d.barscale at=55.3125,93.125 bcolor=white text_pos=over
i.colors.enhance blue=lsat7_2002_10 green=lsat7_2002_20 red=lsat7_2002_30 strength=95
d.rgb blue=lsat7_2002_10 green=lsat7_2002_20 red=lsat7_2002_30
d.barscale at=55.3125,93.125 bcolor=white text_pos=over
Uncorrected RGB composite of Landsat ETM channels B/G/R π
Color corrected RGB composite of Landsat ETM channels B/G/R π the glow-up is REAL
π§ TODO π§
The strength option requires further refinement. π οΈ she's a work in progress, bestie.
π SEE ALSO π
d.rgbg.regioni.oifr.colorsr.compositer.univar
π AUTHORS π
- Markus Neteler, Trento, Italy
- M. Hamish Bowman, Dept. Marine Science, Otago University, New Zealand
π§ SOURCE CODE π§
Available at: i.colors.enhance source code (history) π
Accessed: Saturday Jan 17 05:41:52 2026 β°
Main index | Imagery index | Topics index | Keywords index | Graphical index | Full index ποΈ
π and that's the whole page, bestie. GRASS 8.4.2, Β© 2003-2025 GRASS Development Team, straight outta the GRASS GIS 8.4.2 Reference Manual β go balance some colors, you absolute icon, periodt. π β¨πΈ
π¦ where this page comes from
- fedora 44: grass 8.4.2-4.fc44 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms