API Reference

This section documents the public user interface of Kokkos-FFT. APIs are defined in KokkosFFT namespace and implementation details are defined in KokkosFFT::Impl namespace. Thus, it is highly discouraged for users to access functions in KokkosFFT::Impl namespace. Except for KokkosFFT::Plan, there are corresponding functions in numpy.fft as shown below.

Note

For the moment, APIs under KokkosFFT::Distributed and KokkosFFT::Testing are considered experimental and may be subject to changes without warnings.

FFT Plan

Description

Kokkos-FFT

numpy.fft

A class that manages a FFT plan of backend FFT library

KokkosFFT::Plan

Execute FFT given by the Plan on input and output Views

KokkosFFT::execute

Standard FFTs

Description

Kokkos-FFT

numpy.fft

One dimensional FFT in forward direction

KokkosFFT::fft

numpy.fft.fft

One dimensional FFT in backward direction

KokkosFFT::ifft

numpy.fft.ifft

Two dimensional FFT in forward direction

KokkosFFT::fft2

numpy.fft.fft2

Two dimensional FFT in backward direction

KokkosFFT::ifft2

numpy.fft.ifft2

N-dimensional FFT in forward direction

KokkosFFT::fftn

numpy.fft.fftn

N-dimensional FFT in backward direction

KokkosFFT::ifftn

numpy.fft.ifftn

Real FFTs

Description

Kokkos-FFT

numpy.fft

One dimensional FFT for real input

KokkosFFT::rfft

numpy.fft.rfft

Inverse of rfft

KokkosFFT::irfft

numpy.fft.irfft

Two dimensional FFT for real input

KokkosFFT::rfft2

numpy.fft.rfft2

Inverse of rfft2

KokkosFFT::irfft2

numpy.fft.irfft2

N-dimensional FFT for real input

KokkosFFT::rfftn

numpy.fft.rfftn

Inverse of rfftn

KokkosFFT::irfftn

numpy.fft.irfftn

Hermitian FFTs

Description

Kokkos-FFT

numpy.fft

One dimensional FFT of a signal that has Hermitian symmetry

KokkosFFT::hfft

numpy.fft.hfft

Inverse of hfft

KokkosFFT::ihfft

numpy.fft.ihfft

Helper routines

Description

Kokkos-FFT

numpy.fft

Return the DFT sample frequencies

KokkosFFT::fftfreq

numpy.fft.fftfreq

Return the DFT sample frequencies for Real FFTs

KokkosFFT::rfftfreq

numpy.fft.rfftfreq

Shift the zero-frequency component to the center of the spectrum

KokkosFFT::fftshift

numpy.fft.fftshift

The inverse of fftshift

KokkosFFT::ifftshift

numpy.fft.ifftshift

Enums

Description

Kokkos-FFT

Tag to specify when and how to normalize

KokkosFFT::Normalization

Tag to specify FFT direction

KokkosFFT::Direction

Macros

Following macros can be used to check whether a backend library is enabled or not.

Description

Macros

Defined if the FFTW is enabled.

KOKKOSFFT_ENABLE_TPL_FFTW

Defined if the cufft is enabled.

KOKKOSFFT_ENABLE_TPL_CUFFT

Defined if the hipfft is enabled.

KOKKOSFFT_ENABLE_TPL_HIPFFT

Defined if the rocfft is enabled.

KOKKOSFFT_ENABLE_TPL_ROCFFT

Defined if the oneMKL is enabled.

KOKKOSFFT_ENABLE_TPL_ONEMKL