Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Filip_K_
Beginner
100 Views

DftiCommitDescriptor error 3

Hi, I upgraded MKL to 2016.3.207 and I get from code that worked flawlessly for years error code 3. It looks like this:

   DFTI_Descriptor_struct *ds1;
   MKL_LONG retval = DFTI_NO_ERROR;
   MKL_LONG sizes[3] = {data->NZ, data->NY, data->NX - 2};
   MKL_LONG strides_in[4] = {0, data->NXY, data->NX, 1};
   MKL_LONG strides_out[4] = {0, data->NXY/2, data->NX/2 ,1}; // data.NXY/2 = (data.NX/2) * data.NY

   retval |= DftiCreateDescriptor(&ds1, DFTI_SINGLE, DFTI_REAL, 3, sizes);


double  scale = 1;
   retval |= DftiSetValue(ds1, DFTI_FORWARD_SCALE, scale);
   retval |= DftiSetValue(ds1, DFTI_PACKED_FORMAT, DFTI_CCE_FORMAT);
   retval |= DftiSetValue(ds1, DFTI_INPUT_STRIDES, strides_in);
   retval |= DftiSetValue(ds1, DFTI_OUTPUT_STRIDES, strides_out);
   retval |= DftiSetValue(ds1, DFTI_CONJUGATE_EVEN_STORAGE, DFTI_COMPLEX_COMPLEX);
   retval |= DftiSetValue(ds1, DFTI_REAL_STORAGE, DFTI_REAL_REAL);
   retval |= DftiCommitDescriptor(ds1);

   char *error_message = DftiErrorMessage(retval);

any idea whats wrong? I've forgotten - VC 2015.

Filip

0 Kudos
6 Replies
Jing_X_Intel
Employee
100 Views

Hi,

Could you share how the following array were set with us, please?

 MKL_LONG sizes[3] = {data->NZ, data->NY, data->NX - 2};
 MKL_LONG strides_in[4] = {0, data->NXY, data->NX, 1};
 MKL_LONG strides_out[4] = {0, data->NXY/2, data->NX/2 ,1};

What were the values?

Besides, could you share your MKL version information with us, please? The version information can be retrieved with the following code.

MKLVersion Version;
mkl_get_version(&Version);
printf("Major version:           %d\n", Version.MajorVersion);
printf("Minor version:           %d\n", Version.MinorVersion);
printf("Update version:          %d\n", Version.UpdateVersion);
printf("Product status:          %s\n", Version.ProductStatus);
printf("Build:                   %s\n", Version.Build);
printf("Platform:                %s\n", Version.Platform);
printf("Processor optimization:  %s\n", Version.Processor);
printf("================================================================\n");
printf("\n");

By the way, what's the content of error_message (printf("%s\n", error_message))?

Zhen_Z_Intel
Employee
100 Views

Hi Filip,

I think your equation for input strides & output strides could only be used for even, for ode number, it would be wrong. If you are using CCE storage, the strides normally set as:

dim[3]={N1, N2, N3};
out[4]={0, N2*(N3/2+1), (N3/2+1), 1};
in[4]={0, 2*N2*(N3/N2+1), 2*(N3/2+1), 1};

Thus, in your program, should be:

dim[3]={Z,Y, (X-2)};
out[4]={0, Y*X/2, X/2, 1};
in[4]={0, 2*Y*(X/2), 2*(X/2), 1};

If you replace 2*(X/2) to X for instance X==11, the result is incorrect. Another point, may I ask which transform you are going to do, forward or backward? input & output strides would be opposite if you use backward.

Best regards,
Fiona

Filip_K_
Beginner
100 Views

Hi,

here are the data:

sizes    0x00000000003d4de8 {80, 768, 1080}    long[3]
strides_in    0x00000000003d4e18 {0, 830976, 1082, 1}    long[4]
strides_out    0x00000000003d4e48 {0, 415488, 541, 1}    long[4]

 

Version    {MajorVersion=11 MinorVersion=3 UpdateVersion=3 ...}    MKLVersion
               MajorVersion    11    int
               MinorVersion    3    int
               UpdateVersion    3    int
               ProductStatus    0x000007fedaf85fa0 "Product"    char *
               Build    0x000007fedaf85fa8 "20160413"    char *
               Processor    0x000007fedaf86160 "Intel(R) Advanced Vector Extensions (Intel(R) AVX) enabled processors"    char *
               Platform    0x000007fedaf86000 "Intel(R) 64 architecture"    char *


error_message    0x000007fedaf78b04 "Intel MKL DFTI ERROR: Inconsistent configuration parameters"    char *

even when I tried to set sizes manualy like:


MKL_LONG sizes[3] = { 128, 1024, 1024 };
MKL_LONG strides_in[4] = { 0, 1024* 1026, 1026, 1 };
MKL_LONG strides_out[4] = { 0, 513*1024, 513, 1 };

 

I got the same error message.

best regards

 

Filip

Jing_X_Intel
Employee
100 Views

Hi,

We could not reproduce the error using your code and data. The output of DftiErrorMessage is No error.

Could you share your test code with us for investigation, please?

Filip_K_
Beginner
100 Views

Hi, I tested I created the project and it produces another error message. I dont know how it is possible. I even found another project with the same library files and it works. So it must be something deep in the project settings.

 

here is the link: https://www.dropbox.com/s/srot7ztvjgbebid/Win32Project1.zip?dl=0

 

thanks Filip

Filip_K_
Beginner
100 Views

Ok, many thanks to all. I found it. There is a new setting in VC2015 together with new MKL. I had to switch on "UseMKL" from No to Parallel and it works now.  It was not there before so it was not obvious to me.

 

thanks to all

 

Filip

Reply