LocalHistogramEqualization (LHE)
LocalHistogramEqualization (LHE) spreads the brightness values of each pixel’s surroundings. Structures that differ only slightly from their immediate neighbourhood stand out – even when they lie in the same midtones as the rest of the image.
Purpose
| Task | Setting |
|---|---|
| emphasise large shapes and edges | large kernel |
| emphasise fine structure within the shapes | small kernel |
| both | two passes, first large, then small |
Principle
WhyLHE rather than a curve?
A curve acts globally: every pixel with the same value is changed in the same way, regardless of its position. LHE acts locally: for each pixel it looks at its surroundings (kernel) and spreads the brightness values there. Nebula filaments, veils and dark clouds often differ only slightly from their surroundings – exactly what LHE is made for.
The kernel size determines which structure size is emphasised. A kernel much larger than the structure emphasises not the structure but its surroundings.
Parameters
| Parameter | Effect | Typical range |
|---|---|---|
| Kernel Radius | size of the surroundings considered; determines the emphasised structure size | large: overall shapes; small: fine detail |
| Contrast Limit | limits the contrast gain; without it, massive noise amplification in uniform areas | 1.5–2.0 |
| Amount | blend with the original; 1.0 is usually too harsh | 0.1–0.4 |
| Histogram Resolution | levels of the local histogram (8 bit = 256, 10 bit = 1,024, 12 bit = 4,096); internal only, the image stays 32 bit | 8 bit |
| Circular Kernel | equal weighting in all directions; a square kernel favours diagonals and can create block patterns | enabled |
Operation
- Apply to a starless image or a luminance: stars would otherwise get halos and rims.
- Use the Real-Time Preview; judge the effect at 1:1.
- Raise the histogram resolution to 10 or 12 bit only when steps or bands appear in smooth areas – noticeably slower, especially with a large kernel.
- LHE makes noise more visible; denoise after LHE.
Typical applications
Two passes
Whytwo passes?
A large kernel emphasises entire shapes, a small one the fine structure within them. A single medium kernel achieves both only halfway.
| Pass | Kernel Radius | Contrast Limit | Amount | emphasises |
|---|---|---|---|---|
| 1 large-scale | 64–128 | 1.5–2.0 | 0.2–0.4 | large nebula shapes, filaments, edges |
| 2 fine | 16–32 | 1.5 | 0.1–0.2 | fine structure within the shapes |
Narrow filaments
For narrow, fibrous structures (e.g. supernova remnants such as the Veil Nebula) use smaller kernels: pass 1 with 48–64, pass 2 with 12–24. A large kernel would emphasise the surroundings of the fibres instead of the fibres themselves.
What a good result looks like
Typical errors
| Observation | Cause | Remedy |
|---|---|---|
| Effect too weak | Amount low | raise Amount in steps of 0.05 |
| Rims at edges, harsh look | Amount or Contrast Limit too high | lower Amount or Contrast Limit |
| Noise amplified in the background | Contrast Limit high | lower Contrast Limit; then AI-based noise reduction with separate strength for fine- and large-scale noise and for brightness and colour. Several light passes keep more detail than one strong pass. Open fundamentals → |
| Steps, bands in smooth areas | histogram too coarse | Histogram Resolution 10 or 12 bit |
| Block-like patterns | square kernel | enable Circular Kernel |
| Halos around stars | applied to an image with stars | apply to the starless image |
When to use it – and when not
| Good for | Better another tool |
|---|---|
| emphasising local contrast of nebula structures | shaping global contrast → Remaps tonal values along a freely shaped curve – for contrast, saturation, hue and for shifting individual tonal ranges. Acts globally; locally only with a mask. Open fundamentals → |
| bringing out fine structure in a luminance | raising structures only above the background → Remaps tonal values along a freely shaped curve – for contrast, saturation, hue and for shifting individual tonal ranges. Acts globally; locally only with a mask. Open fundamentals → |
CurvesTransformation · GeneralizedHyperbolicStretch (GHS) · HaLRGB workflow · Narrowband workflow (HOO/SHO) · OSC workflow with a quad band-pass filter · RangeSelection (Range Mask)