Skip to main content

data_labeling_jobs

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

Overview

Namedata_labeling_jobs
TypeResource
Idgoogle.aiplatform.data_labeling_jobs

Fields

The following fields are returned by SELECT queries:

Successful response

NameDatatypeDescription
namestringOutput only. Resource name of the DataLabelingJob.
activeLearningConfigobjectParameters that configure the active learning pipeline. Active learning will label the data incrementally via several iterations. For every iteration, it will select a batch of data based on the sampling strategy. (id: GoogleCloudAiplatformV1ActiveLearningConfig)
annotationLabelsobjectLabels to assign to annotations generated by this DataLabelingJob. 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. System reserved label keys are prefixed with "aiplatform.googleapis.com/" and are immutable.
createTimestring (google-datetime)Output only. Timestamp when this DataLabelingJob was created.
currentSpendobjectOutput only. Estimated cost(in US dollars) that the DataLabelingJob has incurred to date. (id: GoogleTypeMoney)
datasetsarrayRequired. Dataset resource names. Right now we only support labeling from a single Dataset. Format: projects/{project}/locations/{location}/datasets/{dataset}
displayNamestringRequired. The user-defined name of the DataLabelingJob. The name can be up to 128 characters long and can consist of any UTF-8 characters. Display name of a DataLabelingJob.
encryptionSpecobjectCustomer-managed encryption key spec for a DataLabelingJob. If set, this DataLabelingJob will be secured by this key. Note: Annotations created in the DataLabelingJob are associated with the EncryptionSpec of the Dataset they are exported to. (id: GoogleCloudAiplatformV1EncryptionSpec)
errorobjectOutput only. DataLabelingJob errors. It is only populated when job's state is JOB_STATE_FAILED or JOB_STATE_CANCELLED. (id: GoogleRpcStatus)
inputsanyRequired. Input config parameters for the DataLabelingJob.
inputsSchemaUristringRequired. Points to a YAML file stored on Google Cloud Storage describing the config for a specific type of DataLabelingJob. The schema files that can be used here are found in the https://storage.googleapis.com/google-cloud-aiplatform bucket in the /schema/datalabelingjob/inputs/ folder.
instructionUristringRequired. The Google Cloud Storage location of the instruction pdf. This pdf is shared with labelers, and provides detailed description on how to label DataItems in Datasets.
labelerCountinteger (int32)Required. Number of labelers to work on each DataItem.
labelingProgressinteger (int32)Output only. Current labeling job progress percentage scaled in interval [0, 100], indicating the percentage of DataItems that has been finished.
labelsobjectThe labels with user-defined metadata to organize your DataLabelingJobs. 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. System reserved label keys are prefixed with "aiplatform.googleapis.com/" and are immutable. Following system labels exist for each DataLabelingJob: * "aiplatform.googleapis.com/schema": output only, its value is the inputs_schema's title.
specialistPoolsarrayThe SpecialistPools' resource names associated with this job.
statestringOutput only. The detailed state of the job.
updateTimestring (google-datetime)Output only. Timestamp when this DataLabelingJob was updated most recently.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectprojectsId, locationsId, dataLabelingJobsIdGets a DataLabelingJob.
listselectprojectsId, locationsIdfilter, pageSize, pageToken, readMask, orderByLists DataLabelingJobs in a Location.
createinsertprojectsId, locationsIdCreates a DataLabelingJob.
deletedeleteprojectsId, locationsId, dataLabelingJobsIdDeletes a DataLabelingJob.
cancelexecprojectsId, locationsId, dataLabelingJobsIdCancels a DataLabelingJob. Success of cancellation is not guaranteed.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
dataLabelingJobsIdstring
locationsIdstring
projectsIdstring
filterstring
orderBystring
pageSizeinteger (int32)
pageTokenstring
readMaskstring (google-fieldmask)

SELECT examples

Gets a DataLabelingJob.

SELECT
name,
activeLearningConfig,
annotationLabels,
createTime,
currentSpend,
datasets,
displayName,
encryptionSpec,
error,
inputs,
inputsSchemaUri,
instructionUri,
labelerCount,
labelingProgress,
labels,
specialistPools,
state,
updateTime
FROM google.aiplatform.data_labeling_jobs
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND dataLabelingJobsId = '{{ dataLabelingJobsId }}' -- required;

INSERT examples

Creates a DataLabelingJob.

INSERT INTO google.aiplatform.data_labeling_jobs (
data__displayName,
data__datasets,
data__annotationLabels,
data__labelerCount,
data__instructionUri,
data__inputsSchemaUri,
data__inputs,
data__labels,
data__specialistPools,
data__encryptionSpec,
data__activeLearningConfig,
projectsId,
locationsId
)
SELECT
'{{ displayName }}',
'{{ datasets }}',
'{{ annotationLabels }}',
{{ labelerCount }},
'{{ instructionUri }}',
'{{ inputsSchemaUri }}',
'{{ inputs }}',
'{{ labels }}',
'{{ specialistPools }}',
'{{ encryptionSpec }}',
'{{ activeLearningConfig }}',
'{{ projectsId }}',
'{{ locationsId }}'
RETURNING
name,
activeLearningConfig,
annotationLabels,
createTime,
currentSpend,
datasets,
displayName,
encryptionSpec,
error,
inputs,
inputsSchemaUri,
instructionUri,
labelerCount,
labelingProgress,
labels,
specialistPools,
state,
updateTime
;

DELETE examples

Deletes a DataLabelingJob.

DELETE FROM google.aiplatform.data_labeling_jobs
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND dataLabelingJobsId = '{{ dataLabelingJobsId }}' --required;

Lifecycle Methods

Cancels a DataLabelingJob. Success of cancellation is not guaranteed.

EXEC google.aiplatform.data_labeling_jobs.cancel 
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@dataLabelingJobsId='{{ dataLabelingJobsId }}' --required;