First, my algorithm performs channel alignment. To align the three color channels, my algorithm minimizes the difference between the overlay of the three channels. First, it aligns the red-blue channels, then the green-blue. Recursively implemented, the input image is continuously scaled to 50% until the height is less than 400 pixels. Then, from coarsest to finest, optimal alignments are computed. In order to reduce runtime, the algorithm only brute forces the smallest image in the pyramid, then uses a finer control for the remaining larger images in the pyramid. The smallest image (< 400 pixels tall) aligns its channels usng a large window: [-20, 20] using a Sum of Squared Differences algorithm. Although this yields over 400 comparisons, remember this image is relatively small. This large window has the advantage of finding a great initial alignment. Next, the offsets are refined using a much smaller window: [-2, 2] for the larger image channels. This allows for a less-than 20-second runtime on a typical computer while minimizing aberration.

The Sum of Squared Differences algorithm follows a typical algorithm of this type, adding one optimization base on knowledge of thi image set. Since these images frequently have mis-colored borders and frames, a thin border is cropped from around the image before the sum of squared differences is computed. This produces more accurate results because the SSD was minimizing when the borders overlap, not key image features.

In addition to channel alignment, my algorithm performs some image editing. First, a crop is performed around all edges, constant thickness of 5%, to remove the border around every photo. Next, ranges of contrast and saturation are computed then stretched by a fine-tuned amount to modernize the appearance of the photos. For example, these photos have a greyed-out color palette and lack variety in brightness. To compensate for this, the value (brightness) and saturation (colorful-ness) of pixels are stretched from the center to produce a beautiful result.

Shown below are all images passed through this algorithm. The first in each pair has no bells and whistles, while the second image has been cropped and enhanced. The last 4 images are additional from the same collection. Noted are Red-Blue and Green-Blue offsets for full-scale images.