xref: /aosp_15_r20/external/googleapis/google/cloud/datalabeling/v1beta1/operations.proto (revision d5c09012810ac0c9f33fe448fb6da8260d444cc9)
1// Copyright 2019 Google LLC.
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7//     http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14//
15
16syntax = "proto3";
17
18package google.cloud.datalabeling.v1beta1;
19
20import "google/cloud/datalabeling/v1beta1/dataset.proto";
21import "google/cloud/datalabeling/v1beta1/human_annotation_config.proto";
22import "google/protobuf/timestamp.proto";
23import "google/rpc/status.proto";
24
25option csharp_namespace = "Google.Cloud.DataLabeling.V1Beta1";
26option go_package = "cloud.google.com/go/datalabeling/apiv1beta1/datalabelingpb;datalabelingpb";
27option java_multiple_files = true;
28option java_package = "com.google.cloud.datalabeling.v1beta1";
29option php_namespace = "Google\\Cloud\\DataLabeling\\V1beta1";
30option ruby_package = "Google::Cloud::DataLabeling::V1beta1";
31
32// Response used for ImportData longrunning operation.
33message ImportDataOperationResponse {
34  // Ouptut only. The name of imported dataset.
35  string dataset = 1;
36
37  // Output only. Total number of examples requested to import
38  int32 total_count = 2;
39
40  // Output only. Number of examples imported successfully.
41  int32 import_count = 3;
42}
43
44// Response used for ExportDataset longrunning operation.
45message ExportDataOperationResponse {
46  // Ouptut only. The name of dataset.
47  // "projects/*/datasets/*"
48  string dataset = 1;
49
50  // Output only. Total number of examples requested to export
51  int32 total_count = 2;
52
53  // Output only. Number of examples exported successfully.
54  int32 export_count = 3;
55
56  // Output only. Statistic infos of labels in the exported dataset.
57  LabelStats label_stats = 4;
58
59  // Output only. output_config in the ExportData request.
60  OutputConfig output_config = 5;
61}
62
63// Metadata of an ImportData operation.
64message ImportDataOperationMetadata {
65  // Output only. The name of imported dataset.
66  // "projects/*/datasets/*"
67  string dataset = 1;
68
69  // Output only. Partial failures encountered.
70  // E.g. single files that couldn't be read.
71  // Status details field will contain standard GCP error details.
72  repeated google.rpc.Status partial_failures = 2;
73
74  // Output only. Timestamp when import dataset request was created.
75  google.protobuf.Timestamp create_time = 3;
76}
77
78// Metadata of an ExportData operation.
79message ExportDataOperationMetadata {
80  // Output only. The name of dataset to be exported.
81  // "projects/*/datasets/*"
82  string dataset = 1;
83
84  // Output only. Partial failures encountered.
85  // E.g. single files that couldn't be read.
86  // Status details field will contain standard GCP error details.
87  repeated google.rpc.Status partial_failures = 2;
88
89  // Output only. Timestamp when export dataset request was created.
90  google.protobuf.Timestamp create_time = 3;
91}
92
93// Metadata of a labeling operation, such as LabelImage or LabelVideo.
94// Next tag: 20
95message LabelOperationMetadata {
96  // Ouptut only. Details of specific label operation.
97  oneof details {
98    // Details of label image classification operation.
99    LabelImageClassificationOperationMetadata image_classification_details = 3;
100
101    // Details of label image bounding box operation.
102    LabelImageBoundingBoxOperationMetadata image_bounding_box_details = 4;
103
104    // Details of label image bounding poly operation.
105    LabelImageBoundingPolyOperationMetadata image_bounding_poly_details = 11;
106
107    // Details of label image oriented bounding box operation.
108    LabelImageOrientedBoundingBoxOperationMetadata image_oriented_bounding_box_details = 14;
109
110    // Details of label image polyline operation.
111    LabelImagePolylineOperationMetadata image_polyline_details = 12;
112
113    // Details of label image segmentation operation.
114    LabelImageSegmentationOperationMetadata image_segmentation_details = 15;
115
116    // Details of label video classification operation.
117    LabelVideoClassificationOperationMetadata video_classification_details = 5;
118
119    // Details of label video object detection operation.
120    LabelVideoObjectDetectionOperationMetadata video_object_detection_details = 6;
121
122    // Details of label video object tracking operation.
123    LabelVideoObjectTrackingOperationMetadata video_object_tracking_details = 7;
124
125    // Details of label video event operation.
126    LabelVideoEventOperationMetadata video_event_details = 8;
127
128    // Details of label text classification operation.
129    LabelTextClassificationOperationMetadata text_classification_details = 9;
130
131    // Details of label text entity extraction operation.
132    LabelTextEntityExtractionOperationMetadata text_entity_extraction_details = 13;
133  }
134
135  // Output only. Progress of label operation. Range: [0, 100].
136  int32 progress_percent = 1;
137
138  // Output only. Partial failures encountered.
139  // E.g. single files that couldn't be read.
140  // Status details field will contain standard GCP error details.
141  repeated google.rpc.Status partial_failures = 2;
142
143  // Output only. Timestamp when labeling request was created.
144  google.protobuf.Timestamp create_time = 16;
145}
146
147// Metadata of a LabelImageClassification operation.
148message LabelImageClassificationOperationMetadata {
149  // Basic human annotation config used in labeling request.
150  HumanAnnotationConfig basic_config = 1;
151}
152
153// Details of a LabelImageBoundingBox operation metadata.
154message LabelImageBoundingBoxOperationMetadata {
155  // Basic human annotation config used in labeling request.
156  HumanAnnotationConfig basic_config = 1;
157}
158
159// Details of a LabelImageOrientedBoundingBox operation metadata.
160message LabelImageOrientedBoundingBoxOperationMetadata {
161  // Basic human annotation config.
162  HumanAnnotationConfig basic_config = 1;
163}
164
165// Details of LabelImageBoundingPoly operation metadata.
166message LabelImageBoundingPolyOperationMetadata {
167  // Basic human annotation config used in labeling request.
168  HumanAnnotationConfig basic_config = 1;
169}
170
171// Details of LabelImagePolyline operation metadata.
172message LabelImagePolylineOperationMetadata {
173  // Basic human annotation config used in labeling request.
174  HumanAnnotationConfig basic_config = 1;
175}
176
177// Details of a LabelImageSegmentation operation metadata.
178message LabelImageSegmentationOperationMetadata {
179  // Basic human annotation config.
180  HumanAnnotationConfig basic_config = 1;
181}
182
183// Details of a LabelVideoClassification operation metadata.
184message LabelVideoClassificationOperationMetadata {
185  // Basic human annotation config used in labeling request.
186  HumanAnnotationConfig basic_config = 1;
187}
188
189// Details of a LabelVideoObjectDetection operation metadata.
190message LabelVideoObjectDetectionOperationMetadata {
191  // Basic human annotation config used in labeling request.
192  HumanAnnotationConfig basic_config = 1;
193}
194
195// Details of a LabelVideoObjectTracking operation metadata.
196message LabelVideoObjectTrackingOperationMetadata {
197  // Basic human annotation config used in labeling request.
198  HumanAnnotationConfig basic_config = 1;
199}
200
201// Details of a LabelVideoEvent operation metadata.
202message LabelVideoEventOperationMetadata {
203  // Basic human annotation config used in labeling request.
204  HumanAnnotationConfig basic_config = 1;
205}
206
207// Details of a LabelTextClassification operation metadata.
208message LabelTextClassificationOperationMetadata {
209  // Basic human annotation config used in labeling request.
210  HumanAnnotationConfig basic_config = 1;
211}
212
213// Details of a LabelTextEntityExtraction operation metadata.
214message LabelTextEntityExtractionOperationMetadata {
215  // Basic human annotation config used in labeling request.
216  HumanAnnotationConfig basic_config = 1;
217}
218
219// Metadata of a CreateInstruction operation.
220message CreateInstructionMetadata {
221  // The name of the created Instruction.
222  // projects/{project_id}/instructions/{instruction_id}
223  string instruction = 1;
224
225  // Partial failures encountered.
226  // E.g. single files that couldn't be read.
227  // Status details field will contain standard GCP error details.
228  repeated google.rpc.Status partial_failures = 2;
229
230  // Timestamp when create instruction request was created.
231  google.protobuf.Timestamp create_time = 3;
232}
233