Skip to main content
16 votes

CUDA on Tesla V100 card

The CUDALink package doesn't work right on Linux. For years and years I've been reporting it, they don't fix it. You have to go through some hoops, but when you get it working, it's really sweet! My ...
Andreas Lauschke's user avatar
13 votes
Accepted

Optimizing sequential computation

Have you happened to try FunctionLayer? It provides quite an automation to port normal code to GPU. For this particular question, one can do: Define the computing ...
Silvia's user avatar
  • 27.6k
12 votes
Accepted

CUDA for linear equations

Turning the comments into an answer. Making a linear solver work on a GPU is highly nontrivial (it's a task to be assigned to someone who poisened his mother and father), and as far as I can tell, no ...
Henrik Schumacher's user avatar
10 votes
Accepted

Why I can only train some NetModel with GPU

The cause is the GPU running out of memory, and Mathematica not correctly reporting the failure (ResNet 152 is very memory hungry!). This can be seen by running ...
Sebastian's user avatar
  • 3,479
10 votes
Accepted

CUDALink support-Mathematica 11

Your CUDA paclet is outdated. Updating it with CUDAResourcesInstall[Update -> True] should fix your problems. The output of ...
Karsten7's user avatar
  • 27.5k
10 votes
Accepted

Which GPUs does NetTrain work with?

All NVIDIA GPUs except newest 10xx. http://community.wolfram.com/groups/-/m/t/917616 "A number of TensorFlow users are reporting problems using a 1080/1070 with CUDA v7.5 and cuDNN v5.0 (which ...
Alexey Golyshev's user avatar
9 votes
Accepted

Configuring GPU for NetTrain

Solution "TargetDevice"->{"GPU",1} It should be noted that numeration of GPUs starts from 0. "TargetDevice"->"GPU" is equivalent to ...
Alexey Golyshev's user avatar
9 votes
Accepted

CUDA on Tesla V100 card

In the end, in our case, the following allowed us to get CUDA to work. export NVIDIA_DRIVER_LIBRARY_PATH /usr/lib64/libnvidia-tls.so.418.116.00 (adapt to your ...
chris's user avatar
  • 23k
8 votes
Accepted

OpenCL compute large matrices

If memory is your bottleneck then don't use a GPU. The transfer of data between CPU (and its main memory) and the GPU is so slow that it virtually always takes longer than performing the computation ...
Henrik Schumacher's user avatar
8 votes
Accepted

Does Mathematica 12 support GT 730 CUDA?

In the Details sections of the documentation page ref/TargetDevice, there's a table that might help:
M.R.'s user avatar
  • 31.5k
7 votes

CUDA on Tesla V100 card

This is a reply to a question from chris, not a "new" answer. You mean a working example? How about 250 million normally-distributed random numbers, displayed in a histo: ...
Andreas Lauschke's user avatar
7 votes
Accepted

Can one use NetTrain with two Nvidia GPUs?

Multi-GPU support very nearly made it for 11.3, and it will definitely be available to users in 12. I will update this answer if it becomes available before that. Regarding SLI: as far as I know, it ...
Sebastian's user avatar
  • 3,479
6 votes
Accepted

Mathematica 10 enables discrete GPU

Use the gfxCardStatus utility to force integrated graphics. This must be done while integrated graphics is in use, i.e. before Mathematica is started. Sometimes it may be necessary to switch twice ...
Szabolcs's user avatar
  • 235k
6 votes
Accepted

How to use an external GPU to train neural networks in Mathematica?

Go to the NVIDIA Drivers Download page and download and install the correct driver for your GPU and system. Open a new Mathematica notebook and ensure that the GPUs can be detected. To do so, run <...
Miladiouss's user avatar
  • 1,883
6 votes
Accepted

GPU support on latest MacBook Pro, especially for deep learning

It's possible that MXNet (the underlying NN framework) will eventually support OpenCL (https://github.com/apache/incubator-mxnet/issues/621 is the issue to track) but I would not hold out for this, ...
Carl Lange's user avatar
  • 13.1k
5 votes
Accepted

Why the GPU will cost more time when train the net

actually I have a very powerfull gpu as you see Sorry for the car analogy, but the best way to think if this is: Picture your CPU as a Ferrari race car, and your GPU as a passenger train. If you want ...
Niki Estner's user avatar
  • 36.1k
5 votes

TargetDevice->"GPU" fails even though a CUDA GPU exists

See wolfram community : Here is the link
andre314's user avatar
  • 18.6k
5 votes
Accepted

TargetDevice->"GPU" doesn't work in version 11.1 on mac

Update The mac support has been brought back in version 11.1.1. And according to my test on MNIST example in the documentation, the GPU training is now 3X faster than version 11.0. Per info in the ...
Gregory Klopper's user avatar
5 votes

Using GPU Computation in LearnDistribution

It was simpler than I thought - simply run: SetOptions[NetTrain,TargetDevice->"GPU"] You can't specify GPU training for LearnDistribution, apparently, but you ...
Nico A's user avatar
  • 3,634
5 votes

CUDA on Tesla V100 card

The automatic detection has been improved with a paclet update for version 12.0, so after doing ...
ilian's user avatar
  • 25.5k
5 votes

Does NetTrain Support Nvidia 30xx series GPU (RTX 3080, 3090 etc)?

At the time of writing this (Feb. 6, 2021), Mathematica 12.2 doesn't support these cards, see for example: Extremely Long GPU Initialization Times on Mathematica 12.2 and RTX3090 and https://community....
Fidel I. Schaposnik's user avatar
4 votes
Accepted

CUDA on Manjaro Linux (Arch)

After struggling for two days, I finally figure it out minutes after asking for help... so typical :) Nevertheless, I post my solution here in case anyone else gets stuck. The Mathematica ...
a20's user avatar
  • 912
4 votes

Optimizing sequential computation

Your approach can be made a little faster (roughly 2x) by pre-calculating the random matrices, and using Fold over that list, rather than ...
MarcoB's user avatar
  • 67.3k
3 votes
Accepted

TargetDevice->"GPU" fails even though a CUDA GPU exists

As of his writing the latest Nvidia driver is for Quadro K2100M is 377.11 (Enterprise) 378.66 (New Feature) However CUDADriverVersion is reporting ...
Edmund's user avatar
  • 42.3k
3 votes

CUDATranspose bad result

For the sake of an answer: After several tries I have found that with Mathematica 10.4 and nvidia drivers 367.27 and upgrading to the latest CUDAResources paclet everythig is working ok – Javier ...
3 votes

How to determine MMA/CUDA support for specific GPUs?

ALL Nvidia GPUs with Compute Capability >=3.0 are supported for neural networks. However, you're out of luck with great hardware and a buggy version of Mathematica. 11.0 had an issue with all 10xx ...
Gregory Klopper's user avatar
3 votes
Accepted

Using library code (specifically curand) with CUDALink

The compiler accepts the following code : ...
andre314's user avatar
  • 18.6k
3 votes

OpenCL compute large matrices

The problem in my OpenCL code was probably coming due to the local memory constraints of the workgroups. After modifying the code a little bit, I could get it to work for the size ...
dykes's user avatar
  • 361
3 votes
Accepted

How can I free GPU memory allocated with NetTrain

This issue appears to be resolved in Wolfram 13.1! (the memory is not freed by mxnet, but at least I can ClearAll the model and re-train and without the GPU memory consumption spiking). Repeatedly ...
Alec Graves's user avatar
  • 1,058
3 votes
Accepted

Anyone has any succes on GPU NetTrain with RemoteBatchSubmit on AWS EC2?

The main issue here should now be resolved with a newly released version of the Wolfram Engine Docker image containing version 12.3.1 of the Wolfram Engine and version 12.3.406 of MXNetResources. If ...
Jesse Friedman's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible