LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

pnmnlfilt

Apply non-linear smoothing filters to images

TLDR

Smooth noise with alpha-trimmed mean filter
$ pnmnlfilt [0.4] [0.8] [input.pnm] > [output.pnm]
copy
Optimal estimation smoothing (alpha 1.0-2.0)
$ pnmnlfilt [1.2] [1.0] [input.pnm] > [output.pnm]
copy
Edge enhancement (negative alpha)
$ pnmnlfilt [-0.3] [0.8] [input.pnm] > [output.pnm]
copy

SYNOPSIS

pnmnlfilt alpha radius [pnmfile]

DESCRIPTION

pnmnlfilt applies a non-linear filter to a PNM image, combining noise reduction with edge preservation. The single alpha parameter selects between three distinct modes: alpha-trimmed mean filter for smoothing and noise reduction (alpha 0.0-0.5), optimal estimation smoothing that adapts to local variance (alpha 1.0-2.0), and edge enhancement that sharpens transitions (negative alpha).The radius parameter controls the hexagonal pixel neighborhood size. Larger radii produce stronger effect but may blur fine details. Unlike simple convolution filters, pnmnlfilt avoids destroying sharp edges during smoothing.

PARAMETERS

alpha

Filter mode selector. 0.0-0.5: alpha-trimmed mean (smoothing). 1.0-2.0: optimal estimation smoothing. -0.1 to -0.9: edge enhancement.
radius
Hexagonal neighborhood radius. Recommended 0.55-1.0 for smoothing, 0.5-0.9 for edge enhancement. Smaller values reduce effect.

INSTALL

sudo apt install netpbm
copy
sudo dnf install netpbm
copy
sudo pacman -S netpbm
copy
sudo apk add netpbm
copy
sudo zypper install netpbm
copy
brew install netpbm
copy
nix profile install nixpkgs#netpbm
copy

CAVEATS

No pnmnlfilt-specific command-line flags exist; only standard libnetpbm options apply. Part of the Netpbm toolkit.

SEE ALSO

Braincup
Open source brain training for math, memory and focus
Braincup mini-games
41 mini-games · Apache-2.0
No ads · No tracking
Play in browser
Download Braincup on the App StoreGet Braincup on Google PlayGet Braincup on F-Droid
276 stars
From the maker of Linux Command Library
Copied to clipboard
Braincup
Open source brain training for math, memory and focus. 41 mini-games, from mental arithmetic to Sudoku, N-Back and Solo Chess.
Apache-2.0 licensed · No ads · No tracking · No account
From the maker of Linux Command Library
Download Braincup on the App StoreGet Braincup on Google PlayGet Braincup on F-Droid