I have the two methods which should write pixel values of the absolute difference of a template and the same size patch from the original picture into the pixel where both patch and template coordinates are 0,0. I have the two methods which should write pixel