Bartlett's and Welch's Method for PSD
This is just a 1D example that shows the idea (I can't seem to get scilab to cooperate with real images; at least not yet).

The top plot in blue shows the "image".  The "patch" is indicated by the red dots.  I've selected the location of the "patch" randomly throughout the "image".

The bottom plot shows the cross-correlation between the patch and the image (in green), and the red dot indicates the actual location (start position) of the patch.

The code below does no prewhitening because the "image" is generated using white noise.  Apart from the mean-correction, that is.



// 25803
clf;
NIM = 100;
IM = rand(1,NIM,"uniform");
IM = (IM - min(IM))/(max(IM) - min(IM))*255;
subplot(211)
plot(IM)

NPT = 24;
idx = ceil(rand(1,1,"uniform")*75);
PT = IM(idx + [0:NPT-1]);
plot(idx+[0:NPT-1],PT,'r.')
title('Original and patch')
NFFT = NIM + NPT - 1;

IMFFT = fft([IM-mean(IM),zeros(1,NPT-1)]);
PTFFT = fft([PT-mean(PT),zeros(1,NIM-1)]);

subplot(212)
CORR = ifft(IMFFT.*conj(PTFFT));
plot(CORR,'g')
plot(idx,CORR(idx),'r.')
title('Cross correlation and actual patch position')