M 005 / 18301 Edge & Featuresalgorithm output

Scharr Filter

edge & feature detection

Typeface · Azeret Mono

Real-world algorithm demonstration, applied to a NASA portrait.
Real-world algorithm demonstration, applied to a NASA portrait.Image: NASA / Eileen Collins · scikit-image (public domain)View source ↗

Prompt

Apply a Scharr Filter effect, rendering fine grayscale contours on black with consistent sensitivity to vertical, horizontal, and diagonal boundaries. Make line brightness follow local contrast, revealing delicate texture and clean curved edges without directional bias. Leave flat regions dark and untextured. Keep the original subject and composition.

Identify

Fine, contrast-dependent contour lines.

Principle

A Scharr operator improves the rotational symmetry1 of small gradient kernels2.

Try it out

Compare fine diagonal details with Sobel.

Classification

Calculated image processing result.

Further examples · 7 images

Scharr Filter, applied to “KosyginaStreet Moscow view to Khamovniki 06-2015 img1”
02 Scharr Filter, applied to “KosyginaStreet Moscow view to Khamovniki 06-2015 img1”A cityscape view from Kosygina Street displays high-frequency edge detection across buildings and traffic. Fine, bright outlines indicate the gradient magnitude calculated by the Scharr operator.A.Savin (photo); processed for the Atlas · CC BY-SA 3.0 · Wikimedia Commons
Scharr Filter, applied to “Regietów Wyżny (Рeґєтiв) - dzwonnica 01”
03 Scharr Filter, applied to “Regietów Wyżny (Рeґєтiв) - dzwonnica 01”A wooden bell tower and landscape show distinct contrast-dependent contours against a dark sky. The filter captures delicate diagonal details on the sloped roof and textured hillside.Pudelek (photo); processed for the Atlas · CC BY-SA 4.0 · Wikimedia Commons
Scharr Filter, applied to “Helleborus orientalis, Zaaddozen zwellen, Locatie, Tuinreservaat Jonkervallei 01”
04 Scharr Filter, applied to “Helleborus orientalis, Zaaddozen zwellen, Locatie, Tuinreservaat Jonkervallei 01”A flower study reveals intricate venation on the leaves and thin outlines around the petals. The Scharr filter preserves symmetry in the fine, radiating details of the plant's structure.Dominicus Johannes Bergsma (photo); processed for the Atlas · CC BY-SA 4.0 · Wikimedia Commons
Scharr Filter, applied to “Dam at Jalpa de Canovas 2”
05 Scharr Filter, applied to “Dam at Jalpa de Canovas 2”A stone dam with multiple arches is rendered as a complex network of white lines on black. The operator highlights the high-contrast edges of the masonry and surrounding vegetation.Tomascastelazo (photo); processed for the Atlas · CC BY-SA 4.0 · Wikimedia Commons
Scharr Filter, applied to “Fishmonger smiling, Maracaibo street market, Venezuela”
06 Scharr Filter, applied to “Fishmonger smiling, Maracaibo street market, Venezuela”A portrait of a fishmonger shows the pattern of his shirt and facial features as fine white contours. The Scharr kernel emphasizes the dense textural gradients found in the fabric and skin.Wilfredor (photo); processed for the Atlas · CC0 · Wikimedia Commons
Scharr Filter, applied to “Centaurea phrygia - Keila”
07 Scharr Filter, applied to “Centaurea phrygia - Keila”The Centaurea phrygia flowers are represented by sharp outlines of their complex, feathery bracts. This image demonstrates the filter's ability to extract fine details from thin, overlapping natural forms.Ivar Leidus (photo); processed for the Atlas · CC BY-SA 4.0 · Wikimedia Commons