1

I've been running a DL4J project on my laptop using my mobile gpu. It runs fine, the gpu is detected and my models get trained. But after switching to a desktop with discrete graphics, the same program attempts to use the cpu! Both machines are running ubuntu 18.04 and have cuda 9.0 installed.

When the program starts, I get this output from the laptop:

INFO: Loaded [JCublasBackend] backend Dec 05, 2018 3:26:33 AM org.nd4j.nativeblas.NativeOpsHolder INFO: Number of threads used for NativeOps: 32 Dec 05, 2018 3:26:33 AM org.nd4j.nativeblas.Nd4jBlas INFO: Number of threads used for BLAS: 0 Dec 05, 2018 3:26:33 AM org.nd4j.linalg.api.ops.executioner.DefaultOpExecutioner printEnvironmentInformation INFO: Backend used: [CUDA]; OS: [Linux] Dec 05, 2018 3:26:33 AM org.nd4j.linalg.api.ops.executioner.DefaultOpExecutioner printEnvironmentInformation INFO: Cores: [8]; Memory: [3.4GB]; Dec 05, 2018 3:26:33 AM org.nd4j.linalg.api.ops.executioner.DefaultOpExecutioner printEnvironmentInformation INFO: Blas vendor: [CUBLAS] Dec 05, 2018 3:26:33 AM org.nd4j.linalg.jcublas.ops.executioner.CudaExecutioner printEnvironmentInformation INFO: Device Name: [GeForce GTX 960M]; CC: [5.0]; Total/free memory: [4242604032]

And this from the desktop:

03:29:44.843 [main] INFO org.nd4j.linalg.factory.Nd4jBackend - Loaded [CpuBackend] backend

A crash happens immediately after since my dependencies include nd4j-cuda-9.0-platform and not nd4j-native-platform.

I'm pretty sure cuda is working on the desktop, I've run tensorflow-gpu programs on it without any issues.

I use gradle, here is the dependencies section of my build.gradle:

compile group: 'org.deeplearning4j', name: 'deeplearning4j-core', version: '1.0.0-beta'
compile group: 'org.nd4j', name: 'nd4j-cuda-9.0-platform', version: '1.0.0-beta'
compile group: 'org.datavec', name: 'datavec-api', version: '1.0.0-beta'
compile group: 'org.deeplearning4j', name: 'rl4j-core', version: '1.0.0-beta'
compile group: 'org.deeplearning4j', name: 'rl4j-api', version: '1.0.0-beta'
compile group: 'org.deeplearning4j', name: 'deeplearning4j-cuda-9.0', version: '1.0.0-beta'
compile group: 'org.deeplearning4j', name: 'deeplearning4j-ui_2.10', version: '1.0.0-beta'

I could be missing something basic here. Any help is greatly appreciated.

0 Answers0