Mathematics, Fourier Transform, Image Processing, Numpy.
only maximized when a vector dot products with itself. The time complexity of the above algorithm is O(M²) (M is the number of pixels). We can do better than that by solving the problem in the Fourier domain. Let’s define the discrete Fourier transform of a row of N pixels x[n] as The famous