Using fast vector magnitude function to improve performance.
Precreating fft object to improve performance