public class NEFGPUInterface
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected float |
myEndTime |
protected NEFEnsembleImpl[] |
myGPUEnsembles |
protected Node[] |
myGPUNetworkArrays |
protected Projection[] |
myGPUProjections |
protected Node[] |
myNodes |
protected Projection[] |
myProjections |
protected boolean |
myRequireAllOutputsOnCPU |
protected float |
myStartTime |
protected Projection[] |
nonGPUProjections |
Constructor and Description |
---|
NEFGPUInterface(boolean interactive) |
Modifier and Type | Method and Description |
---|---|
static int[] |
findOptimalNodeAssignments(Node[] nodes,
Projection[] projections,
int numPartitions)
Used when there are multiple GPU's running a simulation.
|
static java.lang.String |
getErrorMessage() |
static int |
getNumDetectedDevices() |
static int |
getNumDevices() |
static boolean |
getUseGPU() |
static void |
hideGPUTiming() |
void |
initialize()
Gets all the necessary data from the nodes and projections which are assigned to run on GPUss
and puts it in a form appropriate for passing to the native setup function.
|
void |
kill() |
static void |
setNumDevices(int value) |
void |
setRequireAllOutputsOnCPU(boolean require) |
static void |
showGPUTiming() |
void |
step(float startTime,
float endTime)
1.
|
Node[] |
takeGPUNodes(Node[] nodes)
Finds all nodes in the given array which are supposed to execute on the GPU.
|
Projection[] |
takeGPUProjections(Projection[] projections)
Finds all projections in the given array which are supposed to execute on the GPU.
|
protected boolean myRequireAllOutputsOnCPU
protected NEFEnsembleImpl[] myGPUEnsembles
protected Projection[] myGPUProjections
protected Projection[] nonGPUProjections
protected Node[] myGPUNetworkArrays
protected Node[] myNodes
protected Projection[] myProjections
protected float myStartTime
protected float myEndTime
public static int getNumDetectedDevices()
public static void setNumDevices(int value)
public static int getNumDevices()
public static boolean getUseGPU()
public static void showGPUTiming()
public static void hideGPUTiming()
public static java.lang.String getErrorMessage()
public void setRequireAllOutputsOnCPU(boolean require)
public void initialize()
public void step(float startTime, float endTime)
public void kill()
public static int[] findOptimalNodeAssignments(Node[] nodes, Projection[] projections, int numPartitions)
public Node[] takeGPUNodes(Node[] nodes)
public Projection[] takeGPUProjections(Projection[] projections)