Optimizing fft algorithm using FFTW and CUDA python bindings