Why comm.gpu.AWGNChannel is not faster than comm.AWGNChannel?
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Bhavanithya Thiraviaraja
am 12 Apr. 2018
Kommentiert: Bhavanithya Thiraviaraja
am 20 Apr. 2018
I am trying to understand GPU enabled communication System functions. In order to analyse it's processing speed, i wrote the below sample program,
M = 8;
modData = pskmod(randi([0 M-1],8192,1),M,pi/M);
tic;
% modData1 = gpuArray(modData);
gpuChannel = comm.gpu.AWGNChannel('NoiseMethod','Signal to noise ratio (SNR)','SNR',15);
channelOutput = gpuChannel(modData);
toc
tic;
Channel = comm.AWGNChannel('NoiseMethod','Signal to noise ratio (SNR)','SNR',15);
channelOutput1 = Channel(modData);
toc;
tic;
channelOutput2 = add_awgn_noise(modData,15);
toc;
tic;
channelOutput3 = awgn(modData,15);
toc;
scatterplot(channelOutput);
scatterplot(channelOutput1);
scatterplot(channelOutput2);
scatterplot(channelOutput3);
The output of this matlab programm is,
>> gpu_awgnchannel
Elapsed time is 0.067871 seconds.
Elapsed time is 0.002515 seconds.
Elapsed time is 0.000550 seconds.
Elapsed time is 0.000703 seconds.
As can be seen, the processing time taken by the gpu System function is more than ten times the normal function. Why is this Happening even though the GPU device is selected? Is it even running on the GPU? Is there any particular Settings to run on the gpu?
MATLAB : 2017a
2 Kommentare
Antworten (0)
Siehe auch
Kategorien
Mehr zu PSK finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!