DTolm / VkFFT

Vulkan/CUDA/HIP/OpenCL/Level Zero/Metal Fast Fourier Transform library
MIT License
1.48k stars 88 forks source link

Batch/Many FFT #140

Open lashgar opened 8 months ago

lashgar commented 8 months ago

Does VkFFT support performing multiple FFTs in one call? A functionality similar to cufftPlanMany: https://docs.nvidia.com/cuda/cufft/index.html?highlight=cufftPlanMany#function-cufftplanmany

DTolm commented 8 months ago

Hello,

Yes, it is supported. There are also multiple ways to achieve these.

  1. You can use the numberBatches parameter, which is a straightforward number of consecutive systems in memory to do N-dimensional FFTs on. (See section 6.3 in documentation)
  2. You can select the higher number of dimensions and use omitDimension[i] parameter to disable the dimensions from performing the FFT on. With it, you can do the inner-most batching and have multiple types of batches with different strides. (See section 6.5 in documentation)

istride, idist and other parameters can be set with custom strides - see section 6.4

Best regards, Dmitrii