The fftshift function of the numpy.linalg module shifts zero-frequency components to the center of a spectrum. The ifftshift function reverses this operation.
fftshift
numpy.linalg
ifftshift