affinity fix for tensorflow conversion

Signed-off-by: raver119 <raver119@gmail.com>
master
raver119 2019-08-17 17:59:14 +03:00
parent 56910ddee7
commit 000334ea2a
1 changed files with 1 additions and 1 deletions

View File

@ -296,7 +296,7 @@ public class TensorflowConversion {
* @return * @return
*/ */
public static String defaultDeviceForThread() { public static String defaultDeviceForThread() {
Integer deviceForThread = Nd4j.getAffinityManager().getDeviceForThread(Thread.currentThread()); Integer deviceForThread = Nd4j.getAffinityManager().getDeviceForCurrentThread();
String deviceName = null; String deviceName = null;
//gpu //gpu
if(Nd4j.getBackend().getClass().getName().contains("JCublasBackend")) { if(Nd4j.getBackend().getClass().getName().contains("JCublasBackend")) {