Visible to Intel only — GUID: GUID-D779B39E-4C12-4CB1-9A95-8998EB292C5C
Visible to Intel only — GUID: GUID-D779B39E-4C12-4CB1-9A95-8998EB292C5C
descriptor<precision, domain>::set_value
Sets one configuration parameter with the specified configuration value. This routine belongs to the oneapi::mkl::dft namespace.
Description
This function sets one configuration parameter with the specified configuration value and throws an std::runtime_exception in the case that it fails. Each configuration parameter is a named constant, and the configuration value must have the corresponding type, which can be a named constant or a native type. The DPC++ configuration parameters have type mkl::dft::config_param. Each parameter mkl::dft::config_param::<PARAMETER_NAME> has the same meaning and possible values as the C interface’s DFTI_<PARAMETER_NAME>. Some of the options available in the C interface are not fully supported in the DPC++ interface yet. See the note below and the Intel® oneAPI Math Kernel Library Release Notes. For a full description of each parameter’s meaning and options, see Config Params.
- An important difference in the configuration options for DPC++ FFT interface is the use of FWD_DISTANCE and BWD_DISTANCE instead of INPUT_DISTANCE and OUTPUT_DISTANCE. The FWD_DISTANCE describes the number of elements between different batched FFTs for the forward domain while BWD_DISTANCE describes the number of elements between different batched FFTs for the backward domain. These configuration parameters enable a committed 1D descriptor with default strides to compute both forward and backward transforms without resetting the distance parameters.
For COMPLEX_STORAGE, only the DFTI_COMPLEX_COMPLEX format is currently supported on CPU and GPU devices.
In the case of a real forward domain, the only supported values on GPU devices for CONJUGATE_EVEN_STORAGE and PACKED_FORMAT are respectively DFTI_COMPLEX_COMPLEX and DFTI_CCE_FORMAT. These values are set by default and require the setting of the INPUT_STRIDE and OUTPUT_STRIDE parameters before calling commit.
In the case of a real forward domain, arbitrary strides and batch distances are not supported for multi-dimensional transforms on GPU. Considering the last dimension of the data, every element must be separated from its nearest peer(s) (along another dimension and/or in another batch) by a constant distance. For example, to compute a batched, two-dimensional R2C FFT of size [N2, N1] with input strides [0, S2, 1] (row-major layout with unit elementary stride and no offset), FWD_DISTANCE must be equal to N2*S2 so that every element is separated from its nearest last-dimension counterpart(s) by a distance S2 (in this example), even across batches.
Transforms on GPU devices may overwrite FFT-irrelevant, padding entries in the output data.
The set_value function cannot be used to change configuration parameters mkl::dft::config_param::FORWARD_DOMAIN, mkl::dft::config_param::PRECISION since these are a part of the template. Likewise, mkl::dft::config_param::LENGTHS is set with the constructor.
All calls to set_value() must be done before calls to commit(). This is because the handle may have been moved to an offloaded device after commit().
Function calls needed to configure an FFT descriptor for a particular call to an FFT computation function are summarized in Configuring and Computing an FFT in C/C++.
API
Syntax
namespace oneapi::mkl::dft{ void descriptor<prec,dom>::set_value(config_param param, ...); }
Include Files
oneapi/mkl/dfti.hpp
Input Parameters
Name |
Type |
Description |
---|---|---|
param |
mkl::dft::config_param |
Configuration parameter |
value |
Depends on the configuration parameter |
Configuration value |