google-cloud-automl-v1 0.6.0 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/google/cloud/automl/v1/annotation_payload_pb.rb +29 -12
- data/lib/google/cloud/automl/v1/annotation_spec_pb.rb +24 -6
- data/lib/google/cloud/automl/v1/automl/client.rb +16 -5
- data/lib/google/cloud/automl/v1/automl/operations.rb +15 -4
- data/lib/google/cloud/automl/v1/automl/rest/client.rb +369 -4
- data/lib/google/cloud/automl/v1/automl/rest/operations.rb +108 -8
- data/lib/google/cloud/automl/v1/automl/rest/service_stub.rb +18 -18
- data/lib/google/cloud/automl/v1/classification_pb.rb +24 -41
- data/lib/google/cloud/automl/v1/data_items_pb.rb +27 -55
- data/lib/google/cloud/automl/v1/dataset_pb.rb +28 -18
- data/lib/google/cloud/automl/v1/detection_pb.rb +25 -21
- data/lib/google/cloud/automl/v1/geometry_pb.rb +24 -8
- data/lib/google/cloud/automl/v1/image_pb.rb +24 -29
- data/lib/google/cloud/automl/v1/io_pb.rb +24 -38
- data/lib/google/cloud/automl/v1/model_evaluation_pb.rb +30 -15
- data/lib/google/cloud/automl/v1/model_pb.rb +28 -24
- data/lib/google/cloud/automl/v1/operations_pb.rb +27 -53
- data/lib/google/cloud/automl/v1/prediction_service/client.rb +16 -5
- data/lib/google/cloud/automl/v1/prediction_service/operations.rb +15 -4
- data/lib/google/cloud/automl/v1/prediction_service/rest/client.rb +45 -4
- data/lib/google/cloud/automl/v1/prediction_service/rest/operations.rb +108 -8
- data/lib/google/cloud/automl/v1/prediction_service/rest/service_stub.rb +2 -2
- data/lib/google/cloud/automl/v1/prediction_service_pb.rb +27 -20
- data/lib/google/cloud/automl/v1/service_pb.rb +30 -87
- data/lib/google/cloud/automl/v1/text_extraction_pb.rb +25 -17
- data/lib/google/cloud/automl/v1/text_pb.rb +24 -16
- data/lib/google/cloud/automl/v1/text_segment_pb.rb +24 -6
- data/lib/google/cloud/automl/v1/text_sentiment_pb.rb +25 -14
- data/lib/google/cloud/automl/v1/translation_pb.rb +25 -17
- data/lib/google/cloud/automl/v1/version.rb +1 -1
- data/proto_docs/google/api/client.rb +67 -4
- data/proto_docs/google/api/field_behavior.rb +14 -0
- data/proto_docs/google/protobuf/any.rb +7 -4
- data/proto_docs/google/protobuf/timestamp.rb +1 -3
- metadata +5 -5
@@ -1,3 +1,4 @@
|
|
1
|
+
# frozen_string_literal: true
|
1
2
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
3
|
# source: google/cloud/automl/v1/detection.proto
|
3
4
|
|
@@ -5,29 +6,32 @@ require 'google/protobuf'
|
|
5
6
|
|
6
7
|
require 'google/cloud/automl/v1/geometry_pb'
|
7
8
|
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
9
|
+
|
10
|
+
descriptor_data = "\n&google/cloud/automl/v1/detection.proto\x12\x16google.cloud.automl.v1\x1a%google/cloud/automl/v1/geometry.proto\"k\n\x1eImageObjectDetectionAnnotation\x12:\n\x0c\x62ounding_box\x18\x01 \x01(\x0b\x32$.google.cloud.automl.v1.BoundingPoly\x12\r\n\x05score\x18\x02 \x01(\x02\"\xa9\x02\n\x17\x42oundingBoxMetricsEntry\x12\x15\n\riou_threshold\x18\x01 \x01(\x02\x12\x1e\n\x16mean_average_precision\x18\x02 \x01(\x02\x12j\n\x1a\x63onfidence_metrics_entries\x18\x03 \x03(\x0b\x32\x46.google.cloud.automl.v1.BoundingBoxMetricsEntry.ConfidenceMetricsEntry\x1ak\n\x16\x43onfidenceMetricsEntry\x12\x1c\n\x14\x63onfidence_threshold\x18\x01 \x01(\x02\x12\x0e\n\x06recall\x18\x02 \x01(\x02\x12\x11\n\tprecision\x18\x03 \x01(\x02\x12\x10\n\x08\x66\x31_score\x18\x04 \x01(\x02\"\xd1\x01\n%ImageObjectDetectionEvaluationMetrics\x12$\n\x1c\x65valuated_bounding_box_count\x18\x01 \x01(\x05\x12U\n\x1c\x62ounding_box_metrics_entries\x18\x02 \x03(\x0b\x32/.google.cloud.automl.v1.BoundingBoxMetricsEntry\x12+\n#bounding_box_mean_average_precision\x18\x03 \x01(\x02\x42\xa0\x01\n\x1a\x63om.google.cloud.automl.v1P\x01Z2cloud.google.com/go/automl/apiv1/automlpb;automlpb\xaa\x02\x16Google.Cloud.AutoML.V1\xca\x02\x16Google\\Cloud\\AutoMl\\V1\xea\x02\x19Google::Cloud::AutoML::V1b\x06proto3"
|
11
|
+
|
12
|
+
pool = Google::Protobuf::DescriptorPool.generated_pool
|
13
|
+
|
14
|
+
begin
|
15
|
+
pool.add_serialized_file(descriptor_data)
|
16
|
+
rescue TypeError => e
|
17
|
+
# Compatibility code: will be removed in the next major version.
|
18
|
+
require 'google/protobuf/descriptor_pb'
|
19
|
+
parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data)
|
20
|
+
parsed.clear_dependency
|
21
|
+
serialized = parsed.class.encode(parsed)
|
22
|
+
file = pool.add_serialized_file(serialized)
|
23
|
+
warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}"
|
24
|
+
imports = [
|
25
|
+
["google.cloud.automl.v1.BoundingPoly", "google/cloud/automl/v1/geometry.proto"],
|
26
|
+
]
|
27
|
+
imports.each do |type_name, expected_filename|
|
28
|
+
import_file = pool.lookup(type_name).file_descriptor
|
29
|
+
if import_file.name != expected_filename
|
30
|
+
warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}"
|
29
31
|
end
|
30
32
|
end
|
33
|
+
warn "Each proto file must use a consistent fully-qualified name."
|
34
|
+
warn "This will become an error in the next major version."
|
31
35
|
end
|
32
36
|
|
33
37
|
module Google
|
@@ -1,18 +1,34 @@
|
|
1
|
+
# frozen_string_literal: true
|
1
2
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
3
|
# source: google/cloud/automl/v1/geometry.proto
|
3
4
|
|
4
5
|
require 'google/protobuf'
|
5
6
|
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
7
|
+
|
8
|
+
descriptor_data = "\n%google/cloud/automl/v1/geometry.proto\x12\x16google.cloud.automl.v1\"(\n\x10NormalizedVertex\x12\t\n\x01x\x18\x01 \x01(\x02\x12\t\n\x01y\x18\x02 \x01(\x02\"U\n\x0c\x42oundingPoly\x12\x45\n\x13normalized_vertices\x18\x02 \x03(\x0b\x32(.google.cloud.automl.v1.NormalizedVertexB\xa0\x01\n\x1a\x63om.google.cloud.automl.v1P\x01Z2cloud.google.com/go/automl/apiv1/automlpb;automlpb\xaa\x02\x16Google.Cloud.AutoML.V1\xca\x02\x16Google\\Cloud\\AutoMl\\V1\xea\x02\x19Google::Cloud::AutoML::V1b\x06proto3"
|
9
|
+
|
10
|
+
pool = Google::Protobuf::DescriptorPool.generated_pool
|
11
|
+
|
12
|
+
begin
|
13
|
+
pool.add_serialized_file(descriptor_data)
|
14
|
+
rescue TypeError => e
|
15
|
+
# Compatibility code: will be removed in the next major version.
|
16
|
+
require 'google/protobuf/descriptor_pb'
|
17
|
+
parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data)
|
18
|
+
parsed.clear_dependency
|
19
|
+
serialized = parsed.class.encode(parsed)
|
20
|
+
file = pool.add_serialized_file(serialized)
|
21
|
+
warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}"
|
22
|
+
imports = [
|
23
|
+
]
|
24
|
+
imports.each do |type_name, expected_filename|
|
25
|
+
import_file = pool.lookup(type_name).file_descriptor
|
26
|
+
if import_file.name != expected_filename
|
27
|
+
warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}"
|
14
28
|
end
|
15
29
|
end
|
30
|
+
warn "Each proto file must use a consistent fully-qualified name."
|
31
|
+
warn "This will become an error in the next major version."
|
16
32
|
end
|
17
33
|
|
18
34
|
module Google
|
@@ -1,3 +1,4 @@
|
|
1
|
+
# frozen_string_literal: true
|
1
2
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
3
|
# source: google/cloud/automl/v1/image.proto
|
3
4
|
|
@@ -6,37 +7,31 @@ require 'google/protobuf'
|
|
6
7
|
require 'google/api/field_behavior_pb'
|
7
8
|
require 'google/cloud/automl/v1/classification_pb'
|
8
9
|
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
optional :train_budget_milli_node_hours, :int64, 6
|
31
|
-
optional :train_cost_milli_node_hours, :int64, 7
|
32
|
-
end
|
33
|
-
add_message "google.cloud.automl.v1.ImageClassificationModelDeploymentMetadata" do
|
34
|
-
optional :node_count, :int64, 1
|
35
|
-
end
|
36
|
-
add_message "google.cloud.automl.v1.ImageObjectDetectionModelDeploymentMetadata" do
|
37
|
-
optional :node_count, :int64, 1
|
10
|
+
|
11
|
+
descriptor_data = "\n\"google/cloud/automl/v1/image.proto\x12\x16google.cloud.automl.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a+google/cloud/automl/v1/classification.proto\"r\n\"ImageClassificationDatasetMetadata\x12L\n\x13\x63lassification_type\x18\x01 \x01(\x0e\x32*.google.cloud.automl.v1.ClassificationTypeB\x03\xe0\x41\x02\"%\n#ImageObjectDetectionDatasetMetadata\"\xf7\x01\n ImageClassificationModelMetadata\x12\x1a\n\rbase_model_id\x18\x01 \x01(\tB\x03\xe0\x41\x01\x12*\n\x1dtrain_budget_milli_node_hours\x18\x10 \x01(\x03\x42\x03\xe0\x41\x01\x12(\n\x1btrain_cost_milli_node_hours\x18\x11 \x01(\x03\x42\x03\xe0\x41\x03\x12\x18\n\x0bstop_reason\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12\x17\n\nmodel_type\x18\x07 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08node_qps\x18\r \x01(\x01\x42\x03\xe0\x41\x03\x12\x17\n\nnode_count\x18\x0e \x01(\x03\x42\x03\xe0\x41\x03\"\xdc\x01\n!ImageObjectDetectionModelMetadata\x12\x17\n\nmodel_type\x18\x01 \x01(\tB\x03\xe0\x41\x01\x12\x17\n\nnode_count\x18\x03 \x01(\x03\x42\x03\xe0\x41\x03\x12\x15\n\x08node_qps\x18\x04 \x01(\x01\x42\x03\xe0\x41\x03\x12\x18\n\x0bstop_reason\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12*\n\x1dtrain_budget_milli_node_hours\x18\x06 \x01(\x03\x42\x03\xe0\x41\x01\x12(\n\x1btrain_cost_milli_node_hours\x18\x07 \x01(\x03\x42\x03\xe0\x41\x03\"E\n*ImageClassificationModelDeploymentMetadata\x12\x17\n\nnode_count\x18\x01 \x01(\x03\x42\x03\xe0\x41\x04\"F\n+ImageObjectDetectionModelDeploymentMetadata\x12\x17\n\nnode_count\x18\x01 \x01(\x03\x42\x03\xe0\x41\x04\x42\xac\x01\n\x1a\x63om.google.cloud.automl.v1B\nImageProtoP\x01Z2cloud.google.com/go/automl/apiv1/automlpb;automlpb\xaa\x02\x16Google.Cloud.AutoML.V1\xca\x02\x16Google\\Cloud\\AutoMl\\V1\xea\x02\x19Google::Cloud::AutoML::V1b\x06proto3"
|
12
|
+
|
13
|
+
pool = Google::Protobuf::DescriptorPool.generated_pool
|
14
|
+
|
15
|
+
begin
|
16
|
+
pool.add_serialized_file(descriptor_data)
|
17
|
+
rescue TypeError => e
|
18
|
+
# Compatibility code: will be removed in the next major version.
|
19
|
+
require 'google/protobuf/descriptor_pb'
|
20
|
+
parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data)
|
21
|
+
parsed.clear_dependency
|
22
|
+
serialized = parsed.class.encode(parsed)
|
23
|
+
file = pool.add_serialized_file(serialized)
|
24
|
+
warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}"
|
25
|
+
imports = [
|
26
|
+
]
|
27
|
+
imports.each do |type_name, expected_filename|
|
28
|
+
import_file = pool.lookup(type_name).file_descriptor
|
29
|
+
if import_file.name != expected_filename
|
30
|
+
warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}"
|
38
31
|
end
|
39
32
|
end
|
33
|
+
warn "Each proto file must use a consistent fully-qualified name."
|
34
|
+
warn "This will become an error in the next major version."
|
40
35
|
end
|
41
36
|
|
42
37
|
module Google
|
@@ -1,3 +1,4 @@
|
|
1
|
+
# frozen_string_literal: true
|
1
2
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
3
|
# source: google/cloud/automl/v1/io.proto
|
3
4
|
|
@@ -5,46 +6,31 @@ require 'google/protobuf'
|
|
5
6
|
|
6
7
|
require 'google/api/field_behavior_pb'
|
7
8
|
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
add_message "google.cloud.automl.v1.BatchPredictOutputConfig" do
|
30
|
-
oneof :destination do
|
31
|
-
optional :gcs_destination, :message, 1, "google.cloud.automl.v1.GcsDestination"
|
32
|
-
end
|
33
|
-
end
|
34
|
-
add_message "google.cloud.automl.v1.ModelExportOutputConfig" do
|
35
|
-
optional :model_format, :string, 4
|
36
|
-
map :params, :string, :string, 2
|
37
|
-
oneof :destination do
|
38
|
-
optional :gcs_destination, :message, 1, "google.cloud.automl.v1.GcsDestination"
|
39
|
-
end
|
40
|
-
end
|
41
|
-
add_message "google.cloud.automl.v1.GcsSource" do
|
42
|
-
repeated :input_uris, :string, 1
|
43
|
-
end
|
44
|
-
add_message "google.cloud.automl.v1.GcsDestination" do
|
45
|
-
optional :output_uri_prefix, :string, 1
|
9
|
+
|
10
|
+
descriptor_data = "\n\x1fgoogle/cloud/automl/v1/io.proto\x12\x16google.cloud.automl.v1\x1a\x1fgoogle/api/field_behavior.proto\"\xc0\x01\n\x0bInputConfig\x12\x37\n\ngcs_source\x18\x01 \x01(\x0b\x32!.google.cloud.automl.v1.GcsSourceH\x00\x12?\n\x06params\x18\x02 \x03(\x0b\x32/.google.cloud.automl.v1.InputConfig.ParamsEntry\x1a-\n\x0bParamsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x42\x08\n\x06source\"a\n\x17\x42\x61tchPredictInputConfig\x12<\n\ngcs_source\x18\x01 \x01(\x0b\x32!.google.cloud.automl.v1.GcsSourceB\x03\xe0\x41\x02H\x00\x42\x08\n\x06source\"L\n\x13\x44ocumentInputConfig\x12\x35\n\ngcs_source\x18\x01 \x01(\x0b\x32!.google.cloud.automl.v1.GcsSource\"e\n\x0cOutputConfig\x12\x46\n\x0fgcs_destination\x18\x01 \x01(\x0b\x32&.google.cloud.automl.v1.GcsDestinationB\x03\xe0\x41\x02H\x00\x42\r\n\x0b\x64\x65stination\"q\n\x18\x42\x61tchPredictOutputConfig\x12\x46\n\x0fgcs_destination\x18\x01 \x01(\x0b\x32&.google.cloud.automl.v1.GcsDestinationB\x03\xe0\x41\x02H\x00\x42\r\n\x0b\x64\x65stination\"\x82\x02\n\x17ModelExportOutputConfig\x12\x46\n\x0fgcs_destination\x18\x01 \x01(\x0b\x32&.google.cloud.automl.v1.GcsDestinationB\x03\xe0\x41\x02H\x00\x12\x14\n\x0cmodel_format\x18\x04 \x01(\t\x12K\n\x06params\x18\x02 \x03(\x0b\x32;.google.cloud.automl.v1.ModelExportOutputConfig.ParamsEntry\x1a-\n\x0bParamsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x42\r\n\x0b\x64\x65stination\"$\n\tGcsSource\x12\x17\n\ninput_uris\x18\x01 \x03(\tB\x03\xe0\x41\x02\"0\n\x0eGcsDestination\x12\x1e\n\x11output_uri_prefix\x18\x01 \x01(\tB\x03\xe0\x41\x02\x42\xa0\x01\n\x1a\x63om.google.cloud.automl.v1P\x01Z2cloud.google.com/go/automl/apiv1/automlpb;automlpb\xaa\x02\x16Google.Cloud.AutoML.V1\xca\x02\x16Google\\Cloud\\AutoMl\\V1\xea\x02\x19Google::Cloud::AutoML::V1b\x06proto3"
|
11
|
+
|
12
|
+
pool = Google::Protobuf::DescriptorPool.generated_pool
|
13
|
+
|
14
|
+
begin
|
15
|
+
pool.add_serialized_file(descriptor_data)
|
16
|
+
rescue TypeError => e
|
17
|
+
# Compatibility code: will be removed in the next major version.
|
18
|
+
require 'google/protobuf/descriptor_pb'
|
19
|
+
parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data)
|
20
|
+
parsed.clear_dependency
|
21
|
+
serialized = parsed.class.encode(parsed)
|
22
|
+
file = pool.add_serialized_file(serialized)
|
23
|
+
warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}"
|
24
|
+
imports = [
|
25
|
+
]
|
26
|
+
imports.each do |type_name, expected_filename|
|
27
|
+
import_file = pool.lookup(type_name).file_descriptor
|
28
|
+
if import_file.name != expected_filename
|
29
|
+
warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}"
|
46
30
|
end
|
47
31
|
end
|
32
|
+
warn "Each proto file must use a consistent fully-qualified name."
|
33
|
+
warn "This will become an error in the next major version."
|
48
34
|
end
|
49
35
|
|
50
36
|
module Google
|
@@ -1,3 +1,4 @@
|
|
1
|
+
# frozen_string_literal: true
|
1
2
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
3
|
# source: google/cloud/automl/v1/model_evaluation.proto
|
3
4
|
|
@@ -11,23 +12,37 @@ require 'google/cloud/automl/v1/text_sentiment_pb'
|
|
11
12
|
require 'google/cloud/automl/v1/translation_pb'
|
12
13
|
require 'google/protobuf/timestamp_pb'
|
13
14
|
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
15
|
+
|
16
|
+
descriptor_data = "\n-google/cloud/automl/v1/model_evaluation.proto\x12\x16google.cloud.automl.v1\x1a\x19google/api/resource.proto\x1a+google/cloud/automl/v1/classification.proto\x1a&google/cloud/automl/v1/detection.proto\x1a,google/cloud/automl/v1/text_extraction.proto\x1a+google/cloud/automl/v1/text_sentiment.proto\x1a(google/cloud/automl/v1/translation.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xbe\x06\n\x0fModelEvaluation\x12\x64\n!classification_evaluation_metrics\x18\x08 \x01(\x0b\x32\x37.google.cloud.automl.v1.ClassificationEvaluationMetricsH\x00\x12^\n\x1etranslation_evaluation_metrics\x18\t \x01(\x0b\x32\x34.google.cloud.automl.v1.TranslationEvaluationMetricsH\x00\x12r\n)image_object_detection_evaluation_metrics\x18\x0c \x01(\x0b\x32=.google.cloud.automl.v1.ImageObjectDetectionEvaluationMetricsH\x00\x12\x63\n!text_sentiment_evaluation_metrics\x18\x0b \x01(\x0b\x32\x36.google.cloud.automl.v1.TextSentimentEvaluationMetricsH\x00\x12\x65\n\"text_extraction_evaluation_metrics\x18\r \x01(\x0b\x32\x37.google.cloud.automl.v1.TextExtractionEvaluationMetricsH\x00\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x1a\n\x12\x61nnotation_spec_id\x18\x02 \x01(\t\x12\x14\n\x0c\x64isplay_name\x18\x0f \x01(\t\x12/\n\x0b\x63reate_time\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x1f\n\x17\x65valuated_example_count\x18\x06 \x01(\x05:\x87\x01\xea\x41\x83\x01\n%automl.googleapis.com/ModelEvaluation\x12Zprojects/{project}/locations/{location}/models/{model}/modelEvaluations/{model_evaluation}B\t\n\x07metricsB\xa0\x01\n\x1a\x63om.google.cloud.automl.v1P\x01Z2cloud.google.com/go/automl/apiv1/automlpb;automlpb\xaa\x02\x16Google.Cloud.AutoML.V1\xca\x02\x16Google\\Cloud\\AutoMl\\V1\xea\x02\x19Google::Cloud::AutoML::V1b\x06proto3"
|
17
|
+
|
18
|
+
pool = Google::Protobuf::DescriptorPool.generated_pool
|
19
|
+
|
20
|
+
begin
|
21
|
+
pool.add_serialized_file(descriptor_data)
|
22
|
+
rescue TypeError => e
|
23
|
+
# Compatibility code: will be removed in the next major version.
|
24
|
+
require 'google/protobuf/descriptor_pb'
|
25
|
+
parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data)
|
26
|
+
parsed.clear_dependency
|
27
|
+
serialized = parsed.class.encode(parsed)
|
28
|
+
file = pool.add_serialized_file(serialized)
|
29
|
+
warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}"
|
30
|
+
imports = [
|
31
|
+
["google.cloud.automl.v1.ClassificationEvaluationMetrics", "google/cloud/automl/v1/classification.proto"],
|
32
|
+
["google.cloud.automl.v1.TranslationEvaluationMetrics", "google/cloud/automl/v1/translation.proto"],
|
33
|
+
["google.cloud.automl.v1.ImageObjectDetectionEvaluationMetrics", "google/cloud/automl/v1/detection.proto"],
|
34
|
+
["google.cloud.automl.v1.TextSentimentEvaluationMetrics", "google/cloud/automl/v1/text_sentiment.proto"],
|
35
|
+
["google.cloud.automl.v1.TextExtractionEvaluationMetrics", "google/cloud/automl/v1/text_extraction.proto"],
|
36
|
+
["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"],
|
37
|
+
]
|
38
|
+
imports.each do |type_name, expected_filename|
|
39
|
+
import_file = pool.lookup(type_name).file_descriptor
|
40
|
+
if import_file.name != expected_filename
|
41
|
+
warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}"
|
29
42
|
end
|
30
43
|
end
|
44
|
+
warn "Each proto file must use a consistent fully-qualified name."
|
45
|
+
warn "This will become an error in the next major version."
|
31
46
|
end
|
32
47
|
|
33
48
|
module Google
|
@@ -1,3 +1,4 @@
|
|
1
|
+
# frozen_string_literal: true
|
1
2
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
3
|
# source: google/cloud/automl/v1/model.proto
|
3
4
|
|
@@ -9,32 +10,35 @@ require 'google/cloud/automl/v1/text_pb'
|
|
9
10
|
require 'google/cloud/automl/v1/translation_pb'
|
10
11
|
require 'google/protobuf/timestamp_pb'
|
11
12
|
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
13
|
+
|
14
|
+
descriptor_data = "\n\"google/cloud/automl/v1/model.proto\x12\x16google.cloud.automl.v1\x1a\x19google/api/resource.proto\x1a\"google/cloud/automl/v1/image.proto\x1a!google/cloud/automl/v1/text.proto\x1a(google/cloud/automl/v1/translation.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xf1\x08\n\x05Model\x12V\n\x1atranslation_model_metadata\x18\x0f \x01(\x0b\x32\x30.google.cloud.automl.v1.TranslationModelMetadataH\x00\x12g\n#image_classification_model_metadata\x18\r \x01(\x0b\x32\x38.google.cloud.automl.v1.ImageClassificationModelMetadataH\x00\x12\x65\n\"text_classification_model_metadata\x18\x0e \x01(\x0b\x32\x37.google.cloud.automl.v1.TextClassificationModelMetadataH\x00\x12j\n%image_object_detection_model_metadata\x18\x14 \x01(\x0b\x32\x39.google.cloud.automl.v1.ImageObjectDetectionModelMetadataH\x00\x12]\n\x1etext_extraction_model_metadata\x18\x13 \x01(\x0b\x32\x33.google.cloud.automl.v1.TextExtractionModelMetadataH\x00\x12[\n\x1dtext_sentiment_model_metadata\x18\x16 \x01(\x0b\x32\x32.google.cloud.automl.v1.TextSentimentModelMetadataH\x00\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0c\x64isplay_name\x18\x02 \x01(\t\x12\x12\n\ndataset_id\x18\x03 \x01(\t\x12/\n\x0b\x63reate_time\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12/\n\x0bupdate_time\x18\x0b \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12G\n\x10\x64\x65ployment_state\x18\x08 \x01(\x0e\x32-.google.cloud.automl.v1.Model.DeploymentState\x12\x0c\n\x04\x65tag\x18\n \x01(\t\x12\x39\n\x06labels\x18\" \x03(\x0b\x32).google.cloud.automl.v1.Model.LabelsEntry\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"Q\n\x0f\x44\x65ploymentState\x12 \n\x1c\x44\x45PLOYMENT_STATE_UNSPECIFIED\x10\x00\x12\x0c\n\x08\x44\x45PLOYED\x10\x01\x12\x0e\n\nUNDEPLOYED\x10\x02:X\xea\x41U\n\x1b\x61utoml.googleapis.com/Model\x12\x36projects/{project}/locations/{location}/models/{model}B\x10\n\x0emodel_metadataB\xa0\x01\n\x1a\x63om.google.cloud.automl.v1P\x01Z2cloud.google.com/go/automl/apiv1/automlpb;automlpb\xaa\x02\x16Google.Cloud.AutoML.V1\xca\x02\x16Google\\Cloud\\AutoMl\\V1\xea\x02\x19Google::Cloud::AutoML::V1b\x06proto3"
|
15
|
+
|
16
|
+
pool = Google::Protobuf::DescriptorPool.generated_pool
|
17
|
+
|
18
|
+
begin
|
19
|
+
pool.add_serialized_file(descriptor_data)
|
20
|
+
rescue TypeError => e
|
21
|
+
# Compatibility code: will be removed in the next major version.
|
22
|
+
require 'google/protobuf/descriptor_pb'
|
23
|
+
parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data)
|
24
|
+
parsed.clear_dependency
|
25
|
+
serialized = parsed.class.encode(parsed)
|
26
|
+
file = pool.add_serialized_file(serialized)
|
27
|
+
warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}"
|
28
|
+
imports = [
|
29
|
+
["google.cloud.automl.v1.TranslationModelMetadata", "google/cloud/automl/v1/translation.proto"],
|
30
|
+
["google.cloud.automl.v1.ImageClassificationModelMetadata", "google/cloud/automl/v1/image.proto"],
|
31
|
+
["google.cloud.automl.v1.TextClassificationModelMetadata", "google/cloud/automl/v1/text.proto"],
|
32
|
+
["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"],
|
33
|
+
]
|
34
|
+
imports.each do |type_name, expected_filename|
|
35
|
+
import_file = pool.lookup(type_name).file_descriptor
|
36
|
+
if import_file.name != expected_filename
|
37
|
+
warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}"
|
36
38
|
end
|
37
39
|
end
|
40
|
+
warn "Each proto file must use a consistent fully-qualified name."
|
41
|
+
warn "This will become an error in the next major version."
|
38
42
|
end
|
39
43
|
|
40
44
|
module Google
|
@@ -1,3 +1,4 @@
|
|
1
|
+
# frozen_string_literal: true
|
1
2
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
3
|
# source: google/cloud/automl/v1/operations.proto
|
3
4
|
|
@@ -7,61 +8,34 @@ require 'google/cloud/automl/v1/io_pb'
|
|
7
8
|
require 'google/protobuf/timestamp_pb'
|
8
9
|
require 'google/rpc/status_pb'
|
9
10
|
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
end
|
35
|
-
add_message "google.cloud.automl.v1.CreateDatasetOperationMetadata" do
|
36
|
-
end
|
37
|
-
add_message "google.cloud.automl.v1.CreateModelOperationMetadata" do
|
38
|
-
end
|
39
|
-
add_message "google.cloud.automl.v1.ImportDataOperationMetadata" do
|
40
|
-
end
|
41
|
-
add_message "google.cloud.automl.v1.ExportDataOperationMetadata" do
|
42
|
-
optional :output_info, :message, 1, "google.cloud.automl.v1.ExportDataOperationMetadata.ExportDataOutputInfo"
|
43
|
-
end
|
44
|
-
add_message "google.cloud.automl.v1.ExportDataOperationMetadata.ExportDataOutputInfo" do
|
45
|
-
oneof :output_location do
|
46
|
-
optional :gcs_output_directory, :string, 1
|
47
|
-
end
|
48
|
-
end
|
49
|
-
add_message "google.cloud.automl.v1.BatchPredictOperationMetadata" do
|
50
|
-
optional :input_config, :message, 1, "google.cloud.automl.v1.BatchPredictInputConfig"
|
51
|
-
optional :output_info, :message, 2, "google.cloud.automl.v1.BatchPredictOperationMetadata.BatchPredictOutputInfo"
|
52
|
-
end
|
53
|
-
add_message "google.cloud.automl.v1.BatchPredictOperationMetadata.BatchPredictOutputInfo" do
|
54
|
-
oneof :output_location do
|
55
|
-
optional :gcs_output_directory, :string, 1
|
56
|
-
end
|
57
|
-
end
|
58
|
-
add_message "google.cloud.automl.v1.ExportModelOperationMetadata" do
|
59
|
-
optional :output_info, :message, 2, "google.cloud.automl.v1.ExportModelOperationMetadata.ExportModelOutputInfo"
|
60
|
-
end
|
61
|
-
add_message "google.cloud.automl.v1.ExportModelOperationMetadata.ExportModelOutputInfo" do
|
62
|
-
optional :gcs_output_directory, :string, 1
|
11
|
+
|
12
|
+
descriptor_data = "\n\'google/cloud/automl/v1/operations.proto\x12\x16google.cloud.automl.v1\x1a\x1fgoogle/cloud/automl/v1/io.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x17google/rpc/status.proto\"\xc9\x07\n\x11OperationMetadata\x12I\n\x0e\x64\x65lete_details\x18\x08 \x01(\x0b\x32/.google.cloud.automl.v1.DeleteOperationMetadataH\x00\x12T\n\x14\x64\x65ploy_model_details\x18\x18 \x01(\x0b\x32\x34.google.cloud.automl.v1.DeployModelOperationMetadataH\x00\x12X\n\x16undeploy_model_details\x18\x19 \x01(\x0b\x32\x36.google.cloud.automl.v1.UndeployModelOperationMetadataH\x00\x12T\n\x14\x63reate_model_details\x18\n \x01(\x0b\x32\x34.google.cloud.automl.v1.CreateModelOperationMetadataH\x00\x12X\n\x16\x63reate_dataset_details\x18\x1e \x01(\x0b\x32\x36.google.cloud.automl.v1.CreateDatasetOperationMetadataH\x00\x12R\n\x13import_data_details\x18\x0f \x01(\x0b\x32\x33.google.cloud.automl.v1.ImportDataOperationMetadataH\x00\x12V\n\x15\x62\x61tch_predict_details\x18\x10 \x01(\x0b\x32\x35.google.cloud.automl.v1.BatchPredictOperationMetadataH\x00\x12R\n\x13\x65xport_data_details\x18\x15 \x01(\x0b\x32\x33.google.cloud.automl.v1.ExportDataOperationMetadataH\x00\x12T\n\x14\x65xport_model_details\x18\x16 \x01(\x0b\x32\x34.google.cloud.automl.v1.ExportModelOperationMetadataH\x00\x12\x18\n\x10progress_percent\x18\r \x01(\x05\x12,\n\x10partial_failures\x18\x02 \x03(\x0b\x32\x12.google.rpc.Status\x12/\n\x0b\x63reate_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12/\n\x0bupdate_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\t\n\x07\x64\x65tails\"\x19\n\x17\x44\x65leteOperationMetadata\"\x1e\n\x1c\x44\x65ployModelOperationMetadata\" \n\x1eUndeployModelOperationMetadata\" \n\x1e\x43reateDatasetOperationMetadata\"\x1e\n\x1c\x43reateModelOperationMetadata\"\x1d\n\x1bImportDataOperationMetadata\"\xc7\x01\n\x1b\x45xportDataOperationMetadata\x12]\n\x0boutput_info\x18\x01 \x01(\x0b\x32H.google.cloud.automl.v1.ExportDataOperationMetadata.ExportDataOutputInfo\x1aI\n\x14\x45xportDataOutputInfo\x12\x1e\n\x14gcs_output_directory\x18\x01 \x01(\tH\x00\x42\x11\n\x0foutput_location\"\x96\x02\n\x1d\x42\x61tchPredictOperationMetadata\x12\x45\n\x0cinput_config\x18\x01 \x01(\x0b\x32/.google.cloud.automl.v1.BatchPredictInputConfig\x12\x61\n\x0boutput_info\x18\x02 \x01(\x0b\x32L.google.cloud.automl.v1.BatchPredictOperationMetadata.BatchPredictOutputInfo\x1aK\n\x16\x42\x61tchPredictOutputInfo\x12\x1e\n\x14gcs_output_directory\x18\x01 \x01(\tH\x00\x42\x11\n\x0foutput_location\"\xb6\x01\n\x1c\x45xportModelOperationMetadata\x12_\n\x0boutput_info\x18\x02 \x01(\x0b\x32J.google.cloud.automl.v1.ExportModelOperationMetadata.ExportModelOutputInfo\x1a\x35\n\x15\x45xportModelOutputInfo\x12\x1c\n\x14gcs_output_directory\x18\x01 \x01(\tB\xa0\x01\n\x1a\x63om.google.cloud.automl.v1P\x01Z2cloud.google.com/go/automl/apiv1/automlpb;automlpb\xaa\x02\x16Google.Cloud.AutoML.V1\xca\x02\x16Google\\Cloud\\AutoMl\\V1\xea\x02\x19Google::Cloud::AutoML::V1b\x06proto3"
|
13
|
+
|
14
|
+
pool = Google::Protobuf::DescriptorPool.generated_pool
|
15
|
+
|
16
|
+
begin
|
17
|
+
pool.add_serialized_file(descriptor_data)
|
18
|
+
rescue TypeError => e
|
19
|
+
# Compatibility code: will be removed in the next major version.
|
20
|
+
require 'google/protobuf/descriptor_pb'
|
21
|
+
parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data)
|
22
|
+
parsed.clear_dependency
|
23
|
+
serialized = parsed.class.encode(parsed)
|
24
|
+
file = pool.add_serialized_file(serialized)
|
25
|
+
warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}"
|
26
|
+
imports = [
|
27
|
+
["google.rpc.Status", "google/rpc/status.proto"],
|
28
|
+
["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"],
|
29
|
+
["google.cloud.automl.v1.BatchPredictInputConfig", "google/cloud/automl/v1/io.proto"],
|
30
|
+
]
|
31
|
+
imports.each do |type_name, expected_filename|
|
32
|
+
import_file = pool.lookup(type_name).file_descriptor
|
33
|
+
if import_file.name != expected_filename
|
34
|
+
warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}"
|
63
35
|
end
|
64
36
|
end
|
37
|
+
warn "Each proto file must use a consistent fully-qualified name."
|
38
|
+
warn "This will become an error in the next major version."
|
65
39
|
end
|
66
40
|
|
67
41
|
module Google
|
@@ -130,7 +130,7 @@ module Google
|
|
130
130
|
credentials = @config.credentials
|
131
131
|
# Use self-signed JWT if the endpoint is unchanged from default,
|
132
132
|
# but only if the default endpoint does not have a region prefix.
|
133
|
-
enable_self_signed_jwt = @config.endpoint ==
|
133
|
+
enable_self_signed_jwt = @config.endpoint == Configuration::DEFAULT_ENDPOINT &&
|
134
134
|
!@config.endpoint.split(".").first.include?("-")
|
135
135
|
credentials ||= Credentials.default scope: @config.scope,
|
136
136
|
enable_self_signed_jwt: enable_self_signed_jwt
|
@@ -151,7 +151,8 @@ module Google
|
|
151
151
|
credentials: credentials,
|
152
152
|
endpoint: @config.endpoint,
|
153
153
|
channel_args: @config.channel_args,
|
154
|
-
interceptors: @config.interceptors
|
154
|
+
interceptors: @config.interceptors,
|
155
|
+
channel_pool_config: @config.channel_pool
|
155
156
|
)
|
156
157
|
end
|
157
158
|
|
@@ -552,9 +553,9 @@ module Google
|
|
552
553
|
# * (`String`) The path to a service account key file in JSON format
|
553
554
|
# * (`Hash`) A service account key as a Hash
|
554
555
|
# * (`Google::Auth::Credentials`) A googleauth credentials object
|
555
|
-
# (see the [googleauth docs](https://
|
556
|
+
# (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
|
556
557
|
# * (`Signet::OAuth2::Client`) A signet oauth2 client object
|
557
|
-
# (see the [signet docs](https://
|
558
|
+
# (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
|
558
559
|
# * (`GRPC::Core::Channel`) a gRPC channel with included credentials
|
559
560
|
# * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
|
560
561
|
# * (`nil`) indicating no credentials
|
@@ -596,7 +597,9 @@ module Google
|
|
596
597
|
class Configuration
|
597
598
|
extend ::Gapic::Config
|
598
599
|
|
599
|
-
|
600
|
+
DEFAULT_ENDPOINT = "automl.googleapis.com"
|
601
|
+
|
602
|
+
config_attr :endpoint, DEFAULT_ENDPOINT, ::String
|
600
603
|
config_attr :credentials, nil do |value|
|
601
604
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
602
605
|
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|
@@ -631,6 +634,14 @@ module Google
|
|
631
634
|
end
|
632
635
|
end
|
633
636
|
|
637
|
+
##
|
638
|
+
# Configuration for the channel pool
|
639
|
+
# @return [::Gapic::ServiceStub::ChannelPool::Configuration]
|
640
|
+
#
|
641
|
+
def channel_pool
|
642
|
+
@channel_pool ||= ::Gapic::ServiceStub::ChannelPool::Configuration.new
|
643
|
+
end
|
644
|
+
|
634
645
|
##
|
635
646
|
# Configuration RPC class for the PredictionService API.
|
636
647
|
#
|
@@ -93,7 +93,8 @@ module Google
|
|
93
93
|
credentials: credentials,
|
94
94
|
endpoint: @config.endpoint,
|
95
95
|
channel_args: @config.channel_args,
|
96
|
-
interceptors: @config.interceptors
|
96
|
+
interceptors: @config.interceptors,
|
97
|
+
channel_pool_config: @config.channel_pool
|
97
98
|
)
|
98
99
|
|
99
100
|
# Used by an LRO wrapper for some methods of this service
|
@@ -628,9 +629,9 @@ module Google
|
|
628
629
|
# * (`String`) The path to a service account key file in JSON format
|
629
630
|
# * (`Hash`) A service account key as a Hash
|
630
631
|
# * (`Google::Auth::Credentials`) A googleauth credentials object
|
631
|
-
# (see the [googleauth docs](https://
|
632
|
+
# (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
|
632
633
|
# * (`Signet::OAuth2::Client`) A signet oauth2 client object
|
633
|
-
# (see the [signet docs](https://
|
634
|
+
# (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
|
634
635
|
# * (`GRPC::Core::Channel`) a gRPC channel with included credentials
|
635
636
|
# * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
|
636
637
|
# * (`nil`) indicating no credentials
|
@@ -672,7 +673,9 @@ module Google
|
|
672
673
|
class Configuration
|
673
674
|
extend ::Gapic::Config
|
674
675
|
|
675
|
-
|
676
|
+
DEFAULT_ENDPOINT = "automl.googleapis.com"
|
677
|
+
|
678
|
+
config_attr :endpoint, DEFAULT_ENDPOINT, ::String
|
676
679
|
config_attr :credentials, nil do |value|
|
677
680
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
678
681
|
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|
@@ -707,6 +710,14 @@ module Google
|
|
707
710
|
end
|
708
711
|
end
|
709
712
|
|
713
|
+
##
|
714
|
+
# Configuration for the channel pool
|
715
|
+
# @return [::Gapic::ServiceStub::ChannelPool::Configuration]
|
716
|
+
#
|
717
|
+
def channel_pool
|
718
|
+
@channel_pool ||= ::Gapic::ServiceStub::ChannelPool::Configuration.new
|
719
|
+
end
|
720
|
+
|
710
721
|
##
|
711
722
|
# Configuration RPC class for the Operations API.
|
712
723
|
#
|