Discrete Fourier Transform Speed in SPNG
Surveys how DFT speed depends on array size and its prime factors, and how a faster size can be chosen. It presents single-threaded, multi-threaded CPU and GPU timings of torch FFTs, showing that powers of two are fastest only up to 1024 and that CPU beats GPU below about 512 points. It describes the SPNG code that selects a faster size.