4
$\begingroup$

I've run

Needs["CUDALink`"]
CUDAResourcesInstall[]

which, after a long download, returns

{
PacletManager`Paclet[
 "Name" -> "CUDAResources", "Version" -> "10.2.0.3", 
  "MathematicaVersion" -> "10.*", 
  "Description" -> "{ToolkitVersion -> 7.0, MinimumDriver -> 300.0}", 
  "SystemID" -> {"Windows-x86-64"}, "Qualifier" -> "Win64", 
  "Extensions" -> {{
    "Resource", 
     "Resources" -> {
      "CUDAToolkit", "ExampleData", "LibraryResources"}}}, 
  "Location" -> "C:\\Users\\Diego\\AppData\\Roaming\\Mathematica\\\
Paclets\\Repository\\CUDAResources-Win64-10.2.0.3"]}

Now

CUDADriverVersion[]

returns

358.87

But then I try

CUDAQ[]
CUDAInformation[]

and I get

False
During evaluation of In[44]:= CUDAInformation::nodev: CUDALink failed to detect a usable device. >>
CUDAInformation[]

So, when I try to use any CUDA function, such as the matrix product

A = RandomInteger[1, {10, 10}];
B = RandomInteger[1, {10, 10}];
CUDADot[A, B];

I get

CUDADot::invdev: CUDALink device is invalid. >>

I have a GeForce GTX Titan X (with NVIDIA drivers recently installed), which should totally be CUDA-ready. So, what am I doing wrong?

EDIT

The following functions return the following outputs:

In[30]:= CUDACCompilers[]
Out[30]= {}

In[31]:= CUDAResourcesInformation[]
Out[31]= {{"Name" -> "CUDAResources", "Version" -> "10.2.0.3", 
  "BuildNumber" -> "", "Qualifier" -> "Win64", 
  "WolframVersion" -> "10.*", "SystemID" -> {"Windows-x86-64"}, 
  "Description" -> "{ToolkitVersion -> 7.0, MinimumDriver -> 300.0}", 
  "Category" -> "", "Creator" -> "", "Publisher" -> "", 
  "Support" -> "", "Internal" -> False, 
  "Location" -> 
   "C:\\Users\\Diego\\AppData\\Roaming\\Mathematica\\Paclets\\\
Repository\\CUDAResources-Win64-10.2.0.3", "Context" -> {}, 
  "Enabled" -> True, "Loading" -> Manual, 
  "Hash" -> "7326e294f5e53407e2ce826e5b3ce301"}}

In[32]:= GPUTools`Internal`$NVIDIADriverLibraryPath
Out[32]= "C:\\Windows\\System32\\nvapi64.dll"

In[33]:= GPUTools`Internal`$CUDALibraryPath
Out[33]= "C:\\Windows\\System32\\nvcuda.dll"

In[34]:= $CUDALinkPath
Out[34]= "C:\\Program Files\\Wolfram
Research\\Mathematica\\10.1\\SystemFiles\\Links\\CUDALink\\"

In[35]:= SystemInformation["Devices", "GraphicsDevices"][[1]]
Out[35]= "DirectX" -> {"Version" -> "9", "Driver" -> "nvd3dumx.dll", 
  "Description" -> "NVIDIA GeForce GTX TITAN X", 
  "DeviceName" -> "\\.\\DISPLAY6", "VendorId" -> "4318", 
  "DeviceId" -> "6082", "SubSysId" -> "429471810", 
  "Revision" -> "161", 
  "DeviceIdentifier" -> {"D7B71E3E-5482-11CF-F14C-94391CC2C735"}, 
  "DriverVersion" -> "10.18.13.5891", 
  "Optimized 3D Transparency" -> True}

I've installed Visual Studio 2015 to serve as C compiler, but apparently CUDA only supports Visual Studio at most 2010... Is this true? (My installation of the CUDA Toolkit doesn't detect any Visual Studio installation!)

$\endgroup$
  • $\begingroup$ I suspect that you might have checked these already, but just in case, take a look at the setup and testing section of the CUDALink docs: reference.wolfram.com/language/CUDALink/tutorial/Setup.html . There are some limited troubleshooting tips mainly regarding the location of required files / drivers / compilers. $\endgroup$ – MarcoB Nov 10 '15 at 5:33
  • 1
    $\begingroup$ What do CUDACCompilers[], CUDAResourcesInformation[], GPUTools`Internal`$NVIDIADriverLibraryPath, GPUTools`Internal`$CUDALibraryPath, and $CUDALinkPath return? $\endgroup$ – Karsten 7. Nov 10 '15 at 5:34
  • 1
    $\begingroup$ Also SystemInformation["Devices", "GraphicsDevices"][[1]] would be important. $\endgroup$ – Karsten 7. Nov 10 '15 at 5:39
  • 3
    $\begingroup$ CUDACCompilers[] is the only thing that doesn't look O.K. mathematica.stackexchange.com/a/91845 should help to solve the issue. $\endgroup$ – Karsten 7. Nov 10 '15 at 6:51
  • 2
    $\begingroup$ @DiegoAlonsoCortez: There might be a way to get the MSVC compiler from visual studio to work with Mathematica (I imagine I read about that somewhere), but out of the box Mathematica only supports VS 2013 or older versions. $\endgroup$ – Wizard Nov 10 '15 at 10:01

Browse other questions tagged or ask your own question.