fft#
- kikuchipy.pattern.fft(pattern: ndarray, apodization_window: ndarray | Window | None = None, shift: bool = False, real_fft_only: bool = False, **kwargs) ndarray [source]#
Compute the discrete Fast Fourier Transform (FFT) of an EBSD pattern.
Very light wrapper around routines in
scipy.fft
. The routines are wrapped instead of used directly to accommodate easy setting ofshift
andreal_fft_only
.- Parameters:
- pattern
EBSD pattern.
- apodization_window
An apodization window to apply before the FFT in order to suppress streaks.
- shift
Whether to shift the zero-frequency component to the centre of the spectrum (default is
False
).- real_fft_only
If
True
, the discrete FFT is computed for real input usingscipy.fft.rfft2()
. IfFalse
(default), it is computed usingscipy.fft.fft2()
.- **kwargs
Keyword arguments pass to
scipy.fft.fft2()
orscipy.fft.rfft2()
.
- Returns:
out
The result of the 2D FFT.