Project 1

Low-scale pictures

The approach I did towards the low-scale pictures is to do a exhuastive search over a 15 * 15 box, and use the SSD as the evaluation function. It shows some effects, and shows a lot improvement from the stacking the original R, G, B together. I think the problem is due to the fact that after shifting the original matrix to some pixcels, we do not want to include these pixel into evaluation. Thus for a better performance, I decided to modifiy the evation to only care about the center part eg. r[30 : -30, 30 : -30] which is the area that won't be affected even after shifting to the maximum condition.

hello

High-scale pictures

For high-scale pictures, I Use the pyramid Search solution. I checked the shape of the original .tif files, which are usually 3100 * 3800 pixels. In order to do a exhuastive search over a 15*15 level, I first downscale the matrix to 1/16 of the original times, then find the best shift position, upscale the offsets and matrix by 2, then do it again. After 4 times of exhuastive search and scale up, I will get an ideal offset and matrix of the same size. I'm still using the ssd as the evaluation method, but the result seems pretty blury at first. Then I modifided the evaluation to only consider the middle part, then the pictures seem much better. For the below offset, a positive value means moving up and moving down.

offset for r in x,y directions are 52 9, offset for r in x,y directions are 22 6

offset for r in x,y directions are 43 10, offset for r in x,y directions are 22 6

offset for r in x,y directions are 60 4, offset for r in x,y directions are 31 3


offset for r in x,y directions are 59 7, offset for r in x,y directions are 28 5

offset for r in x,y directions are 83 0, offset for r in x,y directions are 38 1


offset for r in x,y directions are 53 3, offset for r in x,y directions are 31 3

offset for r in x,y directions are 46 7, offset for r in x,y directions are 23 -2


offset for r in x,y directions are 43 -6, offset for r in x,y directions are 26 -2

My own examples on 4 randomly choosen .tif pictures

offset for r in x,y directions are 54 -4, offset for r in x,y directions are 30 -1

offset for r in x,y directions are 22 -17, offset for r in x,y directions are -1 -9


offset for r in x,y directions are 81 11, offset for r in x,y directions are 40 5

offset for r in x,y directions are 74 -3, offset for r in x,y directions are 16 -1