Digital History
Using Image Processing to Gain Superhero Vision
By Mark Ciotola
First published on February 18, 2019
Learning Objectives
- Students will learn visual concepts and what can be achieved through image processing, such as bringing out hard-to-see text and details of documents and photographs.
Introduction
Image processing involves analyzing and altering images, typically photographs. Images can involve billions of pixels, so having automated techniques to process and analyze images is invaluable. Images can be analyzed to search for certain features, such as structures, or materials. Several ancient complexes have been discovered by image analysis. It is possible to search some images for certain types of minerals or plants.
Challenges
There can be several challenges to image processing and analysis.
- Images might be blurry or out of focus.
- Part of the image might be missing or faded.
- The image might have become color distorted.
- The image might not have the required color information.
- Photos may have been taken at angles that make the subject difficult to view.
- You don’t really know what your are looking for, or even if you do, what t looks like.
Suitable Image File Types
There are several common image file types:
- JPEGs (or JPGs) are well-suited for photographs and offer the benefit of compression. This allows for reduced file size and faster loading. JPEGs also offer a wide range of colours.
- GIFs are well-suited for line drawings with basic colours, as well as simple animations (known as animated GIFs), although the PNG format handles these sufficiently. GIFs are not well-suited to display a rich range of colors.
- The PNG format is well suited for many types of graphics and is the default when creating certain graphics on OSX such as screenshots. Most newer versions of MS Windows can view PNGs, although some older versions cannot.
- SVG code is used to generate images.
Processing with Python
Several image processing libraries have been written for the Python programming language. Using functions from those libraries, it is easy to examine single colors from an image, or even subtract one color from another, in order to highlight various features, such as vegetation or buildings. Below are examples of a raw image and images processed in Python.
Hyperspectral Analysis
Hyperspectral analysis involves taking images in many different wavelengths instead of the simple red green blue of most cameras. The wavelengths for each pixel are plotted to produce a spectral signature for each point. Those signatures are then compared to libraries of material signatures to identify specific substances, plants, or organisms.
Special images and software are required. The TNTmips is a free software program that includes a hyperspectral analysis component as well as a dedicated tutorial.
Activities
- Students will use simple desktop image tools (such as Preview) to quickly examine images and find hidden type.
- Students will learn basics of the Python language.
- Student will learn how to use simple commands in a Python image analysis library package.
Leveling Up
- Learn some Python and use a Python image image analysis library package to manipulate images.
Further Reading
- Python Programming Language (Corsbook)
- Python.org
« Digging Deeper into Document Repositories | COURSE | Satellite Imagery for Historical Uses »