operations.proto 8.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234
  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. syntax = "proto3";
  16. package google.cloud.datalabeling.v1beta1;
  17. import "google/api/annotations.proto";
  18. import "google/api/resource.proto";
  19. import "google/cloud/datalabeling/v1beta1/dataset.proto";
  20. import "google/cloud/datalabeling/v1beta1/human_annotation_config.proto";
  21. import "google/protobuf/timestamp.proto";
  22. import "google/rpc/status.proto";
  23. option csharp_namespace = "Google.Cloud.DataLabeling.V1Beta1";
  24. option go_package = "google.golang.org/genproto/googleapis/cloud/datalabeling/v1beta1;datalabeling";
  25. option java_multiple_files = true;
  26. option java_package = "com.google.cloud.datalabeling.v1beta1";
  27. option php_namespace = "Google\\Cloud\\DataLabeling\\V1beta1";
  28. option ruby_package = "Google::Cloud::DataLabeling::V1beta1";
  29. // Response used for ImportData longrunning operation.
  30. message ImportDataOperationResponse {
  31. // Ouptut only. The name of imported dataset.
  32. string dataset = 1;
  33. // Output only. Total number of examples requested to import
  34. int32 total_count = 2;
  35. // Output only. Number of examples imported successfully.
  36. int32 import_count = 3;
  37. }
  38. // Response used for ExportDataset longrunning operation.
  39. message ExportDataOperationResponse {
  40. // Ouptut only. The name of dataset.
  41. // "projects/*/datasets/*"
  42. string dataset = 1;
  43. // Output only. Total number of examples requested to export
  44. int32 total_count = 2;
  45. // Output only. Number of examples exported successfully.
  46. int32 export_count = 3;
  47. // Output only. Statistic infos of labels in the exported dataset.
  48. LabelStats label_stats = 4;
  49. // Output only. output_config in the ExportData request.
  50. OutputConfig output_config = 5;
  51. }
  52. // Metadata of an ImportData operation.
  53. message ImportDataOperationMetadata {
  54. // Output only. The name of imported dataset.
  55. // "projects/*/datasets/*"
  56. string dataset = 1;
  57. // Output only. Partial failures encountered.
  58. // E.g. single files that couldn't be read.
  59. // Status details field will contain standard GCP error details.
  60. repeated google.rpc.Status partial_failures = 2;
  61. // Output only. Timestamp when import dataset request was created.
  62. google.protobuf.Timestamp create_time = 3;
  63. }
  64. // Metadata of an ExportData operation.
  65. message ExportDataOperationMetadata {
  66. // Output only. The name of dataset to be exported.
  67. // "projects/*/datasets/*"
  68. string dataset = 1;
  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. // Output only. Timestamp when export dataset request was created.
  74. google.protobuf.Timestamp create_time = 3;
  75. }
  76. // Metadata of a labeling operation, such as LabelImage or LabelVideo.
  77. // Next tag: 20
  78. message LabelOperationMetadata {
  79. // Ouptut only. Details of specific label operation.
  80. oneof details {
  81. // Details of label image classification operation.
  82. LabelImageClassificationOperationMetadata image_classification_details = 3;
  83. // Details of label image bounding box operation.
  84. LabelImageBoundingBoxOperationMetadata image_bounding_box_details = 4;
  85. // Details of label image bounding poly operation.
  86. LabelImageBoundingPolyOperationMetadata image_bounding_poly_details = 11;
  87. // Details of label image oriented bounding box operation.
  88. LabelImageOrientedBoundingBoxOperationMetadata image_oriented_bounding_box_details = 14;
  89. // Details of label image polyline operation.
  90. LabelImagePolylineOperationMetadata image_polyline_details = 12;
  91. // Details of label image segmentation operation.
  92. LabelImageSegmentationOperationMetadata image_segmentation_details = 15;
  93. // Details of label video classification operation.
  94. LabelVideoClassificationOperationMetadata video_classification_details = 5;
  95. // Details of label video object detection operation.
  96. LabelVideoObjectDetectionOperationMetadata video_object_detection_details = 6;
  97. // Details of label video object tracking operation.
  98. LabelVideoObjectTrackingOperationMetadata video_object_tracking_details = 7;
  99. // Details of label video event operation.
  100. LabelVideoEventOperationMetadata video_event_details = 8;
  101. // Details of label text classification operation.
  102. LabelTextClassificationOperationMetadata text_classification_details = 9;
  103. // Details of label text entity extraction operation.
  104. LabelTextEntityExtractionOperationMetadata text_entity_extraction_details = 13;
  105. }
  106. // Output only. Progress of label operation. Range: [0, 100].
  107. int32 progress_percent = 1;
  108. // Output only. Partial failures encountered.
  109. // E.g. single files that couldn't be read.
  110. // Status details field will contain standard GCP error details.
  111. repeated google.rpc.Status partial_failures = 2;
  112. // Output only. Timestamp when labeling request was created.
  113. google.protobuf.Timestamp create_time = 16;
  114. }
  115. // Metadata of a LabelImageClassification operation.
  116. message LabelImageClassificationOperationMetadata {
  117. // Basic human annotation config used in labeling request.
  118. HumanAnnotationConfig basic_config = 1;
  119. }
  120. // Details of a LabelImageBoundingBox operation metadata.
  121. message LabelImageBoundingBoxOperationMetadata {
  122. // Basic human annotation config used in labeling request.
  123. HumanAnnotationConfig basic_config = 1;
  124. }
  125. // Details of a LabelImageOrientedBoundingBox operation metadata.
  126. message LabelImageOrientedBoundingBoxOperationMetadata {
  127. // Basic human annotation config.
  128. HumanAnnotationConfig basic_config = 1;
  129. }
  130. // Details of LabelImageBoundingPoly operation metadata.
  131. message LabelImageBoundingPolyOperationMetadata {
  132. // Basic human annotation config used in labeling request.
  133. HumanAnnotationConfig basic_config = 1;
  134. }
  135. // Details of LabelImagePolyline operation metadata.
  136. message LabelImagePolylineOperationMetadata {
  137. // Basic human annotation config used in labeling request.
  138. HumanAnnotationConfig basic_config = 1;
  139. }
  140. // Details of a LabelImageSegmentation operation metadata.
  141. message LabelImageSegmentationOperationMetadata {
  142. // Basic human annotation config.
  143. HumanAnnotationConfig basic_config = 1;
  144. }
  145. // Details of a LabelVideoClassification operation metadata.
  146. message LabelVideoClassificationOperationMetadata {
  147. // Basic human annotation config used in labeling request.
  148. HumanAnnotationConfig basic_config = 1;
  149. }
  150. // Details of a LabelVideoObjectDetection operation metadata.
  151. message LabelVideoObjectDetectionOperationMetadata {
  152. // Basic human annotation config used in labeling request.
  153. HumanAnnotationConfig basic_config = 1;
  154. }
  155. // Details of a LabelVideoObjectTracking operation metadata.
  156. message LabelVideoObjectTrackingOperationMetadata {
  157. // Basic human annotation config used in labeling request.
  158. HumanAnnotationConfig basic_config = 1;
  159. }
  160. // Details of a LabelVideoEvent operation metadata.
  161. message LabelVideoEventOperationMetadata {
  162. // Basic human annotation config used in labeling request.
  163. HumanAnnotationConfig basic_config = 1;
  164. }
  165. // Details of a LabelTextClassification operation metadata.
  166. message LabelTextClassificationOperationMetadata {
  167. // Basic human annotation config used in labeling request.
  168. HumanAnnotationConfig basic_config = 1;
  169. }
  170. // Details of a LabelTextEntityExtraction operation metadata.
  171. message LabelTextEntityExtractionOperationMetadata {
  172. // Basic human annotation config used in labeling request.
  173. HumanAnnotationConfig basic_config = 1;
  174. }
  175. // Metadata of a CreateInstruction operation.
  176. message CreateInstructionMetadata {
  177. // The name of the created Instruction.
  178. // projects/{project_id}/instructions/{instruction_id}
  179. string instruction = 1;
  180. // Partial failures encountered.
  181. // E.g. single files that couldn't be read.
  182. // Status details field will contain standard GCP error details.
  183. repeated google.rpc.Status partial_failures = 2;
  184. // Timestamp when create instruction request was created.
  185. google.protobuf.Timestamp create_time = 3;
  186. }