"Warning: The source file ....\AppDa​ta\Local\T​emp\mathwo​rks_tmp_00​62816838_1​576.auth' has a name conflict with another source file in CTF. It is saved as 'toolbox\i​mages\imag​es\@gpuArr​ay\private​\medfilt2g​pumex_mexw​64.auth' in the CTF..."

1 view (last 30 days)
I am compiling a Matlab code that uses the GPU (with gpuArray). mcc returns the following warning:
Warning: The source file 'C:\...\AppData\Local\Temp\mathworks_tmp_0062816838_1576.auth' has a name conflict with another source file in CTF. It is saved as 'toolbox\images\images\@gpuArray\private\medfilt2gpumex_mexw64.auth' in the CTF. Please verify that your application works as expected.
When I run the compiled code, I get the following error:
Error using gpuArray/gradient
MATLAB encountered an unexpected error in evaluation on the GPU.
This could be caused by an invalid path or a corrupted MATLAB installation.
Error in ...
parallel:gpu:array:MATLABFcnNotFound
I have tried this on different Windows and Linux computers, with the same results. Does anyone know what the issue is here?
Thanks, Iman
  1 Comment
Iman Aganj
Iman Aganj on 15 Aug 2016
To make it simpler, consider this function:
function testFun
a = gpuArray([1 1]);
gradient(a)
end
It works from inside Matlab, but when I deploy it:
mcc -m testFun.m
then the gradient function for gpuArray variables is no more recognized, and I get the following error message:
Error using gpuArray/gradient
MATLAB encountered an unexpected error in evaluation on the GPU.
This could be caused by an invalid path or a corrupted MATLAB installation.
Error in testFun (line 4)
parallel:gpu:array:MATLABFcnNotFound

Sign in to comment.

Answers (1)

Swathik Kurella Janardhan
Swathik Kurella Janardhan on 30 Aug 2016
The error is due to a missing file in the CTF archive. So, as a workaround include the missing file 'toolbox\distcomp\array\+parallel\+internal\+flowthrough\gradient.m' using '-a' flag to 'mcc' command like below:
>> mcc -m testFun.m -a 'C:\Program Files\MATLAB\R2016a\toolbox\distcomp\array\+parallel\+internal\+flowthrough\gradient.m'
This will still give warning messages during compilation, for which the root cause is currently unknown. Once the executable file is generated, you should be able to execute it without any errors.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!