public abstract class Nd4jBackend extends Object
Modifier and Type | Class and Description |
---|---|
static class |
Nd4jBackend.NoAvailableBackendException |
Modifier and Type | Field and Description |
---|---|
static int |
BACKEND_PRIORITY_CPU |
static int |
BACKEND_PRIORITY_GPU |
static String |
DYNAMIC_LOAD_CLASSPATH
Deprecated.
|
static String |
DYNAMIC_LOAD_CLASSPATH_PROPERTY
Deprecated.
|
Constructor and Description |
---|
Nd4jBackend() |
Modifier and Type | Method and Description |
---|---|
abstract boolean |
allowsOrder()
Returns true if the
backend allows order to be specified
on blas operations (cblas)
|
abstract boolean |
canRun()
Returns true if the backend can
run on the os or not
|
abstract Resource |
getConfigurationResource()
Get the configuration resource
|
Nd4jContext |
getContext() |
abstract Environment |
getEnvironment() |
abstract Class |
getNDArrayClass()
Get the actual (concrete/implementation) class for standard INDArrays for this backend
|
abstract int |
getPriority()
Gets a priority number for the backend.
|
Properties |
getProperties() |
abstract boolean |
isAvailable()
Determines whether a given backend is available in the current environment.
|
static Nd4jBackend |
load()
Loads the best available backend.
|
static void |
loadLibrary(File jar)
Adds the supplied Java Archive library to java.class.path.
|
abstract void |
logBackendInit() |
String |
toString() |
public static final int BACKEND_PRIORITY_CPU
public static final int BACKEND_PRIORITY_GPU
@Deprecated public static final String DYNAMIC_LOAD_CLASSPATH
ND4JEnvironmentVars.BACKEND_DYNAMIC_LOAD_CLASSPATH
@Deprecated public static final String DYNAMIC_LOAD_CLASSPATH_PROPERTY
ND4JSystemProperties.DYNAMIC_LOAD_CLASSPATH_PROPERTY
public abstract boolean allowsOrder()
public abstract int getPriority()
public abstract boolean isAvailable()
public abstract boolean canRun()
public abstract Resource getConfigurationResource()
public abstract Class getNDArrayClass()
public abstract Environment getEnvironment()
public static Nd4jBackend load() throws Nd4jBackend.NoAvailableBackendException
Nd4jBackend.NoAvailableBackendException
public static void loadLibrary(File jar) throws Nd4jBackend.NoAvailableBackendException
jar
- the jar file to addNd4jBackend.NoAvailableBackendException
public Properties getProperties() throws IOException
IOException
public Nd4jContext getContext() throws IOException
IOException
public abstract void logBackendInit()
Copyright © 2020. All rights reserved.