- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I m trying to use mkl for fft calcs and here is the snippet I m using in my code:
void std::vector<std::complex> process( const std::vector<double> &data )
{ DFTI_DESCRIPTOR_HANDLE hand = 0; std::vector<std::complex> result; size_t input_data_size = data.size(); int status = DftiCreateDescriptor( &hand, DFTI_DOUBLE, DFTI_REAL, 1, static_cast<MKL_LONG>(input_data_size) ); status = DftiSetValue( hand, DFTI_PLACEMENT, DFTI_NOT_INPLACE ); status DftiSetValue( hand, DFTI_CONJUGATE_EVEN_STORAGE, DFTI_COMPLEX_COMPLEX ); status = DftiCommitDescriptor( hand ); result.resize( input_data_size ); status = DftiComputeForward( hand, const_cast<double*>(&data[0]), &result[0] ); status = DftiFreeDescriptor( &hand ); return result; }
this function is called n times and it usually crash in the call to DftiCreateDescripter after few iterations.
Any help will be appreciated
Sam
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Sam Z.!
Your code looks correct and should run fine if we add <double> after std::complex.
If it does not, please post here, or send privately, or submit via premier.intel.com a complete reproducer for the issue.
Thanks.
Evgueni.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
thanks Evqueni it was just a typo in the post.
I get a double free() failure. it seems that there is an issue inside the call to DftiCreateDescriptor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Please post the size of data, the compile line, the link line, and the MKL version that you use.
You may check the link line for correctness using Intel MKL Link Line Advisor https://software.intel.com/en-us/articles/intel-mkl-link-line-advisor
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page