Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I run MATLAB code on the GPU using CUDA?

I want to run MATLAB code on the GPU using NVIDIA's CUDA. I found a couple of 3rd-party engines:

  • Jacket
  • GPUMat

Would anyone recommend these or are there better ones out there? Any tips or suggestions?

like image 213
sjchoi Avatar asked Dec 08 '09 17:12

sjchoi


People also ask

How do I force MATLAB to use GPU?

Use MATLAB Functions with the GPU Create a row vector that repeats values from -15 to 15. To transfer it to the GPU and create a gpuArray object, use the gpuArray function. To operate with gpuArray objects, use any gpuArray -enabled MATLAB function. MATLAB automatically runs calculations on the GPU.

Is it possible to train models using GPU in MATLAB?

MATLAB® supports training a single deep neural network using multiple GPUs in parallel. By using parallel workers with GPUs, you can train with multiple GPUs on your local machine, on a cluster, or on the cloud. Using multiple GPUs can speed up training significantly.


1 Answers

Parallel Computing Toolbox released with MATLAB R2010b now has GPU support, including overloads for various mathematical operations, and an interface with pre-existing CUDA kernels.

Doc here: http://www.mathworks.com/discovery/matlab-gpu.html

like image 70
Edric Avatar answered Sep 23 '22 21:09

Edric