blob: b4ad06bded8dddbc4f2773757a918e39157c9827 [file] [log] [blame]
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="bigquery_v2.html">BigQuery API</a> . <a href="bigquery_v2.models.html">models</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070078 <code><a href="#close">close()</a></code></p>
79<p class="firstline">Close httplib2 connections.</p>
80<p class="toc_element">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070081 <code><a href="#delete">delete(projectId, datasetId, modelId)</a></code></p>
82<p class="firstline">Deletes the model specified by modelId from the dataset.</p>
83<p class="toc_element">
84 <code><a href="#get">get(projectId, datasetId, modelId)</a></code></p>
85<p class="firstline">Gets the specified model resource by model ID.</p>
86<p class="toc_element">
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -080087 <code><a href="#list">list(projectId, datasetId, pageToken=None, maxResults=None)</a></code></p>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070088<p class="firstline">Lists all models in the specified dataset. Requires the READER dataset role.</p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070089<p class="toc_element">
90 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
91<p class="firstline">Retrieves the next page of results.</p>
92<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070093 <code><a href="#patch">patch(projectId, datasetId, modelId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070094<p class="firstline">Patch specific fields in the specified model.</p>
95<h3>Method Details</h3>
96<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070097 <code class="details" id="close">close()</code>
98 <pre>Close httplib2 connections.</pre>
99</div>
100
101<div class="method">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700102 <code class="details" id="delete">delete(projectId, datasetId, modelId)</code>
103 <pre>Deletes the model specified by modelId from the dataset.
104
105Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700106 projectId: string, Required. Project ID of the model to delete. (required)
107 datasetId: string, Required. Dataset ID of the model to delete. (required)
108 modelId: string, Required. Model ID of the model to delete. (required)
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700109</pre>
110</div>
111
112<div class="method">
113 <code class="details" id="get">get(projectId, datasetId, modelId)</code>
114 <pre>Gets the specified model resource by model ID.
115
116Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700117 projectId: string, Required. Project ID of the requested model. (required)
118 datasetId: string, Required. Dataset ID of the requested model. (required)
119 modelId: string, Required. Model ID of the requested model. (required)
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700120
121Returns:
122 An object of the form:
123
124 {
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800125 &quot;description&quot;: &quot;A String&quot;, # Optional. A user-friendly description of this model.
126 &quot;friendlyName&quot;: &quot;A String&quot;, # Optional. A descriptive name for this model.
127 &quot;trainingRuns&quot;: [ # Output only. Information for all training runs in increasing order of start_time.
128 { # Information about a single training query run for the model.
129 &quot;dataSplitResult&quot;: { # Data split result. This contains references to the training and evaluation data tables that were used to train the model. # Data split result of the training run. Only set when the input data is actually split.
130 &quot;trainingTable&quot;: { # Table reference of the training data after split.
131 &quot;tableId&quot;: &quot;A String&quot;, # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
132 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this table.
133 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this table.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700134 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800135 &quot;evaluationTable&quot;: { # Table reference of the evaluation data after split.
136 &quot;tableId&quot;: &quot;A String&quot;, # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
137 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this table.
138 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this table.
139 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800140 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800141 &quot;results&quot;: [ # Output of each iteration run, results.size() &lt;= max_iterations.
142 { # Information about a single iteration of the training run.
143 &quot;trainingLoss&quot;: 3.14, # Loss computed on the training data at the end of iteration.
144 &quot;arimaResult&quot;: { # (Auto-)arima fitting result. Wrap everything in ArimaResult for easier refactoring if we want to use model-specific iteration results.
145 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
146 &quot;A String&quot;,
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800147 ],
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800148 &quot;arimaModelInfo&quot;: [ # This message is repeated because there are multiple arima models fitted in auto-arima. For non-auto-arima model, its size is one.
149 { # Arima model information.
Bu Sun Kim65020912020-05-20 12:08:20 -0700150 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # Non-seasonal order.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800151 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800152 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
153 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
154 },
155 &quot;timeSeriesId&quot;: &quot;A String&quot;, # The id to indicate different time series.
156 &quot;arimaCoefficients&quot;: { # Arima coefficients. # Arima coefficients.
157 &quot;movingAverageCoefficients&quot;: [ # Moving-average coefficients, an array of double.
158 3.14,
159 ],
160 &quot;interceptCoefficient&quot;: 3.14, # Intercept coefficient, just a double not an array.
161 &quot;autoRegressiveCoefficients&quot;: [ # Auto-regressive coefficients, an array of double.
162 3.14,
163 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700164 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700165 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
166 &quot;A String&quot;,
167 ],
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800168 &quot;hasDrift&quot;: True or False, # Whether Arima model fitted with drift or not. It is always false when d is not 1.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800169 &quot;arimaFittingMetrics&quot;: { # ARIMA model fitting metrics. # Arima fitting metrics.
170 &quot;variance&quot;: 3.14, # Variance.
171 &quot;aic&quot;: 3.14, # AIC.
172 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
173 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700174 },
175 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700176 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800177 &quot;index&quot;: 42, # Index of the iteration, 0 based.
178 &quot;durationMs&quot;: &quot;A String&quot;, # Time taken to run the iteration in milliseconds.
179 &quot;clusterInfos&quot;: [ # Information about top clusters for clustering models.
180 { # Information about a single cluster for clustering model.
181 &quot;clusterSize&quot;: &quot;A String&quot;, # Cluster size, the total number of points assigned to the cluster.
182 &quot;clusterRadius&quot;: 3.14, # Cluster radius, the average distance from centroid to each point assigned to the cluster.
183 &quot;centroidId&quot;: &quot;A String&quot;, # Centroid id.
184 },
185 ],
186 &quot;learnRate&quot;: 3.14, # Learn rate used for this iteration.
187 &quot;evalLoss&quot;: 3.14, # Loss computed on the eval data at the end of iteration.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700188 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800189 ],
190 &quot;trainingOptions&quot;: { # Options that were used for this training run, includes user specified and default options that were used.
191 &quot;inputLabelColumns&quot;: [ # Name of input label columns in training data.
192 &quot;A String&quot;,
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800193 ],
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800194 &quot;dataFrequency&quot;: &quot;A String&quot;, # The data frequency of a time series.
195 &quot;walsAlpha&quot;: 3.14, # Hyperparameter for matrix factoration when implicit feedback type is specified.
196 &quot;userColumn&quot;: &quot;A String&quot;, # User column specified for matrix factorization models.
197 &quot;autoArimaMaxOrder&quot;: &quot;A String&quot;, # The max value of non-seasonal p and q.
198 &quot;batchSize&quot;: &quot;A String&quot;, # Batch size for dnn models.
199 &quot;minSplitLoss&quot;: 3.14, # Minimum split loss for boosted tree models.
200 &quot;dataSplitEvalFraction&quot;: 3.14, # The fraction of evaluation data over the whole input data. The rest of data will be used as training data. The format should be double. Accurate to two decimal places. Default value is 0.2.
201 &quot;modelUri&quot;: &quot;A String&quot;, # [Beta] Google Cloud Storage URI from which the model was imported. Only applicable for imported models.
202 &quot;kmeansInitializationMethod&quot;: &quot;A String&quot;, # The method used to initialize the centroids for kmeans algorithm.
203 &quot;subsample&quot;: 3.14, # Subsample fraction of the training data to grow tree to prevent overfitting for boosted tree models.
204 &quot;l2Regularization&quot;: 3.14, # L2 regularization coefficient.
205 &quot;hiddenUnits&quot;: [ # Hidden units for dnn models.
206 &quot;A String&quot;,
207 ],
208 &quot;initialLearnRate&quot;: 3.14, # Specifies the initial learning rate for the line search learn rate strategy.
209 &quot;maxIterations&quot;: &quot;A String&quot;, # The maximum number of iterations in training. Used only for iterative training algorithms.
210 &quot;feedbackType&quot;: &quot;A String&quot;, # Feedback type that specifies which algorithm to run for matrix factorization.
211 &quot;preserveInputStructs&quot;: True or False, # Whether to preserve the input structs in output feature names. Suppose there is a struct A with field b. When false (default), the output feature name is A_b. When true, the output feature name is A.b.
212 &quot;dataSplitMethod&quot;: &quot;A String&quot;, # The data split type for training and evaluation, e.g. RANDOM.
213 &quot;includeDrift&quot;: True or False, # Include drift when fitting an ARIMA model.
214 &quot;numFactors&quot;: &quot;A String&quot;, # Num factors specified for matrix factorization models.
215 &quot;maxTreeDepth&quot;: &quot;A String&quot;, # Maximum depth of a tree for boosted tree models.
216 &quot;numClusters&quot;: &quot;A String&quot;, # Number of clusters for clustering models.
217 &quot;dataSplitColumn&quot;: &quot;A String&quot;, # The column to split data with. This column won&#x27;t be used as a feature. 1. When data_split_method is CUSTOM, the corresponding column should be boolean. The rows with true value tag are eval data, and the false are training data. 2. When data_split_method is SEQ, the first DATA_SPLIT_EVAL_FRACTION rows (from smallest to largest) in the corresponding column are used as training data, and the rest are eval data. It respects the order in Orderable data types: https://cloud.google.com/bigquery/docs/reference/standard-sql/data-types#data-type-properties
218 &quot;timeSeriesIdColumn&quot;: &quot;A String&quot;, # The id column that will be used to indicate different time series to forecast in parallel.
219 &quot;dropout&quot;: 3.14, # Dropout probability for dnn models.
220 &quot;itemColumn&quot;: &quot;A String&quot;, # Item column specified for matrix factorization models.
221 &quot;timeSeriesTimestampColumn&quot;: &quot;A String&quot;, # Column to be designated as time series timestamp for ARIMA model.
222 &quot;minRelativeProgress&quot;: 3.14, # When early_stop is true, stops training when accuracy improvement is less than &#x27;min_relative_progress&#x27;. Used only for iterative training algorithms.
223 &quot;autoArima&quot;: True or False, # Whether to enable auto ARIMA or not.
224 &quot;learnRate&quot;: 3.14, # Learning rate in training. Used only for iterative training algorithms.
225 &quot;warmStart&quot;: True or False, # Whether to train a model from the last checkpoint.
226 &quot;holidayRegion&quot;: &quot;A String&quot;, # The geographical region based on which the holidays are considered in time series modeling. If a valid value is specified, then holiday effects modeling is enabled.
227 &quot;lossType&quot;: &quot;A String&quot;, # Type of loss function used during training run.
228 &quot;distanceType&quot;: &quot;A String&quot;, # Distance type for clustering models.
229 &quot;earlyStop&quot;: True or False, # Whether to stop early when the loss doesn&#x27;t improve significantly any more (compared to min_relative_progress). Used only for iterative training algorithms.
230 &quot;learnRateStrategy&quot;: &quot;A String&quot;, # The strategy to determine learn rate for the current iteration.
231 &quot;kmeansInitializationColumn&quot;: &quot;A String&quot;, # The column used to provide the initial centroids for kmeans algorithm when kmeans_initialization_method is CUSTOM.
232 &quot;l1Regularization&quot;: 3.14, # L1 regularization coefficient.
233 &quot;timeSeriesDataColumn&quot;: &quot;A String&quot;, # Column to be designated as time series data for ARIMA model.
234 &quot;horizon&quot;: &quot;A String&quot;, # The number of periods ahead that need to be forecasted.
235 &quot;labelClassWeights&quot;: { # Weights associated with each label class, for rebalancing the training data. Only applicable for classification models.
236 &quot;a_key&quot;: 3.14,
237 },
238 &quot;optimizationStrategy&quot;: &quot;A String&quot;, # Optimization strategy for training linear regression models.
239 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # A specification of the non-seasonal part of the ARIMA model: the three components (p, d, q) are the AR order, the degree of differencing, and the MA order.
240 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
241 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
242 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700243 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700244 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800245 &quot;evaluationMetrics&quot;: { # Evaluation metrics of a model. These are either computed on all training data or just the eval data based on whether eval data was used during training. These are not present for imported models. # The evaluation metrics over training/eval data that were computed at the end of training.
246 &quot;rankingMetrics&quot;: { # Evaluation metrics used by weighted-ALS models specified by feedback_type=implicit. # Populated for implicit feedback type matrix factorization models.
247 &quot;averageRank&quot;: 3.14, # Determines the goodness of a ranking by computing the percentile rank from the predicted confidence and dividing it by the original rank.
248 &quot;meanSquaredError&quot;: 3.14, # Similar to the mean squared error computed in regression and explicit recommendation models except instead of computing the rating directly, the output from evaluate is computed against a preference which is 1 or 0 depending on if the rating exists or not.
249 &quot;meanAveragePrecision&quot;: 3.14, # Calculates a precision per user for all the items by ranking them and then averages all the precisions across all the users.
250 &quot;normalizedDiscountedCumulativeGain&quot;: 3.14, # A metric to determine the goodness of a ranking calculated from the predicted confidence by comparing it to an ideal rank measured by the original ratings.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800251 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800252 &quot;binaryClassificationMetrics&quot;: { # Evaluation metrics for binary classification/classifier models. # Populated for binary classification/classifier models.
253 &quot;aggregateClassificationMetrics&quot;: { # Aggregate metrics for classification/classifier models. For multi-class models, the metrics are either macro-averaged or micro-averaged. When macro-averaged, the metrics are calculated for each label and then an unweighted average is taken of those values. When micro-averaged, the metric is calculated globally by counting the total number of correctly predicted rows. # Aggregate classification metrics.
254 &quot;rocAuc&quot;: 3.14, # Area Under a ROC Curve. For multiclass this is a macro-averaged metric.
255 &quot;threshold&quot;: 3.14, # Threshold at which the metrics are computed. For binary classification models this is the positive class threshold. For multi-class classfication models this is the confidence threshold.
256 &quot;precision&quot;: 3.14, # Precision is the fraction of actual positive predictions that had positive actual labels. For multiclass this is a macro-averaged metric treating each class as a binary classifier.
257 &quot;accuracy&quot;: 3.14, # Accuracy is the fraction of predictions given the correct label. For multiclass this is a micro-averaged metric.
258 &quot;logLoss&quot;: 3.14, # Logarithmic Loss. For multiclass this is a macro-averaged metric.
259 &quot;f1Score&quot;: 3.14, # The F1 score is an average of recall and precision. For multiclass this is a macro-averaged metric.
260 &quot;recall&quot;: 3.14, # Recall is the fraction of actual positive labels that were given a positive prediction. For multiclass this is a macro-averaged metric.
261 },
262 &quot;positiveLabel&quot;: &quot;A String&quot;, # Label representing the positive class.
263 &quot;negativeLabel&quot;: &quot;A String&quot;, # Label representing the negative class.
264 &quot;binaryConfusionMatrixList&quot;: [ # Binary confusion matrix at multiple thresholds.
265 { # Confusion matrix for binary classification models.
266 &quot;positiveClassThreshold&quot;: 3.14, # Threshold value used when computing each of the following metric.
267 &quot;recall&quot;: 3.14, # The fraction of actual positive labels that were given a positive prediction.
268 &quot;precision&quot;: 3.14, # The fraction of actual positive predictions that had positive actual labels.
269 &quot;f1Score&quot;: 3.14, # The equally weighted average of recall and precision.
270 &quot;falseNegatives&quot;: &quot;A String&quot;, # Number of false samples predicted as false.
271 &quot;accuracy&quot;: 3.14, # The fraction of predictions given the correct label.
272 &quot;truePositives&quot;: &quot;A String&quot;, # Number of true samples predicted as true.
273 &quot;falsePositives&quot;: &quot;A String&quot;, # Number of false samples predicted as true.
274 &quot;trueNegatives&quot;: &quot;A String&quot;, # Number of true samples predicted as false.
275 },
276 ],
277 },
278 &quot;multiClassClassificationMetrics&quot;: { # Evaluation metrics for multi-class classification/classifier models. # Populated for multi-class classification/classifier models.
279 &quot;confusionMatrixList&quot;: [ # Confusion matrix at different thresholds.
280 { # Confusion matrix for multi-class classification models.
281 &quot;rows&quot;: [ # One row per actual label.
282 { # A single row in the confusion matrix.
283 &quot;entries&quot;: [ # Info describing predicted label distribution.
284 { # A single entry in the confusion matrix.
285 &quot;predictedLabel&quot;: &quot;A String&quot;, # The predicted label. For confidence_threshold &gt; 0, we will also add an entry indicating the number of items under the confidence threshold.
286 &quot;itemCount&quot;: &quot;A String&quot;, # Number of items being predicted as this label.
287 },
288 ],
289 &quot;actualLabel&quot;: &quot;A String&quot;, # The original label of this row.
290 },
291 ],
292 &quot;confidenceThreshold&quot;: 3.14, # Confidence threshold used when computing the entries of the confusion matrix.
293 },
294 ],
295 &quot;aggregateClassificationMetrics&quot;: { # Aggregate metrics for classification/classifier models. For multi-class models, the metrics are either macro-averaged or micro-averaged. When macro-averaged, the metrics are calculated for each label and then an unweighted average is taken of those values. When micro-averaged, the metric is calculated globally by counting the total number of correctly predicted rows. # Aggregate classification metrics.
296 &quot;rocAuc&quot;: 3.14, # Area Under a ROC Curve. For multiclass this is a macro-averaged metric.
297 &quot;threshold&quot;: 3.14, # Threshold at which the metrics are computed. For binary classification models this is the positive class threshold. For multi-class classfication models this is the confidence threshold.
298 &quot;precision&quot;: 3.14, # Precision is the fraction of actual positive predictions that had positive actual labels. For multiclass this is a macro-averaged metric treating each class as a binary classifier.
299 &quot;accuracy&quot;: 3.14, # Accuracy is the fraction of predictions given the correct label. For multiclass this is a micro-averaged metric.
300 &quot;logLoss&quot;: 3.14, # Logarithmic Loss. For multiclass this is a macro-averaged metric.
301 &quot;f1Score&quot;: 3.14, # The F1 score is an average of recall and precision. For multiclass this is a macro-averaged metric.
302 &quot;recall&quot;: 3.14, # Recall is the fraction of actual positive labels that were given a positive prediction. For multiclass this is a macro-averaged metric.
303 },
304 },
305 &quot;arimaForecastingMetrics&quot;: { # Model evaluation metrics for ARIMA forecasting models. # Populated for ARIMA models.
306 &quot;timeSeriesId&quot;: [ # Id to differentiate different time series for the large-scale case.
307 &quot;A String&quot;,
308 ],
309 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
310 &quot;A String&quot;,
311 ],
312 &quot;nonSeasonalOrder&quot;: [ # Non-seasonal order.
313 { # Arima order, can be used for both non-seasonal and seasonal parts.
314 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
315 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
316 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
317 },
318 ],
319 &quot;arimaSingleModelForecastingMetrics&quot;: [ # Repeated as there can be many metric sets (one for each model) in auto-arima and the large-scale case.
320 { # Model evaluation metrics for a single ARIMA forecasting model.
321 &quot;hasDrift&quot;: True or False, # Is arima model fitted with drift or not. It is always false when d is not 1.
322 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
323 &quot;A String&quot;,
324 ],
325 &quot;timeSeriesId&quot;: &quot;A String&quot;, # The id to indicate different time series.
326 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # Non-seasonal order.
327 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
328 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
329 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
330 },
331 &quot;arimaFittingMetrics&quot;: { # ARIMA model fitting metrics. # Arima fitting metrics.
332 &quot;variance&quot;: 3.14, # Variance.
333 &quot;aic&quot;: 3.14, # AIC.
334 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
335 },
336 },
337 ],
338 &quot;arimaFittingMetrics&quot;: [ # Arima model fitting metrics.
339 { # ARIMA model fitting metrics.
340 &quot;variance&quot;: 3.14, # Variance.
341 &quot;aic&quot;: 3.14, # AIC.
342 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
343 },
344 ],
345 &quot;hasDrift&quot;: [ # Whether Arima model fitted with drift or not. It is always false when d is not 1.
346 True or False,
347 ],
348 },
349 &quot;clusteringMetrics&quot;: { # Evaluation metrics for clustering models. # Populated for clustering models.
350 &quot;clusters&quot;: [ # [Beta] Information for all clusters.
351 { # Message containing the information about one cluster.
352 &quot;featureValues&quot;: [ # Values of highly variant features for this cluster.
353 { # Representative value of a single feature within the cluster.
354 &quot;categoricalValue&quot;: { # Representative value of a categorical feature. # The categorical feature value.
355 &quot;categoryCounts&quot;: [ # Counts of all categories for the categorical feature. If there are more than ten categories, we return top ten (by count) and return one more CategoryCount with category &quot;_OTHER_&quot; and count as aggregate counts of remaining categories.
356 { # Represents the count of a single category within the cluster.
357 &quot;count&quot;: &quot;A String&quot;, # The count of training samples matching the category within the cluster.
358 &quot;category&quot;: &quot;A String&quot;, # The name of category.
359 },
360 ],
361 },
362 &quot;numericalValue&quot;: 3.14, # The numerical feature value. This is the centroid value for this feature.
363 &quot;featureColumn&quot;: &quot;A String&quot;, # The feature column name.
364 },
365 ],
366 &quot;count&quot;: &quot;A String&quot;, # Count of training data rows that were assigned to this cluster.
367 &quot;centroidId&quot;: &quot;A String&quot;, # Centroid id.
368 },
369 ],
370 &quot;daviesBouldinIndex&quot;: 3.14, # Davies-Bouldin index.
371 &quot;meanSquaredDistance&quot;: 3.14, # Mean of squared distances between each sample to its cluster centroid.
372 },
373 &quot;regressionMetrics&quot;: { # Evaluation metrics for regression and explicit feedback type matrix factorization models. # Populated for regression models and explicit feedback type matrix factorization models.
374 &quot;medianAbsoluteError&quot;: 3.14, # Median absolute error.
375 &quot;rSquared&quot;: 3.14, # R^2 score.
376 &quot;meanAbsoluteError&quot;: 3.14, # Mean absolute error.
377 &quot;meanSquaredError&quot;: 3.14, # Mean squared error.
378 &quot;meanSquaredLogError&quot;: 3.14, # Mean squared log error.
379 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800380 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800381 &quot;globalExplanations&quot;: [ # Global explanations for important features of the model. For multi-class models, there is one entry for each label class. For other models, there is only one entry in the list.
382 { # Global explanations containing the top most important features after training.
383 &quot;classLabel&quot;: &quot;A String&quot;, # Class label for this set of global explanations. Will be empty/null for binary logistic and linear regression models. Sorted alphabetically in descending order.
384 &quot;explanations&quot;: [ # A list of the top global explanations. Sorted by absolute value of attribution in descending order.
385 { # Explanation for a single feature.
386 &quot;attribution&quot;: 3.14, # Attribution of feature.
387 &quot;featureName&quot;: &quot;A String&quot;, # Full name of the feature. For non-numerical features, will be formatted like .. Overall size of feature name will always be truncated to first 120 characters.
388 },
389 ],
390 },
391 ],
392 &quot;startTime&quot;: &quot;A String&quot;, # The start time of this training run.
393 },
394 ],
395 &quot;creationTime&quot;: &quot;A String&quot;, # Output only. The time when this model was created, in millisecs since the epoch.
396 &quot;labels&quot;: { # The labels associated with this model. You can use these to organize and group your models. Label keys and values can be no longer than 63 characters, can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. Label values are optional. Label keys must start with a letter and each label in the list must have a different key.
397 &quot;a_key&quot;: &quot;A String&quot;,
398 },
399 &quot;location&quot;: &quot;A String&quot;, # Output only. The geographic location where the model resides. This value is inherited from the dataset.
400 &quot;expirationTime&quot;: &quot;A String&quot;, # Optional. The time when this model expires, in milliseconds since the epoch. If not present, the model will persist indefinitely. Expired models will be deleted and their storage reclaimed. The defaultTableExpirationMs property of the encapsulating dataset can be used to set a default expirationTime on newly created models.
401 &quot;modelType&quot;: &quot;A String&quot;, # Output only. Type of the model resource.
402 &quot;etag&quot;: &quot;A String&quot;, # Output only. A hash of this resource.
403 &quot;modelReference&quot;: { # Required. Unique identifier for this model.
404 &quot;modelId&quot;: &quot;A String&quot;, # [Required] The ID of the model. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
405 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this model.
406 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this model.
407 },
408 &quot;labelColumns&quot;: [ # Output only. Label columns that were used to train this model. The output of the model will have a &quot;predicted_&quot; prefix to these columns.
409 { # A field or a column.
410 &quot;type&quot;: { # The type of a variable, e.g., a function argument. Examples: INT64: {type_kind=&quot;INT64&quot;} ARRAY: {type_kind=&quot;ARRAY&quot;, array_element_type=&quot;STRING&quot;} STRUCT&gt;: {type_kind=&quot;STRUCT&quot;, struct_type={fields=[ {name=&quot;x&quot;, type={type_kind=&quot;STRING&quot;}}, {name=&quot;y&quot;, type={type_kind=&quot;ARRAY&quot;, array_element_type=&quot;DATE&quot;}} ]}} # Optional. The type of this parameter. Absent if not explicitly specified (e.g., CREATE FUNCTION statement can omit the return type; in this case the output parameter does not have this &quot;type&quot; field).
411 &quot;arrayElementType&quot;: # Object with schema name: StandardSqlDataType # The type of the array&#x27;s elements, if type_kind = &quot;ARRAY&quot;.
412 &quot;structType&quot;: { # The fields of this struct, in order, if type_kind = &quot;STRUCT&quot;.
413 &quot;fields&quot;: [
414 # Object with schema name: StandardSqlField
415 ],
416 },
417 &quot;typeKind&quot;: &quot;A String&quot;, # Required. The top level type of this field. Can be any standard SQL data type (e.g., &quot;INT64&quot;, &quot;DATE&quot;, &quot;ARRAY&quot;).
418 },
419 &quot;name&quot;: &quot;A String&quot;, # Optional. The name of this field. Can be absent for struct fields.
420 },
421 ],
422 &quot;featureColumns&quot;: [ # Output only. Input feature columns that were used to train this model.
423 { # A field or a column.
424 &quot;type&quot;: { # The type of a variable, e.g., a function argument. Examples: INT64: {type_kind=&quot;INT64&quot;} ARRAY: {type_kind=&quot;ARRAY&quot;, array_element_type=&quot;STRING&quot;} STRUCT&gt;: {type_kind=&quot;STRUCT&quot;, struct_type={fields=[ {name=&quot;x&quot;, type={type_kind=&quot;STRING&quot;}}, {name=&quot;y&quot;, type={type_kind=&quot;ARRAY&quot;, array_element_type=&quot;DATE&quot;}} ]}} # Optional. The type of this parameter. Absent if not explicitly specified (e.g., CREATE FUNCTION statement can omit the return type; in this case the output parameter does not have this &quot;type&quot; field).
425 &quot;arrayElementType&quot;: # Object with schema name: StandardSqlDataType # The type of the array&#x27;s elements, if type_kind = &quot;ARRAY&quot;.
426 &quot;structType&quot;: { # The fields of this struct, in order, if type_kind = &quot;STRUCT&quot;.
427 &quot;fields&quot;: [
428 # Object with schema name: StandardSqlField
429 ],
430 },
431 &quot;typeKind&quot;: &quot;A String&quot;, # Required. The top level type of this field. Can be any standard SQL data type (e.g., &quot;INT64&quot;, &quot;DATE&quot;, &quot;ARRAY&quot;).
432 },
433 &quot;name&quot;: &quot;A String&quot;, # Optional. The name of this field. Can be absent for struct fields.
434 },
435 ],
436 &quot;encryptionConfiguration&quot;: { # Custom encryption configuration (e.g., Cloud KMS keys). This shows the encryption configuration of the model data while stored in BigQuery storage. This field can be used with PatchModel to update encryption key for an already encrypted model.
437 &quot;kmsKeyName&quot;: &quot;A String&quot;, # [Optional] Describes the Cloud KMS encryption key that will be used to protect destination BigQuery table. The BigQuery Service Account associated with your project requires access to this encryption key.
438 },
439 &quot;lastModifiedTime&quot;: &quot;A String&quot;, # Output only. The time when this model was last modified, in millisecs since the epoch.
440 }</pre>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700441</div>
442
443<div class="method">
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800444 <code class="details" id="list">list(projectId, datasetId, pageToken=None, maxResults=None)</code>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700445 <pre>Lists all models in the specified dataset. Requires the READER dataset role.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700446
447Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700448 projectId: string, Required. Project ID of the models to list. (required)
449 datasetId: string, Required. Dataset ID of the models to list. (required)
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800450 pageToken: string, Page token, returned by a previous call to request the next page of results
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800451 maxResults: integer, The maximum number of results to return in a single response page. Leverage the page tokens to iterate through the entire collection.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700452
453Returns:
454 An object of the form:
455
456 {
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700457 &quot;models&quot;: [ # Models in the requested dataset. Only the following fields are populated: model_reference, model_type, creation_time, last_modified_time and labels.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700458 {
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800459 &quot;description&quot;: &quot;A String&quot;, # Optional. A user-friendly description of this model.
460 &quot;friendlyName&quot;: &quot;A String&quot;, # Optional. A descriptive name for this model.
461 &quot;trainingRuns&quot;: [ # Output only. Information for all training runs in increasing order of start_time.
462 { # Information about a single training query run for the model.
463 &quot;dataSplitResult&quot;: { # Data split result. This contains references to the training and evaluation data tables that were used to train the model. # Data split result of the training run. Only set when the input data is actually split.
464 &quot;trainingTable&quot;: { # Table reference of the training data after split.
465 &quot;tableId&quot;: &quot;A String&quot;, # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
466 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this table.
467 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this table.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700468 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800469 &quot;evaluationTable&quot;: { # Table reference of the evaluation data after split.
470 &quot;tableId&quot;: &quot;A String&quot;, # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
471 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this table.
472 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this table.
473 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800474 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800475 &quot;results&quot;: [ # Output of each iteration run, results.size() &lt;= max_iterations.
476 { # Information about a single iteration of the training run.
477 &quot;trainingLoss&quot;: 3.14, # Loss computed on the training data at the end of iteration.
478 &quot;arimaResult&quot;: { # (Auto-)arima fitting result. Wrap everything in ArimaResult for easier refactoring if we want to use model-specific iteration results.
479 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
480 &quot;A String&quot;,
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800481 ],
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800482 &quot;arimaModelInfo&quot;: [ # This message is repeated because there are multiple arima models fitted in auto-arima. For non-auto-arima model, its size is one.
483 { # Arima model information.
Bu Sun Kim65020912020-05-20 12:08:20 -0700484 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # Non-seasonal order.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800485 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800486 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
487 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
488 },
489 &quot;timeSeriesId&quot;: &quot;A String&quot;, # The id to indicate different time series.
490 &quot;arimaCoefficients&quot;: { # Arima coefficients. # Arima coefficients.
491 &quot;movingAverageCoefficients&quot;: [ # Moving-average coefficients, an array of double.
492 3.14,
493 ],
494 &quot;interceptCoefficient&quot;: 3.14, # Intercept coefficient, just a double not an array.
495 &quot;autoRegressiveCoefficients&quot;: [ # Auto-regressive coefficients, an array of double.
496 3.14,
497 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700498 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700499 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
500 &quot;A String&quot;,
501 ],
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800502 &quot;hasDrift&quot;: True or False, # Whether Arima model fitted with drift or not. It is always false when d is not 1.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800503 &quot;arimaFittingMetrics&quot;: { # ARIMA model fitting metrics. # Arima fitting metrics.
504 &quot;variance&quot;: 3.14, # Variance.
505 &quot;aic&quot;: 3.14, # AIC.
506 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
507 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700508 },
509 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700510 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800511 &quot;index&quot;: 42, # Index of the iteration, 0 based.
512 &quot;durationMs&quot;: &quot;A String&quot;, # Time taken to run the iteration in milliseconds.
513 &quot;clusterInfos&quot;: [ # Information about top clusters for clustering models.
514 { # Information about a single cluster for clustering model.
515 &quot;clusterSize&quot;: &quot;A String&quot;, # Cluster size, the total number of points assigned to the cluster.
516 &quot;clusterRadius&quot;: 3.14, # Cluster radius, the average distance from centroid to each point assigned to the cluster.
517 &quot;centroidId&quot;: &quot;A String&quot;, # Centroid id.
518 },
519 ],
520 &quot;learnRate&quot;: 3.14, # Learn rate used for this iteration.
521 &quot;evalLoss&quot;: 3.14, # Loss computed on the eval data at the end of iteration.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700522 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800523 ],
524 &quot;trainingOptions&quot;: { # Options that were used for this training run, includes user specified and default options that were used.
525 &quot;inputLabelColumns&quot;: [ # Name of input label columns in training data.
526 &quot;A String&quot;,
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800527 ],
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800528 &quot;dataFrequency&quot;: &quot;A String&quot;, # The data frequency of a time series.
529 &quot;walsAlpha&quot;: 3.14, # Hyperparameter for matrix factoration when implicit feedback type is specified.
530 &quot;userColumn&quot;: &quot;A String&quot;, # User column specified for matrix factorization models.
531 &quot;autoArimaMaxOrder&quot;: &quot;A String&quot;, # The max value of non-seasonal p and q.
532 &quot;batchSize&quot;: &quot;A String&quot;, # Batch size for dnn models.
533 &quot;minSplitLoss&quot;: 3.14, # Minimum split loss for boosted tree models.
534 &quot;dataSplitEvalFraction&quot;: 3.14, # The fraction of evaluation data over the whole input data. The rest of data will be used as training data. The format should be double. Accurate to two decimal places. Default value is 0.2.
535 &quot;modelUri&quot;: &quot;A String&quot;, # [Beta] Google Cloud Storage URI from which the model was imported. Only applicable for imported models.
536 &quot;kmeansInitializationMethod&quot;: &quot;A String&quot;, # The method used to initialize the centroids for kmeans algorithm.
537 &quot;subsample&quot;: 3.14, # Subsample fraction of the training data to grow tree to prevent overfitting for boosted tree models.
538 &quot;l2Regularization&quot;: 3.14, # L2 regularization coefficient.
539 &quot;hiddenUnits&quot;: [ # Hidden units for dnn models.
540 &quot;A String&quot;,
541 ],
542 &quot;initialLearnRate&quot;: 3.14, # Specifies the initial learning rate for the line search learn rate strategy.
543 &quot;maxIterations&quot;: &quot;A String&quot;, # The maximum number of iterations in training. Used only for iterative training algorithms.
544 &quot;feedbackType&quot;: &quot;A String&quot;, # Feedback type that specifies which algorithm to run for matrix factorization.
545 &quot;preserveInputStructs&quot;: True or False, # Whether to preserve the input structs in output feature names. Suppose there is a struct A with field b. When false (default), the output feature name is A_b. When true, the output feature name is A.b.
546 &quot;dataSplitMethod&quot;: &quot;A String&quot;, # The data split type for training and evaluation, e.g. RANDOM.
547 &quot;includeDrift&quot;: True or False, # Include drift when fitting an ARIMA model.
548 &quot;numFactors&quot;: &quot;A String&quot;, # Num factors specified for matrix factorization models.
549 &quot;maxTreeDepth&quot;: &quot;A String&quot;, # Maximum depth of a tree for boosted tree models.
550 &quot;numClusters&quot;: &quot;A String&quot;, # Number of clusters for clustering models.
551 &quot;dataSplitColumn&quot;: &quot;A String&quot;, # The column to split data with. This column won&#x27;t be used as a feature. 1. When data_split_method is CUSTOM, the corresponding column should be boolean. The rows with true value tag are eval data, and the false are training data. 2. When data_split_method is SEQ, the first DATA_SPLIT_EVAL_FRACTION rows (from smallest to largest) in the corresponding column are used as training data, and the rest are eval data. It respects the order in Orderable data types: https://cloud.google.com/bigquery/docs/reference/standard-sql/data-types#data-type-properties
552 &quot;timeSeriesIdColumn&quot;: &quot;A String&quot;, # The id column that will be used to indicate different time series to forecast in parallel.
553 &quot;dropout&quot;: 3.14, # Dropout probability for dnn models.
554 &quot;itemColumn&quot;: &quot;A String&quot;, # Item column specified for matrix factorization models.
555 &quot;timeSeriesTimestampColumn&quot;: &quot;A String&quot;, # Column to be designated as time series timestamp for ARIMA model.
556 &quot;minRelativeProgress&quot;: 3.14, # When early_stop is true, stops training when accuracy improvement is less than &#x27;min_relative_progress&#x27;. Used only for iterative training algorithms.
557 &quot;autoArima&quot;: True or False, # Whether to enable auto ARIMA or not.
558 &quot;learnRate&quot;: 3.14, # Learning rate in training. Used only for iterative training algorithms.
559 &quot;warmStart&quot;: True or False, # Whether to train a model from the last checkpoint.
560 &quot;holidayRegion&quot;: &quot;A String&quot;, # The geographical region based on which the holidays are considered in time series modeling. If a valid value is specified, then holiday effects modeling is enabled.
561 &quot;lossType&quot;: &quot;A String&quot;, # Type of loss function used during training run.
562 &quot;distanceType&quot;: &quot;A String&quot;, # Distance type for clustering models.
563 &quot;earlyStop&quot;: True or False, # Whether to stop early when the loss doesn&#x27;t improve significantly any more (compared to min_relative_progress). Used only for iterative training algorithms.
564 &quot;learnRateStrategy&quot;: &quot;A String&quot;, # The strategy to determine learn rate for the current iteration.
565 &quot;kmeansInitializationColumn&quot;: &quot;A String&quot;, # The column used to provide the initial centroids for kmeans algorithm when kmeans_initialization_method is CUSTOM.
566 &quot;l1Regularization&quot;: 3.14, # L1 regularization coefficient.
567 &quot;timeSeriesDataColumn&quot;: &quot;A String&quot;, # Column to be designated as time series data for ARIMA model.
568 &quot;horizon&quot;: &quot;A String&quot;, # The number of periods ahead that need to be forecasted.
569 &quot;labelClassWeights&quot;: { # Weights associated with each label class, for rebalancing the training data. Only applicable for classification models.
570 &quot;a_key&quot;: 3.14,
571 },
572 &quot;optimizationStrategy&quot;: &quot;A String&quot;, # Optimization strategy for training linear regression models.
573 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # A specification of the non-seasonal part of the ARIMA model: the three components (p, d, q) are the AR order, the degree of differencing, and the MA order.
574 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
575 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
576 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700577 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700578 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800579 &quot;evaluationMetrics&quot;: { # Evaluation metrics of a model. These are either computed on all training data or just the eval data based on whether eval data was used during training. These are not present for imported models. # The evaluation metrics over training/eval data that were computed at the end of training.
580 &quot;rankingMetrics&quot;: { # Evaluation metrics used by weighted-ALS models specified by feedback_type=implicit. # Populated for implicit feedback type matrix factorization models.
581 &quot;averageRank&quot;: 3.14, # Determines the goodness of a ranking by computing the percentile rank from the predicted confidence and dividing it by the original rank.
582 &quot;meanSquaredError&quot;: 3.14, # Similar to the mean squared error computed in regression and explicit recommendation models except instead of computing the rating directly, the output from evaluate is computed against a preference which is 1 or 0 depending on if the rating exists or not.
583 &quot;meanAveragePrecision&quot;: 3.14, # Calculates a precision per user for all the items by ranking them and then averages all the precisions across all the users.
584 &quot;normalizedDiscountedCumulativeGain&quot;: 3.14, # A metric to determine the goodness of a ranking calculated from the predicted confidence by comparing it to an ideal rank measured by the original ratings.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800585 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800586 &quot;binaryClassificationMetrics&quot;: { # Evaluation metrics for binary classification/classifier models. # Populated for binary classification/classifier models.
587 &quot;aggregateClassificationMetrics&quot;: { # Aggregate metrics for classification/classifier models. For multi-class models, the metrics are either macro-averaged or micro-averaged. When macro-averaged, the metrics are calculated for each label and then an unweighted average is taken of those values. When micro-averaged, the metric is calculated globally by counting the total number of correctly predicted rows. # Aggregate classification metrics.
588 &quot;rocAuc&quot;: 3.14, # Area Under a ROC Curve. For multiclass this is a macro-averaged metric.
589 &quot;threshold&quot;: 3.14, # Threshold at which the metrics are computed. For binary classification models this is the positive class threshold. For multi-class classfication models this is the confidence threshold.
590 &quot;precision&quot;: 3.14, # Precision is the fraction of actual positive predictions that had positive actual labels. For multiclass this is a macro-averaged metric treating each class as a binary classifier.
591 &quot;accuracy&quot;: 3.14, # Accuracy is the fraction of predictions given the correct label. For multiclass this is a micro-averaged metric.
592 &quot;logLoss&quot;: 3.14, # Logarithmic Loss. For multiclass this is a macro-averaged metric.
593 &quot;f1Score&quot;: 3.14, # The F1 score is an average of recall and precision. For multiclass this is a macro-averaged metric.
594 &quot;recall&quot;: 3.14, # Recall is the fraction of actual positive labels that were given a positive prediction. For multiclass this is a macro-averaged metric.
595 },
596 &quot;positiveLabel&quot;: &quot;A String&quot;, # Label representing the positive class.
597 &quot;negativeLabel&quot;: &quot;A String&quot;, # Label representing the negative class.
598 &quot;binaryConfusionMatrixList&quot;: [ # Binary confusion matrix at multiple thresholds.
599 { # Confusion matrix for binary classification models.
600 &quot;positiveClassThreshold&quot;: 3.14, # Threshold value used when computing each of the following metric.
601 &quot;recall&quot;: 3.14, # The fraction of actual positive labels that were given a positive prediction.
602 &quot;precision&quot;: 3.14, # The fraction of actual positive predictions that had positive actual labels.
603 &quot;f1Score&quot;: 3.14, # The equally weighted average of recall and precision.
604 &quot;falseNegatives&quot;: &quot;A String&quot;, # Number of false samples predicted as false.
605 &quot;accuracy&quot;: 3.14, # The fraction of predictions given the correct label.
606 &quot;truePositives&quot;: &quot;A String&quot;, # Number of true samples predicted as true.
607 &quot;falsePositives&quot;: &quot;A String&quot;, # Number of false samples predicted as true.
608 &quot;trueNegatives&quot;: &quot;A String&quot;, # Number of true samples predicted as false.
609 },
610 ],
611 },
612 &quot;multiClassClassificationMetrics&quot;: { # Evaluation metrics for multi-class classification/classifier models. # Populated for multi-class classification/classifier models.
613 &quot;confusionMatrixList&quot;: [ # Confusion matrix at different thresholds.
614 { # Confusion matrix for multi-class classification models.
615 &quot;rows&quot;: [ # One row per actual label.
616 { # A single row in the confusion matrix.
617 &quot;entries&quot;: [ # Info describing predicted label distribution.
618 { # A single entry in the confusion matrix.
619 &quot;predictedLabel&quot;: &quot;A String&quot;, # The predicted label. For confidence_threshold &gt; 0, we will also add an entry indicating the number of items under the confidence threshold.
620 &quot;itemCount&quot;: &quot;A String&quot;, # Number of items being predicted as this label.
621 },
622 ],
623 &quot;actualLabel&quot;: &quot;A String&quot;, # The original label of this row.
624 },
625 ],
626 &quot;confidenceThreshold&quot;: 3.14, # Confidence threshold used when computing the entries of the confusion matrix.
627 },
628 ],
629 &quot;aggregateClassificationMetrics&quot;: { # Aggregate metrics for classification/classifier models. For multi-class models, the metrics are either macro-averaged or micro-averaged. When macro-averaged, the metrics are calculated for each label and then an unweighted average is taken of those values. When micro-averaged, the metric is calculated globally by counting the total number of correctly predicted rows. # Aggregate classification metrics.
630 &quot;rocAuc&quot;: 3.14, # Area Under a ROC Curve. For multiclass this is a macro-averaged metric.
631 &quot;threshold&quot;: 3.14, # Threshold at which the metrics are computed. For binary classification models this is the positive class threshold. For multi-class classfication models this is the confidence threshold.
632 &quot;precision&quot;: 3.14, # Precision is the fraction of actual positive predictions that had positive actual labels. For multiclass this is a macro-averaged metric treating each class as a binary classifier.
633 &quot;accuracy&quot;: 3.14, # Accuracy is the fraction of predictions given the correct label. For multiclass this is a micro-averaged metric.
634 &quot;logLoss&quot;: 3.14, # Logarithmic Loss. For multiclass this is a macro-averaged metric.
635 &quot;f1Score&quot;: 3.14, # The F1 score is an average of recall and precision. For multiclass this is a macro-averaged metric.
636 &quot;recall&quot;: 3.14, # Recall is the fraction of actual positive labels that were given a positive prediction. For multiclass this is a macro-averaged metric.
637 },
638 },
639 &quot;arimaForecastingMetrics&quot;: { # Model evaluation metrics for ARIMA forecasting models. # Populated for ARIMA models.
640 &quot;timeSeriesId&quot;: [ # Id to differentiate different time series for the large-scale case.
641 &quot;A String&quot;,
642 ],
643 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
644 &quot;A String&quot;,
645 ],
646 &quot;nonSeasonalOrder&quot;: [ # Non-seasonal order.
647 { # Arima order, can be used for both non-seasonal and seasonal parts.
648 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
649 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
650 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
651 },
652 ],
653 &quot;arimaSingleModelForecastingMetrics&quot;: [ # Repeated as there can be many metric sets (one for each model) in auto-arima and the large-scale case.
654 { # Model evaluation metrics for a single ARIMA forecasting model.
655 &quot;hasDrift&quot;: True or False, # Is arima model fitted with drift or not. It is always false when d is not 1.
656 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
657 &quot;A String&quot;,
658 ],
659 &quot;timeSeriesId&quot;: &quot;A String&quot;, # The id to indicate different time series.
660 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # Non-seasonal order.
661 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
662 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
663 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
664 },
665 &quot;arimaFittingMetrics&quot;: { # ARIMA model fitting metrics. # Arima fitting metrics.
666 &quot;variance&quot;: 3.14, # Variance.
667 &quot;aic&quot;: 3.14, # AIC.
668 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
669 },
670 },
671 ],
672 &quot;arimaFittingMetrics&quot;: [ # Arima model fitting metrics.
673 { # ARIMA model fitting metrics.
674 &quot;variance&quot;: 3.14, # Variance.
675 &quot;aic&quot;: 3.14, # AIC.
676 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
677 },
678 ],
679 &quot;hasDrift&quot;: [ # Whether Arima model fitted with drift or not. It is always false when d is not 1.
680 True or False,
681 ],
682 },
683 &quot;clusteringMetrics&quot;: { # Evaluation metrics for clustering models. # Populated for clustering models.
684 &quot;clusters&quot;: [ # [Beta] Information for all clusters.
685 { # Message containing the information about one cluster.
686 &quot;featureValues&quot;: [ # Values of highly variant features for this cluster.
687 { # Representative value of a single feature within the cluster.
688 &quot;categoricalValue&quot;: { # Representative value of a categorical feature. # The categorical feature value.
689 &quot;categoryCounts&quot;: [ # Counts of all categories for the categorical feature. If there are more than ten categories, we return top ten (by count) and return one more CategoryCount with category &quot;_OTHER_&quot; and count as aggregate counts of remaining categories.
690 { # Represents the count of a single category within the cluster.
691 &quot;count&quot;: &quot;A String&quot;, # The count of training samples matching the category within the cluster.
692 &quot;category&quot;: &quot;A String&quot;, # The name of category.
693 },
694 ],
695 },
696 &quot;numericalValue&quot;: 3.14, # The numerical feature value. This is the centroid value for this feature.
697 &quot;featureColumn&quot;: &quot;A String&quot;, # The feature column name.
698 },
699 ],
700 &quot;count&quot;: &quot;A String&quot;, # Count of training data rows that were assigned to this cluster.
701 &quot;centroidId&quot;: &quot;A String&quot;, # Centroid id.
702 },
703 ],
704 &quot;daviesBouldinIndex&quot;: 3.14, # Davies-Bouldin index.
705 &quot;meanSquaredDistance&quot;: 3.14, # Mean of squared distances between each sample to its cluster centroid.
706 },
707 &quot;regressionMetrics&quot;: { # Evaluation metrics for regression and explicit feedback type matrix factorization models. # Populated for regression models and explicit feedback type matrix factorization models.
708 &quot;medianAbsoluteError&quot;: 3.14, # Median absolute error.
709 &quot;rSquared&quot;: 3.14, # R^2 score.
710 &quot;meanAbsoluteError&quot;: 3.14, # Mean absolute error.
711 &quot;meanSquaredError&quot;: 3.14, # Mean squared error.
712 &quot;meanSquaredLogError&quot;: 3.14, # Mean squared log error.
713 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800714 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800715 &quot;globalExplanations&quot;: [ # Global explanations for important features of the model. For multi-class models, there is one entry for each label class. For other models, there is only one entry in the list.
716 { # Global explanations containing the top most important features after training.
717 &quot;classLabel&quot;: &quot;A String&quot;, # Class label for this set of global explanations. Will be empty/null for binary logistic and linear regression models. Sorted alphabetically in descending order.
718 &quot;explanations&quot;: [ # A list of the top global explanations. Sorted by absolute value of attribution in descending order.
719 { # Explanation for a single feature.
720 &quot;attribution&quot;: 3.14, # Attribution of feature.
721 &quot;featureName&quot;: &quot;A String&quot;, # Full name of the feature. For non-numerical features, will be formatted like .. Overall size of feature name will always be truncated to first 120 characters.
722 },
723 ],
724 },
725 ],
726 &quot;startTime&quot;: &quot;A String&quot;, # The start time of this training run.
727 },
728 ],
729 &quot;creationTime&quot;: &quot;A String&quot;, # Output only. The time when this model was created, in millisecs since the epoch.
730 &quot;labels&quot;: { # The labels associated with this model. You can use these to organize and group your models. Label keys and values can be no longer than 63 characters, can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. Label values are optional. Label keys must start with a letter and each label in the list must have a different key.
731 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700732 },
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800733 &quot;location&quot;: &quot;A String&quot;, # Output only. The geographic location where the model resides. This value is inherited from the dataset.
734 &quot;expirationTime&quot;: &quot;A String&quot;, # Optional. The time when this model expires, in milliseconds since the epoch. If not present, the model will persist indefinitely. Expired models will be deleted and their storage reclaimed. The defaultTableExpirationMs property of the encapsulating dataset can be used to set a default expirationTime on newly created models.
735 &quot;modelType&quot;: &quot;A String&quot;, # Output only. Type of the model resource.
736 &quot;etag&quot;: &quot;A String&quot;, # Output only. A hash of this resource.
737 &quot;modelReference&quot;: { # Required. Unique identifier for this model.
738 &quot;modelId&quot;: &quot;A String&quot;, # [Required] The ID of the model. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
739 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this model.
740 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this model.
741 },
742 &quot;labelColumns&quot;: [ # Output only. Label columns that were used to train this model. The output of the model will have a &quot;predicted_&quot; prefix to these columns.
743 { # A field or a column.
744 &quot;type&quot;: { # The type of a variable, e.g., a function argument. Examples: INT64: {type_kind=&quot;INT64&quot;} ARRAY: {type_kind=&quot;ARRAY&quot;, array_element_type=&quot;STRING&quot;} STRUCT&gt;: {type_kind=&quot;STRUCT&quot;, struct_type={fields=[ {name=&quot;x&quot;, type={type_kind=&quot;STRING&quot;}}, {name=&quot;y&quot;, type={type_kind=&quot;ARRAY&quot;, array_element_type=&quot;DATE&quot;}} ]}} # Optional. The type of this parameter. Absent if not explicitly specified (e.g., CREATE FUNCTION statement can omit the return type; in this case the output parameter does not have this &quot;type&quot; field).
745 &quot;arrayElementType&quot;: # Object with schema name: StandardSqlDataType # The type of the array&#x27;s elements, if type_kind = &quot;ARRAY&quot;.
746 &quot;structType&quot;: { # The fields of this struct, in order, if type_kind = &quot;STRUCT&quot;.
747 &quot;fields&quot;: [
748 # Object with schema name: StandardSqlField
749 ],
750 },
751 &quot;typeKind&quot;: &quot;A String&quot;, # Required. The top level type of this field. Can be any standard SQL data type (e.g., &quot;INT64&quot;, &quot;DATE&quot;, &quot;ARRAY&quot;).
752 },
753 &quot;name&quot;: &quot;A String&quot;, # Optional. The name of this field. Can be absent for struct fields.
754 },
755 ],
756 &quot;featureColumns&quot;: [ # Output only. Input feature columns that were used to train this model.
757 { # A field or a column.
758 &quot;type&quot;: { # The type of a variable, e.g., a function argument. Examples: INT64: {type_kind=&quot;INT64&quot;} ARRAY: {type_kind=&quot;ARRAY&quot;, array_element_type=&quot;STRING&quot;} STRUCT&gt;: {type_kind=&quot;STRUCT&quot;, struct_type={fields=[ {name=&quot;x&quot;, type={type_kind=&quot;STRING&quot;}}, {name=&quot;y&quot;, type={type_kind=&quot;ARRAY&quot;, array_element_type=&quot;DATE&quot;}} ]}} # Optional. The type of this parameter. Absent if not explicitly specified (e.g., CREATE FUNCTION statement can omit the return type; in this case the output parameter does not have this &quot;type&quot; field).
759 &quot;arrayElementType&quot;: # Object with schema name: StandardSqlDataType # The type of the array&#x27;s elements, if type_kind = &quot;ARRAY&quot;.
760 &quot;structType&quot;: { # The fields of this struct, in order, if type_kind = &quot;STRUCT&quot;.
761 &quot;fields&quot;: [
762 # Object with schema name: StandardSqlField
763 ],
764 },
765 &quot;typeKind&quot;: &quot;A String&quot;, # Required. The top level type of this field. Can be any standard SQL data type (e.g., &quot;INT64&quot;, &quot;DATE&quot;, &quot;ARRAY&quot;).
766 },
767 &quot;name&quot;: &quot;A String&quot;, # Optional. The name of this field. Can be absent for struct fields.
768 },
769 ],
770 &quot;encryptionConfiguration&quot;: { # Custom encryption configuration (e.g., Cloud KMS keys). This shows the encryption configuration of the model data while stored in BigQuery storage. This field can be used with PatchModel to update encryption key for an already encrypted model.
771 &quot;kmsKeyName&quot;: &quot;A String&quot;, # [Optional] Describes the Cloud KMS encryption key that will be used to protect destination BigQuery table. The BigQuery Service Account associated with your project requires access to this encryption key.
772 },
773 &quot;lastModifiedTime&quot;: &quot;A String&quot;, # Output only. The time when this model was last modified, in millisecs since the epoch.
774 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700775 ],
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800776 &quot;nextPageToken&quot;: &quot;A String&quot;, # A token to request the next page of results.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700777 }</pre>
778</div>
779
780<div class="method">
781 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
782 <pre>Retrieves the next page of results.
783
784Args:
785 previous_request: The request for the previous page. (required)
786 previous_response: The response from the request for the previous page. (required)
787
788Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -0700789 A request object that you can call &#x27;execute()&#x27; on to request the next
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700790 page. Returns None if there are no more items in the collection.
791 </pre>
792</div>
793
794<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700795 <code class="details" id="patch">patch(projectId, datasetId, modelId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700796 <pre>Patch specific fields in the specified model.
797
798Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700799 projectId: string, Required. Project ID of the model to patch. (required)
800 datasetId: string, Required. Dataset ID of the model to patch. (required)
801 modelId: string, Required. Model ID of the model to patch. (required)
802 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700803 The object takes the form of:
804
805{
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800806 &quot;description&quot;: &quot;A String&quot;, # Optional. A user-friendly description of this model.
807 &quot;friendlyName&quot;: &quot;A String&quot;, # Optional. A descriptive name for this model.
808 &quot;trainingRuns&quot;: [ # Output only. Information for all training runs in increasing order of start_time.
809 { # Information about a single training query run for the model.
810 &quot;dataSplitResult&quot;: { # Data split result. This contains references to the training and evaluation data tables that were used to train the model. # Data split result of the training run. Only set when the input data is actually split.
811 &quot;trainingTable&quot;: { # Table reference of the training data after split.
812 &quot;tableId&quot;: &quot;A String&quot;, # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
813 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this table.
814 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this table.
815 },
816 &quot;evaluationTable&quot;: { # Table reference of the evaluation data after split.
817 &quot;tableId&quot;: &quot;A String&quot;, # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
818 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this table.
819 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this table.
820 },
821 },
822 &quot;results&quot;: [ # Output of each iteration run, results.size() &lt;= max_iterations.
823 { # Information about a single iteration of the training run.
824 &quot;trainingLoss&quot;: 3.14, # Loss computed on the training data at the end of iteration.
825 &quot;arimaResult&quot;: { # (Auto-)arima fitting result. Wrap everything in ArimaResult for easier refactoring if we want to use model-specific iteration results.
826 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
827 &quot;A String&quot;,
828 ],
829 &quot;arimaModelInfo&quot;: [ # This message is repeated because there are multiple arima models fitted in auto-arima. For non-auto-arima model, its size is one.
830 { # Arima model information.
831 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # Non-seasonal order.
832 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
833 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
834 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
835 },
836 &quot;timeSeriesId&quot;: &quot;A String&quot;, # The id to indicate different time series.
837 &quot;arimaCoefficients&quot;: { # Arima coefficients. # Arima coefficients.
838 &quot;movingAverageCoefficients&quot;: [ # Moving-average coefficients, an array of double.
839 3.14,
840 ],
841 &quot;interceptCoefficient&quot;: 3.14, # Intercept coefficient, just a double not an array.
842 &quot;autoRegressiveCoefficients&quot;: [ # Auto-regressive coefficients, an array of double.
843 3.14,
844 ],
845 },
846 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
847 &quot;A String&quot;,
848 ],
849 &quot;hasDrift&quot;: True or False, # Whether Arima model fitted with drift or not. It is always false when d is not 1.
850 &quot;arimaFittingMetrics&quot;: { # ARIMA model fitting metrics. # Arima fitting metrics.
851 &quot;variance&quot;: 3.14, # Variance.
852 &quot;aic&quot;: 3.14, # AIC.
853 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
854 },
855 },
856 ],
857 },
858 &quot;index&quot;: 42, # Index of the iteration, 0 based.
859 &quot;durationMs&quot;: &quot;A String&quot;, # Time taken to run the iteration in milliseconds.
860 &quot;clusterInfos&quot;: [ # Information about top clusters for clustering models.
861 { # Information about a single cluster for clustering model.
862 &quot;clusterSize&quot;: &quot;A String&quot;, # Cluster size, the total number of points assigned to the cluster.
863 &quot;clusterRadius&quot;: 3.14, # Cluster radius, the average distance from centroid to each point assigned to the cluster.
864 &quot;centroidId&quot;: &quot;A String&quot;, # Centroid id.
865 },
866 ],
867 &quot;learnRate&quot;: 3.14, # Learn rate used for this iteration.
868 &quot;evalLoss&quot;: 3.14, # Loss computed on the eval data at the end of iteration.
869 },
870 ],
871 &quot;trainingOptions&quot;: { # Options that were used for this training run, includes user specified and default options that were used.
872 &quot;inputLabelColumns&quot;: [ # Name of input label columns in training data.
873 &quot;A String&quot;,
874 ],
875 &quot;dataFrequency&quot;: &quot;A String&quot;, # The data frequency of a time series.
876 &quot;walsAlpha&quot;: 3.14, # Hyperparameter for matrix factoration when implicit feedback type is specified.
877 &quot;userColumn&quot;: &quot;A String&quot;, # User column specified for matrix factorization models.
878 &quot;autoArimaMaxOrder&quot;: &quot;A String&quot;, # The max value of non-seasonal p and q.
879 &quot;batchSize&quot;: &quot;A String&quot;, # Batch size for dnn models.
880 &quot;minSplitLoss&quot;: 3.14, # Minimum split loss for boosted tree models.
881 &quot;dataSplitEvalFraction&quot;: 3.14, # The fraction of evaluation data over the whole input data. The rest of data will be used as training data. The format should be double. Accurate to two decimal places. Default value is 0.2.
882 &quot;modelUri&quot;: &quot;A String&quot;, # [Beta] Google Cloud Storage URI from which the model was imported. Only applicable for imported models.
883 &quot;kmeansInitializationMethod&quot;: &quot;A String&quot;, # The method used to initialize the centroids for kmeans algorithm.
884 &quot;subsample&quot;: 3.14, # Subsample fraction of the training data to grow tree to prevent overfitting for boosted tree models.
885 &quot;l2Regularization&quot;: 3.14, # L2 regularization coefficient.
886 &quot;hiddenUnits&quot;: [ # Hidden units for dnn models.
887 &quot;A String&quot;,
888 ],
889 &quot;initialLearnRate&quot;: 3.14, # Specifies the initial learning rate for the line search learn rate strategy.
890 &quot;maxIterations&quot;: &quot;A String&quot;, # The maximum number of iterations in training. Used only for iterative training algorithms.
891 &quot;feedbackType&quot;: &quot;A String&quot;, # Feedback type that specifies which algorithm to run for matrix factorization.
892 &quot;preserveInputStructs&quot;: True or False, # Whether to preserve the input structs in output feature names. Suppose there is a struct A with field b. When false (default), the output feature name is A_b. When true, the output feature name is A.b.
893 &quot;dataSplitMethod&quot;: &quot;A String&quot;, # The data split type for training and evaluation, e.g. RANDOM.
894 &quot;includeDrift&quot;: True or False, # Include drift when fitting an ARIMA model.
895 &quot;numFactors&quot;: &quot;A String&quot;, # Num factors specified for matrix factorization models.
896 &quot;maxTreeDepth&quot;: &quot;A String&quot;, # Maximum depth of a tree for boosted tree models.
897 &quot;numClusters&quot;: &quot;A String&quot;, # Number of clusters for clustering models.
898 &quot;dataSplitColumn&quot;: &quot;A String&quot;, # The column to split data with. This column won&#x27;t be used as a feature. 1. When data_split_method is CUSTOM, the corresponding column should be boolean. The rows with true value tag are eval data, and the false are training data. 2. When data_split_method is SEQ, the first DATA_SPLIT_EVAL_FRACTION rows (from smallest to largest) in the corresponding column are used as training data, and the rest are eval data. It respects the order in Orderable data types: https://cloud.google.com/bigquery/docs/reference/standard-sql/data-types#data-type-properties
899 &quot;timeSeriesIdColumn&quot;: &quot;A String&quot;, # The id column that will be used to indicate different time series to forecast in parallel.
900 &quot;dropout&quot;: 3.14, # Dropout probability for dnn models.
901 &quot;itemColumn&quot;: &quot;A String&quot;, # Item column specified for matrix factorization models.
902 &quot;timeSeriesTimestampColumn&quot;: &quot;A String&quot;, # Column to be designated as time series timestamp for ARIMA model.
903 &quot;minRelativeProgress&quot;: 3.14, # When early_stop is true, stops training when accuracy improvement is less than &#x27;min_relative_progress&#x27;. Used only for iterative training algorithms.
904 &quot;autoArima&quot;: True or False, # Whether to enable auto ARIMA or not.
905 &quot;learnRate&quot;: 3.14, # Learning rate in training. Used only for iterative training algorithms.
906 &quot;warmStart&quot;: True or False, # Whether to train a model from the last checkpoint.
907 &quot;holidayRegion&quot;: &quot;A String&quot;, # The geographical region based on which the holidays are considered in time series modeling. If a valid value is specified, then holiday effects modeling is enabled.
908 &quot;lossType&quot;: &quot;A String&quot;, # Type of loss function used during training run.
909 &quot;distanceType&quot;: &quot;A String&quot;, # Distance type for clustering models.
910 &quot;earlyStop&quot;: True or False, # Whether to stop early when the loss doesn&#x27;t improve significantly any more (compared to min_relative_progress). Used only for iterative training algorithms.
911 &quot;learnRateStrategy&quot;: &quot;A String&quot;, # The strategy to determine learn rate for the current iteration.
912 &quot;kmeansInitializationColumn&quot;: &quot;A String&quot;, # The column used to provide the initial centroids for kmeans algorithm when kmeans_initialization_method is CUSTOM.
913 &quot;l1Regularization&quot;: 3.14, # L1 regularization coefficient.
914 &quot;timeSeriesDataColumn&quot;: &quot;A String&quot;, # Column to be designated as time series data for ARIMA model.
915 &quot;horizon&quot;: &quot;A String&quot;, # The number of periods ahead that need to be forecasted.
916 &quot;labelClassWeights&quot;: { # Weights associated with each label class, for rebalancing the training data. Only applicable for classification models.
917 &quot;a_key&quot;: 3.14,
918 },
919 &quot;optimizationStrategy&quot;: &quot;A String&quot;, # Optimization strategy for training linear regression models.
920 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # A specification of the non-seasonal part of the ARIMA model: the three components (p, d, q) are the AR order, the degree of differencing, and the MA order.
921 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
922 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
923 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
924 },
925 },
926 &quot;evaluationMetrics&quot;: { # Evaluation metrics of a model. These are either computed on all training data or just the eval data based on whether eval data was used during training. These are not present for imported models. # The evaluation metrics over training/eval data that were computed at the end of training.
927 &quot;rankingMetrics&quot;: { # Evaluation metrics used by weighted-ALS models specified by feedback_type=implicit. # Populated for implicit feedback type matrix factorization models.
928 &quot;averageRank&quot;: 3.14, # Determines the goodness of a ranking by computing the percentile rank from the predicted confidence and dividing it by the original rank.
929 &quot;meanSquaredError&quot;: 3.14, # Similar to the mean squared error computed in regression and explicit recommendation models except instead of computing the rating directly, the output from evaluate is computed against a preference which is 1 or 0 depending on if the rating exists or not.
930 &quot;meanAveragePrecision&quot;: 3.14, # Calculates a precision per user for all the items by ranking them and then averages all the precisions across all the users.
931 &quot;normalizedDiscountedCumulativeGain&quot;: 3.14, # A metric to determine the goodness of a ranking calculated from the predicted confidence by comparing it to an ideal rank measured by the original ratings.
932 },
933 &quot;binaryClassificationMetrics&quot;: { # Evaluation metrics for binary classification/classifier models. # Populated for binary classification/classifier models.
934 &quot;aggregateClassificationMetrics&quot;: { # Aggregate metrics for classification/classifier models. For multi-class models, the metrics are either macro-averaged or micro-averaged. When macro-averaged, the metrics are calculated for each label and then an unweighted average is taken of those values. When micro-averaged, the metric is calculated globally by counting the total number of correctly predicted rows. # Aggregate classification metrics.
935 &quot;rocAuc&quot;: 3.14, # Area Under a ROC Curve. For multiclass this is a macro-averaged metric.
936 &quot;threshold&quot;: 3.14, # Threshold at which the metrics are computed. For binary classification models this is the positive class threshold. For multi-class classfication models this is the confidence threshold.
937 &quot;precision&quot;: 3.14, # Precision is the fraction of actual positive predictions that had positive actual labels. For multiclass this is a macro-averaged metric treating each class as a binary classifier.
938 &quot;accuracy&quot;: 3.14, # Accuracy is the fraction of predictions given the correct label. For multiclass this is a micro-averaged metric.
939 &quot;logLoss&quot;: 3.14, # Logarithmic Loss. For multiclass this is a macro-averaged metric.
940 &quot;f1Score&quot;: 3.14, # The F1 score is an average of recall and precision. For multiclass this is a macro-averaged metric.
941 &quot;recall&quot;: 3.14, # Recall is the fraction of actual positive labels that were given a positive prediction. For multiclass this is a macro-averaged metric.
942 },
943 &quot;positiveLabel&quot;: &quot;A String&quot;, # Label representing the positive class.
944 &quot;negativeLabel&quot;: &quot;A String&quot;, # Label representing the negative class.
945 &quot;binaryConfusionMatrixList&quot;: [ # Binary confusion matrix at multiple thresholds.
946 { # Confusion matrix for binary classification models.
947 &quot;positiveClassThreshold&quot;: 3.14, # Threshold value used when computing each of the following metric.
948 &quot;recall&quot;: 3.14, # The fraction of actual positive labels that were given a positive prediction.
949 &quot;precision&quot;: 3.14, # The fraction of actual positive predictions that had positive actual labels.
950 &quot;f1Score&quot;: 3.14, # The equally weighted average of recall and precision.
951 &quot;falseNegatives&quot;: &quot;A String&quot;, # Number of false samples predicted as false.
952 &quot;accuracy&quot;: 3.14, # The fraction of predictions given the correct label.
953 &quot;truePositives&quot;: &quot;A String&quot;, # Number of true samples predicted as true.
954 &quot;falsePositives&quot;: &quot;A String&quot;, # Number of false samples predicted as true.
955 &quot;trueNegatives&quot;: &quot;A String&quot;, # Number of true samples predicted as false.
956 },
957 ],
958 },
959 &quot;multiClassClassificationMetrics&quot;: { # Evaluation metrics for multi-class classification/classifier models. # Populated for multi-class classification/classifier models.
960 &quot;confusionMatrixList&quot;: [ # Confusion matrix at different thresholds.
961 { # Confusion matrix for multi-class classification models.
962 &quot;rows&quot;: [ # One row per actual label.
963 { # A single row in the confusion matrix.
964 &quot;entries&quot;: [ # Info describing predicted label distribution.
965 { # A single entry in the confusion matrix.
966 &quot;predictedLabel&quot;: &quot;A String&quot;, # The predicted label. For confidence_threshold &gt; 0, we will also add an entry indicating the number of items under the confidence threshold.
967 &quot;itemCount&quot;: &quot;A String&quot;, # Number of items being predicted as this label.
968 },
969 ],
970 &quot;actualLabel&quot;: &quot;A String&quot;, # The original label of this row.
971 },
972 ],
973 &quot;confidenceThreshold&quot;: 3.14, # Confidence threshold used when computing the entries of the confusion matrix.
974 },
975 ],
976 &quot;aggregateClassificationMetrics&quot;: { # Aggregate metrics for classification/classifier models. For multi-class models, the metrics are either macro-averaged or micro-averaged. When macro-averaged, the metrics are calculated for each label and then an unweighted average is taken of those values. When micro-averaged, the metric is calculated globally by counting the total number of correctly predicted rows. # Aggregate classification metrics.
977 &quot;rocAuc&quot;: 3.14, # Area Under a ROC Curve. For multiclass this is a macro-averaged metric.
978 &quot;threshold&quot;: 3.14, # Threshold at which the metrics are computed. For binary classification models this is the positive class threshold. For multi-class classfication models this is the confidence threshold.
979 &quot;precision&quot;: 3.14, # Precision is the fraction of actual positive predictions that had positive actual labels. For multiclass this is a macro-averaged metric treating each class as a binary classifier.
980 &quot;accuracy&quot;: 3.14, # Accuracy is the fraction of predictions given the correct label. For multiclass this is a micro-averaged metric.
981 &quot;logLoss&quot;: 3.14, # Logarithmic Loss. For multiclass this is a macro-averaged metric.
982 &quot;f1Score&quot;: 3.14, # The F1 score is an average of recall and precision. For multiclass this is a macro-averaged metric.
983 &quot;recall&quot;: 3.14, # Recall is the fraction of actual positive labels that were given a positive prediction. For multiclass this is a macro-averaged metric.
984 },
985 },
986 &quot;arimaForecastingMetrics&quot;: { # Model evaluation metrics for ARIMA forecasting models. # Populated for ARIMA models.
987 &quot;timeSeriesId&quot;: [ # Id to differentiate different time series for the large-scale case.
988 &quot;A String&quot;,
989 ],
990 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
991 &quot;A String&quot;,
992 ],
993 &quot;nonSeasonalOrder&quot;: [ # Non-seasonal order.
994 { # Arima order, can be used for both non-seasonal and seasonal parts.
995 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
996 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
997 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
998 },
999 ],
1000 &quot;arimaSingleModelForecastingMetrics&quot;: [ # Repeated as there can be many metric sets (one for each model) in auto-arima and the large-scale case.
1001 { # Model evaluation metrics for a single ARIMA forecasting model.
1002 &quot;hasDrift&quot;: True or False, # Is arima model fitted with drift or not. It is always false when d is not 1.
1003 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
1004 &quot;A String&quot;,
1005 ],
1006 &quot;timeSeriesId&quot;: &quot;A String&quot;, # The id to indicate different time series.
1007 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # Non-seasonal order.
1008 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
1009 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
1010 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
1011 },
1012 &quot;arimaFittingMetrics&quot;: { # ARIMA model fitting metrics. # Arima fitting metrics.
1013 &quot;variance&quot;: 3.14, # Variance.
1014 &quot;aic&quot;: 3.14, # AIC.
1015 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
1016 },
1017 },
1018 ],
1019 &quot;arimaFittingMetrics&quot;: [ # Arima model fitting metrics.
1020 { # ARIMA model fitting metrics.
1021 &quot;variance&quot;: 3.14, # Variance.
1022 &quot;aic&quot;: 3.14, # AIC.
1023 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
1024 },
1025 ],
1026 &quot;hasDrift&quot;: [ # Whether Arima model fitted with drift or not. It is always false when d is not 1.
1027 True or False,
1028 ],
1029 },
1030 &quot;clusteringMetrics&quot;: { # Evaluation metrics for clustering models. # Populated for clustering models.
1031 &quot;clusters&quot;: [ # [Beta] Information for all clusters.
1032 { # Message containing the information about one cluster.
1033 &quot;featureValues&quot;: [ # Values of highly variant features for this cluster.
1034 { # Representative value of a single feature within the cluster.
1035 &quot;categoricalValue&quot;: { # Representative value of a categorical feature. # The categorical feature value.
1036 &quot;categoryCounts&quot;: [ # Counts of all categories for the categorical feature. If there are more than ten categories, we return top ten (by count) and return one more CategoryCount with category &quot;_OTHER_&quot; and count as aggregate counts of remaining categories.
1037 { # Represents the count of a single category within the cluster.
1038 &quot;count&quot;: &quot;A String&quot;, # The count of training samples matching the category within the cluster.
1039 &quot;category&quot;: &quot;A String&quot;, # The name of category.
1040 },
1041 ],
1042 },
1043 &quot;numericalValue&quot;: 3.14, # The numerical feature value. This is the centroid value for this feature.
1044 &quot;featureColumn&quot;: &quot;A String&quot;, # The feature column name.
1045 },
1046 ],
1047 &quot;count&quot;: &quot;A String&quot;, # Count of training data rows that were assigned to this cluster.
1048 &quot;centroidId&quot;: &quot;A String&quot;, # Centroid id.
1049 },
1050 ],
1051 &quot;daviesBouldinIndex&quot;: 3.14, # Davies-Bouldin index.
1052 &quot;meanSquaredDistance&quot;: 3.14, # Mean of squared distances between each sample to its cluster centroid.
1053 },
1054 &quot;regressionMetrics&quot;: { # Evaluation metrics for regression and explicit feedback type matrix factorization models. # Populated for regression models and explicit feedback type matrix factorization models.
1055 &quot;medianAbsoluteError&quot;: 3.14, # Median absolute error.
1056 &quot;rSquared&quot;: 3.14, # R^2 score.
1057 &quot;meanAbsoluteError&quot;: 3.14, # Mean absolute error.
1058 &quot;meanSquaredError&quot;: 3.14, # Mean squared error.
1059 &quot;meanSquaredLogError&quot;: 3.14, # Mean squared log error.
1060 },
1061 },
1062 &quot;globalExplanations&quot;: [ # Global explanations for important features of the model. For multi-class models, there is one entry for each label class. For other models, there is only one entry in the list.
1063 { # Global explanations containing the top most important features after training.
1064 &quot;classLabel&quot;: &quot;A String&quot;, # Class label for this set of global explanations. Will be empty/null for binary logistic and linear regression models. Sorted alphabetically in descending order.
1065 &quot;explanations&quot;: [ # A list of the top global explanations. Sorted by absolute value of attribution in descending order.
1066 { # Explanation for a single feature.
1067 &quot;attribution&quot;: 3.14, # Attribution of feature.
1068 &quot;featureName&quot;: &quot;A String&quot;, # Full name of the feature. For non-numerical features, will be formatted like .. Overall size of feature name will always be truncated to first 120 characters.
1069 },
1070 ],
1071 },
1072 ],
1073 &quot;startTime&quot;: &quot;A String&quot;, # The start time of this training run.
1074 },
1075 ],
1076 &quot;creationTime&quot;: &quot;A String&quot;, # Output only. The time when this model was created, in millisecs since the epoch.
1077 &quot;labels&quot;: { # The labels associated with this model. You can use these to organize and group your models. Label keys and values can be no longer than 63 characters, can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. Label values are optional. Label keys must start with a letter and each label in the list must have a different key.
1078 &quot;a_key&quot;: &quot;A String&quot;,
1079 },
1080 &quot;location&quot;: &quot;A String&quot;, # Output only. The geographic location where the model resides. This value is inherited from the dataset.
1081 &quot;expirationTime&quot;: &quot;A String&quot;, # Optional. The time when this model expires, in milliseconds since the epoch. If not present, the model will persist indefinitely. Expired models will be deleted and their storage reclaimed. The defaultTableExpirationMs property of the encapsulating dataset can be used to set a default expirationTime on newly created models.
1082 &quot;modelType&quot;: &quot;A String&quot;, # Output only. Type of the model resource.
1083 &quot;etag&quot;: &quot;A String&quot;, # Output only. A hash of this resource.
1084 &quot;modelReference&quot;: { # Required. Unique identifier for this model.
1085 &quot;modelId&quot;: &quot;A String&quot;, # [Required] The ID of the model. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
1086 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this model.
1087 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this model.
1088 },
1089 &quot;labelColumns&quot;: [ # Output only. Label columns that were used to train this model. The output of the model will have a &quot;predicted_&quot; prefix to these columns.
1090 { # A field or a column.
1091 &quot;type&quot;: { # The type of a variable, e.g., a function argument. Examples: INT64: {type_kind=&quot;INT64&quot;} ARRAY: {type_kind=&quot;ARRAY&quot;, array_element_type=&quot;STRING&quot;} STRUCT&gt;: {type_kind=&quot;STRUCT&quot;, struct_type={fields=[ {name=&quot;x&quot;, type={type_kind=&quot;STRING&quot;}}, {name=&quot;y&quot;, type={type_kind=&quot;ARRAY&quot;, array_element_type=&quot;DATE&quot;}} ]}} # Optional. The type of this parameter. Absent if not explicitly specified (e.g., CREATE FUNCTION statement can omit the return type; in this case the output parameter does not have this &quot;type&quot; field).
1092 &quot;arrayElementType&quot;: # Object with schema name: StandardSqlDataType # The type of the array&#x27;s elements, if type_kind = &quot;ARRAY&quot;.
1093 &quot;structType&quot;: { # The fields of this struct, in order, if type_kind = &quot;STRUCT&quot;.
1094 &quot;fields&quot;: [
1095 # Object with schema name: StandardSqlField
1096 ],
1097 },
1098 &quot;typeKind&quot;: &quot;A String&quot;, # Required. The top level type of this field. Can be any standard SQL data type (e.g., &quot;INT64&quot;, &quot;DATE&quot;, &quot;ARRAY&quot;).
1099 },
1100 &quot;name&quot;: &quot;A String&quot;, # Optional. The name of this field. Can be absent for struct fields.
1101 },
1102 ],
1103 &quot;featureColumns&quot;: [ # Output only. Input feature columns that were used to train this model.
1104 { # A field or a column.
1105 &quot;type&quot;: { # The type of a variable, e.g., a function argument. Examples: INT64: {type_kind=&quot;INT64&quot;} ARRAY: {type_kind=&quot;ARRAY&quot;, array_element_type=&quot;STRING&quot;} STRUCT&gt;: {type_kind=&quot;STRUCT&quot;, struct_type={fields=[ {name=&quot;x&quot;, type={type_kind=&quot;STRING&quot;}}, {name=&quot;y&quot;, type={type_kind=&quot;ARRAY&quot;, array_element_type=&quot;DATE&quot;}} ]}} # Optional. The type of this parameter. Absent if not explicitly specified (e.g., CREATE FUNCTION statement can omit the return type; in this case the output parameter does not have this &quot;type&quot; field).
1106 &quot;arrayElementType&quot;: # Object with schema name: StandardSqlDataType # The type of the array&#x27;s elements, if type_kind = &quot;ARRAY&quot;.
1107 &quot;structType&quot;: { # The fields of this struct, in order, if type_kind = &quot;STRUCT&quot;.
1108 &quot;fields&quot;: [
1109 # Object with schema name: StandardSqlField
1110 ],
1111 },
1112 &quot;typeKind&quot;: &quot;A String&quot;, # Required. The top level type of this field. Can be any standard SQL data type (e.g., &quot;INT64&quot;, &quot;DATE&quot;, &quot;ARRAY&quot;).
1113 },
1114 &quot;name&quot;: &quot;A String&quot;, # Optional. The name of this field. Can be absent for struct fields.
1115 },
1116 ],
1117 &quot;encryptionConfiguration&quot;: { # Custom encryption configuration (e.g., Cloud KMS keys). This shows the encryption configuration of the model data while stored in BigQuery storage. This field can be used with PatchModel to update encryption key for an already encrypted model.
1118 &quot;kmsKeyName&quot;: &quot;A String&quot;, # [Optional] Describes the Cloud KMS encryption key that will be used to protect destination BigQuery table. The BigQuery Service Account associated with your project requires access to this encryption key.
1119 },
1120 &quot;lastModifiedTime&quot;: &quot;A String&quot;, # Output only. The time when this model was last modified, in millisecs since the epoch.
1121}
1122
1123
1124Returns:
1125 An object of the form:
1126
1127 {
1128 &quot;description&quot;: &quot;A String&quot;, # Optional. A user-friendly description of this model.
1129 &quot;friendlyName&quot;: &quot;A String&quot;, # Optional. A descriptive name for this model.
1130 &quot;trainingRuns&quot;: [ # Output only. Information for all training runs in increasing order of start_time.
1131 { # Information about a single training query run for the model.
1132 &quot;dataSplitResult&quot;: { # Data split result. This contains references to the training and evaluation data tables that were used to train the model. # Data split result of the training run. Only set when the input data is actually split.
1133 &quot;trainingTable&quot;: { # Table reference of the training data after split.
1134 &quot;tableId&quot;: &quot;A String&quot;, # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
1135 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this table.
1136 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this table.
1137 },
1138 &quot;evaluationTable&quot;: { # Table reference of the evaluation data after split.
1139 &quot;tableId&quot;: &quot;A String&quot;, # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
1140 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this table.
1141 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this table.
1142 },
1143 },
1144 &quot;results&quot;: [ # Output of each iteration run, results.size() &lt;= max_iterations.
1145 { # Information about a single iteration of the training run.
1146 &quot;trainingLoss&quot;: 3.14, # Loss computed on the training data at the end of iteration.
1147 &quot;arimaResult&quot;: { # (Auto-)arima fitting result. Wrap everything in ArimaResult for easier refactoring if we want to use model-specific iteration results.
1148 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
1149 &quot;A String&quot;,
1150 ],
1151 &quot;arimaModelInfo&quot;: [ # This message is repeated because there are multiple arima models fitted in auto-arima. For non-auto-arima model, its size is one.
1152 { # Arima model information.
1153 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # Non-seasonal order.
1154 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
1155 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
1156 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
1157 },
1158 &quot;timeSeriesId&quot;: &quot;A String&quot;, # The id to indicate different time series.
1159 &quot;arimaCoefficients&quot;: { # Arima coefficients. # Arima coefficients.
1160 &quot;movingAverageCoefficients&quot;: [ # Moving-average coefficients, an array of double.
1161 3.14,
1162 ],
1163 &quot;interceptCoefficient&quot;: 3.14, # Intercept coefficient, just a double not an array.
1164 &quot;autoRegressiveCoefficients&quot;: [ # Auto-regressive coefficients, an array of double.
1165 3.14,
1166 ],
1167 },
1168 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
1169 &quot;A String&quot;,
1170 ],
1171 &quot;hasDrift&quot;: True or False, # Whether Arima model fitted with drift or not. It is always false when d is not 1.
1172 &quot;arimaFittingMetrics&quot;: { # ARIMA model fitting metrics. # Arima fitting metrics.
1173 &quot;variance&quot;: 3.14, # Variance.
1174 &quot;aic&quot;: 3.14, # AIC.
1175 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
1176 },
1177 },
1178 ],
1179 },
1180 &quot;index&quot;: 42, # Index of the iteration, 0 based.
1181 &quot;durationMs&quot;: &quot;A String&quot;, # Time taken to run the iteration in milliseconds.
1182 &quot;clusterInfos&quot;: [ # Information about top clusters for clustering models.
1183 { # Information about a single cluster for clustering model.
1184 &quot;clusterSize&quot;: &quot;A String&quot;, # Cluster size, the total number of points assigned to the cluster.
1185 &quot;clusterRadius&quot;: 3.14, # Cluster radius, the average distance from centroid to each point assigned to the cluster.
1186 &quot;centroidId&quot;: &quot;A String&quot;, # Centroid id.
1187 },
1188 ],
1189 &quot;learnRate&quot;: 3.14, # Learn rate used for this iteration.
1190 &quot;evalLoss&quot;: 3.14, # Loss computed on the eval data at the end of iteration.
1191 },
1192 ],
1193 &quot;trainingOptions&quot;: { # Options that were used for this training run, includes user specified and default options that were used.
1194 &quot;inputLabelColumns&quot;: [ # Name of input label columns in training data.
1195 &quot;A String&quot;,
1196 ],
1197 &quot;dataFrequency&quot;: &quot;A String&quot;, # The data frequency of a time series.
1198 &quot;walsAlpha&quot;: 3.14, # Hyperparameter for matrix factoration when implicit feedback type is specified.
1199 &quot;userColumn&quot;: &quot;A String&quot;, # User column specified for matrix factorization models.
1200 &quot;autoArimaMaxOrder&quot;: &quot;A String&quot;, # The max value of non-seasonal p and q.
1201 &quot;batchSize&quot;: &quot;A String&quot;, # Batch size for dnn models.
1202 &quot;minSplitLoss&quot;: 3.14, # Minimum split loss for boosted tree models.
1203 &quot;dataSplitEvalFraction&quot;: 3.14, # The fraction of evaluation data over the whole input data. The rest of data will be used as training data. The format should be double. Accurate to two decimal places. Default value is 0.2.
1204 &quot;modelUri&quot;: &quot;A String&quot;, # [Beta] Google Cloud Storage URI from which the model was imported. Only applicable for imported models.
1205 &quot;kmeansInitializationMethod&quot;: &quot;A String&quot;, # The method used to initialize the centroids for kmeans algorithm.
1206 &quot;subsample&quot;: 3.14, # Subsample fraction of the training data to grow tree to prevent overfitting for boosted tree models.
1207 &quot;l2Regularization&quot;: 3.14, # L2 regularization coefficient.
1208 &quot;hiddenUnits&quot;: [ # Hidden units for dnn models.
1209 &quot;A String&quot;,
1210 ],
1211 &quot;initialLearnRate&quot;: 3.14, # Specifies the initial learning rate for the line search learn rate strategy.
1212 &quot;maxIterations&quot;: &quot;A String&quot;, # The maximum number of iterations in training. Used only for iterative training algorithms.
1213 &quot;feedbackType&quot;: &quot;A String&quot;, # Feedback type that specifies which algorithm to run for matrix factorization.
1214 &quot;preserveInputStructs&quot;: True or False, # Whether to preserve the input structs in output feature names. Suppose there is a struct A with field b. When false (default), the output feature name is A_b. When true, the output feature name is A.b.
1215 &quot;dataSplitMethod&quot;: &quot;A String&quot;, # The data split type for training and evaluation, e.g. RANDOM.
1216 &quot;includeDrift&quot;: True or False, # Include drift when fitting an ARIMA model.
1217 &quot;numFactors&quot;: &quot;A String&quot;, # Num factors specified for matrix factorization models.
1218 &quot;maxTreeDepth&quot;: &quot;A String&quot;, # Maximum depth of a tree for boosted tree models.
1219 &quot;numClusters&quot;: &quot;A String&quot;, # Number of clusters for clustering models.
1220 &quot;dataSplitColumn&quot;: &quot;A String&quot;, # The column to split data with. This column won&#x27;t be used as a feature. 1. When data_split_method is CUSTOM, the corresponding column should be boolean. The rows with true value tag are eval data, and the false are training data. 2. When data_split_method is SEQ, the first DATA_SPLIT_EVAL_FRACTION rows (from smallest to largest) in the corresponding column are used as training data, and the rest are eval data. It respects the order in Orderable data types: https://cloud.google.com/bigquery/docs/reference/standard-sql/data-types#data-type-properties
1221 &quot;timeSeriesIdColumn&quot;: &quot;A String&quot;, # The id column that will be used to indicate different time series to forecast in parallel.
1222 &quot;dropout&quot;: 3.14, # Dropout probability for dnn models.
1223 &quot;itemColumn&quot;: &quot;A String&quot;, # Item column specified for matrix factorization models.
1224 &quot;timeSeriesTimestampColumn&quot;: &quot;A String&quot;, # Column to be designated as time series timestamp for ARIMA model.
1225 &quot;minRelativeProgress&quot;: 3.14, # When early_stop is true, stops training when accuracy improvement is less than &#x27;min_relative_progress&#x27;. Used only for iterative training algorithms.
1226 &quot;autoArima&quot;: True or False, # Whether to enable auto ARIMA or not.
1227 &quot;learnRate&quot;: 3.14, # Learning rate in training. Used only for iterative training algorithms.
1228 &quot;warmStart&quot;: True or False, # Whether to train a model from the last checkpoint.
1229 &quot;holidayRegion&quot;: &quot;A String&quot;, # The geographical region based on which the holidays are considered in time series modeling. If a valid value is specified, then holiday effects modeling is enabled.
1230 &quot;lossType&quot;: &quot;A String&quot;, # Type of loss function used during training run.
1231 &quot;distanceType&quot;: &quot;A String&quot;, # Distance type for clustering models.
1232 &quot;earlyStop&quot;: True or False, # Whether to stop early when the loss doesn&#x27;t improve significantly any more (compared to min_relative_progress). Used only for iterative training algorithms.
1233 &quot;learnRateStrategy&quot;: &quot;A String&quot;, # The strategy to determine learn rate for the current iteration.
1234 &quot;kmeansInitializationColumn&quot;: &quot;A String&quot;, # The column used to provide the initial centroids for kmeans algorithm when kmeans_initialization_method is CUSTOM.
1235 &quot;l1Regularization&quot;: 3.14, # L1 regularization coefficient.
1236 &quot;timeSeriesDataColumn&quot;: &quot;A String&quot;, # Column to be designated as time series data for ARIMA model.
1237 &quot;horizon&quot;: &quot;A String&quot;, # The number of periods ahead that need to be forecasted.
1238 &quot;labelClassWeights&quot;: { # Weights associated with each label class, for rebalancing the training data. Only applicable for classification models.
1239 &quot;a_key&quot;: 3.14,
1240 },
1241 &quot;optimizationStrategy&quot;: &quot;A String&quot;, # Optimization strategy for training linear regression models.
1242 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # A specification of the non-seasonal part of the ARIMA model: the three components (p, d, q) are the AR order, the degree of differencing, and the MA order.
1243 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
1244 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
1245 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
1246 },
1247 },
1248 &quot;evaluationMetrics&quot;: { # Evaluation metrics of a model. These are either computed on all training data or just the eval data based on whether eval data was used during training. These are not present for imported models. # The evaluation metrics over training/eval data that were computed at the end of training.
1249 &quot;rankingMetrics&quot;: { # Evaluation metrics used by weighted-ALS models specified by feedback_type=implicit. # Populated for implicit feedback type matrix factorization models.
1250 &quot;averageRank&quot;: 3.14, # Determines the goodness of a ranking by computing the percentile rank from the predicted confidence and dividing it by the original rank.
1251 &quot;meanSquaredError&quot;: 3.14, # Similar to the mean squared error computed in regression and explicit recommendation models except instead of computing the rating directly, the output from evaluate is computed against a preference which is 1 or 0 depending on if the rating exists or not.
1252 &quot;meanAveragePrecision&quot;: 3.14, # Calculates a precision per user for all the items by ranking them and then averages all the precisions across all the users.
1253 &quot;normalizedDiscountedCumulativeGain&quot;: 3.14, # A metric to determine the goodness of a ranking calculated from the predicted confidence by comparing it to an ideal rank measured by the original ratings.
1254 },
1255 &quot;binaryClassificationMetrics&quot;: { # Evaluation metrics for binary classification/classifier models. # Populated for binary classification/classifier models.
1256 &quot;aggregateClassificationMetrics&quot;: { # Aggregate metrics for classification/classifier models. For multi-class models, the metrics are either macro-averaged or micro-averaged. When macro-averaged, the metrics are calculated for each label and then an unweighted average is taken of those values. When micro-averaged, the metric is calculated globally by counting the total number of correctly predicted rows. # Aggregate classification metrics.
1257 &quot;rocAuc&quot;: 3.14, # Area Under a ROC Curve. For multiclass this is a macro-averaged metric.
1258 &quot;threshold&quot;: 3.14, # Threshold at which the metrics are computed. For binary classification models this is the positive class threshold. For multi-class classfication models this is the confidence threshold.
1259 &quot;precision&quot;: 3.14, # Precision is the fraction of actual positive predictions that had positive actual labels. For multiclass this is a macro-averaged metric treating each class as a binary classifier.
1260 &quot;accuracy&quot;: 3.14, # Accuracy is the fraction of predictions given the correct label. For multiclass this is a micro-averaged metric.
1261 &quot;logLoss&quot;: 3.14, # Logarithmic Loss. For multiclass this is a macro-averaged metric.
1262 &quot;f1Score&quot;: 3.14, # The F1 score is an average of recall and precision. For multiclass this is a macro-averaged metric.
1263 &quot;recall&quot;: 3.14, # Recall is the fraction of actual positive labels that were given a positive prediction. For multiclass this is a macro-averaged metric.
1264 },
1265 &quot;positiveLabel&quot;: &quot;A String&quot;, # Label representing the positive class.
1266 &quot;negativeLabel&quot;: &quot;A String&quot;, # Label representing the negative class.
1267 &quot;binaryConfusionMatrixList&quot;: [ # Binary confusion matrix at multiple thresholds.
1268 { # Confusion matrix for binary classification models.
1269 &quot;positiveClassThreshold&quot;: 3.14, # Threshold value used when computing each of the following metric.
1270 &quot;recall&quot;: 3.14, # The fraction of actual positive labels that were given a positive prediction.
1271 &quot;precision&quot;: 3.14, # The fraction of actual positive predictions that had positive actual labels.
1272 &quot;f1Score&quot;: 3.14, # The equally weighted average of recall and precision.
1273 &quot;falseNegatives&quot;: &quot;A String&quot;, # Number of false samples predicted as false.
1274 &quot;accuracy&quot;: 3.14, # The fraction of predictions given the correct label.
1275 &quot;truePositives&quot;: &quot;A String&quot;, # Number of true samples predicted as true.
1276 &quot;falsePositives&quot;: &quot;A String&quot;, # Number of false samples predicted as true.
1277 &quot;trueNegatives&quot;: &quot;A String&quot;, # Number of true samples predicted as false.
1278 },
1279 ],
1280 },
1281 &quot;multiClassClassificationMetrics&quot;: { # Evaluation metrics for multi-class classification/classifier models. # Populated for multi-class classification/classifier models.
1282 &quot;confusionMatrixList&quot;: [ # Confusion matrix at different thresholds.
1283 { # Confusion matrix for multi-class classification models.
1284 &quot;rows&quot;: [ # One row per actual label.
1285 { # A single row in the confusion matrix.
1286 &quot;entries&quot;: [ # Info describing predicted label distribution.
1287 { # A single entry in the confusion matrix.
1288 &quot;predictedLabel&quot;: &quot;A String&quot;, # The predicted label. For confidence_threshold &gt; 0, we will also add an entry indicating the number of items under the confidence threshold.
1289 &quot;itemCount&quot;: &quot;A String&quot;, # Number of items being predicted as this label.
1290 },
1291 ],
1292 &quot;actualLabel&quot;: &quot;A String&quot;, # The original label of this row.
1293 },
1294 ],
1295 &quot;confidenceThreshold&quot;: 3.14, # Confidence threshold used when computing the entries of the confusion matrix.
1296 },
1297 ],
1298 &quot;aggregateClassificationMetrics&quot;: { # Aggregate metrics for classification/classifier models. For multi-class models, the metrics are either macro-averaged or micro-averaged. When macro-averaged, the metrics are calculated for each label and then an unweighted average is taken of those values. When micro-averaged, the metric is calculated globally by counting the total number of correctly predicted rows. # Aggregate classification metrics.
1299 &quot;rocAuc&quot;: 3.14, # Area Under a ROC Curve. For multiclass this is a macro-averaged metric.
1300 &quot;threshold&quot;: 3.14, # Threshold at which the metrics are computed. For binary classification models this is the positive class threshold. For multi-class classfication models this is the confidence threshold.
1301 &quot;precision&quot;: 3.14, # Precision is the fraction of actual positive predictions that had positive actual labels. For multiclass this is a macro-averaged metric treating each class as a binary classifier.
1302 &quot;accuracy&quot;: 3.14, # Accuracy is the fraction of predictions given the correct label. For multiclass this is a micro-averaged metric.
1303 &quot;logLoss&quot;: 3.14, # Logarithmic Loss. For multiclass this is a macro-averaged metric.
1304 &quot;f1Score&quot;: 3.14, # The F1 score is an average of recall and precision. For multiclass this is a macro-averaged metric.
1305 &quot;recall&quot;: 3.14, # Recall is the fraction of actual positive labels that were given a positive prediction. For multiclass this is a macro-averaged metric.
1306 },
1307 },
1308 &quot;arimaForecastingMetrics&quot;: { # Model evaluation metrics for ARIMA forecasting models. # Populated for ARIMA models.
1309 &quot;timeSeriesId&quot;: [ # Id to differentiate different time series for the large-scale case.
1310 &quot;A String&quot;,
1311 ],
1312 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
1313 &quot;A String&quot;,
1314 ],
1315 &quot;nonSeasonalOrder&quot;: [ # Non-seasonal order.
1316 { # Arima order, can be used for both non-seasonal and seasonal parts.
1317 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
1318 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
1319 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
1320 },
1321 ],
1322 &quot;arimaSingleModelForecastingMetrics&quot;: [ # Repeated as there can be many metric sets (one for each model) in auto-arima and the large-scale case.
1323 { # Model evaluation metrics for a single ARIMA forecasting model.
1324 &quot;hasDrift&quot;: True or False, # Is arima model fitted with drift or not. It is always false when d is not 1.
1325 &quot;seasonalPeriods&quot;: [ # Seasonal periods. Repeated because multiple periods are supported for one time series.
1326 &quot;A String&quot;,
1327 ],
1328 &quot;timeSeriesId&quot;: &quot;A String&quot;, # The id to indicate different time series.
1329 &quot;nonSeasonalOrder&quot;: { # Arima order, can be used for both non-seasonal and seasonal parts. # Non-seasonal order.
1330 &quot;d&quot;: &quot;A String&quot;, # Order of the differencing part.
1331 &quot;q&quot;: &quot;A String&quot;, # Order of the moving-average part.
1332 &quot;p&quot;: &quot;A String&quot;, # Order of the autoregressive part.
1333 },
1334 &quot;arimaFittingMetrics&quot;: { # ARIMA model fitting metrics. # Arima fitting metrics.
1335 &quot;variance&quot;: 3.14, # Variance.
1336 &quot;aic&quot;: 3.14, # AIC.
1337 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
1338 },
1339 },
1340 ],
1341 &quot;arimaFittingMetrics&quot;: [ # Arima model fitting metrics.
1342 { # ARIMA model fitting metrics.
1343 &quot;variance&quot;: 3.14, # Variance.
1344 &quot;aic&quot;: 3.14, # AIC.
1345 &quot;logLikelihood&quot;: 3.14, # Log-likelihood.
1346 },
1347 ],
1348 &quot;hasDrift&quot;: [ # Whether Arima model fitted with drift or not. It is always false when d is not 1.
1349 True or False,
1350 ],
1351 },
1352 &quot;clusteringMetrics&quot;: { # Evaluation metrics for clustering models. # Populated for clustering models.
1353 &quot;clusters&quot;: [ # [Beta] Information for all clusters.
1354 { # Message containing the information about one cluster.
1355 &quot;featureValues&quot;: [ # Values of highly variant features for this cluster.
1356 { # Representative value of a single feature within the cluster.
1357 &quot;categoricalValue&quot;: { # Representative value of a categorical feature. # The categorical feature value.
1358 &quot;categoryCounts&quot;: [ # Counts of all categories for the categorical feature. If there are more than ten categories, we return top ten (by count) and return one more CategoryCount with category &quot;_OTHER_&quot; and count as aggregate counts of remaining categories.
1359 { # Represents the count of a single category within the cluster.
1360 &quot;count&quot;: &quot;A String&quot;, # The count of training samples matching the category within the cluster.
1361 &quot;category&quot;: &quot;A String&quot;, # The name of category.
1362 },
1363 ],
1364 },
1365 &quot;numericalValue&quot;: 3.14, # The numerical feature value. This is the centroid value for this feature.
1366 &quot;featureColumn&quot;: &quot;A String&quot;, # The feature column name.
1367 },
1368 ],
1369 &quot;count&quot;: &quot;A String&quot;, # Count of training data rows that were assigned to this cluster.
1370 &quot;centroidId&quot;: &quot;A String&quot;, # Centroid id.
1371 },
1372 ],
1373 &quot;daviesBouldinIndex&quot;: 3.14, # Davies-Bouldin index.
1374 &quot;meanSquaredDistance&quot;: 3.14, # Mean of squared distances between each sample to its cluster centroid.
1375 },
1376 &quot;regressionMetrics&quot;: { # Evaluation metrics for regression and explicit feedback type matrix factorization models. # Populated for regression models and explicit feedback type matrix factorization models.
1377 &quot;medianAbsoluteError&quot;: 3.14, # Median absolute error.
1378 &quot;rSquared&quot;: 3.14, # R^2 score.
1379 &quot;meanAbsoluteError&quot;: 3.14, # Mean absolute error.
1380 &quot;meanSquaredError&quot;: 3.14, # Mean squared error.
1381 &quot;meanSquaredLogError&quot;: 3.14, # Mean squared log error.
1382 },
1383 },
1384 &quot;globalExplanations&quot;: [ # Global explanations for important features of the model. For multi-class models, there is one entry for each label class. For other models, there is only one entry in the list.
1385 { # Global explanations containing the top most important features after training.
1386 &quot;classLabel&quot;: &quot;A String&quot;, # Class label for this set of global explanations. Will be empty/null for binary logistic and linear regression models. Sorted alphabetically in descending order.
1387 &quot;explanations&quot;: [ # A list of the top global explanations. Sorted by absolute value of attribution in descending order.
1388 { # Explanation for a single feature.
1389 &quot;attribution&quot;: 3.14, # Attribution of feature.
1390 &quot;featureName&quot;: &quot;A String&quot;, # Full name of the feature. For non-numerical features, will be formatted like .. Overall size of feature name will always be truncated to first 120 characters.
1391 },
1392 ],
1393 },
1394 ],
1395 &quot;startTime&quot;: &quot;A String&quot;, # The start time of this training run.
1396 },
1397 ],
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001398 &quot;creationTime&quot;: &quot;A String&quot;, # Output only. The time when this model was created, in millisecs since the epoch.
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -08001399 &quot;labels&quot;: { # The labels associated with this model. You can use these to organize and group your models. Label keys and values can be no longer than 63 characters, can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. Label values are optional. Label keys must start with a letter and each label in the list must have a different key.
1400 &quot;a_key&quot;: &quot;A String&quot;,
1401 },
1402 &quot;location&quot;: &quot;A String&quot;, # Output only. The geographic location where the model resides. This value is inherited from the dataset.
1403 &quot;expirationTime&quot;: &quot;A String&quot;, # Optional. The time when this model expires, in milliseconds since the epoch. If not present, the model will persist indefinitely. Expired models will be deleted and their storage reclaimed. The defaultTableExpirationMs property of the encapsulating dataset can be used to set a default expirationTime on newly created models.
1404 &quot;modelType&quot;: &quot;A String&quot;, # Output only. Type of the model resource.
1405 &quot;etag&quot;: &quot;A String&quot;, # Output only. A hash of this resource.
1406 &quot;modelReference&quot;: { # Required. Unique identifier for this model.
1407 &quot;modelId&quot;: &quot;A String&quot;, # [Required] The ID of the model. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.
1408 &quot;datasetId&quot;: &quot;A String&quot;, # [Required] The ID of the dataset containing this model.
1409 &quot;projectId&quot;: &quot;A String&quot;, # [Required] The ID of the project containing this model.
1410 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001411 &quot;labelColumns&quot;: [ # Output only. Label columns that were used to train this model. The output of the model will have a &quot;predicted_&quot; prefix to these columns.
Bu Sun Kim65020912020-05-20 12:08:20 -07001412 { # A field or a column.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001413 &quot;type&quot;: { # The type of a variable, e.g., a function argument. Examples: INT64: {type_kind=&quot;INT64&quot;} ARRAY: {type_kind=&quot;ARRAY&quot;, array_element_type=&quot;STRING&quot;} STRUCT&gt;: {type_kind=&quot;STRUCT&quot;, struct_type={fields=[ {name=&quot;x&quot;, type={type_kind=&quot;STRING&quot;}}, {name=&quot;y&quot;, type={type_kind=&quot;ARRAY&quot;, array_element_type=&quot;DATE&quot;}} ]}} # Optional. The type of this parameter. Absent if not explicitly specified (e.g., CREATE FUNCTION statement can omit the return type; in this case the output parameter does not have this &quot;type&quot; field).
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001414 &quot;arrayElementType&quot;: # Object with schema name: StandardSqlDataType # The type of the array&#x27;s elements, if type_kind = &quot;ARRAY&quot;.
Bu Sun Kim65020912020-05-20 12:08:20 -07001415 &quot;structType&quot;: { # The fields of this struct, in order, if type_kind = &quot;STRUCT&quot;.
1416 &quot;fields&quot;: [
1417 # Object with schema name: StandardSqlField
1418 ],
1419 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001420 &quot;typeKind&quot;: &quot;A String&quot;, # Required. The top level type of this field. Can be any standard SQL data type (e.g., &quot;INT64&quot;, &quot;DATE&quot;, &quot;ARRAY&quot;).
Bu Sun Kim65020912020-05-20 12:08:20 -07001421 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001422 &quot;name&quot;: &quot;A String&quot;, # Optional. The name of this field. Can be absent for struct fields.
Bu Sun Kim65020912020-05-20 12:08:20 -07001423 },
1424 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001425 &quot;featureColumns&quot;: [ # Output only. Input feature columns that were used to train this model.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001426 { # A field or a column.
1427 &quot;type&quot;: { # The type of a variable, e.g., a function argument. Examples: INT64: {type_kind=&quot;INT64&quot;} ARRAY: {type_kind=&quot;ARRAY&quot;, array_element_type=&quot;STRING&quot;} STRUCT&gt;: {type_kind=&quot;STRUCT&quot;, struct_type={fields=[ {name=&quot;x&quot;, type={type_kind=&quot;STRING&quot;}}, {name=&quot;y&quot;, type={type_kind=&quot;ARRAY&quot;, array_element_type=&quot;DATE&quot;}} ]}} # Optional. The type of this parameter. Absent if not explicitly specified (e.g., CREATE FUNCTION statement can omit the return type; in this case the output parameter does not have this &quot;type&quot; field).
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001428 &quot;arrayElementType&quot;: # Object with schema name: StandardSqlDataType # The type of the array&#x27;s elements, if type_kind = &quot;ARRAY&quot;.
1429 &quot;structType&quot;: { # The fields of this struct, in order, if type_kind = &quot;STRUCT&quot;.
1430 &quot;fields&quot;: [
1431 # Object with schema name: StandardSqlField
1432 ],
1433 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001434 &quot;typeKind&quot;: &quot;A String&quot;, # Required. The top level type of this field. Can be any standard SQL data type (e.g., &quot;INT64&quot;, &quot;DATE&quot;, &quot;ARRAY&quot;).
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001435 },
1436 &quot;name&quot;: &quot;A String&quot;, # Optional. The name of this field. Can be absent for struct fields.
1437 },
1438 ],
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -08001439 &quot;encryptionConfiguration&quot;: { # Custom encryption configuration (e.g., Cloud KMS keys). This shows the encryption configuration of the model data while stored in BigQuery storage. This field can be used with PatchModel to update encryption key for an already encrypted model.
1440 &quot;kmsKeyName&quot;: &quot;A String&quot;, # [Optional] Describes the Cloud KMS encryption key that will be used to protect destination BigQuery table. The BigQuery Service Account associated with your project requires access to this encryption key.
1441 },
1442 &quot;lastModifiedTime&quot;: &quot;A String&quot;, # Output only. The time when this model was last modified, in millisecs since the epoch.
1443 }</pre>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001444</div>
1445
1446</body></html>