Class ModelExportOutputConfig.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<ModelExportOutputConfig.Builder>
com.google.cloud.automl.v1.ModelExportOutputConfig.Builder
All Implemented Interfaces:
ModelExportOutputConfigOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
ModelExportOutputConfig

public static final class ModelExportOutputConfig.Builder extends com.google.protobuf.GeneratedMessage.Builder<ModelExportOutputConfig.Builder> implements ModelExportOutputConfigOrBuilder
 Output configuration for ModelExport Action.
 
Protobuf type google.cloud.automl.v1.ModelExportOutputConfig
  • Method Details

    • getDescriptor

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

      protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
      Overrides:
      internalGetMapFieldReflection in class com.google.protobuf.GeneratedMessage.Builder<ModelExportOutputConfig.Builder>
    • internalGetMutableMapFieldReflection

      protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
      Overrides:
      internalGetMutableMapFieldReflection in class com.google.protobuf.GeneratedMessage.Builder<ModelExportOutputConfig.Builder>
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<ModelExportOutputConfig.Builder>
    • clear

      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<ModelExportOutputConfig.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<ModelExportOutputConfig.Builder>
    • getDefaultInstanceForType

      public ModelExportOutputConfig getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public ModelExportOutputConfig build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public ModelExportOutputConfig buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public ModelExportOutputConfig.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<ModelExportOutputConfig.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<ModelExportOutputConfig.Builder>
    • mergeFrom

      public ModelExportOutputConfig.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<ModelExportOutputConfig.Builder>
      Throws:
      IOException
    • getDestinationCase

      public ModelExportOutputConfig.DestinationCase getDestinationCase()
      Specified by:
      getDestinationCase in interface ModelExportOutputConfigOrBuilder
    • clearDestination

      public ModelExportOutputConfig.Builder clearDestination()
    • hasGcsDestination

      public boolean hasGcsDestination()
       Required. The Google Cloud Storage location where the model is to be
       written to. This location may only be set for the following model
       formats:
       "tflite", "edgetpu_tflite", "tf_saved_model", "tf_js", "core_ml".
      
       Under the directory given as the destination a new one with name
       "model-export-<model-display-name>-<timestamp-of-export-call>",
       where timestamp is in YYYY-MM-DDThh:mm:ss.sssZ ISO-8601 format,
       will be created. Inside the model and any of its supporting files
       will be written.
       
      .google.cloud.automl.v1.GcsDestination gcs_destination = 1 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      hasGcsDestination in interface ModelExportOutputConfigOrBuilder
      Returns:
      Whether the gcsDestination field is set.
    • getGcsDestination

      public GcsDestination getGcsDestination()
       Required. The Google Cloud Storage location where the model is to be
       written to. This location may only be set for the following model
       formats:
       "tflite", "edgetpu_tflite", "tf_saved_model", "tf_js", "core_ml".
      
       Under the directory given as the destination a new one with name
       "model-export-<model-display-name>-<timestamp-of-export-call>",
       where timestamp is in YYYY-MM-DDThh:mm:ss.sssZ ISO-8601 format,
       will be created. Inside the model and any of its supporting files
       will be written.
       
      .google.cloud.automl.v1.GcsDestination gcs_destination = 1 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getGcsDestination in interface ModelExportOutputConfigOrBuilder
      Returns:
      The gcsDestination.
    • setGcsDestination

      public ModelExportOutputConfig.Builder setGcsDestination(GcsDestination value)
       Required. The Google Cloud Storage location where the model is to be
       written to. This location may only be set for the following model
       formats:
       "tflite", "edgetpu_tflite", "tf_saved_model", "tf_js", "core_ml".
      
       Under the directory given as the destination a new one with name
       "model-export-<model-display-name>-<timestamp-of-export-call>",
       where timestamp is in YYYY-MM-DDThh:mm:ss.sssZ ISO-8601 format,
       will be created. Inside the model and any of its supporting files
       will be written.
       
      .google.cloud.automl.v1.GcsDestination gcs_destination = 1 [(.google.api.field_behavior) = REQUIRED];
    • setGcsDestination

      public ModelExportOutputConfig.Builder setGcsDestination(GcsDestination.Builder builderForValue)
       Required. The Google Cloud Storage location where the model is to be
       written to. This location may only be set for the following model
       formats:
       "tflite", "edgetpu_tflite", "tf_saved_model", "tf_js", "core_ml".
      
       Under the directory given as the destination a new one with name
       "model-export-<model-display-name>-<timestamp-of-export-call>",
       where timestamp is in YYYY-MM-DDThh:mm:ss.sssZ ISO-8601 format,
       will be created. Inside the model and any of its supporting files
       will be written.
       
      .google.cloud.automl.v1.GcsDestination gcs_destination = 1 [(.google.api.field_behavior) = REQUIRED];
    • mergeGcsDestination

      public ModelExportOutputConfig.Builder mergeGcsDestination(GcsDestination value)
       Required. The Google Cloud Storage location where the model is to be
       written to. This location may only be set for the following model
       formats:
       "tflite", "edgetpu_tflite", "tf_saved_model", "tf_js", "core_ml".
      
       Under the directory given as the destination a new one with name
       "model-export-<model-display-name>-<timestamp-of-export-call>",
       where timestamp is in YYYY-MM-DDThh:mm:ss.sssZ ISO-8601 format,
       will be created. Inside the model and any of its supporting files
       will be written.
       
      .google.cloud.automl.v1.GcsDestination gcs_destination = 1 [(.google.api.field_behavior) = REQUIRED];
    • clearGcsDestination

      public ModelExportOutputConfig.Builder clearGcsDestination()
       Required. The Google Cloud Storage location where the model is to be
       written to. This location may only be set for the following model
       formats:
       "tflite", "edgetpu_tflite", "tf_saved_model", "tf_js", "core_ml".
      
       Under the directory given as the destination a new one with name
       "model-export-<model-display-name>-<timestamp-of-export-call>",
       where timestamp is in YYYY-MM-DDThh:mm:ss.sssZ ISO-8601 format,
       will be created. Inside the model and any of its supporting files
       will be written.
       
      .google.cloud.automl.v1.GcsDestination gcs_destination = 1 [(.google.api.field_behavior) = REQUIRED];
    • getGcsDestinationBuilder

      public GcsDestination.Builder getGcsDestinationBuilder()
       Required. The Google Cloud Storage location where the model is to be
       written to. This location may only be set for the following model
       formats:
       "tflite", "edgetpu_tflite", "tf_saved_model", "tf_js", "core_ml".
      
       Under the directory given as the destination a new one with name
       "model-export-<model-display-name>-<timestamp-of-export-call>",
       where timestamp is in YYYY-MM-DDThh:mm:ss.sssZ ISO-8601 format,
       will be created. Inside the model and any of its supporting files
       will be written.
       
      .google.cloud.automl.v1.GcsDestination gcs_destination = 1 [(.google.api.field_behavior) = REQUIRED];
    • getGcsDestinationOrBuilder

      public GcsDestinationOrBuilder getGcsDestinationOrBuilder()
       Required. The Google Cloud Storage location where the model is to be
       written to. This location may only be set for the following model
       formats:
       "tflite", "edgetpu_tflite", "tf_saved_model", "tf_js", "core_ml".
      
       Under the directory given as the destination a new one with name
       "model-export-<model-display-name>-<timestamp-of-export-call>",
       where timestamp is in YYYY-MM-DDThh:mm:ss.sssZ ISO-8601 format,
       will be created. Inside the model and any of its supporting files
       will be written.
       
      .google.cloud.automl.v1.GcsDestination gcs_destination = 1 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getGcsDestinationOrBuilder in interface ModelExportOutputConfigOrBuilder
    • getModelFormat

      public String getModelFormat()
       The format in which the model must be exported. The available, and default,
       formats depend on the problem and model type (if given problem and type
       combination doesn't have a format listed, it means its models are not
       exportable):
      
       *  For Image Classification mobile-low-latency-1, mobile-versatile-1,
       mobile-high-accuracy-1:
       "tflite" (default), "edgetpu_tflite", "tf_saved_model", "tf_js",
       "docker".
      
       *  For Image Classification mobile-core-ml-low-latency-1,
       mobile-core-ml-versatile-1, mobile-core-ml-high-accuracy-1:
       "core_ml" (default).
      
       *  For Image Object Detection mobile-low-latency-1, mobile-versatile-1,
       mobile-high-accuracy-1:
       "tflite", "tf_saved_model", "tf_js".
       Formats description:
      
       * tflite - Used for Android mobile devices.
       * edgetpu_tflite - Used for [Edge TPU](https://cloud.google.com/edge-tpu/)
       devices.
       * tf_saved_model - A tensorflow model in SavedModel format.
       * tf_js - A [TensorFlow.js](https://www.tensorflow.org/js) model that can
       be used in the browser and in Node.js using JavaScript.
       * docker - Used for Docker containers. Use the params field to customize
       the container. The container is verified to work correctly on
       ubuntu 16.04 operating system. See more at
       [containers
       quickstart](https://cloud.google.com/vision/automl/docs/containers-gcs-quickstart)
       * core_ml - Used for iOS mobile devices.
       
      string model_format = 4;
      Specified by:
      getModelFormat in interface ModelExportOutputConfigOrBuilder
      Returns:
      The modelFormat.
    • getModelFormatBytes

      public com.google.protobuf.ByteString getModelFormatBytes()
       The format in which the model must be exported. The available, and default,
       formats depend on the problem and model type (if given problem and type
       combination doesn't have a format listed, it means its models are not
       exportable):
      
       *  For Image Classification mobile-low-latency-1, mobile-versatile-1,
       mobile-high-accuracy-1:
       "tflite" (default), "edgetpu_tflite", "tf_saved_model", "tf_js",
       "docker".
      
       *  For Image Classification mobile-core-ml-low-latency-1,
       mobile-core-ml-versatile-1, mobile-core-ml-high-accuracy-1:
       "core_ml" (default).
      
       *  For Image Object Detection mobile-low-latency-1, mobile-versatile-1,
       mobile-high-accuracy-1:
       "tflite", "tf_saved_model", "tf_js".
       Formats description:
      
       * tflite - Used for Android mobile devices.
       * edgetpu_tflite - Used for [Edge TPU](https://cloud.google.com/edge-tpu/)
       devices.
       * tf_saved_model - A tensorflow model in SavedModel format.
       * tf_js - A [TensorFlow.js](https://www.tensorflow.org/js) model that can
       be used in the browser and in Node.js using JavaScript.
       * docker - Used for Docker containers. Use the params field to customize
       the container. The container is verified to work correctly on
       ubuntu 16.04 operating system. See more at
       [containers
       quickstart](https://cloud.google.com/vision/automl/docs/containers-gcs-quickstart)
       * core_ml - Used for iOS mobile devices.
       
      string model_format = 4;
      Specified by:
      getModelFormatBytes in interface ModelExportOutputConfigOrBuilder
      Returns:
      The bytes for modelFormat.
    • setModelFormat

      public ModelExportOutputConfig.Builder setModelFormat(String value)
       The format in which the model must be exported. The available, and default,
       formats depend on the problem and model type (if given problem and type
       combination doesn't have a format listed, it means its models are not
       exportable):
      
       *  For Image Classification mobile-low-latency-1, mobile-versatile-1,
       mobile-high-accuracy-1:
       "tflite" (default), "edgetpu_tflite", "tf_saved_model", "tf_js",
       "docker".
      
       *  For Image Classification mobile-core-ml-low-latency-1,
       mobile-core-ml-versatile-1, mobile-core-ml-high-accuracy-1:
       "core_ml" (default).
      
       *  For Image Object Detection mobile-low-latency-1, mobile-versatile-1,
       mobile-high-accuracy-1:
       "tflite", "tf_saved_model", "tf_js".
       Formats description:
      
       * tflite - Used for Android mobile devices.
       * edgetpu_tflite - Used for [Edge TPU](https://cloud.google.com/edge-tpu/)
       devices.
       * tf_saved_model - A tensorflow model in SavedModel format.
       * tf_js - A [TensorFlow.js](https://www.tensorflow.org/js) model that can
       be used in the browser and in Node.js using JavaScript.
       * docker - Used for Docker containers. Use the params field to customize
       the container. The container is verified to work correctly on
       ubuntu 16.04 operating system. See more at
       [containers
       quickstart](https://cloud.google.com/vision/automl/docs/containers-gcs-quickstart)
       * core_ml - Used for iOS mobile devices.
       
      string model_format = 4;
      Parameters:
      value - The modelFormat to set.
      Returns:
      This builder for chaining.
    • clearModelFormat

      public ModelExportOutputConfig.Builder clearModelFormat()
       The format in which the model must be exported. The available, and default,
       formats depend on the problem and model type (if given problem and type
       combination doesn't have a format listed, it means its models are not
       exportable):
      
       *  For Image Classification mobile-low-latency-1, mobile-versatile-1,
       mobile-high-accuracy-1:
       "tflite" (default), "edgetpu_tflite", "tf_saved_model", "tf_js",
       "docker".
      
       *  For Image Classification mobile-core-ml-low-latency-1,
       mobile-core-ml-versatile-1, mobile-core-ml-high-accuracy-1:
       "core_ml" (default).
      
       *  For Image Object Detection mobile-low-latency-1, mobile-versatile-1,
       mobile-high-accuracy-1:
       "tflite", "tf_saved_model", "tf_js".
       Formats description:
      
       * tflite - Used for Android mobile devices.
       * edgetpu_tflite - Used for [Edge TPU](https://cloud.google.com/edge-tpu/)
       devices.
       * tf_saved_model - A tensorflow model in SavedModel format.
       * tf_js - A [TensorFlow.js](https://www.tensorflow.org/js) model that can
       be used in the browser and in Node.js using JavaScript.
       * docker - Used for Docker containers. Use the params field to customize
       the container. The container is verified to work correctly on
       ubuntu 16.04 operating system. See more at
       [containers
       quickstart](https://cloud.google.com/vision/automl/docs/containers-gcs-quickstart)
       * core_ml - Used for iOS mobile devices.
       
      string model_format = 4;
      Returns:
      This builder for chaining.
    • setModelFormatBytes

      public ModelExportOutputConfig.Builder setModelFormatBytes(com.google.protobuf.ByteString value)
       The format in which the model must be exported. The available, and default,
       formats depend on the problem and model type (if given problem and type
       combination doesn't have a format listed, it means its models are not
       exportable):
      
       *  For Image Classification mobile-low-latency-1, mobile-versatile-1,
       mobile-high-accuracy-1:
       "tflite" (default), "edgetpu_tflite", "tf_saved_model", "tf_js",
       "docker".
      
       *  For Image Classification mobile-core-ml-low-latency-1,
       mobile-core-ml-versatile-1, mobile-core-ml-high-accuracy-1:
       "core_ml" (default).
      
       *  For Image Object Detection mobile-low-latency-1, mobile-versatile-1,
       mobile-high-accuracy-1:
       "tflite", "tf_saved_model", "tf_js".
       Formats description:
      
       * tflite - Used for Android mobile devices.
       * edgetpu_tflite - Used for [Edge TPU](https://cloud.google.com/edge-tpu/)
       devices.
       * tf_saved_model - A tensorflow model in SavedModel format.
       * tf_js - A [TensorFlow.js](https://www.tensorflow.org/js) model that can
       be used in the browser and in Node.js using JavaScript.
       * docker - Used for Docker containers. Use the params field to customize
       the container. The container is verified to work correctly on
       ubuntu 16.04 operating system. See more at
       [containers
       quickstart](https://cloud.google.com/vision/automl/docs/containers-gcs-quickstart)
       * core_ml - Used for iOS mobile devices.
       
      string model_format = 4;
      Parameters:
      value - The bytes for modelFormat to set.
      Returns:
      This builder for chaining.
    • getParamsCount

      public int getParamsCount()
      Description copied from interface: ModelExportOutputConfigOrBuilder
       Additional model-type and format specific parameters describing the
       requirements for the to be exported model files, any string must be up to
       25000 characters long.
      
       * For `docker` format:
       `cpu_architecture` - (string) "x86_64" (default).
       `gpu_architecture` - (string) "none" (default), "nvidia".
       
      map<string, string> params = 2;
      Specified by:
      getParamsCount in interface ModelExportOutputConfigOrBuilder
    • containsParams

      public boolean containsParams(String key)
       Additional model-type and format specific parameters describing the
       requirements for the to be exported model files, any string must be up to
       25000 characters long.
      
       * For `docker` format:
       `cpu_architecture` - (string) "x86_64" (default).
       `gpu_architecture` - (string) "none" (default), "nvidia".
       
      map<string, string> params = 2;
      Specified by:
      containsParams in interface ModelExportOutputConfigOrBuilder
    • getParams

      @Deprecated public Map<String,String> getParams()
      Deprecated.
      Use getParamsMap() instead.
      Specified by:
      getParams in interface ModelExportOutputConfigOrBuilder
    • getParamsMap

      public Map<String,String> getParamsMap()
       Additional model-type and format specific parameters describing the
       requirements for the to be exported model files, any string must be up to
       25000 characters long.
      
       * For `docker` format:
       `cpu_architecture` - (string) "x86_64" (default).
       `gpu_architecture` - (string) "none" (default), "nvidia".
       
      map<string, string> params = 2;
      Specified by:
      getParamsMap in interface ModelExportOutputConfigOrBuilder
    • getParamsOrDefault

      public String getParamsOrDefault(String key, String defaultValue)
       Additional model-type and format specific parameters describing the
       requirements for the to be exported model files, any string must be up to
       25000 characters long.
      
       * For `docker` format:
       `cpu_architecture` - (string) "x86_64" (default).
       `gpu_architecture` - (string) "none" (default), "nvidia".
       
      map<string, string> params = 2;
      Specified by:
      getParamsOrDefault in interface ModelExportOutputConfigOrBuilder
    • getParamsOrThrow

      public String getParamsOrThrow(String key)
       Additional model-type and format specific parameters describing the
       requirements for the to be exported model files, any string must be up to
       25000 characters long.
      
       * For `docker` format:
       `cpu_architecture` - (string) "x86_64" (default).
       `gpu_architecture` - (string) "none" (default), "nvidia".
       
      map<string, string> params = 2;
      Specified by:
      getParamsOrThrow in interface ModelExportOutputConfigOrBuilder
    • clearParams

      public ModelExportOutputConfig.Builder clearParams()
    • removeParams

      public ModelExportOutputConfig.Builder removeParams(String key)
       Additional model-type and format specific parameters describing the
       requirements for the to be exported model files, any string must be up to
       25000 characters long.
      
       * For `docker` format:
       `cpu_architecture` - (string) "x86_64" (default).
       `gpu_architecture` - (string) "none" (default), "nvidia".
       
      map<string, string> params = 2;
    • getMutableParams

      @Deprecated public Map<String,String> getMutableParams()
      Deprecated.
      Use alternate mutation accessors instead.
    • putParams

      public ModelExportOutputConfig.Builder putParams(String key, String value)
       Additional model-type and format specific parameters describing the
       requirements for the to be exported model files, any string must be up to
       25000 characters long.
      
       * For `docker` format:
       `cpu_architecture` - (string) "x86_64" (default).
       `gpu_architecture` - (string) "none" (default), "nvidia".
       
      map<string, string> params = 2;
    • putAllParams

      public ModelExportOutputConfig.Builder putAllParams(Map<String,String> values)
       Additional model-type and format specific parameters describing the
       requirements for the to be exported model files, any string must be up to
       25000 characters long.
      
       * For `docker` format:
       `cpu_architecture` - (string) "x86_64" (default).
       `gpu_architecture` - (string) "none" (default), "nvidia".
       
      map<string, string> params = 2;