2D Spectrum Characterization

A note on analyzing spectra of perforated board designs

Tangibit Studios
Tangibit Studios

--

Introduction

Transforming an image into the spatial frequency domain is a useful analysis technique. The resulting 2D power spectrum can quantify structure in the image. It is often useful to summarize 2D spectrum with 1D Power Spectral Density (PSD) plots. Both azimuthal and radial integration can generate 1D PSD plots. Characterization parameters are then extracted from these simpler plots. For example, it is often reported that natural images follow a ~1/f² power law in their azimuthal averaged PSD [1][2].

This article gives examples of Python code for 1D PSD plots which are then used to characterize a few test cases.

Azimuthally Averaged 1D PSD

Azimuthal integration either sums or averages 2D spectrum values along radii from the origin:

The resulting 1D plot shows spectral power (summed or averaged) by radii. Python code for implementing this using some interesting indexing methods is available [3]. An alternative method using Scipy ndimage functions [4] is shown below. It uses region labels to assign which portions of the image are summed together. A simple 1D example [4] illustrates this:

>>> from scipy import ndimage…

--

--