1 // Copyright 2024 Google LLC. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 // Code generated file. DO NOT EDIT. 6 7 // Package videointelligence provides access to the Cloud Video Intelligence API. 8 // 9 // This package is DEPRECATED. Use package cloud.google.com/go/videointelligence/apiv1 instead. 10 // 11 // For product documentation, see: https://cloud.google.com/video-intelligence/docs/ 12 // 13 // # Library status 14 // 15 // These client libraries are officially supported by Google. However, this 16 // library is considered complete and is in maintenance mode. This means 17 // that we will address critical bugs and security issues but will not add 18 // any new features. 19 // 20 // When possible, we recommend using our newer 21 // [Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go) 22 // that are still actively being worked and iterated on. 23 // 24 // # Creating a client 25 // 26 // Usage example: 27 // 28 // import "google.golang.org/api/videointelligence/v1" 29 // ... 30 // ctx := context.Background() 31 // videointelligenceService, err := videointelligence.NewService(ctx) 32 // 33 // In this example, Google Application Default Credentials are used for 34 // authentication. For information on how to create and obtain Application 35 // Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials. 36 // 37 // # Other authentication options 38 // 39 // To use an API key for authentication (note: some APIs do not support API 40 // keys), use [google.golang.org/api/option.WithAPIKey]: 41 // 42 // videointelligenceService, err := videointelligence.NewService(ctx, option.WithAPIKey("AIza...")) 43 // 44 // To use an OAuth token (e.g., a user token obtained via a three-legged OAuth 45 // flow, use [google.golang.org/api/option.WithTokenSource]: 46 // 47 // config := &oauth2.Config{...} 48 // // ... 49 // token, err := config.Exchange(ctx, ...) 50 // videointelligenceService, err := videointelligence.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token))) 51 // 52 // See [google.golang.org/api/option.ClientOption] for details on options. 53 package videointelligence // import "google.golang.org/api/videointelligence/v1" 54 55 import ( 56 "bytes" 57 "context" 58 "encoding/json" 59 "errors" 60 "fmt" 61 "io" 62 "net/http" 63 "net/url" 64 "strconv" 65 "strings" 66 67 googleapi "google.golang.org/api/googleapi" 68 internal "google.golang.org/api/internal" 69 gensupport "google.golang.org/api/internal/gensupport" 70 option "google.golang.org/api/option" 71 internaloption "google.golang.org/api/option/internaloption" 72 htransport "google.golang.org/api/transport/http" 73 ) 74 75 // Always reference these packages, just in case the auto-generated code 76 // below doesn't. 77 var _ = bytes.NewBuffer 78 var _ = strconv.Itoa 79 var _ = fmt.Sprintf 80 var _ = json.NewDecoder 81 var _ = io.Copy 82 var _ = url.Parse 83 var _ = gensupport.MarshalJSON 84 var _ = googleapi.Version 85 var _ = errors.New 86 var _ = strings.Replace 87 var _ = context.Canceled 88 var _ = internaloption.WithDefaultEndpoint 89 var _ = internal.Version 90 91 const apiId = "videointelligence:v1" 92 const apiName = "videointelligence" 93 const apiVersion = "v1" 94 const basePath = "https://videointelligence.googleapis.com/" 95 const basePathTemplate = "https://videointelligence.UNIVERSE_DOMAIN/" 96 const mtlsBasePath = "https://videointelligence.mtls.googleapis.com/" 97 98 // OAuth2 scopes used by this API. 99 const ( 100 // See, edit, configure, and delete your Google Cloud data and see the email 101 // address for your Google Account. 102 CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform" 103 ) 104 105 // NewService creates a new Service. 106 func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) { 107 scopesOption := internaloption.WithDefaultScopes( 108 "https://www.googleapis.com/auth/cloud-platform", 109 ) 110 // NOTE: prepend, so we don't override user-specified scopes. 111 opts = append([]option.ClientOption{scopesOption}, opts...) 112 opts = append(opts, internaloption.WithDefaultEndpoint(basePath)) 113 opts = append(opts, internaloption.WithDefaultEndpointTemplate(basePathTemplate)) 114 opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath)) 115 opts = append(opts, internaloption.EnableNewAuthLibrary()) 116 client, endpoint, err := htransport.NewClient(ctx, opts...) 117 if err != nil { 118 return nil, err 119 } 120 s, err := New(client) 121 if err != nil { 122 return nil, err 123 } 124 if endpoint != "" { 125 s.BasePath = endpoint 126 } 127 return s, nil 128 } 129 130 // New creates a new Service. It uses the provided http.Client for requests. 131 // 132 // Deprecated: please use NewService instead. 133 // To provide a custom HTTP client, use option.WithHTTPClient. 134 // If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead. 135 func New(client *http.Client) (*Service, error) { 136 if client == nil { 137 return nil, errors.New("client is nil") 138 } 139 s := &Service{client: client, BasePath: basePath} 140 s.Operations = NewOperationsService(s) 141 s.Projects = NewProjectsService(s) 142 s.Videos = NewVideosService(s) 143 return s, nil 144 } 145 146 type Service struct { 147 client *http.Client 148 BasePath string // API endpoint base URL 149 UserAgent string // optional additional User-Agent fragment 150 151 Operations *OperationsService 152 153 Projects *ProjectsService 154 155 Videos *VideosService 156 } 157 158 func (s *Service) userAgent() string { 159 if s.UserAgent == "" { 160 return googleapi.UserAgent 161 } 162 return googleapi.UserAgent + " " + s.UserAgent 163 } 164 165 func NewOperationsService(s *Service) *OperationsService { 166 rs := &OperationsService{s: s} 167 rs.Projects = NewOperationsProjectsService(s) 168 return rs 169 } 170 171 type OperationsService struct { 172 s *Service 173 174 Projects *OperationsProjectsService 175 } 176 177 func NewOperationsProjectsService(s *Service) *OperationsProjectsService { 178 rs := &OperationsProjectsService{s: s} 179 rs.Locations = NewOperationsProjectsLocationsService(s) 180 return rs 181 } 182 183 type OperationsProjectsService struct { 184 s *Service 185 186 Locations *OperationsProjectsLocationsService 187 } 188 189 func NewOperationsProjectsLocationsService(s *Service) *OperationsProjectsLocationsService { 190 rs := &OperationsProjectsLocationsService{s: s} 191 rs.Operations = NewOperationsProjectsLocationsOperationsService(s) 192 return rs 193 } 194 195 type OperationsProjectsLocationsService struct { 196 s *Service 197 198 Operations *OperationsProjectsLocationsOperationsService 199 } 200 201 func NewOperationsProjectsLocationsOperationsService(s *Service) *OperationsProjectsLocationsOperationsService { 202 rs := &OperationsProjectsLocationsOperationsService{s: s} 203 return rs 204 } 205 206 type OperationsProjectsLocationsOperationsService struct { 207 s *Service 208 } 209 210 func NewProjectsService(s *Service) *ProjectsService { 211 rs := &ProjectsService{s: s} 212 rs.Locations = NewProjectsLocationsService(s) 213 return rs 214 } 215 216 type ProjectsService struct { 217 s *Service 218 219 Locations *ProjectsLocationsService 220 } 221 222 func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { 223 rs := &ProjectsLocationsService{s: s} 224 rs.Operations = NewProjectsLocationsOperationsService(s) 225 return rs 226 } 227 228 type ProjectsLocationsService struct { 229 s *Service 230 231 Operations *ProjectsLocationsOperationsService 232 } 233 234 func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService { 235 rs := &ProjectsLocationsOperationsService{s: s} 236 return rs 237 } 238 239 type ProjectsLocationsOperationsService struct { 240 s *Service 241 } 242 243 func NewVideosService(s *Service) *VideosService { 244 rs := &VideosService{s: s} 245 return rs 246 } 247 248 type VideosService struct { 249 s *Service 250 } 251 252 // GoogleCloudVideointelligenceV1AnnotateVideoProgress: Video annotation 253 // progress. Included in the `metadata` field of the `Operation` returned by 254 // the `GetOperation` call of the `google::longrunning::Operations` service. 255 type GoogleCloudVideointelligenceV1AnnotateVideoProgress struct { 256 // AnnotationProgress: Progress metadata for all videos specified in 257 // `AnnotateVideoRequest`. 258 AnnotationProgress []*GoogleCloudVideointelligenceV1VideoAnnotationProgress `json:"annotationProgress,omitempty"` 259 // ForceSendFields is a list of field names (e.g. "AnnotationProgress") to 260 // unconditionally include in API requests. By default, fields with empty or 261 // default values are omitted from API requests. See 262 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 263 // details. 264 ForceSendFields []string `json:"-"` 265 // NullFields is a list of field names (e.g. "AnnotationProgress") to include 266 // in API requests with the JSON null value. By default, fields with empty 267 // values are omitted from API requests. See 268 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 269 NullFields []string `json:"-"` 270 } 271 272 func (s *GoogleCloudVideointelligenceV1AnnotateVideoProgress) MarshalJSON() ([]byte, error) { 273 type NoMethod GoogleCloudVideointelligenceV1AnnotateVideoProgress 274 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 275 } 276 277 // GoogleCloudVideointelligenceV1AnnotateVideoRequest: Video annotation 278 // request. 279 type GoogleCloudVideointelligenceV1AnnotateVideoRequest struct { 280 // Features: Required. Requested video annotation features. 281 // 282 // Possible values: 283 // "FEATURE_UNSPECIFIED" - Unspecified. 284 // "LABEL_DETECTION" - Label detection. Detect objects, such as dog or 285 // flower. 286 // "SHOT_CHANGE_DETECTION" - Shot change detection. 287 // "EXPLICIT_CONTENT_DETECTION" - Explicit content detection. 288 // "FACE_DETECTION" - Human face detection. 289 // "SPEECH_TRANSCRIPTION" - Speech transcription. 290 // "TEXT_DETECTION" - OCR text detection and tracking. 291 // "OBJECT_TRACKING" - Object detection and tracking. 292 // "LOGO_RECOGNITION" - Logo detection, tracking, and recognition. 293 // "PERSON_DETECTION" - Person detection. 294 Features []string `json:"features,omitempty"` 295 // InputContent: The video data bytes. If unset, the input video(s) should be 296 // specified via the `input_uri`. If set, `input_uri` must be unset. 297 InputContent string `json:"inputContent,omitempty"` 298 // InputUri: Input video location. Currently, only Cloud Storage 299 // (https://cloud.google.com/storage/) URIs are supported. URIs must be 300 // specified in the following format: `gs://bucket-id/object-id` (other URI 301 // formats return google.rpc.Code.INVALID_ARGUMENT). For more information, see 302 // Request URIs (https://cloud.google.com/storage/docs/request-endpoints). To 303 // identify multiple videos, a video URI may include wildcards in the 304 // `object-id`. Supported wildcards: '*' to match 0 or more characters; '?' to 305 // match 1 character. If unset, the input video should be embedded in the 306 // request as `input_content`. If set, `input_content` must be unset. 307 InputUri string `json:"inputUri,omitempty"` 308 // LocationId: Optional. Cloud region where annotation should take place. 309 // Supported cloud regions are: `us-east1`, `us-west1`, `europe-west1`, 310 // `asia-east1`. If no region is specified, the region will be determined based 311 // on video file location. 312 LocationId string `json:"locationId,omitempty"` 313 // OutputUri: Optional. Location where the output (in JSON format) should be 314 // stored. Currently, only Cloud Storage (https://cloud.google.com/storage/) 315 // URIs are supported. These must be specified in the following format: 316 // `gs://bucket-id/object-id` (other URI formats return 317 // google.rpc.Code.INVALID_ARGUMENT). For more information, see Request URIs 318 // (https://cloud.google.com/storage/docs/request-endpoints). 319 OutputUri string `json:"outputUri,omitempty"` 320 // VideoContext: Additional video context and/or feature-specific parameters. 321 VideoContext *GoogleCloudVideointelligenceV1VideoContext `json:"videoContext,omitempty"` 322 // ForceSendFields is a list of field names (e.g. "Features") to 323 // unconditionally include in API requests. By default, fields with empty or 324 // default values are omitted from API requests. See 325 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 326 // details. 327 ForceSendFields []string `json:"-"` 328 // NullFields is a list of field names (e.g. "Features") to include in API 329 // requests with the JSON null value. By default, fields with empty values are 330 // omitted from API requests. See 331 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 332 NullFields []string `json:"-"` 333 } 334 335 func (s *GoogleCloudVideointelligenceV1AnnotateVideoRequest) MarshalJSON() ([]byte, error) { 336 type NoMethod GoogleCloudVideointelligenceV1AnnotateVideoRequest 337 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 338 } 339 340 // GoogleCloudVideointelligenceV1AnnotateVideoResponse: Video annotation 341 // response. Included in the `response` field of the `Operation` returned by 342 // the `GetOperation` call of the `google::longrunning::Operations` service. 343 type GoogleCloudVideointelligenceV1AnnotateVideoResponse struct { 344 // AnnotationResults: Annotation results for all videos specified in 345 // `AnnotateVideoRequest`. 346 AnnotationResults []*GoogleCloudVideointelligenceV1VideoAnnotationResults `json:"annotationResults,omitempty"` 347 // ForceSendFields is a list of field names (e.g. "AnnotationResults") to 348 // unconditionally include in API requests. By default, fields with empty or 349 // default values are omitted from API requests. See 350 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 351 // details. 352 ForceSendFields []string `json:"-"` 353 // NullFields is a list of field names (e.g. "AnnotationResults") to include in 354 // API requests with the JSON null value. By default, fields with empty values 355 // are omitted from API requests. See 356 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 357 NullFields []string `json:"-"` 358 } 359 360 func (s *GoogleCloudVideointelligenceV1AnnotateVideoResponse) MarshalJSON() ([]byte, error) { 361 type NoMethod GoogleCloudVideointelligenceV1AnnotateVideoResponse 362 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 363 } 364 365 // GoogleCloudVideointelligenceV1DetectedAttribute: A generic detected 366 // attribute represented by name in string format. 367 type GoogleCloudVideointelligenceV1DetectedAttribute struct { 368 // Confidence: Detected attribute confidence. Range [0, 1]. 369 Confidence float64 `json:"confidence,omitempty"` 370 // Name: The name of the attribute, for example, glasses, dark_glasses, 371 // mouth_open. A full list of supported type names will be provided in the 372 // document. 373 Name string `json:"name,omitempty"` 374 // Value: Text value of the detection result. For example, the value for 375 // "HairColor" can be "black", "blonde", etc. 376 Value string `json:"value,omitempty"` 377 // ForceSendFields is a list of field names (e.g. "Confidence") to 378 // unconditionally include in API requests. By default, fields with empty or 379 // default values are omitted from API requests. See 380 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 381 // details. 382 ForceSendFields []string `json:"-"` 383 // NullFields is a list of field names (e.g. "Confidence") to include in API 384 // requests with the JSON null value. By default, fields with empty values are 385 // omitted from API requests. See 386 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 387 NullFields []string `json:"-"` 388 } 389 390 func (s *GoogleCloudVideointelligenceV1DetectedAttribute) MarshalJSON() ([]byte, error) { 391 type NoMethod GoogleCloudVideointelligenceV1DetectedAttribute 392 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 393 } 394 395 func (s *GoogleCloudVideointelligenceV1DetectedAttribute) UnmarshalJSON(data []byte) error { 396 type NoMethod GoogleCloudVideointelligenceV1DetectedAttribute 397 var s1 struct { 398 Confidence gensupport.JSONFloat64 `json:"confidence"` 399 *NoMethod 400 } 401 s1.NoMethod = (*NoMethod)(s) 402 if err := json.Unmarshal(data, &s1); err != nil { 403 return err 404 } 405 s.Confidence = float64(s1.Confidence) 406 return nil 407 } 408 409 // GoogleCloudVideointelligenceV1DetectedLandmark: A generic detected landmark 410 // represented by name in string format and a 2D location. 411 type GoogleCloudVideointelligenceV1DetectedLandmark struct { 412 // Confidence: The confidence score of the detected landmark. Range [0, 1]. 413 Confidence float64 `json:"confidence,omitempty"` 414 // Name: The name of this landmark, for example, left_hand, right_shoulder. 415 Name string `json:"name,omitempty"` 416 // Point: The 2D point of the detected landmark using the normalized image 417 // coordindate system. The normalized coordinates have the range from 0 to 1. 418 Point *GoogleCloudVideointelligenceV1NormalizedVertex `json:"point,omitempty"` 419 // ForceSendFields is a list of field names (e.g. "Confidence") to 420 // unconditionally include in API requests. By default, fields with empty or 421 // default values are omitted from API requests. See 422 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 423 // details. 424 ForceSendFields []string `json:"-"` 425 // NullFields is a list of field names (e.g. "Confidence") to include in API 426 // requests with the JSON null value. By default, fields with empty values are 427 // omitted from API requests. See 428 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 429 NullFields []string `json:"-"` 430 } 431 432 func (s *GoogleCloudVideointelligenceV1DetectedLandmark) MarshalJSON() ([]byte, error) { 433 type NoMethod GoogleCloudVideointelligenceV1DetectedLandmark 434 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 435 } 436 437 func (s *GoogleCloudVideointelligenceV1DetectedLandmark) UnmarshalJSON(data []byte) error { 438 type NoMethod GoogleCloudVideointelligenceV1DetectedLandmark 439 var s1 struct { 440 Confidence gensupport.JSONFloat64 `json:"confidence"` 441 *NoMethod 442 } 443 s1.NoMethod = (*NoMethod)(s) 444 if err := json.Unmarshal(data, &s1); err != nil { 445 return err 446 } 447 s.Confidence = float64(s1.Confidence) 448 return nil 449 } 450 451 // GoogleCloudVideointelligenceV1Entity: Detected entity from video analysis. 452 type GoogleCloudVideointelligenceV1Entity struct { 453 // Description: Textual description, e.g., `Fixed-gear bicycle`. 454 Description string `json:"description,omitempty"` 455 // EntityId: Opaque entity ID. Some IDs may be available in Google Knowledge 456 // Graph Search API (https://developers.google.com/knowledge-graph/). 457 EntityId string `json:"entityId,omitempty"` 458 // LanguageCode: Language code for `description` in BCP-47 format. 459 LanguageCode string `json:"languageCode,omitempty"` 460 // ForceSendFields is a list of field names (e.g. "Description") to 461 // unconditionally include in API requests. By default, fields with empty or 462 // default values are omitted from API requests. See 463 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 464 // details. 465 ForceSendFields []string `json:"-"` 466 // NullFields is a list of field names (e.g. "Description") to include in API 467 // requests with the JSON null value. By default, fields with empty values are 468 // omitted from API requests. See 469 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 470 NullFields []string `json:"-"` 471 } 472 473 func (s *GoogleCloudVideointelligenceV1Entity) MarshalJSON() ([]byte, error) { 474 type NoMethod GoogleCloudVideointelligenceV1Entity 475 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 476 } 477 478 // GoogleCloudVideointelligenceV1ExplicitContentAnnotation: Explicit content 479 // annotation (based on per-frame visual signals only). If no explicit content 480 // has been detected in a frame, no annotations are present for that frame. 481 type GoogleCloudVideointelligenceV1ExplicitContentAnnotation struct { 482 // Frames: All video frames where explicit content was detected. 483 Frames []*GoogleCloudVideointelligenceV1ExplicitContentFrame `json:"frames,omitempty"` 484 // Version: Feature version. 485 Version string `json:"version,omitempty"` 486 // ForceSendFields is a list of field names (e.g. "Frames") to unconditionally 487 // include in API requests. By default, fields with empty or default values are 488 // omitted from API requests. See 489 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 490 // details. 491 ForceSendFields []string `json:"-"` 492 // NullFields is a list of field names (e.g. "Frames") to include in API 493 // requests with the JSON null value. By default, fields with empty values are 494 // omitted from API requests. See 495 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 496 NullFields []string `json:"-"` 497 } 498 499 func (s *GoogleCloudVideointelligenceV1ExplicitContentAnnotation) MarshalJSON() ([]byte, error) { 500 type NoMethod GoogleCloudVideointelligenceV1ExplicitContentAnnotation 501 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 502 } 503 504 // GoogleCloudVideointelligenceV1ExplicitContentDetectionConfig: Config for 505 // EXPLICIT_CONTENT_DETECTION. 506 type GoogleCloudVideointelligenceV1ExplicitContentDetectionConfig struct { 507 // Model: Model to use for explicit content detection. Supported values: 508 // "builtin/stable" (the default if unset) and "builtin/latest". 509 Model string `json:"model,omitempty"` 510 // ForceSendFields is a list of field names (e.g. "Model") to unconditionally 511 // include in API requests. By default, fields with empty or default values are 512 // omitted from API requests. See 513 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 514 // details. 515 ForceSendFields []string `json:"-"` 516 // NullFields is a list of field names (e.g. "Model") to include in API 517 // requests with the JSON null value. By default, fields with empty values are 518 // omitted from API requests. See 519 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 520 NullFields []string `json:"-"` 521 } 522 523 func (s *GoogleCloudVideointelligenceV1ExplicitContentDetectionConfig) MarshalJSON() ([]byte, error) { 524 type NoMethod GoogleCloudVideointelligenceV1ExplicitContentDetectionConfig 525 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 526 } 527 528 // GoogleCloudVideointelligenceV1ExplicitContentFrame: Video frame level 529 // annotation results for explicit content. 530 type GoogleCloudVideointelligenceV1ExplicitContentFrame struct { 531 // PornographyLikelihood: Likelihood of the pornography content.. 532 // 533 // Possible values: 534 // "LIKELIHOOD_UNSPECIFIED" - Unspecified likelihood. 535 // "VERY_UNLIKELY" - Very unlikely. 536 // "UNLIKELY" - Unlikely. 537 // "POSSIBLE" - Possible. 538 // "LIKELY" - Likely. 539 // "VERY_LIKELY" - Very likely. 540 PornographyLikelihood string `json:"pornographyLikelihood,omitempty"` 541 // TimeOffset: Time-offset, relative to the beginning of the video, 542 // corresponding to the video frame for this location. 543 TimeOffset string `json:"timeOffset,omitempty"` 544 // ForceSendFields is a list of field names (e.g. "PornographyLikelihood") to 545 // unconditionally include in API requests. By default, fields with empty or 546 // default values are omitted from API requests. See 547 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 548 // details. 549 ForceSendFields []string `json:"-"` 550 // NullFields is a list of field names (e.g. "PornographyLikelihood") to 551 // include in API requests with the JSON null value. By default, fields with 552 // empty values are omitted from API requests. See 553 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 554 NullFields []string `json:"-"` 555 } 556 557 func (s *GoogleCloudVideointelligenceV1ExplicitContentFrame) MarshalJSON() ([]byte, error) { 558 type NoMethod GoogleCloudVideointelligenceV1ExplicitContentFrame 559 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 560 } 561 562 // GoogleCloudVideointelligenceV1FaceAnnotation: Deprecated. No effect. 563 type GoogleCloudVideointelligenceV1FaceAnnotation struct { 564 // Frames: All video frames where a face was detected. 565 Frames []*GoogleCloudVideointelligenceV1FaceFrame `json:"frames,omitempty"` 566 // Segments: All video segments where a face was detected. 567 Segments []*GoogleCloudVideointelligenceV1FaceSegment `json:"segments,omitempty"` 568 // Thumbnail: Thumbnail of a representative face view (in JPEG format). 569 Thumbnail string `json:"thumbnail,omitempty"` 570 // ForceSendFields is a list of field names (e.g. "Frames") to unconditionally 571 // include in API requests. By default, fields with empty or default values are 572 // omitted from API requests. See 573 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 574 // details. 575 ForceSendFields []string `json:"-"` 576 // NullFields is a list of field names (e.g. "Frames") to include in API 577 // requests with the JSON null value. By default, fields with empty values are 578 // omitted from API requests. See 579 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 580 NullFields []string `json:"-"` 581 } 582 583 func (s *GoogleCloudVideointelligenceV1FaceAnnotation) MarshalJSON() ([]byte, error) { 584 type NoMethod GoogleCloudVideointelligenceV1FaceAnnotation 585 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 586 } 587 588 // GoogleCloudVideointelligenceV1FaceDetectionAnnotation: Face detection 589 // annotation. 590 type GoogleCloudVideointelligenceV1FaceDetectionAnnotation struct { 591 // Thumbnail: The thumbnail of a person's face. 592 Thumbnail string `json:"thumbnail,omitempty"` 593 // Tracks: The face tracks with attributes. 594 Tracks []*GoogleCloudVideointelligenceV1Track `json:"tracks,omitempty"` 595 // Version: Feature version. 596 Version string `json:"version,omitempty"` 597 // ForceSendFields is a list of field names (e.g. "Thumbnail") to 598 // unconditionally include in API requests. By default, fields with empty or 599 // default values are omitted from API requests. See 600 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 601 // details. 602 ForceSendFields []string `json:"-"` 603 // NullFields is a list of field names (e.g. "Thumbnail") to include in API 604 // requests with the JSON null value. By default, fields with empty values are 605 // omitted from API requests. See 606 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 607 NullFields []string `json:"-"` 608 } 609 610 func (s *GoogleCloudVideointelligenceV1FaceDetectionAnnotation) MarshalJSON() ([]byte, error) { 611 type NoMethod GoogleCloudVideointelligenceV1FaceDetectionAnnotation 612 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 613 } 614 615 // GoogleCloudVideointelligenceV1FaceDetectionConfig: Config for 616 // FACE_DETECTION. 617 type GoogleCloudVideointelligenceV1FaceDetectionConfig struct { 618 // IncludeAttributes: Whether to enable face attributes detection, such as 619 // glasses, dark_glasses, mouth_open etc. Ignored if 'include_bounding_boxes' 620 // is set to false. 621 IncludeAttributes bool `json:"includeAttributes,omitempty"` 622 // IncludeBoundingBoxes: Whether bounding boxes are included in the face 623 // annotation output. 624 IncludeBoundingBoxes bool `json:"includeBoundingBoxes,omitempty"` 625 // Model: Model to use for face detection. Supported values: "builtin/stable" 626 // (the default if unset) and "builtin/latest". 627 Model string `json:"model,omitempty"` 628 // ForceSendFields is a list of field names (e.g. "IncludeAttributes") to 629 // unconditionally include in API requests. By default, fields with empty or 630 // default values are omitted from API requests. See 631 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 632 // details. 633 ForceSendFields []string `json:"-"` 634 // NullFields is a list of field names (e.g. "IncludeAttributes") to include in 635 // API requests with the JSON null value. By default, fields with empty values 636 // are omitted from API requests. See 637 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 638 NullFields []string `json:"-"` 639 } 640 641 func (s *GoogleCloudVideointelligenceV1FaceDetectionConfig) MarshalJSON() ([]byte, error) { 642 type NoMethod GoogleCloudVideointelligenceV1FaceDetectionConfig 643 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 644 } 645 646 // GoogleCloudVideointelligenceV1FaceFrame: Deprecated. No effect. 647 type GoogleCloudVideointelligenceV1FaceFrame struct { 648 // NormalizedBoundingBoxes: Normalized Bounding boxes in a frame. There can be 649 // more than one boxes if the same face is detected in multiple locations 650 // within the current frame. 651 NormalizedBoundingBoxes []*GoogleCloudVideointelligenceV1NormalizedBoundingBox `json:"normalizedBoundingBoxes,omitempty"` 652 // TimeOffset: Time-offset, relative to the beginning of the video, 653 // corresponding to the video frame for this location. 654 TimeOffset string `json:"timeOffset,omitempty"` 655 // ForceSendFields is a list of field names (e.g. "NormalizedBoundingBoxes") to 656 // unconditionally include in API requests. By default, fields with empty or 657 // default values are omitted from API requests. See 658 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 659 // details. 660 ForceSendFields []string `json:"-"` 661 // NullFields is a list of field names (e.g. "NormalizedBoundingBoxes") to 662 // include in API requests with the JSON null value. By default, fields with 663 // empty values are omitted from API requests. See 664 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 665 NullFields []string `json:"-"` 666 } 667 668 func (s *GoogleCloudVideointelligenceV1FaceFrame) MarshalJSON() ([]byte, error) { 669 type NoMethod GoogleCloudVideointelligenceV1FaceFrame 670 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 671 } 672 673 // GoogleCloudVideointelligenceV1FaceSegment: Video segment level annotation 674 // results for face detection. 675 type GoogleCloudVideointelligenceV1FaceSegment struct { 676 // Segment: Video segment where a face was detected. 677 Segment *GoogleCloudVideointelligenceV1VideoSegment `json:"segment,omitempty"` 678 // ForceSendFields is a list of field names (e.g. "Segment") to unconditionally 679 // include in API requests. By default, fields with empty or default values are 680 // omitted from API requests. See 681 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 682 // details. 683 ForceSendFields []string `json:"-"` 684 // NullFields is a list of field names (e.g. "Segment") to include in API 685 // requests with the JSON null value. By default, fields with empty values are 686 // omitted from API requests. See 687 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 688 NullFields []string `json:"-"` 689 } 690 691 func (s *GoogleCloudVideointelligenceV1FaceSegment) MarshalJSON() ([]byte, error) { 692 type NoMethod GoogleCloudVideointelligenceV1FaceSegment 693 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 694 } 695 696 // GoogleCloudVideointelligenceV1LabelAnnotation: Label annotation. 697 type GoogleCloudVideointelligenceV1LabelAnnotation struct { 698 // CategoryEntities: Common categories for the detected entity. For example, 699 // when the label is `Terrier`, the category is likely `dog`. And in some cases 700 // there might be more than one categories e.g., `Terrier` could also be a 701 // `pet`. 702 CategoryEntities []*GoogleCloudVideointelligenceV1Entity `json:"categoryEntities,omitempty"` 703 // Entity: Detected entity. 704 Entity *GoogleCloudVideointelligenceV1Entity `json:"entity,omitempty"` 705 // Frames: All video frames where a label was detected. 706 Frames []*GoogleCloudVideointelligenceV1LabelFrame `json:"frames,omitempty"` 707 // Segments: All video segments where a label was detected. 708 Segments []*GoogleCloudVideointelligenceV1LabelSegment `json:"segments,omitempty"` 709 // Version: Feature version. 710 Version string `json:"version,omitempty"` 711 // ForceSendFields is a list of field names (e.g. "CategoryEntities") to 712 // unconditionally include in API requests. By default, fields with empty or 713 // default values are omitted from API requests. See 714 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 715 // details. 716 ForceSendFields []string `json:"-"` 717 // NullFields is a list of field names (e.g. "CategoryEntities") to include in 718 // API requests with the JSON null value. By default, fields with empty values 719 // are omitted from API requests. See 720 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 721 NullFields []string `json:"-"` 722 } 723 724 func (s *GoogleCloudVideointelligenceV1LabelAnnotation) MarshalJSON() ([]byte, error) { 725 type NoMethod GoogleCloudVideointelligenceV1LabelAnnotation 726 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 727 } 728 729 // GoogleCloudVideointelligenceV1LabelDetectionConfig: Config for 730 // LABEL_DETECTION. 731 type GoogleCloudVideointelligenceV1LabelDetectionConfig struct { 732 // FrameConfidenceThreshold: The confidence threshold we perform filtering on 733 // the labels from frame-level detection. If not set, it is set to 0.4 by 734 // default. The valid range for this threshold is [0.1, 0.9]. Any value set 735 // outside of this range will be clipped. Note: For best results, follow the 736 // default threshold. We will update the default threshold everytime when we 737 // release a new model. 738 FrameConfidenceThreshold float64 `json:"frameConfidenceThreshold,omitempty"` 739 // LabelDetectionMode: What labels should be detected with LABEL_DETECTION, in 740 // addition to video-level labels or segment-level labels. If unspecified, 741 // defaults to `SHOT_MODE`. 742 // 743 // Possible values: 744 // "LABEL_DETECTION_MODE_UNSPECIFIED" - Unspecified. 745 // "SHOT_MODE" - Detect shot-level labels. 746 // "FRAME_MODE" - Detect frame-level labels. 747 // "SHOT_AND_FRAME_MODE" - Detect both shot-level and frame-level labels. 748 LabelDetectionMode string `json:"labelDetectionMode,omitempty"` 749 // Model: Model to use for label detection. Supported values: "builtin/stable" 750 // (the default if unset) and "builtin/latest". 751 Model string `json:"model,omitempty"` 752 // StationaryCamera: Whether the video has been shot from a stationary (i.e., 753 // non-moving) camera. When set to true, might improve detection accuracy for 754 // moving objects. Should be used with `SHOT_AND_FRAME_MODE` enabled. 755 StationaryCamera bool `json:"stationaryCamera,omitempty"` 756 // VideoConfidenceThreshold: The confidence threshold we perform filtering on 757 // the labels from video-level and shot-level detections. If not set, it's set 758 // to 0.3 by default. The valid range for this threshold is [0.1, 0.9]. Any 759 // value set outside of this range will be clipped. Note: For best results, 760 // follow the default threshold. We will update the default threshold everytime 761 // when we release a new model. 762 VideoConfidenceThreshold float64 `json:"videoConfidenceThreshold,omitempty"` 763 // ForceSendFields is a list of field names (e.g. "FrameConfidenceThreshold") 764 // to unconditionally include in API requests. By default, fields with empty or 765 // default values are omitted from API requests. See 766 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 767 // details. 768 ForceSendFields []string `json:"-"` 769 // NullFields is a list of field names (e.g. "FrameConfidenceThreshold") to 770 // include in API requests with the JSON null value. By default, fields with 771 // empty values are omitted from API requests. See 772 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 773 NullFields []string `json:"-"` 774 } 775 776 func (s *GoogleCloudVideointelligenceV1LabelDetectionConfig) MarshalJSON() ([]byte, error) { 777 type NoMethod GoogleCloudVideointelligenceV1LabelDetectionConfig 778 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 779 } 780 781 func (s *GoogleCloudVideointelligenceV1LabelDetectionConfig) UnmarshalJSON(data []byte) error { 782 type NoMethod GoogleCloudVideointelligenceV1LabelDetectionConfig 783 var s1 struct { 784 FrameConfidenceThreshold gensupport.JSONFloat64 `json:"frameConfidenceThreshold"` 785 VideoConfidenceThreshold gensupport.JSONFloat64 `json:"videoConfidenceThreshold"` 786 *NoMethod 787 } 788 s1.NoMethod = (*NoMethod)(s) 789 if err := json.Unmarshal(data, &s1); err != nil { 790 return err 791 } 792 s.FrameConfidenceThreshold = float64(s1.FrameConfidenceThreshold) 793 s.VideoConfidenceThreshold = float64(s1.VideoConfidenceThreshold) 794 return nil 795 } 796 797 // GoogleCloudVideointelligenceV1LabelFrame: Video frame level annotation 798 // results for label detection. 799 type GoogleCloudVideointelligenceV1LabelFrame struct { 800 // Confidence: Confidence that the label is accurate. Range: [0, 1]. 801 Confidence float64 `json:"confidence,omitempty"` 802 // TimeOffset: Time-offset, relative to the beginning of the video, 803 // corresponding to the video frame for this location. 804 TimeOffset string `json:"timeOffset,omitempty"` 805 // ForceSendFields is a list of field names (e.g. "Confidence") to 806 // unconditionally include in API requests. By default, fields with empty or 807 // default values are omitted from API requests. See 808 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 809 // details. 810 ForceSendFields []string `json:"-"` 811 // NullFields is a list of field names (e.g. "Confidence") to include in API 812 // requests with the JSON null value. By default, fields with empty values are 813 // omitted from API requests. See 814 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 815 NullFields []string `json:"-"` 816 } 817 818 func (s *GoogleCloudVideointelligenceV1LabelFrame) MarshalJSON() ([]byte, error) { 819 type NoMethod GoogleCloudVideointelligenceV1LabelFrame 820 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 821 } 822 823 func (s *GoogleCloudVideointelligenceV1LabelFrame) UnmarshalJSON(data []byte) error { 824 type NoMethod GoogleCloudVideointelligenceV1LabelFrame 825 var s1 struct { 826 Confidence gensupport.JSONFloat64 `json:"confidence"` 827 *NoMethod 828 } 829 s1.NoMethod = (*NoMethod)(s) 830 if err := json.Unmarshal(data, &s1); err != nil { 831 return err 832 } 833 s.Confidence = float64(s1.Confidence) 834 return nil 835 } 836 837 // GoogleCloudVideointelligenceV1LabelSegment: Video segment level annotation 838 // results for label detection. 839 type GoogleCloudVideointelligenceV1LabelSegment struct { 840 // Confidence: Confidence that the label is accurate. Range: [0, 1]. 841 Confidence float64 `json:"confidence,omitempty"` 842 // Segment: Video segment where a label was detected. 843 Segment *GoogleCloudVideointelligenceV1VideoSegment `json:"segment,omitempty"` 844 // ForceSendFields is a list of field names (e.g. "Confidence") to 845 // unconditionally include in API requests. By default, fields with empty or 846 // default values are omitted from API requests. See 847 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 848 // details. 849 ForceSendFields []string `json:"-"` 850 // NullFields is a list of field names (e.g. "Confidence") to include in API 851 // requests with the JSON null value. By default, fields with empty values are 852 // omitted from API requests. See 853 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 854 NullFields []string `json:"-"` 855 } 856 857 func (s *GoogleCloudVideointelligenceV1LabelSegment) MarshalJSON() ([]byte, error) { 858 type NoMethod GoogleCloudVideointelligenceV1LabelSegment 859 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 860 } 861 862 func (s *GoogleCloudVideointelligenceV1LabelSegment) UnmarshalJSON(data []byte) error { 863 type NoMethod GoogleCloudVideointelligenceV1LabelSegment 864 var s1 struct { 865 Confidence gensupport.JSONFloat64 `json:"confidence"` 866 *NoMethod 867 } 868 s1.NoMethod = (*NoMethod)(s) 869 if err := json.Unmarshal(data, &s1); err != nil { 870 return err 871 } 872 s.Confidence = float64(s1.Confidence) 873 return nil 874 } 875 876 // GoogleCloudVideointelligenceV1LogoRecognitionAnnotation: Annotation 877 // corresponding to one detected, tracked and recognized logo class. 878 type GoogleCloudVideointelligenceV1LogoRecognitionAnnotation struct { 879 // Entity: Entity category information to specify the logo class that all the 880 // logo tracks within this LogoRecognitionAnnotation are recognized as. 881 Entity *GoogleCloudVideointelligenceV1Entity `json:"entity,omitempty"` 882 // Segments: All video segments where the recognized logo appears. There might 883 // be multiple instances of the same logo class appearing in one VideoSegment. 884 Segments []*GoogleCloudVideointelligenceV1VideoSegment `json:"segments,omitempty"` 885 // Tracks: All logo tracks where the recognized logo appears. Each track 886 // corresponds to one logo instance appearing in consecutive frames. 887 Tracks []*GoogleCloudVideointelligenceV1Track `json:"tracks,omitempty"` 888 // ForceSendFields is a list of field names (e.g. "Entity") to unconditionally 889 // include in API requests. By default, fields with empty or default values are 890 // omitted from API requests. See 891 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 892 // details. 893 ForceSendFields []string `json:"-"` 894 // NullFields is a list of field names (e.g. "Entity") to include in API 895 // requests with the JSON null value. By default, fields with empty values are 896 // omitted from API requests. See 897 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 898 NullFields []string `json:"-"` 899 } 900 901 func (s *GoogleCloudVideointelligenceV1LogoRecognitionAnnotation) MarshalJSON() ([]byte, error) { 902 type NoMethod GoogleCloudVideointelligenceV1LogoRecognitionAnnotation 903 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 904 } 905 906 // GoogleCloudVideointelligenceV1NormalizedBoundingBox: Normalized bounding 907 // box. The normalized vertex coordinates are relative to the original image. 908 // Range: [0, 1]. 909 type GoogleCloudVideointelligenceV1NormalizedBoundingBox struct { 910 // Bottom: Bottom Y coordinate. 911 Bottom float64 `json:"bottom,omitempty"` 912 // Left: Left X coordinate. 913 Left float64 `json:"left,omitempty"` 914 // Right: Right X coordinate. 915 Right float64 `json:"right,omitempty"` 916 // Top: Top Y coordinate. 917 Top float64 `json:"top,omitempty"` 918 // ForceSendFields is a list of field names (e.g. "Bottom") to unconditionally 919 // include in API requests. By default, fields with empty or default values are 920 // omitted from API requests. See 921 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 922 // details. 923 ForceSendFields []string `json:"-"` 924 // NullFields is a list of field names (e.g. "Bottom") to include in API 925 // requests with the JSON null value. By default, fields with empty values are 926 // omitted from API requests. See 927 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 928 NullFields []string `json:"-"` 929 } 930 931 func (s *GoogleCloudVideointelligenceV1NormalizedBoundingBox) MarshalJSON() ([]byte, error) { 932 type NoMethod GoogleCloudVideointelligenceV1NormalizedBoundingBox 933 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 934 } 935 936 func (s *GoogleCloudVideointelligenceV1NormalizedBoundingBox) UnmarshalJSON(data []byte) error { 937 type NoMethod GoogleCloudVideointelligenceV1NormalizedBoundingBox 938 var s1 struct { 939 Bottom gensupport.JSONFloat64 `json:"bottom"` 940 Left gensupport.JSONFloat64 `json:"left"` 941 Right gensupport.JSONFloat64 `json:"right"` 942 Top gensupport.JSONFloat64 `json:"top"` 943 *NoMethod 944 } 945 s1.NoMethod = (*NoMethod)(s) 946 if err := json.Unmarshal(data, &s1); err != nil { 947 return err 948 } 949 s.Bottom = float64(s1.Bottom) 950 s.Left = float64(s1.Left) 951 s.Right = float64(s1.Right) 952 s.Top = float64(s1.Top) 953 return nil 954 } 955 956 // GoogleCloudVideointelligenceV1NormalizedBoundingPoly: Normalized bounding 957 // polygon for text (that might not be aligned with axis). Contains list of the 958 // corner points in clockwise order starting from top-left corner. For example, 959 // for a rectangular bounding box: When the text is horizontal it might look 960 // like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees around the 961 // top-left corner it becomes: 2----3 | | 1----0 and the vertex order will 962 // still be (0, 1, 2, 3). Note that values can be less than 0, or greater than 963 // 1 due to trignometric calculations for location of the box. 964 type GoogleCloudVideointelligenceV1NormalizedBoundingPoly struct { 965 // Vertices: Normalized vertices of the bounding polygon. 966 Vertices []*GoogleCloudVideointelligenceV1NormalizedVertex `json:"vertices,omitempty"` 967 // ForceSendFields is a list of field names (e.g. "Vertices") to 968 // unconditionally include in API requests. By default, fields with empty or 969 // default values are omitted from API requests. See 970 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 971 // details. 972 ForceSendFields []string `json:"-"` 973 // NullFields is a list of field names (e.g. "Vertices") to include in API 974 // requests with the JSON null value. By default, fields with empty values are 975 // omitted from API requests. See 976 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 977 NullFields []string `json:"-"` 978 } 979 980 func (s *GoogleCloudVideointelligenceV1NormalizedBoundingPoly) MarshalJSON() ([]byte, error) { 981 type NoMethod GoogleCloudVideointelligenceV1NormalizedBoundingPoly 982 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 983 } 984 985 // GoogleCloudVideointelligenceV1NormalizedVertex: A vertex represents a 2D 986 // point in the image. NOTE: the normalized vertex coordinates are relative to 987 // the original image and range from 0 to 1. 988 type GoogleCloudVideointelligenceV1NormalizedVertex struct { 989 // X: X coordinate. 990 X float64 `json:"x,omitempty"` 991 // Y: Y coordinate. 992 Y float64 `json:"y,omitempty"` 993 // ForceSendFields is a list of field names (e.g. "X") to unconditionally 994 // include in API requests. By default, fields with empty or default values are 995 // omitted from API requests. See 996 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 997 // details. 998 ForceSendFields []string `json:"-"` 999 // NullFields is a list of field names (e.g. "X") to include in API requests 1000 // with the JSON null value. By default, fields with empty values are omitted 1001 // from API requests. See 1002 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1003 NullFields []string `json:"-"` 1004 } 1005 1006 func (s *GoogleCloudVideointelligenceV1NormalizedVertex) MarshalJSON() ([]byte, error) { 1007 type NoMethod GoogleCloudVideointelligenceV1NormalizedVertex 1008 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1009 } 1010 1011 func (s *GoogleCloudVideointelligenceV1NormalizedVertex) UnmarshalJSON(data []byte) error { 1012 type NoMethod GoogleCloudVideointelligenceV1NormalizedVertex 1013 var s1 struct { 1014 X gensupport.JSONFloat64 `json:"x"` 1015 Y gensupport.JSONFloat64 `json:"y"` 1016 *NoMethod 1017 } 1018 s1.NoMethod = (*NoMethod)(s) 1019 if err := json.Unmarshal(data, &s1); err != nil { 1020 return err 1021 } 1022 s.X = float64(s1.X) 1023 s.Y = float64(s1.Y) 1024 return nil 1025 } 1026 1027 // GoogleCloudVideointelligenceV1ObjectTrackingAnnotation: Annotations 1028 // corresponding to one tracked object. 1029 type GoogleCloudVideointelligenceV1ObjectTrackingAnnotation struct { 1030 // Confidence: Object category's labeling confidence of this track. 1031 Confidence float64 `json:"confidence,omitempty"` 1032 // Entity: Entity to specify the object category that this track is labeled as. 1033 Entity *GoogleCloudVideointelligenceV1Entity `json:"entity,omitempty"` 1034 // Frames: Information corresponding to all frames where this object track 1035 // appears. Non-streaming batch mode: it may be one or multiple 1036 // ObjectTrackingFrame messages in frames. Streaming mode: it can only be one 1037 // ObjectTrackingFrame message in frames. 1038 Frames []*GoogleCloudVideointelligenceV1ObjectTrackingFrame `json:"frames,omitempty"` 1039 // Segment: Non-streaming batch mode ONLY. Each object track corresponds to one 1040 // video segment where it appears. 1041 Segment *GoogleCloudVideointelligenceV1VideoSegment `json:"segment,omitempty"` 1042 // TrackId: Streaming mode ONLY. In streaming mode, we do not know the end time 1043 // of a tracked object before it is completed. Hence, there is no VideoSegment 1044 // info returned. Instead, we provide a unique identifiable integer track_id so 1045 // that the customers can correlate the results of the ongoing 1046 // ObjectTrackAnnotation of the same track_id over time. 1047 TrackId int64 `json:"trackId,omitempty,string"` 1048 // Version: Feature version. 1049 Version string `json:"version,omitempty"` 1050 // ForceSendFields is a list of field names (e.g. "Confidence") to 1051 // unconditionally include in API requests. By default, fields with empty or 1052 // default values are omitted from API requests. See 1053 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1054 // details. 1055 ForceSendFields []string `json:"-"` 1056 // NullFields is a list of field names (e.g. "Confidence") to include in API 1057 // requests with the JSON null value. By default, fields with empty values are 1058 // omitted from API requests. See 1059 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1060 NullFields []string `json:"-"` 1061 } 1062 1063 func (s *GoogleCloudVideointelligenceV1ObjectTrackingAnnotation) MarshalJSON() ([]byte, error) { 1064 type NoMethod GoogleCloudVideointelligenceV1ObjectTrackingAnnotation 1065 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1066 } 1067 1068 func (s *GoogleCloudVideointelligenceV1ObjectTrackingAnnotation) UnmarshalJSON(data []byte) error { 1069 type NoMethod GoogleCloudVideointelligenceV1ObjectTrackingAnnotation 1070 var s1 struct { 1071 Confidence gensupport.JSONFloat64 `json:"confidence"` 1072 *NoMethod 1073 } 1074 s1.NoMethod = (*NoMethod)(s) 1075 if err := json.Unmarshal(data, &s1); err != nil { 1076 return err 1077 } 1078 s.Confidence = float64(s1.Confidence) 1079 return nil 1080 } 1081 1082 // GoogleCloudVideointelligenceV1ObjectTrackingConfig: Config for 1083 // OBJECT_TRACKING. 1084 type GoogleCloudVideointelligenceV1ObjectTrackingConfig struct { 1085 // Model: Model to use for object tracking. Supported values: "builtin/stable" 1086 // (the default if unset) and "builtin/latest". 1087 Model string `json:"model,omitempty"` 1088 // ForceSendFields is a list of field names (e.g. "Model") to unconditionally 1089 // include in API requests. By default, fields with empty or default values are 1090 // omitted from API requests. See 1091 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1092 // details. 1093 ForceSendFields []string `json:"-"` 1094 // NullFields is a list of field names (e.g. "Model") to include in API 1095 // requests with the JSON null value. By default, fields with empty values are 1096 // omitted from API requests. See 1097 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1098 NullFields []string `json:"-"` 1099 } 1100 1101 func (s *GoogleCloudVideointelligenceV1ObjectTrackingConfig) MarshalJSON() ([]byte, error) { 1102 type NoMethod GoogleCloudVideointelligenceV1ObjectTrackingConfig 1103 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1104 } 1105 1106 // GoogleCloudVideointelligenceV1ObjectTrackingFrame: Video frame level 1107 // annotations for object detection and tracking. This field stores per frame 1108 // location, time offset, and confidence. 1109 type GoogleCloudVideointelligenceV1ObjectTrackingFrame struct { 1110 // NormalizedBoundingBox: The normalized bounding box location of this object 1111 // track for the frame. 1112 NormalizedBoundingBox *GoogleCloudVideointelligenceV1NormalizedBoundingBox `json:"normalizedBoundingBox,omitempty"` 1113 // TimeOffset: The timestamp of the frame in microseconds. 1114 TimeOffset string `json:"timeOffset,omitempty"` 1115 // ForceSendFields is a list of field names (e.g. "NormalizedBoundingBox") to 1116 // unconditionally include in API requests. By default, fields with empty or 1117 // default values are omitted from API requests. See 1118 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1119 // details. 1120 ForceSendFields []string `json:"-"` 1121 // NullFields is a list of field names (e.g. "NormalizedBoundingBox") to 1122 // include in API requests with the JSON null value. By default, fields with 1123 // empty values are omitted from API requests. See 1124 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1125 NullFields []string `json:"-"` 1126 } 1127 1128 func (s *GoogleCloudVideointelligenceV1ObjectTrackingFrame) MarshalJSON() ([]byte, error) { 1129 type NoMethod GoogleCloudVideointelligenceV1ObjectTrackingFrame 1130 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1131 } 1132 1133 // GoogleCloudVideointelligenceV1PersonDetectionAnnotation: Person detection 1134 // annotation per video. 1135 type GoogleCloudVideointelligenceV1PersonDetectionAnnotation struct { 1136 // Tracks: The detected tracks of a person. 1137 Tracks []*GoogleCloudVideointelligenceV1Track `json:"tracks,omitempty"` 1138 // Version: Feature version. 1139 Version string `json:"version,omitempty"` 1140 // ForceSendFields is a list of field names (e.g. "Tracks") to unconditionally 1141 // include in API requests. By default, fields with empty or default values are 1142 // omitted from API requests. See 1143 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1144 // details. 1145 ForceSendFields []string `json:"-"` 1146 // NullFields is a list of field names (e.g. "Tracks") to include in API 1147 // requests with the JSON null value. By default, fields with empty values are 1148 // omitted from API requests. See 1149 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1150 NullFields []string `json:"-"` 1151 } 1152 1153 func (s *GoogleCloudVideointelligenceV1PersonDetectionAnnotation) MarshalJSON() ([]byte, error) { 1154 type NoMethod GoogleCloudVideointelligenceV1PersonDetectionAnnotation 1155 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1156 } 1157 1158 // GoogleCloudVideointelligenceV1PersonDetectionConfig: Config for 1159 // PERSON_DETECTION. 1160 type GoogleCloudVideointelligenceV1PersonDetectionConfig struct { 1161 // IncludeAttributes: Whether to enable person attributes detection, such as 1162 // cloth color (black, blue, etc), type (coat, dress, etc), pattern (plain, 1163 // floral, etc), hair, etc. Ignored if 'include_bounding_boxes' is set to 1164 // false. 1165 IncludeAttributes bool `json:"includeAttributes,omitempty"` 1166 // IncludeBoundingBoxes: Whether bounding boxes are included in the person 1167 // detection annotation output. 1168 IncludeBoundingBoxes bool `json:"includeBoundingBoxes,omitempty"` 1169 // IncludePoseLandmarks: Whether to enable pose landmarks detection. Ignored if 1170 // 'include_bounding_boxes' is set to false. 1171 IncludePoseLandmarks bool `json:"includePoseLandmarks,omitempty"` 1172 // ForceSendFields is a list of field names (e.g. "IncludeAttributes") to 1173 // unconditionally include in API requests. By default, fields with empty or 1174 // default values are omitted from API requests. See 1175 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1176 // details. 1177 ForceSendFields []string `json:"-"` 1178 // NullFields is a list of field names (e.g. "IncludeAttributes") to include in 1179 // API requests with the JSON null value. By default, fields with empty values 1180 // are omitted from API requests. See 1181 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1182 NullFields []string `json:"-"` 1183 } 1184 1185 func (s *GoogleCloudVideointelligenceV1PersonDetectionConfig) MarshalJSON() ([]byte, error) { 1186 type NoMethod GoogleCloudVideointelligenceV1PersonDetectionConfig 1187 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1188 } 1189 1190 // GoogleCloudVideointelligenceV1ShotChangeDetectionConfig: Config for 1191 // SHOT_CHANGE_DETECTION. 1192 type GoogleCloudVideointelligenceV1ShotChangeDetectionConfig struct { 1193 // Model: Model to use for shot change detection. Supported values: 1194 // "builtin/stable" (the default if unset), "builtin/latest", and 1195 // "builtin/legacy". 1196 Model string `json:"model,omitempty"` 1197 // ForceSendFields is a list of field names (e.g. "Model") to unconditionally 1198 // include in API requests. By default, fields with empty or default values are 1199 // omitted from API requests. See 1200 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1201 // details. 1202 ForceSendFields []string `json:"-"` 1203 // NullFields is a list of field names (e.g. "Model") to include in API 1204 // requests with the JSON null value. By default, fields with empty values are 1205 // omitted from API requests. See 1206 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1207 NullFields []string `json:"-"` 1208 } 1209 1210 func (s *GoogleCloudVideointelligenceV1ShotChangeDetectionConfig) MarshalJSON() ([]byte, error) { 1211 type NoMethod GoogleCloudVideointelligenceV1ShotChangeDetectionConfig 1212 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1213 } 1214 1215 // GoogleCloudVideointelligenceV1SpeechContext: Provides "hints" to the speech 1216 // recognizer to favor specific words and phrases in the results. 1217 type GoogleCloudVideointelligenceV1SpeechContext struct { 1218 // Phrases: Optional. A list of strings containing words and phrases "hints" so 1219 // that the speech recognition is more likely to recognize them. This can be 1220 // used to improve the accuracy for specific words and phrases, for example, if 1221 // specific commands are typically spoken by the user. This can also be used to 1222 // add additional words to the vocabulary of the recognizer. See usage limits 1223 // (https://cloud.google.com/speech/limits#content). 1224 Phrases []string `json:"phrases,omitempty"` 1225 // ForceSendFields is a list of field names (e.g. "Phrases") to unconditionally 1226 // include in API requests. By default, fields with empty or default values are 1227 // omitted from API requests. See 1228 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1229 // details. 1230 ForceSendFields []string `json:"-"` 1231 // NullFields is a list of field names (e.g. "Phrases") to include in API 1232 // requests with the JSON null value. By default, fields with empty values are 1233 // omitted from API requests. See 1234 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1235 NullFields []string `json:"-"` 1236 } 1237 1238 func (s *GoogleCloudVideointelligenceV1SpeechContext) MarshalJSON() ([]byte, error) { 1239 type NoMethod GoogleCloudVideointelligenceV1SpeechContext 1240 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1241 } 1242 1243 // GoogleCloudVideointelligenceV1SpeechRecognitionAlternative: Alternative 1244 // hypotheses (a.k.a. n-best list). 1245 type GoogleCloudVideointelligenceV1SpeechRecognitionAlternative struct { 1246 // Confidence: Output only. The confidence estimate between 0.0 and 1.0. A 1247 // higher number indicates an estimated greater likelihood that the recognized 1248 // words are correct. This field is set only for the top alternative. This 1249 // field is not guaranteed to be accurate and users should not rely on it to be 1250 // always provided. The default of 0.0 is a sentinel value indicating 1251 // `confidence` was not set. 1252 Confidence float64 `json:"confidence,omitempty"` 1253 // Transcript: Transcript text representing the words that the user spoke. 1254 Transcript string `json:"transcript,omitempty"` 1255 // Words: Output only. A list of word-specific information for each recognized 1256 // word. Note: When `enable_speaker_diarization` is set to true, you will see 1257 // all the words from the beginning of the audio. 1258 Words []*GoogleCloudVideointelligenceV1WordInfo `json:"words,omitempty"` 1259 // ForceSendFields is a list of field names (e.g. "Confidence") to 1260 // unconditionally include in API requests. By default, fields with empty or 1261 // default values are omitted from API requests. See 1262 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1263 // details. 1264 ForceSendFields []string `json:"-"` 1265 // NullFields is a list of field names (e.g. "Confidence") to include in API 1266 // requests with the JSON null value. By default, fields with empty values are 1267 // omitted from API requests. See 1268 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1269 NullFields []string `json:"-"` 1270 } 1271 1272 func (s *GoogleCloudVideointelligenceV1SpeechRecognitionAlternative) MarshalJSON() ([]byte, error) { 1273 type NoMethod GoogleCloudVideointelligenceV1SpeechRecognitionAlternative 1274 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1275 } 1276 1277 func (s *GoogleCloudVideointelligenceV1SpeechRecognitionAlternative) UnmarshalJSON(data []byte) error { 1278 type NoMethod GoogleCloudVideointelligenceV1SpeechRecognitionAlternative 1279 var s1 struct { 1280 Confidence gensupport.JSONFloat64 `json:"confidence"` 1281 *NoMethod 1282 } 1283 s1.NoMethod = (*NoMethod)(s) 1284 if err := json.Unmarshal(data, &s1); err != nil { 1285 return err 1286 } 1287 s.Confidence = float64(s1.Confidence) 1288 return nil 1289 } 1290 1291 // GoogleCloudVideointelligenceV1SpeechTranscription: A speech recognition 1292 // result corresponding to a portion of the audio. 1293 type GoogleCloudVideointelligenceV1SpeechTranscription struct { 1294 // Alternatives: May contain one or more recognition hypotheses (up to the 1295 // maximum specified in `max_alternatives`). These alternatives are ordered in 1296 // terms of accuracy, with the top (first) alternative being the most probable, 1297 // as ranked by the recognizer. 1298 Alternatives []*GoogleCloudVideointelligenceV1SpeechRecognitionAlternative `json:"alternatives,omitempty"` 1299 // LanguageCode: Output only. The BCP-47 1300 // (https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag of the language 1301 // in this result. This language code was detected to have the most likelihood 1302 // of being spoken in the audio. 1303 LanguageCode string `json:"languageCode,omitempty"` 1304 // ForceSendFields is a list of field names (e.g. "Alternatives") to 1305 // unconditionally include in API requests. By default, fields with empty or 1306 // default values are omitted from API requests. See 1307 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1308 // details. 1309 ForceSendFields []string `json:"-"` 1310 // NullFields is a list of field names (e.g. "Alternatives") to include in API 1311 // requests with the JSON null value. By default, fields with empty values are 1312 // omitted from API requests. See 1313 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1314 NullFields []string `json:"-"` 1315 } 1316 1317 func (s *GoogleCloudVideointelligenceV1SpeechTranscription) MarshalJSON() ([]byte, error) { 1318 type NoMethod GoogleCloudVideointelligenceV1SpeechTranscription 1319 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1320 } 1321 1322 // GoogleCloudVideointelligenceV1SpeechTranscriptionConfig: Config for 1323 // SPEECH_TRANSCRIPTION. 1324 type GoogleCloudVideointelligenceV1SpeechTranscriptionConfig struct { 1325 // AudioTracks: Optional. For file formats, such as MXF or MKV, supporting 1326 // multiple audio tracks, specify up to two tracks. Default: track 0. 1327 AudioTracks []int64 `json:"audioTracks,omitempty"` 1328 // DiarizationSpeakerCount: Optional. If set, specifies the estimated number of 1329 // speakers in the conversation. If not set, defaults to '2'. Ignored unless 1330 // enable_speaker_diarization is set to true. 1331 DiarizationSpeakerCount int64 `json:"diarizationSpeakerCount,omitempty"` 1332 // EnableAutomaticPunctuation: Optional. If 'true', adds punctuation to 1333 // recognition result hypotheses. This feature is only available in select 1334 // languages. Setting this for requests in other languages has no effect at 1335 // all. The default 'false' value does not add punctuation to result 1336 // hypotheses. NOTE: "This is currently offered as an experimental service, 1337 // complimentary to all users. In the future this may be exclusively available 1338 // as a premium feature." 1339 EnableAutomaticPunctuation bool `json:"enableAutomaticPunctuation,omitempty"` 1340 // EnableSpeakerDiarization: Optional. If 'true', enables speaker detection for 1341 // each recognized word in the top alternative of the recognition result using 1342 // a speaker_tag provided in the WordInfo. Note: When this is true, we send all 1343 // the words from the beginning of the audio for the top alternative in every 1344 // consecutive response. This is done in order to improve our speaker tags as 1345 // our models learn to identify the speakers in the conversation over time. 1346 EnableSpeakerDiarization bool `json:"enableSpeakerDiarization,omitempty"` 1347 // EnableWordConfidence: Optional. If `true`, the top result includes a list of 1348 // words and the confidence for those words. If `false`, no word-level 1349 // confidence information is returned. The default is `false`. 1350 EnableWordConfidence bool `json:"enableWordConfidence,omitempty"` 1351 // FilterProfanity: Optional. If set to `true`, the server will attempt to 1352 // filter out profanities, replacing all but the initial character in each 1353 // filtered word with asterisks, e.g. "f***". If set to `false` or omitted, 1354 // profanities won't be filtered out. 1355 FilterProfanity bool `json:"filterProfanity,omitempty"` 1356 // LanguageCode: Required. *Required* The language of the supplied audio as a 1357 // BCP-47 (https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. Example: 1358 // "en-US". See Language Support 1359 // (https://cloud.google.com/speech/docs/languages) for a list of the currently 1360 // supported language codes. 1361 LanguageCode string `json:"languageCode,omitempty"` 1362 // MaxAlternatives: Optional. Maximum number of recognition hypotheses to be 1363 // returned. Specifically, the maximum number of `SpeechRecognitionAlternative` 1364 // messages within each `SpeechTranscription`. The server may return fewer than 1365 // `max_alternatives`. Valid values are `0`-`30`. A value of `0` or `1` will 1366 // return a maximum of one. If omitted, will return a maximum of one. 1367 MaxAlternatives int64 `json:"maxAlternatives,omitempty"` 1368 // SpeechContexts: Optional. A means to provide context to assist the speech 1369 // recognition. 1370 SpeechContexts []*GoogleCloudVideointelligenceV1SpeechContext `json:"speechContexts,omitempty"` 1371 // ForceSendFields is a list of field names (e.g. "AudioTracks") to 1372 // unconditionally include in API requests. By default, fields with empty or 1373 // default values are omitted from API requests. See 1374 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1375 // details. 1376 ForceSendFields []string `json:"-"` 1377 // NullFields is a list of field names (e.g. "AudioTracks") to include in API 1378 // requests with the JSON null value. By default, fields with empty values are 1379 // omitted from API requests. See 1380 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1381 NullFields []string `json:"-"` 1382 } 1383 1384 func (s *GoogleCloudVideointelligenceV1SpeechTranscriptionConfig) MarshalJSON() ([]byte, error) { 1385 type NoMethod GoogleCloudVideointelligenceV1SpeechTranscriptionConfig 1386 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1387 } 1388 1389 // GoogleCloudVideointelligenceV1TextAnnotation: Annotations related to one 1390 // detected OCR text snippet. This will contain the corresponding text, 1391 // confidence value, and frame level information for each detection. 1392 type GoogleCloudVideointelligenceV1TextAnnotation struct { 1393 // Segments: All video segments where OCR detected text appears. 1394 Segments []*GoogleCloudVideointelligenceV1TextSegment `json:"segments,omitempty"` 1395 // Text: The detected text. 1396 Text string `json:"text,omitempty"` 1397 // Version: Feature version. 1398 Version string `json:"version,omitempty"` 1399 // ForceSendFields is a list of field names (e.g. "Segments") to 1400 // unconditionally include in API requests. By default, fields with empty or 1401 // default values are omitted from API requests. See 1402 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1403 // details. 1404 ForceSendFields []string `json:"-"` 1405 // NullFields is a list of field names (e.g. "Segments") to include in API 1406 // requests with the JSON null value. By default, fields with empty values are 1407 // omitted from API requests. See 1408 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1409 NullFields []string `json:"-"` 1410 } 1411 1412 func (s *GoogleCloudVideointelligenceV1TextAnnotation) MarshalJSON() ([]byte, error) { 1413 type NoMethod GoogleCloudVideointelligenceV1TextAnnotation 1414 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1415 } 1416 1417 // GoogleCloudVideointelligenceV1TextDetectionConfig: Config for 1418 // TEXT_DETECTION. 1419 type GoogleCloudVideointelligenceV1TextDetectionConfig struct { 1420 // LanguageHints: Language hint can be specified if the language to be detected 1421 // is known a priori. It can increase the accuracy of the detection. Language 1422 // hint must be language code in BCP-47 format. Automatic language detection is 1423 // performed if no hint is provided. 1424 LanguageHints []string `json:"languageHints,omitempty"` 1425 // Model: Model to use for text detection. Supported values: "builtin/stable" 1426 // (the default if unset) and "builtin/latest". 1427 Model string `json:"model,omitempty"` 1428 // ForceSendFields is a list of field names (e.g. "LanguageHints") to 1429 // unconditionally include in API requests. By default, fields with empty or 1430 // default values are omitted from API requests. See 1431 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1432 // details. 1433 ForceSendFields []string `json:"-"` 1434 // NullFields is a list of field names (e.g. "LanguageHints") to include in API 1435 // requests with the JSON null value. By default, fields with empty values are 1436 // omitted from API requests. See 1437 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1438 NullFields []string `json:"-"` 1439 } 1440 1441 func (s *GoogleCloudVideointelligenceV1TextDetectionConfig) MarshalJSON() ([]byte, error) { 1442 type NoMethod GoogleCloudVideointelligenceV1TextDetectionConfig 1443 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1444 } 1445 1446 // GoogleCloudVideointelligenceV1TextFrame: Video frame level annotation 1447 // results for text annotation (OCR). Contains information regarding timestamp 1448 // and bounding box locations for the frames containing detected OCR text 1449 // snippets. 1450 type GoogleCloudVideointelligenceV1TextFrame struct { 1451 // RotatedBoundingBox: Bounding polygon of the detected text for this frame. 1452 RotatedBoundingBox *GoogleCloudVideointelligenceV1NormalizedBoundingPoly `json:"rotatedBoundingBox,omitempty"` 1453 // TimeOffset: Timestamp of this frame. 1454 TimeOffset string `json:"timeOffset,omitempty"` 1455 // ForceSendFields is a list of field names (e.g. "RotatedBoundingBox") to 1456 // unconditionally include in API requests. By default, fields with empty or 1457 // default values are omitted from API requests. See 1458 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1459 // details. 1460 ForceSendFields []string `json:"-"` 1461 // NullFields is a list of field names (e.g. "RotatedBoundingBox") to include 1462 // in API requests with the JSON null value. By default, fields with empty 1463 // values are omitted from API requests. See 1464 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1465 NullFields []string `json:"-"` 1466 } 1467 1468 func (s *GoogleCloudVideointelligenceV1TextFrame) MarshalJSON() ([]byte, error) { 1469 type NoMethod GoogleCloudVideointelligenceV1TextFrame 1470 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1471 } 1472 1473 // GoogleCloudVideointelligenceV1TextSegment: Video segment level annotation 1474 // results for text detection. 1475 type GoogleCloudVideointelligenceV1TextSegment struct { 1476 // Confidence: Confidence for the track of detected text. It is calculated as 1477 // the highest over all frames where OCR detected text appears. 1478 Confidence float64 `json:"confidence,omitempty"` 1479 // Frames: Information related to the frames where OCR detected text appears. 1480 Frames []*GoogleCloudVideointelligenceV1TextFrame `json:"frames,omitempty"` 1481 // Segment: Video segment where a text snippet was detected. 1482 Segment *GoogleCloudVideointelligenceV1VideoSegment `json:"segment,omitempty"` 1483 // ForceSendFields is a list of field names (e.g. "Confidence") to 1484 // unconditionally include in API requests. By default, fields with empty or 1485 // default values are omitted from API requests. See 1486 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1487 // details. 1488 ForceSendFields []string `json:"-"` 1489 // NullFields is a list of field names (e.g. "Confidence") to include in API 1490 // requests with the JSON null value. By default, fields with empty values are 1491 // omitted from API requests. See 1492 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1493 NullFields []string `json:"-"` 1494 } 1495 1496 func (s *GoogleCloudVideointelligenceV1TextSegment) MarshalJSON() ([]byte, error) { 1497 type NoMethod GoogleCloudVideointelligenceV1TextSegment 1498 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1499 } 1500 1501 func (s *GoogleCloudVideointelligenceV1TextSegment) UnmarshalJSON(data []byte) error { 1502 type NoMethod GoogleCloudVideointelligenceV1TextSegment 1503 var s1 struct { 1504 Confidence gensupport.JSONFloat64 `json:"confidence"` 1505 *NoMethod 1506 } 1507 s1.NoMethod = (*NoMethod)(s) 1508 if err := json.Unmarshal(data, &s1); err != nil { 1509 return err 1510 } 1511 s.Confidence = float64(s1.Confidence) 1512 return nil 1513 } 1514 1515 // GoogleCloudVideointelligenceV1TimestampedObject: For tracking related 1516 // features. An object at time_offset with attributes, and located with 1517 // normalized_bounding_box. 1518 type GoogleCloudVideointelligenceV1TimestampedObject struct { 1519 // Attributes: Optional. The attributes of the object in the bounding box. 1520 Attributes []*GoogleCloudVideointelligenceV1DetectedAttribute `json:"attributes,omitempty"` 1521 // Landmarks: Optional. The detected landmarks. 1522 Landmarks []*GoogleCloudVideointelligenceV1DetectedLandmark `json:"landmarks,omitempty"` 1523 // NormalizedBoundingBox: Normalized Bounding box in a frame, where the object 1524 // is located. 1525 NormalizedBoundingBox *GoogleCloudVideointelligenceV1NormalizedBoundingBox `json:"normalizedBoundingBox,omitempty"` 1526 // TimeOffset: Time-offset, relative to the beginning of the video, 1527 // corresponding to the video frame for this object. 1528 TimeOffset string `json:"timeOffset,omitempty"` 1529 // ForceSendFields is a list of field names (e.g. "Attributes") to 1530 // unconditionally include in API requests. By default, fields with empty or 1531 // default values are omitted from API requests. See 1532 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1533 // details. 1534 ForceSendFields []string `json:"-"` 1535 // NullFields is a list of field names (e.g. "Attributes") to include in API 1536 // requests with the JSON null value. By default, fields with empty values are 1537 // omitted from API requests. See 1538 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1539 NullFields []string `json:"-"` 1540 } 1541 1542 func (s *GoogleCloudVideointelligenceV1TimestampedObject) MarshalJSON() ([]byte, error) { 1543 type NoMethod GoogleCloudVideointelligenceV1TimestampedObject 1544 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1545 } 1546 1547 // GoogleCloudVideointelligenceV1Track: A track of an object instance. 1548 type GoogleCloudVideointelligenceV1Track struct { 1549 // Attributes: Optional. Attributes in the track level. 1550 Attributes []*GoogleCloudVideointelligenceV1DetectedAttribute `json:"attributes,omitempty"` 1551 // Confidence: Optional. The confidence score of the tracked object. 1552 Confidence float64 `json:"confidence,omitempty"` 1553 // Segment: Video segment of a track. 1554 Segment *GoogleCloudVideointelligenceV1VideoSegment `json:"segment,omitempty"` 1555 // TimestampedObjects: The object with timestamp and attributes per frame in 1556 // the track. 1557 TimestampedObjects []*GoogleCloudVideointelligenceV1TimestampedObject `json:"timestampedObjects,omitempty"` 1558 // ForceSendFields is a list of field names (e.g. "Attributes") to 1559 // unconditionally include in API requests. By default, fields with empty or 1560 // default values are omitted from API requests. See 1561 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1562 // details. 1563 ForceSendFields []string `json:"-"` 1564 // NullFields is a list of field names (e.g. "Attributes") to include in API 1565 // requests with the JSON null value. By default, fields with empty values are 1566 // omitted from API requests. See 1567 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1568 NullFields []string `json:"-"` 1569 } 1570 1571 func (s *GoogleCloudVideointelligenceV1Track) MarshalJSON() ([]byte, error) { 1572 type NoMethod GoogleCloudVideointelligenceV1Track 1573 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1574 } 1575 1576 func (s *GoogleCloudVideointelligenceV1Track) UnmarshalJSON(data []byte) error { 1577 type NoMethod GoogleCloudVideointelligenceV1Track 1578 var s1 struct { 1579 Confidence gensupport.JSONFloat64 `json:"confidence"` 1580 *NoMethod 1581 } 1582 s1.NoMethod = (*NoMethod)(s) 1583 if err := json.Unmarshal(data, &s1); err != nil { 1584 return err 1585 } 1586 s.Confidence = float64(s1.Confidence) 1587 return nil 1588 } 1589 1590 // GoogleCloudVideointelligenceV1VideoAnnotationProgress: Annotation progress 1591 // for a single video. 1592 type GoogleCloudVideointelligenceV1VideoAnnotationProgress struct { 1593 // Feature: Specifies which feature is being tracked if the request contains 1594 // more than one feature. 1595 // 1596 // Possible values: 1597 // "FEATURE_UNSPECIFIED" - Unspecified. 1598 // "LABEL_DETECTION" - Label detection. Detect objects, such as dog or 1599 // flower. 1600 // "SHOT_CHANGE_DETECTION" - Shot change detection. 1601 // "EXPLICIT_CONTENT_DETECTION" - Explicit content detection. 1602 // "FACE_DETECTION" - Human face detection. 1603 // "SPEECH_TRANSCRIPTION" - Speech transcription. 1604 // "TEXT_DETECTION" - OCR text detection and tracking. 1605 // "OBJECT_TRACKING" - Object detection and tracking. 1606 // "LOGO_RECOGNITION" - Logo detection, tracking, and recognition. 1607 // "PERSON_DETECTION" - Person detection. 1608 Feature string `json:"feature,omitempty"` 1609 // InputUri: Video file location in Cloud Storage 1610 // (https://cloud.google.com/storage/). 1611 InputUri string `json:"inputUri,omitempty"` 1612 // ProgressPercent: Approximate percentage processed thus far. Guaranteed to be 1613 // 100 when fully processed. 1614 ProgressPercent int64 `json:"progressPercent,omitempty"` 1615 // Segment: Specifies which segment is being tracked if the request contains 1616 // more than one segment. 1617 Segment *GoogleCloudVideointelligenceV1VideoSegment `json:"segment,omitempty"` 1618 // StartTime: Time when the request was received. 1619 StartTime string `json:"startTime,omitempty"` 1620 // UpdateTime: Time of the most recent update. 1621 UpdateTime string `json:"updateTime,omitempty"` 1622 // ForceSendFields is a list of field names (e.g. "Feature") to unconditionally 1623 // include in API requests. By default, fields with empty or default values are 1624 // omitted from API requests. See 1625 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1626 // details. 1627 ForceSendFields []string `json:"-"` 1628 // NullFields is a list of field names (e.g. "Feature") to include in API 1629 // requests with the JSON null value. By default, fields with empty values are 1630 // omitted from API requests. See 1631 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1632 NullFields []string `json:"-"` 1633 } 1634 1635 func (s *GoogleCloudVideointelligenceV1VideoAnnotationProgress) MarshalJSON() ([]byte, error) { 1636 type NoMethod GoogleCloudVideointelligenceV1VideoAnnotationProgress 1637 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1638 } 1639 1640 // GoogleCloudVideointelligenceV1VideoAnnotationResults: Annotation results for 1641 // a single video. 1642 type GoogleCloudVideointelligenceV1VideoAnnotationResults struct { 1643 // Error: If set, indicates an error. Note that for a single 1644 // `AnnotateVideoRequest` some videos may succeed and some may fail. 1645 Error *GoogleRpcStatus `json:"error,omitempty"` 1646 // ExplicitAnnotation: Explicit content annotation. 1647 ExplicitAnnotation *GoogleCloudVideointelligenceV1ExplicitContentAnnotation `json:"explicitAnnotation,omitempty"` 1648 // FaceAnnotations: Deprecated. Please use `face_detection_annotations` 1649 // instead. 1650 FaceAnnotations []*GoogleCloudVideointelligenceV1FaceAnnotation `json:"faceAnnotations,omitempty"` 1651 // FaceDetectionAnnotations: Face detection annotations. 1652 FaceDetectionAnnotations []*GoogleCloudVideointelligenceV1FaceDetectionAnnotation `json:"faceDetectionAnnotations,omitempty"` 1653 // FrameLabelAnnotations: Label annotations on frame level. There is exactly 1654 // one element for each unique label. 1655 FrameLabelAnnotations []*GoogleCloudVideointelligenceV1LabelAnnotation `json:"frameLabelAnnotations,omitempty"` 1656 // InputUri: Video file location in Cloud Storage 1657 // (https://cloud.google.com/storage/). 1658 InputUri string `json:"inputUri,omitempty"` 1659 // LogoRecognitionAnnotations: Annotations for list of logos detected, tracked 1660 // and recognized in video. 1661 LogoRecognitionAnnotations []*GoogleCloudVideointelligenceV1LogoRecognitionAnnotation `json:"logoRecognitionAnnotations,omitempty"` 1662 // ObjectAnnotations: Annotations for list of objects detected and tracked in 1663 // video. 1664 ObjectAnnotations []*GoogleCloudVideointelligenceV1ObjectTrackingAnnotation `json:"objectAnnotations,omitempty"` 1665 // PersonDetectionAnnotations: Person detection annotations. 1666 PersonDetectionAnnotations []*GoogleCloudVideointelligenceV1PersonDetectionAnnotation `json:"personDetectionAnnotations,omitempty"` 1667 // Segment: Video segment on which the annotation is run. 1668 Segment *GoogleCloudVideointelligenceV1VideoSegment `json:"segment,omitempty"` 1669 // SegmentLabelAnnotations: Topical label annotations on video level or 1670 // user-specified segment level. There is exactly one element for each unique 1671 // label. 1672 SegmentLabelAnnotations []*GoogleCloudVideointelligenceV1LabelAnnotation `json:"segmentLabelAnnotations,omitempty"` 1673 // SegmentPresenceLabelAnnotations: Presence label annotations on video level 1674 // or user-specified segment level. There is exactly one element for each 1675 // unique label. Compared to the existing topical `segment_label_annotations`, 1676 // this field presents more fine-grained, segment-level labels detected in 1677 // video content and is made available only when the client sets 1678 // `LabelDetectionConfig.model` to "builtin/latest" in the request. 1679 SegmentPresenceLabelAnnotations []*GoogleCloudVideointelligenceV1LabelAnnotation `json:"segmentPresenceLabelAnnotations,omitempty"` 1680 // ShotAnnotations: Shot annotations. Each shot is represented as a video 1681 // segment. 1682 ShotAnnotations []*GoogleCloudVideointelligenceV1VideoSegment `json:"shotAnnotations,omitempty"` 1683 // ShotLabelAnnotations: Topical label annotations on shot level. There is 1684 // exactly one element for each unique label. 1685 ShotLabelAnnotations []*GoogleCloudVideointelligenceV1LabelAnnotation `json:"shotLabelAnnotations,omitempty"` 1686 // ShotPresenceLabelAnnotations: Presence label annotations on shot level. 1687 // There is exactly one element for each unique label. Compared to the existing 1688 // topical `shot_label_annotations`, this field presents more fine-grained, 1689 // shot-level labels detected in video content and is made available only when 1690 // the client sets `LabelDetectionConfig.model` to "builtin/latest" in the 1691 // request. 1692 ShotPresenceLabelAnnotations []*GoogleCloudVideointelligenceV1LabelAnnotation `json:"shotPresenceLabelAnnotations,omitempty"` 1693 // SpeechTranscriptions: Speech transcription. 1694 SpeechTranscriptions []*GoogleCloudVideointelligenceV1SpeechTranscription `json:"speechTranscriptions,omitempty"` 1695 // TextAnnotations: OCR text detection and tracking. Annotations for list of 1696 // detected text snippets. Each will have list of frame information associated 1697 // with it. 1698 TextAnnotations []*GoogleCloudVideointelligenceV1TextAnnotation `json:"textAnnotations,omitempty"` 1699 // ForceSendFields is a list of field names (e.g. "Error") to unconditionally 1700 // include in API requests. By default, fields with empty or default values are 1701 // omitted from API requests. See 1702 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1703 // details. 1704 ForceSendFields []string `json:"-"` 1705 // NullFields is a list of field names (e.g. "Error") to include in API 1706 // requests with the JSON null value. By default, fields with empty values are 1707 // omitted from API requests. See 1708 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1709 NullFields []string `json:"-"` 1710 } 1711 1712 func (s *GoogleCloudVideointelligenceV1VideoAnnotationResults) MarshalJSON() ([]byte, error) { 1713 type NoMethod GoogleCloudVideointelligenceV1VideoAnnotationResults 1714 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1715 } 1716 1717 // GoogleCloudVideointelligenceV1VideoContext: Video context and/or 1718 // feature-specific parameters. 1719 type GoogleCloudVideointelligenceV1VideoContext struct { 1720 // ExplicitContentDetectionConfig: Config for EXPLICIT_CONTENT_DETECTION. 1721 ExplicitContentDetectionConfig *GoogleCloudVideointelligenceV1ExplicitContentDetectionConfig `json:"explicitContentDetectionConfig,omitempty"` 1722 // FaceDetectionConfig: Config for FACE_DETECTION. 1723 FaceDetectionConfig *GoogleCloudVideointelligenceV1FaceDetectionConfig `json:"faceDetectionConfig,omitempty"` 1724 // LabelDetectionConfig: Config for LABEL_DETECTION. 1725 LabelDetectionConfig *GoogleCloudVideointelligenceV1LabelDetectionConfig `json:"labelDetectionConfig,omitempty"` 1726 // ObjectTrackingConfig: Config for OBJECT_TRACKING. 1727 ObjectTrackingConfig *GoogleCloudVideointelligenceV1ObjectTrackingConfig `json:"objectTrackingConfig,omitempty"` 1728 // PersonDetectionConfig: Config for PERSON_DETECTION. 1729 PersonDetectionConfig *GoogleCloudVideointelligenceV1PersonDetectionConfig `json:"personDetectionConfig,omitempty"` 1730 // Segments: Video segments to annotate. The segments may overlap and are not 1731 // required to be contiguous or span the whole video. If unspecified, each 1732 // video is treated as a single segment. 1733 Segments []*GoogleCloudVideointelligenceV1VideoSegment `json:"segments,omitempty"` 1734 // ShotChangeDetectionConfig: Config for SHOT_CHANGE_DETECTION. 1735 ShotChangeDetectionConfig *GoogleCloudVideointelligenceV1ShotChangeDetectionConfig `json:"shotChangeDetectionConfig,omitempty"` 1736 // SpeechTranscriptionConfig: Config for SPEECH_TRANSCRIPTION. 1737 SpeechTranscriptionConfig *GoogleCloudVideointelligenceV1SpeechTranscriptionConfig `json:"speechTranscriptionConfig,omitempty"` 1738 // TextDetectionConfig: Config for TEXT_DETECTION. 1739 TextDetectionConfig *GoogleCloudVideointelligenceV1TextDetectionConfig `json:"textDetectionConfig,omitempty"` 1740 // ForceSendFields is a list of field names (e.g. 1741 // "ExplicitContentDetectionConfig") to unconditionally include in API 1742 // requests. By default, fields with empty or default values are omitted from 1743 // API requests. See 1744 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1745 // details. 1746 ForceSendFields []string `json:"-"` 1747 // NullFields is a list of field names (e.g. "ExplicitContentDetectionConfig") 1748 // to include in API requests with the JSON null value. By default, fields with 1749 // empty values are omitted from API requests. See 1750 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1751 NullFields []string `json:"-"` 1752 } 1753 1754 func (s *GoogleCloudVideointelligenceV1VideoContext) MarshalJSON() ([]byte, error) { 1755 type NoMethod GoogleCloudVideointelligenceV1VideoContext 1756 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1757 } 1758 1759 // GoogleCloudVideointelligenceV1VideoSegment: Video segment. 1760 type GoogleCloudVideointelligenceV1VideoSegment struct { 1761 // EndTimeOffset: Time-offset, relative to the beginning of the video, 1762 // corresponding to the end of the segment (inclusive). 1763 EndTimeOffset string `json:"endTimeOffset,omitempty"` 1764 // StartTimeOffset: Time-offset, relative to the beginning of the video, 1765 // corresponding to the start of the segment (inclusive). 1766 StartTimeOffset string `json:"startTimeOffset,omitempty"` 1767 // ForceSendFields is a list of field names (e.g. "EndTimeOffset") to 1768 // unconditionally include in API requests. By default, fields with empty or 1769 // default values are omitted from API requests. See 1770 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1771 // details. 1772 ForceSendFields []string `json:"-"` 1773 // NullFields is a list of field names (e.g. "EndTimeOffset") to include in API 1774 // requests with the JSON null value. By default, fields with empty values are 1775 // omitted from API requests. See 1776 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1777 NullFields []string `json:"-"` 1778 } 1779 1780 func (s *GoogleCloudVideointelligenceV1VideoSegment) MarshalJSON() ([]byte, error) { 1781 type NoMethod GoogleCloudVideointelligenceV1VideoSegment 1782 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1783 } 1784 1785 // GoogleCloudVideointelligenceV1WordInfo: Word-specific information for 1786 // recognized words. Word information is only included in the response when 1787 // certain request parameters are set, such as `enable_word_time_offsets`. 1788 type GoogleCloudVideointelligenceV1WordInfo struct { 1789 // Confidence: Output only. The confidence estimate between 0.0 and 1.0. A 1790 // higher number indicates an estimated greater likelihood that the recognized 1791 // words are correct. This field is set only for the top alternative. This 1792 // field is not guaranteed to be accurate and users should not rely on it to be 1793 // always provided. The default of 0.0 is a sentinel value indicating 1794 // `confidence` was not set. 1795 Confidence float64 `json:"confidence,omitempty"` 1796 // EndTime: Time offset relative to the beginning of the audio, and 1797 // corresponding to the end of the spoken word. This field is only set if 1798 // `enable_word_time_offsets=true` and only in the top hypothesis. This is an 1799 // experimental feature and the accuracy of the time offset can vary. 1800 EndTime string `json:"endTime,omitempty"` 1801 // SpeakerTag: Output only. A distinct integer value is assigned for every 1802 // speaker within the audio. This field specifies which one of those speakers 1803 // was detected to have spoken this word. Value ranges from 1 up to 1804 // diarization_speaker_count, and is only set if speaker diarization is 1805 // enabled. 1806 SpeakerTag int64 `json:"speakerTag,omitempty"` 1807 // StartTime: Time offset relative to the beginning of the audio, and 1808 // corresponding to the start of the spoken word. This field is only set if 1809 // `enable_word_time_offsets=true` and only in the top hypothesis. This is an 1810 // experimental feature and the accuracy of the time offset can vary. 1811 StartTime string `json:"startTime,omitempty"` 1812 // Word: The word corresponding to this set of information. 1813 Word string `json:"word,omitempty"` 1814 // ForceSendFields is a list of field names (e.g. "Confidence") to 1815 // unconditionally include in API requests. By default, fields with empty or 1816 // default values are omitted from API requests. See 1817 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1818 // details. 1819 ForceSendFields []string `json:"-"` 1820 // NullFields is a list of field names (e.g. "Confidence") to include in API 1821 // requests with the JSON null value. By default, fields with empty values are 1822 // omitted from API requests. See 1823 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1824 NullFields []string `json:"-"` 1825 } 1826 1827 func (s *GoogleCloudVideointelligenceV1WordInfo) MarshalJSON() ([]byte, error) { 1828 type NoMethod GoogleCloudVideointelligenceV1WordInfo 1829 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1830 } 1831 1832 func (s *GoogleCloudVideointelligenceV1WordInfo) UnmarshalJSON(data []byte) error { 1833 type NoMethod GoogleCloudVideointelligenceV1WordInfo 1834 var s1 struct { 1835 Confidence gensupport.JSONFloat64 `json:"confidence"` 1836 *NoMethod 1837 } 1838 s1.NoMethod = (*NoMethod)(s) 1839 if err := json.Unmarshal(data, &s1); err != nil { 1840 return err 1841 } 1842 s.Confidence = float64(s1.Confidence) 1843 return nil 1844 } 1845 1846 // GoogleCloudVideointelligenceV1beta2AnnotateVideoProgress: Video annotation 1847 // progress. Included in the `metadata` field of the `Operation` returned by 1848 // the `GetOperation` call of the `google::longrunning::Operations` service. 1849 type GoogleCloudVideointelligenceV1beta2AnnotateVideoProgress struct { 1850 // AnnotationProgress: Progress metadata for all videos specified in 1851 // `AnnotateVideoRequest`. 1852 AnnotationProgress []*GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress `json:"annotationProgress,omitempty"` 1853 // ForceSendFields is a list of field names (e.g. "AnnotationProgress") to 1854 // unconditionally include in API requests. By default, fields with empty or 1855 // default values are omitted from API requests. See 1856 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1857 // details. 1858 ForceSendFields []string `json:"-"` 1859 // NullFields is a list of field names (e.g. "AnnotationProgress") to include 1860 // in API requests with the JSON null value. By default, fields with empty 1861 // values are omitted from API requests. See 1862 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1863 NullFields []string `json:"-"` 1864 } 1865 1866 func (s *GoogleCloudVideointelligenceV1beta2AnnotateVideoProgress) MarshalJSON() ([]byte, error) { 1867 type NoMethod GoogleCloudVideointelligenceV1beta2AnnotateVideoProgress 1868 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1869 } 1870 1871 // GoogleCloudVideointelligenceV1beta2AnnotateVideoResponse: Video annotation 1872 // response. Included in the `response` field of the `Operation` returned by 1873 // the `GetOperation` call of the `google::longrunning::Operations` service. 1874 type GoogleCloudVideointelligenceV1beta2AnnotateVideoResponse struct { 1875 // AnnotationResults: Annotation results for all videos specified in 1876 // `AnnotateVideoRequest`. 1877 AnnotationResults []*GoogleCloudVideointelligenceV1beta2VideoAnnotationResults `json:"annotationResults,omitempty"` 1878 // ForceSendFields is a list of field names (e.g. "AnnotationResults") to 1879 // unconditionally include in API requests. By default, fields with empty or 1880 // default values are omitted from API requests. See 1881 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1882 // details. 1883 ForceSendFields []string `json:"-"` 1884 // NullFields is a list of field names (e.g. "AnnotationResults") to include in 1885 // API requests with the JSON null value. By default, fields with empty values 1886 // are omitted from API requests. See 1887 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1888 NullFields []string `json:"-"` 1889 } 1890 1891 func (s *GoogleCloudVideointelligenceV1beta2AnnotateVideoResponse) MarshalJSON() ([]byte, error) { 1892 type NoMethod GoogleCloudVideointelligenceV1beta2AnnotateVideoResponse 1893 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1894 } 1895 1896 // GoogleCloudVideointelligenceV1beta2DetectedAttribute: A generic detected 1897 // attribute represented by name in string format. 1898 type GoogleCloudVideointelligenceV1beta2DetectedAttribute struct { 1899 // Confidence: Detected attribute confidence. Range [0, 1]. 1900 Confidence float64 `json:"confidence,omitempty"` 1901 // Name: The name of the attribute, for example, glasses, dark_glasses, 1902 // mouth_open. A full list of supported type names will be provided in the 1903 // document. 1904 Name string `json:"name,omitempty"` 1905 // Value: Text value of the detection result. For example, the value for 1906 // "HairColor" can be "black", "blonde", etc. 1907 Value string `json:"value,omitempty"` 1908 // ForceSendFields is a list of field names (e.g. "Confidence") to 1909 // unconditionally include in API requests. By default, fields with empty or 1910 // default values are omitted from API requests. See 1911 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1912 // details. 1913 ForceSendFields []string `json:"-"` 1914 // NullFields is a list of field names (e.g. "Confidence") to include in API 1915 // requests with the JSON null value. By default, fields with empty values are 1916 // omitted from API requests. See 1917 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1918 NullFields []string `json:"-"` 1919 } 1920 1921 func (s *GoogleCloudVideointelligenceV1beta2DetectedAttribute) MarshalJSON() ([]byte, error) { 1922 type NoMethod GoogleCloudVideointelligenceV1beta2DetectedAttribute 1923 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1924 } 1925 1926 func (s *GoogleCloudVideointelligenceV1beta2DetectedAttribute) UnmarshalJSON(data []byte) error { 1927 type NoMethod GoogleCloudVideointelligenceV1beta2DetectedAttribute 1928 var s1 struct { 1929 Confidence gensupport.JSONFloat64 `json:"confidence"` 1930 *NoMethod 1931 } 1932 s1.NoMethod = (*NoMethod)(s) 1933 if err := json.Unmarshal(data, &s1); err != nil { 1934 return err 1935 } 1936 s.Confidence = float64(s1.Confidence) 1937 return nil 1938 } 1939 1940 // GoogleCloudVideointelligenceV1beta2DetectedLandmark: A generic detected 1941 // landmark represented by name in string format and a 2D location. 1942 type GoogleCloudVideointelligenceV1beta2DetectedLandmark struct { 1943 // Confidence: The confidence score of the detected landmark. Range [0, 1]. 1944 Confidence float64 `json:"confidence,omitempty"` 1945 // Name: The name of this landmark, for example, left_hand, right_shoulder. 1946 Name string `json:"name,omitempty"` 1947 // Point: The 2D point of the detected landmark using the normalized image 1948 // coordindate system. The normalized coordinates have the range from 0 to 1. 1949 Point *GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"point,omitempty"` 1950 // ForceSendFields is a list of field names (e.g. "Confidence") to 1951 // unconditionally include in API requests. By default, fields with empty or 1952 // default values are omitted from API requests. See 1953 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1954 // details. 1955 ForceSendFields []string `json:"-"` 1956 // NullFields is a list of field names (e.g. "Confidence") to include in API 1957 // requests with the JSON null value. By default, fields with empty values are 1958 // omitted from API requests. See 1959 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 1960 NullFields []string `json:"-"` 1961 } 1962 1963 func (s *GoogleCloudVideointelligenceV1beta2DetectedLandmark) MarshalJSON() ([]byte, error) { 1964 type NoMethod GoogleCloudVideointelligenceV1beta2DetectedLandmark 1965 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 1966 } 1967 1968 func (s *GoogleCloudVideointelligenceV1beta2DetectedLandmark) UnmarshalJSON(data []byte) error { 1969 type NoMethod GoogleCloudVideointelligenceV1beta2DetectedLandmark 1970 var s1 struct { 1971 Confidence gensupport.JSONFloat64 `json:"confidence"` 1972 *NoMethod 1973 } 1974 s1.NoMethod = (*NoMethod)(s) 1975 if err := json.Unmarshal(data, &s1); err != nil { 1976 return err 1977 } 1978 s.Confidence = float64(s1.Confidence) 1979 return nil 1980 } 1981 1982 // GoogleCloudVideointelligenceV1beta2Entity: Detected entity from video 1983 // analysis. 1984 type GoogleCloudVideointelligenceV1beta2Entity struct { 1985 // Description: Textual description, e.g., `Fixed-gear bicycle`. 1986 Description string `json:"description,omitempty"` 1987 // EntityId: Opaque entity ID. Some IDs may be available in Google Knowledge 1988 // Graph Search API (https://developers.google.com/knowledge-graph/). 1989 EntityId string `json:"entityId,omitempty"` 1990 // LanguageCode: Language code for `description` in BCP-47 format. 1991 LanguageCode string `json:"languageCode,omitempty"` 1992 // ForceSendFields is a list of field names (e.g. "Description") to 1993 // unconditionally include in API requests. By default, fields with empty or 1994 // default values are omitted from API requests. See 1995 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 1996 // details. 1997 ForceSendFields []string `json:"-"` 1998 // NullFields is a list of field names (e.g. "Description") to include in API 1999 // requests with the JSON null value. By default, fields with empty values are 2000 // omitted from API requests. See 2001 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2002 NullFields []string `json:"-"` 2003 } 2004 2005 func (s *GoogleCloudVideointelligenceV1beta2Entity) MarshalJSON() ([]byte, error) { 2006 type NoMethod GoogleCloudVideointelligenceV1beta2Entity 2007 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2008 } 2009 2010 // GoogleCloudVideointelligenceV1beta2ExplicitContentAnnotation: Explicit 2011 // content annotation (based on per-frame visual signals only). If no explicit 2012 // content has been detected in a frame, no annotations are present for that 2013 // frame. 2014 type GoogleCloudVideointelligenceV1beta2ExplicitContentAnnotation struct { 2015 // Frames: All video frames where explicit content was detected. 2016 Frames []*GoogleCloudVideointelligenceV1beta2ExplicitContentFrame `json:"frames,omitempty"` 2017 // Version: Feature version. 2018 Version string `json:"version,omitempty"` 2019 // ForceSendFields is a list of field names (e.g. "Frames") to unconditionally 2020 // include in API requests. By default, fields with empty or default values are 2021 // omitted from API requests. See 2022 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2023 // details. 2024 ForceSendFields []string `json:"-"` 2025 // NullFields is a list of field names (e.g. "Frames") to include in API 2026 // requests with the JSON null value. By default, fields with empty values are 2027 // omitted from API requests. See 2028 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2029 NullFields []string `json:"-"` 2030 } 2031 2032 func (s *GoogleCloudVideointelligenceV1beta2ExplicitContentAnnotation) MarshalJSON() ([]byte, error) { 2033 type NoMethod GoogleCloudVideointelligenceV1beta2ExplicitContentAnnotation 2034 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2035 } 2036 2037 // GoogleCloudVideointelligenceV1beta2ExplicitContentFrame: Video frame level 2038 // annotation results for explicit content. 2039 type GoogleCloudVideointelligenceV1beta2ExplicitContentFrame struct { 2040 // PornographyLikelihood: Likelihood of the pornography content.. 2041 // 2042 // Possible values: 2043 // "LIKELIHOOD_UNSPECIFIED" - Unspecified likelihood. 2044 // "VERY_UNLIKELY" - Very unlikely. 2045 // "UNLIKELY" - Unlikely. 2046 // "POSSIBLE" - Possible. 2047 // "LIKELY" - Likely. 2048 // "VERY_LIKELY" - Very likely. 2049 PornographyLikelihood string `json:"pornographyLikelihood,omitempty"` 2050 // TimeOffset: Time-offset, relative to the beginning of the video, 2051 // corresponding to the video frame for this location. 2052 TimeOffset string `json:"timeOffset,omitempty"` 2053 // ForceSendFields is a list of field names (e.g. "PornographyLikelihood") to 2054 // unconditionally include in API requests. By default, fields with empty or 2055 // default values are omitted from API requests. See 2056 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2057 // details. 2058 ForceSendFields []string `json:"-"` 2059 // NullFields is a list of field names (e.g. "PornographyLikelihood") to 2060 // include in API requests with the JSON null value. By default, fields with 2061 // empty values are omitted from API requests. See 2062 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2063 NullFields []string `json:"-"` 2064 } 2065 2066 func (s *GoogleCloudVideointelligenceV1beta2ExplicitContentFrame) MarshalJSON() ([]byte, error) { 2067 type NoMethod GoogleCloudVideointelligenceV1beta2ExplicitContentFrame 2068 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2069 } 2070 2071 // GoogleCloudVideointelligenceV1beta2FaceAnnotation: Deprecated. No effect. 2072 type GoogleCloudVideointelligenceV1beta2FaceAnnotation struct { 2073 // Frames: All video frames where a face was detected. 2074 Frames []*GoogleCloudVideointelligenceV1beta2FaceFrame `json:"frames,omitempty"` 2075 // Segments: All video segments where a face was detected. 2076 Segments []*GoogleCloudVideointelligenceV1beta2FaceSegment `json:"segments,omitempty"` 2077 // Thumbnail: Thumbnail of a representative face view (in JPEG format). 2078 Thumbnail string `json:"thumbnail,omitempty"` 2079 // ForceSendFields is a list of field names (e.g. "Frames") to unconditionally 2080 // include in API requests. By default, fields with empty or default values are 2081 // omitted from API requests. See 2082 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2083 // details. 2084 ForceSendFields []string `json:"-"` 2085 // NullFields is a list of field names (e.g. "Frames") to include in API 2086 // requests with the JSON null value. By default, fields with empty values are 2087 // omitted from API requests. See 2088 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2089 NullFields []string `json:"-"` 2090 } 2091 2092 func (s *GoogleCloudVideointelligenceV1beta2FaceAnnotation) MarshalJSON() ([]byte, error) { 2093 type NoMethod GoogleCloudVideointelligenceV1beta2FaceAnnotation 2094 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2095 } 2096 2097 // GoogleCloudVideointelligenceV1beta2FaceDetectionAnnotation: Face detection 2098 // annotation. 2099 type GoogleCloudVideointelligenceV1beta2FaceDetectionAnnotation struct { 2100 // Thumbnail: The thumbnail of a person's face. 2101 Thumbnail string `json:"thumbnail,omitempty"` 2102 // Tracks: The face tracks with attributes. 2103 Tracks []*GoogleCloudVideointelligenceV1beta2Track `json:"tracks,omitempty"` 2104 // Version: Feature version. 2105 Version string `json:"version,omitempty"` 2106 // ForceSendFields is a list of field names (e.g. "Thumbnail") to 2107 // unconditionally include in API requests. By default, fields with empty or 2108 // default values are omitted from API requests. See 2109 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2110 // details. 2111 ForceSendFields []string `json:"-"` 2112 // NullFields is a list of field names (e.g. "Thumbnail") to include in API 2113 // requests with the JSON null value. By default, fields with empty values are 2114 // omitted from API requests. See 2115 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2116 NullFields []string `json:"-"` 2117 } 2118 2119 func (s *GoogleCloudVideointelligenceV1beta2FaceDetectionAnnotation) MarshalJSON() ([]byte, error) { 2120 type NoMethod GoogleCloudVideointelligenceV1beta2FaceDetectionAnnotation 2121 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2122 } 2123 2124 // GoogleCloudVideointelligenceV1beta2FaceFrame: Deprecated. No effect. 2125 type GoogleCloudVideointelligenceV1beta2FaceFrame struct { 2126 // NormalizedBoundingBoxes: Normalized Bounding boxes in a frame. There can be 2127 // more than one boxes if the same face is detected in multiple locations 2128 // within the current frame. 2129 NormalizedBoundingBoxes []*GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox `json:"normalizedBoundingBoxes,omitempty"` 2130 // TimeOffset: Time-offset, relative to the beginning of the video, 2131 // corresponding to the video frame for this location. 2132 TimeOffset string `json:"timeOffset,omitempty"` 2133 // ForceSendFields is a list of field names (e.g. "NormalizedBoundingBoxes") to 2134 // unconditionally include in API requests. By default, fields with empty or 2135 // default values are omitted from API requests. See 2136 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2137 // details. 2138 ForceSendFields []string `json:"-"` 2139 // NullFields is a list of field names (e.g. "NormalizedBoundingBoxes") to 2140 // include in API requests with the JSON null value. By default, fields with 2141 // empty values are omitted from API requests. See 2142 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2143 NullFields []string `json:"-"` 2144 } 2145 2146 func (s *GoogleCloudVideointelligenceV1beta2FaceFrame) MarshalJSON() ([]byte, error) { 2147 type NoMethod GoogleCloudVideointelligenceV1beta2FaceFrame 2148 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2149 } 2150 2151 // GoogleCloudVideointelligenceV1beta2FaceSegment: Video segment level 2152 // annotation results for face detection. 2153 type GoogleCloudVideointelligenceV1beta2FaceSegment struct { 2154 // Segment: Video segment where a face was detected. 2155 Segment *GoogleCloudVideointelligenceV1beta2VideoSegment `json:"segment,omitempty"` 2156 // ForceSendFields is a list of field names (e.g. "Segment") to unconditionally 2157 // include in API requests. By default, fields with empty or default values are 2158 // omitted from API requests. See 2159 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2160 // details. 2161 ForceSendFields []string `json:"-"` 2162 // NullFields is a list of field names (e.g. "Segment") to include in API 2163 // requests with the JSON null value. By default, fields with empty values are 2164 // omitted from API requests. See 2165 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2166 NullFields []string `json:"-"` 2167 } 2168 2169 func (s *GoogleCloudVideointelligenceV1beta2FaceSegment) MarshalJSON() ([]byte, error) { 2170 type NoMethod GoogleCloudVideointelligenceV1beta2FaceSegment 2171 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2172 } 2173 2174 // GoogleCloudVideointelligenceV1beta2LabelAnnotation: Label annotation. 2175 type GoogleCloudVideointelligenceV1beta2LabelAnnotation struct { 2176 // CategoryEntities: Common categories for the detected entity. For example, 2177 // when the label is `Terrier`, the category is likely `dog`. And in some cases 2178 // there might be more than one categories e.g., `Terrier` could also be a 2179 // `pet`. 2180 CategoryEntities []*GoogleCloudVideointelligenceV1beta2Entity `json:"categoryEntities,omitempty"` 2181 // Entity: Detected entity. 2182 Entity *GoogleCloudVideointelligenceV1beta2Entity `json:"entity,omitempty"` 2183 // Frames: All video frames where a label was detected. 2184 Frames []*GoogleCloudVideointelligenceV1beta2LabelFrame `json:"frames,omitempty"` 2185 // Segments: All video segments where a label was detected. 2186 Segments []*GoogleCloudVideointelligenceV1beta2LabelSegment `json:"segments,omitempty"` 2187 // Version: Feature version. 2188 Version string `json:"version,omitempty"` 2189 // ForceSendFields is a list of field names (e.g. "CategoryEntities") to 2190 // unconditionally include in API requests. By default, fields with empty or 2191 // default values are omitted from API requests. See 2192 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2193 // details. 2194 ForceSendFields []string `json:"-"` 2195 // NullFields is a list of field names (e.g. "CategoryEntities") to include in 2196 // API requests with the JSON null value. By default, fields with empty values 2197 // are omitted from API requests. See 2198 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2199 NullFields []string `json:"-"` 2200 } 2201 2202 func (s *GoogleCloudVideointelligenceV1beta2LabelAnnotation) MarshalJSON() ([]byte, error) { 2203 type NoMethod GoogleCloudVideointelligenceV1beta2LabelAnnotation 2204 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2205 } 2206 2207 // GoogleCloudVideointelligenceV1beta2LabelFrame: Video frame level annotation 2208 // results for label detection. 2209 type GoogleCloudVideointelligenceV1beta2LabelFrame struct { 2210 // Confidence: Confidence that the label is accurate. Range: [0, 1]. 2211 Confidence float64 `json:"confidence,omitempty"` 2212 // TimeOffset: Time-offset, relative to the beginning of the video, 2213 // corresponding to the video frame for this location. 2214 TimeOffset string `json:"timeOffset,omitempty"` 2215 // ForceSendFields is a list of field names (e.g. "Confidence") to 2216 // unconditionally include in API requests. By default, fields with empty or 2217 // default values are omitted from API requests. See 2218 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2219 // details. 2220 ForceSendFields []string `json:"-"` 2221 // NullFields is a list of field names (e.g. "Confidence") to include in API 2222 // requests with the JSON null value. By default, fields with empty values are 2223 // omitted from API requests. See 2224 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2225 NullFields []string `json:"-"` 2226 } 2227 2228 func (s *GoogleCloudVideointelligenceV1beta2LabelFrame) MarshalJSON() ([]byte, error) { 2229 type NoMethod GoogleCloudVideointelligenceV1beta2LabelFrame 2230 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2231 } 2232 2233 func (s *GoogleCloudVideointelligenceV1beta2LabelFrame) UnmarshalJSON(data []byte) error { 2234 type NoMethod GoogleCloudVideointelligenceV1beta2LabelFrame 2235 var s1 struct { 2236 Confidence gensupport.JSONFloat64 `json:"confidence"` 2237 *NoMethod 2238 } 2239 s1.NoMethod = (*NoMethod)(s) 2240 if err := json.Unmarshal(data, &s1); err != nil { 2241 return err 2242 } 2243 s.Confidence = float64(s1.Confidence) 2244 return nil 2245 } 2246 2247 // GoogleCloudVideointelligenceV1beta2LabelSegment: Video segment level 2248 // annotation results for label detection. 2249 type GoogleCloudVideointelligenceV1beta2LabelSegment struct { 2250 // Confidence: Confidence that the label is accurate. Range: [0, 1]. 2251 Confidence float64 `json:"confidence,omitempty"` 2252 // Segment: Video segment where a label was detected. 2253 Segment *GoogleCloudVideointelligenceV1beta2VideoSegment `json:"segment,omitempty"` 2254 // ForceSendFields is a list of field names (e.g. "Confidence") to 2255 // unconditionally include in API requests. By default, fields with empty or 2256 // default values are omitted from API requests. See 2257 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2258 // details. 2259 ForceSendFields []string `json:"-"` 2260 // NullFields is a list of field names (e.g. "Confidence") to include in API 2261 // requests with the JSON null value. By default, fields with empty values are 2262 // omitted from API requests. See 2263 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2264 NullFields []string `json:"-"` 2265 } 2266 2267 func (s *GoogleCloudVideointelligenceV1beta2LabelSegment) MarshalJSON() ([]byte, error) { 2268 type NoMethod GoogleCloudVideointelligenceV1beta2LabelSegment 2269 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2270 } 2271 2272 func (s *GoogleCloudVideointelligenceV1beta2LabelSegment) UnmarshalJSON(data []byte) error { 2273 type NoMethod GoogleCloudVideointelligenceV1beta2LabelSegment 2274 var s1 struct { 2275 Confidence gensupport.JSONFloat64 `json:"confidence"` 2276 *NoMethod 2277 } 2278 s1.NoMethod = (*NoMethod)(s) 2279 if err := json.Unmarshal(data, &s1); err != nil { 2280 return err 2281 } 2282 s.Confidence = float64(s1.Confidence) 2283 return nil 2284 } 2285 2286 // GoogleCloudVideointelligenceV1beta2LogoRecognitionAnnotation: Annotation 2287 // corresponding to one detected, tracked and recognized logo class. 2288 type GoogleCloudVideointelligenceV1beta2LogoRecognitionAnnotation struct { 2289 // Entity: Entity category information to specify the logo class that all the 2290 // logo tracks within this LogoRecognitionAnnotation are recognized as. 2291 Entity *GoogleCloudVideointelligenceV1beta2Entity `json:"entity,omitempty"` 2292 // Segments: All video segments where the recognized logo appears. There might 2293 // be multiple instances of the same logo class appearing in one VideoSegment. 2294 Segments []*GoogleCloudVideointelligenceV1beta2VideoSegment `json:"segments,omitempty"` 2295 // Tracks: All logo tracks where the recognized logo appears. Each track 2296 // corresponds to one logo instance appearing in consecutive frames. 2297 Tracks []*GoogleCloudVideointelligenceV1beta2Track `json:"tracks,omitempty"` 2298 // ForceSendFields is a list of field names (e.g. "Entity") to unconditionally 2299 // include in API requests. By default, fields with empty or default values are 2300 // omitted from API requests. See 2301 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2302 // details. 2303 ForceSendFields []string `json:"-"` 2304 // NullFields is a list of field names (e.g. "Entity") to include in API 2305 // requests with the JSON null value. By default, fields with empty values are 2306 // omitted from API requests. See 2307 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2308 NullFields []string `json:"-"` 2309 } 2310 2311 func (s *GoogleCloudVideointelligenceV1beta2LogoRecognitionAnnotation) MarshalJSON() ([]byte, error) { 2312 type NoMethod GoogleCloudVideointelligenceV1beta2LogoRecognitionAnnotation 2313 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2314 } 2315 2316 // GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox: Normalized 2317 // bounding box. The normalized vertex coordinates are relative to the original 2318 // image. Range: [0, 1]. 2319 type GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox struct { 2320 // Bottom: Bottom Y coordinate. 2321 Bottom float64 `json:"bottom,omitempty"` 2322 // Left: Left X coordinate. 2323 Left float64 `json:"left,omitempty"` 2324 // Right: Right X coordinate. 2325 Right float64 `json:"right,omitempty"` 2326 // Top: Top Y coordinate. 2327 Top float64 `json:"top,omitempty"` 2328 // ForceSendFields is a list of field names (e.g. "Bottom") to unconditionally 2329 // include in API requests. By default, fields with empty or default values are 2330 // omitted from API requests. See 2331 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2332 // details. 2333 ForceSendFields []string `json:"-"` 2334 // NullFields is a list of field names (e.g. "Bottom") to include in API 2335 // requests with the JSON null value. By default, fields with empty values are 2336 // omitted from API requests. See 2337 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2338 NullFields []string `json:"-"` 2339 } 2340 2341 func (s *GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox) MarshalJSON() ([]byte, error) { 2342 type NoMethod GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox 2343 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2344 } 2345 2346 func (s *GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox) UnmarshalJSON(data []byte) error { 2347 type NoMethod GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox 2348 var s1 struct { 2349 Bottom gensupport.JSONFloat64 `json:"bottom"` 2350 Left gensupport.JSONFloat64 `json:"left"` 2351 Right gensupport.JSONFloat64 `json:"right"` 2352 Top gensupport.JSONFloat64 `json:"top"` 2353 *NoMethod 2354 } 2355 s1.NoMethod = (*NoMethod)(s) 2356 if err := json.Unmarshal(data, &s1); err != nil { 2357 return err 2358 } 2359 s.Bottom = float64(s1.Bottom) 2360 s.Left = float64(s1.Left) 2361 s.Right = float64(s1.Right) 2362 s.Top = float64(s1.Top) 2363 return nil 2364 } 2365 2366 // GoogleCloudVideointelligenceV1beta2NormalizedBoundingPoly: Normalized 2367 // bounding polygon for text (that might not be aligned with axis). Contains 2368 // list of the corner points in clockwise order starting from top-left corner. 2369 // For example, for a rectangular bounding box: When the text is horizontal it 2370 // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees 2371 // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex 2372 // order will still be (0, 1, 2, 3). Note that values can be less than 0, or 2373 // greater than 1 due to trignometric calculations for location of the box. 2374 type GoogleCloudVideointelligenceV1beta2NormalizedBoundingPoly struct { 2375 // Vertices: Normalized vertices of the bounding polygon. 2376 Vertices []*GoogleCloudVideointelligenceV1beta2NormalizedVertex `json:"vertices,omitempty"` 2377 // ForceSendFields is a list of field names (e.g. "Vertices") to 2378 // unconditionally include in API requests. By default, fields with empty or 2379 // default values are omitted from API requests. See 2380 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2381 // details. 2382 ForceSendFields []string `json:"-"` 2383 // NullFields is a list of field names (e.g. "Vertices") to include in API 2384 // requests with the JSON null value. By default, fields with empty values are 2385 // omitted from API requests. See 2386 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2387 NullFields []string `json:"-"` 2388 } 2389 2390 func (s *GoogleCloudVideointelligenceV1beta2NormalizedBoundingPoly) MarshalJSON() ([]byte, error) { 2391 type NoMethod GoogleCloudVideointelligenceV1beta2NormalizedBoundingPoly 2392 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2393 } 2394 2395 // GoogleCloudVideointelligenceV1beta2NormalizedVertex: A vertex represents a 2396 // 2D point in the image. NOTE: the normalized vertex coordinates are relative 2397 // to the original image and range from 0 to 1. 2398 type GoogleCloudVideointelligenceV1beta2NormalizedVertex struct { 2399 // X: X coordinate. 2400 X float64 `json:"x,omitempty"` 2401 // Y: Y coordinate. 2402 Y float64 `json:"y,omitempty"` 2403 // ForceSendFields is a list of field names (e.g. "X") to unconditionally 2404 // include in API requests. By default, fields with empty or default values are 2405 // omitted from API requests. See 2406 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2407 // details. 2408 ForceSendFields []string `json:"-"` 2409 // NullFields is a list of field names (e.g. "X") to include in API requests 2410 // with the JSON null value. By default, fields with empty values are omitted 2411 // from API requests. See 2412 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2413 NullFields []string `json:"-"` 2414 } 2415 2416 func (s *GoogleCloudVideointelligenceV1beta2NormalizedVertex) MarshalJSON() ([]byte, error) { 2417 type NoMethod GoogleCloudVideointelligenceV1beta2NormalizedVertex 2418 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2419 } 2420 2421 func (s *GoogleCloudVideointelligenceV1beta2NormalizedVertex) UnmarshalJSON(data []byte) error { 2422 type NoMethod GoogleCloudVideointelligenceV1beta2NormalizedVertex 2423 var s1 struct { 2424 X gensupport.JSONFloat64 `json:"x"` 2425 Y gensupport.JSONFloat64 `json:"y"` 2426 *NoMethod 2427 } 2428 s1.NoMethod = (*NoMethod)(s) 2429 if err := json.Unmarshal(data, &s1); err != nil { 2430 return err 2431 } 2432 s.X = float64(s1.X) 2433 s.Y = float64(s1.Y) 2434 return nil 2435 } 2436 2437 // GoogleCloudVideointelligenceV1beta2ObjectTrackingAnnotation: Annotations 2438 // corresponding to one tracked object. 2439 type GoogleCloudVideointelligenceV1beta2ObjectTrackingAnnotation struct { 2440 // Confidence: Object category's labeling confidence of this track. 2441 Confidence float64 `json:"confidence,omitempty"` 2442 // Entity: Entity to specify the object category that this track is labeled as. 2443 Entity *GoogleCloudVideointelligenceV1beta2Entity `json:"entity,omitempty"` 2444 // Frames: Information corresponding to all frames where this object track 2445 // appears. Non-streaming batch mode: it may be one or multiple 2446 // ObjectTrackingFrame messages in frames. Streaming mode: it can only be one 2447 // ObjectTrackingFrame message in frames. 2448 Frames []*GoogleCloudVideointelligenceV1beta2ObjectTrackingFrame `json:"frames,omitempty"` 2449 // Segment: Non-streaming batch mode ONLY. Each object track corresponds to one 2450 // video segment where it appears. 2451 Segment *GoogleCloudVideointelligenceV1beta2VideoSegment `json:"segment,omitempty"` 2452 // TrackId: Streaming mode ONLY. In streaming mode, we do not know the end time 2453 // of a tracked object before it is completed. Hence, there is no VideoSegment 2454 // info returned. Instead, we provide a unique identifiable integer track_id so 2455 // that the customers can correlate the results of the ongoing 2456 // ObjectTrackAnnotation of the same track_id over time. 2457 TrackId int64 `json:"trackId,omitempty,string"` 2458 // Version: Feature version. 2459 Version string `json:"version,omitempty"` 2460 // ForceSendFields is a list of field names (e.g. "Confidence") to 2461 // unconditionally include in API requests. By default, fields with empty or 2462 // default values are omitted from API requests. See 2463 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2464 // details. 2465 ForceSendFields []string `json:"-"` 2466 // NullFields is a list of field names (e.g. "Confidence") to include in API 2467 // requests with the JSON null value. By default, fields with empty values are 2468 // omitted from API requests. See 2469 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2470 NullFields []string `json:"-"` 2471 } 2472 2473 func (s *GoogleCloudVideointelligenceV1beta2ObjectTrackingAnnotation) MarshalJSON() ([]byte, error) { 2474 type NoMethod GoogleCloudVideointelligenceV1beta2ObjectTrackingAnnotation 2475 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2476 } 2477 2478 func (s *GoogleCloudVideointelligenceV1beta2ObjectTrackingAnnotation) UnmarshalJSON(data []byte) error { 2479 type NoMethod GoogleCloudVideointelligenceV1beta2ObjectTrackingAnnotation 2480 var s1 struct { 2481 Confidence gensupport.JSONFloat64 `json:"confidence"` 2482 *NoMethod 2483 } 2484 s1.NoMethod = (*NoMethod)(s) 2485 if err := json.Unmarshal(data, &s1); err != nil { 2486 return err 2487 } 2488 s.Confidence = float64(s1.Confidence) 2489 return nil 2490 } 2491 2492 // GoogleCloudVideointelligenceV1beta2ObjectTrackingFrame: Video frame level 2493 // annotations for object detection and tracking. This field stores per frame 2494 // location, time offset, and confidence. 2495 type GoogleCloudVideointelligenceV1beta2ObjectTrackingFrame struct { 2496 // NormalizedBoundingBox: The normalized bounding box location of this object 2497 // track for the frame. 2498 NormalizedBoundingBox *GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox `json:"normalizedBoundingBox,omitempty"` 2499 // TimeOffset: The timestamp of the frame in microseconds. 2500 TimeOffset string `json:"timeOffset,omitempty"` 2501 // ForceSendFields is a list of field names (e.g. "NormalizedBoundingBox") to 2502 // unconditionally include in API requests. By default, fields with empty or 2503 // default values are omitted from API requests. See 2504 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2505 // details. 2506 ForceSendFields []string `json:"-"` 2507 // NullFields is a list of field names (e.g. "NormalizedBoundingBox") to 2508 // include in API requests with the JSON null value. By default, fields with 2509 // empty values are omitted from API requests. See 2510 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2511 NullFields []string `json:"-"` 2512 } 2513 2514 func (s *GoogleCloudVideointelligenceV1beta2ObjectTrackingFrame) MarshalJSON() ([]byte, error) { 2515 type NoMethod GoogleCloudVideointelligenceV1beta2ObjectTrackingFrame 2516 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2517 } 2518 2519 // GoogleCloudVideointelligenceV1beta2PersonDetectionAnnotation: Person 2520 // detection annotation per video. 2521 type GoogleCloudVideointelligenceV1beta2PersonDetectionAnnotation struct { 2522 // Tracks: The detected tracks of a person. 2523 Tracks []*GoogleCloudVideointelligenceV1beta2Track `json:"tracks,omitempty"` 2524 // Version: Feature version. 2525 Version string `json:"version,omitempty"` 2526 // ForceSendFields is a list of field names (e.g. "Tracks") to unconditionally 2527 // include in API requests. By default, fields with empty or default values are 2528 // omitted from API requests. See 2529 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2530 // details. 2531 ForceSendFields []string `json:"-"` 2532 // NullFields is a list of field names (e.g. "Tracks") to include in API 2533 // requests with the JSON null value. By default, fields with empty values are 2534 // omitted from API requests. See 2535 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2536 NullFields []string `json:"-"` 2537 } 2538 2539 func (s *GoogleCloudVideointelligenceV1beta2PersonDetectionAnnotation) MarshalJSON() ([]byte, error) { 2540 type NoMethod GoogleCloudVideointelligenceV1beta2PersonDetectionAnnotation 2541 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2542 } 2543 2544 // GoogleCloudVideointelligenceV1beta2SpeechRecognitionAlternative: Alternative 2545 // hypotheses (a.k.a. n-best list). 2546 type GoogleCloudVideointelligenceV1beta2SpeechRecognitionAlternative struct { 2547 // Confidence: Output only. The confidence estimate between 0.0 and 1.0. A 2548 // higher number indicates an estimated greater likelihood that the recognized 2549 // words are correct. This field is set only for the top alternative. This 2550 // field is not guaranteed to be accurate and users should not rely on it to be 2551 // always provided. The default of 0.0 is a sentinel value indicating 2552 // `confidence` was not set. 2553 Confidence float64 `json:"confidence,omitempty"` 2554 // Transcript: Transcript text representing the words that the user spoke. 2555 Transcript string `json:"transcript,omitempty"` 2556 // Words: Output only. A list of word-specific information for each recognized 2557 // word. Note: When `enable_speaker_diarization` is set to true, you will see 2558 // all the words from the beginning of the audio. 2559 Words []*GoogleCloudVideointelligenceV1beta2WordInfo `json:"words,omitempty"` 2560 // ForceSendFields is a list of field names (e.g. "Confidence") to 2561 // unconditionally include in API requests. By default, fields with empty or 2562 // default values are omitted from API requests. See 2563 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2564 // details. 2565 ForceSendFields []string `json:"-"` 2566 // NullFields is a list of field names (e.g. "Confidence") to include in API 2567 // requests with the JSON null value. By default, fields with empty values are 2568 // omitted from API requests. See 2569 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2570 NullFields []string `json:"-"` 2571 } 2572 2573 func (s *GoogleCloudVideointelligenceV1beta2SpeechRecognitionAlternative) MarshalJSON() ([]byte, error) { 2574 type NoMethod GoogleCloudVideointelligenceV1beta2SpeechRecognitionAlternative 2575 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2576 } 2577 2578 func (s *GoogleCloudVideointelligenceV1beta2SpeechRecognitionAlternative) UnmarshalJSON(data []byte) error { 2579 type NoMethod GoogleCloudVideointelligenceV1beta2SpeechRecognitionAlternative 2580 var s1 struct { 2581 Confidence gensupport.JSONFloat64 `json:"confidence"` 2582 *NoMethod 2583 } 2584 s1.NoMethod = (*NoMethod)(s) 2585 if err := json.Unmarshal(data, &s1); err != nil { 2586 return err 2587 } 2588 s.Confidence = float64(s1.Confidence) 2589 return nil 2590 } 2591 2592 // GoogleCloudVideointelligenceV1beta2SpeechTranscription: A speech recognition 2593 // result corresponding to a portion of the audio. 2594 type GoogleCloudVideointelligenceV1beta2SpeechTranscription struct { 2595 // Alternatives: May contain one or more recognition hypotheses (up to the 2596 // maximum specified in `max_alternatives`). These alternatives are ordered in 2597 // terms of accuracy, with the top (first) alternative being the most probable, 2598 // as ranked by the recognizer. 2599 Alternatives []*GoogleCloudVideointelligenceV1beta2SpeechRecognitionAlternative `json:"alternatives,omitempty"` 2600 // LanguageCode: Output only. The BCP-47 2601 // (https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag of the language 2602 // in this result. This language code was detected to have the most likelihood 2603 // of being spoken in the audio. 2604 LanguageCode string `json:"languageCode,omitempty"` 2605 // ForceSendFields is a list of field names (e.g. "Alternatives") to 2606 // unconditionally include in API requests. By default, fields with empty or 2607 // default values are omitted from API requests. See 2608 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2609 // details. 2610 ForceSendFields []string `json:"-"` 2611 // NullFields is a list of field names (e.g. "Alternatives") to include in API 2612 // requests with the JSON null value. By default, fields with empty values are 2613 // omitted from API requests. See 2614 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2615 NullFields []string `json:"-"` 2616 } 2617 2618 func (s *GoogleCloudVideointelligenceV1beta2SpeechTranscription) MarshalJSON() ([]byte, error) { 2619 type NoMethod GoogleCloudVideointelligenceV1beta2SpeechTranscription 2620 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2621 } 2622 2623 // GoogleCloudVideointelligenceV1beta2TextAnnotation: Annotations related to 2624 // one detected OCR text snippet. This will contain the corresponding text, 2625 // confidence value, and frame level information for each detection. 2626 type GoogleCloudVideointelligenceV1beta2TextAnnotation struct { 2627 // Segments: All video segments where OCR detected text appears. 2628 Segments []*GoogleCloudVideointelligenceV1beta2TextSegment `json:"segments,omitempty"` 2629 // Text: The detected text. 2630 Text string `json:"text,omitempty"` 2631 // Version: Feature version. 2632 Version string `json:"version,omitempty"` 2633 // ForceSendFields is a list of field names (e.g. "Segments") to 2634 // unconditionally include in API requests. By default, fields with empty or 2635 // default values are omitted from API requests. See 2636 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2637 // details. 2638 ForceSendFields []string `json:"-"` 2639 // NullFields is a list of field names (e.g. "Segments") to include in API 2640 // requests with the JSON null value. By default, fields with empty values are 2641 // omitted from API requests. See 2642 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2643 NullFields []string `json:"-"` 2644 } 2645 2646 func (s *GoogleCloudVideointelligenceV1beta2TextAnnotation) MarshalJSON() ([]byte, error) { 2647 type NoMethod GoogleCloudVideointelligenceV1beta2TextAnnotation 2648 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2649 } 2650 2651 // GoogleCloudVideointelligenceV1beta2TextFrame: Video frame level annotation 2652 // results for text annotation (OCR). Contains information regarding timestamp 2653 // and bounding box locations for the frames containing detected OCR text 2654 // snippets. 2655 type GoogleCloudVideointelligenceV1beta2TextFrame struct { 2656 // RotatedBoundingBox: Bounding polygon of the detected text for this frame. 2657 RotatedBoundingBox *GoogleCloudVideointelligenceV1beta2NormalizedBoundingPoly `json:"rotatedBoundingBox,omitempty"` 2658 // TimeOffset: Timestamp of this frame. 2659 TimeOffset string `json:"timeOffset,omitempty"` 2660 // ForceSendFields is a list of field names (e.g. "RotatedBoundingBox") to 2661 // unconditionally include in API requests. By default, fields with empty or 2662 // default values are omitted from API requests. See 2663 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2664 // details. 2665 ForceSendFields []string `json:"-"` 2666 // NullFields is a list of field names (e.g. "RotatedBoundingBox") to include 2667 // in API requests with the JSON null value. By default, fields with empty 2668 // values are omitted from API requests. See 2669 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2670 NullFields []string `json:"-"` 2671 } 2672 2673 func (s *GoogleCloudVideointelligenceV1beta2TextFrame) MarshalJSON() ([]byte, error) { 2674 type NoMethod GoogleCloudVideointelligenceV1beta2TextFrame 2675 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2676 } 2677 2678 // GoogleCloudVideointelligenceV1beta2TextSegment: Video segment level 2679 // annotation results for text detection. 2680 type GoogleCloudVideointelligenceV1beta2TextSegment struct { 2681 // Confidence: Confidence for the track of detected text. It is calculated as 2682 // the highest over all frames where OCR detected text appears. 2683 Confidence float64 `json:"confidence,omitempty"` 2684 // Frames: Information related to the frames where OCR detected text appears. 2685 Frames []*GoogleCloudVideointelligenceV1beta2TextFrame `json:"frames,omitempty"` 2686 // Segment: Video segment where a text snippet was detected. 2687 Segment *GoogleCloudVideointelligenceV1beta2VideoSegment `json:"segment,omitempty"` 2688 // ForceSendFields is a list of field names (e.g. "Confidence") to 2689 // unconditionally include in API requests. By default, fields with empty or 2690 // default values are omitted from API requests. See 2691 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2692 // details. 2693 ForceSendFields []string `json:"-"` 2694 // NullFields is a list of field names (e.g. "Confidence") to include in API 2695 // requests with the JSON null value. By default, fields with empty values are 2696 // omitted from API requests. See 2697 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2698 NullFields []string `json:"-"` 2699 } 2700 2701 func (s *GoogleCloudVideointelligenceV1beta2TextSegment) MarshalJSON() ([]byte, error) { 2702 type NoMethod GoogleCloudVideointelligenceV1beta2TextSegment 2703 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2704 } 2705 2706 func (s *GoogleCloudVideointelligenceV1beta2TextSegment) UnmarshalJSON(data []byte) error { 2707 type NoMethod GoogleCloudVideointelligenceV1beta2TextSegment 2708 var s1 struct { 2709 Confidence gensupport.JSONFloat64 `json:"confidence"` 2710 *NoMethod 2711 } 2712 s1.NoMethod = (*NoMethod)(s) 2713 if err := json.Unmarshal(data, &s1); err != nil { 2714 return err 2715 } 2716 s.Confidence = float64(s1.Confidence) 2717 return nil 2718 } 2719 2720 // GoogleCloudVideointelligenceV1beta2TimestampedObject: For tracking related 2721 // features. An object at time_offset with attributes, and located with 2722 // normalized_bounding_box. 2723 type GoogleCloudVideointelligenceV1beta2TimestampedObject struct { 2724 // Attributes: Optional. The attributes of the object in the bounding box. 2725 Attributes []*GoogleCloudVideointelligenceV1beta2DetectedAttribute `json:"attributes,omitempty"` 2726 // Landmarks: Optional. The detected landmarks. 2727 Landmarks []*GoogleCloudVideointelligenceV1beta2DetectedLandmark `json:"landmarks,omitempty"` 2728 // NormalizedBoundingBox: Normalized Bounding box in a frame, where the object 2729 // is located. 2730 NormalizedBoundingBox *GoogleCloudVideointelligenceV1beta2NormalizedBoundingBox `json:"normalizedBoundingBox,omitempty"` 2731 // TimeOffset: Time-offset, relative to the beginning of the video, 2732 // corresponding to the video frame for this object. 2733 TimeOffset string `json:"timeOffset,omitempty"` 2734 // ForceSendFields is a list of field names (e.g. "Attributes") to 2735 // unconditionally include in API requests. By default, fields with empty or 2736 // default values are omitted from API requests. See 2737 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2738 // details. 2739 ForceSendFields []string `json:"-"` 2740 // NullFields is a list of field names (e.g. "Attributes") to include in API 2741 // requests with the JSON null value. By default, fields with empty values are 2742 // omitted from API requests. See 2743 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2744 NullFields []string `json:"-"` 2745 } 2746 2747 func (s *GoogleCloudVideointelligenceV1beta2TimestampedObject) MarshalJSON() ([]byte, error) { 2748 type NoMethod GoogleCloudVideointelligenceV1beta2TimestampedObject 2749 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2750 } 2751 2752 // GoogleCloudVideointelligenceV1beta2Track: A track of an object instance. 2753 type GoogleCloudVideointelligenceV1beta2Track struct { 2754 // Attributes: Optional. Attributes in the track level. 2755 Attributes []*GoogleCloudVideointelligenceV1beta2DetectedAttribute `json:"attributes,omitempty"` 2756 // Confidence: Optional. The confidence score of the tracked object. 2757 Confidence float64 `json:"confidence,omitempty"` 2758 // Segment: Video segment of a track. 2759 Segment *GoogleCloudVideointelligenceV1beta2VideoSegment `json:"segment,omitempty"` 2760 // TimestampedObjects: The object with timestamp and attributes per frame in 2761 // the track. 2762 TimestampedObjects []*GoogleCloudVideointelligenceV1beta2TimestampedObject `json:"timestampedObjects,omitempty"` 2763 // ForceSendFields is a list of field names (e.g. "Attributes") to 2764 // unconditionally include in API requests. By default, fields with empty or 2765 // default values are omitted from API requests. See 2766 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2767 // details. 2768 ForceSendFields []string `json:"-"` 2769 // NullFields is a list of field names (e.g. "Attributes") to include in API 2770 // requests with the JSON null value. By default, fields with empty values are 2771 // omitted from API requests. See 2772 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2773 NullFields []string `json:"-"` 2774 } 2775 2776 func (s *GoogleCloudVideointelligenceV1beta2Track) MarshalJSON() ([]byte, error) { 2777 type NoMethod GoogleCloudVideointelligenceV1beta2Track 2778 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2779 } 2780 2781 func (s *GoogleCloudVideointelligenceV1beta2Track) UnmarshalJSON(data []byte) error { 2782 type NoMethod GoogleCloudVideointelligenceV1beta2Track 2783 var s1 struct { 2784 Confidence gensupport.JSONFloat64 `json:"confidence"` 2785 *NoMethod 2786 } 2787 s1.NoMethod = (*NoMethod)(s) 2788 if err := json.Unmarshal(data, &s1); err != nil { 2789 return err 2790 } 2791 s.Confidence = float64(s1.Confidence) 2792 return nil 2793 } 2794 2795 // GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress: Annotation 2796 // progress for a single video. 2797 type GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress struct { 2798 // Feature: Specifies which feature is being tracked if the request contains 2799 // more than one feature. 2800 // 2801 // Possible values: 2802 // "FEATURE_UNSPECIFIED" - Unspecified. 2803 // "LABEL_DETECTION" - Label detection. Detect objects, such as dog or 2804 // flower. 2805 // "SHOT_CHANGE_DETECTION" - Shot change detection. 2806 // "EXPLICIT_CONTENT_DETECTION" - Explicit content detection. 2807 // "FACE_DETECTION" - Human face detection. 2808 // "SPEECH_TRANSCRIPTION" - Speech transcription. 2809 // "TEXT_DETECTION" - OCR text detection and tracking. 2810 // "OBJECT_TRACKING" - Object detection and tracking. 2811 // "LOGO_RECOGNITION" - Logo detection, tracking, and recognition. 2812 // "PERSON_DETECTION" - Person detection. 2813 Feature string `json:"feature,omitempty"` 2814 // InputUri: Video file location in Cloud Storage 2815 // (https://cloud.google.com/storage/). 2816 InputUri string `json:"inputUri,omitempty"` 2817 // ProgressPercent: Approximate percentage processed thus far. Guaranteed to be 2818 // 100 when fully processed. 2819 ProgressPercent int64 `json:"progressPercent,omitempty"` 2820 // Segment: Specifies which segment is being tracked if the request contains 2821 // more than one segment. 2822 Segment *GoogleCloudVideointelligenceV1beta2VideoSegment `json:"segment,omitempty"` 2823 // StartTime: Time when the request was received. 2824 StartTime string `json:"startTime,omitempty"` 2825 // UpdateTime: Time of the most recent update. 2826 UpdateTime string `json:"updateTime,omitempty"` 2827 // ForceSendFields is a list of field names (e.g. "Feature") to unconditionally 2828 // include in API requests. By default, fields with empty or default values are 2829 // omitted from API requests. See 2830 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2831 // details. 2832 ForceSendFields []string `json:"-"` 2833 // NullFields is a list of field names (e.g. "Feature") to include in API 2834 // requests with the JSON null value. By default, fields with empty values are 2835 // omitted from API requests. See 2836 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2837 NullFields []string `json:"-"` 2838 } 2839 2840 func (s *GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress) MarshalJSON() ([]byte, error) { 2841 type NoMethod GoogleCloudVideointelligenceV1beta2VideoAnnotationProgress 2842 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2843 } 2844 2845 // GoogleCloudVideointelligenceV1beta2VideoAnnotationResults: Annotation 2846 // results for a single video. 2847 type GoogleCloudVideointelligenceV1beta2VideoAnnotationResults struct { 2848 // Error: If set, indicates an error. Note that for a single 2849 // `AnnotateVideoRequest` some videos may succeed and some may fail. 2850 Error *GoogleRpcStatus `json:"error,omitempty"` 2851 // ExplicitAnnotation: Explicit content annotation. 2852 ExplicitAnnotation *GoogleCloudVideointelligenceV1beta2ExplicitContentAnnotation `json:"explicitAnnotation,omitempty"` 2853 // FaceAnnotations: Deprecated. Please use `face_detection_annotations` 2854 // instead. 2855 FaceAnnotations []*GoogleCloudVideointelligenceV1beta2FaceAnnotation `json:"faceAnnotations,omitempty"` 2856 // FaceDetectionAnnotations: Face detection annotations. 2857 FaceDetectionAnnotations []*GoogleCloudVideointelligenceV1beta2FaceDetectionAnnotation `json:"faceDetectionAnnotations,omitempty"` 2858 // FrameLabelAnnotations: Label annotations on frame level. There is exactly 2859 // one element for each unique label. 2860 FrameLabelAnnotations []*GoogleCloudVideointelligenceV1beta2LabelAnnotation `json:"frameLabelAnnotations,omitempty"` 2861 // InputUri: Video file location in Cloud Storage 2862 // (https://cloud.google.com/storage/). 2863 InputUri string `json:"inputUri,omitempty"` 2864 // LogoRecognitionAnnotations: Annotations for list of logos detected, tracked 2865 // and recognized in video. 2866 LogoRecognitionAnnotations []*GoogleCloudVideointelligenceV1beta2LogoRecognitionAnnotation `json:"logoRecognitionAnnotations,omitempty"` 2867 // ObjectAnnotations: Annotations for list of objects detected and tracked in 2868 // video. 2869 ObjectAnnotations []*GoogleCloudVideointelligenceV1beta2ObjectTrackingAnnotation `json:"objectAnnotations,omitempty"` 2870 // PersonDetectionAnnotations: Person detection annotations. 2871 PersonDetectionAnnotations []*GoogleCloudVideointelligenceV1beta2PersonDetectionAnnotation `json:"personDetectionAnnotations,omitempty"` 2872 // Segment: Video segment on which the annotation is run. 2873 Segment *GoogleCloudVideointelligenceV1beta2VideoSegment `json:"segment,omitempty"` 2874 // SegmentLabelAnnotations: Topical label annotations on video level or 2875 // user-specified segment level. There is exactly one element for each unique 2876 // label. 2877 SegmentLabelAnnotations []*GoogleCloudVideointelligenceV1beta2LabelAnnotation `json:"segmentLabelAnnotations,omitempty"` 2878 // SegmentPresenceLabelAnnotations: Presence label annotations on video level 2879 // or user-specified segment level. There is exactly one element for each 2880 // unique label. Compared to the existing topical `segment_label_annotations`, 2881 // this field presents more fine-grained, segment-level labels detected in 2882 // video content and is made available only when the client sets 2883 // `LabelDetectionConfig.model` to "builtin/latest" in the request. 2884 SegmentPresenceLabelAnnotations []*GoogleCloudVideointelligenceV1beta2LabelAnnotation `json:"segmentPresenceLabelAnnotations,omitempty"` 2885 // ShotAnnotations: Shot annotations. Each shot is represented as a video 2886 // segment. 2887 ShotAnnotations []*GoogleCloudVideointelligenceV1beta2VideoSegment `json:"shotAnnotations,omitempty"` 2888 // ShotLabelAnnotations: Topical label annotations on shot level. There is 2889 // exactly one element for each unique label. 2890 ShotLabelAnnotations []*GoogleCloudVideointelligenceV1beta2LabelAnnotation `json:"shotLabelAnnotations,omitempty"` 2891 // ShotPresenceLabelAnnotations: Presence label annotations on shot level. 2892 // There is exactly one element for each unique label. Compared to the existing 2893 // topical `shot_label_annotations`, this field presents more fine-grained, 2894 // shot-level labels detected in video content and is made available only when 2895 // the client sets `LabelDetectionConfig.model` to "builtin/latest" in the 2896 // request. 2897 ShotPresenceLabelAnnotations []*GoogleCloudVideointelligenceV1beta2LabelAnnotation `json:"shotPresenceLabelAnnotations,omitempty"` 2898 // SpeechTranscriptions: Speech transcription. 2899 SpeechTranscriptions []*GoogleCloudVideointelligenceV1beta2SpeechTranscription `json:"speechTranscriptions,omitempty"` 2900 // TextAnnotations: OCR text detection and tracking. Annotations for list of 2901 // detected text snippets. Each will have list of frame information associated 2902 // with it. 2903 TextAnnotations []*GoogleCloudVideointelligenceV1beta2TextAnnotation `json:"textAnnotations,omitempty"` 2904 // ForceSendFields is a list of field names (e.g. "Error") to unconditionally 2905 // include in API requests. By default, fields with empty or default values are 2906 // omitted from API requests. See 2907 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2908 // details. 2909 ForceSendFields []string `json:"-"` 2910 // NullFields is a list of field names (e.g. "Error") to include in API 2911 // requests with the JSON null value. By default, fields with empty values are 2912 // omitted from API requests. See 2913 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2914 NullFields []string `json:"-"` 2915 } 2916 2917 func (s *GoogleCloudVideointelligenceV1beta2VideoAnnotationResults) MarshalJSON() ([]byte, error) { 2918 type NoMethod GoogleCloudVideointelligenceV1beta2VideoAnnotationResults 2919 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2920 } 2921 2922 // GoogleCloudVideointelligenceV1beta2VideoSegment: Video segment. 2923 type GoogleCloudVideointelligenceV1beta2VideoSegment struct { 2924 // EndTimeOffset: Time-offset, relative to the beginning of the video, 2925 // corresponding to the end of the segment (inclusive). 2926 EndTimeOffset string `json:"endTimeOffset,omitempty"` 2927 // StartTimeOffset: Time-offset, relative to the beginning of the video, 2928 // corresponding to the start of the segment (inclusive). 2929 StartTimeOffset string `json:"startTimeOffset,omitempty"` 2930 // ForceSendFields is a list of field names (e.g. "EndTimeOffset") to 2931 // unconditionally include in API requests. By default, fields with empty or 2932 // default values are omitted from API requests. See 2933 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2934 // details. 2935 ForceSendFields []string `json:"-"` 2936 // NullFields is a list of field names (e.g. "EndTimeOffset") to include in API 2937 // requests with the JSON null value. By default, fields with empty values are 2938 // omitted from API requests. See 2939 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2940 NullFields []string `json:"-"` 2941 } 2942 2943 func (s *GoogleCloudVideointelligenceV1beta2VideoSegment) MarshalJSON() ([]byte, error) { 2944 type NoMethod GoogleCloudVideointelligenceV1beta2VideoSegment 2945 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2946 } 2947 2948 // GoogleCloudVideointelligenceV1beta2WordInfo: Word-specific information for 2949 // recognized words. Word information is only included in the response when 2950 // certain request parameters are set, such as `enable_word_time_offsets`. 2951 type GoogleCloudVideointelligenceV1beta2WordInfo struct { 2952 // Confidence: Output only. The confidence estimate between 0.0 and 1.0. A 2953 // higher number indicates an estimated greater likelihood that the recognized 2954 // words are correct. This field is set only for the top alternative. This 2955 // field is not guaranteed to be accurate and users should not rely on it to be 2956 // always provided. The default of 0.0 is a sentinel value indicating 2957 // `confidence` was not set. 2958 Confidence float64 `json:"confidence,omitempty"` 2959 // EndTime: Time offset relative to the beginning of the audio, and 2960 // corresponding to the end of the spoken word. This field is only set if 2961 // `enable_word_time_offsets=true` and only in the top hypothesis. This is an 2962 // experimental feature and the accuracy of the time offset can vary. 2963 EndTime string `json:"endTime,omitempty"` 2964 // SpeakerTag: Output only. A distinct integer value is assigned for every 2965 // speaker within the audio. This field specifies which one of those speakers 2966 // was detected to have spoken this word. Value ranges from 1 up to 2967 // diarization_speaker_count, and is only set if speaker diarization is 2968 // enabled. 2969 SpeakerTag int64 `json:"speakerTag,omitempty"` 2970 // StartTime: Time offset relative to the beginning of the audio, and 2971 // corresponding to the start of the spoken word. This field is only set if 2972 // `enable_word_time_offsets=true` and only in the top hypothesis. This is an 2973 // experimental feature and the accuracy of the time offset can vary. 2974 StartTime string `json:"startTime,omitempty"` 2975 // Word: The word corresponding to this set of information. 2976 Word string `json:"word,omitempty"` 2977 // ForceSendFields is a list of field names (e.g. "Confidence") to 2978 // unconditionally include in API requests. By default, fields with empty or 2979 // default values are omitted from API requests. See 2980 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 2981 // details. 2982 ForceSendFields []string `json:"-"` 2983 // NullFields is a list of field names (e.g. "Confidence") to include in API 2984 // requests with the JSON null value. By default, fields with empty values are 2985 // omitted from API requests. See 2986 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 2987 NullFields []string `json:"-"` 2988 } 2989 2990 func (s *GoogleCloudVideointelligenceV1beta2WordInfo) MarshalJSON() ([]byte, error) { 2991 type NoMethod GoogleCloudVideointelligenceV1beta2WordInfo 2992 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 2993 } 2994 2995 func (s *GoogleCloudVideointelligenceV1beta2WordInfo) UnmarshalJSON(data []byte) error { 2996 type NoMethod GoogleCloudVideointelligenceV1beta2WordInfo 2997 var s1 struct { 2998 Confidence gensupport.JSONFloat64 `json:"confidence"` 2999 *NoMethod 3000 } 3001 s1.NoMethod = (*NoMethod)(s) 3002 if err := json.Unmarshal(data, &s1); err != nil { 3003 return err 3004 } 3005 s.Confidence = float64(s1.Confidence) 3006 return nil 3007 } 3008 3009 // GoogleCloudVideointelligenceV1p1beta1AnnotateVideoProgress: Video annotation 3010 // progress. Included in the `metadata` field of the `Operation` returned by 3011 // the `GetOperation` call of the `google::longrunning::Operations` service. 3012 type GoogleCloudVideointelligenceV1p1beta1AnnotateVideoProgress struct { 3013 // AnnotationProgress: Progress metadata for all videos specified in 3014 // `AnnotateVideoRequest`. 3015 AnnotationProgress []*GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress `json:"annotationProgress,omitempty"` 3016 // ForceSendFields is a list of field names (e.g. "AnnotationProgress") to 3017 // unconditionally include in API requests. By default, fields with empty or 3018 // default values are omitted from API requests. See 3019 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3020 // details. 3021 ForceSendFields []string `json:"-"` 3022 // NullFields is a list of field names (e.g. "AnnotationProgress") to include 3023 // in API requests with the JSON null value. By default, fields with empty 3024 // values are omitted from API requests. See 3025 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3026 NullFields []string `json:"-"` 3027 } 3028 3029 func (s *GoogleCloudVideointelligenceV1p1beta1AnnotateVideoProgress) MarshalJSON() ([]byte, error) { 3030 type NoMethod GoogleCloudVideointelligenceV1p1beta1AnnotateVideoProgress 3031 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3032 } 3033 3034 // GoogleCloudVideointelligenceV1p1beta1AnnotateVideoResponse: Video annotation 3035 // response. Included in the `response` field of the `Operation` returned by 3036 // the `GetOperation` call of the `google::longrunning::Operations` service. 3037 type GoogleCloudVideointelligenceV1p1beta1AnnotateVideoResponse struct { 3038 // AnnotationResults: Annotation results for all videos specified in 3039 // `AnnotateVideoRequest`. 3040 AnnotationResults []*GoogleCloudVideointelligenceV1p1beta1VideoAnnotationResults `json:"annotationResults,omitempty"` 3041 // ForceSendFields is a list of field names (e.g. "AnnotationResults") to 3042 // unconditionally include in API requests. By default, fields with empty or 3043 // default values are omitted from API requests. See 3044 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3045 // details. 3046 ForceSendFields []string `json:"-"` 3047 // NullFields is a list of field names (e.g. "AnnotationResults") to include in 3048 // API requests with the JSON null value. By default, fields with empty values 3049 // are omitted from API requests. See 3050 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3051 NullFields []string `json:"-"` 3052 } 3053 3054 func (s *GoogleCloudVideointelligenceV1p1beta1AnnotateVideoResponse) MarshalJSON() ([]byte, error) { 3055 type NoMethod GoogleCloudVideointelligenceV1p1beta1AnnotateVideoResponse 3056 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3057 } 3058 3059 // GoogleCloudVideointelligenceV1p1beta1DetectedAttribute: A generic detected 3060 // attribute represented by name in string format. 3061 type GoogleCloudVideointelligenceV1p1beta1DetectedAttribute struct { 3062 // Confidence: Detected attribute confidence. Range [0, 1]. 3063 Confidence float64 `json:"confidence,omitempty"` 3064 // Name: The name of the attribute, for example, glasses, dark_glasses, 3065 // mouth_open. A full list of supported type names will be provided in the 3066 // document. 3067 Name string `json:"name,omitempty"` 3068 // Value: Text value of the detection result. For example, the value for 3069 // "HairColor" can be "black", "blonde", etc. 3070 Value string `json:"value,omitempty"` 3071 // ForceSendFields is a list of field names (e.g. "Confidence") to 3072 // unconditionally include in API requests. By default, fields with empty or 3073 // default values are omitted from API requests. See 3074 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3075 // details. 3076 ForceSendFields []string `json:"-"` 3077 // NullFields is a list of field names (e.g. "Confidence") to include in API 3078 // requests with the JSON null value. By default, fields with empty values are 3079 // omitted from API requests. See 3080 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3081 NullFields []string `json:"-"` 3082 } 3083 3084 func (s *GoogleCloudVideointelligenceV1p1beta1DetectedAttribute) MarshalJSON() ([]byte, error) { 3085 type NoMethod GoogleCloudVideointelligenceV1p1beta1DetectedAttribute 3086 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3087 } 3088 3089 func (s *GoogleCloudVideointelligenceV1p1beta1DetectedAttribute) UnmarshalJSON(data []byte) error { 3090 type NoMethod GoogleCloudVideointelligenceV1p1beta1DetectedAttribute 3091 var s1 struct { 3092 Confidence gensupport.JSONFloat64 `json:"confidence"` 3093 *NoMethod 3094 } 3095 s1.NoMethod = (*NoMethod)(s) 3096 if err := json.Unmarshal(data, &s1); err != nil { 3097 return err 3098 } 3099 s.Confidence = float64(s1.Confidence) 3100 return nil 3101 } 3102 3103 // GoogleCloudVideointelligenceV1p1beta1DetectedLandmark: A generic detected 3104 // landmark represented by name in string format and a 2D location. 3105 type GoogleCloudVideointelligenceV1p1beta1DetectedLandmark struct { 3106 // Confidence: The confidence score of the detected landmark. Range [0, 1]. 3107 Confidence float64 `json:"confidence,omitempty"` 3108 // Name: The name of this landmark, for example, left_hand, right_shoulder. 3109 Name string `json:"name,omitempty"` 3110 // Point: The 2D point of the detected landmark using the normalized image 3111 // coordindate system. The normalized coordinates have the range from 0 to 1. 3112 Point *GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"point,omitempty"` 3113 // ForceSendFields is a list of field names (e.g. "Confidence") to 3114 // unconditionally include in API requests. By default, fields with empty or 3115 // default values are omitted from API requests. See 3116 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3117 // details. 3118 ForceSendFields []string `json:"-"` 3119 // NullFields is a list of field names (e.g. "Confidence") to include in API 3120 // requests with the JSON null value. By default, fields with empty values are 3121 // omitted from API requests. See 3122 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3123 NullFields []string `json:"-"` 3124 } 3125 3126 func (s *GoogleCloudVideointelligenceV1p1beta1DetectedLandmark) MarshalJSON() ([]byte, error) { 3127 type NoMethod GoogleCloudVideointelligenceV1p1beta1DetectedLandmark 3128 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3129 } 3130 3131 func (s *GoogleCloudVideointelligenceV1p1beta1DetectedLandmark) UnmarshalJSON(data []byte) error { 3132 type NoMethod GoogleCloudVideointelligenceV1p1beta1DetectedLandmark 3133 var s1 struct { 3134 Confidence gensupport.JSONFloat64 `json:"confidence"` 3135 *NoMethod 3136 } 3137 s1.NoMethod = (*NoMethod)(s) 3138 if err := json.Unmarshal(data, &s1); err != nil { 3139 return err 3140 } 3141 s.Confidence = float64(s1.Confidence) 3142 return nil 3143 } 3144 3145 // GoogleCloudVideointelligenceV1p1beta1Entity: Detected entity from video 3146 // analysis. 3147 type GoogleCloudVideointelligenceV1p1beta1Entity struct { 3148 // Description: Textual description, e.g., `Fixed-gear bicycle`. 3149 Description string `json:"description,omitempty"` 3150 // EntityId: Opaque entity ID. Some IDs may be available in Google Knowledge 3151 // Graph Search API (https://developers.google.com/knowledge-graph/). 3152 EntityId string `json:"entityId,omitempty"` 3153 // LanguageCode: Language code for `description` in BCP-47 format. 3154 LanguageCode string `json:"languageCode,omitempty"` 3155 // ForceSendFields is a list of field names (e.g. "Description") to 3156 // unconditionally include in API requests. By default, fields with empty or 3157 // default values are omitted from API requests. See 3158 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3159 // details. 3160 ForceSendFields []string `json:"-"` 3161 // NullFields is a list of field names (e.g. "Description") to include in API 3162 // requests with the JSON null value. By default, fields with empty values are 3163 // omitted from API requests. See 3164 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3165 NullFields []string `json:"-"` 3166 } 3167 3168 func (s *GoogleCloudVideointelligenceV1p1beta1Entity) MarshalJSON() ([]byte, error) { 3169 type NoMethod GoogleCloudVideointelligenceV1p1beta1Entity 3170 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3171 } 3172 3173 // GoogleCloudVideointelligenceV1p1beta1ExplicitContentAnnotation: Explicit 3174 // content annotation (based on per-frame visual signals only). If no explicit 3175 // content has been detected in a frame, no annotations are present for that 3176 // frame. 3177 type GoogleCloudVideointelligenceV1p1beta1ExplicitContentAnnotation struct { 3178 // Frames: All video frames where explicit content was detected. 3179 Frames []*GoogleCloudVideointelligenceV1p1beta1ExplicitContentFrame `json:"frames,omitempty"` 3180 // Version: Feature version. 3181 Version string `json:"version,omitempty"` 3182 // ForceSendFields is a list of field names (e.g. "Frames") to unconditionally 3183 // include in API requests. By default, fields with empty or default values are 3184 // omitted from API requests. See 3185 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3186 // details. 3187 ForceSendFields []string `json:"-"` 3188 // NullFields is a list of field names (e.g. "Frames") to include in API 3189 // requests with the JSON null value. By default, fields with empty values are 3190 // omitted from API requests. See 3191 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3192 NullFields []string `json:"-"` 3193 } 3194 3195 func (s *GoogleCloudVideointelligenceV1p1beta1ExplicitContentAnnotation) MarshalJSON() ([]byte, error) { 3196 type NoMethod GoogleCloudVideointelligenceV1p1beta1ExplicitContentAnnotation 3197 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3198 } 3199 3200 // GoogleCloudVideointelligenceV1p1beta1ExplicitContentFrame: Video frame level 3201 // annotation results for explicit content. 3202 type GoogleCloudVideointelligenceV1p1beta1ExplicitContentFrame struct { 3203 // PornographyLikelihood: Likelihood of the pornography content.. 3204 // 3205 // Possible values: 3206 // "LIKELIHOOD_UNSPECIFIED" - Unspecified likelihood. 3207 // "VERY_UNLIKELY" - Very unlikely. 3208 // "UNLIKELY" - Unlikely. 3209 // "POSSIBLE" - Possible. 3210 // "LIKELY" - Likely. 3211 // "VERY_LIKELY" - Very likely. 3212 PornographyLikelihood string `json:"pornographyLikelihood,omitempty"` 3213 // TimeOffset: Time-offset, relative to the beginning of the video, 3214 // corresponding to the video frame for this location. 3215 TimeOffset string `json:"timeOffset,omitempty"` 3216 // ForceSendFields is a list of field names (e.g. "PornographyLikelihood") to 3217 // unconditionally include in API requests. By default, fields with empty or 3218 // default values are omitted from API requests. See 3219 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3220 // details. 3221 ForceSendFields []string `json:"-"` 3222 // NullFields is a list of field names (e.g. "PornographyLikelihood") to 3223 // include in API requests with the JSON null value. By default, fields with 3224 // empty values are omitted from API requests. See 3225 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3226 NullFields []string `json:"-"` 3227 } 3228 3229 func (s *GoogleCloudVideointelligenceV1p1beta1ExplicitContentFrame) MarshalJSON() ([]byte, error) { 3230 type NoMethod GoogleCloudVideointelligenceV1p1beta1ExplicitContentFrame 3231 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3232 } 3233 3234 // GoogleCloudVideointelligenceV1p1beta1FaceAnnotation: Deprecated. No effect. 3235 type GoogleCloudVideointelligenceV1p1beta1FaceAnnotation struct { 3236 // Frames: All video frames where a face was detected. 3237 Frames []*GoogleCloudVideointelligenceV1p1beta1FaceFrame `json:"frames,omitempty"` 3238 // Segments: All video segments where a face was detected. 3239 Segments []*GoogleCloudVideointelligenceV1p1beta1FaceSegment `json:"segments,omitempty"` 3240 // Thumbnail: Thumbnail of a representative face view (in JPEG format). 3241 Thumbnail string `json:"thumbnail,omitempty"` 3242 // ForceSendFields is a list of field names (e.g. "Frames") to unconditionally 3243 // include in API requests. By default, fields with empty or default values are 3244 // omitted from API requests. See 3245 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3246 // details. 3247 ForceSendFields []string `json:"-"` 3248 // NullFields is a list of field names (e.g. "Frames") to include in API 3249 // requests with the JSON null value. By default, fields with empty values are 3250 // omitted from API requests. See 3251 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3252 NullFields []string `json:"-"` 3253 } 3254 3255 func (s *GoogleCloudVideointelligenceV1p1beta1FaceAnnotation) MarshalJSON() ([]byte, error) { 3256 type NoMethod GoogleCloudVideointelligenceV1p1beta1FaceAnnotation 3257 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3258 } 3259 3260 // GoogleCloudVideointelligenceV1p1beta1FaceDetectionAnnotation: Face detection 3261 // annotation. 3262 type GoogleCloudVideointelligenceV1p1beta1FaceDetectionAnnotation struct { 3263 // Thumbnail: The thumbnail of a person's face. 3264 Thumbnail string `json:"thumbnail,omitempty"` 3265 // Tracks: The face tracks with attributes. 3266 Tracks []*GoogleCloudVideointelligenceV1p1beta1Track `json:"tracks,omitempty"` 3267 // Version: Feature version. 3268 Version string `json:"version,omitempty"` 3269 // ForceSendFields is a list of field names (e.g. "Thumbnail") to 3270 // unconditionally include in API requests. By default, fields with empty or 3271 // default values are omitted from API requests. See 3272 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3273 // details. 3274 ForceSendFields []string `json:"-"` 3275 // NullFields is a list of field names (e.g. "Thumbnail") to include in API 3276 // requests with the JSON null value. By default, fields with empty values are 3277 // omitted from API requests. See 3278 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3279 NullFields []string `json:"-"` 3280 } 3281 3282 func (s *GoogleCloudVideointelligenceV1p1beta1FaceDetectionAnnotation) MarshalJSON() ([]byte, error) { 3283 type NoMethod GoogleCloudVideointelligenceV1p1beta1FaceDetectionAnnotation 3284 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3285 } 3286 3287 // GoogleCloudVideointelligenceV1p1beta1FaceFrame: Deprecated. No effect. 3288 type GoogleCloudVideointelligenceV1p1beta1FaceFrame struct { 3289 // NormalizedBoundingBoxes: Normalized Bounding boxes in a frame. There can be 3290 // more than one boxes if the same face is detected in multiple locations 3291 // within the current frame. 3292 NormalizedBoundingBoxes []*GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox `json:"normalizedBoundingBoxes,omitempty"` 3293 // TimeOffset: Time-offset, relative to the beginning of the video, 3294 // corresponding to the video frame for this location. 3295 TimeOffset string `json:"timeOffset,omitempty"` 3296 // ForceSendFields is a list of field names (e.g. "NormalizedBoundingBoxes") to 3297 // unconditionally include in API requests. By default, fields with empty or 3298 // default values are omitted from API requests. See 3299 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3300 // details. 3301 ForceSendFields []string `json:"-"` 3302 // NullFields is a list of field names (e.g. "NormalizedBoundingBoxes") to 3303 // include in API requests with the JSON null value. By default, fields with 3304 // empty values are omitted from API requests. See 3305 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3306 NullFields []string `json:"-"` 3307 } 3308 3309 func (s *GoogleCloudVideointelligenceV1p1beta1FaceFrame) MarshalJSON() ([]byte, error) { 3310 type NoMethod GoogleCloudVideointelligenceV1p1beta1FaceFrame 3311 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3312 } 3313 3314 // GoogleCloudVideointelligenceV1p1beta1FaceSegment: Video segment level 3315 // annotation results for face detection. 3316 type GoogleCloudVideointelligenceV1p1beta1FaceSegment struct { 3317 // Segment: Video segment where a face was detected. 3318 Segment *GoogleCloudVideointelligenceV1p1beta1VideoSegment `json:"segment,omitempty"` 3319 // ForceSendFields is a list of field names (e.g. "Segment") to unconditionally 3320 // include in API requests. By default, fields with empty or default values are 3321 // omitted from API requests. See 3322 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3323 // details. 3324 ForceSendFields []string `json:"-"` 3325 // NullFields is a list of field names (e.g. "Segment") to include in API 3326 // requests with the JSON null value. By default, fields with empty values are 3327 // omitted from API requests. See 3328 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3329 NullFields []string `json:"-"` 3330 } 3331 3332 func (s *GoogleCloudVideointelligenceV1p1beta1FaceSegment) MarshalJSON() ([]byte, error) { 3333 type NoMethod GoogleCloudVideointelligenceV1p1beta1FaceSegment 3334 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3335 } 3336 3337 // GoogleCloudVideointelligenceV1p1beta1LabelAnnotation: Label annotation. 3338 type GoogleCloudVideointelligenceV1p1beta1LabelAnnotation struct { 3339 // CategoryEntities: Common categories for the detected entity. For example, 3340 // when the label is `Terrier`, the category is likely `dog`. And in some cases 3341 // there might be more than one categories e.g., `Terrier` could also be a 3342 // `pet`. 3343 CategoryEntities []*GoogleCloudVideointelligenceV1p1beta1Entity `json:"categoryEntities,omitempty"` 3344 // Entity: Detected entity. 3345 Entity *GoogleCloudVideointelligenceV1p1beta1Entity `json:"entity,omitempty"` 3346 // Frames: All video frames where a label was detected. 3347 Frames []*GoogleCloudVideointelligenceV1p1beta1LabelFrame `json:"frames,omitempty"` 3348 // Segments: All video segments where a label was detected. 3349 Segments []*GoogleCloudVideointelligenceV1p1beta1LabelSegment `json:"segments,omitempty"` 3350 // Version: Feature version. 3351 Version string `json:"version,omitempty"` 3352 // ForceSendFields is a list of field names (e.g. "CategoryEntities") to 3353 // unconditionally include in API requests. By default, fields with empty or 3354 // default values are omitted from API requests. See 3355 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3356 // details. 3357 ForceSendFields []string `json:"-"` 3358 // NullFields is a list of field names (e.g. "CategoryEntities") to include in 3359 // API requests with the JSON null value. By default, fields with empty values 3360 // are omitted from API requests. See 3361 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3362 NullFields []string `json:"-"` 3363 } 3364 3365 func (s *GoogleCloudVideointelligenceV1p1beta1LabelAnnotation) MarshalJSON() ([]byte, error) { 3366 type NoMethod GoogleCloudVideointelligenceV1p1beta1LabelAnnotation 3367 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3368 } 3369 3370 // GoogleCloudVideointelligenceV1p1beta1LabelFrame: Video frame level 3371 // annotation results for label detection. 3372 type GoogleCloudVideointelligenceV1p1beta1LabelFrame struct { 3373 // Confidence: Confidence that the label is accurate. Range: [0, 1]. 3374 Confidence float64 `json:"confidence,omitempty"` 3375 // TimeOffset: Time-offset, relative to the beginning of the video, 3376 // corresponding to the video frame for this location. 3377 TimeOffset string `json:"timeOffset,omitempty"` 3378 // ForceSendFields is a list of field names (e.g. "Confidence") to 3379 // unconditionally include in API requests. By default, fields with empty or 3380 // default values are omitted from API requests. See 3381 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3382 // details. 3383 ForceSendFields []string `json:"-"` 3384 // NullFields is a list of field names (e.g. "Confidence") to include in API 3385 // requests with the JSON null value. By default, fields with empty values are 3386 // omitted from API requests. See 3387 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3388 NullFields []string `json:"-"` 3389 } 3390 3391 func (s *GoogleCloudVideointelligenceV1p1beta1LabelFrame) MarshalJSON() ([]byte, error) { 3392 type NoMethod GoogleCloudVideointelligenceV1p1beta1LabelFrame 3393 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3394 } 3395 3396 func (s *GoogleCloudVideointelligenceV1p1beta1LabelFrame) UnmarshalJSON(data []byte) error { 3397 type NoMethod GoogleCloudVideointelligenceV1p1beta1LabelFrame 3398 var s1 struct { 3399 Confidence gensupport.JSONFloat64 `json:"confidence"` 3400 *NoMethod 3401 } 3402 s1.NoMethod = (*NoMethod)(s) 3403 if err := json.Unmarshal(data, &s1); err != nil { 3404 return err 3405 } 3406 s.Confidence = float64(s1.Confidence) 3407 return nil 3408 } 3409 3410 // GoogleCloudVideointelligenceV1p1beta1LabelSegment: Video segment level 3411 // annotation results for label detection. 3412 type GoogleCloudVideointelligenceV1p1beta1LabelSegment struct { 3413 // Confidence: Confidence that the label is accurate. Range: [0, 1]. 3414 Confidence float64 `json:"confidence,omitempty"` 3415 // Segment: Video segment where a label was detected. 3416 Segment *GoogleCloudVideointelligenceV1p1beta1VideoSegment `json:"segment,omitempty"` 3417 // ForceSendFields is a list of field names (e.g. "Confidence") to 3418 // unconditionally include in API requests. By default, fields with empty or 3419 // default values are omitted from API requests. See 3420 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3421 // details. 3422 ForceSendFields []string `json:"-"` 3423 // NullFields is a list of field names (e.g. "Confidence") to include in API 3424 // requests with the JSON null value. By default, fields with empty values are 3425 // omitted from API requests. See 3426 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3427 NullFields []string `json:"-"` 3428 } 3429 3430 func (s *GoogleCloudVideointelligenceV1p1beta1LabelSegment) MarshalJSON() ([]byte, error) { 3431 type NoMethod GoogleCloudVideointelligenceV1p1beta1LabelSegment 3432 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3433 } 3434 3435 func (s *GoogleCloudVideointelligenceV1p1beta1LabelSegment) UnmarshalJSON(data []byte) error { 3436 type NoMethod GoogleCloudVideointelligenceV1p1beta1LabelSegment 3437 var s1 struct { 3438 Confidence gensupport.JSONFloat64 `json:"confidence"` 3439 *NoMethod 3440 } 3441 s1.NoMethod = (*NoMethod)(s) 3442 if err := json.Unmarshal(data, &s1); err != nil { 3443 return err 3444 } 3445 s.Confidence = float64(s1.Confidence) 3446 return nil 3447 } 3448 3449 // GoogleCloudVideointelligenceV1p1beta1LogoRecognitionAnnotation: Annotation 3450 // corresponding to one detected, tracked and recognized logo class. 3451 type GoogleCloudVideointelligenceV1p1beta1LogoRecognitionAnnotation struct { 3452 // Entity: Entity category information to specify the logo class that all the 3453 // logo tracks within this LogoRecognitionAnnotation are recognized as. 3454 Entity *GoogleCloudVideointelligenceV1p1beta1Entity `json:"entity,omitempty"` 3455 // Segments: All video segments where the recognized logo appears. There might 3456 // be multiple instances of the same logo class appearing in one VideoSegment. 3457 Segments []*GoogleCloudVideointelligenceV1p1beta1VideoSegment `json:"segments,omitempty"` 3458 // Tracks: All logo tracks where the recognized logo appears. Each track 3459 // corresponds to one logo instance appearing in consecutive frames. 3460 Tracks []*GoogleCloudVideointelligenceV1p1beta1Track `json:"tracks,omitempty"` 3461 // ForceSendFields is a list of field names (e.g. "Entity") to unconditionally 3462 // include in API requests. By default, fields with empty or default values are 3463 // omitted from API requests. See 3464 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3465 // details. 3466 ForceSendFields []string `json:"-"` 3467 // NullFields is a list of field names (e.g. "Entity") to include in API 3468 // requests with the JSON null value. By default, fields with empty values are 3469 // omitted from API requests. See 3470 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3471 NullFields []string `json:"-"` 3472 } 3473 3474 func (s *GoogleCloudVideointelligenceV1p1beta1LogoRecognitionAnnotation) MarshalJSON() ([]byte, error) { 3475 type NoMethod GoogleCloudVideointelligenceV1p1beta1LogoRecognitionAnnotation 3476 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3477 } 3478 3479 // GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox: Normalized 3480 // bounding box. The normalized vertex coordinates are relative to the original 3481 // image. Range: [0, 1]. 3482 type GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox struct { 3483 // Bottom: Bottom Y coordinate. 3484 Bottom float64 `json:"bottom,omitempty"` 3485 // Left: Left X coordinate. 3486 Left float64 `json:"left,omitempty"` 3487 // Right: Right X coordinate. 3488 Right float64 `json:"right,omitempty"` 3489 // Top: Top Y coordinate. 3490 Top float64 `json:"top,omitempty"` 3491 // ForceSendFields is a list of field names (e.g. "Bottom") to unconditionally 3492 // include in API requests. By default, fields with empty or default values are 3493 // omitted from API requests. See 3494 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3495 // details. 3496 ForceSendFields []string `json:"-"` 3497 // NullFields is a list of field names (e.g. "Bottom") to include in API 3498 // requests with the JSON null value. By default, fields with empty values are 3499 // omitted from API requests. See 3500 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3501 NullFields []string `json:"-"` 3502 } 3503 3504 func (s *GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox) MarshalJSON() ([]byte, error) { 3505 type NoMethod GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox 3506 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3507 } 3508 3509 func (s *GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox) UnmarshalJSON(data []byte) error { 3510 type NoMethod GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox 3511 var s1 struct { 3512 Bottom gensupport.JSONFloat64 `json:"bottom"` 3513 Left gensupport.JSONFloat64 `json:"left"` 3514 Right gensupport.JSONFloat64 `json:"right"` 3515 Top gensupport.JSONFloat64 `json:"top"` 3516 *NoMethod 3517 } 3518 s1.NoMethod = (*NoMethod)(s) 3519 if err := json.Unmarshal(data, &s1); err != nil { 3520 return err 3521 } 3522 s.Bottom = float64(s1.Bottom) 3523 s.Left = float64(s1.Left) 3524 s.Right = float64(s1.Right) 3525 s.Top = float64(s1.Top) 3526 return nil 3527 } 3528 3529 // GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingPoly: Normalized 3530 // bounding polygon for text (that might not be aligned with axis). Contains 3531 // list of the corner points in clockwise order starting from top-left corner. 3532 // For example, for a rectangular bounding box: When the text is horizontal it 3533 // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees 3534 // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex 3535 // order will still be (0, 1, 2, 3). Note that values can be less than 0, or 3536 // greater than 1 due to trignometric calculations for location of the box. 3537 type GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingPoly struct { 3538 // Vertices: Normalized vertices of the bounding polygon. 3539 Vertices []*GoogleCloudVideointelligenceV1p1beta1NormalizedVertex `json:"vertices,omitempty"` 3540 // ForceSendFields is a list of field names (e.g. "Vertices") to 3541 // unconditionally include in API requests. By default, fields with empty or 3542 // default values are omitted from API requests. See 3543 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3544 // details. 3545 ForceSendFields []string `json:"-"` 3546 // NullFields is a list of field names (e.g. "Vertices") to include in API 3547 // requests with the JSON null value. By default, fields with empty values are 3548 // omitted from API requests. See 3549 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3550 NullFields []string `json:"-"` 3551 } 3552 3553 func (s *GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingPoly) MarshalJSON() ([]byte, error) { 3554 type NoMethod GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingPoly 3555 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3556 } 3557 3558 // GoogleCloudVideointelligenceV1p1beta1NormalizedVertex: A vertex represents a 3559 // 2D point in the image. NOTE: the normalized vertex coordinates are relative 3560 // to the original image and range from 0 to 1. 3561 type GoogleCloudVideointelligenceV1p1beta1NormalizedVertex struct { 3562 // X: X coordinate. 3563 X float64 `json:"x,omitempty"` 3564 // Y: Y coordinate. 3565 Y float64 `json:"y,omitempty"` 3566 // ForceSendFields is a list of field names (e.g. "X") to unconditionally 3567 // include in API requests. By default, fields with empty or default values are 3568 // omitted from API requests. See 3569 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3570 // details. 3571 ForceSendFields []string `json:"-"` 3572 // NullFields is a list of field names (e.g. "X") to include in API requests 3573 // with the JSON null value. By default, fields with empty values are omitted 3574 // from API requests. See 3575 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3576 NullFields []string `json:"-"` 3577 } 3578 3579 func (s *GoogleCloudVideointelligenceV1p1beta1NormalizedVertex) MarshalJSON() ([]byte, error) { 3580 type NoMethod GoogleCloudVideointelligenceV1p1beta1NormalizedVertex 3581 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3582 } 3583 3584 func (s *GoogleCloudVideointelligenceV1p1beta1NormalizedVertex) UnmarshalJSON(data []byte) error { 3585 type NoMethod GoogleCloudVideointelligenceV1p1beta1NormalizedVertex 3586 var s1 struct { 3587 X gensupport.JSONFloat64 `json:"x"` 3588 Y gensupport.JSONFloat64 `json:"y"` 3589 *NoMethod 3590 } 3591 s1.NoMethod = (*NoMethod)(s) 3592 if err := json.Unmarshal(data, &s1); err != nil { 3593 return err 3594 } 3595 s.X = float64(s1.X) 3596 s.Y = float64(s1.Y) 3597 return nil 3598 } 3599 3600 // GoogleCloudVideointelligenceV1p1beta1ObjectTrackingAnnotation: Annotations 3601 // corresponding to one tracked object. 3602 type GoogleCloudVideointelligenceV1p1beta1ObjectTrackingAnnotation struct { 3603 // Confidence: Object category's labeling confidence of this track. 3604 Confidence float64 `json:"confidence,omitempty"` 3605 // Entity: Entity to specify the object category that this track is labeled as. 3606 Entity *GoogleCloudVideointelligenceV1p1beta1Entity `json:"entity,omitempty"` 3607 // Frames: Information corresponding to all frames where this object track 3608 // appears. Non-streaming batch mode: it may be one or multiple 3609 // ObjectTrackingFrame messages in frames. Streaming mode: it can only be one 3610 // ObjectTrackingFrame message in frames. 3611 Frames []*GoogleCloudVideointelligenceV1p1beta1ObjectTrackingFrame `json:"frames,omitempty"` 3612 // Segment: Non-streaming batch mode ONLY. Each object track corresponds to one 3613 // video segment where it appears. 3614 Segment *GoogleCloudVideointelligenceV1p1beta1VideoSegment `json:"segment,omitempty"` 3615 // TrackId: Streaming mode ONLY. In streaming mode, we do not know the end time 3616 // of a tracked object before it is completed. Hence, there is no VideoSegment 3617 // info returned. Instead, we provide a unique identifiable integer track_id so 3618 // that the customers can correlate the results of the ongoing 3619 // ObjectTrackAnnotation of the same track_id over time. 3620 TrackId int64 `json:"trackId,omitempty,string"` 3621 // Version: Feature version. 3622 Version string `json:"version,omitempty"` 3623 // ForceSendFields is a list of field names (e.g. "Confidence") to 3624 // unconditionally include in API requests. By default, fields with empty or 3625 // default values are omitted from API requests. See 3626 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3627 // details. 3628 ForceSendFields []string `json:"-"` 3629 // NullFields is a list of field names (e.g. "Confidence") to include in API 3630 // requests with the JSON null value. By default, fields with empty values are 3631 // omitted from API requests. See 3632 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3633 NullFields []string `json:"-"` 3634 } 3635 3636 func (s *GoogleCloudVideointelligenceV1p1beta1ObjectTrackingAnnotation) MarshalJSON() ([]byte, error) { 3637 type NoMethod GoogleCloudVideointelligenceV1p1beta1ObjectTrackingAnnotation 3638 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3639 } 3640 3641 func (s *GoogleCloudVideointelligenceV1p1beta1ObjectTrackingAnnotation) UnmarshalJSON(data []byte) error { 3642 type NoMethod GoogleCloudVideointelligenceV1p1beta1ObjectTrackingAnnotation 3643 var s1 struct { 3644 Confidence gensupport.JSONFloat64 `json:"confidence"` 3645 *NoMethod 3646 } 3647 s1.NoMethod = (*NoMethod)(s) 3648 if err := json.Unmarshal(data, &s1); err != nil { 3649 return err 3650 } 3651 s.Confidence = float64(s1.Confidence) 3652 return nil 3653 } 3654 3655 // GoogleCloudVideointelligenceV1p1beta1ObjectTrackingFrame: Video frame level 3656 // annotations for object detection and tracking. This field stores per frame 3657 // location, time offset, and confidence. 3658 type GoogleCloudVideointelligenceV1p1beta1ObjectTrackingFrame struct { 3659 // NormalizedBoundingBox: The normalized bounding box location of this object 3660 // track for the frame. 3661 NormalizedBoundingBox *GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox `json:"normalizedBoundingBox,omitempty"` 3662 // TimeOffset: The timestamp of the frame in microseconds. 3663 TimeOffset string `json:"timeOffset,omitempty"` 3664 // ForceSendFields is a list of field names (e.g. "NormalizedBoundingBox") to 3665 // unconditionally include in API requests. By default, fields with empty or 3666 // default values are omitted from API requests. See 3667 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3668 // details. 3669 ForceSendFields []string `json:"-"` 3670 // NullFields is a list of field names (e.g. "NormalizedBoundingBox") to 3671 // include in API requests with the JSON null value. By default, fields with 3672 // empty values are omitted from API requests. See 3673 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3674 NullFields []string `json:"-"` 3675 } 3676 3677 func (s *GoogleCloudVideointelligenceV1p1beta1ObjectTrackingFrame) MarshalJSON() ([]byte, error) { 3678 type NoMethod GoogleCloudVideointelligenceV1p1beta1ObjectTrackingFrame 3679 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3680 } 3681 3682 // GoogleCloudVideointelligenceV1p1beta1PersonDetectionAnnotation: Person 3683 // detection annotation per video. 3684 type GoogleCloudVideointelligenceV1p1beta1PersonDetectionAnnotation struct { 3685 // Tracks: The detected tracks of a person. 3686 Tracks []*GoogleCloudVideointelligenceV1p1beta1Track `json:"tracks,omitempty"` 3687 // Version: Feature version. 3688 Version string `json:"version,omitempty"` 3689 // ForceSendFields is a list of field names (e.g. "Tracks") to unconditionally 3690 // include in API requests. By default, fields with empty or default values are 3691 // omitted from API requests. See 3692 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3693 // details. 3694 ForceSendFields []string `json:"-"` 3695 // NullFields is a list of field names (e.g. "Tracks") to include in API 3696 // requests with the JSON null value. By default, fields with empty values are 3697 // omitted from API requests. See 3698 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3699 NullFields []string `json:"-"` 3700 } 3701 3702 func (s *GoogleCloudVideointelligenceV1p1beta1PersonDetectionAnnotation) MarshalJSON() ([]byte, error) { 3703 type NoMethod GoogleCloudVideointelligenceV1p1beta1PersonDetectionAnnotation 3704 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3705 } 3706 3707 // GoogleCloudVideointelligenceV1p1beta1SpeechRecognitionAlternative: 3708 // Alternative hypotheses (a.k.a. n-best list). 3709 type GoogleCloudVideointelligenceV1p1beta1SpeechRecognitionAlternative struct { 3710 // Confidence: Output only. The confidence estimate between 0.0 and 1.0. A 3711 // higher number indicates an estimated greater likelihood that the recognized 3712 // words are correct. This field is set only for the top alternative. This 3713 // field is not guaranteed to be accurate and users should not rely on it to be 3714 // always provided. The default of 0.0 is a sentinel value indicating 3715 // `confidence` was not set. 3716 Confidence float64 `json:"confidence,omitempty"` 3717 // Transcript: Transcript text representing the words that the user spoke. 3718 Transcript string `json:"transcript,omitempty"` 3719 // Words: Output only. A list of word-specific information for each recognized 3720 // word. Note: When `enable_speaker_diarization` is set to true, you will see 3721 // all the words from the beginning of the audio. 3722 Words []*GoogleCloudVideointelligenceV1p1beta1WordInfo `json:"words,omitempty"` 3723 // ForceSendFields is a list of field names (e.g. "Confidence") to 3724 // unconditionally include in API requests. By default, fields with empty or 3725 // default values are omitted from API requests. See 3726 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3727 // details. 3728 ForceSendFields []string `json:"-"` 3729 // NullFields is a list of field names (e.g. "Confidence") to include in API 3730 // requests with the JSON null value. By default, fields with empty values are 3731 // omitted from API requests. See 3732 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3733 NullFields []string `json:"-"` 3734 } 3735 3736 func (s *GoogleCloudVideointelligenceV1p1beta1SpeechRecognitionAlternative) MarshalJSON() ([]byte, error) { 3737 type NoMethod GoogleCloudVideointelligenceV1p1beta1SpeechRecognitionAlternative 3738 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3739 } 3740 3741 func (s *GoogleCloudVideointelligenceV1p1beta1SpeechRecognitionAlternative) UnmarshalJSON(data []byte) error { 3742 type NoMethod GoogleCloudVideointelligenceV1p1beta1SpeechRecognitionAlternative 3743 var s1 struct { 3744 Confidence gensupport.JSONFloat64 `json:"confidence"` 3745 *NoMethod 3746 } 3747 s1.NoMethod = (*NoMethod)(s) 3748 if err := json.Unmarshal(data, &s1); err != nil { 3749 return err 3750 } 3751 s.Confidence = float64(s1.Confidence) 3752 return nil 3753 } 3754 3755 // GoogleCloudVideointelligenceV1p1beta1SpeechTranscription: A speech 3756 // recognition result corresponding to a portion of the audio. 3757 type GoogleCloudVideointelligenceV1p1beta1SpeechTranscription struct { 3758 // Alternatives: May contain one or more recognition hypotheses (up to the 3759 // maximum specified in `max_alternatives`). These alternatives are ordered in 3760 // terms of accuracy, with the top (first) alternative being the most probable, 3761 // as ranked by the recognizer. 3762 Alternatives []*GoogleCloudVideointelligenceV1p1beta1SpeechRecognitionAlternative `json:"alternatives,omitempty"` 3763 // LanguageCode: Output only. The BCP-47 3764 // (https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag of the language 3765 // in this result. This language code was detected to have the most likelihood 3766 // of being spoken in the audio. 3767 LanguageCode string `json:"languageCode,omitempty"` 3768 // ForceSendFields is a list of field names (e.g. "Alternatives") to 3769 // unconditionally include in API requests. By default, fields with empty or 3770 // default values are omitted from API requests. See 3771 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3772 // details. 3773 ForceSendFields []string `json:"-"` 3774 // NullFields is a list of field names (e.g. "Alternatives") to include in API 3775 // requests with the JSON null value. By default, fields with empty values are 3776 // omitted from API requests. See 3777 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3778 NullFields []string `json:"-"` 3779 } 3780 3781 func (s *GoogleCloudVideointelligenceV1p1beta1SpeechTranscription) MarshalJSON() ([]byte, error) { 3782 type NoMethod GoogleCloudVideointelligenceV1p1beta1SpeechTranscription 3783 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3784 } 3785 3786 // GoogleCloudVideointelligenceV1p1beta1TextAnnotation: Annotations related to 3787 // one detected OCR text snippet. This will contain the corresponding text, 3788 // confidence value, and frame level information for each detection. 3789 type GoogleCloudVideointelligenceV1p1beta1TextAnnotation struct { 3790 // Segments: All video segments where OCR detected text appears. 3791 Segments []*GoogleCloudVideointelligenceV1p1beta1TextSegment `json:"segments,omitempty"` 3792 // Text: The detected text. 3793 Text string `json:"text,omitempty"` 3794 // Version: Feature version. 3795 Version string `json:"version,omitempty"` 3796 // ForceSendFields is a list of field names (e.g. "Segments") to 3797 // unconditionally include in API requests. By default, fields with empty or 3798 // default values are omitted from API requests. See 3799 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3800 // details. 3801 ForceSendFields []string `json:"-"` 3802 // NullFields is a list of field names (e.g. "Segments") to include in API 3803 // requests with the JSON null value. By default, fields with empty values are 3804 // omitted from API requests. See 3805 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3806 NullFields []string `json:"-"` 3807 } 3808 3809 func (s *GoogleCloudVideointelligenceV1p1beta1TextAnnotation) MarshalJSON() ([]byte, error) { 3810 type NoMethod GoogleCloudVideointelligenceV1p1beta1TextAnnotation 3811 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3812 } 3813 3814 // GoogleCloudVideointelligenceV1p1beta1TextFrame: Video frame level annotation 3815 // results for text annotation (OCR). Contains information regarding timestamp 3816 // and bounding box locations for the frames containing detected OCR text 3817 // snippets. 3818 type GoogleCloudVideointelligenceV1p1beta1TextFrame struct { 3819 // RotatedBoundingBox: Bounding polygon of the detected text for this frame. 3820 RotatedBoundingBox *GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingPoly `json:"rotatedBoundingBox,omitempty"` 3821 // TimeOffset: Timestamp of this frame. 3822 TimeOffset string `json:"timeOffset,omitempty"` 3823 // ForceSendFields is a list of field names (e.g. "RotatedBoundingBox") to 3824 // unconditionally include in API requests. By default, fields with empty or 3825 // default values are omitted from API requests. See 3826 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3827 // details. 3828 ForceSendFields []string `json:"-"` 3829 // NullFields is a list of field names (e.g. "RotatedBoundingBox") to include 3830 // in API requests with the JSON null value. By default, fields with empty 3831 // values are omitted from API requests. See 3832 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3833 NullFields []string `json:"-"` 3834 } 3835 3836 func (s *GoogleCloudVideointelligenceV1p1beta1TextFrame) MarshalJSON() ([]byte, error) { 3837 type NoMethod GoogleCloudVideointelligenceV1p1beta1TextFrame 3838 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3839 } 3840 3841 // GoogleCloudVideointelligenceV1p1beta1TextSegment: Video segment level 3842 // annotation results for text detection. 3843 type GoogleCloudVideointelligenceV1p1beta1TextSegment struct { 3844 // Confidence: Confidence for the track of detected text. It is calculated as 3845 // the highest over all frames where OCR detected text appears. 3846 Confidence float64 `json:"confidence,omitempty"` 3847 // Frames: Information related to the frames where OCR detected text appears. 3848 Frames []*GoogleCloudVideointelligenceV1p1beta1TextFrame `json:"frames,omitempty"` 3849 // Segment: Video segment where a text snippet was detected. 3850 Segment *GoogleCloudVideointelligenceV1p1beta1VideoSegment `json:"segment,omitempty"` 3851 // ForceSendFields is a list of field names (e.g. "Confidence") to 3852 // unconditionally include in API requests. By default, fields with empty or 3853 // default values are omitted from API requests. See 3854 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3855 // details. 3856 ForceSendFields []string `json:"-"` 3857 // NullFields is a list of field names (e.g. "Confidence") to include in API 3858 // requests with the JSON null value. By default, fields with empty values are 3859 // omitted from API requests. See 3860 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3861 NullFields []string `json:"-"` 3862 } 3863 3864 func (s *GoogleCloudVideointelligenceV1p1beta1TextSegment) MarshalJSON() ([]byte, error) { 3865 type NoMethod GoogleCloudVideointelligenceV1p1beta1TextSegment 3866 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3867 } 3868 3869 func (s *GoogleCloudVideointelligenceV1p1beta1TextSegment) UnmarshalJSON(data []byte) error { 3870 type NoMethod GoogleCloudVideointelligenceV1p1beta1TextSegment 3871 var s1 struct { 3872 Confidence gensupport.JSONFloat64 `json:"confidence"` 3873 *NoMethod 3874 } 3875 s1.NoMethod = (*NoMethod)(s) 3876 if err := json.Unmarshal(data, &s1); err != nil { 3877 return err 3878 } 3879 s.Confidence = float64(s1.Confidence) 3880 return nil 3881 } 3882 3883 // GoogleCloudVideointelligenceV1p1beta1TimestampedObject: For tracking related 3884 // features. An object at time_offset with attributes, and located with 3885 // normalized_bounding_box. 3886 type GoogleCloudVideointelligenceV1p1beta1TimestampedObject struct { 3887 // Attributes: Optional. The attributes of the object in the bounding box. 3888 Attributes []*GoogleCloudVideointelligenceV1p1beta1DetectedAttribute `json:"attributes,omitempty"` 3889 // Landmarks: Optional. The detected landmarks. 3890 Landmarks []*GoogleCloudVideointelligenceV1p1beta1DetectedLandmark `json:"landmarks,omitempty"` 3891 // NormalizedBoundingBox: Normalized Bounding box in a frame, where the object 3892 // is located. 3893 NormalizedBoundingBox *GoogleCloudVideointelligenceV1p1beta1NormalizedBoundingBox `json:"normalizedBoundingBox,omitempty"` 3894 // TimeOffset: Time-offset, relative to the beginning of the video, 3895 // corresponding to the video frame for this object. 3896 TimeOffset string `json:"timeOffset,omitempty"` 3897 // ForceSendFields is a list of field names (e.g. "Attributes") to 3898 // unconditionally include in API requests. By default, fields with empty or 3899 // default values are omitted from API requests. See 3900 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3901 // details. 3902 ForceSendFields []string `json:"-"` 3903 // NullFields is a list of field names (e.g. "Attributes") to include in API 3904 // requests with the JSON null value. By default, fields with empty values are 3905 // omitted from API requests. See 3906 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3907 NullFields []string `json:"-"` 3908 } 3909 3910 func (s *GoogleCloudVideointelligenceV1p1beta1TimestampedObject) MarshalJSON() ([]byte, error) { 3911 type NoMethod GoogleCloudVideointelligenceV1p1beta1TimestampedObject 3912 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3913 } 3914 3915 // GoogleCloudVideointelligenceV1p1beta1Track: A track of an object instance. 3916 type GoogleCloudVideointelligenceV1p1beta1Track struct { 3917 // Attributes: Optional. Attributes in the track level. 3918 Attributes []*GoogleCloudVideointelligenceV1p1beta1DetectedAttribute `json:"attributes,omitempty"` 3919 // Confidence: Optional. The confidence score of the tracked object. 3920 Confidence float64 `json:"confidence,omitempty"` 3921 // Segment: Video segment of a track. 3922 Segment *GoogleCloudVideointelligenceV1p1beta1VideoSegment `json:"segment,omitempty"` 3923 // TimestampedObjects: The object with timestamp and attributes per frame in 3924 // the track. 3925 TimestampedObjects []*GoogleCloudVideointelligenceV1p1beta1TimestampedObject `json:"timestampedObjects,omitempty"` 3926 // ForceSendFields is a list of field names (e.g. "Attributes") to 3927 // unconditionally include in API requests. By default, fields with empty or 3928 // default values are omitted from API requests. See 3929 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3930 // details. 3931 ForceSendFields []string `json:"-"` 3932 // NullFields is a list of field names (e.g. "Attributes") to include in API 3933 // requests with the JSON null value. By default, fields with empty values are 3934 // omitted from API requests. See 3935 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 3936 NullFields []string `json:"-"` 3937 } 3938 3939 func (s *GoogleCloudVideointelligenceV1p1beta1Track) MarshalJSON() ([]byte, error) { 3940 type NoMethod GoogleCloudVideointelligenceV1p1beta1Track 3941 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 3942 } 3943 3944 func (s *GoogleCloudVideointelligenceV1p1beta1Track) UnmarshalJSON(data []byte) error { 3945 type NoMethod GoogleCloudVideointelligenceV1p1beta1Track 3946 var s1 struct { 3947 Confidence gensupport.JSONFloat64 `json:"confidence"` 3948 *NoMethod 3949 } 3950 s1.NoMethod = (*NoMethod)(s) 3951 if err := json.Unmarshal(data, &s1); err != nil { 3952 return err 3953 } 3954 s.Confidence = float64(s1.Confidence) 3955 return nil 3956 } 3957 3958 // GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress: Annotation 3959 // progress for a single video. 3960 type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress struct { 3961 // Feature: Specifies which feature is being tracked if the request contains 3962 // more than one feature. 3963 // 3964 // Possible values: 3965 // "FEATURE_UNSPECIFIED" - Unspecified. 3966 // "LABEL_DETECTION" - Label detection. Detect objects, such as dog or 3967 // flower. 3968 // "SHOT_CHANGE_DETECTION" - Shot change detection. 3969 // "EXPLICIT_CONTENT_DETECTION" - Explicit content detection. 3970 // "FACE_DETECTION" - Human face detection. 3971 // "SPEECH_TRANSCRIPTION" - Speech transcription. 3972 // "TEXT_DETECTION" - OCR text detection and tracking. 3973 // "OBJECT_TRACKING" - Object detection and tracking. 3974 // "LOGO_RECOGNITION" - Logo detection, tracking, and recognition. 3975 // "PERSON_DETECTION" - Person detection. 3976 Feature string `json:"feature,omitempty"` 3977 // InputUri: Video file location in Cloud Storage 3978 // (https://cloud.google.com/storage/). 3979 InputUri string `json:"inputUri,omitempty"` 3980 // ProgressPercent: Approximate percentage processed thus far. Guaranteed to be 3981 // 100 when fully processed. 3982 ProgressPercent int64 `json:"progressPercent,omitempty"` 3983 // Segment: Specifies which segment is being tracked if the request contains 3984 // more than one segment. 3985 Segment *GoogleCloudVideointelligenceV1p1beta1VideoSegment `json:"segment,omitempty"` 3986 // StartTime: Time when the request was received. 3987 StartTime string `json:"startTime,omitempty"` 3988 // UpdateTime: Time of the most recent update. 3989 UpdateTime string `json:"updateTime,omitempty"` 3990 // ForceSendFields is a list of field names (e.g. "Feature") to unconditionally 3991 // include in API requests. By default, fields with empty or default values are 3992 // omitted from API requests. See 3993 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 3994 // details. 3995 ForceSendFields []string `json:"-"` 3996 // NullFields is a list of field names (e.g. "Feature") to include in API 3997 // requests with the JSON null value. By default, fields with empty values are 3998 // omitted from API requests. See 3999 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4000 NullFields []string `json:"-"` 4001 } 4002 4003 func (s *GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress) MarshalJSON() ([]byte, error) { 4004 type NoMethod GoogleCloudVideointelligenceV1p1beta1VideoAnnotationProgress 4005 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4006 } 4007 4008 // GoogleCloudVideointelligenceV1p1beta1VideoAnnotationResults: Annotation 4009 // results for a single video. 4010 type GoogleCloudVideointelligenceV1p1beta1VideoAnnotationResults struct { 4011 // Error: If set, indicates an error. Note that for a single 4012 // `AnnotateVideoRequest` some videos may succeed and some may fail. 4013 Error *GoogleRpcStatus `json:"error,omitempty"` 4014 // ExplicitAnnotation: Explicit content annotation. 4015 ExplicitAnnotation *GoogleCloudVideointelligenceV1p1beta1ExplicitContentAnnotation `json:"explicitAnnotation,omitempty"` 4016 // FaceAnnotations: Deprecated. Please use `face_detection_annotations` 4017 // instead. 4018 FaceAnnotations []*GoogleCloudVideointelligenceV1p1beta1FaceAnnotation `json:"faceAnnotations,omitempty"` 4019 // FaceDetectionAnnotations: Face detection annotations. 4020 FaceDetectionAnnotations []*GoogleCloudVideointelligenceV1p1beta1FaceDetectionAnnotation `json:"faceDetectionAnnotations,omitempty"` 4021 // FrameLabelAnnotations: Label annotations on frame level. There is exactly 4022 // one element for each unique label. 4023 FrameLabelAnnotations []*GoogleCloudVideointelligenceV1p1beta1LabelAnnotation `json:"frameLabelAnnotations,omitempty"` 4024 // InputUri: Video file location in Cloud Storage 4025 // (https://cloud.google.com/storage/). 4026 InputUri string `json:"inputUri,omitempty"` 4027 // LogoRecognitionAnnotations: Annotations for list of logos detected, tracked 4028 // and recognized in video. 4029 LogoRecognitionAnnotations []*GoogleCloudVideointelligenceV1p1beta1LogoRecognitionAnnotation `json:"logoRecognitionAnnotations,omitempty"` 4030 // ObjectAnnotations: Annotations for list of objects detected and tracked in 4031 // video. 4032 ObjectAnnotations []*GoogleCloudVideointelligenceV1p1beta1ObjectTrackingAnnotation `json:"objectAnnotations,omitempty"` 4033 // PersonDetectionAnnotations: Person detection annotations. 4034 PersonDetectionAnnotations []*GoogleCloudVideointelligenceV1p1beta1PersonDetectionAnnotation `json:"personDetectionAnnotations,omitempty"` 4035 // Segment: Video segment on which the annotation is run. 4036 Segment *GoogleCloudVideointelligenceV1p1beta1VideoSegment `json:"segment,omitempty"` 4037 // SegmentLabelAnnotations: Topical label annotations on video level or 4038 // user-specified segment level. There is exactly one element for each unique 4039 // label. 4040 SegmentLabelAnnotations []*GoogleCloudVideointelligenceV1p1beta1LabelAnnotation `json:"segmentLabelAnnotations,omitempty"` 4041 // SegmentPresenceLabelAnnotations: Presence label annotations on video level 4042 // or user-specified segment level. There is exactly one element for each 4043 // unique label. Compared to the existing topical `segment_label_annotations`, 4044 // this field presents more fine-grained, segment-level labels detected in 4045 // video content and is made available only when the client sets 4046 // `LabelDetectionConfig.model` to "builtin/latest" in the request. 4047 SegmentPresenceLabelAnnotations []*GoogleCloudVideointelligenceV1p1beta1LabelAnnotation `json:"segmentPresenceLabelAnnotations,omitempty"` 4048 // ShotAnnotations: Shot annotations. Each shot is represented as a video 4049 // segment. 4050 ShotAnnotations []*GoogleCloudVideointelligenceV1p1beta1VideoSegment `json:"shotAnnotations,omitempty"` 4051 // ShotLabelAnnotations: Topical label annotations on shot level. There is 4052 // exactly one element for each unique label. 4053 ShotLabelAnnotations []*GoogleCloudVideointelligenceV1p1beta1LabelAnnotation `json:"shotLabelAnnotations,omitempty"` 4054 // ShotPresenceLabelAnnotations: Presence label annotations on shot level. 4055 // There is exactly one element for each unique label. Compared to the existing 4056 // topical `shot_label_annotations`, this field presents more fine-grained, 4057 // shot-level labels detected in video content and is made available only when 4058 // the client sets `LabelDetectionConfig.model` to "builtin/latest" in the 4059 // request. 4060 ShotPresenceLabelAnnotations []*GoogleCloudVideointelligenceV1p1beta1LabelAnnotation `json:"shotPresenceLabelAnnotations,omitempty"` 4061 // SpeechTranscriptions: Speech transcription. 4062 SpeechTranscriptions []*GoogleCloudVideointelligenceV1p1beta1SpeechTranscription `json:"speechTranscriptions,omitempty"` 4063 // TextAnnotations: OCR text detection and tracking. Annotations for list of 4064 // detected text snippets. Each will have list of frame information associated 4065 // with it. 4066 TextAnnotations []*GoogleCloudVideointelligenceV1p1beta1TextAnnotation `json:"textAnnotations,omitempty"` 4067 // ForceSendFields is a list of field names (e.g. "Error") to unconditionally 4068 // include in API requests. By default, fields with empty or default values are 4069 // omitted from API requests. See 4070 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4071 // details. 4072 ForceSendFields []string `json:"-"` 4073 // NullFields is a list of field names (e.g. "Error") to include in API 4074 // requests with the JSON null value. By default, fields with empty values are 4075 // omitted from API requests. See 4076 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4077 NullFields []string `json:"-"` 4078 } 4079 4080 func (s *GoogleCloudVideointelligenceV1p1beta1VideoAnnotationResults) MarshalJSON() ([]byte, error) { 4081 type NoMethod GoogleCloudVideointelligenceV1p1beta1VideoAnnotationResults 4082 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4083 } 4084 4085 // GoogleCloudVideointelligenceV1p1beta1VideoSegment: Video segment. 4086 type GoogleCloudVideointelligenceV1p1beta1VideoSegment struct { 4087 // EndTimeOffset: Time-offset, relative to the beginning of the video, 4088 // corresponding to the end of the segment (inclusive). 4089 EndTimeOffset string `json:"endTimeOffset,omitempty"` 4090 // StartTimeOffset: Time-offset, relative to the beginning of the video, 4091 // corresponding to the start of the segment (inclusive). 4092 StartTimeOffset string `json:"startTimeOffset,omitempty"` 4093 // ForceSendFields is a list of field names (e.g. "EndTimeOffset") to 4094 // unconditionally include in API requests. By default, fields with empty or 4095 // default values are omitted from API requests. See 4096 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4097 // details. 4098 ForceSendFields []string `json:"-"` 4099 // NullFields is a list of field names (e.g. "EndTimeOffset") to include in API 4100 // requests with the JSON null value. By default, fields with empty values are 4101 // omitted from API requests. See 4102 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4103 NullFields []string `json:"-"` 4104 } 4105 4106 func (s *GoogleCloudVideointelligenceV1p1beta1VideoSegment) MarshalJSON() ([]byte, error) { 4107 type NoMethod GoogleCloudVideointelligenceV1p1beta1VideoSegment 4108 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4109 } 4110 4111 // GoogleCloudVideointelligenceV1p1beta1WordInfo: Word-specific information for 4112 // recognized words. Word information is only included in the response when 4113 // certain request parameters are set, such as `enable_word_time_offsets`. 4114 type GoogleCloudVideointelligenceV1p1beta1WordInfo struct { 4115 // Confidence: Output only. The confidence estimate between 0.0 and 1.0. A 4116 // higher number indicates an estimated greater likelihood that the recognized 4117 // words are correct. This field is set only for the top alternative. This 4118 // field is not guaranteed to be accurate and users should not rely on it to be 4119 // always provided. The default of 0.0 is a sentinel value indicating 4120 // `confidence` was not set. 4121 Confidence float64 `json:"confidence,omitempty"` 4122 // EndTime: Time offset relative to the beginning of the audio, and 4123 // corresponding to the end of the spoken word. This field is only set if 4124 // `enable_word_time_offsets=true` and only in the top hypothesis. This is an 4125 // experimental feature and the accuracy of the time offset can vary. 4126 EndTime string `json:"endTime,omitempty"` 4127 // SpeakerTag: Output only. A distinct integer value is assigned for every 4128 // speaker within the audio. This field specifies which one of those speakers 4129 // was detected to have spoken this word. Value ranges from 1 up to 4130 // diarization_speaker_count, and is only set if speaker diarization is 4131 // enabled. 4132 SpeakerTag int64 `json:"speakerTag,omitempty"` 4133 // StartTime: Time offset relative to the beginning of the audio, and 4134 // corresponding to the start of the spoken word. This field is only set if 4135 // `enable_word_time_offsets=true` and only in the top hypothesis. This is an 4136 // experimental feature and the accuracy of the time offset can vary. 4137 StartTime string `json:"startTime,omitempty"` 4138 // Word: The word corresponding to this set of information. 4139 Word string `json:"word,omitempty"` 4140 // ForceSendFields is a list of field names (e.g. "Confidence") to 4141 // unconditionally include in API requests. By default, fields with empty or 4142 // default values are omitted from API requests. See 4143 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4144 // details. 4145 ForceSendFields []string `json:"-"` 4146 // NullFields is a list of field names (e.g. "Confidence") to include in API 4147 // requests with the JSON null value. By default, fields with empty values are 4148 // omitted from API requests. See 4149 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4150 NullFields []string `json:"-"` 4151 } 4152 4153 func (s *GoogleCloudVideointelligenceV1p1beta1WordInfo) MarshalJSON() ([]byte, error) { 4154 type NoMethod GoogleCloudVideointelligenceV1p1beta1WordInfo 4155 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4156 } 4157 4158 func (s *GoogleCloudVideointelligenceV1p1beta1WordInfo) UnmarshalJSON(data []byte) error { 4159 type NoMethod GoogleCloudVideointelligenceV1p1beta1WordInfo 4160 var s1 struct { 4161 Confidence gensupport.JSONFloat64 `json:"confidence"` 4162 *NoMethod 4163 } 4164 s1.NoMethod = (*NoMethod)(s) 4165 if err := json.Unmarshal(data, &s1); err != nil { 4166 return err 4167 } 4168 s.Confidence = float64(s1.Confidence) 4169 return nil 4170 } 4171 4172 // GoogleCloudVideointelligenceV1p2beta1AnnotateVideoProgress: Video annotation 4173 // progress. Included in the `metadata` field of the `Operation` returned by 4174 // the `GetOperation` call of the `google::longrunning::Operations` service. 4175 type GoogleCloudVideointelligenceV1p2beta1AnnotateVideoProgress struct { 4176 // AnnotationProgress: Progress metadata for all videos specified in 4177 // `AnnotateVideoRequest`. 4178 AnnotationProgress []*GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress `json:"annotationProgress,omitempty"` 4179 // ForceSendFields is a list of field names (e.g. "AnnotationProgress") to 4180 // unconditionally include in API requests. By default, fields with empty or 4181 // default values are omitted from API requests. See 4182 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4183 // details. 4184 ForceSendFields []string `json:"-"` 4185 // NullFields is a list of field names (e.g. "AnnotationProgress") to include 4186 // in API requests with the JSON null value. By default, fields with empty 4187 // values are omitted from API requests. See 4188 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4189 NullFields []string `json:"-"` 4190 } 4191 4192 func (s *GoogleCloudVideointelligenceV1p2beta1AnnotateVideoProgress) MarshalJSON() ([]byte, error) { 4193 type NoMethod GoogleCloudVideointelligenceV1p2beta1AnnotateVideoProgress 4194 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4195 } 4196 4197 // GoogleCloudVideointelligenceV1p2beta1AnnotateVideoResponse: Video annotation 4198 // response. Included in the `response` field of the `Operation` returned by 4199 // the `GetOperation` call of the `google::longrunning::Operations` service. 4200 type GoogleCloudVideointelligenceV1p2beta1AnnotateVideoResponse struct { 4201 // AnnotationResults: Annotation results for all videos specified in 4202 // `AnnotateVideoRequest`. 4203 AnnotationResults []*GoogleCloudVideointelligenceV1p2beta1VideoAnnotationResults `json:"annotationResults,omitempty"` 4204 // ForceSendFields is a list of field names (e.g. "AnnotationResults") to 4205 // unconditionally include in API requests. By default, fields with empty or 4206 // default values are omitted from API requests. See 4207 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4208 // details. 4209 ForceSendFields []string `json:"-"` 4210 // NullFields is a list of field names (e.g. "AnnotationResults") to include in 4211 // API requests with the JSON null value. By default, fields with empty values 4212 // are omitted from API requests. See 4213 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4214 NullFields []string `json:"-"` 4215 } 4216 4217 func (s *GoogleCloudVideointelligenceV1p2beta1AnnotateVideoResponse) MarshalJSON() ([]byte, error) { 4218 type NoMethod GoogleCloudVideointelligenceV1p2beta1AnnotateVideoResponse 4219 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4220 } 4221 4222 // GoogleCloudVideointelligenceV1p2beta1DetectedAttribute: A generic detected 4223 // attribute represented by name in string format. 4224 type GoogleCloudVideointelligenceV1p2beta1DetectedAttribute struct { 4225 // Confidence: Detected attribute confidence. Range [0, 1]. 4226 Confidence float64 `json:"confidence,omitempty"` 4227 // Name: The name of the attribute, for example, glasses, dark_glasses, 4228 // mouth_open. A full list of supported type names will be provided in the 4229 // document. 4230 Name string `json:"name,omitempty"` 4231 // Value: Text value of the detection result. For example, the value for 4232 // "HairColor" can be "black", "blonde", etc. 4233 Value string `json:"value,omitempty"` 4234 // ForceSendFields is a list of field names (e.g. "Confidence") to 4235 // unconditionally include in API requests. By default, fields with empty or 4236 // default values are omitted from API requests. See 4237 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4238 // details. 4239 ForceSendFields []string `json:"-"` 4240 // NullFields is a list of field names (e.g. "Confidence") to include in API 4241 // requests with the JSON null value. By default, fields with empty values are 4242 // omitted from API requests. See 4243 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4244 NullFields []string `json:"-"` 4245 } 4246 4247 func (s *GoogleCloudVideointelligenceV1p2beta1DetectedAttribute) MarshalJSON() ([]byte, error) { 4248 type NoMethod GoogleCloudVideointelligenceV1p2beta1DetectedAttribute 4249 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4250 } 4251 4252 func (s *GoogleCloudVideointelligenceV1p2beta1DetectedAttribute) UnmarshalJSON(data []byte) error { 4253 type NoMethod GoogleCloudVideointelligenceV1p2beta1DetectedAttribute 4254 var s1 struct { 4255 Confidence gensupport.JSONFloat64 `json:"confidence"` 4256 *NoMethod 4257 } 4258 s1.NoMethod = (*NoMethod)(s) 4259 if err := json.Unmarshal(data, &s1); err != nil { 4260 return err 4261 } 4262 s.Confidence = float64(s1.Confidence) 4263 return nil 4264 } 4265 4266 // GoogleCloudVideointelligenceV1p2beta1DetectedLandmark: A generic detected 4267 // landmark represented by name in string format and a 2D location. 4268 type GoogleCloudVideointelligenceV1p2beta1DetectedLandmark struct { 4269 // Confidence: The confidence score of the detected landmark. Range [0, 1]. 4270 Confidence float64 `json:"confidence,omitempty"` 4271 // Name: The name of this landmark, for example, left_hand, right_shoulder. 4272 Name string `json:"name,omitempty"` 4273 // Point: The 2D point of the detected landmark using the normalized image 4274 // coordindate system. The normalized coordinates have the range from 0 to 1. 4275 Point *GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"point,omitempty"` 4276 // ForceSendFields is a list of field names (e.g. "Confidence") to 4277 // unconditionally include in API requests. By default, fields with empty or 4278 // default values are omitted from API requests. See 4279 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4280 // details. 4281 ForceSendFields []string `json:"-"` 4282 // NullFields is a list of field names (e.g. "Confidence") to include in API 4283 // requests with the JSON null value. By default, fields with empty values are 4284 // omitted from API requests. See 4285 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4286 NullFields []string `json:"-"` 4287 } 4288 4289 func (s *GoogleCloudVideointelligenceV1p2beta1DetectedLandmark) MarshalJSON() ([]byte, error) { 4290 type NoMethod GoogleCloudVideointelligenceV1p2beta1DetectedLandmark 4291 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4292 } 4293 4294 func (s *GoogleCloudVideointelligenceV1p2beta1DetectedLandmark) UnmarshalJSON(data []byte) error { 4295 type NoMethod GoogleCloudVideointelligenceV1p2beta1DetectedLandmark 4296 var s1 struct { 4297 Confidence gensupport.JSONFloat64 `json:"confidence"` 4298 *NoMethod 4299 } 4300 s1.NoMethod = (*NoMethod)(s) 4301 if err := json.Unmarshal(data, &s1); err != nil { 4302 return err 4303 } 4304 s.Confidence = float64(s1.Confidence) 4305 return nil 4306 } 4307 4308 // GoogleCloudVideointelligenceV1p2beta1Entity: Detected entity from video 4309 // analysis. 4310 type GoogleCloudVideointelligenceV1p2beta1Entity struct { 4311 // Description: Textual description, e.g., `Fixed-gear bicycle`. 4312 Description string `json:"description,omitempty"` 4313 // EntityId: Opaque entity ID. Some IDs may be available in Google Knowledge 4314 // Graph Search API (https://developers.google.com/knowledge-graph/). 4315 EntityId string `json:"entityId,omitempty"` 4316 // LanguageCode: Language code for `description` in BCP-47 format. 4317 LanguageCode string `json:"languageCode,omitempty"` 4318 // ForceSendFields is a list of field names (e.g. "Description") to 4319 // unconditionally include in API requests. By default, fields with empty or 4320 // default values are omitted from API requests. See 4321 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4322 // details. 4323 ForceSendFields []string `json:"-"` 4324 // NullFields is a list of field names (e.g. "Description") to include in API 4325 // requests with the JSON null value. By default, fields with empty values are 4326 // omitted from API requests. See 4327 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4328 NullFields []string `json:"-"` 4329 } 4330 4331 func (s *GoogleCloudVideointelligenceV1p2beta1Entity) MarshalJSON() ([]byte, error) { 4332 type NoMethod GoogleCloudVideointelligenceV1p2beta1Entity 4333 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4334 } 4335 4336 // GoogleCloudVideointelligenceV1p2beta1ExplicitContentAnnotation: Explicit 4337 // content annotation (based on per-frame visual signals only). If no explicit 4338 // content has been detected in a frame, no annotations are present for that 4339 // frame. 4340 type GoogleCloudVideointelligenceV1p2beta1ExplicitContentAnnotation struct { 4341 // Frames: All video frames where explicit content was detected. 4342 Frames []*GoogleCloudVideointelligenceV1p2beta1ExplicitContentFrame `json:"frames,omitempty"` 4343 // Version: Feature version. 4344 Version string `json:"version,omitempty"` 4345 // ForceSendFields is a list of field names (e.g. "Frames") to unconditionally 4346 // include in API requests. By default, fields with empty or default values are 4347 // omitted from API requests. See 4348 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4349 // details. 4350 ForceSendFields []string `json:"-"` 4351 // NullFields is a list of field names (e.g. "Frames") to include in API 4352 // requests with the JSON null value. By default, fields with empty values are 4353 // omitted from API requests. See 4354 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4355 NullFields []string `json:"-"` 4356 } 4357 4358 func (s *GoogleCloudVideointelligenceV1p2beta1ExplicitContentAnnotation) MarshalJSON() ([]byte, error) { 4359 type NoMethod GoogleCloudVideointelligenceV1p2beta1ExplicitContentAnnotation 4360 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4361 } 4362 4363 // GoogleCloudVideointelligenceV1p2beta1ExplicitContentFrame: Video frame level 4364 // annotation results for explicit content. 4365 type GoogleCloudVideointelligenceV1p2beta1ExplicitContentFrame struct { 4366 // PornographyLikelihood: Likelihood of the pornography content.. 4367 // 4368 // Possible values: 4369 // "LIKELIHOOD_UNSPECIFIED" - Unspecified likelihood. 4370 // "VERY_UNLIKELY" - Very unlikely. 4371 // "UNLIKELY" - Unlikely. 4372 // "POSSIBLE" - Possible. 4373 // "LIKELY" - Likely. 4374 // "VERY_LIKELY" - Very likely. 4375 PornographyLikelihood string `json:"pornographyLikelihood,omitempty"` 4376 // TimeOffset: Time-offset, relative to the beginning of the video, 4377 // corresponding to the video frame for this location. 4378 TimeOffset string `json:"timeOffset,omitempty"` 4379 // ForceSendFields is a list of field names (e.g. "PornographyLikelihood") to 4380 // unconditionally include in API requests. By default, fields with empty or 4381 // default values are omitted from API requests. See 4382 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4383 // details. 4384 ForceSendFields []string `json:"-"` 4385 // NullFields is a list of field names (e.g. "PornographyLikelihood") to 4386 // include in API requests with the JSON null value. By default, fields with 4387 // empty values are omitted from API requests. See 4388 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4389 NullFields []string `json:"-"` 4390 } 4391 4392 func (s *GoogleCloudVideointelligenceV1p2beta1ExplicitContentFrame) MarshalJSON() ([]byte, error) { 4393 type NoMethod GoogleCloudVideointelligenceV1p2beta1ExplicitContentFrame 4394 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4395 } 4396 4397 // GoogleCloudVideointelligenceV1p2beta1FaceAnnotation: Deprecated. No effect. 4398 type GoogleCloudVideointelligenceV1p2beta1FaceAnnotation struct { 4399 // Frames: All video frames where a face was detected. 4400 Frames []*GoogleCloudVideointelligenceV1p2beta1FaceFrame `json:"frames,omitempty"` 4401 // Segments: All video segments where a face was detected. 4402 Segments []*GoogleCloudVideointelligenceV1p2beta1FaceSegment `json:"segments,omitempty"` 4403 // Thumbnail: Thumbnail of a representative face view (in JPEG format). 4404 Thumbnail string `json:"thumbnail,omitempty"` 4405 // ForceSendFields is a list of field names (e.g. "Frames") to unconditionally 4406 // include in API requests. By default, fields with empty or default values are 4407 // omitted from API requests. See 4408 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4409 // details. 4410 ForceSendFields []string `json:"-"` 4411 // NullFields is a list of field names (e.g. "Frames") to include in API 4412 // requests with the JSON null value. By default, fields with empty values are 4413 // omitted from API requests. See 4414 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4415 NullFields []string `json:"-"` 4416 } 4417 4418 func (s *GoogleCloudVideointelligenceV1p2beta1FaceAnnotation) MarshalJSON() ([]byte, error) { 4419 type NoMethod GoogleCloudVideointelligenceV1p2beta1FaceAnnotation 4420 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4421 } 4422 4423 // GoogleCloudVideointelligenceV1p2beta1FaceDetectionAnnotation: Face detection 4424 // annotation. 4425 type GoogleCloudVideointelligenceV1p2beta1FaceDetectionAnnotation struct { 4426 // Thumbnail: The thumbnail of a person's face. 4427 Thumbnail string `json:"thumbnail,omitempty"` 4428 // Tracks: The face tracks with attributes. 4429 Tracks []*GoogleCloudVideointelligenceV1p2beta1Track `json:"tracks,omitempty"` 4430 // Version: Feature version. 4431 Version string `json:"version,omitempty"` 4432 // ForceSendFields is a list of field names (e.g. "Thumbnail") to 4433 // unconditionally include in API requests. By default, fields with empty or 4434 // default values are omitted from API requests. See 4435 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4436 // details. 4437 ForceSendFields []string `json:"-"` 4438 // NullFields is a list of field names (e.g. "Thumbnail") to include in API 4439 // requests with the JSON null value. By default, fields with empty values are 4440 // omitted from API requests. See 4441 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4442 NullFields []string `json:"-"` 4443 } 4444 4445 func (s *GoogleCloudVideointelligenceV1p2beta1FaceDetectionAnnotation) MarshalJSON() ([]byte, error) { 4446 type NoMethod GoogleCloudVideointelligenceV1p2beta1FaceDetectionAnnotation 4447 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4448 } 4449 4450 // GoogleCloudVideointelligenceV1p2beta1FaceFrame: Deprecated. No effect. 4451 type GoogleCloudVideointelligenceV1p2beta1FaceFrame struct { 4452 // NormalizedBoundingBoxes: Normalized Bounding boxes in a frame. There can be 4453 // more than one boxes if the same face is detected in multiple locations 4454 // within the current frame. 4455 NormalizedBoundingBoxes []*GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox `json:"normalizedBoundingBoxes,omitempty"` 4456 // TimeOffset: Time-offset, relative to the beginning of the video, 4457 // corresponding to the video frame for this location. 4458 TimeOffset string `json:"timeOffset,omitempty"` 4459 // ForceSendFields is a list of field names (e.g. "NormalizedBoundingBoxes") to 4460 // unconditionally include in API requests. By default, fields with empty or 4461 // default values are omitted from API requests. See 4462 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4463 // details. 4464 ForceSendFields []string `json:"-"` 4465 // NullFields is a list of field names (e.g. "NormalizedBoundingBoxes") to 4466 // include in API requests with the JSON null value. By default, fields with 4467 // empty values are omitted from API requests. See 4468 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4469 NullFields []string `json:"-"` 4470 } 4471 4472 func (s *GoogleCloudVideointelligenceV1p2beta1FaceFrame) MarshalJSON() ([]byte, error) { 4473 type NoMethod GoogleCloudVideointelligenceV1p2beta1FaceFrame 4474 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4475 } 4476 4477 // GoogleCloudVideointelligenceV1p2beta1FaceSegment: Video segment level 4478 // annotation results for face detection. 4479 type GoogleCloudVideointelligenceV1p2beta1FaceSegment struct { 4480 // Segment: Video segment where a face was detected. 4481 Segment *GoogleCloudVideointelligenceV1p2beta1VideoSegment `json:"segment,omitempty"` 4482 // ForceSendFields is a list of field names (e.g. "Segment") to unconditionally 4483 // include in API requests. By default, fields with empty or default values are 4484 // omitted from API requests. See 4485 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4486 // details. 4487 ForceSendFields []string `json:"-"` 4488 // NullFields is a list of field names (e.g. "Segment") to include in API 4489 // requests with the JSON null value. By default, fields with empty values are 4490 // omitted from API requests. See 4491 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4492 NullFields []string `json:"-"` 4493 } 4494 4495 func (s *GoogleCloudVideointelligenceV1p2beta1FaceSegment) MarshalJSON() ([]byte, error) { 4496 type NoMethod GoogleCloudVideointelligenceV1p2beta1FaceSegment 4497 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4498 } 4499 4500 // GoogleCloudVideointelligenceV1p2beta1LabelAnnotation: Label annotation. 4501 type GoogleCloudVideointelligenceV1p2beta1LabelAnnotation struct { 4502 // CategoryEntities: Common categories for the detected entity. For example, 4503 // when the label is `Terrier`, the category is likely `dog`. And in some cases 4504 // there might be more than one categories e.g., `Terrier` could also be a 4505 // `pet`. 4506 CategoryEntities []*GoogleCloudVideointelligenceV1p2beta1Entity `json:"categoryEntities,omitempty"` 4507 // Entity: Detected entity. 4508 Entity *GoogleCloudVideointelligenceV1p2beta1Entity `json:"entity,omitempty"` 4509 // Frames: All video frames where a label was detected. 4510 Frames []*GoogleCloudVideointelligenceV1p2beta1LabelFrame `json:"frames,omitempty"` 4511 // Segments: All video segments where a label was detected. 4512 Segments []*GoogleCloudVideointelligenceV1p2beta1LabelSegment `json:"segments,omitempty"` 4513 // Version: Feature version. 4514 Version string `json:"version,omitempty"` 4515 // ForceSendFields is a list of field names (e.g. "CategoryEntities") to 4516 // unconditionally include in API requests. By default, fields with empty or 4517 // default values are omitted from API requests. See 4518 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4519 // details. 4520 ForceSendFields []string `json:"-"` 4521 // NullFields is a list of field names (e.g. "CategoryEntities") to include in 4522 // API requests with the JSON null value. By default, fields with empty values 4523 // are omitted from API requests. See 4524 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4525 NullFields []string `json:"-"` 4526 } 4527 4528 func (s *GoogleCloudVideointelligenceV1p2beta1LabelAnnotation) MarshalJSON() ([]byte, error) { 4529 type NoMethod GoogleCloudVideointelligenceV1p2beta1LabelAnnotation 4530 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4531 } 4532 4533 // GoogleCloudVideointelligenceV1p2beta1LabelFrame: Video frame level 4534 // annotation results for label detection. 4535 type GoogleCloudVideointelligenceV1p2beta1LabelFrame struct { 4536 // Confidence: Confidence that the label is accurate. Range: [0, 1]. 4537 Confidence float64 `json:"confidence,omitempty"` 4538 // TimeOffset: Time-offset, relative to the beginning of the video, 4539 // corresponding to the video frame for this location. 4540 TimeOffset string `json:"timeOffset,omitempty"` 4541 // ForceSendFields is a list of field names (e.g. "Confidence") to 4542 // unconditionally include in API requests. By default, fields with empty or 4543 // default values are omitted from API requests. See 4544 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4545 // details. 4546 ForceSendFields []string `json:"-"` 4547 // NullFields is a list of field names (e.g. "Confidence") to include in API 4548 // requests with the JSON null value. By default, fields with empty values are 4549 // omitted from API requests. See 4550 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4551 NullFields []string `json:"-"` 4552 } 4553 4554 func (s *GoogleCloudVideointelligenceV1p2beta1LabelFrame) MarshalJSON() ([]byte, error) { 4555 type NoMethod GoogleCloudVideointelligenceV1p2beta1LabelFrame 4556 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4557 } 4558 4559 func (s *GoogleCloudVideointelligenceV1p2beta1LabelFrame) UnmarshalJSON(data []byte) error { 4560 type NoMethod GoogleCloudVideointelligenceV1p2beta1LabelFrame 4561 var s1 struct { 4562 Confidence gensupport.JSONFloat64 `json:"confidence"` 4563 *NoMethod 4564 } 4565 s1.NoMethod = (*NoMethod)(s) 4566 if err := json.Unmarshal(data, &s1); err != nil { 4567 return err 4568 } 4569 s.Confidence = float64(s1.Confidence) 4570 return nil 4571 } 4572 4573 // GoogleCloudVideointelligenceV1p2beta1LabelSegment: Video segment level 4574 // annotation results for label detection. 4575 type GoogleCloudVideointelligenceV1p2beta1LabelSegment struct { 4576 // Confidence: Confidence that the label is accurate. Range: [0, 1]. 4577 Confidence float64 `json:"confidence,omitempty"` 4578 // Segment: Video segment where a label was detected. 4579 Segment *GoogleCloudVideointelligenceV1p2beta1VideoSegment `json:"segment,omitempty"` 4580 // ForceSendFields is a list of field names (e.g. "Confidence") to 4581 // unconditionally include in API requests. By default, fields with empty or 4582 // default values are omitted from API requests. See 4583 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4584 // details. 4585 ForceSendFields []string `json:"-"` 4586 // NullFields is a list of field names (e.g. "Confidence") to include in API 4587 // requests with the JSON null value. By default, fields with empty values are 4588 // omitted from API requests. See 4589 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4590 NullFields []string `json:"-"` 4591 } 4592 4593 func (s *GoogleCloudVideointelligenceV1p2beta1LabelSegment) MarshalJSON() ([]byte, error) { 4594 type NoMethod GoogleCloudVideointelligenceV1p2beta1LabelSegment 4595 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4596 } 4597 4598 func (s *GoogleCloudVideointelligenceV1p2beta1LabelSegment) UnmarshalJSON(data []byte) error { 4599 type NoMethod GoogleCloudVideointelligenceV1p2beta1LabelSegment 4600 var s1 struct { 4601 Confidence gensupport.JSONFloat64 `json:"confidence"` 4602 *NoMethod 4603 } 4604 s1.NoMethod = (*NoMethod)(s) 4605 if err := json.Unmarshal(data, &s1); err != nil { 4606 return err 4607 } 4608 s.Confidence = float64(s1.Confidence) 4609 return nil 4610 } 4611 4612 // GoogleCloudVideointelligenceV1p2beta1LogoRecognitionAnnotation: Annotation 4613 // corresponding to one detected, tracked and recognized logo class. 4614 type GoogleCloudVideointelligenceV1p2beta1LogoRecognitionAnnotation struct { 4615 // Entity: Entity category information to specify the logo class that all the 4616 // logo tracks within this LogoRecognitionAnnotation are recognized as. 4617 Entity *GoogleCloudVideointelligenceV1p2beta1Entity `json:"entity,omitempty"` 4618 // Segments: All video segments where the recognized logo appears. There might 4619 // be multiple instances of the same logo class appearing in one VideoSegment. 4620 Segments []*GoogleCloudVideointelligenceV1p2beta1VideoSegment `json:"segments,omitempty"` 4621 // Tracks: All logo tracks where the recognized logo appears. Each track 4622 // corresponds to one logo instance appearing in consecutive frames. 4623 Tracks []*GoogleCloudVideointelligenceV1p2beta1Track `json:"tracks,omitempty"` 4624 // ForceSendFields is a list of field names (e.g. "Entity") to unconditionally 4625 // include in API requests. By default, fields with empty or default values are 4626 // omitted from API requests. See 4627 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4628 // details. 4629 ForceSendFields []string `json:"-"` 4630 // NullFields is a list of field names (e.g. "Entity") to include in API 4631 // requests with the JSON null value. By default, fields with empty values are 4632 // omitted from API requests. See 4633 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4634 NullFields []string `json:"-"` 4635 } 4636 4637 func (s *GoogleCloudVideointelligenceV1p2beta1LogoRecognitionAnnotation) MarshalJSON() ([]byte, error) { 4638 type NoMethod GoogleCloudVideointelligenceV1p2beta1LogoRecognitionAnnotation 4639 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4640 } 4641 4642 // GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox: Normalized 4643 // bounding box. The normalized vertex coordinates are relative to the original 4644 // image. Range: [0, 1]. 4645 type GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox struct { 4646 // Bottom: Bottom Y coordinate. 4647 Bottom float64 `json:"bottom,omitempty"` 4648 // Left: Left X coordinate. 4649 Left float64 `json:"left,omitempty"` 4650 // Right: Right X coordinate. 4651 Right float64 `json:"right,omitempty"` 4652 // Top: Top Y coordinate. 4653 Top float64 `json:"top,omitempty"` 4654 // ForceSendFields is a list of field names (e.g. "Bottom") to unconditionally 4655 // include in API requests. By default, fields with empty or default values are 4656 // omitted from API requests. See 4657 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4658 // details. 4659 ForceSendFields []string `json:"-"` 4660 // NullFields is a list of field names (e.g. "Bottom") to include in API 4661 // requests with the JSON null value. By default, fields with empty values are 4662 // omitted from API requests. See 4663 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4664 NullFields []string `json:"-"` 4665 } 4666 4667 func (s *GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox) MarshalJSON() ([]byte, error) { 4668 type NoMethod GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox 4669 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4670 } 4671 4672 func (s *GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox) UnmarshalJSON(data []byte) error { 4673 type NoMethod GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox 4674 var s1 struct { 4675 Bottom gensupport.JSONFloat64 `json:"bottom"` 4676 Left gensupport.JSONFloat64 `json:"left"` 4677 Right gensupport.JSONFloat64 `json:"right"` 4678 Top gensupport.JSONFloat64 `json:"top"` 4679 *NoMethod 4680 } 4681 s1.NoMethod = (*NoMethod)(s) 4682 if err := json.Unmarshal(data, &s1); err != nil { 4683 return err 4684 } 4685 s.Bottom = float64(s1.Bottom) 4686 s.Left = float64(s1.Left) 4687 s.Right = float64(s1.Right) 4688 s.Top = float64(s1.Top) 4689 return nil 4690 } 4691 4692 // GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingPoly: Normalized 4693 // bounding polygon for text (that might not be aligned with axis). Contains 4694 // list of the corner points in clockwise order starting from top-left corner. 4695 // For example, for a rectangular bounding box: When the text is horizontal it 4696 // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees 4697 // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex 4698 // order will still be (0, 1, 2, 3). Note that values can be less than 0, or 4699 // greater than 1 due to trignometric calculations for location of the box. 4700 type GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingPoly struct { 4701 // Vertices: Normalized vertices of the bounding polygon. 4702 Vertices []*GoogleCloudVideointelligenceV1p2beta1NormalizedVertex `json:"vertices,omitempty"` 4703 // ForceSendFields is a list of field names (e.g. "Vertices") to 4704 // unconditionally include in API requests. By default, fields with empty or 4705 // default values are omitted from API requests. See 4706 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4707 // details. 4708 ForceSendFields []string `json:"-"` 4709 // NullFields is a list of field names (e.g. "Vertices") to include in API 4710 // requests with the JSON null value. By default, fields with empty values are 4711 // omitted from API requests. See 4712 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4713 NullFields []string `json:"-"` 4714 } 4715 4716 func (s *GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingPoly) MarshalJSON() ([]byte, error) { 4717 type NoMethod GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingPoly 4718 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4719 } 4720 4721 // GoogleCloudVideointelligenceV1p2beta1NormalizedVertex: A vertex represents a 4722 // 2D point in the image. NOTE: the normalized vertex coordinates are relative 4723 // to the original image and range from 0 to 1. 4724 type GoogleCloudVideointelligenceV1p2beta1NormalizedVertex struct { 4725 // X: X coordinate. 4726 X float64 `json:"x,omitempty"` 4727 // Y: Y coordinate. 4728 Y float64 `json:"y,omitempty"` 4729 // ForceSendFields is a list of field names (e.g. "X") to unconditionally 4730 // include in API requests. By default, fields with empty or default values are 4731 // omitted from API requests. See 4732 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4733 // details. 4734 ForceSendFields []string `json:"-"` 4735 // NullFields is a list of field names (e.g. "X") to include in API requests 4736 // with the JSON null value. By default, fields with empty values are omitted 4737 // from API requests. See 4738 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4739 NullFields []string `json:"-"` 4740 } 4741 4742 func (s *GoogleCloudVideointelligenceV1p2beta1NormalizedVertex) MarshalJSON() ([]byte, error) { 4743 type NoMethod GoogleCloudVideointelligenceV1p2beta1NormalizedVertex 4744 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4745 } 4746 4747 func (s *GoogleCloudVideointelligenceV1p2beta1NormalizedVertex) UnmarshalJSON(data []byte) error { 4748 type NoMethod GoogleCloudVideointelligenceV1p2beta1NormalizedVertex 4749 var s1 struct { 4750 X gensupport.JSONFloat64 `json:"x"` 4751 Y gensupport.JSONFloat64 `json:"y"` 4752 *NoMethod 4753 } 4754 s1.NoMethod = (*NoMethod)(s) 4755 if err := json.Unmarshal(data, &s1); err != nil { 4756 return err 4757 } 4758 s.X = float64(s1.X) 4759 s.Y = float64(s1.Y) 4760 return nil 4761 } 4762 4763 // GoogleCloudVideointelligenceV1p2beta1ObjectTrackingAnnotation: Annotations 4764 // corresponding to one tracked object. 4765 type GoogleCloudVideointelligenceV1p2beta1ObjectTrackingAnnotation struct { 4766 // Confidence: Object category's labeling confidence of this track. 4767 Confidence float64 `json:"confidence,omitempty"` 4768 // Entity: Entity to specify the object category that this track is labeled as. 4769 Entity *GoogleCloudVideointelligenceV1p2beta1Entity `json:"entity,omitempty"` 4770 // Frames: Information corresponding to all frames where this object track 4771 // appears. Non-streaming batch mode: it may be one or multiple 4772 // ObjectTrackingFrame messages in frames. Streaming mode: it can only be one 4773 // ObjectTrackingFrame message in frames. 4774 Frames []*GoogleCloudVideointelligenceV1p2beta1ObjectTrackingFrame `json:"frames,omitempty"` 4775 // Segment: Non-streaming batch mode ONLY. Each object track corresponds to one 4776 // video segment where it appears. 4777 Segment *GoogleCloudVideointelligenceV1p2beta1VideoSegment `json:"segment,omitempty"` 4778 // TrackId: Streaming mode ONLY. In streaming mode, we do not know the end time 4779 // of a tracked object before it is completed. Hence, there is no VideoSegment 4780 // info returned. Instead, we provide a unique identifiable integer track_id so 4781 // that the customers can correlate the results of the ongoing 4782 // ObjectTrackAnnotation of the same track_id over time. 4783 TrackId int64 `json:"trackId,omitempty,string"` 4784 // Version: Feature version. 4785 Version string `json:"version,omitempty"` 4786 // ForceSendFields is a list of field names (e.g. "Confidence") to 4787 // unconditionally include in API requests. By default, fields with empty or 4788 // default values are omitted from API requests. See 4789 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4790 // details. 4791 ForceSendFields []string `json:"-"` 4792 // NullFields is a list of field names (e.g. "Confidence") to include in API 4793 // requests with the JSON null value. By default, fields with empty values are 4794 // omitted from API requests. See 4795 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4796 NullFields []string `json:"-"` 4797 } 4798 4799 func (s *GoogleCloudVideointelligenceV1p2beta1ObjectTrackingAnnotation) MarshalJSON() ([]byte, error) { 4800 type NoMethod GoogleCloudVideointelligenceV1p2beta1ObjectTrackingAnnotation 4801 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4802 } 4803 4804 func (s *GoogleCloudVideointelligenceV1p2beta1ObjectTrackingAnnotation) UnmarshalJSON(data []byte) error { 4805 type NoMethod GoogleCloudVideointelligenceV1p2beta1ObjectTrackingAnnotation 4806 var s1 struct { 4807 Confidence gensupport.JSONFloat64 `json:"confidence"` 4808 *NoMethod 4809 } 4810 s1.NoMethod = (*NoMethod)(s) 4811 if err := json.Unmarshal(data, &s1); err != nil { 4812 return err 4813 } 4814 s.Confidence = float64(s1.Confidence) 4815 return nil 4816 } 4817 4818 // GoogleCloudVideointelligenceV1p2beta1ObjectTrackingFrame: Video frame level 4819 // annotations for object detection and tracking. This field stores per frame 4820 // location, time offset, and confidence. 4821 type GoogleCloudVideointelligenceV1p2beta1ObjectTrackingFrame struct { 4822 // NormalizedBoundingBox: The normalized bounding box location of this object 4823 // track for the frame. 4824 NormalizedBoundingBox *GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox `json:"normalizedBoundingBox,omitempty"` 4825 // TimeOffset: The timestamp of the frame in microseconds. 4826 TimeOffset string `json:"timeOffset,omitempty"` 4827 // ForceSendFields is a list of field names (e.g. "NormalizedBoundingBox") to 4828 // unconditionally include in API requests. By default, fields with empty or 4829 // default values are omitted from API requests. See 4830 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4831 // details. 4832 ForceSendFields []string `json:"-"` 4833 // NullFields is a list of field names (e.g. "NormalizedBoundingBox") to 4834 // include in API requests with the JSON null value. By default, fields with 4835 // empty values are omitted from API requests. See 4836 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4837 NullFields []string `json:"-"` 4838 } 4839 4840 func (s *GoogleCloudVideointelligenceV1p2beta1ObjectTrackingFrame) MarshalJSON() ([]byte, error) { 4841 type NoMethod GoogleCloudVideointelligenceV1p2beta1ObjectTrackingFrame 4842 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4843 } 4844 4845 // GoogleCloudVideointelligenceV1p2beta1PersonDetectionAnnotation: Person 4846 // detection annotation per video. 4847 type GoogleCloudVideointelligenceV1p2beta1PersonDetectionAnnotation struct { 4848 // Tracks: The detected tracks of a person. 4849 Tracks []*GoogleCloudVideointelligenceV1p2beta1Track `json:"tracks,omitempty"` 4850 // Version: Feature version. 4851 Version string `json:"version,omitempty"` 4852 // ForceSendFields is a list of field names (e.g. "Tracks") to unconditionally 4853 // include in API requests. By default, fields with empty or default values are 4854 // omitted from API requests. See 4855 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4856 // details. 4857 ForceSendFields []string `json:"-"` 4858 // NullFields is a list of field names (e.g. "Tracks") to include in API 4859 // requests with the JSON null value. By default, fields with empty values are 4860 // omitted from API requests. See 4861 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4862 NullFields []string `json:"-"` 4863 } 4864 4865 func (s *GoogleCloudVideointelligenceV1p2beta1PersonDetectionAnnotation) MarshalJSON() ([]byte, error) { 4866 type NoMethod GoogleCloudVideointelligenceV1p2beta1PersonDetectionAnnotation 4867 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4868 } 4869 4870 // GoogleCloudVideointelligenceV1p2beta1SpeechRecognitionAlternative: 4871 // Alternative hypotheses (a.k.a. n-best list). 4872 type GoogleCloudVideointelligenceV1p2beta1SpeechRecognitionAlternative struct { 4873 // Confidence: Output only. The confidence estimate between 0.0 and 1.0. A 4874 // higher number indicates an estimated greater likelihood that the recognized 4875 // words are correct. This field is set only for the top alternative. This 4876 // field is not guaranteed to be accurate and users should not rely on it to be 4877 // always provided. The default of 0.0 is a sentinel value indicating 4878 // `confidence` was not set. 4879 Confidence float64 `json:"confidence,omitempty"` 4880 // Transcript: Transcript text representing the words that the user spoke. 4881 Transcript string `json:"transcript,omitempty"` 4882 // Words: Output only. A list of word-specific information for each recognized 4883 // word. Note: When `enable_speaker_diarization` is set to true, you will see 4884 // all the words from the beginning of the audio. 4885 Words []*GoogleCloudVideointelligenceV1p2beta1WordInfo `json:"words,omitempty"` 4886 // ForceSendFields is a list of field names (e.g. "Confidence") to 4887 // unconditionally include in API requests. By default, fields with empty or 4888 // default values are omitted from API requests. See 4889 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4890 // details. 4891 ForceSendFields []string `json:"-"` 4892 // NullFields is a list of field names (e.g. "Confidence") to include in API 4893 // requests with the JSON null value. By default, fields with empty values are 4894 // omitted from API requests. See 4895 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4896 NullFields []string `json:"-"` 4897 } 4898 4899 func (s *GoogleCloudVideointelligenceV1p2beta1SpeechRecognitionAlternative) MarshalJSON() ([]byte, error) { 4900 type NoMethod GoogleCloudVideointelligenceV1p2beta1SpeechRecognitionAlternative 4901 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4902 } 4903 4904 func (s *GoogleCloudVideointelligenceV1p2beta1SpeechRecognitionAlternative) UnmarshalJSON(data []byte) error { 4905 type NoMethod GoogleCloudVideointelligenceV1p2beta1SpeechRecognitionAlternative 4906 var s1 struct { 4907 Confidence gensupport.JSONFloat64 `json:"confidence"` 4908 *NoMethod 4909 } 4910 s1.NoMethod = (*NoMethod)(s) 4911 if err := json.Unmarshal(data, &s1); err != nil { 4912 return err 4913 } 4914 s.Confidence = float64(s1.Confidence) 4915 return nil 4916 } 4917 4918 // GoogleCloudVideointelligenceV1p2beta1SpeechTranscription: A speech 4919 // recognition result corresponding to a portion of the audio. 4920 type GoogleCloudVideointelligenceV1p2beta1SpeechTranscription struct { 4921 // Alternatives: May contain one or more recognition hypotheses (up to the 4922 // maximum specified in `max_alternatives`). These alternatives are ordered in 4923 // terms of accuracy, with the top (first) alternative being the most probable, 4924 // as ranked by the recognizer. 4925 Alternatives []*GoogleCloudVideointelligenceV1p2beta1SpeechRecognitionAlternative `json:"alternatives,omitempty"` 4926 // LanguageCode: Output only. The BCP-47 4927 // (https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag of the language 4928 // in this result. This language code was detected to have the most likelihood 4929 // of being spoken in the audio. 4930 LanguageCode string `json:"languageCode,omitempty"` 4931 // ForceSendFields is a list of field names (e.g. "Alternatives") to 4932 // unconditionally include in API requests. By default, fields with empty or 4933 // default values are omitted from API requests. See 4934 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4935 // details. 4936 ForceSendFields []string `json:"-"` 4937 // NullFields is a list of field names (e.g. "Alternatives") to include in API 4938 // requests with the JSON null value. By default, fields with empty values are 4939 // omitted from API requests. See 4940 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4941 NullFields []string `json:"-"` 4942 } 4943 4944 func (s *GoogleCloudVideointelligenceV1p2beta1SpeechTranscription) MarshalJSON() ([]byte, error) { 4945 type NoMethod GoogleCloudVideointelligenceV1p2beta1SpeechTranscription 4946 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4947 } 4948 4949 // GoogleCloudVideointelligenceV1p2beta1TextAnnotation: Annotations related to 4950 // one detected OCR text snippet. This will contain the corresponding text, 4951 // confidence value, and frame level information for each detection. 4952 type GoogleCloudVideointelligenceV1p2beta1TextAnnotation struct { 4953 // Segments: All video segments where OCR detected text appears. 4954 Segments []*GoogleCloudVideointelligenceV1p2beta1TextSegment `json:"segments,omitempty"` 4955 // Text: The detected text. 4956 Text string `json:"text,omitempty"` 4957 // Version: Feature version. 4958 Version string `json:"version,omitempty"` 4959 // ForceSendFields is a list of field names (e.g. "Segments") to 4960 // unconditionally include in API requests. By default, fields with empty or 4961 // default values are omitted from API requests. See 4962 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4963 // details. 4964 ForceSendFields []string `json:"-"` 4965 // NullFields is a list of field names (e.g. "Segments") to include in API 4966 // requests with the JSON null value. By default, fields with empty values are 4967 // omitted from API requests. See 4968 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4969 NullFields []string `json:"-"` 4970 } 4971 4972 func (s *GoogleCloudVideointelligenceV1p2beta1TextAnnotation) MarshalJSON() ([]byte, error) { 4973 type NoMethod GoogleCloudVideointelligenceV1p2beta1TextAnnotation 4974 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 4975 } 4976 4977 // GoogleCloudVideointelligenceV1p2beta1TextFrame: Video frame level annotation 4978 // results for text annotation (OCR). Contains information regarding timestamp 4979 // and bounding box locations for the frames containing detected OCR text 4980 // snippets. 4981 type GoogleCloudVideointelligenceV1p2beta1TextFrame struct { 4982 // RotatedBoundingBox: Bounding polygon of the detected text for this frame. 4983 RotatedBoundingBox *GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingPoly `json:"rotatedBoundingBox,omitempty"` 4984 // TimeOffset: Timestamp of this frame. 4985 TimeOffset string `json:"timeOffset,omitempty"` 4986 // ForceSendFields is a list of field names (e.g. "RotatedBoundingBox") to 4987 // unconditionally include in API requests. By default, fields with empty or 4988 // default values are omitted from API requests. See 4989 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 4990 // details. 4991 ForceSendFields []string `json:"-"` 4992 // NullFields is a list of field names (e.g. "RotatedBoundingBox") to include 4993 // in API requests with the JSON null value. By default, fields with empty 4994 // values are omitted from API requests. See 4995 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 4996 NullFields []string `json:"-"` 4997 } 4998 4999 func (s *GoogleCloudVideointelligenceV1p2beta1TextFrame) MarshalJSON() ([]byte, error) { 5000 type NoMethod GoogleCloudVideointelligenceV1p2beta1TextFrame 5001 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5002 } 5003 5004 // GoogleCloudVideointelligenceV1p2beta1TextSegment: Video segment level 5005 // annotation results for text detection. 5006 type GoogleCloudVideointelligenceV1p2beta1TextSegment struct { 5007 // Confidence: Confidence for the track of detected text. It is calculated as 5008 // the highest over all frames where OCR detected text appears. 5009 Confidence float64 `json:"confidence,omitempty"` 5010 // Frames: Information related to the frames where OCR detected text appears. 5011 Frames []*GoogleCloudVideointelligenceV1p2beta1TextFrame `json:"frames,omitempty"` 5012 // Segment: Video segment where a text snippet was detected. 5013 Segment *GoogleCloudVideointelligenceV1p2beta1VideoSegment `json:"segment,omitempty"` 5014 // ForceSendFields is a list of field names (e.g. "Confidence") to 5015 // unconditionally include in API requests. By default, fields with empty or 5016 // default values are omitted from API requests. See 5017 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5018 // details. 5019 ForceSendFields []string `json:"-"` 5020 // NullFields is a list of field names (e.g. "Confidence") to include in API 5021 // requests with the JSON null value. By default, fields with empty values are 5022 // omitted from API requests. See 5023 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5024 NullFields []string `json:"-"` 5025 } 5026 5027 func (s *GoogleCloudVideointelligenceV1p2beta1TextSegment) MarshalJSON() ([]byte, error) { 5028 type NoMethod GoogleCloudVideointelligenceV1p2beta1TextSegment 5029 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5030 } 5031 5032 func (s *GoogleCloudVideointelligenceV1p2beta1TextSegment) UnmarshalJSON(data []byte) error { 5033 type NoMethod GoogleCloudVideointelligenceV1p2beta1TextSegment 5034 var s1 struct { 5035 Confidence gensupport.JSONFloat64 `json:"confidence"` 5036 *NoMethod 5037 } 5038 s1.NoMethod = (*NoMethod)(s) 5039 if err := json.Unmarshal(data, &s1); err != nil { 5040 return err 5041 } 5042 s.Confidence = float64(s1.Confidence) 5043 return nil 5044 } 5045 5046 // GoogleCloudVideointelligenceV1p2beta1TimestampedObject: For tracking related 5047 // features. An object at time_offset with attributes, and located with 5048 // normalized_bounding_box. 5049 type GoogleCloudVideointelligenceV1p2beta1TimestampedObject struct { 5050 // Attributes: Optional. The attributes of the object in the bounding box. 5051 Attributes []*GoogleCloudVideointelligenceV1p2beta1DetectedAttribute `json:"attributes,omitempty"` 5052 // Landmarks: Optional. The detected landmarks. 5053 Landmarks []*GoogleCloudVideointelligenceV1p2beta1DetectedLandmark `json:"landmarks,omitempty"` 5054 // NormalizedBoundingBox: Normalized Bounding box in a frame, where the object 5055 // is located. 5056 NormalizedBoundingBox *GoogleCloudVideointelligenceV1p2beta1NormalizedBoundingBox `json:"normalizedBoundingBox,omitempty"` 5057 // TimeOffset: Time-offset, relative to the beginning of the video, 5058 // corresponding to the video frame for this object. 5059 TimeOffset string `json:"timeOffset,omitempty"` 5060 // ForceSendFields is a list of field names (e.g. "Attributes") to 5061 // unconditionally include in API requests. By default, fields with empty or 5062 // default values are omitted from API requests. See 5063 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5064 // details. 5065 ForceSendFields []string `json:"-"` 5066 // NullFields is a list of field names (e.g. "Attributes") to include in API 5067 // requests with the JSON null value. By default, fields with empty values are 5068 // omitted from API requests. See 5069 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5070 NullFields []string `json:"-"` 5071 } 5072 5073 func (s *GoogleCloudVideointelligenceV1p2beta1TimestampedObject) MarshalJSON() ([]byte, error) { 5074 type NoMethod GoogleCloudVideointelligenceV1p2beta1TimestampedObject 5075 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5076 } 5077 5078 // GoogleCloudVideointelligenceV1p2beta1Track: A track of an object instance. 5079 type GoogleCloudVideointelligenceV1p2beta1Track struct { 5080 // Attributes: Optional. Attributes in the track level. 5081 Attributes []*GoogleCloudVideointelligenceV1p2beta1DetectedAttribute `json:"attributes,omitempty"` 5082 // Confidence: Optional. The confidence score of the tracked object. 5083 Confidence float64 `json:"confidence,omitempty"` 5084 // Segment: Video segment of a track. 5085 Segment *GoogleCloudVideointelligenceV1p2beta1VideoSegment `json:"segment,omitempty"` 5086 // TimestampedObjects: The object with timestamp and attributes per frame in 5087 // the track. 5088 TimestampedObjects []*GoogleCloudVideointelligenceV1p2beta1TimestampedObject `json:"timestampedObjects,omitempty"` 5089 // ForceSendFields is a list of field names (e.g. "Attributes") to 5090 // unconditionally include in API requests. By default, fields with empty or 5091 // default values are omitted from API requests. See 5092 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5093 // details. 5094 ForceSendFields []string `json:"-"` 5095 // NullFields is a list of field names (e.g. "Attributes") to include in API 5096 // requests with the JSON null value. By default, fields with empty values are 5097 // omitted from API requests. See 5098 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5099 NullFields []string `json:"-"` 5100 } 5101 5102 func (s *GoogleCloudVideointelligenceV1p2beta1Track) MarshalJSON() ([]byte, error) { 5103 type NoMethod GoogleCloudVideointelligenceV1p2beta1Track 5104 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5105 } 5106 5107 func (s *GoogleCloudVideointelligenceV1p2beta1Track) UnmarshalJSON(data []byte) error { 5108 type NoMethod GoogleCloudVideointelligenceV1p2beta1Track 5109 var s1 struct { 5110 Confidence gensupport.JSONFloat64 `json:"confidence"` 5111 *NoMethod 5112 } 5113 s1.NoMethod = (*NoMethod)(s) 5114 if err := json.Unmarshal(data, &s1); err != nil { 5115 return err 5116 } 5117 s.Confidence = float64(s1.Confidence) 5118 return nil 5119 } 5120 5121 // GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress: Annotation 5122 // progress for a single video. 5123 type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress struct { 5124 // Feature: Specifies which feature is being tracked if the request contains 5125 // more than one feature. 5126 // 5127 // Possible values: 5128 // "FEATURE_UNSPECIFIED" - Unspecified. 5129 // "LABEL_DETECTION" - Label detection. Detect objects, such as dog or 5130 // flower. 5131 // "SHOT_CHANGE_DETECTION" - Shot change detection. 5132 // "EXPLICIT_CONTENT_DETECTION" - Explicit content detection. 5133 // "FACE_DETECTION" - Human face detection. 5134 // "SPEECH_TRANSCRIPTION" - Speech transcription. 5135 // "TEXT_DETECTION" - OCR text detection and tracking. 5136 // "OBJECT_TRACKING" - Object detection and tracking. 5137 // "LOGO_RECOGNITION" - Logo detection, tracking, and recognition. 5138 // "PERSON_DETECTION" - Person detection. 5139 Feature string `json:"feature,omitempty"` 5140 // InputUri: Video file location in Cloud Storage 5141 // (https://cloud.google.com/storage/). 5142 InputUri string `json:"inputUri,omitempty"` 5143 // ProgressPercent: Approximate percentage processed thus far. Guaranteed to be 5144 // 100 when fully processed. 5145 ProgressPercent int64 `json:"progressPercent,omitempty"` 5146 // Segment: Specifies which segment is being tracked if the request contains 5147 // more than one segment. 5148 Segment *GoogleCloudVideointelligenceV1p2beta1VideoSegment `json:"segment,omitempty"` 5149 // StartTime: Time when the request was received. 5150 StartTime string `json:"startTime,omitempty"` 5151 // UpdateTime: Time of the most recent update. 5152 UpdateTime string `json:"updateTime,omitempty"` 5153 // ForceSendFields is a list of field names (e.g. "Feature") to unconditionally 5154 // include in API requests. By default, fields with empty or default values are 5155 // omitted from API requests. See 5156 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5157 // details. 5158 ForceSendFields []string `json:"-"` 5159 // NullFields is a list of field names (e.g. "Feature") to include in API 5160 // requests with the JSON null value. By default, fields with empty values are 5161 // omitted from API requests. See 5162 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5163 NullFields []string `json:"-"` 5164 } 5165 5166 func (s *GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress) MarshalJSON() ([]byte, error) { 5167 type NoMethod GoogleCloudVideointelligenceV1p2beta1VideoAnnotationProgress 5168 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5169 } 5170 5171 // GoogleCloudVideointelligenceV1p2beta1VideoAnnotationResults: Annotation 5172 // results for a single video. 5173 type GoogleCloudVideointelligenceV1p2beta1VideoAnnotationResults struct { 5174 // Error: If set, indicates an error. Note that for a single 5175 // `AnnotateVideoRequest` some videos may succeed and some may fail. 5176 Error *GoogleRpcStatus `json:"error,omitempty"` 5177 // ExplicitAnnotation: Explicit content annotation. 5178 ExplicitAnnotation *GoogleCloudVideointelligenceV1p2beta1ExplicitContentAnnotation `json:"explicitAnnotation,omitempty"` 5179 // FaceAnnotations: Deprecated. Please use `face_detection_annotations` 5180 // instead. 5181 FaceAnnotations []*GoogleCloudVideointelligenceV1p2beta1FaceAnnotation `json:"faceAnnotations,omitempty"` 5182 // FaceDetectionAnnotations: Face detection annotations. 5183 FaceDetectionAnnotations []*GoogleCloudVideointelligenceV1p2beta1FaceDetectionAnnotation `json:"faceDetectionAnnotations,omitempty"` 5184 // FrameLabelAnnotations: Label annotations on frame level. There is exactly 5185 // one element for each unique label. 5186 FrameLabelAnnotations []*GoogleCloudVideointelligenceV1p2beta1LabelAnnotation `json:"frameLabelAnnotations,omitempty"` 5187 // InputUri: Video file location in Cloud Storage 5188 // (https://cloud.google.com/storage/). 5189 InputUri string `json:"inputUri,omitempty"` 5190 // LogoRecognitionAnnotations: Annotations for list of logos detected, tracked 5191 // and recognized in video. 5192 LogoRecognitionAnnotations []*GoogleCloudVideointelligenceV1p2beta1LogoRecognitionAnnotation `json:"logoRecognitionAnnotations,omitempty"` 5193 // ObjectAnnotations: Annotations for list of objects detected and tracked in 5194 // video. 5195 ObjectAnnotations []*GoogleCloudVideointelligenceV1p2beta1ObjectTrackingAnnotation `json:"objectAnnotations,omitempty"` 5196 // PersonDetectionAnnotations: Person detection annotations. 5197 PersonDetectionAnnotations []*GoogleCloudVideointelligenceV1p2beta1PersonDetectionAnnotation `json:"personDetectionAnnotations,omitempty"` 5198 // Segment: Video segment on which the annotation is run. 5199 Segment *GoogleCloudVideointelligenceV1p2beta1VideoSegment `json:"segment,omitempty"` 5200 // SegmentLabelAnnotations: Topical label annotations on video level or 5201 // user-specified segment level. There is exactly one element for each unique 5202 // label. 5203 SegmentLabelAnnotations []*GoogleCloudVideointelligenceV1p2beta1LabelAnnotation `json:"segmentLabelAnnotations,omitempty"` 5204 // SegmentPresenceLabelAnnotations: Presence label annotations on video level 5205 // or user-specified segment level. There is exactly one element for each 5206 // unique label. Compared to the existing topical `segment_label_annotations`, 5207 // this field presents more fine-grained, segment-level labels detected in 5208 // video content and is made available only when the client sets 5209 // `LabelDetectionConfig.model` to "builtin/latest" in the request. 5210 SegmentPresenceLabelAnnotations []*GoogleCloudVideointelligenceV1p2beta1LabelAnnotation `json:"segmentPresenceLabelAnnotations,omitempty"` 5211 // ShotAnnotations: Shot annotations. Each shot is represented as a video 5212 // segment. 5213 ShotAnnotations []*GoogleCloudVideointelligenceV1p2beta1VideoSegment `json:"shotAnnotations,omitempty"` 5214 // ShotLabelAnnotations: Topical label annotations on shot level. There is 5215 // exactly one element for each unique label. 5216 ShotLabelAnnotations []*GoogleCloudVideointelligenceV1p2beta1LabelAnnotation `json:"shotLabelAnnotations,omitempty"` 5217 // ShotPresenceLabelAnnotations: Presence label annotations on shot level. 5218 // There is exactly one element for each unique label. Compared to the existing 5219 // topical `shot_label_annotations`, this field presents more fine-grained, 5220 // shot-level labels detected in video content and is made available only when 5221 // the client sets `LabelDetectionConfig.model` to "builtin/latest" in the 5222 // request. 5223 ShotPresenceLabelAnnotations []*GoogleCloudVideointelligenceV1p2beta1LabelAnnotation `json:"shotPresenceLabelAnnotations,omitempty"` 5224 // SpeechTranscriptions: Speech transcription. 5225 SpeechTranscriptions []*GoogleCloudVideointelligenceV1p2beta1SpeechTranscription `json:"speechTranscriptions,omitempty"` 5226 // TextAnnotations: OCR text detection and tracking. Annotations for list of 5227 // detected text snippets. Each will have list of frame information associated 5228 // with it. 5229 TextAnnotations []*GoogleCloudVideointelligenceV1p2beta1TextAnnotation `json:"textAnnotations,omitempty"` 5230 // ForceSendFields is a list of field names (e.g. "Error") to unconditionally 5231 // include in API requests. By default, fields with empty or default values are 5232 // omitted from API requests. See 5233 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5234 // details. 5235 ForceSendFields []string `json:"-"` 5236 // NullFields is a list of field names (e.g. "Error") to include in API 5237 // requests with the JSON null value. By default, fields with empty values are 5238 // omitted from API requests. See 5239 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5240 NullFields []string `json:"-"` 5241 } 5242 5243 func (s *GoogleCloudVideointelligenceV1p2beta1VideoAnnotationResults) MarshalJSON() ([]byte, error) { 5244 type NoMethod GoogleCloudVideointelligenceV1p2beta1VideoAnnotationResults 5245 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5246 } 5247 5248 // GoogleCloudVideointelligenceV1p2beta1VideoSegment: Video segment. 5249 type GoogleCloudVideointelligenceV1p2beta1VideoSegment struct { 5250 // EndTimeOffset: Time-offset, relative to the beginning of the video, 5251 // corresponding to the end of the segment (inclusive). 5252 EndTimeOffset string `json:"endTimeOffset,omitempty"` 5253 // StartTimeOffset: Time-offset, relative to the beginning of the video, 5254 // corresponding to the start of the segment (inclusive). 5255 StartTimeOffset string `json:"startTimeOffset,omitempty"` 5256 // ForceSendFields is a list of field names (e.g. "EndTimeOffset") to 5257 // unconditionally include in API requests. By default, fields with empty or 5258 // default values are omitted from API requests. See 5259 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5260 // details. 5261 ForceSendFields []string `json:"-"` 5262 // NullFields is a list of field names (e.g. "EndTimeOffset") to include in API 5263 // requests with the JSON null value. By default, fields with empty values are 5264 // omitted from API requests. See 5265 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5266 NullFields []string `json:"-"` 5267 } 5268 5269 func (s *GoogleCloudVideointelligenceV1p2beta1VideoSegment) MarshalJSON() ([]byte, error) { 5270 type NoMethod GoogleCloudVideointelligenceV1p2beta1VideoSegment 5271 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5272 } 5273 5274 // GoogleCloudVideointelligenceV1p2beta1WordInfo: Word-specific information for 5275 // recognized words. Word information is only included in the response when 5276 // certain request parameters are set, such as `enable_word_time_offsets`. 5277 type GoogleCloudVideointelligenceV1p2beta1WordInfo struct { 5278 // Confidence: Output only. The confidence estimate between 0.0 and 1.0. A 5279 // higher number indicates an estimated greater likelihood that the recognized 5280 // words are correct. This field is set only for the top alternative. This 5281 // field is not guaranteed to be accurate and users should not rely on it to be 5282 // always provided. The default of 0.0 is a sentinel value indicating 5283 // `confidence` was not set. 5284 Confidence float64 `json:"confidence,omitempty"` 5285 // EndTime: Time offset relative to the beginning of the audio, and 5286 // corresponding to the end of the spoken word. This field is only set if 5287 // `enable_word_time_offsets=true` and only in the top hypothesis. This is an 5288 // experimental feature and the accuracy of the time offset can vary. 5289 EndTime string `json:"endTime,omitempty"` 5290 // SpeakerTag: Output only. A distinct integer value is assigned for every 5291 // speaker within the audio. This field specifies which one of those speakers 5292 // was detected to have spoken this word. Value ranges from 1 up to 5293 // diarization_speaker_count, and is only set if speaker diarization is 5294 // enabled. 5295 SpeakerTag int64 `json:"speakerTag,omitempty"` 5296 // StartTime: Time offset relative to the beginning of the audio, and 5297 // corresponding to the start of the spoken word. This field is only set if 5298 // `enable_word_time_offsets=true` and only in the top hypothesis. This is an 5299 // experimental feature and the accuracy of the time offset can vary. 5300 StartTime string `json:"startTime,omitempty"` 5301 // Word: The word corresponding to this set of information. 5302 Word string `json:"word,omitempty"` 5303 // ForceSendFields is a list of field names (e.g. "Confidence") to 5304 // unconditionally include in API requests. By default, fields with empty or 5305 // default values are omitted from API requests. See 5306 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5307 // details. 5308 ForceSendFields []string `json:"-"` 5309 // NullFields is a list of field names (e.g. "Confidence") to include in API 5310 // requests with the JSON null value. By default, fields with empty values are 5311 // omitted from API requests. See 5312 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5313 NullFields []string `json:"-"` 5314 } 5315 5316 func (s *GoogleCloudVideointelligenceV1p2beta1WordInfo) MarshalJSON() ([]byte, error) { 5317 type NoMethod GoogleCloudVideointelligenceV1p2beta1WordInfo 5318 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5319 } 5320 5321 func (s *GoogleCloudVideointelligenceV1p2beta1WordInfo) UnmarshalJSON(data []byte) error { 5322 type NoMethod GoogleCloudVideointelligenceV1p2beta1WordInfo 5323 var s1 struct { 5324 Confidence gensupport.JSONFloat64 `json:"confidence"` 5325 *NoMethod 5326 } 5327 s1.NoMethod = (*NoMethod)(s) 5328 if err := json.Unmarshal(data, &s1); err != nil { 5329 return err 5330 } 5331 s.Confidence = float64(s1.Confidence) 5332 return nil 5333 } 5334 5335 // GoogleCloudVideointelligenceV1p3beta1AnnotateVideoProgress: Video annotation 5336 // progress. Included in the `metadata` field of the `Operation` returned by 5337 // the `GetOperation` call of the `google::longrunning::Operations` service. 5338 type GoogleCloudVideointelligenceV1p3beta1AnnotateVideoProgress struct { 5339 // AnnotationProgress: Progress metadata for all videos specified in 5340 // `AnnotateVideoRequest`. 5341 AnnotationProgress []*GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress `json:"annotationProgress,omitempty"` 5342 // ForceSendFields is a list of field names (e.g. "AnnotationProgress") to 5343 // unconditionally include in API requests. By default, fields with empty or 5344 // default values are omitted from API requests. See 5345 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5346 // details. 5347 ForceSendFields []string `json:"-"` 5348 // NullFields is a list of field names (e.g. "AnnotationProgress") to include 5349 // in API requests with the JSON null value. By default, fields with empty 5350 // values are omitted from API requests. See 5351 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5352 NullFields []string `json:"-"` 5353 } 5354 5355 func (s *GoogleCloudVideointelligenceV1p3beta1AnnotateVideoProgress) MarshalJSON() ([]byte, error) { 5356 type NoMethod GoogleCloudVideointelligenceV1p3beta1AnnotateVideoProgress 5357 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5358 } 5359 5360 // GoogleCloudVideointelligenceV1p3beta1AnnotateVideoResponse: Video annotation 5361 // response. Included in the `response` field of the `Operation` returned by 5362 // the `GetOperation` call of the `google::longrunning::Operations` service. 5363 type GoogleCloudVideointelligenceV1p3beta1AnnotateVideoResponse struct { 5364 // AnnotationResults: Annotation results for all videos specified in 5365 // `AnnotateVideoRequest`. 5366 AnnotationResults []*GoogleCloudVideointelligenceV1p3beta1VideoAnnotationResults `json:"annotationResults,omitempty"` 5367 // ForceSendFields is a list of field names (e.g. "AnnotationResults") to 5368 // unconditionally include in API requests. By default, fields with empty or 5369 // default values are omitted from API requests. See 5370 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5371 // details. 5372 ForceSendFields []string `json:"-"` 5373 // NullFields is a list of field names (e.g. "AnnotationResults") to include in 5374 // API requests with the JSON null value. By default, fields with empty values 5375 // are omitted from API requests. See 5376 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5377 NullFields []string `json:"-"` 5378 } 5379 5380 func (s *GoogleCloudVideointelligenceV1p3beta1AnnotateVideoResponse) MarshalJSON() ([]byte, error) { 5381 type NoMethod GoogleCloudVideointelligenceV1p3beta1AnnotateVideoResponse 5382 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5383 } 5384 5385 // GoogleCloudVideointelligenceV1p3beta1Celebrity: Celebrity definition. 5386 type GoogleCloudVideointelligenceV1p3beta1Celebrity struct { 5387 // Description: Textual description of additional information about the 5388 // celebrity, if applicable. 5389 Description string `json:"description,omitempty"` 5390 // DisplayName: The celebrity name. 5391 DisplayName string `json:"displayName,omitempty"` 5392 // Name: The resource name of the celebrity. Have the format 5393 // `video-intelligence/kg-mid` indicates a celebrity from preloaded gallery. 5394 // kg-mid is the id in Google knowledge graph, which is unique for the 5395 // celebrity. 5396 Name string `json:"name,omitempty"` 5397 // ForceSendFields is a list of field names (e.g. "Description") to 5398 // unconditionally include in API requests. By default, fields with empty or 5399 // default values are omitted from API requests. See 5400 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5401 // details. 5402 ForceSendFields []string `json:"-"` 5403 // NullFields is a list of field names (e.g. "Description") to include in API 5404 // requests with the JSON null value. By default, fields with empty values are 5405 // omitted from API requests. See 5406 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5407 NullFields []string `json:"-"` 5408 } 5409 5410 func (s *GoogleCloudVideointelligenceV1p3beta1Celebrity) MarshalJSON() ([]byte, error) { 5411 type NoMethod GoogleCloudVideointelligenceV1p3beta1Celebrity 5412 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5413 } 5414 5415 // GoogleCloudVideointelligenceV1p3beta1CelebrityRecognitionAnnotation: 5416 // Celebrity recognition annotation per video. 5417 type GoogleCloudVideointelligenceV1p3beta1CelebrityRecognitionAnnotation struct { 5418 // CelebrityTracks: The tracks detected from the input video, including 5419 // recognized celebrities and other detected faces in the video. 5420 CelebrityTracks []*GoogleCloudVideointelligenceV1p3beta1CelebrityTrack `json:"celebrityTracks,omitempty"` 5421 // Version: Feature version. 5422 Version string `json:"version,omitempty"` 5423 // ForceSendFields is a list of field names (e.g. "CelebrityTracks") to 5424 // unconditionally include in API requests. By default, fields with empty or 5425 // default values are omitted from API requests. See 5426 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5427 // details. 5428 ForceSendFields []string `json:"-"` 5429 // NullFields is a list of field names (e.g. "CelebrityTracks") to include in 5430 // API requests with the JSON null value. By default, fields with empty values 5431 // are omitted from API requests. See 5432 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5433 NullFields []string `json:"-"` 5434 } 5435 5436 func (s *GoogleCloudVideointelligenceV1p3beta1CelebrityRecognitionAnnotation) MarshalJSON() ([]byte, error) { 5437 type NoMethod GoogleCloudVideointelligenceV1p3beta1CelebrityRecognitionAnnotation 5438 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5439 } 5440 5441 // GoogleCloudVideointelligenceV1p3beta1CelebrityTrack: The annotation result 5442 // of a celebrity face track. RecognizedCelebrity field could be empty if the 5443 // face track does not have any matched celebrities. 5444 type GoogleCloudVideointelligenceV1p3beta1CelebrityTrack struct { 5445 // Celebrities: Top N match of the celebrities for the face in this track. 5446 Celebrities []*GoogleCloudVideointelligenceV1p3beta1RecognizedCelebrity `json:"celebrities,omitempty"` 5447 // FaceTrack: A track of a person's face. 5448 FaceTrack *GoogleCloudVideointelligenceV1p3beta1Track `json:"faceTrack,omitempty"` 5449 // ForceSendFields is a list of field names (e.g. "Celebrities") to 5450 // unconditionally include in API requests. By default, fields with empty or 5451 // default values are omitted from API requests. See 5452 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5453 // details. 5454 ForceSendFields []string `json:"-"` 5455 // NullFields is a list of field names (e.g. "Celebrities") to include in API 5456 // requests with the JSON null value. By default, fields with empty values are 5457 // omitted from API requests. See 5458 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5459 NullFields []string `json:"-"` 5460 } 5461 5462 func (s *GoogleCloudVideointelligenceV1p3beta1CelebrityTrack) MarshalJSON() ([]byte, error) { 5463 type NoMethod GoogleCloudVideointelligenceV1p3beta1CelebrityTrack 5464 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5465 } 5466 5467 // GoogleCloudVideointelligenceV1p3beta1DetectedAttribute: A generic detected 5468 // attribute represented by name in string format. 5469 type GoogleCloudVideointelligenceV1p3beta1DetectedAttribute struct { 5470 // Confidence: Detected attribute confidence. Range [0, 1]. 5471 Confidence float64 `json:"confidence,omitempty"` 5472 // Name: The name of the attribute, for example, glasses, dark_glasses, 5473 // mouth_open. A full list of supported type names will be provided in the 5474 // document. 5475 Name string `json:"name,omitempty"` 5476 // Value: Text value of the detection result. For example, the value for 5477 // "HairColor" can be "black", "blonde", etc. 5478 Value string `json:"value,omitempty"` 5479 // ForceSendFields is a list of field names (e.g. "Confidence") to 5480 // unconditionally include in API requests. By default, fields with empty or 5481 // default values are omitted from API requests. See 5482 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5483 // details. 5484 ForceSendFields []string `json:"-"` 5485 // NullFields is a list of field names (e.g. "Confidence") to include in API 5486 // requests with the JSON null value. By default, fields with empty values are 5487 // omitted from API requests. See 5488 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5489 NullFields []string `json:"-"` 5490 } 5491 5492 func (s *GoogleCloudVideointelligenceV1p3beta1DetectedAttribute) MarshalJSON() ([]byte, error) { 5493 type NoMethod GoogleCloudVideointelligenceV1p3beta1DetectedAttribute 5494 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5495 } 5496 5497 func (s *GoogleCloudVideointelligenceV1p3beta1DetectedAttribute) UnmarshalJSON(data []byte) error { 5498 type NoMethod GoogleCloudVideointelligenceV1p3beta1DetectedAttribute 5499 var s1 struct { 5500 Confidence gensupport.JSONFloat64 `json:"confidence"` 5501 *NoMethod 5502 } 5503 s1.NoMethod = (*NoMethod)(s) 5504 if err := json.Unmarshal(data, &s1); err != nil { 5505 return err 5506 } 5507 s.Confidence = float64(s1.Confidence) 5508 return nil 5509 } 5510 5511 // GoogleCloudVideointelligenceV1p3beta1DetectedLandmark: A generic detected 5512 // landmark represented by name in string format and a 2D location. 5513 type GoogleCloudVideointelligenceV1p3beta1DetectedLandmark struct { 5514 // Confidence: The confidence score of the detected landmark. Range [0, 1]. 5515 Confidence float64 `json:"confidence,omitempty"` 5516 // Name: The name of this landmark, for example, left_hand, right_shoulder. 5517 Name string `json:"name,omitempty"` 5518 // Point: The 2D point of the detected landmark using the normalized image 5519 // coordindate system. The normalized coordinates have the range from 0 to 1. 5520 Point *GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"point,omitempty"` 5521 // ForceSendFields is a list of field names (e.g. "Confidence") to 5522 // unconditionally include in API requests. By default, fields with empty or 5523 // default values are omitted from API requests. See 5524 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5525 // details. 5526 ForceSendFields []string `json:"-"` 5527 // NullFields is a list of field names (e.g. "Confidence") to include in API 5528 // requests with the JSON null value. By default, fields with empty values are 5529 // omitted from API requests. See 5530 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5531 NullFields []string `json:"-"` 5532 } 5533 5534 func (s *GoogleCloudVideointelligenceV1p3beta1DetectedLandmark) MarshalJSON() ([]byte, error) { 5535 type NoMethod GoogleCloudVideointelligenceV1p3beta1DetectedLandmark 5536 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5537 } 5538 5539 func (s *GoogleCloudVideointelligenceV1p3beta1DetectedLandmark) UnmarshalJSON(data []byte) error { 5540 type NoMethod GoogleCloudVideointelligenceV1p3beta1DetectedLandmark 5541 var s1 struct { 5542 Confidence gensupport.JSONFloat64 `json:"confidence"` 5543 *NoMethod 5544 } 5545 s1.NoMethod = (*NoMethod)(s) 5546 if err := json.Unmarshal(data, &s1); err != nil { 5547 return err 5548 } 5549 s.Confidence = float64(s1.Confidence) 5550 return nil 5551 } 5552 5553 // GoogleCloudVideointelligenceV1p3beta1Entity: Detected entity from video 5554 // analysis. 5555 type GoogleCloudVideointelligenceV1p3beta1Entity struct { 5556 // Description: Textual description, e.g., `Fixed-gear bicycle`. 5557 Description string `json:"description,omitempty"` 5558 // EntityId: Opaque entity ID. Some IDs may be available in Google Knowledge 5559 // Graph Search API (https://developers.google.com/knowledge-graph/). 5560 EntityId string `json:"entityId,omitempty"` 5561 // LanguageCode: Language code for `description` in BCP-47 format. 5562 LanguageCode string `json:"languageCode,omitempty"` 5563 // ForceSendFields is a list of field names (e.g. "Description") to 5564 // unconditionally include in API requests. By default, fields with empty or 5565 // default values are omitted from API requests. See 5566 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5567 // details. 5568 ForceSendFields []string `json:"-"` 5569 // NullFields is a list of field names (e.g. "Description") to include in API 5570 // requests with the JSON null value. By default, fields with empty values are 5571 // omitted from API requests. See 5572 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5573 NullFields []string `json:"-"` 5574 } 5575 5576 func (s *GoogleCloudVideointelligenceV1p3beta1Entity) MarshalJSON() ([]byte, error) { 5577 type NoMethod GoogleCloudVideointelligenceV1p3beta1Entity 5578 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5579 } 5580 5581 // GoogleCloudVideointelligenceV1p3beta1ExplicitContentAnnotation: Explicit 5582 // content annotation (based on per-frame visual signals only). If no explicit 5583 // content has been detected in a frame, no annotations are present for that 5584 // frame. 5585 type GoogleCloudVideointelligenceV1p3beta1ExplicitContentAnnotation struct { 5586 // Frames: All video frames where explicit content was detected. 5587 Frames []*GoogleCloudVideointelligenceV1p3beta1ExplicitContentFrame `json:"frames,omitempty"` 5588 // Version: Feature version. 5589 Version string `json:"version,omitempty"` 5590 // ForceSendFields is a list of field names (e.g. "Frames") to unconditionally 5591 // include in API requests. By default, fields with empty or default values are 5592 // omitted from API requests. See 5593 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5594 // details. 5595 ForceSendFields []string `json:"-"` 5596 // NullFields is a list of field names (e.g. "Frames") to include in API 5597 // requests with the JSON null value. By default, fields with empty values are 5598 // omitted from API requests. See 5599 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5600 NullFields []string `json:"-"` 5601 } 5602 5603 func (s *GoogleCloudVideointelligenceV1p3beta1ExplicitContentAnnotation) MarshalJSON() ([]byte, error) { 5604 type NoMethod GoogleCloudVideointelligenceV1p3beta1ExplicitContentAnnotation 5605 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5606 } 5607 5608 // GoogleCloudVideointelligenceV1p3beta1ExplicitContentFrame: Video frame level 5609 // annotation results for explicit content. 5610 type GoogleCloudVideointelligenceV1p3beta1ExplicitContentFrame struct { 5611 // PornographyLikelihood: Likelihood of the pornography content.. 5612 // 5613 // Possible values: 5614 // "LIKELIHOOD_UNSPECIFIED" - Unspecified likelihood. 5615 // "VERY_UNLIKELY" - Very unlikely. 5616 // "UNLIKELY" - Unlikely. 5617 // "POSSIBLE" - Possible. 5618 // "LIKELY" - Likely. 5619 // "VERY_LIKELY" - Very likely. 5620 PornographyLikelihood string `json:"pornographyLikelihood,omitempty"` 5621 // TimeOffset: Time-offset, relative to the beginning of the video, 5622 // corresponding to the video frame for this location. 5623 TimeOffset string `json:"timeOffset,omitempty"` 5624 // ForceSendFields is a list of field names (e.g. "PornographyLikelihood") to 5625 // unconditionally include in API requests. By default, fields with empty or 5626 // default values are omitted from API requests. See 5627 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5628 // details. 5629 ForceSendFields []string `json:"-"` 5630 // NullFields is a list of field names (e.g. "PornographyLikelihood") to 5631 // include in API requests with the JSON null value. By default, fields with 5632 // empty values are omitted from API requests. See 5633 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5634 NullFields []string `json:"-"` 5635 } 5636 5637 func (s *GoogleCloudVideointelligenceV1p3beta1ExplicitContentFrame) MarshalJSON() ([]byte, error) { 5638 type NoMethod GoogleCloudVideointelligenceV1p3beta1ExplicitContentFrame 5639 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5640 } 5641 5642 // GoogleCloudVideointelligenceV1p3beta1FaceAnnotation: Deprecated. No effect. 5643 type GoogleCloudVideointelligenceV1p3beta1FaceAnnotation struct { 5644 // Frames: All video frames where a face was detected. 5645 Frames []*GoogleCloudVideointelligenceV1p3beta1FaceFrame `json:"frames,omitempty"` 5646 // Segments: All video segments where a face was detected. 5647 Segments []*GoogleCloudVideointelligenceV1p3beta1FaceSegment `json:"segments,omitempty"` 5648 // Thumbnail: Thumbnail of a representative face view (in JPEG format). 5649 Thumbnail string `json:"thumbnail,omitempty"` 5650 // ForceSendFields is a list of field names (e.g. "Frames") to unconditionally 5651 // include in API requests. By default, fields with empty or default values are 5652 // omitted from API requests. See 5653 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5654 // details. 5655 ForceSendFields []string `json:"-"` 5656 // NullFields is a list of field names (e.g. "Frames") to include in API 5657 // requests with the JSON null value. By default, fields with empty values are 5658 // omitted from API requests. See 5659 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5660 NullFields []string `json:"-"` 5661 } 5662 5663 func (s *GoogleCloudVideointelligenceV1p3beta1FaceAnnotation) MarshalJSON() ([]byte, error) { 5664 type NoMethod GoogleCloudVideointelligenceV1p3beta1FaceAnnotation 5665 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5666 } 5667 5668 // GoogleCloudVideointelligenceV1p3beta1FaceDetectionAnnotation: Face detection 5669 // annotation. 5670 type GoogleCloudVideointelligenceV1p3beta1FaceDetectionAnnotation struct { 5671 // Thumbnail: The thumbnail of a person's face. 5672 Thumbnail string `json:"thumbnail,omitempty"` 5673 // Tracks: The face tracks with attributes. 5674 Tracks []*GoogleCloudVideointelligenceV1p3beta1Track `json:"tracks,omitempty"` 5675 // Version: Feature version. 5676 Version string `json:"version,omitempty"` 5677 // ForceSendFields is a list of field names (e.g. "Thumbnail") to 5678 // unconditionally include in API requests. By default, fields with empty or 5679 // default values are omitted from API requests. See 5680 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5681 // details. 5682 ForceSendFields []string `json:"-"` 5683 // NullFields is a list of field names (e.g. "Thumbnail") to include in API 5684 // requests with the JSON null value. By default, fields with empty values are 5685 // omitted from API requests. See 5686 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5687 NullFields []string `json:"-"` 5688 } 5689 5690 func (s *GoogleCloudVideointelligenceV1p3beta1FaceDetectionAnnotation) MarshalJSON() ([]byte, error) { 5691 type NoMethod GoogleCloudVideointelligenceV1p3beta1FaceDetectionAnnotation 5692 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5693 } 5694 5695 // GoogleCloudVideointelligenceV1p3beta1FaceFrame: Deprecated. No effect. 5696 type GoogleCloudVideointelligenceV1p3beta1FaceFrame struct { 5697 // NormalizedBoundingBoxes: Normalized Bounding boxes in a frame. There can be 5698 // more than one boxes if the same face is detected in multiple locations 5699 // within the current frame. 5700 NormalizedBoundingBoxes []*GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox `json:"normalizedBoundingBoxes,omitempty"` 5701 // TimeOffset: Time-offset, relative to the beginning of the video, 5702 // corresponding to the video frame for this location. 5703 TimeOffset string `json:"timeOffset,omitempty"` 5704 // ForceSendFields is a list of field names (e.g. "NormalizedBoundingBoxes") to 5705 // unconditionally include in API requests. By default, fields with empty or 5706 // default values are omitted from API requests. See 5707 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5708 // details. 5709 ForceSendFields []string `json:"-"` 5710 // NullFields is a list of field names (e.g. "NormalizedBoundingBoxes") to 5711 // include in API requests with the JSON null value. By default, fields with 5712 // empty values are omitted from API requests. See 5713 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5714 NullFields []string `json:"-"` 5715 } 5716 5717 func (s *GoogleCloudVideointelligenceV1p3beta1FaceFrame) MarshalJSON() ([]byte, error) { 5718 type NoMethod GoogleCloudVideointelligenceV1p3beta1FaceFrame 5719 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5720 } 5721 5722 // GoogleCloudVideointelligenceV1p3beta1FaceSegment: Video segment level 5723 // annotation results for face detection. 5724 type GoogleCloudVideointelligenceV1p3beta1FaceSegment struct { 5725 // Segment: Video segment where a face was detected. 5726 Segment *GoogleCloudVideointelligenceV1p3beta1VideoSegment `json:"segment,omitempty"` 5727 // ForceSendFields is a list of field names (e.g. "Segment") to unconditionally 5728 // include in API requests. By default, fields with empty or default values are 5729 // omitted from API requests. See 5730 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5731 // details. 5732 ForceSendFields []string `json:"-"` 5733 // NullFields is a list of field names (e.g. "Segment") to include in API 5734 // requests with the JSON null value. By default, fields with empty values are 5735 // omitted from API requests. See 5736 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5737 NullFields []string `json:"-"` 5738 } 5739 5740 func (s *GoogleCloudVideointelligenceV1p3beta1FaceSegment) MarshalJSON() ([]byte, error) { 5741 type NoMethod GoogleCloudVideointelligenceV1p3beta1FaceSegment 5742 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5743 } 5744 5745 // GoogleCloudVideointelligenceV1p3beta1LabelAnnotation: Label annotation. 5746 type GoogleCloudVideointelligenceV1p3beta1LabelAnnotation struct { 5747 // CategoryEntities: Common categories for the detected entity. For example, 5748 // when the label is `Terrier`, the category is likely `dog`. And in some cases 5749 // there might be more than one categories e.g., `Terrier` could also be a 5750 // `pet`. 5751 CategoryEntities []*GoogleCloudVideointelligenceV1p3beta1Entity `json:"categoryEntities,omitempty"` 5752 // Entity: Detected entity. 5753 Entity *GoogleCloudVideointelligenceV1p3beta1Entity `json:"entity,omitempty"` 5754 // Frames: All video frames where a label was detected. 5755 Frames []*GoogleCloudVideointelligenceV1p3beta1LabelFrame `json:"frames,omitempty"` 5756 // Segments: All video segments where a label was detected. 5757 Segments []*GoogleCloudVideointelligenceV1p3beta1LabelSegment `json:"segments,omitempty"` 5758 // Version: Feature version. 5759 Version string `json:"version,omitempty"` 5760 // ForceSendFields is a list of field names (e.g. "CategoryEntities") to 5761 // unconditionally include in API requests. By default, fields with empty or 5762 // default values are omitted from API requests. See 5763 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5764 // details. 5765 ForceSendFields []string `json:"-"` 5766 // NullFields is a list of field names (e.g. "CategoryEntities") to include in 5767 // API requests with the JSON null value. By default, fields with empty values 5768 // are omitted from API requests. See 5769 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5770 NullFields []string `json:"-"` 5771 } 5772 5773 func (s *GoogleCloudVideointelligenceV1p3beta1LabelAnnotation) MarshalJSON() ([]byte, error) { 5774 type NoMethod GoogleCloudVideointelligenceV1p3beta1LabelAnnotation 5775 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5776 } 5777 5778 // GoogleCloudVideointelligenceV1p3beta1LabelFrame: Video frame level 5779 // annotation results for label detection. 5780 type GoogleCloudVideointelligenceV1p3beta1LabelFrame struct { 5781 // Confidence: Confidence that the label is accurate. Range: [0, 1]. 5782 Confidence float64 `json:"confidence,omitempty"` 5783 // TimeOffset: Time-offset, relative to the beginning of the video, 5784 // corresponding to the video frame for this location. 5785 TimeOffset string `json:"timeOffset,omitempty"` 5786 // ForceSendFields is a list of field names (e.g. "Confidence") to 5787 // unconditionally include in API requests. By default, fields with empty or 5788 // default values are omitted from API requests. See 5789 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5790 // details. 5791 ForceSendFields []string `json:"-"` 5792 // NullFields is a list of field names (e.g. "Confidence") to include in API 5793 // requests with the JSON null value. By default, fields with empty values are 5794 // omitted from API requests. See 5795 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5796 NullFields []string `json:"-"` 5797 } 5798 5799 func (s *GoogleCloudVideointelligenceV1p3beta1LabelFrame) MarshalJSON() ([]byte, error) { 5800 type NoMethod GoogleCloudVideointelligenceV1p3beta1LabelFrame 5801 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5802 } 5803 5804 func (s *GoogleCloudVideointelligenceV1p3beta1LabelFrame) UnmarshalJSON(data []byte) error { 5805 type NoMethod GoogleCloudVideointelligenceV1p3beta1LabelFrame 5806 var s1 struct { 5807 Confidence gensupport.JSONFloat64 `json:"confidence"` 5808 *NoMethod 5809 } 5810 s1.NoMethod = (*NoMethod)(s) 5811 if err := json.Unmarshal(data, &s1); err != nil { 5812 return err 5813 } 5814 s.Confidence = float64(s1.Confidence) 5815 return nil 5816 } 5817 5818 // GoogleCloudVideointelligenceV1p3beta1LabelSegment: Video segment level 5819 // annotation results for label detection. 5820 type GoogleCloudVideointelligenceV1p3beta1LabelSegment struct { 5821 // Confidence: Confidence that the label is accurate. Range: [0, 1]. 5822 Confidence float64 `json:"confidence,omitempty"` 5823 // Segment: Video segment where a label was detected. 5824 Segment *GoogleCloudVideointelligenceV1p3beta1VideoSegment `json:"segment,omitempty"` 5825 // ForceSendFields is a list of field names (e.g. "Confidence") to 5826 // unconditionally include in API requests. By default, fields with empty or 5827 // default values are omitted from API requests. See 5828 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5829 // details. 5830 ForceSendFields []string `json:"-"` 5831 // NullFields is a list of field names (e.g. "Confidence") to include in API 5832 // requests with the JSON null value. By default, fields with empty values are 5833 // omitted from API requests. See 5834 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5835 NullFields []string `json:"-"` 5836 } 5837 5838 func (s *GoogleCloudVideointelligenceV1p3beta1LabelSegment) MarshalJSON() ([]byte, error) { 5839 type NoMethod GoogleCloudVideointelligenceV1p3beta1LabelSegment 5840 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5841 } 5842 5843 func (s *GoogleCloudVideointelligenceV1p3beta1LabelSegment) UnmarshalJSON(data []byte) error { 5844 type NoMethod GoogleCloudVideointelligenceV1p3beta1LabelSegment 5845 var s1 struct { 5846 Confidence gensupport.JSONFloat64 `json:"confidence"` 5847 *NoMethod 5848 } 5849 s1.NoMethod = (*NoMethod)(s) 5850 if err := json.Unmarshal(data, &s1); err != nil { 5851 return err 5852 } 5853 s.Confidence = float64(s1.Confidence) 5854 return nil 5855 } 5856 5857 // GoogleCloudVideointelligenceV1p3beta1LogoRecognitionAnnotation: Annotation 5858 // corresponding to one detected, tracked and recognized logo class. 5859 type GoogleCloudVideointelligenceV1p3beta1LogoRecognitionAnnotation struct { 5860 // Entity: Entity category information to specify the logo class that all the 5861 // logo tracks within this LogoRecognitionAnnotation are recognized as. 5862 Entity *GoogleCloudVideointelligenceV1p3beta1Entity `json:"entity,omitempty"` 5863 // Segments: All video segments where the recognized logo appears. There might 5864 // be multiple instances of the same logo class appearing in one VideoSegment. 5865 Segments []*GoogleCloudVideointelligenceV1p3beta1VideoSegment `json:"segments,omitempty"` 5866 // Tracks: All logo tracks where the recognized logo appears. Each track 5867 // corresponds to one logo instance appearing in consecutive frames. 5868 Tracks []*GoogleCloudVideointelligenceV1p3beta1Track `json:"tracks,omitempty"` 5869 // ForceSendFields is a list of field names (e.g. "Entity") to unconditionally 5870 // include in API requests. By default, fields with empty or default values are 5871 // omitted from API requests. See 5872 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5873 // details. 5874 ForceSendFields []string `json:"-"` 5875 // NullFields is a list of field names (e.g. "Entity") to include in API 5876 // requests with the JSON null value. By default, fields with empty values are 5877 // omitted from API requests. See 5878 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5879 NullFields []string `json:"-"` 5880 } 5881 5882 func (s *GoogleCloudVideointelligenceV1p3beta1LogoRecognitionAnnotation) MarshalJSON() ([]byte, error) { 5883 type NoMethod GoogleCloudVideointelligenceV1p3beta1LogoRecognitionAnnotation 5884 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5885 } 5886 5887 // GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox: Normalized 5888 // bounding box. The normalized vertex coordinates are relative to the original 5889 // image. Range: [0, 1]. 5890 type GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox struct { 5891 // Bottom: Bottom Y coordinate. 5892 Bottom float64 `json:"bottom,omitempty"` 5893 // Left: Left X coordinate. 5894 Left float64 `json:"left,omitempty"` 5895 // Right: Right X coordinate. 5896 Right float64 `json:"right,omitempty"` 5897 // Top: Top Y coordinate. 5898 Top float64 `json:"top,omitempty"` 5899 // ForceSendFields is a list of field names (e.g. "Bottom") to unconditionally 5900 // include in API requests. By default, fields with empty or default values are 5901 // omitted from API requests. See 5902 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5903 // details. 5904 ForceSendFields []string `json:"-"` 5905 // NullFields is a list of field names (e.g. "Bottom") to include in API 5906 // requests with the JSON null value. By default, fields with empty values are 5907 // omitted from API requests. See 5908 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5909 NullFields []string `json:"-"` 5910 } 5911 5912 func (s *GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox) MarshalJSON() ([]byte, error) { 5913 type NoMethod GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox 5914 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5915 } 5916 5917 func (s *GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox) UnmarshalJSON(data []byte) error { 5918 type NoMethod GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox 5919 var s1 struct { 5920 Bottom gensupport.JSONFloat64 `json:"bottom"` 5921 Left gensupport.JSONFloat64 `json:"left"` 5922 Right gensupport.JSONFloat64 `json:"right"` 5923 Top gensupport.JSONFloat64 `json:"top"` 5924 *NoMethod 5925 } 5926 s1.NoMethod = (*NoMethod)(s) 5927 if err := json.Unmarshal(data, &s1); err != nil { 5928 return err 5929 } 5930 s.Bottom = float64(s1.Bottom) 5931 s.Left = float64(s1.Left) 5932 s.Right = float64(s1.Right) 5933 s.Top = float64(s1.Top) 5934 return nil 5935 } 5936 5937 // GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingPoly: Normalized 5938 // bounding polygon for text (that might not be aligned with axis). Contains 5939 // list of the corner points in clockwise order starting from top-left corner. 5940 // For example, for a rectangular bounding box: When the text is horizontal it 5941 // might look like: 0----1 | | 3----2 When it's clockwise rotated 180 degrees 5942 // around the top-left corner it becomes: 2----3 | | 1----0 and the vertex 5943 // order will still be (0, 1, 2, 3). Note that values can be less than 0, or 5944 // greater than 1 due to trignometric calculations for location of the box. 5945 type GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingPoly struct { 5946 // Vertices: Normalized vertices of the bounding polygon. 5947 Vertices []*GoogleCloudVideointelligenceV1p3beta1NormalizedVertex `json:"vertices,omitempty"` 5948 // ForceSendFields is a list of field names (e.g. "Vertices") to 5949 // unconditionally include in API requests. By default, fields with empty or 5950 // default values are omitted from API requests. See 5951 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5952 // details. 5953 ForceSendFields []string `json:"-"` 5954 // NullFields is a list of field names (e.g. "Vertices") to include in API 5955 // requests with the JSON null value. By default, fields with empty values are 5956 // omitted from API requests. See 5957 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5958 NullFields []string `json:"-"` 5959 } 5960 5961 func (s *GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingPoly) MarshalJSON() ([]byte, error) { 5962 type NoMethod GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingPoly 5963 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5964 } 5965 5966 // GoogleCloudVideointelligenceV1p3beta1NormalizedVertex: A vertex represents a 5967 // 2D point in the image. NOTE: the normalized vertex coordinates are relative 5968 // to the original image and range from 0 to 1. 5969 type GoogleCloudVideointelligenceV1p3beta1NormalizedVertex struct { 5970 // X: X coordinate. 5971 X float64 `json:"x,omitempty"` 5972 // Y: Y coordinate. 5973 Y float64 `json:"y,omitempty"` 5974 // ForceSendFields is a list of field names (e.g. "X") to unconditionally 5975 // include in API requests. By default, fields with empty or default values are 5976 // omitted from API requests. See 5977 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 5978 // details. 5979 ForceSendFields []string `json:"-"` 5980 // NullFields is a list of field names (e.g. "X") to include in API requests 5981 // with the JSON null value. By default, fields with empty values are omitted 5982 // from API requests. See 5983 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 5984 NullFields []string `json:"-"` 5985 } 5986 5987 func (s *GoogleCloudVideointelligenceV1p3beta1NormalizedVertex) MarshalJSON() ([]byte, error) { 5988 type NoMethod GoogleCloudVideointelligenceV1p3beta1NormalizedVertex 5989 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 5990 } 5991 5992 func (s *GoogleCloudVideointelligenceV1p3beta1NormalizedVertex) UnmarshalJSON(data []byte) error { 5993 type NoMethod GoogleCloudVideointelligenceV1p3beta1NormalizedVertex 5994 var s1 struct { 5995 X gensupport.JSONFloat64 `json:"x"` 5996 Y gensupport.JSONFloat64 `json:"y"` 5997 *NoMethod 5998 } 5999 s1.NoMethod = (*NoMethod)(s) 6000 if err := json.Unmarshal(data, &s1); err != nil { 6001 return err 6002 } 6003 s.X = float64(s1.X) 6004 s.Y = float64(s1.Y) 6005 return nil 6006 } 6007 6008 // GoogleCloudVideointelligenceV1p3beta1ObjectTrackingAnnotation: Annotations 6009 // corresponding to one tracked object. 6010 type GoogleCloudVideointelligenceV1p3beta1ObjectTrackingAnnotation struct { 6011 // Confidence: Object category's labeling confidence of this track. 6012 Confidence float64 `json:"confidence,omitempty"` 6013 // Entity: Entity to specify the object category that this track is labeled as. 6014 Entity *GoogleCloudVideointelligenceV1p3beta1Entity `json:"entity,omitempty"` 6015 // Frames: Information corresponding to all frames where this object track 6016 // appears. Non-streaming batch mode: it may be one or multiple 6017 // ObjectTrackingFrame messages in frames. Streaming mode: it can only be one 6018 // ObjectTrackingFrame message in frames. 6019 Frames []*GoogleCloudVideointelligenceV1p3beta1ObjectTrackingFrame `json:"frames,omitempty"` 6020 // Segment: Non-streaming batch mode ONLY. Each object track corresponds to one 6021 // video segment where it appears. 6022 Segment *GoogleCloudVideointelligenceV1p3beta1VideoSegment `json:"segment,omitempty"` 6023 // TrackId: Streaming mode ONLY. In streaming mode, we do not know the end time 6024 // of a tracked object before it is completed. Hence, there is no VideoSegment 6025 // info returned. Instead, we provide a unique identifiable integer track_id so 6026 // that the customers can correlate the results of the ongoing 6027 // ObjectTrackAnnotation of the same track_id over time. 6028 TrackId int64 `json:"trackId,omitempty,string"` 6029 // Version: Feature version. 6030 Version string `json:"version,omitempty"` 6031 // ForceSendFields is a list of field names (e.g. "Confidence") to 6032 // unconditionally include in API requests. By default, fields with empty or 6033 // default values are omitted from API requests. See 6034 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6035 // details. 6036 ForceSendFields []string `json:"-"` 6037 // NullFields is a list of field names (e.g. "Confidence") to include in API 6038 // requests with the JSON null value. By default, fields with empty values are 6039 // omitted from API requests. See 6040 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6041 NullFields []string `json:"-"` 6042 } 6043 6044 func (s *GoogleCloudVideointelligenceV1p3beta1ObjectTrackingAnnotation) MarshalJSON() ([]byte, error) { 6045 type NoMethod GoogleCloudVideointelligenceV1p3beta1ObjectTrackingAnnotation 6046 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6047 } 6048 6049 func (s *GoogleCloudVideointelligenceV1p3beta1ObjectTrackingAnnotation) UnmarshalJSON(data []byte) error { 6050 type NoMethod GoogleCloudVideointelligenceV1p3beta1ObjectTrackingAnnotation 6051 var s1 struct { 6052 Confidence gensupport.JSONFloat64 `json:"confidence"` 6053 *NoMethod 6054 } 6055 s1.NoMethod = (*NoMethod)(s) 6056 if err := json.Unmarshal(data, &s1); err != nil { 6057 return err 6058 } 6059 s.Confidence = float64(s1.Confidence) 6060 return nil 6061 } 6062 6063 // GoogleCloudVideointelligenceV1p3beta1ObjectTrackingFrame: Video frame level 6064 // annotations for object detection and tracking. This field stores per frame 6065 // location, time offset, and confidence. 6066 type GoogleCloudVideointelligenceV1p3beta1ObjectTrackingFrame struct { 6067 // NormalizedBoundingBox: The normalized bounding box location of this object 6068 // track for the frame. 6069 NormalizedBoundingBox *GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox `json:"normalizedBoundingBox,omitempty"` 6070 // TimeOffset: The timestamp of the frame in microseconds. 6071 TimeOffset string `json:"timeOffset,omitempty"` 6072 // ForceSendFields is a list of field names (e.g. "NormalizedBoundingBox") to 6073 // unconditionally include in API requests. By default, fields with empty or 6074 // default values are omitted from API requests. See 6075 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6076 // details. 6077 ForceSendFields []string `json:"-"` 6078 // NullFields is a list of field names (e.g. "NormalizedBoundingBox") to 6079 // include in API requests with the JSON null value. By default, fields with 6080 // empty values are omitted from API requests. See 6081 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6082 NullFields []string `json:"-"` 6083 } 6084 6085 func (s *GoogleCloudVideointelligenceV1p3beta1ObjectTrackingFrame) MarshalJSON() ([]byte, error) { 6086 type NoMethod GoogleCloudVideointelligenceV1p3beta1ObjectTrackingFrame 6087 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6088 } 6089 6090 // GoogleCloudVideointelligenceV1p3beta1PersonDetectionAnnotation: Person 6091 // detection annotation per video. 6092 type GoogleCloudVideointelligenceV1p3beta1PersonDetectionAnnotation struct { 6093 // Tracks: The detected tracks of a person. 6094 Tracks []*GoogleCloudVideointelligenceV1p3beta1Track `json:"tracks,omitempty"` 6095 // Version: Feature version. 6096 Version string `json:"version,omitempty"` 6097 // ForceSendFields is a list of field names (e.g. "Tracks") to unconditionally 6098 // include in API requests. By default, fields with empty or default values are 6099 // omitted from API requests. See 6100 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6101 // details. 6102 ForceSendFields []string `json:"-"` 6103 // NullFields is a list of field names (e.g. "Tracks") to include in API 6104 // requests with the JSON null value. By default, fields with empty values are 6105 // omitted from API requests. See 6106 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6107 NullFields []string `json:"-"` 6108 } 6109 6110 func (s *GoogleCloudVideointelligenceV1p3beta1PersonDetectionAnnotation) MarshalJSON() ([]byte, error) { 6111 type NoMethod GoogleCloudVideointelligenceV1p3beta1PersonDetectionAnnotation 6112 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6113 } 6114 6115 // GoogleCloudVideointelligenceV1p3beta1RecognizedCelebrity: The recognized 6116 // celebrity with confidence score. 6117 type GoogleCloudVideointelligenceV1p3beta1RecognizedCelebrity struct { 6118 // Celebrity: The recognized celebrity. 6119 Celebrity *GoogleCloudVideointelligenceV1p3beta1Celebrity `json:"celebrity,omitempty"` 6120 // Confidence: Recognition confidence. Range [0, 1]. 6121 Confidence float64 `json:"confidence,omitempty"` 6122 // ForceSendFields is a list of field names (e.g. "Celebrity") to 6123 // unconditionally include in API requests. By default, fields with empty or 6124 // default values are omitted from API requests. See 6125 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6126 // details. 6127 ForceSendFields []string `json:"-"` 6128 // NullFields is a list of field names (e.g. "Celebrity") to include in API 6129 // requests with the JSON null value. By default, fields with empty values are 6130 // omitted from API requests. See 6131 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6132 NullFields []string `json:"-"` 6133 } 6134 6135 func (s *GoogleCloudVideointelligenceV1p3beta1RecognizedCelebrity) MarshalJSON() ([]byte, error) { 6136 type NoMethod GoogleCloudVideointelligenceV1p3beta1RecognizedCelebrity 6137 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6138 } 6139 6140 func (s *GoogleCloudVideointelligenceV1p3beta1RecognizedCelebrity) UnmarshalJSON(data []byte) error { 6141 type NoMethod GoogleCloudVideointelligenceV1p3beta1RecognizedCelebrity 6142 var s1 struct { 6143 Confidence gensupport.JSONFloat64 `json:"confidence"` 6144 *NoMethod 6145 } 6146 s1.NoMethod = (*NoMethod)(s) 6147 if err := json.Unmarshal(data, &s1); err != nil { 6148 return err 6149 } 6150 s.Confidence = float64(s1.Confidence) 6151 return nil 6152 } 6153 6154 // GoogleCloudVideointelligenceV1p3beta1SpeechRecognitionAlternative: 6155 // Alternative hypotheses (a.k.a. n-best list). 6156 type GoogleCloudVideointelligenceV1p3beta1SpeechRecognitionAlternative struct { 6157 // Confidence: Output only. The confidence estimate between 0.0 and 1.0. A 6158 // higher number indicates an estimated greater likelihood that the recognized 6159 // words are correct. This field is set only for the top alternative. This 6160 // field is not guaranteed to be accurate and users should not rely on it to be 6161 // always provided. The default of 0.0 is a sentinel value indicating 6162 // `confidence` was not set. 6163 Confidence float64 `json:"confidence,omitempty"` 6164 // Transcript: Transcript text representing the words that the user spoke. 6165 Transcript string `json:"transcript,omitempty"` 6166 // Words: Output only. A list of word-specific information for each recognized 6167 // word. Note: When `enable_speaker_diarization` is set to true, you will see 6168 // all the words from the beginning of the audio. 6169 Words []*GoogleCloudVideointelligenceV1p3beta1WordInfo `json:"words,omitempty"` 6170 // ForceSendFields is a list of field names (e.g. "Confidence") to 6171 // unconditionally include in API requests. By default, fields with empty or 6172 // default values are omitted from API requests. See 6173 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6174 // details. 6175 ForceSendFields []string `json:"-"` 6176 // NullFields is a list of field names (e.g. "Confidence") to include in API 6177 // requests with the JSON null value. By default, fields with empty values are 6178 // omitted from API requests. See 6179 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6180 NullFields []string `json:"-"` 6181 } 6182 6183 func (s *GoogleCloudVideointelligenceV1p3beta1SpeechRecognitionAlternative) MarshalJSON() ([]byte, error) { 6184 type NoMethod GoogleCloudVideointelligenceV1p3beta1SpeechRecognitionAlternative 6185 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6186 } 6187 6188 func (s *GoogleCloudVideointelligenceV1p3beta1SpeechRecognitionAlternative) UnmarshalJSON(data []byte) error { 6189 type NoMethod GoogleCloudVideointelligenceV1p3beta1SpeechRecognitionAlternative 6190 var s1 struct { 6191 Confidence gensupport.JSONFloat64 `json:"confidence"` 6192 *NoMethod 6193 } 6194 s1.NoMethod = (*NoMethod)(s) 6195 if err := json.Unmarshal(data, &s1); err != nil { 6196 return err 6197 } 6198 s.Confidence = float64(s1.Confidence) 6199 return nil 6200 } 6201 6202 // GoogleCloudVideointelligenceV1p3beta1SpeechTranscription: A speech 6203 // recognition result corresponding to a portion of the audio. 6204 type GoogleCloudVideointelligenceV1p3beta1SpeechTranscription struct { 6205 // Alternatives: May contain one or more recognition hypotheses (up to the 6206 // maximum specified in `max_alternatives`). These alternatives are ordered in 6207 // terms of accuracy, with the top (first) alternative being the most probable, 6208 // as ranked by the recognizer. 6209 Alternatives []*GoogleCloudVideointelligenceV1p3beta1SpeechRecognitionAlternative `json:"alternatives,omitempty"` 6210 // LanguageCode: Output only. The BCP-47 6211 // (https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag of the language 6212 // in this result. This language code was detected to have the most likelihood 6213 // of being spoken in the audio. 6214 LanguageCode string `json:"languageCode,omitempty"` 6215 // ForceSendFields is a list of field names (e.g. "Alternatives") to 6216 // unconditionally include in API requests. By default, fields with empty or 6217 // default values are omitted from API requests. See 6218 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6219 // details. 6220 ForceSendFields []string `json:"-"` 6221 // NullFields is a list of field names (e.g. "Alternatives") to include in API 6222 // requests with the JSON null value. By default, fields with empty values are 6223 // omitted from API requests. See 6224 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6225 NullFields []string `json:"-"` 6226 } 6227 6228 func (s *GoogleCloudVideointelligenceV1p3beta1SpeechTranscription) MarshalJSON() ([]byte, error) { 6229 type NoMethod GoogleCloudVideointelligenceV1p3beta1SpeechTranscription 6230 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6231 } 6232 6233 // GoogleCloudVideointelligenceV1p3beta1StreamingAnnotateVideoResponse: 6234 // `StreamingAnnotateVideoResponse` is the only message returned to the client 6235 // by `StreamingAnnotateVideo`. A series of zero or more 6236 // `StreamingAnnotateVideoResponse` messages are streamed back to the client. 6237 type GoogleCloudVideointelligenceV1p3beta1StreamingAnnotateVideoResponse struct { 6238 // AnnotationResults: Streaming annotation results. 6239 AnnotationResults *GoogleCloudVideointelligenceV1p3beta1StreamingVideoAnnotationResults `json:"annotationResults,omitempty"` 6240 // AnnotationResultsUri: Google Cloud Storage URI that stores annotation 6241 // results of one streaming session in JSON format. It is the 6242 // annotation_result_storage_directory from the request followed by 6243 // '/cloud_project_number-session_id'. 6244 AnnotationResultsUri string `json:"annotationResultsUri,omitempty"` 6245 // Error: If set, returns a google.rpc.Status message that specifies the error 6246 // for the operation. 6247 Error *GoogleRpcStatus `json:"error,omitempty"` 6248 // ForceSendFields is a list of field names (e.g. "AnnotationResults") to 6249 // unconditionally include in API requests. By default, fields with empty or 6250 // default values are omitted from API requests. See 6251 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6252 // details. 6253 ForceSendFields []string `json:"-"` 6254 // NullFields is a list of field names (e.g. "AnnotationResults") to include in 6255 // API requests with the JSON null value. By default, fields with empty values 6256 // are omitted from API requests. See 6257 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6258 NullFields []string `json:"-"` 6259 } 6260 6261 func (s *GoogleCloudVideointelligenceV1p3beta1StreamingAnnotateVideoResponse) MarshalJSON() ([]byte, error) { 6262 type NoMethod GoogleCloudVideointelligenceV1p3beta1StreamingAnnotateVideoResponse 6263 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6264 } 6265 6266 // GoogleCloudVideointelligenceV1p3beta1StreamingVideoAnnotationResults: 6267 // Streaming annotation results corresponding to a portion of the video that is 6268 // currently being processed. Only ONE type of annotation will be specified in 6269 // the response. 6270 type GoogleCloudVideointelligenceV1p3beta1StreamingVideoAnnotationResults struct { 6271 // ExplicitAnnotation: Explicit content annotation results. 6272 ExplicitAnnotation *GoogleCloudVideointelligenceV1p3beta1ExplicitContentAnnotation `json:"explicitAnnotation,omitempty"` 6273 // FrameTimestamp: Timestamp of the processed frame in microseconds. 6274 FrameTimestamp string `json:"frameTimestamp,omitempty"` 6275 // LabelAnnotations: Label annotation results. 6276 LabelAnnotations []*GoogleCloudVideointelligenceV1p3beta1LabelAnnotation `json:"labelAnnotations,omitempty"` 6277 // ObjectAnnotations: Object tracking results. 6278 ObjectAnnotations []*GoogleCloudVideointelligenceV1p3beta1ObjectTrackingAnnotation `json:"objectAnnotations,omitempty"` 6279 // ShotAnnotations: Shot annotation results. Each shot is represented as a 6280 // video segment. 6281 ShotAnnotations []*GoogleCloudVideointelligenceV1p3beta1VideoSegment `json:"shotAnnotations,omitempty"` 6282 // ForceSendFields is a list of field names (e.g. "ExplicitAnnotation") to 6283 // unconditionally include in API requests. By default, fields with empty or 6284 // default values are omitted from API requests. See 6285 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6286 // details. 6287 ForceSendFields []string `json:"-"` 6288 // NullFields is a list of field names (e.g. "ExplicitAnnotation") to include 6289 // in API requests with the JSON null value. By default, fields with empty 6290 // values are omitted from API requests. See 6291 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6292 NullFields []string `json:"-"` 6293 } 6294 6295 func (s *GoogleCloudVideointelligenceV1p3beta1StreamingVideoAnnotationResults) MarshalJSON() ([]byte, error) { 6296 type NoMethod GoogleCloudVideointelligenceV1p3beta1StreamingVideoAnnotationResults 6297 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6298 } 6299 6300 // GoogleCloudVideointelligenceV1p3beta1TextAnnotation: Annotations related to 6301 // one detected OCR text snippet. This will contain the corresponding text, 6302 // confidence value, and frame level information for each detection. 6303 type GoogleCloudVideointelligenceV1p3beta1TextAnnotation struct { 6304 // Segments: All video segments where OCR detected text appears. 6305 Segments []*GoogleCloudVideointelligenceV1p3beta1TextSegment `json:"segments,omitempty"` 6306 // Text: The detected text. 6307 Text string `json:"text,omitempty"` 6308 // Version: Feature version. 6309 Version string `json:"version,omitempty"` 6310 // ForceSendFields is a list of field names (e.g. "Segments") to 6311 // unconditionally include in API requests. By default, fields with empty or 6312 // default values are omitted from API requests. See 6313 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6314 // details. 6315 ForceSendFields []string `json:"-"` 6316 // NullFields is a list of field names (e.g. "Segments") to include in API 6317 // requests with the JSON null value. By default, fields with empty values are 6318 // omitted from API requests. See 6319 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6320 NullFields []string `json:"-"` 6321 } 6322 6323 func (s *GoogleCloudVideointelligenceV1p3beta1TextAnnotation) MarshalJSON() ([]byte, error) { 6324 type NoMethod GoogleCloudVideointelligenceV1p3beta1TextAnnotation 6325 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6326 } 6327 6328 // GoogleCloudVideointelligenceV1p3beta1TextFrame: Video frame level annotation 6329 // results for text annotation (OCR). Contains information regarding timestamp 6330 // and bounding box locations for the frames containing detected OCR text 6331 // snippets. 6332 type GoogleCloudVideointelligenceV1p3beta1TextFrame struct { 6333 // RotatedBoundingBox: Bounding polygon of the detected text for this frame. 6334 RotatedBoundingBox *GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingPoly `json:"rotatedBoundingBox,omitempty"` 6335 // TimeOffset: Timestamp of this frame. 6336 TimeOffset string `json:"timeOffset,omitempty"` 6337 // ForceSendFields is a list of field names (e.g. "RotatedBoundingBox") to 6338 // unconditionally include in API requests. By default, fields with empty or 6339 // default values are omitted from API requests. See 6340 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6341 // details. 6342 ForceSendFields []string `json:"-"` 6343 // NullFields is a list of field names (e.g. "RotatedBoundingBox") to include 6344 // in API requests with the JSON null value. By default, fields with empty 6345 // values are omitted from API requests. See 6346 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6347 NullFields []string `json:"-"` 6348 } 6349 6350 func (s *GoogleCloudVideointelligenceV1p3beta1TextFrame) MarshalJSON() ([]byte, error) { 6351 type NoMethod GoogleCloudVideointelligenceV1p3beta1TextFrame 6352 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6353 } 6354 6355 // GoogleCloudVideointelligenceV1p3beta1TextSegment: Video segment level 6356 // annotation results for text detection. 6357 type GoogleCloudVideointelligenceV1p3beta1TextSegment struct { 6358 // Confidence: Confidence for the track of detected text. It is calculated as 6359 // the highest over all frames where OCR detected text appears. 6360 Confidence float64 `json:"confidence,omitempty"` 6361 // Frames: Information related to the frames where OCR detected text appears. 6362 Frames []*GoogleCloudVideointelligenceV1p3beta1TextFrame `json:"frames,omitempty"` 6363 // Segment: Video segment where a text snippet was detected. 6364 Segment *GoogleCloudVideointelligenceV1p3beta1VideoSegment `json:"segment,omitempty"` 6365 // ForceSendFields is a list of field names (e.g. "Confidence") to 6366 // unconditionally include in API requests. By default, fields with empty or 6367 // default values are omitted from API requests. See 6368 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6369 // details. 6370 ForceSendFields []string `json:"-"` 6371 // NullFields is a list of field names (e.g. "Confidence") to include in API 6372 // requests with the JSON null value. By default, fields with empty values are 6373 // omitted from API requests. See 6374 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6375 NullFields []string `json:"-"` 6376 } 6377 6378 func (s *GoogleCloudVideointelligenceV1p3beta1TextSegment) MarshalJSON() ([]byte, error) { 6379 type NoMethod GoogleCloudVideointelligenceV1p3beta1TextSegment 6380 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6381 } 6382 6383 func (s *GoogleCloudVideointelligenceV1p3beta1TextSegment) UnmarshalJSON(data []byte) error { 6384 type NoMethod GoogleCloudVideointelligenceV1p3beta1TextSegment 6385 var s1 struct { 6386 Confidence gensupport.JSONFloat64 `json:"confidence"` 6387 *NoMethod 6388 } 6389 s1.NoMethod = (*NoMethod)(s) 6390 if err := json.Unmarshal(data, &s1); err != nil { 6391 return err 6392 } 6393 s.Confidence = float64(s1.Confidence) 6394 return nil 6395 } 6396 6397 // GoogleCloudVideointelligenceV1p3beta1TimestampedObject: For tracking related 6398 // features. An object at time_offset with attributes, and located with 6399 // normalized_bounding_box. 6400 type GoogleCloudVideointelligenceV1p3beta1TimestampedObject struct { 6401 // Attributes: Optional. The attributes of the object in the bounding box. 6402 Attributes []*GoogleCloudVideointelligenceV1p3beta1DetectedAttribute `json:"attributes,omitempty"` 6403 // Landmarks: Optional. The detected landmarks. 6404 Landmarks []*GoogleCloudVideointelligenceV1p3beta1DetectedLandmark `json:"landmarks,omitempty"` 6405 // NormalizedBoundingBox: Normalized Bounding box in a frame, where the object 6406 // is located. 6407 NormalizedBoundingBox *GoogleCloudVideointelligenceV1p3beta1NormalizedBoundingBox `json:"normalizedBoundingBox,omitempty"` 6408 // TimeOffset: Time-offset, relative to the beginning of the video, 6409 // corresponding to the video frame for this object. 6410 TimeOffset string `json:"timeOffset,omitempty"` 6411 // ForceSendFields is a list of field names (e.g. "Attributes") to 6412 // unconditionally include in API requests. By default, fields with empty or 6413 // default values are omitted from API requests. See 6414 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6415 // details. 6416 ForceSendFields []string `json:"-"` 6417 // NullFields is a list of field names (e.g. "Attributes") to include in API 6418 // requests with the JSON null value. By default, fields with empty values are 6419 // omitted from API requests. See 6420 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6421 NullFields []string `json:"-"` 6422 } 6423 6424 func (s *GoogleCloudVideointelligenceV1p3beta1TimestampedObject) MarshalJSON() ([]byte, error) { 6425 type NoMethod GoogleCloudVideointelligenceV1p3beta1TimestampedObject 6426 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6427 } 6428 6429 // GoogleCloudVideointelligenceV1p3beta1Track: A track of an object instance. 6430 type GoogleCloudVideointelligenceV1p3beta1Track struct { 6431 // Attributes: Optional. Attributes in the track level. 6432 Attributes []*GoogleCloudVideointelligenceV1p3beta1DetectedAttribute `json:"attributes,omitempty"` 6433 // Confidence: Optional. The confidence score of the tracked object. 6434 Confidence float64 `json:"confidence,omitempty"` 6435 // Segment: Video segment of a track. 6436 Segment *GoogleCloudVideointelligenceV1p3beta1VideoSegment `json:"segment,omitempty"` 6437 // TimestampedObjects: The object with timestamp and attributes per frame in 6438 // the track. 6439 TimestampedObjects []*GoogleCloudVideointelligenceV1p3beta1TimestampedObject `json:"timestampedObjects,omitempty"` 6440 // ForceSendFields is a list of field names (e.g. "Attributes") to 6441 // unconditionally include in API requests. By default, fields with empty or 6442 // default values are omitted from API requests. See 6443 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6444 // details. 6445 ForceSendFields []string `json:"-"` 6446 // NullFields is a list of field names (e.g. "Attributes") to include in API 6447 // requests with the JSON null value. By default, fields with empty values are 6448 // omitted from API requests. See 6449 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6450 NullFields []string `json:"-"` 6451 } 6452 6453 func (s *GoogleCloudVideointelligenceV1p3beta1Track) MarshalJSON() ([]byte, error) { 6454 type NoMethod GoogleCloudVideointelligenceV1p3beta1Track 6455 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6456 } 6457 6458 func (s *GoogleCloudVideointelligenceV1p3beta1Track) UnmarshalJSON(data []byte) error { 6459 type NoMethod GoogleCloudVideointelligenceV1p3beta1Track 6460 var s1 struct { 6461 Confidence gensupport.JSONFloat64 `json:"confidence"` 6462 *NoMethod 6463 } 6464 s1.NoMethod = (*NoMethod)(s) 6465 if err := json.Unmarshal(data, &s1); err != nil { 6466 return err 6467 } 6468 s.Confidence = float64(s1.Confidence) 6469 return nil 6470 } 6471 6472 // GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress: Annotation 6473 // progress for a single video. 6474 type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress struct { 6475 // Feature: Specifies which feature is being tracked if the request contains 6476 // more than one feature. 6477 // 6478 // Possible values: 6479 // "FEATURE_UNSPECIFIED" - Unspecified. 6480 // "LABEL_DETECTION" - Label detection. Detect objects, such as dog or 6481 // flower. 6482 // "SHOT_CHANGE_DETECTION" - Shot change detection. 6483 // "EXPLICIT_CONTENT_DETECTION" - Explicit content detection. 6484 // "FACE_DETECTION" - Human face detection. 6485 // "SPEECH_TRANSCRIPTION" - Speech transcription. 6486 // "TEXT_DETECTION" - OCR text detection and tracking. 6487 // "OBJECT_TRACKING" - Object detection and tracking. 6488 // "LOGO_RECOGNITION" - Logo detection, tracking, and recognition. 6489 // "CELEBRITY_RECOGNITION" - Celebrity recognition. 6490 // "PERSON_DETECTION" - Person detection. 6491 Feature string `json:"feature,omitempty"` 6492 // InputUri: Video file location in Cloud Storage 6493 // (https://cloud.google.com/storage/). 6494 InputUri string `json:"inputUri,omitempty"` 6495 // ProgressPercent: Approximate percentage processed thus far. Guaranteed to be 6496 // 100 when fully processed. 6497 ProgressPercent int64 `json:"progressPercent,omitempty"` 6498 // Segment: Specifies which segment is being tracked if the request contains 6499 // more than one segment. 6500 Segment *GoogleCloudVideointelligenceV1p3beta1VideoSegment `json:"segment,omitempty"` 6501 // StartTime: Time when the request was received. 6502 StartTime string `json:"startTime,omitempty"` 6503 // UpdateTime: Time of the most recent update. 6504 UpdateTime string `json:"updateTime,omitempty"` 6505 // ForceSendFields is a list of field names (e.g. "Feature") to unconditionally 6506 // include in API requests. By default, fields with empty or default values are 6507 // omitted from API requests. See 6508 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6509 // details. 6510 ForceSendFields []string `json:"-"` 6511 // NullFields is a list of field names (e.g. "Feature") to include in API 6512 // requests with the JSON null value. By default, fields with empty values are 6513 // omitted from API requests. See 6514 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6515 NullFields []string `json:"-"` 6516 } 6517 6518 func (s *GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress) MarshalJSON() ([]byte, error) { 6519 type NoMethod GoogleCloudVideointelligenceV1p3beta1VideoAnnotationProgress 6520 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6521 } 6522 6523 // GoogleCloudVideointelligenceV1p3beta1VideoAnnotationResults: Annotation 6524 // results for a single video. 6525 type GoogleCloudVideointelligenceV1p3beta1VideoAnnotationResults struct { 6526 // CelebrityRecognitionAnnotations: Celebrity recognition annotations. 6527 CelebrityRecognitionAnnotations *GoogleCloudVideointelligenceV1p3beta1CelebrityRecognitionAnnotation `json:"celebrityRecognitionAnnotations,omitempty"` 6528 // Error: If set, indicates an error. Note that for a single 6529 // `AnnotateVideoRequest` some videos may succeed and some may fail. 6530 Error *GoogleRpcStatus `json:"error,omitempty"` 6531 // ExplicitAnnotation: Explicit content annotation. 6532 ExplicitAnnotation *GoogleCloudVideointelligenceV1p3beta1ExplicitContentAnnotation `json:"explicitAnnotation,omitempty"` 6533 // FaceAnnotations: Deprecated. Please use `face_detection_annotations` 6534 // instead. 6535 FaceAnnotations []*GoogleCloudVideointelligenceV1p3beta1FaceAnnotation `json:"faceAnnotations,omitempty"` 6536 // FaceDetectionAnnotations: Face detection annotations. 6537 FaceDetectionAnnotations []*GoogleCloudVideointelligenceV1p3beta1FaceDetectionAnnotation `json:"faceDetectionAnnotations,omitempty"` 6538 // FrameLabelAnnotations: Label annotations on frame level. There is exactly 6539 // one element for each unique label. 6540 FrameLabelAnnotations []*GoogleCloudVideointelligenceV1p3beta1LabelAnnotation `json:"frameLabelAnnotations,omitempty"` 6541 // InputUri: Video file location in Cloud Storage 6542 // (https://cloud.google.com/storage/). 6543 InputUri string `json:"inputUri,omitempty"` 6544 // LogoRecognitionAnnotations: Annotations for list of logos detected, tracked 6545 // and recognized in video. 6546 LogoRecognitionAnnotations []*GoogleCloudVideointelligenceV1p3beta1LogoRecognitionAnnotation `json:"logoRecognitionAnnotations,omitempty"` 6547 // ObjectAnnotations: Annotations for list of objects detected and tracked in 6548 // video. 6549 ObjectAnnotations []*GoogleCloudVideointelligenceV1p3beta1ObjectTrackingAnnotation `json:"objectAnnotations,omitempty"` 6550 // PersonDetectionAnnotations: Person detection annotations. 6551 PersonDetectionAnnotations []*GoogleCloudVideointelligenceV1p3beta1PersonDetectionAnnotation `json:"personDetectionAnnotations,omitempty"` 6552 // Segment: Video segment on which the annotation is run. 6553 Segment *GoogleCloudVideointelligenceV1p3beta1VideoSegment `json:"segment,omitempty"` 6554 // SegmentLabelAnnotations: Topical label annotations on video level or 6555 // user-specified segment level. There is exactly one element for each unique 6556 // label. 6557 SegmentLabelAnnotations []*GoogleCloudVideointelligenceV1p3beta1LabelAnnotation `json:"segmentLabelAnnotations,omitempty"` 6558 // SegmentPresenceLabelAnnotations: Presence label annotations on video level 6559 // or user-specified segment level. There is exactly one element for each 6560 // unique label. Compared to the existing topical `segment_label_annotations`, 6561 // this field presents more fine-grained, segment-level labels detected in 6562 // video content and is made available only when the client sets 6563 // `LabelDetectionConfig.model` to "builtin/latest" in the request. 6564 SegmentPresenceLabelAnnotations []*GoogleCloudVideointelligenceV1p3beta1LabelAnnotation `json:"segmentPresenceLabelAnnotations,omitempty"` 6565 // ShotAnnotations: Shot annotations. Each shot is represented as a video 6566 // segment. 6567 ShotAnnotations []*GoogleCloudVideointelligenceV1p3beta1VideoSegment `json:"shotAnnotations,omitempty"` 6568 // ShotLabelAnnotations: Topical label annotations on shot level. There is 6569 // exactly one element for each unique label. 6570 ShotLabelAnnotations []*GoogleCloudVideointelligenceV1p3beta1LabelAnnotation `json:"shotLabelAnnotations,omitempty"` 6571 // ShotPresenceLabelAnnotations: Presence label annotations on shot level. 6572 // There is exactly one element for each unique label. Compared to the existing 6573 // topical `shot_label_annotations`, this field presents more fine-grained, 6574 // shot-level labels detected in video content and is made available only when 6575 // the client sets `LabelDetectionConfig.model` to "builtin/latest" in the 6576 // request. 6577 ShotPresenceLabelAnnotations []*GoogleCloudVideointelligenceV1p3beta1LabelAnnotation `json:"shotPresenceLabelAnnotations,omitempty"` 6578 // SpeechTranscriptions: Speech transcription. 6579 SpeechTranscriptions []*GoogleCloudVideointelligenceV1p3beta1SpeechTranscription `json:"speechTranscriptions,omitempty"` 6580 // TextAnnotations: OCR text detection and tracking. Annotations for list of 6581 // detected text snippets. Each will have list of frame information associated 6582 // with it. 6583 TextAnnotations []*GoogleCloudVideointelligenceV1p3beta1TextAnnotation `json:"textAnnotations,omitempty"` 6584 // ForceSendFields is a list of field names (e.g. 6585 // "CelebrityRecognitionAnnotations") to unconditionally include in API 6586 // requests. By default, fields with empty or default values are omitted from 6587 // API requests. See 6588 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6589 // details. 6590 ForceSendFields []string `json:"-"` 6591 // NullFields is a list of field names (e.g. "CelebrityRecognitionAnnotations") 6592 // to include in API requests with the JSON null value. By default, fields with 6593 // empty values are omitted from API requests. See 6594 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6595 NullFields []string `json:"-"` 6596 } 6597 6598 func (s *GoogleCloudVideointelligenceV1p3beta1VideoAnnotationResults) MarshalJSON() ([]byte, error) { 6599 type NoMethod GoogleCloudVideointelligenceV1p3beta1VideoAnnotationResults 6600 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6601 } 6602 6603 // GoogleCloudVideointelligenceV1p3beta1VideoSegment: Video segment. 6604 type GoogleCloudVideointelligenceV1p3beta1VideoSegment struct { 6605 // EndTimeOffset: Time-offset, relative to the beginning of the video, 6606 // corresponding to the end of the segment (inclusive). 6607 EndTimeOffset string `json:"endTimeOffset,omitempty"` 6608 // StartTimeOffset: Time-offset, relative to the beginning of the video, 6609 // corresponding to the start of the segment (inclusive). 6610 StartTimeOffset string `json:"startTimeOffset,omitempty"` 6611 // ForceSendFields is a list of field names (e.g. "EndTimeOffset") to 6612 // unconditionally include in API requests. By default, fields with empty or 6613 // default values are omitted from API requests. See 6614 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6615 // details. 6616 ForceSendFields []string `json:"-"` 6617 // NullFields is a list of field names (e.g. "EndTimeOffset") to include in API 6618 // requests with the JSON null value. By default, fields with empty values are 6619 // omitted from API requests. See 6620 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6621 NullFields []string `json:"-"` 6622 } 6623 6624 func (s *GoogleCloudVideointelligenceV1p3beta1VideoSegment) MarshalJSON() ([]byte, error) { 6625 type NoMethod GoogleCloudVideointelligenceV1p3beta1VideoSegment 6626 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6627 } 6628 6629 // GoogleCloudVideointelligenceV1p3beta1WordInfo: Word-specific information for 6630 // recognized words. Word information is only included in the response when 6631 // certain request parameters are set, such as `enable_word_time_offsets`. 6632 type GoogleCloudVideointelligenceV1p3beta1WordInfo struct { 6633 // Confidence: Output only. The confidence estimate between 0.0 and 1.0. A 6634 // higher number indicates an estimated greater likelihood that the recognized 6635 // words are correct. This field is set only for the top alternative. This 6636 // field is not guaranteed to be accurate and users should not rely on it to be 6637 // always provided. The default of 0.0 is a sentinel value indicating 6638 // `confidence` was not set. 6639 Confidence float64 `json:"confidence,omitempty"` 6640 // EndTime: Time offset relative to the beginning of the audio, and 6641 // corresponding to the end of the spoken word. This field is only set if 6642 // `enable_word_time_offsets=true` and only in the top hypothesis. This is an 6643 // experimental feature and the accuracy of the time offset can vary. 6644 EndTime string `json:"endTime,omitempty"` 6645 // SpeakerTag: Output only. A distinct integer value is assigned for every 6646 // speaker within the audio. This field specifies which one of those speakers 6647 // was detected to have spoken this word. Value ranges from 1 up to 6648 // diarization_speaker_count, and is only set if speaker diarization is 6649 // enabled. 6650 SpeakerTag int64 `json:"speakerTag,omitempty"` 6651 // StartTime: Time offset relative to the beginning of the audio, and 6652 // corresponding to the start of the spoken word. This field is only set if 6653 // `enable_word_time_offsets=true` and only in the top hypothesis. This is an 6654 // experimental feature and the accuracy of the time offset can vary. 6655 StartTime string `json:"startTime,omitempty"` 6656 // Word: The word corresponding to this set of information. 6657 Word string `json:"word,omitempty"` 6658 // ForceSendFields is a list of field names (e.g. "Confidence") to 6659 // unconditionally include in API requests. By default, fields with empty or 6660 // default values are omitted from API requests. See 6661 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6662 // details. 6663 ForceSendFields []string `json:"-"` 6664 // NullFields is a list of field names (e.g. "Confidence") to include in API 6665 // requests with the JSON null value. By default, fields with empty values are 6666 // omitted from API requests. See 6667 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6668 NullFields []string `json:"-"` 6669 } 6670 6671 func (s *GoogleCloudVideointelligenceV1p3beta1WordInfo) MarshalJSON() ([]byte, error) { 6672 type NoMethod GoogleCloudVideointelligenceV1p3beta1WordInfo 6673 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6674 } 6675 6676 func (s *GoogleCloudVideointelligenceV1p3beta1WordInfo) UnmarshalJSON(data []byte) error { 6677 type NoMethod GoogleCloudVideointelligenceV1p3beta1WordInfo 6678 var s1 struct { 6679 Confidence gensupport.JSONFloat64 `json:"confidence"` 6680 *NoMethod 6681 } 6682 s1.NoMethod = (*NoMethod)(s) 6683 if err := json.Unmarshal(data, &s1); err != nil { 6684 return err 6685 } 6686 s.Confidence = float64(s1.Confidence) 6687 return nil 6688 } 6689 6690 // GoogleLongrunningCancelOperationRequest: The request message for 6691 // Operations.CancelOperation. 6692 type GoogleLongrunningCancelOperationRequest struct { 6693 } 6694 6695 // GoogleLongrunningListOperationsResponse: The response message for 6696 // Operations.ListOperations. 6697 type GoogleLongrunningListOperationsResponse struct { 6698 // NextPageToken: The standard List next-page token. 6699 NextPageToken string `json:"nextPageToken,omitempty"` 6700 // Operations: A list of operations that matches the specified filter in the 6701 // request. 6702 Operations []*GoogleLongrunningOperation `json:"operations,omitempty"` 6703 6704 // ServerResponse contains the HTTP response code and headers from the server. 6705 googleapi.ServerResponse `json:"-"` 6706 // ForceSendFields is a list of field names (e.g. "NextPageToken") to 6707 // unconditionally include in API requests. By default, fields with empty or 6708 // default values are omitted from API requests. See 6709 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6710 // details. 6711 ForceSendFields []string `json:"-"` 6712 // NullFields is a list of field names (e.g. "NextPageToken") to include in API 6713 // requests with the JSON null value. By default, fields with empty values are 6714 // omitted from API requests. See 6715 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6716 NullFields []string `json:"-"` 6717 } 6718 6719 func (s *GoogleLongrunningListOperationsResponse) MarshalJSON() ([]byte, error) { 6720 type NoMethod GoogleLongrunningListOperationsResponse 6721 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6722 } 6723 6724 // GoogleLongrunningOperation: This resource represents a long-running 6725 // operation that is the result of a network API call. 6726 type GoogleLongrunningOperation struct { 6727 // Done: If the value is `false`, it means the operation is still in progress. 6728 // If `true`, the operation is completed, and either `error` or `response` is 6729 // available. 6730 Done bool `json:"done,omitempty"` 6731 // Error: The error result of the operation in case of failure or cancellation. 6732 Error *GoogleRpcStatus `json:"error,omitempty"` 6733 // Metadata: Service-specific metadata associated with the operation. It 6734 // typically contains progress information and common metadata such as create 6735 // time. Some services might not provide such metadata. Any method that returns 6736 // a long-running operation should document the metadata type, if any. 6737 Metadata googleapi.RawMessage `json:"metadata,omitempty"` 6738 // Name: The server-assigned name, which is only unique within the same service 6739 // that originally returns it. If you use the default HTTP mapping, the `name` 6740 // should be a resource name ending with `operations/{unique_id}`. 6741 Name string `json:"name,omitempty"` 6742 // Response: The normal, successful response of the operation. If the original 6743 // method returns no data on success, such as `Delete`, the response is 6744 // `google.protobuf.Empty`. If the original method is standard 6745 // `Get`/`Create`/`Update`, the response should be the resource. For other 6746 // methods, the response should have the type `XxxResponse`, where `Xxx` is the 6747 // original method name. For example, if the original method name is 6748 // `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. 6749 Response googleapi.RawMessage `json:"response,omitempty"` 6750 6751 // ServerResponse contains the HTTP response code and headers from the server. 6752 googleapi.ServerResponse `json:"-"` 6753 // ForceSendFields is a list of field names (e.g. "Done") to unconditionally 6754 // include in API requests. By default, fields with empty or default values are 6755 // omitted from API requests. See 6756 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6757 // details. 6758 ForceSendFields []string `json:"-"` 6759 // NullFields is a list of field names (e.g. "Done") to include in API requests 6760 // with the JSON null value. By default, fields with empty values are omitted 6761 // from API requests. See 6762 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6763 NullFields []string `json:"-"` 6764 } 6765 6766 func (s *GoogleLongrunningOperation) MarshalJSON() ([]byte, error) { 6767 type NoMethod GoogleLongrunningOperation 6768 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6769 } 6770 6771 // GoogleProtobufEmpty: A generic empty message that you can re-use to avoid 6772 // defining duplicated empty messages in your APIs. A typical example is to use 6773 // it as the request or the response type of an API method. For instance: 6774 // service Foo { rpc Bar(google.protobuf.Empty) returns 6775 // (google.protobuf.Empty); } 6776 type GoogleProtobufEmpty struct { 6777 // ServerResponse contains the HTTP response code and headers from the server. 6778 googleapi.ServerResponse `json:"-"` 6779 } 6780 6781 // GoogleRpcStatus: The `Status` type defines a logical error model that is 6782 // suitable for different programming environments, including REST APIs and RPC 6783 // APIs. It is used by gRPC (https://github.com/grpc). Each `Status` message 6784 // contains three pieces of data: error code, error message, and error details. 6785 // You can find out more about this error model and how to work with it in the 6786 // API Design Guide (https://cloud.google.com/apis/design/errors). 6787 type GoogleRpcStatus struct { 6788 // Code: The status code, which should be an enum value of google.rpc.Code. 6789 Code int64 `json:"code,omitempty"` 6790 // Details: A list of messages that carry the error details. There is a common 6791 // set of message types for APIs to use. 6792 Details []googleapi.RawMessage `json:"details,omitempty"` 6793 // Message: A developer-facing error message, which should be in English. Any 6794 // user-facing error message should be localized and sent in the 6795 // google.rpc.Status.details field, or localized by the client. 6796 Message string `json:"message,omitempty"` 6797 // ForceSendFields is a list of field names (e.g. "Code") to unconditionally 6798 // include in API requests. By default, fields with empty or default values are 6799 // omitted from API requests. See 6800 // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more 6801 // details. 6802 ForceSendFields []string `json:"-"` 6803 // NullFields is a list of field names (e.g. "Code") to include in API requests 6804 // with the JSON null value. By default, fields with empty values are omitted 6805 // from API requests. See 6806 // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. 6807 NullFields []string `json:"-"` 6808 } 6809 6810 func (s *GoogleRpcStatus) MarshalJSON() ([]byte, error) { 6811 type NoMethod GoogleRpcStatus 6812 return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) 6813 } 6814 6815 type OperationsProjectsLocationsOperationsCancelCall struct { 6816 s *Service 6817 name string 6818 urlParams_ gensupport.URLParams 6819 ctx_ context.Context 6820 header_ http.Header 6821 } 6822 6823 // Cancel: Starts asynchronous cancellation on a long-running operation. The 6824 // server makes a best effort to cancel the operation, but success is not 6825 // guaranteed. If the server doesn't support this method, it returns 6826 // `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or 6827 // other methods to check whether the cancellation succeeded or whether the 6828 // operation completed despite cancellation. On successful cancellation, the 6829 // operation is not deleted; instead, it becomes an operation with an 6830 // Operation.error value with a google.rpc.Status.code of 1, corresponding to 6831 // `Code.CANCELLED`. 6832 // 6833 // - name: The name of the operation resource to be cancelled. 6834 func (r *OperationsProjectsLocationsOperationsService) Cancel(name string) *OperationsProjectsLocationsOperationsCancelCall { 6835 c := &OperationsProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} 6836 c.name = name 6837 return c 6838 } 6839 6840 // Fields allows partial responses to be retrieved. See 6841 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 6842 // details. 6843 func (c *OperationsProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *OperationsProjectsLocationsOperationsCancelCall { 6844 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 6845 return c 6846 } 6847 6848 // Context sets the context to be used in this call's Do method. 6849 func (c *OperationsProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *OperationsProjectsLocationsOperationsCancelCall { 6850 c.ctx_ = ctx 6851 return c 6852 } 6853 6854 // Header returns a http.Header that can be modified by the caller to add 6855 // headers to the request. 6856 func (c *OperationsProjectsLocationsOperationsCancelCall) Header() http.Header { 6857 if c.header_ == nil { 6858 c.header_ = make(http.Header) 6859 } 6860 return c.header_ 6861 } 6862 6863 func (c *OperationsProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) { 6864 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 6865 var body io.Reader = nil 6866 c.urlParams_.Set("alt", alt) 6867 c.urlParams_.Set("prettyPrint", "false") 6868 urls := googleapi.ResolveRelative(c.s.BasePath, "v1/operations/{+name}:cancel") 6869 urls += "?" + c.urlParams_.Encode() 6870 req, err := http.NewRequest("POST", urls, body) 6871 if err != nil { 6872 return nil, err 6873 } 6874 req.Header = reqHeaders 6875 googleapi.Expand(req.URL, map[string]string{ 6876 "name": c.name, 6877 }) 6878 return gensupport.SendRequest(c.ctx_, c.s.client, req) 6879 } 6880 6881 // Do executes the "videointelligence.operations.projects.locations.operations.cancel" call. 6882 // Any non-2xx status code is an error. Response headers are in either 6883 // *GoogleProtobufEmpty.ServerResponse.Header or (if a response was returned at 6884 // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to 6885 // check whether the returned error was because http.StatusNotModified was 6886 // returned. 6887 func (c *OperationsProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { 6888 gensupport.SetOptions(c.urlParams_, opts...) 6889 res, err := c.doRequest("json") 6890 if res != nil && res.StatusCode == http.StatusNotModified { 6891 if res.Body != nil { 6892 res.Body.Close() 6893 } 6894 return nil, gensupport.WrapError(&googleapi.Error{ 6895 Code: res.StatusCode, 6896 Header: res.Header, 6897 }) 6898 } 6899 if err != nil { 6900 return nil, err 6901 } 6902 defer googleapi.CloseBody(res) 6903 if err := googleapi.CheckResponse(res); err != nil { 6904 return nil, gensupport.WrapError(err) 6905 } 6906 ret := &GoogleProtobufEmpty{ 6907 ServerResponse: googleapi.ServerResponse{ 6908 Header: res.Header, 6909 HTTPStatusCode: res.StatusCode, 6910 }, 6911 } 6912 target := &ret 6913 if err := gensupport.DecodeResponse(target, res); err != nil { 6914 return nil, err 6915 } 6916 return ret, nil 6917 } 6918 6919 type OperationsProjectsLocationsOperationsDeleteCall struct { 6920 s *Service 6921 name string 6922 urlParams_ gensupport.URLParams 6923 ctx_ context.Context 6924 header_ http.Header 6925 } 6926 6927 // Delete: Deletes a long-running operation. This method indicates that the 6928 // client is no longer interested in the operation result. It does not cancel 6929 // the operation. If the server doesn't support this method, it returns 6930 // `google.rpc.Code.UNIMPLEMENTED`. 6931 // 6932 // - name: The name of the operation resource to be deleted. 6933 func (r *OperationsProjectsLocationsOperationsService) Delete(name string) *OperationsProjectsLocationsOperationsDeleteCall { 6934 c := &OperationsProjectsLocationsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} 6935 c.name = name 6936 return c 6937 } 6938 6939 // Fields allows partial responses to be retrieved. See 6940 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 6941 // details. 6942 func (c *OperationsProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *OperationsProjectsLocationsOperationsDeleteCall { 6943 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 6944 return c 6945 } 6946 6947 // Context sets the context to be used in this call's Do method. 6948 func (c *OperationsProjectsLocationsOperationsDeleteCall) Context(ctx context.Context) *OperationsProjectsLocationsOperationsDeleteCall { 6949 c.ctx_ = ctx 6950 return c 6951 } 6952 6953 // Header returns a http.Header that can be modified by the caller to add 6954 // headers to the request. 6955 func (c *OperationsProjectsLocationsOperationsDeleteCall) Header() http.Header { 6956 if c.header_ == nil { 6957 c.header_ = make(http.Header) 6958 } 6959 return c.header_ 6960 } 6961 6962 func (c *OperationsProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) { 6963 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 6964 var body io.Reader = nil 6965 c.urlParams_.Set("alt", alt) 6966 c.urlParams_.Set("prettyPrint", "false") 6967 urls := googleapi.ResolveRelative(c.s.BasePath, "v1/operations/{+name}") 6968 urls += "?" + c.urlParams_.Encode() 6969 req, err := http.NewRequest("DELETE", urls, body) 6970 if err != nil { 6971 return nil, err 6972 } 6973 req.Header = reqHeaders 6974 googleapi.Expand(req.URL, map[string]string{ 6975 "name": c.name, 6976 }) 6977 return gensupport.SendRequest(c.ctx_, c.s.client, req) 6978 } 6979 6980 // Do executes the "videointelligence.operations.projects.locations.operations.delete" call. 6981 // Any non-2xx status code is an error. Response headers are in either 6982 // *GoogleProtobufEmpty.ServerResponse.Header or (if a response was returned at 6983 // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to 6984 // check whether the returned error was because http.StatusNotModified was 6985 // returned. 6986 func (c *OperationsProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { 6987 gensupport.SetOptions(c.urlParams_, opts...) 6988 res, err := c.doRequest("json") 6989 if res != nil && res.StatusCode == http.StatusNotModified { 6990 if res.Body != nil { 6991 res.Body.Close() 6992 } 6993 return nil, gensupport.WrapError(&googleapi.Error{ 6994 Code: res.StatusCode, 6995 Header: res.Header, 6996 }) 6997 } 6998 if err != nil { 6999 return nil, err 7000 } 7001 defer googleapi.CloseBody(res) 7002 if err := googleapi.CheckResponse(res); err != nil { 7003 return nil, gensupport.WrapError(err) 7004 } 7005 ret := &GoogleProtobufEmpty{ 7006 ServerResponse: googleapi.ServerResponse{ 7007 Header: res.Header, 7008 HTTPStatusCode: res.StatusCode, 7009 }, 7010 } 7011 target := &ret 7012 if err := gensupport.DecodeResponse(target, res); err != nil { 7013 return nil, err 7014 } 7015 return ret, nil 7016 } 7017 7018 type OperationsProjectsLocationsOperationsGetCall struct { 7019 s *Service 7020 name string 7021 urlParams_ gensupport.URLParams 7022 ifNoneMatch_ string 7023 ctx_ context.Context 7024 header_ http.Header 7025 } 7026 7027 // Get: Gets the latest state of a long-running operation. Clients can use this 7028 // method to poll the operation result at intervals as recommended by the API 7029 // service. 7030 // 7031 // - name: The name of the operation resource. 7032 func (r *OperationsProjectsLocationsOperationsService) Get(name string) *OperationsProjectsLocationsOperationsGetCall { 7033 c := &OperationsProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} 7034 c.name = name 7035 return c 7036 } 7037 7038 // Fields allows partial responses to be retrieved. See 7039 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 7040 // details. 7041 func (c *OperationsProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *OperationsProjectsLocationsOperationsGetCall { 7042 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 7043 return c 7044 } 7045 7046 // IfNoneMatch sets an optional parameter which makes the operation fail if the 7047 // object's ETag matches the given value. This is useful for getting updates 7048 // only after the object has changed since the last request. 7049 func (c *OperationsProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *OperationsProjectsLocationsOperationsGetCall { 7050 c.ifNoneMatch_ = entityTag 7051 return c 7052 } 7053 7054 // Context sets the context to be used in this call's Do method. 7055 func (c *OperationsProjectsLocationsOperationsGetCall) Context(ctx context.Context) *OperationsProjectsLocationsOperationsGetCall { 7056 c.ctx_ = ctx 7057 return c 7058 } 7059 7060 // Header returns a http.Header that can be modified by the caller to add 7061 // headers to the request. 7062 func (c *OperationsProjectsLocationsOperationsGetCall) Header() http.Header { 7063 if c.header_ == nil { 7064 c.header_ = make(http.Header) 7065 } 7066 return c.header_ 7067 } 7068 7069 func (c *OperationsProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) { 7070 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 7071 if c.ifNoneMatch_ != "" { 7072 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 7073 } 7074 var body io.Reader = nil 7075 c.urlParams_.Set("alt", alt) 7076 c.urlParams_.Set("prettyPrint", "false") 7077 urls := googleapi.ResolveRelative(c.s.BasePath, "v1/operations/{+name}") 7078 urls += "?" + c.urlParams_.Encode() 7079 req, err := http.NewRequest("GET", urls, body) 7080 if err != nil { 7081 return nil, err 7082 } 7083 req.Header = reqHeaders 7084 googleapi.Expand(req.URL, map[string]string{ 7085 "name": c.name, 7086 }) 7087 return gensupport.SendRequest(c.ctx_, c.s.client, req) 7088 } 7089 7090 // Do executes the "videointelligence.operations.projects.locations.operations.get" call. 7091 // Any non-2xx status code is an error. Response headers are in either 7092 // *GoogleLongrunningOperation.ServerResponse.Header or (if a response was 7093 // returned at all) in error.(*googleapi.Error).Header. Use 7094 // googleapi.IsNotModified to check whether the returned error was because 7095 // http.StatusNotModified was returned. 7096 func (c *OperationsProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { 7097 gensupport.SetOptions(c.urlParams_, opts...) 7098 res, err := c.doRequest("json") 7099 if res != nil && res.StatusCode == http.StatusNotModified { 7100 if res.Body != nil { 7101 res.Body.Close() 7102 } 7103 return nil, gensupport.WrapError(&googleapi.Error{ 7104 Code: res.StatusCode, 7105 Header: res.Header, 7106 }) 7107 } 7108 if err != nil { 7109 return nil, err 7110 } 7111 defer googleapi.CloseBody(res) 7112 if err := googleapi.CheckResponse(res); err != nil { 7113 return nil, gensupport.WrapError(err) 7114 } 7115 ret := &GoogleLongrunningOperation{ 7116 ServerResponse: googleapi.ServerResponse{ 7117 Header: res.Header, 7118 HTTPStatusCode: res.StatusCode, 7119 }, 7120 } 7121 target := &ret 7122 if err := gensupport.DecodeResponse(target, res); err != nil { 7123 return nil, err 7124 } 7125 return ret, nil 7126 } 7127 7128 type ProjectsLocationsOperationsCancelCall struct { 7129 s *Service 7130 name string 7131 googlelongrunningCanceloperationrequest *GoogleLongrunningCancelOperationRequest 7132 urlParams_ gensupport.URLParams 7133 ctx_ context.Context 7134 header_ http.Header 7135 } 7136 7137 // Cancel: Starts asynchronous cancellation on a long-running operation. The 7138 // server makes a best effort to cancel the operation, but success is not 7139 // guaranteed. If the server doesn't support this method, it returns 7140 // `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or 7141 // other methods to check whether the cancellation succeeded or whether the 7142 // operation completed despite cancellation. On successful cancellation, the 7143 // operation is not deleted; instead, it becomes an operation with an 7144 // Operation.error value with a google.rpc.Status.code of 1, corresponding to 7145 // `Code.CANCELLED`. 7146 // 7147 // - name: The name of the operation resource to be cancelled. 7148 func (r *ProjectsLocationsOperationsService) Cancel(name string, googlelongrunningCanceloperationrequest *GoogleLongrunningCancelOperationRequest) *ProjectsLocationsOperationsCancelCall { 7149 c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} 7150 c.name = name 7151 c.googlelongrunningCanceloperationrequest = googlelongrunningCanceloperationrequest 7152 return c 7153 } 7154 7155 // Fields allows partial responses to be retrieved. See 7156 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 7157 // details. 7158 func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall { 7159 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 7160 return c 7161 } 7162 7163 // Context sets the context to be used in this call's Do method. 7164 func (c *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall { 7165 c.ctx_ = ctx 7166 return c 7167 } 7168 7169 // Header returns a http.Header that can be modified by the caller to add 7170 // headers to the request. 7171 func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header { 7172 if c.header_ == nil { 7173 c.header_ = make(http.Header) 7174 } 7175 return c.header_ 7176 } 7177 7178 func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) { 7179 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) 7180 var body io.Reader = nil 7181 body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlelongrunningCanceloperationrequest) 7182 if err != nil { 7183 return nil, err 7184 } 7185 c.urlParams_.Set("alt", alt) 7186 c.urlParams_.Set("prettyPrint", "false") 7187 urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:cancel") 7188 urls += "?" + c.urlParams_.Encode() 7189 req, err := http.NewRequest("POST", urls, body) 7190 if err != nil { 7191 return nil, err 7192 } 7193 req.Header = reqHeaders 7194 googleapi.Expand(req.URL, map[string]string{ 7195 "name": c.name, 7196 }) 7197 return gensupport.SendRequest(c.ctx_, c.s.client, req) 7198 } 7199 7200 // Do executes the "videointelligence.projects.locations.operations.cancel" call. 7201 // Any non-2xx status code is an error. Response headers are in either 7202 // *GoogleProtobufEmpty.ServerResponse.Header or (if a response was returned at 7203 // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to 7204 // check whether the returned error was because http.StatusNotModified was 7205 // returned. 7206 func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { 7207 gensupport.SetOptions(c.urlParams_, opts...) 7208 res, err := c.doRequest("json") 7209 if res != nil && res.StatusCode == http.StatusNotModified { 7210 if res.Body != nil { 7211 res.Body.Close() 7212 } 7213 return nil, gensupport.WrapError(&googleapi.Error{ 7214 Code: res.StatusCode, 7215 Header: res.Header, 7216 }) 7217 } 7218 if err != nil { 7219 return nil, err 7220 } 7221 defer googleapi.CloseBody(res) 7222 if err := googleapi.CheckResponse(res); err != nil { 7223 return nil, gensupport.WrapError(err) 7224 } 7225 ret := &GoogleProtobufEmpty{ 7226 ServerResponse: googleapi.ServerResponse{ 7227 Header: res.Header, 7228 HTTPStatusCode: res.StatusCode, 7229 }, 7230 } 7231 target := &ret 7232 if err := gensupport.DecodeResponse(target, res); err != nil { 7233 return nil, err 7234 } 7235 return ret, nil 7236 } 7237 7238 type ProjectsLocationsOperationsDeleteCall struct { 7239 s *Service 7240 name string 7241 urlParams_ gensupport.URLParams 7242 ctx_ context.Context 7243 header_ http.Header 7244 } 7245 7246 // Delete: Deletes a long-running operation. This method indicates that the 7247 // client is no longer interested in the operation result. It does not cancel 7248 // the operation. If the server doesn't support this method, it returns 7249 // `google.rpc.Code.UNIMPLEMENTED`. 7250 // 7251 // - name: The name of the operation resource to be deleted. 7252 func (r *ProjectsLocationsOperationsService) Delete(name string) *ProjectsLocationsOperationsDeleteCall { 7253 c := &ProjectsLocationsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} 7254 c.name = name 7255 return c 7256 } 7257 7258 // Fields allows partial responses to be retrieved. See 7259 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 7260 // details. 7261 func (c *ProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsDeleteCall { 7262 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 7263 return c 7264 } 7265 7266 // Context sets the context to be used in this call's Do method. 7267 func (c *ProjectsLocationsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOperationsDeleteCall { 7268 c.ctx_ = ctx 7269 return c 7270 } 7271 7272 // Header returns a http.Header that can be modified by the caller to add 7273 // headers to the request. 7274 func (c *ProjectsLocationsOperationsDeleteCall) Header() http.Header { 7275 if c.header_ == nil { 7276 c.header_ = make(http.Header) 7277 } 7278 return c.header_ 7279 } 7280 7281 func (c *ProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) { 7282 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 7283 var body io.Reader = nil 7284 c.urlParams_.Set("alt", alt) 7285 c.urlParams_.Set("prettyPrint", "false") 7286 urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") 7287 urls += "?" + c.urlParams_.Encode() 7288 req, err := http.NewRequest("DELETE", urls, body) 7289 if err != nil { 7290 return nil, err 7291 } 7292 req.Header = reqHeaders 7293 googleapi.Expand(req.URL, map[string]string{ 7294 "name": c.name, 7295 }) 7296 return gensupport.SendRequest(c.ctx_, c.s.client, req) 7297 } 7298 7299 // Do executes the "videointelligence.projects.locations.operations.delete" call. 7300 // Any non-2xx status code is an error. Response headers are in either 7301 // *GoogleProtobufEmpty.ServerResponse.Header or (if a response was returned at 7302 // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to 7303 // check whether the returned error was because http.StatusNotModified was 7304 // returned. 7305 func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { 7306 gensupport.SetOptions(c.urlParams_, opts...) 7307 res, err := c.doRequest("json") 7308 if res != nil && res.StatusCode == http.StatusNotModified { 7309 if res.Body != nil { 7310 res.Body.Close() 7311 } 7312 return nil, gensupport.WrapError(&googleapi.Error{ 7313 Code: res.StatusCode, 7314 Header: res.Header, 7315 }) 7316 } 7317 if err != nil { 7318 return nil, err 7319 } 7320 defer googleapi.CloseBody(res) 7321 if err := googleapi.CheckResponse(res); err != nil { 7322 return nil, gensupport.WrapError(err) 7323 } 7324 ret := &GoogleProtobufEmpty{ 7325 ServerResponse: googleapi.ServerResponse{ 7326 Header: res.Header, 7327 HTTPStatusCode: res.StatusCode, 7328 }, 7329 } 7330 target := &ret 7331 if err := gensupport.DecodeResponse(target, res); err != nil { 7332 return nil, err 7333 } 7334 return ret, nil 7335 } 7336 7337 type ProjectsLocationsOperationsGetCall struct { 7338 s *Service 7339 name string 7340 urlParams_ gensupport.URLParams 7341 ifNoneMatch_ string 7342 ctx_ context.Context 7343 header_ http.Header 7344 } 7345 7346 // Get: Gets the latest state of a long-running operation. Clients can use this 7347 // method to poll the operation result at intervals as recommended by the API 7348 // service. 7349 // 7350 // - name: The name of the operation resource. 7351 func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall { 7352 c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} 7353 c.name = name 7354 return c 7355 } 7356 7357 // Fields allows partial responses to be retrieved. See 7358 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 7359 // details. 7360 func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall { 7361 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 7362 return c 7363 } 7364 7365 // IfNoneMatch sets an optional parameter which makes the operation fail if the 7366 // object's ETag matches the given value. This is useful for getting updates 7367 // only after the object has changed since the last request. 7368 func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall { 7369 c.ifNoneMatch_ = entityTag 7370 return c 7371 } 7372 7373 // Context sets the context to be used in this call's Do method. 7374 func (c *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall { 7375 c.ctx_ = ctx 7376 return c 7377 } 7378 7379 // Header returns a http.Header that can be modified by the caller to add 7380 // headers to the request. 7381 func (c *ProjectsLocationsOperationsGetCall) Header() http.Header { 7382 if c.header_ == nil { 7383 c.header_ = make(http.Header) 7384 } 7385 return c.header_ 7386 } 7387 7388 func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) { 7389 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 7390 if c.ifNoneMatch_ != "" { 7391 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 7392 } 7393 var body io.Reader = nil 7394 c.urlParams_.Set("alt", alt) 7395 c.urlParams_.Set("prettyPrint", "false") 7396 urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") 7397 urls += "?" + c.urlParams_.Encode() 7398 req, err := http.NewRequest("GET", urls, body) 7399 if err != nil { 7400 return nil, err 7401 } 7402 req.Header = reqHeaders 7403 googleapi.Expand(req.URL, map[string]string{ 7404 "name": c.name, 7405 }) 7406 return gensupport.SendRequest(c.ctx_, c.s.client, req) 7407 } 7408 7409 // Do executes the "videointelligence.projects.locations.operations.get" call. 7410 // Any non-2xx status code is an error. Response headers are in either 7411 // *GoogleLongrunningOperation.ServerResponse.Header or (if a response was 7412 // returned at all) in error.(*googleapi.Error).Header. Use 7413 // googleapi.IsNotModified to check whether the returned error was because 7414 // http.StatusNotModified was returned. 7415 func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { 7416 gensupport.SetOptions(c.urlParams_, opts...) 7417 res, err := c.doRequest("json") 7418 if res != nil && res.StatusCode == http.StatusNotModified { 7419 if res.Body != nil { 7420 res.Body.Close() 7421 } 7422 return nil, gensupport.WrapError(&googleapi.Error{ 7423 Code: res.StatusCode, 7424 Header: res.Header, 7425 }) 7426 } 7427 if err != nil { 7428 return nil, err 7429 } 7430 defer googleapi.CloseBody(res) 7431 if err := googleapi.CheckResponse(res); err != nil { 7432 return nil, gensupport.WrapError(err) 7433 } 7434 ret := &GoogleLongrunningOperation{ 7435 ServerResponse: googleapi.ServerResponse{ 7436 Header: res.Header, 7437 HTTPStatusCode: res.StatusCode, 7438 }, 7439 } 7440 target := &ret 7441 if err := gensupport.DecodeResponse(target, res); err != nil { 7442 return nil, err 7443 } 7444 return ret, nil 7445 } 7446 7447 type ProjectsLocationsOperationsListCall struct { 7448 s *Service 7449 name string 7450 urlParams_ gensupport.URLParams 7451 ifNoneMatch_ string 7452 ctx_ context.Context 7453 header_ http.Header 7454 } 7455 7456 // List: Lists operations that match the specified filter in the request. If 7457 // the server doesn't support this method, it returns `UNIMPLEMENTED`. 7458 // 7459 // - name: The name of the operation's parent resource. 7460 func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall { 7461 c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} 7462 c.name = name 7463 return c 7464 } 7465 7466 // Filter sets the optional parameter "filter": The standard list filter. 7467 func (c *ProjectsLocationsOperationsListCall) Filter(filter string) *ProjectsLocationsOperationsListCall { 7468 c.urlParams_.Set("filter", filter) 7469 return c 7470 } 7471 7472 // PageSize sets the optional parameter "pageSize": The standard list page 7473 // size. 7474 func (c *ProjectsLocationsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsOperationsListCall { 7475 c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) 7476 return c 7477 } 7478 7479 // PageToken sets the optional parameter "pageToken": The standard list page 7480 // token. 7481 func (c *ProjectsLocationsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsOperationsListCall { 7482 c.urlParams_.Set("pageToken", pageToken) 7483 return c 7484 } 7485 7486 // Fields allows partial responses to be retrieved. See 7487 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 7488 // details. 7489 func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall { 7490 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 7491 return c 7492 } 7493 7494 // IfNoneMatch sets an optional parameter which makes the operation fail if the 7495 // object's ETag matches the given value. This is useful for getting updates 7496 // only after the object has changed since the last request. 7497 func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall { 7498 c.ifNoneMatch_ = entityTag 7499 return c 7500 } 7501 7502 // Context sets the context to be used in this call's Do method. 7503 func (c *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall { 7504 c.ctx_ = ctx 7505 return c 7506 } 7507 7508 // Header returns a http.Header that can be modified by the caller to add 7509 // headers to the request. 7510 func (c *ProjectsLocationsOperationsListCall) Header() http.Header { 7511 if c.header_ == nil { 7512 c.header_ = make(http.Header) 7513 } 7514 return c.header_ 7515 } 7516 7517 func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) { 7518 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) 7519 if c.ifNoneMatch_ != "" { 7520 reqHeaders.Set("If-None-Match", c.ifNoneMatch_) 7521 } 7522 var body io.Reader = nil 7523 c.urlParams_.Set("alt", alt) 7524 c.urlParams_.Set("prettyPrint", "false") 7525 urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/operations") 7526 urls += "?" + c.urlParams_.Encode() 7527 req, err := http.NewRequest("GET", urls, body) 7528 if err != nil { 7529 return nil, err 7530 } 7531 req.Header = reqHeaders 7532 googleapi.Expand(req.URL, map[string]string{ 7533 "name": c.name, 7534 }) 7535 return gensupport.SendRequest(c.ctx_, c.s.client, req) 7536 } 7537 7538 // Do executes the "videointelligence.projects.locations.operations.list" call. 7539 // Any non-2xx status code is an error. Response headers are in either 7540 // *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if a 7541 // response was returned at all) in error.(*googleapi.Error).Header. Use 7542 // googleapi.IsNotModified to check whether the returned error was because 7543 // http.StatusNotModified was returned. 7544 func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { 7545 gensupport.SetOptions(c.urlParams_, opts...) 7546 res, err := c.doRequest("json") 7547 if res != nil && res.StatusCode == http.StatusNotModified { 7548 if res.Body != nil { 7549 res.Body.Close() 7550 } 7551 return nil, gensupport.WrapError(&googleapi.Error{ 7552 Code: res.StatusCode, 7553 Header: res.Header, 7554 }) 7555 } 7556 if err != nil { 7557 return nil, err 7558 } 7559 defer googleapi.CloseBody(res) 7560 if err := googleapi.CheckResponse(res); err != nil { 7561 return nil, gensupport.WrapError(err) 7562 } 7563 ret := &GoogleLongrunningListOperationsResponse{ 7564 ServerResponse: googleapi.ServerResponse{ 7565 Header: res.Header, 7566 HTTPStatusCode: res.StatusCode, 7567 }, 7568 } 7569 target := &ret 7570 if err := gensupport.DecodeResponse(target, res); err != nil { 7571 return nil, err 7572 } 7573 return ret, nil 7574 } 7575 7576 // Pages invokes f for each page of results. 7577 // A non-nil error returned from f will halt the iteration. 7578 // The provided context supersedes any context provided to the Context method. 7579 func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { 7580 c.ctx_ = ctx 7581 defer c.PageToken(c.urlParams_.Get("pageToken")) 7582 for { 7583 x, err := c.Do() 7584 if err != nil { 7585 return err 7586 } 7587 if err := f(x); err != nil { 7588 return err 7589 } 7590 if x.NextPageToken == "" { 7591 return nil 7592 } 7593 c.PageToken(x.NextPageToken) 7594 } 7595 } 7596 7597 type VideosAnnotateCall struct { 7598 s *Service 7599 googlecloudvideointelligencev1Annotatevideorequest *GoogleCloudVideointelligenceV1AnnotateVideoRequest 7600 urlParams_ gensupport.URLParams 7601 ctx_ context.Context 7602 header_ http.Header 7603 } 7604 7605 // Annotate: Performs asynchronous video annotation. Progress and results can 7606 // be retrieved through the `google.longrunning.Operations` interface. 7607 // `Operation.metadata` contains `AnnotateVideoProgress` (progress). 7608 // `Operation.response` contains `AnnotateVideoResponse` (results). 7609 func (r *VideosService) Annotate(googlecloudvideointelligencev1Annotatevideorequest *GoogleCloudVideointelligenceV1AnnotateVideoRequest) *VideosAnnotateCall { 7610 c := &VideosAnnotateCall{s: r.s, urlParams_: make(gensupport.URLParams)} 7611 c.googlecloudvideointelligencev1Annotatevideorequest = googlecloudvideointelligencev1Annotatevideorequest 7612 return c 7613 } 7614 7615 // Fields allows partial responses to be retrieved. See 7616 // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more 7617 // details. 7618 func (c *VideosAnnotateCall) Fields(s ...googleapi.Field) *VideosAnnotateCall { 7619 c.urlParams_.Set("fields", googleapi.CombineFields(s)) 7620 return c 7621 } 7622 7623 // Context sets the context to be used in this call's Do method. 7624 func (c *VideosAnnotateCall) Context(ctx context.Context) *VideosAnnotateCall { 7625 c.ctx_ = ctx 7626 return c 7627 } 7628 7629 // Header returns a http.Header that can be modified by the caller to add 7630 // headers to the request. 7631 func (c *VideosAnnotateCall) Header() http.Header { 7632 if c.header_ == nil { 7633 c.header_ = make(http.Header) 7634 } 7635 return c.header_ 7636 } 7637 7638 func (c *VideosAnnotateCall) doRequest(alt string) (*http.Response, error) { 7639 reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) 7640 var body io.Reader = nil 7641 body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudvideointelligencev1Annotatevideorequest) 7642 if err != nil { 7643 return nil, err 7644 } 7645 c.urlParams_.Set("alt", alt) 7646 c.urlParams_.Set("prettyPrint", "false") 7647 urls := googleapi.ResolveRelative(c.s.BasePath, "v1/videos:annotate") 7648 urls += "?" + c.urlParams_.Encode() 7649 req, err := http.NewRequest("POST", urls, body) 7650 if err != nil { 7651 return nil, err 7652 } 7653 req.Header = reqHeaders 7654 return gensupport.SendRequest(c.ctx_, c.s.client, req) 7655 } 7656 7657 // Do executes the "videointelligence.videos.annotate" call. 7658 // Any non-2xx status code is an error. Response headers are in either 7659 // *GoogleLongrunningOperation.ServerResponse.Header or (if a response was 7660 // returned at all) in error.(*googleapi.Error).Header. Use 7661 // googleapi.IsNotModified to check whether the returned error was because 7662 // http.StatusNotModified was returned. 7663 func (c *VideosAnnotateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { 7664 gensupport.SetOptions(c.urlParams_, opts...) 7665 res, err := c.doRequest("json") 7666 if res != nil && res.StatusCode == http.StatusNotModified { 7667 if res.Body != nil { 7668 res.Body.Close() 7669 } 7670 return nil, gensupport.WrapError(&googleapi.Error{ 7671 Code: res.StatusCode, 7672 Header: res.Header, 7673 }) 7674 } 7675 if err != nil { 7676 return nil, err 7677 } 7678 defer googleapi.CloseBody(res) 7679 if err := googleapi.CheckResponse(res); err != nil { 7680 return nil, gensupport.WrapError(err) 7681 } 7682 ret := &GoogleLongrunningOperation{ 7683 ServerResponse: googleapi.ServerResponse{ 7684 Header: res.Header, 7685 HTTPStatusCode: res.StatusCode, 7686 }, 7687 } 7688 target := &ret 7689 if err := gensupport.DecodeResponse(target, res); err != nil { 7690 return nil, err 7691 } 7692 return ret, nil 7693 } 7694