public final class FeatureStatsAnomaly extends GeneratedMessageV3 implements FeatureStatsAnomalyOrBuilder
Stats and Anomaly generated at specific timestamp for specific Feature.
The start_time and end_time are used to define the time range of the dataset
that current stats belongs to, e.g. prediction traffic is bucketed into
prediction datasets by time window. If the Dataset is not defined by time
window, start_time = end_time. Timestamp of the stats and anomalies always
refers to end_time. Raw stats and anomalies are stored in stats_uri or
anomaly_uri in the tensorflow defined protos. Field data_stats contains
almost identical information with the raw stats in Vertex AI
defined proto, for UI to display.
Protobuf type google.cloud.aiplatform.v1beta1.FeatureStatsAnomaly
Static Fields
public static final int ANOMALY_DETECTION_THRESHOLD_FIELD_NUMBER
Field Value
public static final int ANOMALY_URI_FIELD_NUMBER
Field Value
public static final int DISTRIBUTION_DEVIATION_FIELD_NUMBER
Field Value
public static final int END_TIME_FIELD_NUMBER
Field Value
public static final int SCORE_FIELD_NUMBER
Field Value
public static final int START_TIME_FIELD_NUMBER
Field Value
public static final int STATS_URI_FIELD_NUMBER
Field Value
Static Methods
public static FeatureStatsAnomaly getDefaultInstance()
Returns
public static final Descriptors.Descriptor getDescriptor()
Returns
public static FeatureStatsAnomaly.Builder newBuilder()
Returns
public static FeatureStatsAnomaly.Builder newBuilder(FeatureStatsAnomaly prototype)
Parameter
Returns
public static FeatureStatsAnomaly parseDelimitedFrom(InputStream input)
Parameter
Returns
Exceptions
public static FeatureStatsAnomaly parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static FeatureStatsAnomaly parseFrom(byte[] data)
Parameter
Name | Description |
data | byte[]
|
Returns
Exceptions
public static FeatureStatsAnomaly parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static FeatureStatsAnomaly parseFrom(ByteString data)
Parameter
Returns
Exceptions
public static FeatureStatsAnomaly parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static FeatureStatsAnomaly parseFrom(CodedInputStream input)
Parameter
Returns
Exceptions
public static FeatureStatsAnomaly parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static FeatureStatsAnomaly parseFrom(InputStream input)
Parameter
Returns
Exceptions
public static FeatureStatsAnomaly parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static FeatureStatsAnomaly parseFrom(ByteBuffer data)
Parameter
Returns
Exceptions
public static FeatureStatsAnomaly parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static Parser<FeatureStatsAnomaly> parser()
Returns
Methods
public boolean equals(Object obj)
Parameter
Returns
Overrides
public double getAnomalyDetectionThreshold()
This is the threshold used when detecting anomalies.
The threshold can be changed by user, so this one might be different from
ThresholdConfig.value.
double anomaly_detection_threshold = 9;
Returns
Type | Description |
double | The anomalyDetectionThreshold.
|
public String getAnomalyUri()
Path of the anomaly file for current feature values in Cloud Storage
bucket.
Format: gs://<bucket_name>/<object_name>/anomalies.
Example: gs://monitoring_bucket/feature_name/anomalies.
Stats are stored as binary format with Protobuf message
Anoamlies are stored as binary format with Protobuf message
tensorflow.metadata.v0.AnomalyInfo.
string anomaly_uri = 4;
Returns
Type | Description |
String | The anomalyUri.
|
public ByteString getAnomalyUriBytes()
Path of the anomaly file for current feature values in Cloud Storage
bucket.
Format: gs://<bucket_name>/<object_name>/anomalies.
Example: gs://monitoring_bucket/feature_name/anomalies.
Stats are stored as binary format with Protobuf message
Anoamlies are stored as binary format with Protobuf message
tensorflow.metadata.v0.AnomalyInfo.
string anomaly_uri = 4;
Returns
Type | Description |
ByteString | The bytes for anomalyUri.
|
public FeatureStatsAnomaly getDefaultInstanceForType()
Returns
public double getDistributionDeviation()
Deviation from the current stats to baseline stats.
- For categorical feature, the distribution distance is calculated by
L-inifinity norm.
- For numerical feature, the distribution distance is calculated by
Jensen–Shannon divergence.
double distribution_deviation = 5;
Returns
Type | Description |
double | The distributionDeviation.
|
public Timestamp getEndTime()
The end timestamp of window where stats were generated.
For objectives where time window doesn't make sense (e.g. Featurestore
Snapshot Monitoring), end_time indicates the timestamp of the data used to
generate stats (e.g. timestamp we take snapshots for feature values).
.google.protobuf.Timestamp end_time = 8;
Returns
public TimestampOrBuilder getEndTimeOrBuilder()
The end timestamp of window where stats were generated.
For objectives where time window doesn't make sense (e.g. Featurestore
Snapshot Monitoring), end_time indicates the timestamp of the data used to
generate stats (e.g. timestamp we take snapshots for feature values).
.google.protobuf.Timestamp end_time = 8;
Returns
public Parser<FeatureStatsAnomaly> getParserForType()
Returns
Overrides
Feature importance score, only populated when cross-feature monitoring is
enabled. For now only used to represent feature attribution score within
range [0, 1] for
ModelDeploymentMonitoringObjectiveType.FEATURE_ATTRIBUTION_SKEW
and
ModelDeploymentMonitoringObjectiveType.FEATURE_ATTRIBUTION_DRIFT.
double score = 1;
Returns
Type | Description |
double | The score.
|
public int getSerializedSize()
Returns
Overrides
public Timestamp getStartTime()
The start timestamp of window where stats were generated.
For objectives where time window doesn't make sense (e.g. Featurestore
Snapshot Monitoring), start_time is only used to indicate the monitoring
intervals, so it always equals to (end_time - monitoring_interval).
.google.protobuf.Timestamp start_time = 7;
Returns
public TimestampOrBuilder getStartTimeOrBuilder()
The start timestamp of window where stats were generated.
For objectives where time window doesn't make sense (e.g. Featurestore
Snapshot Monitoring), start_time is only used to indicate the monitoring
intervals, so it always equals to (end_time - monitoring_interval).
.google.protobuf.Timestamp start_time = 7;
Returns
public String getStatsUri()
Path of the stats file for current feature values in Cloud Storage bucket.
Format: gs://<bucket_name>/<object_name>/stats.
Example: gs://monitoring_bucket/feature_name/stats.
Stats are stored as binary format with Protobuf message
tensorflow.metadata.v0.FeatureNameStatistics.
string stats_uri = 3;
Returns
Type | Description |
String | The statsUri.
|
public ByteString getStatsUriBytes()
Path of the stats file for current feature values in Cloud Storage bucket.
Format: gs://<bucket_name>/<object_name>/stats.
Example: gs://monitoring_bucket/feature_name/stats.
Stats are stored as binary format with Protobuf message
tensorflow.metadata.v0.FeatureNameStatistics.
string stats_uri = 3;
Returns
public final UnknownFieldSet getUnknownFields()
Returns
Overrides
public boolean hasEndTime()
The end timestamp of window where stats were generated.
For objectives where time window doesn't make sense (e.g. Featurestore
Snapshot Monitoring), end_time indicates the timestamp of the data used to
generate stats (e.g. timestamp we take snapshots for feature values).
.google.protobuf.Timestamp end_time = 8;
Returns
Type | Description |
boolean | Whether the endTime field is set.
|
public boolean hasStartTime()
The start timestamp of window where stats were generated.
For objectives where time window doesn't make sense (e.g. Featurestore
Snapshot Monitoring), start_time is only used to indicate the monitoring
intervals, so it always equals to (end_time - monitoring_interval).
.google.protobuf.Timestamp start_time = 7;
Returns
Type | Description |
boolean | Whether the startTime field is set.
|
Returns
Overrides
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
public final boolean isInitialized()
Returns
Overrides
public FeatureStatsAnomaly.Builder newBuilderForType()
Returns
protected FeatureStatsAnomaly.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Returns
Overrides
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Returns
Overrides
public FeatureStatsAnomaly.Builder toBuilder()
Returns
public void writeTo(CodedOutputStream output)
Parameter
Overrides
Exceptions