Module fftw_plan_cache

Module fftw_plan_cache 

Source
Expand description

FFTW Plan Cache for performance optimization

Caches FFTW plans to avoid expensive plan creation on repeated FFT calls. Plans are stored in global caches keyed by size (1D) or dimensions (2D).

Note: Plans require &mut self for execution, so we use Mutex to ensure exclusive access. This is fine for Python bindings where the GIL serializes calls.

Functionsยง

clear_all_caches
Clear all cached plans (useful for testing or memory management)
execute_c2c_2d_backward
Execute 2D C2C backward FFT with cached plan
execute_c2c_2d_forward
Execute 2D C2C forward FFT with cached plan
execute_c2c_backward
Execute C2C backward (inverse) FFT with cached plan
execute_c2c_forward
Execute C2C forward FFT with cached plan
execute_c2r
Execute C2R (inverse real) FFT with cached plan
execute_c2r_2d
Execute 2D C2R FFT with cached plan
execute_dct2
Execute DCT-II with cached plan
execute_dst2
Execute DST-II with cached plan
execute_idct2
Execute IDCT-II (DCT-III) with cached plan
execute_idst2
Execute IDST-II (DST-III) with cached plan
execute_r2c
Execute R2C FFT with cached plan
execute_r2c_2d
Execute 2D R2C FFT with cached plan