public interface Batchifier
NDList
into a batched NDList
and vice versa.
Different implementations of Batchifier
represent different ways of creating batches.
The most common would be the StackBatchifier
that batchifies by creating a new batch axis
as axis 0. Another implementation could be a concatenated batchifier for sequence elements that
will concatenate the data elements along the time axis.
Modifier and Type | Field and Description |
---|---|
static Batchifier |
STACK |
Modifier and Type | Method and Description |
---|---|
NDList |
batchify(NDList[] inputs)
Converts an array of
NDList into an NDList. |
static Batchifier |
fromString(java.lang.String name)
Returns a batchifier from a batchifier name.
|
default NDList[] |
split(NDList list,
int numOfSlices,
boolean evenSplit)
Splits the given
NDList into the given number of slices. |
NDList[] |
unbatchify(NDList inputs)
Reverses the
batchify operation. |
static final Batchifier STACK
static Batchifier fromString(java.lang.String name)
name
- the batchifier namejava.lang.IllegalArgumentException
- if an invalid name is givenNDList[] unbatchify(NDList inputs)
batchify
operation.inputs
- the NDList
that needs to be 'unbatchified'