public final class GradientDef extends org.nd4j.shade.protobuf.GeneratedMessageV3 implements GradientDefOrBuilder
GradientDef defines the gradient function of a function defined in
a function library.
A gradient function g (specified by gradient_func) for a function f
(specified by function_name) must follow the following:
The function 'f' must be a numerical function which takes N inputs
and produces M outputs. Its gradient function 'g', which is a
function taking N + M inputs and produces N outputs.
I.e. if we have
(y1, y2, ..., y_M) = f(x1, x2, ..., x_N),
then, g is
(dL/dx1, dL/dx2, ..., dL/dx_N) = g(x1, x2, ..., x_N,
dL/dy1, dL/dy2, ..., dL/dy_M),
where L is a scalar-value function of (x1, x2, ..., xN) (e.g., the
loss function). dL/dx_i is the partial derivative of L with respect
to x_i.
Protobuf type tensorflow.GradientDef| Modifier and Type | Class and Description |
|---|---|
static class |
GradientDef.Builder
GradientDef defines the gradient function of a function defined in
a function library.
|
org.nd4j.shade.protobuf.GeneratedMessageV3.BuilderParent, org.nd4j.shade.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType extends org.nd4j.shade.protobuf.GeneratedMessageV3.ExtendableMessage,BuilderType extends org.nd4j.shade.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType,BuilderType>>, org.nd4j.shade.protobuf.GeneratedMessageV3.ExtendableMessage<MessageType extends org.nd4j.shade.protobuf.GeneratedMessageV3.ExtendableMessage>, org.nd4j.shade.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends org.nd4j.shade.protobuf.GeneratedMessageV3.ExtendableMessage>, org.nd4j.shade.protobuf.GeneratedMessageV3.FieldAccessorTable, org.nd4j.shade.protobuf.GeneratedMessageV3.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
FUNCTION_NAME_FIELD_NUMBER |
static int |
GRADIENT_FUNC_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
static GradientDef |
getDefaultInstance() |
GradientDef |
getDefaultInstanceForType() |
static org.nd4j.shade.protobuf.Descriptors.Descriptor |
getDescriptor() |
String |
getFunctionName()
The function name.
|
org.nd4j.shade.protobuf.ByteString |
getFunctionNameBytes()
The function name.
|
String |
getGradientFunc()
The gradient function's name.
|
org.nd4j.shade.protobuf.ByteString |
getGradientFuncBytes()
The gradient function's name.
|
org.nd4j.shade.protobuf.Parser<GradientDef> |
getParserForType() |
int |
getSerializedSize() |
org.nd4j.shade.protobuf.UnknownFieldSet |
getUnknownFields() |
int |
hashCode() |
protected org.nd4j.shade.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
static GradientDef.Builder |
newBuilder() |
static GradientDef.Builder |
newBuilder(GradientDef prototype) |
GradientDef.Builder |
newBuilderForType() |
protected GradientDef.Builder |
newBuilderForType(org.nd4j.shade.protobuf.GeneratedMessageV3.BuilderParent parent) |
protected Object |
newInstance(org.nd4j.shade.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) |
static GradientDef |
parseDelimitedFrom(InputStream input) |
static GradientDef |
parseDelimitedFrom(InputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) |
static GradientDef |
parseFrom(byte[] data) |
static GradientDef |
parseFrom(byte[] data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) |
static GradientDef |
parseFrom(ByteBuffer data) |
static GradientDef |
parseFrom(ByteBuffer data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) |
static GradientDef |
parseFrom(org.nd4j.shade.protobuf.ByteString data) |
static GradientDef |
parseFrom(org.nd4j.shade.protobuf.ByteString data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) |
static GradientDef |
parseFrom(org.nd4j.shade.protobuf.CodedInputStream input) |
static GradientDef |
parseFrom(org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) |
static GradientDef |
parseFrom(InputStream input) |
static GradientDef |
parseFrom(InputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) |
static org.nd4j.shade.protobuf.Parser<GradientDef> |
parser() |
GradientDef.Builder |
toBuilder() |
void |
writeTo(org.nd4j.shade.protobuf.CodedOutputStream output) |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneof, internalGetMapField, makeExtensionsImmutable, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringaddAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int FUNCTION_NAME_FIELD_NUMBER
public static final int GRADIENT_FUNC_FIELD_NUMBER
protected Object newInstance(org.nd4j.shade.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
newInstance in class org.nd4j.shade.protobuf.GeneratedMessageV3public final org.nd4j.shade.protobuf.UnknownFieldSet getUnknownFields()
getUnknownFields in interface org.nd4j.shade.protobuf.MessageOrBuildergetUnknownFields in class org.nd4j.shade.protobuf.GeneratedMessageV3public static final org.nd4j.shade.protobuf.Descriptors.Descriptor getDescriptor()
protected org.nd4j.shade.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class org.nd4j.shade.protobuf.GeneratedMessageV3public String getFunctionName()
The function name.
string function_name = 1;getFunctionName in interface GradientDefOrBuilderpublic org.nd4j.shade.protobuf.ByteString getFunctionNameBytes()
The function name.
string function_name = 1;getFunctionNameBytes in interface GradientDefOrBuilderpublic String getGradientFunc()
The gradient function's name.
string gradient_func = 2;getGradientFunc in interface GradientDefOrBuilderpublic org.nd4j.shade.protobuf.ByteString getGradientFuncBytes()
The gradient function's name.
string gradient_func = 2;getGradientFuncBytes in interface GradientDefOrBuilderpublic final boolean isInitialized()
isInitialized in interface org.nd4j.shade.protobuf.MessageLiteOrBuilderisInitialized in class org.nd4j.shade.protobuf.GeneratedMessageV3public void writeTo(org.nd4j.shade.protobuf.CodedOutputStream output)
throws IOException
writeTo in interface org.nd4j.shade.protobuf.MessageLitewriteTo in class org.nd4j.shade.protobuf.GeneratedMessageV3IOExceptionpublic int getSerializedSize()
getSerializedSize in interface org.nd4j.shade.protobuf.MessageLitegetSerializedSize in class org.nd4j.shade.protobuf.GeneratedMessageV3public boolean equals(Object obj)
equals in interface org.nd4j.shade.protobuf.Messageequals in class org.nd4j.shade.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface org.nd4j.shade.protobuf.MessagehashCode in class org.nd4j.shade.protobuf.AbstractMessagepublic static GradientDef parseFrom(ByteBuffer data) throws org.nd4j.shade.protobuf.InvalidProtocolBufferException
org.nd4j.shade.protobuf.InvalidProtocolBufferExceptionpublic static GradientDef parseFrom(ByteBuffer data, org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) throws org.nd4j.shade.protobuf.InvalidProtocolBufferException
org.nd4j.shade.protobuf.InvalidProtocolBufferExceptionpublic static GradientDef parseFrom(org.nd4j.shade.protobuf.ByteString data) throws org.nd4j.shade.protobuf.InvalidProtocolBufferException
org.nd4j.shade.protobuf.InvalidProtocolBufferExceptionpublic static GradientDef parseFrom(org.nd4j.shade.protobuf.ByteString data, org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) throws org.nd4j.shade.protobuf.InvalidProtocolBufferException
org.nd4j.shade.protobuf.InvalidProtocolBufferExceptionpublic static GradientDef parseFrom(byte[] data) throws org.nd4j.shade.protobuf.InvalidProtocolBufferException
org.nd4j.shade.protobuf.InvalidProtocolBufferExceptionpublic static GradientDef parseFrom(byte[] data, org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) throws org.nd4j.shade.protobuf.InvalidProtocolBufferException
org.nd4j.shade.protobuf.InvalidProtocolBufferExceptionpublic static GradientDef parseFrom(InputStream input) throws IOException
IOExceptionpublic static GradientDef parseFrom(InputStream input, org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static GradientDef parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static GradientDef parseDelimitedFrom(InputStream input, org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static GradientDef parseFrom(org.nd4j.shade.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static GradientDef parseFrom(org.nd4j.shade.protobuf.CodedInputStream input, org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic GradientDef.Builder newBuilderForType()
newBuilderForType in interface org.nd4j.shade.protobuf.MessagenewBuilderForType in interface org.nd4j.shade.protobuf.MessageLitepublic static GradientDef.Builder newBuilder()
public static GradientDef.Builder newBuilder(GradientDef prototype)
public GradientDef.Builder toBuilder()
toBuilder in interface org.nd4j.shade.protobuf.MessagetoBuilder in interface org.nd4j.shade.protobuf.MessageLiteprotected GradientDef.Builder newBuilderForType(org.nd4j.shade.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class org.nd4j.shade.protobuf.GeneratedMessageV3public static GradientDef getDefaultInstance()
public static org.nd4j.shade.protobuf.Parser<GradientDef> parser()
public org.nd4j.shade.protobuf.Parser<GradientDef> getParserForType()
getParserForType in interface org.nd4j.shade.protobuf.MessagegetParserForType in interface org.nd4j.shade.protobuf.MessageLitegetParserForType in class org.nd4j.shade.protobuf.GeneratedMessageV3public GradientDef getDefaultInstanceForType()
getDefaultInstanceForType in interface org.nd4j.shade.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface org.nd4j.shade.protobuf.MessageOrBuilderCopyright © 2021. All rights reserved.