JayBeams  0.1
Another project to have fun coding.
Namespaces | Classes | Functions
jb::clfft Namespace Reference

Wrappers for the clFFT library. More...

Namespaces

 detail
 

Classes

class  clfft_error
 A run-time clFFT error. More...
 
class  init
 Wrap clfftPlanHandle objects in a class that can automatically destroy them. More...
 
class  plan
 Wrap clfftPlanHandle objects. More...
 

Functions

void check_error_code (cl_int err, char const *msg)
 Check in an OpenCL error code is really an error and raise an exception if so. More...
 
template<typename invector , typename outvector >
plan< invector, outvector > create_forward_plan_1d (outvector const &out, invector const &in, boost::compute::context &ct, boost::compute::command_queue &q, int batch_size=1)
 Create a forward DFT plan. More...
 
template<typename invector , typename outvector >
plan< invector, outvector > create_inverse_plan_1d (outvector const &out, invector const &in, boost::compute::context &ct, boost::compute::command_queue &q, int batch_size=1)
 Create an inverse DFT plan. More...
 

Detailed Description

Wrappers for the clFFT library.

Function Documentation

◆ check_error_code()

void jb::clfft::check_error_code ( cl_int  err,
char const *  msg 
)
inline

◆ create_forward_plan_1d()

template<typename invector , typename outvector >
plan<invector, outvector> jb::clfft::create_forward_plan_1d ( outvector const &  out,
invector const &  in,
boost::compute::context &  ct,
boost::compute::command_queue &  q,
int  batch_size = 1 
)

Create a forward DFT plan.

Parameters
outthe output destination prototype. The actual output in execute() must have the same size as this parameter.
inthe input data prototype. The actual input in execute() must have the same size as this parameter.
cta collection of devices in a single OpenCL platform.
qa command queue associated with ct to create and bake the plan.
batch_sizethe number of timeseries in the input and output vectors.
Returns
a new plan that computes a DFT from a vector like in into a vector like out.
Exceptions
std::exceptionif the parameters are invalid or there was an OpenCL or clFFT error.
Parameters
batch_sizethe number of timeseries in the vector.
Template Parameters
invectorthe type of the input vector
outvectorthe type of the output vector

Definition at line 255 of file plan.hpp.

References jb::clfft::plan< in_timeseries_type, out_timeseries_type >::create_plan_1d_impl().

Referenced by BOOST_AUTO_TEST_CASE(), jb::fftw::plan< timeseries_type, frequency_timeseries_type >::execute(), and main().

◆ create_inverse_plan_1d()

template<typename invector , typename outvector >
plan<invector, outvector> jb::clfft::create_inverse_plan_1d ( outvector const &  out,
invector const &  in,
boost::compute::context &  ct,
boost::compute::command_queue &  q,
int  batch_size = 1 
)

Create an inverse DFT plan.

Parameters
outthe output destination prototype. The actual output in execute() must have the same size as this parameter.
inthe input data prototype. The actual input in execute() must have the same size as this parameter.
cta collection of devices in a single OpenCL platform.
qa command queue associated with ct to create and bake the plan.
batch_sizethe number of timeseries in the input and output vectors.
Returns
a new plan that computes a DFT from a vector like in into a vector like out.
Exceptions
std::exceptionif the parameters are invalid or there was an OpenCL or clFFT error.
Template Parameters
invectorthe type of the input vector
outvectorthe type of the output vector

Definition at line 284 of file plan.hpp.

References jb::clfft::plan< in_timeseries_type, out_timeseries_type >::create_plan_1d_impl().

Referenced by BOOST_AUTO_TEST_CASE().