Class LeakyReLU
- java.lang.Object
-
- org.nd4j.autodiff.functions.DifferentialFunction
-
- org.nd4j.linalg.api.ops.BaseOp
-
- org.nd4j.linalg.api.ops.BaseScalarOp
-
- org.nd4j.linalg.api.ops.impl.scalar.LeakyReLU
-
public class LeakyReLU extends BaseScalarOp
-
-
Field Summary
Fields Modifier and Type Field Description static doubleDEFAULT_ALPHA-
Fields inherited from class org.nd4j.linalg.api.ops.BaseOp
dimensionz, extraArgz, x, xVertexId, y, yVertexId, z, zVertexId
-
Fields inherited from class org.nd4j.autodiff.functions.DifferentialFunction
dimensions, extraArgs, inPlace, ownName, ownNameSetWithDefault, sameDiff, scalarValue
-
-
Constructor Summary
Constructors Constructor Description LeakyReLU()LeakyReLU(SameDiff sameDiff, SDVariable i_v, boolean inPlace, double alpha)LeakyReLU(SameDiff sameDiff, SDVariable i_v, double alpha)LeakyReLU(SameDiff sameDiff, SDVariable i_v, Number scalar)LeakyReLU(SameDiff sameDiff, SDVariable i_v, Object[] extraArgs, double alpha)LeakyReLU(INDArray x)LeakyReLU(INDArray x, double alpha)LeakyReLU(INDArray x, INDArray z)LeakyReLU(INDArray x, INDArray z, double alpha)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<SDVariable>doDiff(List<SDVariable> i_v)The actual implementation for automatic differentiation.voidinitFromTensorFlow(NodeDef nodeDef, SameDiff initWith, Map<String,AttrValue> attributesForNode, GraphDef graph)Initialize the function from the givenNodeDefStringonnxName()The opName of this function in onnxStringopName()The name of the opintopNum()The number of the op (mainly for old legacy XYZ ops likeOp)voidsetPropertiesForFunction(Map<String,Object> properties)StringtensorflowName()The opName of this function tensorflow-
Methods inherited from class org.nd4j.linalg.api.ops.BaseScalarOp
calculateOutputDataTypes, calculateOutputShape, calculateOutputShape, getDimension, getOpType, opType, scalar, setDimension, setScalar, setScalar, validateDataTypes, z
-
Methods inherited from class org.nd4j.linalg.api.ops.BaseOp
clearArrays, computeVariables, defineDimensions, dimensions, equals, extraArgs, extraArgsBuff, extraArgsDataBuff, getFinalResult, getInputArgument, getNumOutputs, getOpType, hashCode, initFromOnnx, outputVariables, setX, setY, setZ, toCustomOp, toString, x, y
-
Methods inherited from class org.nd4j.autodiff.functions.DifferentialFunction
arg, arg, argNames, args, attributeAdaptersForFunction, configFieldName, configureWithSameDiff, diff, dup, getBooleanFromProperty, getDoubleValueFromProperty, getIntValueFromProperty, getLongValueFromProperty, getStringFromProperty, getValue, isConfigProperties, larg, mappingsForFunction, onnxNames, outputs, outputVariable, outputVariables, outputVariablesNames, propertiesForFunction, rarg, replaceArg, setInstanceId, setValueFor, tensorflowNames
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.nd4j.linalg.api.ops.Op
clearArrays, extraArgs, extraArgsBuff, extraArgsDataBuff, setExtraArgs, setX, setY, setZ, toCustomOp, x, y
-
Methods inherited from interface org.nd4j.linalg.api.ops.ScalarOp
dimensions
-
-
-
-
Field Detail
-
DEFAULT_ALPHA
public static final double DEFAULT_ALPHA
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
LeakyReLU
public LeakyReLU(SameDiff sameDiff, SDVariable i_v, boolean inPlace, double alpha)
-
LeakyReLU
public LeakyReLU(SameDiff sameDiff, SDVariable i_v, double alpha)
-
LeakyReLU
public LeakyReLU(SameDiff sameDiff, SDVariable i_v, Object[] extraArgs, double alpha)
-
LeakyReLU
public LeakyReLU()
-
LeakyReLU
public LeakyReLU(INDArray x, double alpha)
-
LeakyReLU
public LeakyReLU(INDArray x)
-
LeakyReLU
public LeakyReLU(SameDiff sameDiff, SDVariable i_v, Number scalar)
-
-
Method Detail
-
opNum
public int opNum()
Description copied from class:DifferentialFunctionThe number of the op (mainly for old legacy XYZ ops likeOp)- Specified by:
opNumin interfaceOp- Overrides:
opNumin classDifferentialFunction- Returns:
-
opName
public String opName()
Description copied from class:DifferentialFunctionThe name of the op- Specified by:
opNamein interfaceOp- Overrides:
opNamein classDifferentialFunction- Returns:
- the opName of this operation
-
onnxName
public String onnxName()
Description copied from class:DifferentialFunctionThe opName of this function in onnx
-
tensorflowName
public String tensorflowName()
Description copied from class:DifferentialFunctionThe opName of this function tensorflow- Overrides:
tensorflowNamein classBaseOp- Returns:
-
setPropertiesForFunction
public void setPropertiesForFunction(Map<String,Object> properties)
- Overrides:
setPropertiesForFunctionin classDifferentialFunction
-
doDiff
public List<SDVariable> doDiff(List<SDVariable> i_v)
Description copied from class:DifferentialFunctionThe actual implementation for automatic differentiation.- Specified by:
doDiffin classDifferentialFunction- Returns:
-
initFromTensorFlow
public void initFromTensorFlow(NodeDef nodeDef, SameDiff initWith, Map<String,AttrValue> attributesForNode, GraphDef graph)
Description copied from class:DifferentialFunctionInitialize the function from the givenNodeDef- Overrides:
initFromTensorFlowin classBaseOp
-
-