ppmhist

Print a histogram of the colors present in a PPM image. More information: <https://netpbm.sourceforge.net/doc/ppmhist.html>.

Install

All systems
curl cmd.cat/ppmhist.sh
Debian Debian
apt-get install netpbm
Ubuntu
apt-get install netpbm
Arch Arch Linux
pacman -S netpbm
image/svg+xml Kali Linux
apt-get install netpbm
CentOS
yum install netpbm-progs
Fedora
dnf install netpbm-progs
Windows (WSL2)
sudo apt-get update sudo apt-get install netpbm
OS X
brew install netpbm
Raspbian
apt-get install netpbm

Print a histogram of the colors present in a PPM image. More information: <https://netpbm.sourceforge.net/doc/ppmhist.html>.

  • Generate the histogram for human reading:
    ppmhist -nomap path/to/image_file.ppm
  • Generate a PPM file of the colormap for the image, with the color histogram as comments:
    ppmhist -map path/to/image_file.ppm
  • Display version:
    ppmhist -version

© tl;dr; authors and contributors