CS180 Project 2: Fun with Filters and Frequencies!
Overview
Project delves into various methods to manipulate frequencies to process and blend images together.
1.1+1.2 Fun with Filters
Finite Difference Operator
Have the finite difference operators D_x ([-1 1]) and D_y ([-1 1].T) used to convolve the cameraman image.
Subsequently will take the gradient magnitude and binarize it setting on 0.1 as the best threshold to display edges as clearly as possibly while suppressing noise.
Introduced the “G” Gaussian Filter to use and create a blurred version of the original image. Method is the Derivative of Gaussian (DoG) Filter
Tried 2 methods, one with 2 convolutions and another with 1 convolution. Noticeable difference compared to simply using finite difference operator was thicker lines on the binarized edges and noise is cleared up more (particularly bottom) compared to previously. Lower threshold is likely possible to achieve similar results.
Between the double and single convolution, they look identical which is desired
2.1 Image “Sharpening”
Want to strengthen the high frequencies of the image to “sharpen” it. Acquire the high freqs by blurring the image (with Gaussian filter) which are the low freqs and then subtracting it from the OG image. Turned the process into an unsharp mask filter using 1 convolution.
V Plush Sharp
Duck Shar-Sharpen
Sharpened Sharp Duck
2.2 Hybrid Images
Want to create a hybrid image where the high frequency image is more visible up close and the low frequency image is more visible from afar. Blending the 2 images together results in the hybrid image.
Tari + Dr. Edgar Zomboss (My grades aka Failure)
Hybrids
Failed since the shapes, especially body posture/shape and head, were too different to make work even tho there may have been potential particularly on the left one. If Zomboss had a background and Tari didn’t it may have turned out different.
Giga Craig
B+W (Gen5 the best unique pokemon gen besides Gen1)
The images in Color vs just simply grayscale. Since the low frequency image (nutmeg the cat) is not super prominent, the one where nutmeg is in black and white vs color is not super noticeable however, compared to both of them being in Black and White, adding color is an improvement on all fronts.
2.3 + 2.4 Multi-resolution Blending and the Oraple Journey (adding another coding nemesis to the list)
Implemented Gaussian and Laplacian stacks to spawn the Oraple. Experimented and settled on 10 levels being sufficient for the stacks.
Gaussian Stack was made by creating an array to store each level with the original image being added first. Subsequent levels would be appended by applying the Gaussian Filter and blurring the image over and over again.
Laplacian Stack was made to have each level consist of the equivalent Gauss Level and having it be subtracted by the next level (i.e. Level 6 in Lap Stack is “Level 6 Gauss Stack - Level 7 Gauss Stack”
The mask (at least for oraple) would be an equal split of the image in black and white (left half of the apple and right half of the orange).
To get the blended image, the mask is applied to each level of the apple and orange (inverse mask from apple tho) Laplacian stack and adding them together. The stack combination has to be collapsed to get the final blended Oraple image.
Flan Brulee
Wet lover Shattering Icy lover’s bisexuality
B+W, all images are colored here and would look better than black and white variants (given BW could result in loss of detail and harder to see blending as easily)