public class PtNDManager
extends ai.djl.ndarray.BaseNDManager
PtNDManager
is the PyTorch implementation of NDManager
.Modifier and Type | Method and Description |
---|---|
java.nio.ByteBuffer |
allocateDirect(int capacity) |
ai.djl.ndarray.NDArray |
arange(float start,
float stop,
float step,
ai.djl.ndarray.types.DataType dataType) |
ai.djl.ndarray.NDArray |
arange(int start,
int stop,
int step,
ai.djl.ndarray.types.DataType dataType) |
PtNDArray |
create(java.nio.Buffer data,
ai.djl.ndarray.types.Shape shape,
ai.djl.ndarray.types.DataType dataType) |
PtNDArray |
create(ai.djl.ndarray.types.Shape shape,
ai.djl.ndarray.types.DataType dataType) |
ai.djl.ndarray.NDArray |
createCoo(java.nio.Buffer data,
long[][] indices,
ai.djl.ndarray.types.Shape shape) |
ai.djl.ndarray.NDArray |
eye(int rows,
int cols,
int k,
ai.djl.ndarray.types.DataType dataType) |
ai.djl.ndarray.NDArray |
full(ai.djl.ndarray.types.Shape shape,
float value,
ai.djl.ndarray.types.DataType dataType) |
ai.djl.engine.Engine |
getEngine() |
ai.djl.ndarray.NDArray |
linspace(float start,
float stop,
int num,
boolean endpoint) |
PtNDManager |
newSubManager(ai.djl.Device device) |
ai.djl.ndarray.NDArray |
ones(ai.djl.ndarray.types.Shape shape,
ai.djl.ndarray.types.DataType dataType) |
ai.djl.ndarray.NDArray |
randomInteger(long low,
long high,
ai.djl.ndarray.types.Shape shape,
ai.djl.ndarray.types.DataType dataType) |
ai.djl.ndarray.NDArray |
randomNormal(float loc,
float scale,
ai.djl.ndarray.types.Shape shape,
ai.djl.ndarray.types.DataType dataType) |
ai.djl.ndarray.NDArray |
randomUniform(float low,
float high,
ai.djl.ndarray.types.Shape shape,
ai.djl.ndarray.types.DataType dataType) |
ai.djl.ndarray.NDArray |
zeros(ai.djl.ndarray.types.Shape shape,
ai.djl.ndarray.types.DataType dataType) |
attachInternal, close, create, create, createCSR, createRowSparse, debugDump, detachInternal, getDevice, getName, getParentManager, invoke, invoke, isOpen, load, newSubManager, randomMultinomial, randomMultinomial, setName, tempAttachInternal, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
arange, arange, arange, arange, arange, arange, arange, attachAll, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, create, createCSR, createCSR, createRowSparse, decode, decode, eye, eye, eye, eye, from, full, full, full, linspace, linspace, linspace, linspace, load, newBaseManager, newBaseManager, newBaseManager, ones, ones, randomNormal, randomNormal, randomNormal, randomUniform, randomUniform, ret, tempAttachAll, zeros, zeros
public java.nio.ByteBuffer allocateDirect(int capacity)
public PtNDArray create(ai.djl.ndarray.types.Shape shape, ai.djl.ndarray.types.DataType dataType)
create
in interface ai.djl.ndarray.NDManager
create
in class ai.djl.ndarray.BaseNDManager
public PtNDArray create(java.nio.Buffer data, ai.djl.ndarray.types.Shape shape, ai.djl.ndarray.types.DataType dataType)
public ai.djl.ndarray.NDArray createCoo(java.nio.Buffer data, long[][] indices, ai.djl.ndarray.types.Shape shape)
createCoo
in interface ai.djl.ndarray.NDManager
createCoo
in class ai.djl.ndarray.BaseNDManager
public ai.djl.ndarray.NDArray zeros(ai.djl.ndarray.types.Shape shape, ai.djl.ndarray.types.DataType dataType)
zeros
in interface ai.djl.ndarray.NDManager
zeros
in class ai.djl.ndarray.BaseNDManager
public ai.djl.ndarray.NDArray ones(ai.djl.ndarray.types.Shape shape, ai.djl.ndarray.types.DataType dataType)
ones
in interface ai.djl.ndarray.NDManager
ones
in class ai.djl.ndarray.BaseNDManager
public ai.djl.ndarray.NDArray full(ai.djl.ndarray.types.Shape shape, float value, ai.djl.ndarray.types.DataType dataType)
full
in interface ai.djl.ndarray.NDManager
full
in class ai.djl.ndarray.BaseNDManager
public ai.djl.ndarray.NDArray arange(int start, int stop, int step, ai.djl.ndarray.types.DataType dataType)
public ai.djl.ndarray.NDArray arange(float start, float stop, float step, ai.djl.ndarray.types.DataType dataType)
arange
in interface ai.djl.ndarray.NDManager
arange
in class ai.djl.ndarray.BaseNDManager
public ai.djl.ndarray.NDArray eye(int rows, int cols, int k, ai.djl.ndarray.types.DataType dataType)
eye
in interface ai.djl.ndarray.NDManager
eye
in class ai.djl.ndarray.BaseNDManager
public ai.djl.ndarray.NDArray linspace(float start, float stop, int num, boolean endpoint)
linspace
in interface ai.djl.ndarray.NDManager
linspace
in class ai.djl.ndarray.BaseNDManager
public ai.djl.ndarray.NDArray randomInteger(long low, long high, ai.djl.ndarray.types.Shape shape, ai.djl.ndarray.types.DataType dataType)
randomInteger
in interface ai.djl.ndarray.NDManager
randomInteger
in class ai.djl.ndarray.BaseNDManager
public ai.djl.ndarray.NDArray randomUniform(float low, float high, ai.djl.ndarray.types.Shape shape, ai.djl.ndarray.types.DataType dataType)
randomUniform
in interface ai.djl.ndarray.NDManager
randomUniform
in class ai.djl.ndarray.BaseNDManager
public ai.djl.ndarray.NDArray randomNormal(float loc, float scale, ai.djl.ndarray.types.Shape shape, ai.djl.ndarray.types.DataType dataType)
randomNormal
in interface ai.djl.ndarray.NDManager
randomNormal
in class ai.djl.ndarray.BaseNDManager
public PtNDManager newSubManager(ai.djl.Device device)
public final ai.djl.engine.Engine getEngine()