matlab运行测试用例报错:
错误使用 gpuArray/bsxfun
无法读取文件 C:\MATLAB\R2016b\toolbox\distcomp\gpu+parallel+internal+ptx\PTX_sm_30.mat。
系统环境:matlab2016 + cuda11.6
源代码的两个文件如下:
ctImageReconstruction.m
function [ir1,ir15]=ctImageReconstruction(img)
th1=0:1:179;
r1=radon(img,th1);
ir1=iradon(r1,th1,'hann');
th15=0:15:179;
r15=radon(img,th15);
ir15=iradon(r15,th15,'hann');
end
demo.m
img=phantom(2000);
gd=gpuDevice();
tic;
A=gpuArray(img);
[ir1,ir15]=ctImageReconstruction(A);
wait(gd);
toc;
具体报错如下:
错误使用 gpuArray/bsxfun
无法读取文件 C:\MATLAB\R2016b\toolbox\distcomp\gpu\+parallel\+internal\+ptx\PTX_sm_30.mat。
出错 gpuArray/iradon>filterProjections (line 175)
p = bsxfun(@times, p, H); % faster than for-loop
出错 gpuArray/iradon (line 130)
[p,H] = filterProjections(p, filter, d);
出错 ctImageReconstruction (line 4)
ir1=iradon(r1,th1,'hann');
出错 demo (line 5)
[ir1,ir15]=ctImageReconstruction(A);
在matlab2022+cuda11.6下面运行不报错,想确认一下问题的原因在哪里