google-cloud-video_intelligence 1.4.0 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/AUTHENTICATION.md +6 -28
- data/README.md +3 -3
- data/lib/google/cloud/video_intelligence.rb +1 -1
- data/lib/google/cloud/video_intelligence/v1.rb +1 -2
- data/lib/google/cloud/video_intelligence/v1/doc/google/cloud/videointelligence/v1/video_intelligence.rb +37 -34
- data/lib/google/cloud/video_intelligence/v1/video_intelligence_service_client.rb +14 -14
- data/lib/google/cloud/video_intelligence/v1/video_intelligence_service_client_config.json +7 -7
- data/lib/google/cloud/video_intelligence/version.rb +1 -1
- data/lib/google/cloud/videointelligence/v1/video_intelligence_pb.rb +5 -4
- metadata +9 -19
- data/lib/google/cloud/video_intelligence/v1beta1.rb +0 -149
- data/lib/google/cloud/video_intelligence/v1beta1/credentials.rb +0 -41
- data/lib/google/cloud/video_intelligence/v1beta1/doc/google/cloud/videointelligence/v1beta1/video_intelligence.rb +0 -322
- data/lib/google/cloud/video_intelligence/v1beta1/doc/google/longrunning/operations.rb +0 -51
- data/lib/google/cloud/video_intelligence/v1beta1/doc/google/protobuf/any.rb +0 -131
- data/lib/google/cloud/video_intelligence/v1beta1/doc/google/rpc/status.rb +0 -87
- data/lib/google/cloud/video_intelligence/v1beta1/video_intelligence_service_client.rb +0 -305
- data/lib/google/cloud/video_intelligence/v1beta1/video_intelligence_service_client_config.json +0 -31
- data/lib/google/cloud/videointelligence/v1beta1/video_intelligence_pb.rb +0 -141
- data/lib/google/cloud/videointelligence/v1beta1/video_intelligence_services_pb.rb +0 -50
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-video_intelligence
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 2.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Google LLC
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-10-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: google-gax
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '1.
|
19
|
+
version: '1.8'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '1.
|
26
|
+
version: '1.8'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: minitest
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -53,19 +53,19 @@ dependencies:
|
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '3.0'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
|
-
name:
|
56
|
+
name: google-style
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version:
|
61
|
+
version: 1.24.0
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version:
|
68
|
+
version: 1.24.0
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: simplecov
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -116,14 +116,6 @@ files:
|
|
116
116
|
- lib/google/cloud/video_intelligence/v1/doc/google/rpc/status.rb
|
117
117
|
- lib/google/cloud/video_intelligence/v1/video_intelligence_service_client.rb
|
118
118
|
- lib/google/cloud/video_intelligence/v1/video_intelligence_service_client_config.json
|
119
|
-
- lib/google/cloud/video_intelligence/v1beta1.rb
|
120
|
-
- lib/google/cloud/video_intelligence/v1beta1/credentials.rb
|
121
|
-
- lib/google/cloud/video_intelligence/v1beta1/doc/google/cloud/videointelligence/v1beta1/video_intelligence.rb
|
122
|
-
- lib/google/cloud/video_intelligence/v1beta1/doc/google/longrunning/operations.rb
|
123
|
-
- lib/google/cloud/video_intelligence/v1beta1/doc/google/protobuf/any.rb
|
124
|
-
- lib/google/cloud/video_intelligence/v1beta1/doc/google/rpc/status.rb
|
125
|
-
- lib/google/cloud/video_intelligence/v1beta1/video_intelligence_service_client.rb
|
126
|
-
- lib/google/cloud/video_intelligence/v1beta1/video_intelligence_service_client_config.json
|
127
119
|
- lib/google/cloud/video_intelligence/v1beta2.rb
|
128
120
|
- lib/google/cloud/video_intelligence/v1beta2/credentials.rb
|
129
121
|
- lib/google/cloud/video_intelligence/v1beta2/doc/google/cloud/videointelligence/v1beta2/video_intelligence.rb
|
@@ -154,8 +146,6 @@ files:
|
|
154
146
|
- lib/google/cloud/video_intelligence/version.rb
|
155
147
|
- lib/google/cloud/videointelligence/v1/video_intelligence_pb.rb
|
156
148
|
- lib/google/cloud/videointelligence/v1/video_intelligence_services_pb.rb
|
157
|
-
- lib/google/cloud/videointelligence/v1beta1/video_intelligence_pb.rb
|
158
|
-
- lib/google/cloud/videointelligence/v1beta1/video_intelligence_services_pb.rb
|
159
149
|
- lib/google/cloud/videointelligence/v1beta2/video_intelligence_pb.rb
|
160
150
|
- lib/google/cloud/videointelligence/v1beta2/video_intelligence_services_pb.rb
|
161
151
|
- lib/google/cloud/videointelligence/v1p1beta1/video_intelligence_pb.rb
|
@@ -174,14 +164,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
174
164
|
requirements:
|
175
165
|
- - ">="
|
176
166
|
- !ruby/object:Gem::Version
|
177
|
-
version: 2.
|
167
|
+
version: '2.4'
|
178
168
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
179
169
|
requirements:
|
180
170
|
- - ">="
|
181
171
|
- !ruby/object:Gem::Version
|
182
172
|
version: '0'
|
183
173
|
requirements: []
|
184
|
-
rubygems_version: 3.0.
|
174
|
+
rubygems_version: 3.0.6
|
185
175
|
signing_key:
|
186
176
|
specification_version: 4
|
187
177
|
summary: API Client library for Cloud Video Intelligence API
|
@@ -1,149 +0,0 @@
|
|
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
|
-
# https://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
|
-
|
16
|
-
require "google/cloud/video_intelligence/v1beta1/video_intelligence_service_client"
|
17
|
-
require "google/cloud/videointelligence/v1beta1/video_intelligence_pb"
|
18
|
-
require "google/rpc/status_pb"
|
19
|
-
|
20
|
-
module Google
|
21
|
-
module Cloud
|
22
|
-
module VideoIntelligence
|
23
|
-
# rubocop:disable LineLength
|
24
|
-
|
25
|
-
##
|
26
|
-
# # Ruby Client for Google Cloud Video Intelligence API ([GA](https://github.com/googleapis/google-cloud-ruby#versioning))
|
27
|
-
#
|
28
|
-
# [Google Cloud Video Intelligence API][Product Documentation]:
|
29
|
-
# Detects objects, explicit content, and scene changes in videos. It also
|
30
|
-
# specifies the region for annotation and transcribes speech to text.
|
31
|
-
# Supports both asynchronous API and streaming API.
|
32
|
-
# - [Product Documentation][]
|
33
|
-
#
|
34
|
-
# ## Quick Start
|
35
|
-
# In order to use this library, you first need to go through the following
|
36
|
-
# steps:
|
37
|
-
#
|
38
|
-
# 1. [Select or create a Cloud Platform project.](https://console.cloud.google.com/project)
|
39
|
-
# 2. [Enable billing for your project.](https://cloud.google.com/billing/docs/how-to/modify-project#enable_billing_for_a_project)
|
40
|
-
# 3. [Enable the Google Cloud Video Intelligence API.](https://console.cloud.google.com/apis/library/videointelligence.googleapis.com)
|
41
|
-
# 4. [Setup Authentication.](https://googleapis.dev/ruby/google-cloud-video_intelligence/latest/file.AUTHENTICATION.html)
|
42
|
-
#
|
43
|
-
# ### Installation
|
44
|
-
# ```
|
45
|
-
# $ gem install google-cloud-video_intelligence
|
46
|
-
# ```
|
47
|
-
#
|
48
|
-
# ### Next Steps
|
49
|
-
# - Read the [Google Cloud Video Intelligence API Product documentation][Product Documentation]
|
50
|
-
# to learn more about the product and see How-to Guides.
|
51
|
-
# - View this [repository's main README](https://github.com/googleapis/google-cloud-ruby/blob/master/README.md)
|
52
|
-
# to see the full list of Cloud APIs that we cover.
|
53
|
-
#
|
54
|
-
# [Product Documentation]: https://cloud.google.com/video-intelligence
|
55
|
-
#
|
56
|
-
# ## Enabling Logging
|
57
|
-
#
|
58
|
-
# To enable logging for this library, set the logger for the underlying [gRPC](https://github.com/grpc/grpc/tree/master/src/ruby) library.
|
59
|
-
# The logger that you set may be a Ruby stdlib [`Logger`](https://ruby-doc.org/stdlib-2.5.0/libdoc/logger/rdoc/Logger.html) as shown below,
|
60
|
-
# or a [`Google::Cloud::Logging::Logger`](https://googleapis.dev/ruby/google-cloud-logging/latest)
|
61
|
-
# that will write logs to [Stackdriver Logging](https://cloud.google.com/logging/). See [grpc/logconfig.rb](https://github.com/grpc/grpc/blob/master/src/ruby/lib/grpc/logconfig.rb)
|
62
|
-
# and the gRPC [spec_helper.rb](https://github.com/grpc/grpc/blob/master/src/ruby/spec/spec_helper.rb) for additional information.
|
63
|
-
#
|
64
|
-
# Configuring a Ruby stdlib logger:
|
65
|
-
#
|
66
|
-
# ```ruby
|
67
|
-
# require "logger"
|
68
|
-
#
|
69
|
-
# module MyLogger
|
70
|
-
# LOGGER = Logger.new $stderr, level: Logger::WARN
|
71
|
-
# def logger
|
72
|
-
# LOGGER
|
73
|
-
# end
|
74
|
-
# end
|
75
|
-
#
|
76
|
-
# # Define a gRPC module-level logger method before grpc/logconfig.rb loads.
|
77
|
-
# module GRPC
|
78
|
-
# extend MyLogger
|
79
|
-
# end
|
80
|
-
# ```
|
81
|
-
#
|
82
|
-
module V1beta1
|
83
|
-
# rubocop:enable LineLength
|
84
|
-
|
85
|
-
##
|
86
|
-
# Service that implements Google Cloud Video Intelligence API.
|
87
|
-
#
|
88
|
-
# @param credentials [Google::Auth::Credentials, String, Hash, GRPC::Core::Channel, GRPC::Core::ChannelCredentials, Proc]
|
89
|
-
# Provides the means for authenticating requests made by the client. This parameter can
|
90
|
-
# be many types.
|
91
|
-
# A `Google::Auth::Credentials` uses a the properties of its represented keyfile for
|
92
|
-
# authenticating requests made by this client.
|
93
|
-
# A `String` will be treated as the path to the keyfile to be used for the construction of
|
94
|
-
# credentials for this client.
|
95
|
-
# A `Hash` will be treated as the contents of a keyfile to be used for the construction of
|
96
|
-
# credentials for this client.
|
97
|
-
# A `GRPC::Core::Channel` will be used to make calls through.
|
98
|
-
# A `GRPC::Core::ChannelCredentials` for the setting up the RPC client. The channel credentials
|
99
|
-
# should already be composed with a `GRPC::Core::CallCredentials` object.
|
100
|
-
# A `Proc` will be used as an updater_proc for the Grpc channel. The proc transforms the
|
101
|
-
# metadata for requests, generally, to give OAuth credentials.
|
102
|
-
# @param scopes [Array<String>]
|
103
|
-
# The OAuth scopes for this service. This parameter is ignored if
|
104
|
-
# an updater_proc is supplied.
|
105
|
-
# @param client_config [Hash]
|
106
|
-
# A Hash for call options for each method. See
|
107
|
-
# Google::Gax#construct_settings for the structure of
|
108
|
-
# this data. Falls back to the default config if not specified
|
109
|
-
# or the specified config is missing data points.
|
110
|
-
# @param timeout [Numeric]
|
111
|
-
# The default timeout, in seconds, for calls made through this client.
|
112
|
-
# @param metadata [Hash]
|
113
|
-
# Default metadata to be sent with each request. This can be overridden on a per call basis.
|
114
|
-
# @param service_address [String]
|
115
|
-
# Override for the service hostname, or `nil` to leave as the default.
|
116
|
-
# @param service_port [Integer]
|
117
|
-
# Override for the service port, or `nil` to leave as the default.
|
118
|
-
# @param exception_transformer [Proc]
|
119
|
-
# An optional proc that intercepts any exceptions raised during an API call to inject
|
120
|
-
# custom error handling.
|
121
|
-
def self.new \
|
122
|
-
credentials: nil,
|
123
|
-
scopes: nil,
|
124
|
-
client_config: nil,
|
125
|
-
timeout: nil,
|
126
|
-
metadata: nil,
|
127
|
-
service_address: nil,
|
128
|
-
service_port: nil,
|
129
|
-
exception_transformer: nil,
|
130
|
-
lib_name: nil,
|
131
|
-
lib_version: nil
|
132
|
-
kwargs = {
|
133
|
-
credentials: credentials,
|
134
|
-
scopes: scopes,
|
135
|
-
client_config: client_config,
|
136
|
-
timeout: timeout,
|
137
|
-
metadata: metadata,
|
138
|
-
exception_transformer: exception_transformer,
|
139
|
-
lib_name: lib_name,
|
140
|
-
service_address: service_address,
|
141
|
-
service_port: service_port,
|
142
|
-
lib_version: lib_version
|
143
|
-
}.select { |_, v| v != nil }
|
144
|
-
Google::Cloud::VideoIntelligence::V1beta1::VideoIntelligenceServiceClient.new(**kwargs)
|
145
|
-
end
|
146
|
-
end
|
147
|
-
end
|
148
|
-
end
|
149
|
-
end
|
@@ -1,41 +0,0 @@
|
|
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
|
-
# https://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
|
-
|
16
|
-
require "googleauth"
|
17
|
-
|
18
|
-
module Google
|
19
|
-
module Cloud
|
20
|
-
module VideoIntelligence
|
21
|
-
module V1beta1
|
22
|
-
class Credentials < Google::Auth::Credentials
|
23
|
-
SCOPE = [
|
24
|
-
"https://www.googleapis.com/auth/cloud-platform"
|
25
|
-
].freeze
|
26
|
-
PATH_ENV_VARS = %w(VIDEO_INTELLIGENCE_CREDENTIALS
|
27
|
-
VIDEO_INTELLIGENCE_KEYFILE
|
28
|
-
GOOGLE_CLOUD_CREDENTIALS
|
29
|
-
GOOGLE_CLOUD_KEYFILE
|
30
|
-
GCLOUD_KEYFILE)
|
31
|
-
JSON_ENV_VARS = %w(VIDEO_INTELLIGENCE_CREDENTIALS_JSON
|
32
|
-
VIDEO_INTELLIGENCE_KEYFILE_JSON
|
33
|
-
GOOGLE_CLOUD_CREDENTIALS_JSON
|
34
|
-
GOOGLE_CLOUD_KEYFILE_JSON
|
35
|
-
GCLOUD_KEYFILE_JSON)
|
36
|
-
DEFAULT_PATHS = ["~/.config/gcloud/application_default_credentials.json"]
|
37
|
-
end
|
38
|
-
end
|
39
|
-
end
|
40
|
-
end
|
41
|
-
end
|
@@ -1,322 +0,0 @@
|
|
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
|
-
# https://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
|
-
|
16
|
-
module Google
|
17
|
-
module Cloud
|
18
|
-
module VideoIntelligence
|
19
|
-
module V1beta1
|
20
|
-
# Video annotation request.
|
21
|
-
# @!attribute [rw] input_uri
|
22
|
-
# @return [String]
|
23
|
-
# Input video location. Currently, only
|
24
|
-
# [Google Cloud Storage](https://cloud.google.com/storage/) URIs are
|
25
|
-
# supported, which must be specified in the following format:
|
26
|
-
# `gs://bucket-id/object-id` (other URI formats return
|
27
|
-
# {Google::Rpc::Code::INVALID_ARGUMENT}). For
|
28
|
-
# more information, see [Request URIs](https://cloud.google.com/storage/docs/reference-uris). A video
|
29
|
-
# URI may include wildcards in `object-id`, and thus identify multiple
|
30
|
-
# videos. Supported wildcards: '*' to match 0 or more characters;
|
31
|
-
# '?' to match 1 character. If unset, the input video should be embedded
|
32
|
-
# in the request as `input_content`. If set, `input_content` should be unset.
|
33
|
-
# @!attribute [rw] input_content
|
34
|
-
# @return [String]
|
35
|
-
# The video data bytes. Encoding: base64. If unset, the input video(s)
|
36
|
-
# should be specified via `input_uri`. If set, `input_uri` should be unset.
|
37
|
-
# @!attribute [rw] features
|
38
|
-
# @return [Array<Google::Cloud::VideoIntelligence::V1beta1::Feature>]
|
39
|
-
# Requested video annotation features.
|
40
|
-
# @!attribute [rw] video_context
|
41
|
-
# @return [Google::Cloud::VideoIntelligence::V1beta1::VideoContext]
|
42
|
-
# Additional video context and/or feature-specific parameters.
|
43
|
-
# @!attribute [rw] output_uri
|
44
|
-
# @return [String]
|
45
|
-
# Optional location where the output (in JSON format) should be stored.
|
46
|
-
# Currently, only [Google Cloud Storage](https://cloud.google.com/storage/)
|
47
|
-
# URIs are supported, which must be specified in the following format:
|
48
|
-
# `gs://bucket-id/object-id` (other URI formats return
|
49
|
-
# {Google::Rpc::Code::INVALID_ARGUMENT}). For
|
50
|
-
# more information, see [Request URIs](https://cloud.google.com/storage/docs/reference-uris).
|
51
|
-
# @!attribute [rw] location_id
|
52
|
-
# @return [String]
|
53
|
-
# Optional cloud region where annotation should take place. Supported cloud
|
54
|
-
# regions: `us-east1`, `us-west1`, `europe-west1`, `asia-east1`. If no region
|
55
|
-
# is specified, a region will be determined based on video file location.
|
56
|
-
class AnnotateVideoRequest; end
|
57
|
-
|
58
|
-
# Video context and/or feature-specific parameters.
|
59
|
-
# @!attribute [rw] segments
|
60
|
-
# @return [Array<Google::Cloud::VideoIntelligence::V1beta1::VideoSegment>]
|
61
|
-
# Video segments to annotate. The segments may overlap and are not required
|
62
|
-
# to be contiguous or span the whole video. If unspecified, each video
|
63
|
-
# is treated as a single segment.
|
64
|
-
# @!attribute [rw] label_detection_mode
|
65
|
-
# @return [Google::Cloud::VideoIntelligence::V1beta1::LabelDetectionMode]
|
66
|
-
# If label detection has been requested, what labels should be detected
|
67
|
-
# in addition to video-level labels or segment-level labels. If unspecified,
|
68
|
-
# defaults to `SHOT_MODE`.
|
69
|
-
# @!attribute [rw] stationary_camera
|
70
|
-
# @return [true, false]
|
71
|
-
# Whether the video has been shot from a stationary (i.e. non-moving) camera.
|
72
|
-
# When set to true, might improve detection accuracy for moving objects.
|
73
|
-
# @!attribute [rw] label_detection_model
|
74
|
-
# @return [String]
|
75
|
-
# Model to use for label detection.
|
76
|
-
# Supported values: "latest" and "stable" (the default).
|
77
|
-
# @!attribute [rw] face_detection_model
|
78
|
-
# @return [String]
|
79
|
-
# Model to use for face detection.
|
80
|
-
# Supported values: "latest" and "stable" (the default).
|
81
|
-
# @!attribute [rw] shot_change_detection_model
|
82
|
-
# @return [String]
|
83
|
-
# Model to use for shot change detection.
|
84
|
-
# Supported values: "latest" and "stable" (the default).
|
85
|
-
# @!attribute [rw] safe_search_detection_model
|
86
|
-
# @return [String]
|
87
|
-
# Model to use for safe search detection.
|
88
|
-
# Supported values: "latest" and "stable" (the default).
|
89
|
-
class VideoContext; end
|
90
|
-
|
91
|
-
# Video segment.
|
92
|
-
# @!attribute [rw] start_time_offset
|
93
|
-
# @return [Integer]
|
94
|
-
# Start offset in microseconds (inclusive). Unset means 0.
|
95
|
-
# @!attribute [rw] end_time_offset
|
96
|
-
# @return [Integer]
|
97
|
-
# End offset in microseconds (inclusive). Unset means 0.
|
98
|
-
class VideoSegment; end
|
99
|
-
|
100
|
-
# Label location.
|
101
|
-
# @!attribute [rw] segment
|
102
|
-
# @return [Google::Cloud::VideoIntelligence::V1beta1::VideoSegment]
|
103
|
-
# Video segment. Set to [-1, -1] for video-level labels.
|
104
|
-
# Set to [timestamp, timestamp] for frame-level labels.
|
105
|
-
# Otherwise, corresponds to one of `AnnotateSpec.segments`
|
106
|
-
# (if specified) or to shot boundaries (if requested).
|
107
|
-
# @!attribute [rw] confidence
|
108
|
-
# @return [Float]
|
109
|
-
# Confidence that the label is accurate. Range: [0, 1].
|
110
|
-
# @!attribute [rw] level
|
111
|
-
# @return [Google::Cloud::VideoIntelligence::V1beta1::LabelLevel]
|
112
|
-
# Label level.
|
113
|
-
class LabelLocation; end
|
114
|
-
|
115
|
-
# Label annotation.
|
116
|
-
# @!attribute [rw] description
|
117
|
-
# @return [String]
|
118
|
-
# Textual description, e.g. `Fixed-gear bicycle`.
|
119
|
-
# @!attribute [rw] language_code
|
120
|
-
# @return [String]
|
121
|
-
# Language code for `description` in BCP-47 format.
|
122
|
-
# @!attribute [rw] locations
|
123
|
-
# @return [Array<Google::Cloud::VideoIntelligence::V1beta1::LabelLocation>]
|
124
|
-
# Where the label was detected and with what confidence.
|
125
|
-
class LabelAnnotation; end
|
126
|
-
|
127
|
-
# Safe search annotation (based on per-frame visual signals only).
|
128
|
-
# If no unsafe content has been detected in a frame, no annotations
|
129
|
-
# are present for that frame. If only some types of unsafe content
|
130
|
-
# have been detected in a frame, the likelihood is set to `UNKNOWN`
|
131
|
-
# for all other types of unsafe content.
|
132
|
-
# @!attribute [rw] adult
|
133
|
-
# @return [Google::Cloud::VideoIntelligence::V1beta1::Likelihood]
|
134
|
-
# Likelihood of adult content.
|
135
|
-
# @!attribute [rw] spoof
|
136
|
-
# @return [Google::Cloud::VideoIntelligence::V1beta1::Likelihood]
|
137
|
-
# Likelihood that an obvious modification was made to the original
|
138
|
-
# version to make it appear funny or offensive.
|
139
|
-
# @!attribute [rw] medical
|
140
|
-
# @return [Google::Cloud::VideoIntelligence::V1beta1::Likelihood]
|
141
|
-
# Likelihood of medical content.
|
142
|
-
# @!attribute [rw] violent
|
143
|
-
# @return [Google::Cloud::VideoIntelligence::V1beta1::Likelihood]
|
144
|
-
# Likelihood of violent content.
|
145
|
-
# @!attribute [rw] racy
|
146
|
-
# @return [Google::Cloud::VideoIntelligence::V1beta1::Likelihood]
|
147
|
-
# Likelihood of racy content.
|
148
|
-
# @!attribute [rw] time_offset
|
149
|
-
# @return [Integer]
|
150
|
-
# Video time offset in microseconds.
|
151
|
-
class SafeSearchAnnotation; end
|
152
|
-
|
153
|
-
# Bounding box.
|
154
|
-
# @!attribute [rw] left
|
155
|
-
# @return [Integer]
|
156
|
-
# Left X coordinate.
|
157
|
-
# @!attribute [rw] right
|
158
|
-
# @return [Integer]
|
159
|
-
# Right X coordinate.
|
160
|
-
# @!attribute [rw] bottom
|
161
|
-
# @return [Integer]
|
162
|
-
# Bottom Y coordinate.
|
163
|
-
# @!attribute [rw] top
|
164
|
-
# @return [Integer]
|
165
|
-
# Top Y coordinate.
|
166
|
-
class BoundingBox; end
|
167
|
-
|
168
|
-
# Face location.
|
169
|
-
# @!attribute [rw] bounding_box
|
170
|
-
# @return [Google::Cloud::VideoIntelligence::V1beta1::BoundingBox]
|
171
|
-
# Bounding box in a frame.
|
172
|
-
# @!attribute [rw] time_offset
|
173
|
-
# @return [Integer]
|
174
|
-
# Video time offset in microseconds.
|
175
|
-
class FaceLocation; end
|
176
|
-
|
177
|
-
# Face annotation.
|
178
|
-
# @!attribute [rw] thumbnail
|
179
|
-
# @return [String]
|
180
|
-
# Thumbnail of a representative face view (in JPEG format). Encoding: base64.
|
181
|
-
# @!attribute [rw] segments
|
182
|
-
# @return [Array<Google::Cloud::VideoIntelligence::V1beta1::VideoSegment>]
|
183
|
-
# All locations where a face was detected.
|
184
|
-
# Faces are detected and tracked on a per-video basis
|
185
|
-
# (as opposed to across multiple videos).
|
186
|
-
# @!attribute [rw] locations
|
187
|
-
# @return [Array<Google::Cloud::VideoIntelligence::V1beta1::FaceLocation>]
|
188
|
-
# Face locations at one frame per second.
|
189
|
-
class FaceAnnotation; end
|
190
|
-
|
191
|
-
# Annotation results for a single video.
|
192
|
-
# @!attribute [rw] input_uri
|
193
|
-
# @return [String]
|
194
|
-
# Video file location in
|
195
|
-
# [Google Cloud Storage](https://cloud.google.com/storage/).
|
196
|
-
# @!attribute [rw] label_annotations
|
197
|
-
# @return [Array<Google::Cloud::VideoIntelligence::V1beta1::LabelAnnotation>]
|
198
|
-
# Label annotations. There is exactly one element for each unique label.
|
199
|
-
# @!attribute [rw] face_annotations
|
200
|
-
# @return [Array<Google::Cloud::VideoIntelligence::V1beta1::FaceAnnotation>]
|
201
|
-
# Face annotations. There is exactly one element for each unique face.
|
202
|
-
# @!attribute [rw] shot_annotations
|
203
|
-
# @return [Array<Google::Cloud::VideoIntelligence::V1beta1::VideoSegment>]
|
204
|
-
# Shot annotations. Each shot is represented as a video segment.
|
205
|
-
# @!attribute [rw] safe_search_annotations
|
206
|
-
# @return [Array<Google::Cloud::VideoIntelligence::V1beta1::SafeSearchAnnotation>]
|
207
|
-
# Safe search annotations.
|
208
|
-
# @!attribute [rw] error
|
209
|
-
# @return [Google::Rpc::Status]
|
210
|
-
# If set, indicates an error. Note that for a single `AnnotateVideoRequest`
|
211
|
-
# some videos may succeed and some may fail.
|
212
|
-
class VideoAnnotationResults; end
|
213
|
-
|
214
|
-
# Video annotation response. Included in the `response`
|
215
|
-
# field of the `Operation` returned by the `GetOperation`
|
216
|
-
# call of the `google::longrunning::Operations` service.
|
217
|
-
# @!attribute [rw] annotation_results
|
218
|
-
# @return [Array<Google::Cloud::VideoIntelligence::V1beta1::VideoAnnotationResults>]
|
219
|
-
# Annotation results for all videos specified in `AnnotateVideoRequest`.
|
220
|
-
class AnnotateVideoResponse; end
|
221
|
-
|
222
|
-
# Annotation progress for a single video.
|
223
|
-
# @!attribute [rw] input_uri
|
224
|
-
# @return [String]
|
225
|
-
# Video file location in
|
226
|
-
# [Google Cloud Storage](https://cloud.google.com/storage/).
|
227
|
-
# @!attribute [rw] progress_percent
|
228
|
-
# @return [Integer]
|
229
|
-
# Approximate percentage processed thus far.
|
230
|
-
# Guaranteed to be 100 when fully processed.
|
231
|
-
# @!attribute [rw] start_time
|
232
|
-
# @return [Google::Protobuf::Timestamp]
|
233
|
-
# Time when the request was received.
|
234
|
-
# @!attribute [rw] update_time
|
235
|
-
# @return [Google::Protobuf::Timestamp]
|
236
|
-
# Time of the most recent update.
|
237
|
-
class VideoAnnotationProgress; end
|
238
|
-
|
239
|
-
# Video annotation progress. Included in the `metadata`
|
240
|
-
# field of the `Operation` returned by the `GetOperation`
|
241
|
-
# call of the `google::longrunning::Operations` service.
|
242
|
-
# @!attribute [rw] annotation_progress
|
243
|
-
# @return [Array<Google::Cloud::VideoIntelligence::V1beta1::VideoAnnotationProgress>]
|
244
|
-
# Progress metadata for all videos specified in `AnnotateVideoRequest`.
|
245
|
-
class AnnotateVideoProgress; end
|
246
|
-
|
247
|
-
# Video annotation feature.
|
248
|
-
module Feature
|
249
|
-
# Unspecified.
|
250
|
-
FEATURE_UNSPECIFIED = 0
|
251
|
-
|
252
|
-
# Label detection. Detect objects, such as dog or flower.
|
253
|
-
LABEL_DETECTION = 1
|
254
|
-
|
255
|
-
# Human face detection and tracking.
|
256
|
-
FACE_DETECTION = 2
|
257
|
-
|
258
|
-
# Shot change detection.
|
259
|
-
SHOT_CHANGE_DETECTION = 3
|
260
|
-
|
261
|
-
# Safe search detection.
|
262
|
-
SAFE_SEARCH_DETECTION = 4
|
263
|
-
end
|
264
|
-
|
265
|
-
# Label detection mode.
|
266
|
-
module LabelDetectionMode
|
267
|
-
# Unspecified.
|
268
|
-
LABEL_DETECTION_MODE_UNSPECIFIED = 0
|
269
|
-
|
270
|
-
# Detect shot-level labels.
|
271
|
-
SHOT_MODE = 1
|
272
|
-
|
273
|
-
# Detect frame-level labels.
|
274
|
-
FRAME_MODE = 2
|
275
|
-
|
276
|
-
# Detect both shot-level and frame-level labels.
|
277
|
-
SHOT_AND_FRAME_MODE = 3
|
278
|
-
end
|
279
|
-
|
280
|
-
# Label level (scope).
|
281
|
-
module LabelLevel
|
282
|
-
# Unspecified.
|
283
|
-
LABEL_LEVEL_UNSPECIFIED = 0
|
284
|
-
|
285
|
-
# Video-level. Corresponds to the whole video.
|
286
|
-
VIDEO_LEVEL = 1
|
287
|
-
|
288
|
-
# Segment-level. Corresponds to one of `AnnotateSpec.segments`.
|
289
|
-
SEGMENT_LEVEL = 2
|
290
|
-
|
291
|
-
# Shot-level. Corresponds to a single shot (i.e. a series of frames
|
292
|
-
# without a major camera position or background change).
|
293
|
-
SHOT_LEVEL = 3
|
294
|
-
|
295
|
-
# Frame-level. Corresponds to a single video frame.
|
296
|
-
FRAME_LEVEL = 4
|
297
|
-
end
|
298
|
-
|
299
|
-
# Bucketized representation of likelihood.
|
300
|
-
module Likelihood
|
301
|
-
# Unknown likelihood.
|
302
|
-
UNKNOWN = 0
|
303
|
-
|
304
|
-
# Very unlikely.
|
305
|
-
VERY_UNLIKELY = 1
|
306
|
-
|
307
|
-
# Unlikely.
|
308
|
-
UNLIKELY = 2
|
309
|
-
|
310
|
-
# Possible.
|
311
|
-
POSSIBLE = 3
|
312
|
-
|
313
|
-
# Likely.
|
314
|
-
LIKELY = 4
|
315
|
-
|
316
|
-
# Very likely.
|
317
|
-
VERY_LIKELY = 5
|
318
|
-
end
|
319
|
-
end
|
320
|
-
end
|
321
|
-
end
|
322
|
-
end
|