Skip to main content

hyperparameter_tuning_jobs

Creates, updates, deletes, gets or lists a hyperparameter_tuning_jobs resource.

Overview

Namehyperparameter_tuning_jobs
TypeResource
Idgoogle.aiplatform.hyperparameter_tuning_jobs

Fields

NameDatatypeDescription
namestringOutput only. Resource name of the HyperparameterTuningJob.
createTimestringOutput only. Time when the HyperparameterTuningJob was created.
displayNamestringRequired. The display name of the HyperparameterTuningJob. The name can be up to 128 characters long and can consist of any UTF-8 characters.
encryptionSpecobjectRepresents a customer-managed encryption key spec that can be applied to a top-level resource.
endTimestringOutput only. Time when the HyperparameterTuningJob entered any of the following states: JOB_STATE_SUCCEEDED, JOB_STATE_FAILED, JOB_STATE_CANCELLED.
errorobjectThe Status type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by gRPC. Each Status message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the API Design Guide.
labelsobjectThe labels with user-defined metadata to organize HyperparameterTuningJobs. Label keys and values can be no longer than 64 characters (Unicode codepoints), can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. See https://goo.gl/xmQnxf for more information and examples of labels.
maxFailedTrialCountintegerThe number of failed Trials that need to be seen before failing the HyperparameterTuningJob. If set to 0, Vertex AI decides how many Trials must fail before the whole job fails.
maxTrialCountintegerRequired. The desired total number of Trials.
parallelTrialCountintegerRequired. The desired number of Trials to run in parallel.
satisfiesPzibooleanOutput only. Reserved for future use.
satisfiesPzsbooleanOutput only. Reserved for future use.
startTimestringOutput only. Time when the HyperparameterTuningJob for the first time entered the JOB_STATE_RUNNING state.
statestringOutput only. The detailed state of the job.
studySpecobjectRepresents specification of a Study.
trialJobSpecobjectRepresents the spec of a CustomJob.
trialsarrayOutput only. Trials of the HyperparameterTuningJob.
updateTimestringOutput only. Time when the HyperparameterTuningJob was most recently updated.

Methods

NameAccessible byRequired ParamsDescription
getSELECThyperparameterTuningJobsId, locationsId, projectsIdGets a HyperparameterTuningJob
listSELECTlocationsId, projectsIdLists HyperparameterTuningJobs in a Location.
createINSERTlocationsId, projectsIdCreates a HyperparameterTuningJob
deleteDELETEhyperparameterTuningJobsId, locationsId, projectsIdDeletes a HyperparameterTuningJob.
cancelEXEChyperparameterTuningJobsId, locationsId, projectsIdCancels a HyperparameterTuningJob. Starts asynchronous cancellation on the HyperparameterTuningJob. The server makes a best effort to cancel the job, but success is not guaranteed. Clients can use JobService.GetHyperparameterTuningJob or other methods to check whether the cancellation succeeded or whether the job completed despite cancellation. On successful cancellation, the HyperparameterTuningJob is not deleted; instead it becomes a job with a HyperparameterTuningJob.error value with a google.rpc.Status.code of 1, corresponding to Code.CANCELLED, and HyperparameterTuningJob.state is set to CANCELLED.

SELECT examples

Lists HyperparameterTuningJobs in a Location.

SELECT
name,
createTime,
displayName,
encryptionSpec,
endTime,
error,
labels,
maxFailedTrialCount,
maxTrialCount,
parallelTrialCount,
satisfiesPzi,
satisfiesPzs,
startTime,
state,
studySpec,
trialJobSpec,
trials,
updateTime
FROM google.aiplatform.hyperparameter_tuning_jobs
WHERE locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';

INSERT example

Use the following StackQL query and manifest file to create a new hyperparameter_tuning_jobs resource.

/*+ create */
INSERT INTO google.aiplatform.hyperparameter_tuning_jobs (
locationsId,
projectsId,
displayName,
studySpec,
maxFailedTrialCount,
trialJobSpec,
maxTrialCount,
encryptionSpec,
parallelTrialCount,
labels
)
SELECT
'{{ locationsId }}',
'{{ projectsId }}',
'{{ displayName }}',
'{{ studySpec }}',
'{{ maxFailedTrialCount }}',
'{{ trialJobSpec }}',
'{{ maxTrialCount }}',
'{{ encryptionSpec }}',
'{{ parallelTrialCount }}',
'{{ labels }}'
;

DELETE example

Deletes the specified hyperparameter_tuning_jobs resource.

/*+ delete */
DELETE FROM google.aiplatform.hyperparameter_tuning_jobs
WHERE hyperparameterTuningJobsId = '{{ hyperparameterTuningJobsId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';