This package provides C++ classes and their Python wrapper classes useful to perform Fast Fourier Transform (FFT) with different libraries, in particular
FluidFFT provides an unified API to use all these libraries. FluidFFT is not limited to just performing Fourier transforms. It is a complete development framework for codes using (distributed) FFT. A simple API allows the developers to easily perform operations on data in real and spectral spaces (gradient, divergence, rotational, sum over wavenumbers, computation of spectra, etc.) and deal with the data distribution (gather the data on one process and scatter the data to many processes) without having to consider the internal organization of every FFT library.
FluidFFT has been created to be:
Easy to install (see Installation and advice).
Easy to use, both for simple users and for developers (see Tutorials). FluidFFT hides the internal complication of (distributed) FFT libraries.
Robust (unittest coverage larger than 90 %).
The architecture of the code and the tools used (C++ classes, Cython wrapper and Pythran computational functions) leads to very good performances.
Moreover, Python developers can easily measure the performance cost of using Python compared to coding in pure C++. This cost has to be compared to the cost of the FFT in pure C++, which of course strongly varies with the size of the arrays. From our experience with real cases, the “Python cost” goes from very small (for small cases) to completely negligible (for medium and large cases).
A great advantage of FluidFFT is that it allows the user to find (see Benchmarking) and to choose the most efficient solution for a particular case. Since the fastest library depends on the case and on the hardware, it is really a useful feature for performance!
FluidFFT is therefore a very useful tool to write HPC applications using FFT, as for example pseudo-spectral simulation codes. For an example of how FluidFFT can be used in a real application, see the code of the Computational Fluid Dynamics (CFD) framework FluidSim.
- Installation and advice
||Efficient and easy Fast Fourier Transform for Python =======================================================|
See also the documentation of the cpp code produced with Doxygen