public static final class StratifiedSplit.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder> implements StratifiedSplitOrBuilder
Assigns input data to the training, validation, and test sets so that the distribution of values found in the categorical column (as specified by the `key` field) is mirrored within each split. The fraction values determine the relative sizes of the splits. For example, if the specified column has three values, with 50% of the rows having value "A", 25% value "B", and 25% value "C", and the split fractions are specified as 80/10/10, then the training set will constitute 80% of the training data, with about 50% of the training set rows having the value "A" for the specified column, about 25% having the value "B", and about 25% having the value "C". Only the top 500 occurring values are used; any values not in the top 500 values are randomly assigned to a split. If less than three rows contain a specific value, those rows are randomly assigned. Supported only for tabular Datasets.Protobuf type
google.cloud.aiplatform.v1beta1.StratifiedSplit| Modifier and Type | Method and Description |
|---|---|
StratifiedSplit.Builder |
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
StratifiedSplit |
build() |
StratifiedSplit |
buildPartial() |
StratifiedSplit.Builder |
clear() |
StratifiedSplit.Builder |
clearField(com.google.protobuf.Descriptors.FieldDescriptor field) |
StratifiedSplit.Builder |
clearKey()
Required.
|
StratifiedSplit.Builder |
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) |
StratifiedSplit.Builder |
clearTestFraction()
The fraction of the input data that is to be used to evaluate the Model.
|
StratifiedSplit.Builder |
clearTrainingFraction()
The fraction of the input data that is to be used to train the Model.
|
StratifiedSplit.Builder |
clearValidationFraction()
The fraction of the input data that is to be used to validate the Model.
|
StratifiedSplit.Builder |
clone() |
StratifiedSplit |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Descriptors.Descriptor |
getDescriptorForType() |
String |
getKey()
Required.
|
com.google.protobuf.ByteString |
getKeyBytes()
Required.
|
double |
getTestFraction()
The fraction of the input data that is to be used to evaluate the Model.
|
double |
getTrainingFraction()
The fraction of the input data that is to be used to train the Model.
|
double |
getValidationFraction()
The fraction of the input data that is to be used to validate the Model.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
StratifiedSplit.Builder |
mergeFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
StratifiedSplit.Builder |
mergeFrom(com.google.protobuf.Message other) |
StratifiedSplit.Builder |
mergeFrom(StratifiedSplit other) |
StratifiedSplit.Builder |
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
StratifiedSplit.Builder |
setField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
StratifiedSplit.Builder |
setKey(String value)
Required.
|
StratifiedSplit.Builder |
setKeyBytes(com.google.protobuf.ByteString value)
Required.
|
StratifiedSplit.Builder |
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
int index,
Object value) |
StratifiedSplit.Builder |
setTestFraction(double value)
The fraction of the input data that is to be used to evaluate the Model.
|
StratifiedSplit.Builder |
setTrainingFraction(double value)
The fraction of the input data that is to be used to train the Model.
|
StratifiedSplit.Builder |
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
StratifiedSplit.Builder |
setValidationFraction(double value)
The fraction of the input data that is to be used to validate the Model.
|
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMutableMapField, isClean, markClean, newBuilderForField, onBuilt, onChanged, setUnknownFieldsProto3findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringaddAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitfindInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneofpublic static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>public StratifiedSplit.Builder clear()
clear in interface com.google.protobuf.Message.Builderclear in interface com.google.protobuf.MessageLite.Builderclear in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
getDescriptorForType in interface com.google.protobuf.Message.BuildergetDescriptorForType in interface com.google.protobuf.MessageOrBuildergetDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>public StratifiedSplit getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderpublic StratifiedSplit build()
build in interface com.google.protobuf.Message.Builderbuild in interface com.google.protobuf.MessageLite.Builderpublic StratifiedSplit buildPartial()
buildPartial in interface com.google.protobuf.Message.BuilderbuildPartial in interface com.google.protobuf.MessageLite.Builderpublic StratifiedSplit.Builder clone()
clone in interface com.google.protobuf.Message.Builderclone in interface com.google.protobuf.MessageLite.Builderclone in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>public StratifiedSplit.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
setField in interface com.google.protobuf.Message.BuildersetField in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>public StratifiedSplit.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
clearField in interface com.google.protobuf.Message.BuilderclearField in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>public StratifiedSplit.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
clearOneof in interface com.google.protobuf.Message.BuilderclearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>public StratifiedSplit.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
setRepeatedField in interface com.google.protobuf.Message.BuildersetRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>public StratifiedSplit.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
addRepeatedField in interface com.google.protobuf.Message.BuilderaddRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>public StratifiedSplit.Builder mergeFrom(com.google.protobuf.Message other)
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<StratifiedSplit.Builder>public StratifiedSplit.Builder mergeFrom(StratifiedSplit other)
public final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>public StratifiedSplit.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in interface com.google.protobuf.MessageLite.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<StratifiedSplit.Builder>IOExceptionpublic double getTrainingFraction()
The fraction of the input data that is to be used to train the Model.
double training_fraction = 1;getTrainingFraction in interface StratifiedSplitOrBuilderpublic StratifiedSplit.Builder setTrainingFraction(double value)
The fraction of the input data that is to be used to train the Model.
double training_fraction = 1;value - The trainingFraction to set.public StratifiedSplit.Builder clearTrainingFraction()
The fraction of the input data that is to be used to train the Model.
double training_fraction = 1;public double getValidationFraction()
The fraction of the input data that is to be used to validate the Model.
double validation_fraction = 2;getValidationFraction in interface StratifiedSplitOrBuilderpublic StratifiedSplit.Builder setValidationFraction(double value)
The fraction of the input data that is to be used to validate the Model.
double validation_fraction = 2;value - The validationFraction to set.public StratifiedSplit.Builder clearValidationFraction()
The fraction of the input data that is to be used to validate the Model.
double validation_fraction = 2;public double getTestFraction()
The fraction of the input data that is to be used to evaluate the Model.
double test_fraction = 3;getTestFraction in interface StratifiedSplitOrBuilderpublic StratifiedSplit.Builder setTestFraction(double value)
The fraction of the input data that is to be used to evaluate the Model.
double test_fraction = 3;value - The testFraction to set.public StratifiedSplit.Builder clearTestFraction()
The fraction of the input data that is to be used to evaluate the Model.
double test_fraction = 3;public String getKey()
Required. The key is a name of one of the Dataset's data columns. The key provided must be for a categorical column.
string key = 4 [(.google.api.field_behavior) = REQUIRED];getKey in interface StratifiedSplitOrBuilderpublic com.google.protobuf.ByteString getKeyBytes()
Required. The key is a name of one of the Dataset's data columns. The key provided must be for a categorical column.
string key = 4 [(.google.api.field_behavior) = REQUIRED];getKeyBytes in interface StratifiedSplitOrBuilderpublic StratifiedSplit.Builder setKey(String value)
Required. The key is a name of one of the Dataset's data columns. The key provided must be for a categorical column.
string key = 4 [(.google.api.field_behavior) = REQUIRED];value - The key to set.public StratifiedSplit.Builder clearKey()
Required. The key is a name of one of the Dataset's data columns. The key provided must be for a categorical column.
string key = 4 [(.google.api.field_behavior) = REQUIRED];public StratifiedSplit.Builder setKeyBytes(com.google.protobuf.ByteString value)
Required. The key is a name of one of the Dataset's data columns. The key provided must be for a categorical column.
string key = 4 [(.google.api.field_behavior) = REQUIRED];value - The bytes for key to set.public final StratifiedSplit.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
setUnknownFields in interface com.google.protobuf.Message.BuildersetUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>public final StratifiedSplit.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
mergeUnknownFields in interface com.google.protobuf.Message.BuildermergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<StratifiedSplit.Builder>Copyright © 2022 Google LLC. All rights reserved.