Given a set of images, LeastAverageImage generates the least average -- the opposite of the average.

LeastAverageImage

Given a set of images, LeastAverageImage generates the least average -- the opposite of the average.

alt text

More information about the program is here: https://www.AndrewEckel.com/LeastAverageImage/

Requirements

To use LeastAverageImage, you will need

  • ImageMagick: a free command line program you'll need to convert image files to and from the PPM format, the only format LeastAverageImage recognizes. Please select Install legacy utilities (e.g. convert) when installing.

You will also "pretty much need"

  • A text editor that automatically color-codes INI files to make them easier to read, such as Notepad++ or Sublime Text
  • A general image processing program to adjust the saturation, brightness, contrast, color balance, etc in your result images. The more variation there is your input images, the more grey-looking your raw results will be.

If you want to use images from video files as your input, you'll also need a way to convert the frames of the video into PPM images. For Windows, I can recommend VirtualDub for that. (Convert to a series of Targa files using VirtualDub, then convert those to PPM using ImageMagick. And of course, if you're converting a video file to a series of still images, you'll probably also need a separate hard drive to store them all.)

Setting up on Windows

Not compiling

Windows users can download a zip file with a 64 bit executable here: https://github.com/AndrewEckel/LeastAverageImage/releases

Compiling!

Those who want to compile the code themselves should start by cloning the entire git repo.

LeastAverageImage does not have complex dependencies, so if you have a preferred Windows C++ compiler, use that. Otherwise...

Install MinGW-w64 and add it to your Windows PATH by following the instructions here:

Setting up MinGW-w64 (just the first two sections -- Install MinGW-w64 and Test MinGW-w64)

Using the Windows command line, navigate to the project directory, where the Makefile is stored, and execute this command:

mingw32-make

Testing on Windows

After unzipping the program or compiling from the source code, navigate to the program directory using the Windows command line, and try running these two commands:

lai
lai ../input/list_mode_test.ini

The first command should create 3 PPM files in the output directory, and the second should create an additional 33.

You can use the Windows batch file in the output directory to convert the PPM files to TIF, but first you'll need to install ImageMagick and add its location to your PATH.

Compiling and testing on a Mac or other UNIX-based OS

Start by cloning the entire git repo.

Open a Terminal window in the directory that holds the Makefile, and execute this command:

make

On a Mac, if you do not have g++ and/or make installed, you will be asked if you wish to install Xcode. (Yes, you do!)

After compiling, navigate to the program directory and try running these two commands:

./lai
./lai ../input/list_mode_test.ini

The first command should create 3 PPM files in the output directory, and the second should create an additional 33.

Running LeastAverageImage

LeastAverageImage accepts one command line argument, the name of a single INI settings file. Without an argument, the program will default to ../input/settings.ini.

The included sample INI files have notes on the meaning of all the options.

LeastAverageImage is a single-threaded program. For processing multiple sets of images on a computer with "n" logical cores, you may wish to run up to n instances of LeastAverageImage at a time.

The amount of time each run takes depends on the number of input images, their dimensions, the number of difference functions included, and the highest value chosen for rankings_to_save. Remember, the area of an image is its width times its height, so if an image's dimensions are doubled, that makes it four times as big, meaning it would take LeastAverageImage four times as long to process!

For Windows users, batch files are included in the input and output folders for converting to and from PPM files using ImageMagick:

  • ImagestoPPM_without_delete.bat converts all JPG/JPEG, TIF, HEIC, PNG, and WEBP files in the current folder to PPM.
  • PPMtoTIF.bat converts all PPM files in the current folder to TIF and also deletes the original PPM files unless their filenames end in avg.ppm.

Sharing cool results

If you make something cool with this program, please show me, and please let others know about LeastAverageImage!

Similar Resources

A simple application that generates animated BTTV emotes from static images

emoteJAM WARNING! The application is in active development and can't do anything yet. A simple application that generates animated BTTV emotes from st

Apr 27, 2021

A simple API wrapper that generates images & facts of any animal

animality.h A simple API wrapper that generates images & facts of any animal Required dependencies: libcurl for sending HTTPS requests. pthreads for t

Jun 23, 2022

libcurses and dependencies taken from netbsd and brought into a portable shape (at least to musl or glibc)

netbsd-libcurses portable edition this is a port of netbsd's curses library for usage on Linux systems (tested and developed on sabotage linux, based

Sep 18, 2022

Recognize stairs with lidar. Project the laser points to X-Z plane and use least squares for linear fitting.

Recognize stairs with lidar. Project the laser points to X-Z plane and use least squares for linear fitting.

stairs_recogniton Recognize stairs with lidar. Project the laser points to X-Z plane and use least squares for linear fitting. Dependencies PCL 1.8 Ei

Jul 27, 2022

✔️The smallest header-only GUI library(4 KLOC) for all platforms

✔️The smallest header-only GUI library(4 KLOC) for all platforms

Welcome to GUI-lite The smallest header-only GUI library (4 KLOC) for all platforms. 中文 Lightweight ✂️ Small: 4,000+ lines of C++ code, zero dependenc

Oct 2, 2022

A C++ implemented set of 8,16,32,64 bit cyclic redundancy check (CRC) functions conforming to the CRC spec given by AUTOSAR

A C++ implemented set of 8,16,32,64 bit cyclic redundancy check (CRC) functions conforming to the CRC spec given by AUTOSAR. Written in C++ and compiled as a 'C++ addon' for use in JavaScript. Available on NPM.

Jul 13, 2022

A drop-in replacement for std::list with 293% faster insertion, 57% faster erasure, 17% faster iteration and 77% faster sorting on average. 20-24% speed increase in use-case testing.

plf_list A drop-in replacement for std::list with (on average): 293% faster insertion 57% faster erasure 17% faster iteration 77% faster sorting 70% f

Sep 11, 2022

Program will decode a PNG file into an array and apply the gaussian blur filter. Blurring an image reduces noise by taking the average RGB values around a specific pixel and setting it’s RGB to the mean values you’ve just calculated.

Program will decode a PNG file into an array and apply the gaussian blur filter. Blurring an image reduces noise by taking the average RGB values around a specific pixel and setting it’s RGB to the mean values you’ve just calculated.

Gaussian Blur with multithreading in C Reading in an image file into a single or 2D array Applying Gaussian filter on image Using multithreading appro

Nov 24, 2021

A drop-in replacement for std::list with 293% faster insertion, 57% faster erasure, 17% faster iteration and 77% faster sorting on average. 20-24% speed increase in use-case testing.

plf::list A drop-in replacement for std::list with (on average): 293% faster insertion 57% faster erasure 17% faster iteration 77% faster sorting 70%

Sep 11, 2022

Get the current average CPU frequency on Apple M1 chips.

M1 CPU Frequency Get the current average CPU frequency on Apple M1 chips. Usage Download the precompiled binary from the releases and run it in the te

Aug 19, 2022

Implementation of Univaraint Linear Regresion (Supervised Machine Learning) in c++. With a data set (training set) you can predict outcomes.

Linear-Regression Implementation of Univaraint Linear Regresion (Supervised Machine Learning) in c++. With a data set (training set) you can predict o

Nov 3, 2021

oZKS (Ordered Zero-Knowledge Set) is a library that provides an implementation of an Ordered (and Append Only) Zero-Knowledge Set.

Ordered Zero-Knowledge Set - oZKS Introduction oZKS is a library that provides an implementation of an Ordered (and Append Only) Zero Knowledge Set. A

Aug 31, 2022

Bear is a tool that generates a compilation database for clang tooling.

ʕ·ᴥ·ʔ Build EAR Bear is a tool that generates a compilation database for clang tooling. The JSON compilation database is used in the clang project to

Sep 27, 2022

multi-sdr-gps-sim generates a IQ data stream on-the-fly to simulate a GPS L1 baseband signal using a SDR platform like HackRF or ADLAM-Pluto.

multi-sdr-gps-sim generates a GPS L1 baseband signal IQ data stream, which is then transmitted by a software-defined radio (SDR) platform. Supported at the moment are HackRF, ADLAM-Pluto and binary IQ file output. The software interacts with the user through a curses based text user interface (TUI) in terminal.

Sep 19, 2022

Generates CIL MLIR dialect from C/C++ source.

Build steps -DLLVM_ENABLE_PROJECTS="mlir;clang" in cmake ninja cml should build the cml clang tool ninja check-clang-cml to run the CIL tests. Check c

Aug 25, 2022

Indexes points and lines and generates map tiles to display them

Datamaps This is a tool for indexing large lists of geographic points or lines and dynamically generating map tiles from the index for display. Depend

Sep 8, 2022

A tool that analyzes headers and generates introspection code

A tool that analyzes headers and generates introspection code

Nov 7, 2021

The Sandboxed API project (SAPI) Generates sandboxes for C/C++ libraries automatically

The Sandboxed API project (SAPI) Generates sandboxes for C/C++ libraries automatically

The Sandboxed API project (SAPI) makes sandboxing of C/C++ libraries less burdensome: after initial setup of security policies and generation of library interfaces, a stub API is generated, transparently forwarding calls using a custom RPC layer to the real library running inside a sandboxed environment.

Sep 29, 2022
An open source library for face detection in images. The face detection speed can reach 1000FPS.
An open source library for face detection in images. The face detection speed can reach 1000FPS.

libfacedetection This is an open source library for CNN-based face detection in images. The CNN model has been converted to static variables in C sour

Sep 24, 2022
Reading, writing, and processing images in a wide variety of file formats, using a format-agnostic API, aimed at VFX applications.

README for OpenImageIO Introduction The primary target audience for OIIO is VFX studios and developers of tools such as renderers, compositors, viewer

Oct 1, 2022
CGIF, A fast and lightweight GIF encoder that can create GIF animations and images

CGIF, a GIF encoder written in C A fast and lightweight GIF encoder that can create GIF animations and images. Summary of the main features: user-defi

Aug 11, 2022
HDRView is a simple research-oriented image viewer with an emphasis on examining and comparing high-dynamic range (HDR) images
HDRView is a simple research-oriented image viewer with an emphasis on examining and comparing high-dynamic range (HDR) images

HDRView is a simple research-oriented high-dynamic range image viewer with an emphasis on examining and comparing images, and including minimalistic tonemapping capabilities. HDRView currently supports reading EXR, PNG, TGA, BMP, HDR, JPG, GIF, PNM, PFM, and PSD images and writing EXR, HDR, PNG, TGA, PPM, PFM, and BMP images.

Sep 14, 2022
You can use this to compile the code and output images into a word doc for assignment purposes
You can use this to compile the code and output images into a word doc for assignment purposes

Code_n_Ouput_to_docx You can use this to compile the code and output images into a word doc for assignment purposes Basic requirements: Python 3.7 or

Aug 21, 2022
A crude untested example showing how to retrieve and display images from multiple cameras with OpenCV and wxWidgets.

About wxOpenCVCameras is a crude untested example of how to retrieve and display images from multiple cameras, using OpenCV to grab images from a came

Jul 13, 2022
Convert images to ASCII art.
Convert images to ASCII art.

Image-to-ascii Convert images to ASCII art. This program using stb library to load images. Usage Usage: compile the program to get *.out file

Aug 20, 2022
Very fast C++ .PNG writer for 24/32bpp images.

fpng Very fast C++ .PNG writer for 24/32bpp images. fpng.cpp was written to see just how fast you can write .PNG's without sacrificing too much compre

Sep 26, 2022
Make It Pixel is a programming language to process images to look like pixel art.
Make It Pixel is a programming language to process images to look like pixel art.

Make images look like pixel art Make It Pixel is a programming language to process images to look like pixel art. Its interpreter is written in C++ an

Sep 7, 2022
6D - Pose Annotation Tool (6D-PAT) - is a tool that allows the user to load a set of images and also a set of 3D models and annotate where in the 2D image the 3D object ist placed.
6D - Pose Annotation Tool (6D-PAT) - is a tool that allows the user to load a set of images and also a set of 3D models and annotate where in the 2D image the 3D object ist placed.

6D - Pose Annotation Tool (6D-PAT) For detiled explanations checkout the WikiPage. What is it? With 6D-PAT you can create 6D annotations on images for

Sep 22, 2022