Can Simulink Models Be Ran On A GPU?

조회 수: 10 (최근 30일)
Aaron Kurlantzick
Aaron Kurlantzick 2021년 3월 1일
댓글: TAHAR NOUAOUI 2024년 1월 15일
I'm part of a group trying to speed up our code. We send out inputs to the simulink model with
simIn(i) = simIn(i).setVariable('Amplitude', pops(i, 1));
simIn(i) = simIn(i).setVariable('Freq', pops(i, 2));
simIn(i) = simIn(i).setVariable('PW', pops(i, 3));
simIn(i) = simIn(i).setVariable('Ramp_Toggle', pops(i, 4));
simIn(i) = simIn(i).setVariable('Ramp_Slope', pops(i, 5));
simIn(i) = simIn(i).setVariable('Ramp_Flat', pops(i, 6));
simIn(i) = simIn(i).setVariable('Intraburst_Toggle', pops(i, 7));
simIn(i) = simIn(i).setVariable('Intraburst_Period', pops(i, 8));
simIn(i) = simIn(i).setVariable('Intraburst_Packet', pops(i, 9));
simIn(i) = simIn(i).setVariable('Phasic', pops(i, 10));
and take back outputs with
simOut = parsim(simIn, 'ShowSimulationManager', 'off');
Using tic toc it seems that the simulink model takes about 90% of our runtime. Is there a way to run this on the GPU or other ways to speed it up? Any help will be greatly appreciated.
Thank you

채택된 답변

Anshika Chaurasia
Anshika Chaurasia 2021년 3월 4일
Hi,
You can use GPU Coder to speed up the execution of your Simulink model by using NVIDIA GPUs:
Please note that not all functions are supported by GPU Coder.
It is currently not possible to run a simulation on a GPU. The developers are aware of this enhancement request and might add this feature in a future release.
Hope it helps!
  댓글 수: 1
TAHAR NOUAOUI
TAHAR NOUAOUI 2024년 1월 15일
hello
is it possible to run a simulation on a gpu now?

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Get Started with GPU Coder에 대해 자세히 알아보기

태그

제품


릴리스

R2020a

Community Treasure Hunt

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

Start Hunting!

Translated by