Parfor Execution time variation
Hi,
I am using parfor for reading 600 .raw files.
c=zeros(1536,1536,600,’uint16′);
parpool(‘threads’,4);
parfor i=1:600
fileName=[folder,’/’,fileList(i).name];
a=fopen(fileName,’r’);
Z=fread(a,[1536 1536],’uint16′);
fclose(a);
c(:,:,i)=Z;
end
However, I am observing significant variability in the execution time, which ranges from 14 seconds to 110 seconds across different runs.
Why is this discrepancy occurring? Is there a way to achieve more consistent execution times?Hi,
I am using parfor for reading 600 .raw files.
c=zeros(1536,1536,600,’uint16′);
parpool(‘threads’,4);
parfor i=1:600
fileName=[folder,’/’,fileList(i).name];
a=fopen(fileName,’r’);
Z=fread(a,[1536 1536],’uint16′);
fclose(a);
c(:,:,i)=Z;
end
However, I am observing significant variability in the execution time, which ranges from 14 seconds to 110 seconds across different runs.
Why is this discrepancy occurring? Is there a way to achieve more consistent execution times? Hi,
I am using parfor for reading 600 .raw files.
c=zeros(1536,1536,600,’uint16′);
parpool(‘threads’,4);
parfor i=1:600
fileName=[folder,’/’,fileList(i).name];
a=fopen(fileName,’r’);
Z=fread(a,[1536 1536],’uint16′);
fclose(a);
c(:,:,i)=Z;
end
However, I am observing significant variability in the execution time, which ranges from 14 seconds to 110 seconds across different runs.
Why is this discrepancy occurring? Is there a way to achieve more consistent execution times? parfor, parallel computing, parallel computing toolbox MATLAB Answers — New Questions