API documentation for datalabeling_v1beta1.types
package.
Classes
AnnotatedDataset
AnnotatedDataset is a set holding annotations for data in a Dataset. Each labeling task will generate an AnnotatedDataset under the Dataset that the task is requested for.
AnnotatedDatasetMetadata
Metadata on AnnotatedDataset. .. attribute:: image_classification_config
Configuration for image classification task.
:type: google.cloud.datalabeling_v1beta1.types.ImageClassificationConfig
Annotation
Annotation for Example. Each example may have one or more annotations. For example in image classification problem, each image might have one or more labels. We call labels binded with this image an Annotation.
AnnotationMetadata
Additional information associated with the annotation. .. attribute:: operator_metadata
Metadata related to human labeling.
:type: google.cloud.datalabeling_v1beta1.types.OperatorMetadata
AnnotationSentiment
API documentation for datalabeling_v1beta1.types.AnnotationSentiment
class.
AnnotationSource
Specifies where the annotation comes from (whether it was provided by a human labeler or a different source).
AnnotationSpec
Container of information related to one possible annotation that can
be used in a labeling task. For example, an image classification
task where images are labeled as dog
or cat
must reference
an AnnotationSpec for dog
and an AnnotationSpec for cat
.
AnnotationSpecSet
An AnnotationSpecSet is a collection of label definitions. For example, in image classification tasks, you define a set of possible labels for images as an AnnotationSpecSet. An AnnotationSpecSet is immutable upon creation.
AnnotationType
API documentation for datalabeling_v1beta1.types.AnnotationType
class.
AnnotationValue
Annotation value for an example. .. attribute:: image_classification_annotation
Annotation value for image classification case.
:type: google.cloud.datalabeling_v1beta1.types.ImageClassificationAnnotation
Attempt
Records a failed evaluation job run. .. attribute:: attempt_time
:type: google.protobuf.timestamp_pb2.Timestamp
BigQuerySource
The BigQuery location for input data. If used in an EvaluationJob, this is where the service saves the prediction input and output sampled from the model version.
BoundingBoxEvaluationOptions
Options regarding evaluation between bounding boxes. .. attribute:: iou_threshold
Minimum [intersection-over-union
(IOU)](/vision/automl/object-detection/docs/evaluate#intersection-over-union) required for 2 bounding boxes to be considered a match. This must be a number between 0 and 1.
:type: float
BoundingPoly
A bounding polygon in the image. .. attribute:: vertices
The bounding polygon vertices.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.Vertex]
BoundingPolyConfig
Config for image bounding poly (and bounding box) human labeling task.
ClassificationMetadata
Metadata for classification annotations. .. attribute:: is_multi_label
Whether the classification task is multi- abel or not.
:type: bool
ClassificationMetrics
Metrics calculated for a classification model. .. attribute:: pr_curve
Precision-recall curve based on ground truth labels, predicted labels, and scores for the predicted labels.
ConfusionMatrix
Confusion matrix of the model running the classification. Only applicable when the metrics entry aggregates multiple labels. Not applicable when the entry is for a single label.
CreateAnnotationSpecSetRequest
Request message for CreateAnnotationSpecSet. .. attribute:: parent
Required. AnnotationSpecSet resource parent, format: projects/{project_id}
:type: str
CreateDatasetRequest
Request message for CreateDataset. .. attribute:: parent
Required. Dataset resource parent, format: projects/{project_id}
:type: str
CreateEvaluationJobRequest
Request message for CreateEvaluationJob. .. attribute:: parent
Required. Evaluation job resource parent. Format: "projects/{project_id}".
:type: str
CreateInstructionMetadata
Metadata of a CreateInstruction operation. .. attribute:: instruction
The name of the created Instruction. projects/{project_id}/instructions/{instruction_id}
:type: str
CreateInstructionRequest
Request message for CreateInstruction. .. attribute:: parent
Required. Instruction resource parent, format: projects/{project_id}
:type: str
CsvInstruction
Deprecated: this instruction format is not supported any more. Instruction from a CSV file.
DataItem
DataItem is a piece of data, without annotation. For example, an image.
DataType
API documentation for datalabeling_v1beta1.types.DataType
class.
Dataset
Dataset is the resource to hold your data. You can request multiple labeling tasks for a dataset while each one will generate an AnnotatedDataset.
DeleteAnnotatedDatasetRequest
Request message for DeleteAnnotatedDataset. .. attribute:: name
Required. Name of the annotated dataset to delete, format: projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/ {annotated_dataset_id}
:type: str
DeleteAnnotationSpecSetRequest
Request message for DeleteAnnotationSpecSet. .. attribute:: name
Required. AnnotationSpec resource name, format:
projects/{project_id}/annotationSpecSets/{annotation_spec_set_id}
.
:type: str
DeleteDatasetRequest
Request message for DeleteDataset. .. attribute:: name
Required. Dataset resource name, format: projects/{project_id}/datasets/{dataset_id}
:type: str
DeleteEvaluationJobRequest
Request message DeleteEvaluationJob. .. attribute:: name
Required. Name of the evaluation job that is going to be deleted. Format:
"projects/{project_id}/evaluationJobs/{evaluation_job_id}".
:type: str
DeleteInstructionRequest
Request message for DeleteInstruction. .. attribute:: name
Required. Instruction resource name, format: projects/{project_id}/instructions/{instruction_id}
:type: str
Evaluation
Describes an evaluation between a machine learning model's predictions and ground truth labels. Created when an EvaluationJob runs successfully.
EvaluationConfig
Configuration details used for calculating evaluation metrics and creating an Evaluation.
EvaluationJob
Defines an evaluation job that runs periodically to generate
Evaluations.
Creating an evaluation
job </ml-engine/docs/continuous-evaluation/create-job>
__ is the
starting point for using continuous evaluation.
EvaluationJobAlertConfig
Provides details for how an evaluation job sends email alerts based on the results of a run.
EvaluationJobConfig
Configures specific details of how a continuous evaluation job works. Provide this configuration when you create an EvaluationJob.
EvaluationMetrics
EventConfig
Config for video event human labeling task. .. attribute:: annotation_spec_sets
Required. The list of annotation spec set resource name. Similar to video classification, we support selecting event from multiple AnnotationSpecSet at the same time.
:type: Sequence[str]
Example
An Example is a piece of data and its annotation. For example, an image with label "house".
ExportDataOperationMetadata
Metadata of an ExportData operation. .. attribute:: dataset
Output only. The name of dataset to be exported. "projects//datasets/".
:type: str
ExportDataOperationResponse
Response used for ExportDataset longrunning operation. .. attribute:: dataset
Ouptut only. The name of dataset. "projects//datasets/".
:type: str
ExportDataRequest
Request message for ExportData API. .. attribute:: name
Required. Dataset resource name, format: projects/{project_id}/datasets/{dataset_id}
:type: str
GcsDestination
Export destination of the data.Only gcs path is allowed in output_uri.
GcsFolderDestination
Export folder destination of the data. .. attribute:: output_folder_uri
Required. Cloud Storage directory to export data to.
:type: str
GcsSource
Source of the Cloud Storage file to be imported. .. attribute:: input_uri
Required. The input URI of source file. This must be a Cloud
Storage path (gs://...
).
:type: str
GetAnnotatedDatasetRequest
Request message for GetAnnotatedDataset. .. attribute:: name
Required. Name of the annotated dataset to get, format: projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/ {annotated_dataset_id}
:type: str
GetAnnotationSpecSetRequest
Request message for GetAnnotationSpecSet. .. attribute:: name
Required. AnnotationSpecSet resource name, format: projects/{project_id}/annotationSpecSets/{annotation_spec_set_id}
:type: str
GetDataItemRequest
Request message for GetDataItem. .. attribute:: name
Required. The name of the data item to get, format: projects/{project_id}/datasets/{dataset_id}/dataItems/{data_item_id}
:type: str
GetDatasetRequest
Request message for GetDataSet. .. attribute:: name
Required. Dataset resource name, format: projects/{project_id}/datasets/{dataset_id}
:type: str
GetEvaluationJobRequest
Request message for GetEvaluationJob. .. attribute:: name
Required. Name of the evaluation job. Format:
"projects/{project_id}/evaluationJobs/{evaluation_job_id}".
:type: str
GetEvaluationRequest
Request message for GetEvaluation. .. attribute:: name
Required. Name of the evaluation. Format:
"projects/{project_id}/datasets/{dataset_id}/evaluations/{evaluation_id}'
:type: str
GetExampleRequest
Request message for GetExample .. attribute:: name
Required. Name of example, format: projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/ {annotated_dataset_id}/examples/{example_id}
:type: str
GetInstructionRequest
Request message for GetInstruction. .. attribute:: name
Required. Instruction resource name, format: projects/{project_id}/instructions/{instruction_id}
:type: str
HumanAnnotationConfig
Configuration for how human labeling task should be done. .. attribute:: instruction
Required. Instruction resource name.
:type: str
ImageBoundingPolyAnnotation
Image bounding poly annotation. It represents a polygon including bounding box in the image.
ImageClassificationAnnotation
Image classification annotation definition. .. attribute:: annotation_spec
Label of image.
:type: google.cloud.datalabeling_v1beta1.types.AnnotationSpec
ImageClassificationConfig
Config for image classification human labeling task. .. attribute:: annotation_spec_set
Required. Annotation spec set resource name.
:type: str
ImagePayload
Container of information about an image. .. attribute:: mime_type
Image format.
:type: str
ImagePolylineAnnotation
A polyline for the image annotation. .. attribute:: polyline
ImageSegmentationAnnotation
Image segmentation annotation. .. attribute:: annotation_colors
The mapping between rgb color and annotation spec. The key is the rgb color represented in format of rgb(0, 0, 0). The value is the AnnotationSpec.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.ImageSegmentationAnnotation.AnnotationColorsEntry]
ImportDataOperationMetadata
Metadata of an ImportData operation. .. attribute:: dataset
Output only. The name of imported dataset. "projects//datasets/".
:type: str
ImportDataOperationResponse
Response used for ImportData longrunning operation. .. attribute:: dataset
Ouptut only. The name of imported dataset.
:type: str
ImportDataRequest
Request message for ImportData API. .. attribute:: name
Required. Dataset resource name, format: projects/{project_id}/datasets/{dataset_id}
:type: str
InputConfig
The configuration of input data, including data type, location, etc.
Instruction
Instruction of how to perform the labeling task for human operators. Currently only PDF instruction is supported.
LabelImageBoundingBoxOperationMetadata
Details of a LabelImageBoundingBox operation metadata. .. attribute:: basic_config
Basic human annotation config used in labeling request.
:type: google.cloud.datalabeling_v1beta1.types.HumanAnnotationConfig
LabelImageBoundingPolyOperationMetadata
Details of LabelImageBoundingPoly operation metadata. .. attribute:: basic_config
Basic human annotation config used in labeling request.
:type: google.cloud.datalabeling_v1beta1.types.HumanAnnotationConfig
LabelImageClassificationOperationMetadata
Metadata of a LabelImageClassification operation. .. attribute:: basic_config
Basic human annotation config used in labeling request.
:type: google.cloud.datalabeling_v1beta1.types.HumanAnnotationConfig
LabelImageOrientedBoundingBoxOperationMetadata
Details of a LabelImageOrientedBoundingBox operation metadata.
LabelImagePolylineOperationMetadata
Details of LabelImagePolyline operation metadata. .. attribute:: basic_config
Basic human annotation config used in labeling request.
:type: google.cloud.datalabeling_v1beta1.types.HumanAnnotationConfig
LabelImageRequest
Request message for starting an image labeling task. .. attribute:: image_classification_config
Configuration for image classification task. One of image_classification_config, bounding_poly_config, polyline_config and segmentation_config are required.
:type: google.cloud.datalabeling_v1beta1.types.ImageClassificationConfig
LabelImageSegmentationOperationMetadata
Details of a LabelImageSegmentation operation metadata. .. attribute:: basic_config
Basic human annotation config.
:type: google.cloud.datalabeling_v1beta1.types.HumanAnnotationConfig
LabelOperationMetadata
Metadata of a labeling operation, such as LabelImage or LabelVideo. Next tag: 20
LabelStats
Statistics about annotation specs. .. attribute:: example_count
Map of each annotation spec's example count. Key is the annotation spec name and value is the number of examples for that annotation spec. If the annotated dataset does not have annotation spec, the map will return a pair where the key is empty string and value is the total number of annotations.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.LabelStats.ExampleCountEntry]
LabelTextClassificationOperationMetadata
Details of a LabelTextClassification operation metadata. .. attribute:: basic_config
Basic human annotation config used in labeling request.
:type: google.cloud.datalabeling_v1beta1.types.HumanAnnotationConfig
LabelTextEntityExtractionOperationMetadata
Details of a LabelTextEntityExtraction operation metadata. .. attribute:: basic_config
Basic human annotation config used in labeling request.
:type: google.cloud.datalabeling_v1beta1.types.HumanAnnotationConfig
LabelTextRequest
Request message for LabelText. .. attribute:: text_classification_config
Configuration for text classification task. One of text_classification_config and text_entity_extraction_config is required.
:type: google.cloud.datalabeling_v1beta1.types.TextClassificationConfig
LabelVideoClassificationOperationMetadata
Details of a LabelVideoClassification operation metadata. .. attribute:: basic_config
Basic human annotation config used in labeling request.
:type: google.cloud.datalabeling_v1beta1.types.HumanAnnotationConfig
LabelVideoEventOperationMetadata
Details of a LabelVideoEvent operation metadata. .. attribute:: basic_config
Basic human annotation config used in labeling request.
:type: google.cloud.datalabeling_v1beta1.types.HumanAnnotationConfig
LabelVideoObjectDetectionOperationMetadata
Details of a LabelVideoObjectDetection operation metadata. .. attribute:: basic_config
Basic human annotation config used in labeling request.
:type: google.cloud.datalabeling_v1beta1.types.HumanAnnotationConfig
LabelVideoObjectTrackingOperationMetadata
Details of a LabelVideoObjectTracking operation metadata. .. attribute:: basic_config
Basic human annotation config used in labeling request.
:type: google.cloud.datalabeling_v1beta1.types.HumanAnnotationConfig
LabelVideoRequest
Request message for LabelVideo. .. attribute:: video_classification_config
Configuration for video classification task. One of video_classification_config, object_detection_config, object_tracking_config and event_config is required.
:type: google.cloud.datalabeling_v1beta1.types.VideoClassificationConfig
ListAnnotatedDatasetsRequest
Request message for ListAnnotatedDatasets. .. attribute:: parent
Required. Name of the dataset to list annotated datasets, format: projects/{project_id}/datasets/{dataset_id}
:type: str
ListAnnotatedDatasetsResponse
Results of listing annotated datasets for a dataset. .. attribute:: annotated_datasets
The list of annotated datasets to return.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.AnnotatedDataset]
ListAnnotationSpecSetsRequest
Request message for ListAnnotationSpecSets. .. attribute:: parent
Required. Parent of AnnotationSpecSet resource, format: projects/{project_id}
:type: str
ListAnnotationSpecSetsResponse
Results of listing annotation spec set under a project. .. attribute:: annotation_spec_sets
The list of annotation spec sets.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.AnnotationSpecSet]
ListDataItemsRequest
Request message for ListDataItems. .. attribute:: parent
Required. Name of the dataset to list data items, format: projects/{project_id}/datasets/{dataset_id}
:type: str
ListDataItemsResponse
Results of listing data items in a dataset. .. attribute:: data_items
The list of data items to return.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.DataItem]
ListDatasetsRequest
Request message for ListDataset. .. attribute:: parent
Required. Dataset resource parent, format: projects/{project_id}
:type: str
ListDatasetsResponse
Results of listing datasets within a project. .. attribute:: datasets
The list of datasets to return.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.Dataset]
ListEvaluationJobsRequest
Request message for ListEvaluationJobs. .. attribute:: parent
Required. Evaluation job resource parent. Format: "projects/{project_id}".
:type: str
ListEvaluationJobsResponse
Results for listing evaluation jobs. .. attribute:: evaluation_jobs
The list of evaluation jobs to return.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.EvaluationJob]
ListExamplesRequest
Request message for ListExamples. .. attribute:: parent
Required. Example resource parent.
:type: str
ListExamplesResponse
Results of listing Examples in and annotated dataset. .. attribute:: examples
The list of examples to return.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.Example]
ListInstructionsRequest
Request message for ListInstructions. .. attribute:: parent
Required. Instruction resource parent, format: projects/{project_id}
:type: str
ListInstructionsResponse
Results of listing instructions under a project. .. attribute:: instructions
The list of Instructions to return.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.Instruction]
NormalizedBoundingPoly
Normalized bounding polygon. .. attribute:: normalized_vertices
The bounding polygon normalized vertices.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.NormalizedVertex]
NormalizedPolyline
Normalized polyline. .. attribute:: normalized_vertices
The normalized polyline vertices.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.NormalizedVertex]
NormalizedVertex
A vertex represents a 2D point in the image. NOTE: the normalized vertex coordinates are relative to the original image and range from 0 to 1.
ObjectDetectionConfig
Config for video object detection human labeling task. Object detection will be conducted on the images extracted from the video, and those objects will be labeled with bounding boxes. User need to specify the number of images to be extracted per second as the extraction frame rate.
ObjectDetectionMetrics
Metrics calculated for an image object detection (bounding box) model.
ObjectTrackingConfig
Config for video object tracking human labeling task. .. attribute:: annotation_spec_set
Required. Annotation spec set resource name.
:type: str
ObjectTrackingFrame
Video frame level annotation for object detection and tracking.
OperatorMetadata
General information useful for labels coming from contributors.
OutputConfig
The configuration of output data. .. attribute:: gcs_destination
Output to a file in Cloud Storage. Should be used for labeling output other than image segmentation.
:type: google.cloud.datalabeling_v1beta1.types.GcsDestination
PauseEvaluationJobRequest
Request message for PauseEvaluationJob. .. attribute:: name
Required. Name of the evaluation job that is going to be paused. Format:
"projects/{project_id}/evaluationJobs/{evaluation_job_id}".
:type: str
PdfInstruction
Instruction from a PDF file. .. attribute:: gcs_file_uri
PDF file for the instruction. Only gcs path is allowed.
:type: str
Polyline
A line with multiple line segments. .. attribute:: vertices
The polyline vertices.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.Vertex]
PolylineConfig
Config for image polyline human labeling task. .. attribute:: annotation_spec_set
Required. Annotation spec set resource name.
:type: str
PrCurve
ResumeEvaluationJobRequest
Request message ResumeEvaluationJob. .. attribute:: name
Required. Name of the evaluation job that is going to be resumed. Format:
"projects/{project_id}/evaluationJobs/{evaluation_job_id}".
:type: str
SearchEvaluationsRequest
Request message for SearchEvaluation. .. attribute:: parent
Required. Evaluation search parent (project ID). Format: "projects/{project_id}".
:type: str
SearchEvaluationsResponse
Results of searching evaluations. .. attribute:: evaluations
The list of evaluations matching the search.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.Evaluation]
SearchExampleComparisonsRequest
Request message of SearchExampleComparisons. .. attribute:: parent
Required. Name of the Evaluation resource to search for example comparisons from. Format:
"projects/{project_id}/datasets/{dataset_id}/evaluations/{evaluation_id}".
:type: str
SearchExampleComparisonsResponse
Results of searching example comparisons. .. attribute:: example_comparisons
A list of example comparisons matching the search criteria.
:type: Sequence[google.cloud.datalabeling_v1beta1.types.SearchExampleComparisonsResponse.ExampleComparison]
SegmentationConfig
Config for image segmentation .. attribute:: annotation_spec_set
Required. Annotation spec set resource name. format: projects/{project_id}/annotationSpecSets/{annotation_spec_set_id}
:type: str
SentimentConfig
Config for setting up sentiments. .. attribute:: enable_label_sentiment_selection
If set to true, contributors will have the option to select sentiment of the label they selected, to mark it as negative or positive label. Default is false.
:type: bool
SequentialSegment
Start and end position in a sequence (e.g. text segment). .. attribute:: start
Start position (inclusive).
:type: int
StringAggregationType
API documentation for datalabeling_v1beta1.types.StringAggregationType
class.
TextClassificationAnnotation
Text classification annotation. .. attribute:: annotation_spec
Label of the text.
:type: google.cloud.datalabeling_v1beta1.types.AnnotationSpec
TextClassificationConfig
Config for text classification human labeling task. .. attribute:: allow_multi_label
Optional. If allow_multi_label is true, contributors are able to choose multiple labels for one text segment.
:type: bool
TextEntityExtractionAnnotation
Text entity extraction annotation. .. attribute:: annotation_spec
Label of the text entities.
:type: google.cloud.datalabeling_v1beta1.types.AnnotationSpec
TextEntityExtractionConfig
Config for text entity extraction human labeling task. .. attribute:: annotation_spec_set
Required. Annotation spec set resource name.
:type: str
TextMetadata
Metadata for the text. .. attribute:: language_code
The language of this text, as a
BCP-47 <https://www.rfc-editor.org/rfc/bcp/bcp47.txt>
__.
Default value is en-US.
:type: str
TextPayload
Container of information about a piece of text. .. attribute:: text_content
Text content.
:type: str
TimeSegment
A time period inside of an example that has a time dimension (e.g. video).
UpdateEvaluationJobRequest
Request message for UpdateEvaluationJob. .. attribute:: evaluation_job
Required. Evaluation job that is going to be updated.
:type: google.cloud.datalabeling_v1beta1.types.EvaluationJob
Vertex
A vertex represents a 2D point in the image. NOTE: the vertex coordinates are in the same scale as the original image.
VideoClassificationAnnotation
Video classification annotation. .. attribute:: time_segment
The time segment of the video to which the annotation applies.
VideoClassificationConfig
Config for video classification human labeling task. Currently two types of video classification are supported: 1. Assign labels on the entire video.
- Split the video into multiple video clips based on camera shot, and assign labels on each video clip.
VideoEventAnnotation
Video event annotation. .. attribute:: annotation_spec
Label of the event in this annotation.
:type: google.cloud.datalabeling_v1beta1.types.AnnotationSpec
VideoObjectTrackingAnnotation
Video object tracking annotation. .. attribute:: annotation_spec
Label of the object tracked in this annotation.
:type: google.cloud.datalabeling_v1beta1.types.AnnotationSpec
VideoPayload
Container of information of a video. .. attribute:: mime_type
Video format.
:type: str
VideoThumbnail
Container of information of a video thumbnail. .. attribute:: thumbnail
A byte string of the video frame.
:type: bytes