public class LSTMLayer extends DynamicCustomOp
DynamicCustomOp.DynamicCustomOpsBuilderaxis, bArguments, dArguments, iArguments, inplaceCall, inputArguments, outputArguments, outputVariables, tArgumentsdimensions, extraArgs, inPlace, ownName, ownNameSetWithDefault, sameDiff, scalarValue| Constructor and Description |
|---|
LSTMLayer(INDArray x,
INDArray cLast,
INDArray yLast,
INDArray maxTSLength,
LSTMLayerWeights lstmWeights,
LSTMLayerConfig LSTMLayerConfig) |
LSTMLayer(@NonNull SameDiff sameDiff,
SDVariable x,
SDVariable cLast,
SDVariable yLast,
SDVariable maxTSLength,
LSTMLayerWeights weights,
LSTMLayerConfig configuration) |
| Modifier and Type | Method and Description |
|---|---|
protected <T> boolean[] |
bArgs(LSTMLayerWeights weights,
T maxTSLength,
T yLast,
T cLast) |
List<DataType> |
calculateOutputDataTypes(List<DataType> inputDataTypes)
Calculate the data types for the output arrays.
|
String |
configFieldName()
Returns the name of the field to be used for looking up field names.
|
List<SDVariable> |
doDiff(List<SDVariable> grads)
The actual implementation for automatic differentiation.
|
int |
getNumOutputs() |
long[] |
iArgs() |
boolean |
isConfigProperties()
Returns true if the fields for this class should be looked up from a configuration class.
|
String |
opName()
This method returns op opName as string
|
Map<String,Object> |
propertiesForFunction()
Returns the properties for a given function
|
double[] |
tArgs() |
addBArgument, addDArgument, addIArgument, addIArgument, addInputArgument, addOutputArgument, addTArgument, assertValidForExecution, bArgs, builder, calculateOutputShape, calculateOutputShape, clearArrays, dArgs, getBArgument, getDescriptor, getIArgument, getInputArgument, getOutputArgument, getTArgument, initFromOnnx, initFromTensorFlow, inputArguments, numBArguments, numDArguments, numIArguments, numInputArguments, numOutputArguments, numTArguments, onnxName, opHash, opNum, opType, outputArguments, outputVariables, outputVariables, removeIArgument, removeInputArgument, removeOutputArgument, removeTArgument, setInputArgument, setInputArguments, setOutputArgument, tensorflowName, toString, wrapFilterNull, wrapOrNull, wrapOrNullarg, arg, argNames, args, attributeAdaptersForFunction, diff, dup, equals, getValue, hashCode, larg, mappingsForFunction, onnxNames, outputs, outputVariable, outputVariablesNames, rarg, replaceArg, setInstanceId, setPropertiesForFunction, setValueFor, tensorflowNamesclone, finalize, getClass, notify, notifyAll, wait, wait, waitisInplaceCallpublic LSTMLayer(@NonNull
@NonNull SameDiff sameDiff,
SDVariable x,
SDVariable cLast,
SDVariable yLast,
SDVariable maxTSLength,
LSTMLayerWeights weights,
LSTMLayerConfig configuration)
public LSTMLayer(INDArray x, INDArray cLast, INDArray yLast, INDArray maxTSLength, LSTMLayerWeights lstmWeights, LSTMLayerConfig LSTMLayerConfig)
public List<DataType> calculateOutputDataTypes(List<DataType> inputDataTypes)
DifferentialFunctionDifferentialFunction.calculateOutputShape(), this method differs in that it does not
require the input arrays to be populated.
This is important as it allows us to do greedy datatype inference for the entire net - even if arrays are not
available.calculateOutputDataTypes in class DifferentialFunctioninputDataTypes - The data types of the inputspublic List<SDVariable> doDiff(List<SDVariable> grads)
DifferentialFunctiondoDiff in class DynamicCustomOppublic String opName()
DynamicCustomOpopName in interface CustomOpopName in class DynamicCustomOppublic Map<String,Object> propertiesForFunction()
DifferentialFunctionpropertiesForFunction in class DifferentialFunctionpublic long[] iArgs()
iArgs in interface CustomOpiArgs in class DynamicCustomOppublic double[] tArgs()
tArgs in interface CustomOptArgs in class DynamicCustomOpprotected <T> boolean[] bArgs(LSTMLayerWeights weights, T maxTSLength, T yLast, T cLast)
public boolean isConfigProperties()
DifferentialFunctionisConfigProperties in class DifferentialFunctionpublic String configFieldName()
DifferentialFunctionDifferentialFunction.isConfigProperties()
to facilitate mapping fields for model import.configFieldName in class DifferentialFunctionpublic int getNumOutputs()
getNumOutputs in class DifferentialFunctionCopyright © 2021. All rights reserved.