Why comm.gpu.AWGNChannel is not faster than comm.AWGNChannel?
2 views (last 30 days)
Show older comments
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 Comments
Answers (0)
See Also
Categories
Find more on PSK in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!