Class Model

  • All Implemented Interfaces:
    ModelOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable

    public final class Model
    extends com.google.protobuf.GeneratedMessageV3
    implements ModelOrBuilder
     API proto representing a trained machine learning model.
     
    Protobuf type google.cloud.automl.v1beta1.Model
    See Also:
    Serialized Form
    • Field Detail

      • TRANSLATION_MODEL_METADATA_FIELD_NUMBER

        public static final int TRANSLATION_MODEL_METADATA_FIELD_NUMBER
        See Also:
        Constant Field Values
      • IMAGE_CLASSIFICATION_MODEL_METADATA_FIELD_NUMBER

        public static final int IMAGE_CLASSIFICATION_MODEL_METADATA_FIELD_NUMBER
        See Also:
        Constant Field Values
      • TEXT_CLASSIFICATION_MODEL_METADATA_FIELD_NUMBER

        public static final int TEXT_CLASSIFICATION_MODEL_METADATA_FIELD_NUMBER
        See Also:
        Constant Field Values
      • IMAGE_OBJECT_DETECTION_MODEL_METADATA_FIELD_NUMBER

        public static final int IMAGE_OBJECT_DETECTION_MODEL_METADATA_FIELD_NUMBER
        See Also:
        Constant Field Values
      • VIDEO_CLASSIFICATION_MODEL_METADATA_FIELD_NUMBER

        public static final int VIDEO_CLASSIFICATION_MODEL_METADATA_FIELD_NUMBER
        See Also:
        Constant Field Values
      • VIDEO_OBJECT_TRACKING_MODEL_METADATA_FIELD_NUMBER

        public static final int VIDEO_OBJECT_TRACKING_MODEL_METADATA_FIELD_NUMBER
        See Also:
        Constant Field Values
      • TEXT_EXTRACTION_MODEL_METADATA_FIELD_NUMBER

        public static final int TEXT_EXTRACTION_MODEL_METADATA_FIELD_NUMBER
        See Also:
        Constant Field Values
      • TABLES_MODEL_METADATA_FIELD_NUMBER

        public static final int TABLES_MODEL_METADATA_FIELD_NUMBER
        See Also:
        Constant Field Values
      • TEXT_SENTIMENT_MODEL_METADATA_FIELD_NUMBER

        public static final int TEXT_SENTIMENT_MODEL_METADATA_FIELD_NUMBER
        See Also:
        Constant Field Values
      • DISPLAY_NAME_FIELD_NUMBER

        public static final int DISPLAY_NAME_FIELD_NUMBER
        See Also:
        Constant Field Values
      • DATASET_ID_FIELD_NUMBER

        public static final int DATASET_ID_FIELD_NUMBER
        See Also:
        Constant Field Values
      • CREATE_TIME_FIELD_NUMBER

        public static final int CREATE_TIME_FIELD_NUMBER
        See Also:
        Constant Field Values
      • UPDATE_TIME_FIELD_NUMBER

        public static final int UPDATE_TIME_FIELD_NUMBER
        See Also:
        Constant Field Values
      • DEPLOYMENT_STATE_FIELD_NUMBER

        public static final int DEPLOYMENT_STATE_FIELD_NUMBER
        See Also:
        Constant Field Values
    • Method Detail

      • newInstance

        protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
      • hasTranslationModelMetadata

        public boolean hasTranslationModelMetadata()
         Metadata for translation models.
         
        .google.cloud.automl.v1beta1.TranslationModelMetadata translation_model_metadata = 15;
        Specified by:
        hasTranslationModelMetadata in interface ModelOrBuilder
        Returns:
        Whether the translationModelMetadata field is set.
      • hasImageClassificationModelMetadata

        public boolean hasImageClassificationModelMetadata()
         Metadata for image classification models.
         
        .google.cloud.automl.v1beta1.ImageClassificationModelMetadata image_classification_model_metadata = 13;
        Specified by:
        hasImageClassificationModelMetadata in interface ModelOrBuilder
        Returns:
        Whether the imageClassificationModelMetadata field is set.
      • hasTextClassificationModelMetadata

        public boolean hasTextClassificationModelMetadata()
         Metadata for text classification models.
         
        .google.cloud.automl.v1beta1.TextClassificationModelMetadata text_classification_model_metadata = 14;
        Specified by:
        hasTextClassificationModelMetadata in interface ModelOrBuilder
        Returns:
        Whether the textClassificationModelMetadata field is set.
      • hasImageObjectDetectionModelMetadata

        public boolean hasImageObjectDetectionModelMetadata()
         Metadata for image object detection models.
         
        .google.cloud.automl.v1beta1.ImageObjectDetectionModelMetadata image_object_detection_model_metadata = 20;
        Specified by:
        hasImageObjectDetectionModelMetadata in interface ModelOrBuilder
        Returns:
        Whether the imageObjectDetectionModelMetadata field is set.
      • hasVideoClassificationModelMetadata

        public boolean hasVideoClassificationModelMetadata()
         Metadata for video classification models.
         
        .google.cloud.automl.v1beta1.VideoClassificationModelMetadata video_classification_model_metadata = 23;
        Specified by:
        hasVideoClassificationModelMetadata in interface ModelOrBuilder
        Returns:
        Whether the videoClassificationModelMetadata field is set.
      • hasVideoObjectTrackingModelMetadata

        public boolean hasVideoObjectTrackingModelMetadata()
         Metadata for video object tracking models.
         
        .google.cloud.automl.v1beta1.VideoObjectTrackingModelMetadata video_object_tracking_model_metadata = 21;
        Specified by:
        hasVideoObjectTrackingModelMetadata in interface ModelOrBuilder
        Returns:
        Whether the videoObjectTrackingModelMetadata field is set.
      • hasTextExtractionModelMetadata

        public boolean hasTextExtractionModelMetadata()
         Metadata for text extraction models.
         
        .google.cloud.automl.v1beta1.TextExtractionModelMetadata text_extraction_model_metadata = 19;
        Specified by:
        hasTextExtractionModelMetadata in interface ModelOrBuilder
        Returns:
        Whether the textExtractionModelMetadata field is set.
      • hasTablesModelMetadata

        public boolean hasTablesModelMetadata()
         Metadata for Tables models.
         
        .google.cloud.automl.v1beta1.TablesModelMetadata tables_model_metadata = 24;
        Specified by:
        hasTablesModelMetadata in interface ModelOrBuilder
        Returns:
        Whether the tablesModelMetadata field is set.
      • getTablesModelMetadata

        public TablesModelMetadata getTablesModelMetadata()
         Metadata for Tables models.
         
        .google.cloud.automl.v1beta1.TablesModelMetadata tables_model_metadata = 24;
        Specified by:
        getTablesModelMetadata in interface ModelOrBuilder
        Returns:
        The tablesModelMetadata.
      • hasTextSentimentModelMetadata

        public boolean hasTextSentimentModelMetadata()
         Metadata for text sentiment models.
         
        .google.cloud.automl.v1beta1.TextSentimentModelMetadata text_sentiment_model_metadata = 22;
        Specified by:
        hasTextSentimentModelMetadata in interface ModelOrBuilder
        Returns:
        Whether the textSentimentModelMetadata field is set.
      • getName

        public String getName()
         Output only. Resource name of the model.
         Format: `projects/{project_id}/locations/{location_id}/models/{model_id}`
         
        string name = 1;
        Specified by:
        getName in interface ModelOrBuilder
        Returns:
        The name.
      • getNameBytes

        public com.google.protobuf.ByteString getNameBytes()
         Output only. Resource name of the model.
         Format: `projects/{project_id}/locations/{location_id}/models/{model_id}`
         
        string name = 1;
        Specified by:
        getNameBytes in interface ModelOrBuilder
        Returns:
        The bytes for name.
      • getDisplayName

        public String getDisplayName()
         Required. The name of the model to show in the interface. The name can be
         up to 32 characters long and can consist only of ASCII Latin letters A-Z
         and a-z, underscores
         (_), and ASCII digits 0-9. It must start with a letter.
         
        string display_name = 2;
        Specified by:
        getDisplayName in interface ModelOrBuilder
        Returns:
        The displayName.
      • getDisplayNameBytes

        public com.google.protobuf.ByteString getDisplayNameBytes()
         Required. The name of the model to show in the interface. The name can be
         up to 32 characters long and can consist only of ASCII Latin letters A-Z
         and a-z, underscores
         (_), and ASCII digits 0-9. It must start with a letter.
         
        string display_name = 2;
        Specified by:
        getDisplayNameBytes in interface ModelOrBuilder
        Returns:
        The bytes for displayName.
      • getDatasetId

        public String getDatasetId()
         Required. The resource ID of the dataset used to create the model. The dataset must
         come from the same ancestor project and location.
         
        string dataset_id = 3;
        Specified by:
        getDatasetId in interface ModelOrBuilder
        Returns:
        The datasetId.
      • getDatasetIdBytes

        public com.google.protobuf.ByteString getDatasetIdBytes()
         Required. The resource ID of the dataset used to create the model. The dataset must
         come from the same ancestor project and location.
         
        string dataset_id = 3;
        Specified by:
        getDatasetIdBytes in interface ModelOrBuilder
        Returns:
        The bytes for datasetId.
      • hasCreateTime

        public boolean hasCreateTime()
         Output only. Timestamp when the model training finished  and can be used for prediction.
         
        .google.protobuf.Timestamp create_time = 7;
        Specified by:
        hasCreateTime in interface ModelOrBuilder
        Returns:
        Whether the createTime field is set.
      • getCreateTime

        public com.google.protobuf.Timestamp getCreateTime()
         Output only. Timestamp when the model training finished  and can be used for prediction.
         
        .google.protobuf.Timestamp create_time = 7;
        Specified by:
        getCreateTime in interface ModelOrBuilder
        Returns:
        The createTime.
      • getCreateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()
         Output only. Timestamp when the model training finished  and can be used for prediction.
         
        .google.protobuf.Timestamp create_time = 7;
        Specified by:
        getCreateTimeOrBuilder in interface ModelOrBuilder
      • hasUpdateTime

        public boolean hasUpdateTime()
         Output only. Timestamp when this model was last updated.
         
        .google.protobuf.Timestamp update_time = 11;
        Specified by:
        hasUpdateTime in interface ModelOrBuilder
        Returns:
        Whether the updateTime field is set.
      • getUpdateTime

        public com.google.protobuf.Timestamp getUpdateTime()
         Output only. Timestamp when this model was last updated.
         
        .google.protobuf.Timestamp update_time = 11;
        Specified by:
        getUpdateTime in interface ModelOrBuilder
        Returns:
        The updateTime.
      • getUpdateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()
         Output only. Timestamp when this model was last updated.
         
        .google.protobuf.Timestamp update_time = 11;
        Specified by:
        getUpdateTimeOrBuilder in interface ModelOrBuilder
      • getDeploymentStateValue

        public int getDeploymentStateValue()
         Output only. Deployment state of the model. A model can only serve
         prediction requests after it gets deployed.
         
        .google.cloud.automl.v1beta1.Model.DeploymentState deployment_state = 8;
        Specified by:
        getDeploymentStateValue in interface ModelOrBuilder
        Returns:
        The enum numeric value on the wire for deploymentState.
      • getDeploymentState

        public Model.DeploymentState getDeploymentState()
         Output only. Deployment state of the model. A model can only serve
         prediction requests after it gets deployed.
         
        .google.cloud.automl.v1beta1.Model.DeploymentState deployment_state = 8;
        Specified by:
        getDeploymentState in interface ModelOrBuilder
        Returns:
        The deploymentState.
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static Model parseFrom​(ByteBuffer data)
                               throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Model parseFrom​(ByteBuffer data,
                                      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                               throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Model parseFrom​(com.google.protobuf.ByteString data)
                               throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Model parseFrom​(com.google.protobuf.ByteString data,
                                      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                               throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Model parseFrom​(byte[] data)
                               throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Model parseFrom​(byte[] data,
                                      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                               throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Model parseFrom​(com.google.protobuf.CodedInputStream input,
                                      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                               throws IOException
        Throws:
        IOException
      • newBuilderForType

        public Model.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public Model.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected Model.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstance

        public static Model getDefaultInstance()
      • parser

        public static com.google.protobuf.Parser<Model> parser()
      • getParserForType

        public com.google.protobuf.Parser<Model> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

        public Model getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder