- Resource: Model
- TranslationModelMetadata
- ImageClassificationModelMetadata
- TextClassificationModelMetadata
- ImageObjectDetectionModelMetadata
- VideoClassificationModelMetadata
- VideoObjectTrackingModelMetadata
- TextExtractionModelMetadata
- TablesModelMetadata
- TablesModelColumnInfo
- TextSentimentModelMetadata
- DeploymentState
- Methods
Resource: Model
API proto representing a trained machine learning model.
JSON representation | |
---|---|
{ "name": string, "displayName": string, "datasetId": string, "createTime": string, "updateTime": string, "deploymentState": enum ( |
Fields | ||
---|---|---|
name |
Output only. Resource name of the model. Format: |
|
displayName |
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. |
|
datasetId |
Required. The resource ID of the dataset used to create the model. The dataset must come from the same ancestor project and location. |
|
createTime |
Output only. Timestamp when the model training finished and can be used for prediction. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: |
|
updateTime |
Output only. Timestamp when this model was last updated. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: |
|
deploymentState |
Output only. Deployment state of the model. A model can only serve prediction requests after it gets deployed. |
|
Union field model_metadata . Required. The model metadata that is specific to the problem type. Must match the metadata type of the dataset used to train the model. model_metadata can be only one of the following: |
||
translationModelMetadata |
Metadata for translation models. |
|
imageClassificationModelMetadata |
Metadata for image classification models. |
|
textClassificationModelMetadata |
Metadata for text classification models. |
|
imageObjectDetectionModelMetadata |
Metadata for image object detection models. |
|
videoClassificationModelMetadata |
Metadata for video classification models. |
|
videoObjectTrackingModelMetadata |
Metadata for video object tracking models. |
|
textExtractionModelMetadata |
Metadata for text extraction models. |
|
tablesModelMetadata |
Metadata for Tables models. |
|
textSentimentModelMetadata |
Metadata for text sentiment models. |
TranslationModelMetadata
Model metadata that is specific to translation.
JSON representation | |
---|---|
{ "baseModel": string, "sourceLanguageCode": string, "targetLanguageCode": string } |
Fields | |
---|---|
baseModel |
The resource name of the model to use as a baseline to train the custom model. If unset, we use the default base model provided by Google Translate. Format: |
sourceLanguageCode |
Output only. Inferred from the dataset. The source languge (The BCP-47 language code) that is used for training. |
targetLanguageCode |
Output only. The target languge (The BCP-47 language code) that is used for training. |
ImageClassificationModelMetadata
Model metadata for image classification.
JSON representation | |
---|---|
{ "baseModelId": string, "trainBudget": string, "trainCost": string, "stopReason": string, "modelType": string, "nodeQps": number, "nodeCount": string } |
Fields | |
---|---|
baseModelId |
Optional. The ID of the |
trainBudget |
Required. The train budget of creating this model, expressed in hours. The actual |
trainCost |
Output only. The actual train cost of creating this model, expressed in hours. If this model is created from a |
stopReason |
Output only. The reason that this create model operation stopped, e.g. |
modelType |
Optional. Type of the model. The available values are: * |
nodeQps |
Output only. An approximate number of online prediction QPS that can be supported by this model per each node on which it is deployed. |
nodeCount |
Output only. The number of nodes this model is deployed on. A node is an abstraction of a machine resource, which can handle online prediction QPS as given in the nodeQps field. |
TextClassificationModelMetadata
Model metadata that is specific to text classification.
JSON representation | |
---|---|
{
"classificationType": enum ( |
Fields | |
---|---|
classificationType |
Output only. Classification type of the dataset used to train this model. |
ImageObjectDetectionModelMetadata
Model metadata specific to image object detection.
JSON representation | |
---|---|
{ "modelType": string, "nodeCount": string, "nodeQps": number, "stopReason": string, "trainBudgetMilliNodeHours": string, "trainCostMilliNodeHours": string } |
Fields | |
---|---|
modelType |
Optional. Type of the model. The available values are: * |
nodeCount |
Output only. The number of nodes this model is deployed on. A node is an abstraction of a machine resource, which can handle online prediction QPS as given in the qps_per_node field. |
nodeQps |
Output only. An approximate number of online prediction QPS that can be supported by this model per each node on which it is deployed. |
stopReason |
Output only. The reason that this create model operation stopped, e.g. |
trainBudgetMilliNodeHours |
The train budget of creating this model, expressed in milli node hours i.e. 1,000 value in this field means 1 node hour. The actual |
trainCostMilliNodeHours |
Output only. The actual train cost of creating this model, expressed in milli node hours, i.e. 1,000 value in this field means 1 node hour. Guaranteed to not exceed the train budget. |
VideoClassificationModelMetadata
Model metadata specific to video classification.
VideoObjectTrackingModelMetadata
Model metadata specific to video object tracking.
TextExtractionModelMetadata
Model metadata that is specific to text extraction.
JSON representation | |
---|---|
{ "modelHint": string } |
Fields | |
---|---|
modelHint |
Indicates the scope of model use case.
|
TablesModelMetadata
Model metadata specific to AutoML Tables.
JSON representation | |
---|---|
{ "targetColumnSpec": { object ( |
Fields | ||
---|---|---|
targetColumnSpec |
Column spec of the dataset's primary table's column the model is predicting. Snapshotted when model creation started. Only 3 fields are used: name - May be set on models.create, if it's not then the ColumnSpec corresponding to the current targetColumnSpecId of the dataset the model is trained from is used. If neither is set, models.create will error. displayName - Output only. dataType - Output only. |
|
inputFeatureColumnSpecs[] |
Column specs of the dataset's primary table's columns, on which the model is trained and which are used as the input for predictions. The
Only 3 fields are used:
|
|
optimizationObjective |
Objective function the model is optimizing towards. The training process creates a model that maximizes/minimizes the value of the objective function over the validation set. The supported optimization objectives depend on the prediction type. If the field is not set, a default objective function is used. CLASSIFICATION_BINARY: "MAXIMIZE_AU_ROC" (default) - Maximize the area under the receiver operating characteristic (ROC) curve. "MINIMIZE_LOG_LOSS" - Minimize log loss. "MAXIMIZE_AU_PRC" - Maximize the area under the precision-recall curve. "MAXIMIZE_PRECISION_AT_RECALL" - Maximize precision for a specified recall value. "MAXIMIZE_RECALL_AT_PRECISION" - Maximize recall for a specified precision value. CLASSIFICATION_MULTI_CLASS : "MINIMIZE_LOG_LOSS" (default) - Minimize log loss. REGRESSION: "MINIMIZE_RMSE" (default) - Minimize root-mean-squared error (RMSE). "MINIMIZE_MAE" - Minimize mean-absolute error (MAE). "MINIMIZE_RMSLE" - Minimize root-mean-squared log error (RMSLE). |
|
tablesModelColumnInfo[] |
Output only. Auxiliary information for each of the inputFeatureColumnSpecs with respect to this particular model. |
|
trainBudgetMilliNodeHours |
Required. The train budget of creating this model, expressed in milli node hours i.e. 1,000 value in this field means 1 node hour. The training cost of the model will not exceed this budget. The final cost will be attempted to be close to the budget, though may end up being (even) noticeably smaller - at the backend's discretion. This especially may happen when further model training ceases to provide any improvements. If the budget is set to a value known to be insufficient to train a model for the given dataset, the training won't be attempted and will error. The train budget must be between 1,000 and 72,000 milli node hours, inclusive. |
|
trainCostMilliNodeHours |
Output only. The actual training cost of the model, expressed in milli node hours, i.e. 1,000 value in this field means 1 node hour. Guaranteed to not exceed the train budget. |
|
disableEarlyStopping |
Use the entire training budget. This disables the early stopping feature. By default, the early stopping feature is enabled, which means that AutoML Tables might stop training before the entire training budget has been used. |
|
Union field additional_optimization_objective_config . Additional optimization objective configuration. Required for MAXIMIZE_PRECISION_AT_RECALL and MAXIMIZE_RECALL_AT_PRECISION , otherwise unused. additional_optimization_objective_config can be only one of the following: |
||
optimizationObjectiveRecallValue |
Required when optimizationObjective is "MAXIMIZE_PRECISION_AT_RECALL". Must be between 0 and 1, inclusive. |
|
optimizationObjectivePrecisionValue |
Required when optimizationObjective is "MAXIMIZE_RECALL_AT_PRECISION". Must be between 0 and 1, inclusive. |
TablesModelColumnInfo
An information specific to given column and Tables Model, in context of the Model and the predictions created by it.
JSON representation | |
---|---|
{ "columnSpecName": string, "columnDisplayName": string, "featureImportance": number } |
Fields | |
---|---|
columnSpecName |
Output only. The name of the ColumnSpec describing the column. Not populated when this proto is outputted to BigQuery. |
columnDisplayName |
Output only. The display name of the column (same as the displayName of its ColumnSpec). |
featureImportance |
Output only. When given as part of a Model (always populated): Measurement of how much model predictions correctness on the TEST data depend on values in this column. A value between 0 and 1, higher means higher influence. These values are normalized - for all input feature columns of a given model they add to 1. When given back by models.predict (populated iff |
TextSentimentModelMetadata
Model metadata that is specific to text sentiment.
DeploymentState
Deployment state of the model.
Enums | |
---|---|
DEPLOYMENT_STATE_UNSPECIFIED |
Should not be used, an un-set enum has this value by default. |
DEPLOYED |
Model is deployed. |
UNDEPLOYED |
Model is not deployed. |
Methods |
|
---|---|
|
Perform a batch prediction. |
|
Creates a model. |
|
Deletes a model. |
|
Deploys a model. |
|
Exports a trained, "export-able", model to a user specified Google Cloud Storage location. |
|
Exports examples on which the model was evaluated (i.e. |
|
Gets a model. |
|
Gets the access control policy for a resource. |
|
Lists models. |
|
Perform an online prediction. |
|
Sets the access control policy on the specified resource. |
|
Undeploys a model. |