public final class SmoothGradConfig extends com.google.protobuf.GeneratedMessageV3 implements SmoothGradConfigOrBuilder
Config for SmoothGrad approximation of gradients. When enabled, the gradients are approximated by averaging the gradients from noisy samples in the vicinity of the inputs. Adding noise can help improve the computed gradients. Refer to this paper for more details: https://arxiv.org/pdf/1706.03825.pdfProtobuf type
google.cloud.aiplatform.v1.SmoothGradConfig| Modifier and Type | Class and Description |
|---|---|
static class |
SmoothGradConfig.Builder
Config for SmoothGrad approximation of gradients.
|
static class |
SmoothGradConfig.GradientNoiseSigmaCase |
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
FEATURE_NOISE_SIGMA_FIELD_NUMBER |
static int |
NOISE_SIGMA_FIELD_NUMBER |
static int |
NOISY_SAMPLE_COUNT_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
static SmoothGradConfig |
getDefaultInstance() |
SmoothGradConfig |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
FeatureNoiseSigma |
getFeatureNoiseSigma()
This is similar to
[noise_sigma][google.cloud.aiplatform.v1.SmoothGradConfig.noise_sigma],
but provides additional flexibility.
|
FeatureNoiseSigmaOrBuilder |
getFeatureNoiseSigmaOrBuilder()
This is similar to
[noise_sigma][google.cloud.aiplatform.v1.SmoothGradConfig.noise_sigma],
but provides additional flexibility.
|
SmoothGradConfig.GradientNoiseSigmaCase |
getGradientNoiseSigmaCase() |
float |
getNoiseSigma()
This is a single float value and will be used to add noise to all the
features.
|
int |
getNoisySampleCount()
The number of gradient samples to use for
approximation.
|
com.google.protobuf.Parser<SmoothGradConfig> |
getParserForType() |
int |
getSerializedSize() |
boolean |
hasFeatureNoiseSigma()
This is similar to
[noise_sigma][google.cloud.aiplatform.v1.SmoothGradConfig.noise_sigma],
but provides additional flexibility.
|
int |
hashCode() |
boolean |
hasNoiseSigma()
This is a single float value and will be used to add noise to all the
features.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
static SmoothGradConfig.Builder |
newBuilder() |
static SmoothGradConfig.Builder |
newBuilder(SmoothGradConfig prototype) |
SmoothGradConfig.Builder |
newBuilderForType() |
protected SmoothGradConfig.Builder |
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
protected Object |
newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) |
static SmoothGradConfig |
parseDelimitedFrom(InputStream input) |
static SmoothGradConfig |
parseDelimitedFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static SmoothGradConfig |
parseFrom(byte[] data) |
static SmoothGradConfig |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static SmoothGradConfig |
parseFrom(ByteBuffer data) |
static SmoothGradConfig |
parseFrom(ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static SmoothGradConfig |
parseFrom(com.google.protobuf.ByteString data) |
static SmoothGradConfig |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static SmoothGradConfig |
parseFrom(com.google.protobuf.CodedInputStream input) |
static SmoothGradConfig |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static SmoothGradConfig |
parseFrom(InputStream input) |
static SmoothGradConfig |
parseFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<SmoothGradConfig> |
parser() |
SmoothGradConfig.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, 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 NOISE_SIGMA_FIELD_NUMBER
public static final int FEATURE_NOISE_SIGMA_FIELD_NUMBER
public static final int NOISY_SAMPLE_COUNT_FIELD_NUMBER
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
newInstance in class com.google.protobuf.GeneratedMessageV3public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3public SmoothGradConfig.GradientNoiseSigmaCase getGradientNoiseSigmaCase()
getGradientNoiseSigmaCase in interface SmoothGradConfigOrBuilderpublic boolean hasNoiseSigma()
This is a single float value and will be used to add noise to all the features. Use this field when all features are normalized to have the same distribution: scale to range [0, 1], [-1, 1] or z-scoring, where features are normalized to have 0-mean and 1-variance. Learn more about [normalization](https://developers.google.com/machine-learning/data-prep/transform/normalization). For best results the recommended value is about 10% - 20% of the standard deviation of the input feature. Refer to section 3.2 of the SmoothGrad paper: https://arxiv.org/pdf/1706.03825.pdf. Defaults to 0.1. If the distribution is different per feature, set [feature_noise_sigma][google.cloud.aiplatform.v1.SmoothGradConfig.feature_noise_sigma] instead for each feature.
float noise_sigma = 1;hasNoiseSigma in interface SmoothGradConfigOrBuilderpublic float getNoiseSigma()
This is a single float value and will be used to add noise to all the features. Use this field when all features are normalized to have the same distribution: scale to range [0, 1], [-1, 1] or z-scoring, where features are normalized to have 0-mean and 1-variance. Learn more about [normalization](https://developers.google.com/machine-learning/data-prep/transform/normalization). For best results the recommended value is about 10% - 20% of the standard deviation of the input feature. Refer to section 3.2 of the SmoothGrad paper: https://arxiv.org/pdf/1706.03825.pdf. Defaults to 0.1. If the distribution is different per feature, set [feature_noise_sigma][google.cloud.aiplatform.v1.SmoothGradConfig.feature_noise_sigma] instead for each feature.
float noise_sigma = 1;getNoiseSigma in interface SmoothGradConfigOrBuilderpublic boolean hasFeatureNoiseSigma()
This is similar to [noise_sigma][google.cloud.aiplatform.v1.SmoothGradConfig.noise_sigma], but provides additional flexibility. A separate noise sigma can be provided for each feature, which is useful if their distributions are different. No noise is added to features that are not set. If this field is unset, [noise_sigma][google.cloud.aiplatform.v1.SmoothGradConfig.noise_sigma] will be used for all features.
.google.cloud.aiplatform.v1.FeatureNoiseSigma feature_noise_sigma = 2;hasFeatureNoiseSigma in interface SmoothGradConfigOrBuilderpublic FeatureNoiseSigma getFeatureNoiseSigma()
This is similar to [noise_sigma][google.cloud.aiplatform.v1.SmoothGradConfig.noise_sigma], but provides additional flexibility. A separate noise sigma can be provided for each feature, which is useful if their distributions are different. No noise is added to features that are not set. If this field is unset, [noise_sigma][google.cloud.aiplatform.v1.SmoothGradConfig.noise_sigma] will be used for all features.
.google.cloud.aiplatform.v1.FeatureNoiseSigma feature_noise_sigma = 2;getFeatureNoiseSigma in interface SmoothGradConfigOrBuilderpublic FeatureNoiseSigmaOrBuilder getFeatureNoiseSigmaOrBuilder()
This is similar to [noise_sigma][google.cloud.aiplatform.v1.SmoothGradConfig.noise_sigma], but provides additional flexibility. A separate noise sigma can be provided for each feature, which is useful if their distributions are different. No noise is added to features that are not set. If this field is unset, [noise_sigma][google.cloud.aiplatform.v1.SmoothGradConfig.noise_sigma] will be used for all features.
.google.cloud.aiplatform.v1.FeatureNoiseSigma feature_noise_sigma = 2;getFeatureNoiseSigmaOrBuilder in interface SmoothGradConfigOrBuilderpublic int getNoisySampleCount()
The number of gradient samples to use for approximation. The higher this number, the more accurate the gradient is, but the runtime complexity increases by this factor as well. Valid range of its value is [1, 50]. Defaults to 3.
int32 noisy_sample_count = 3;getNoisySampleCount in interface SmoothGradConfigOrBuilderpublic final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3public void writeTo(com.google.protobuf.CodedOutputStream output)
throws IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessageV3IOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessageV3public boolean equals(Object obj)
equals in interface com.google.protobuf.Messageequals in class com.google.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface com.google.protobuf.MessagehashCode in class com.google.protobuf.AbstractMessagepublic static SmoothGradConfig parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SmoothGradConfig parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SmoothGradConfig parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SmoothGradConfig parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SmoothGradConfig parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SmoothGradConfig parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static SmoothGradConfig parseFrom(InputStream input) throws IOException
IOExceptionpublic static SmoothGradConfig parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static SmoothGradConfig parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static SmoothGradConfig parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static SmoothGradConfig parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static SmoothGradConfig parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic SmoothGradConfig.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static SmoothGradConfig.Builder newBuilder()
public static SmoothGradConfig.Builder newBuilder(SmoothGradConfig prototype)
public SmoothGradConfig.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected SmoothGradConfig.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class com.google.protobuf.GeneratedMessageV3public static SmoothGradConfig getDefaultInstance()
public static com.google.protobuf.Parser<SmoothGradConfig> parser()
public com.google.protobuf.Parser<SmoothGradConfig> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessageV3public SmoothGradConfig getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2025 Google LLC. All rights reserved.