Skip to content

Instantly share code, notes, and snippets.

@hasham2
Created February 21, 2024 07:23
Show Gist options
  • Select an option

  • Save hasham2/444112571d82a7f20e73a9a506bb94d4 to your computer and use it in GitHub Desktop.

Select an option

Save hasham2/444112571d82a7f20e73a9a506bb94d4 to your computer and use it in GitHub Desktop.
// Object tracking annotations are returned as a objectAnnotations list.
{
"name": "projects/PROJECT_NUMBER/locations/LOCATION_ID/operations/OPERATION_ID",
"metadata": {
"@type": "type.googleapis.com/google.cloud.videointelligence.v1.AnnotateVideoProgress",
"annotationProgress": [
{
"inputUri": "/cloud-ml-sandbox/video/chicago.mp4",
"progressPercent": 100,
"startTime": "2019-12-21T16:56:46.755199Z",
"updateTime": "2019-12-21T16:59:17.911197Z"
}
]
},
"done": true,
"response": {
"@type": "type.googleapis.com/google.cloud.videointelligence.v1.AnnotateVideoResponse",
"annotationResults": [
{
"inputUri": "/cloud-ml-sandbox/video/chicago.mp4",
"objectAnnotations": [
{
"entity": {
"entityId": "/m/0k4j",
"description": "car",
"languageCode": "en-US"
},
"frames": [
{
"normalizedBoundingBox": {
"left": 0.2672763,
"top": 0.5677657,
"right": 0.4388713,
"bottom": 0.7623171
},
"timeOffset": "0s"
},
{
"normalizedBoundingBox": {
"left": 0.26920167,
"top": 0.5659805,
"right": 0.44331276,
"bottom": 0.76780635
},
"timeOffset": "0.100495s"
},
...
{
"normalizedBoundingBox": {
"left": 0.83573246,
"top": 0.6645812,
"right": 1,
"bottom": 0.99865407
},
"timeOffset": "2.311402s"
}
],
"segment": {
"startTimeOffset": "0s",
"endTimeOffset": "2.311402s"
},
"confidence": 0.99488896
},
...
{
"entity": {
"entityId": "/m/0cgh4",
"description": "building",
"languageCode": "en-US"
},
"frames": [
{
"normalizedBoundingBox": {
"left": 0.12340179,
"top": 0.010383379,
"right": 0.21914443,
"bottom": 0.5591795
},
"timeOffset": "0s"
},
{
"normalizedBoundingBox": {
"left": 0.12340179,
"top": 0.009684974,
"right": 0.22915152,
"bottom": 0.56070584
},
"timeOffset": "0.100495s"
},
...
{
"normalizedBoundingBox": {
"left": 0.12340179,
"top": 0.008624528,
"right": 0.22723165,
"bottom": 0.56158626
},
"timeOffset": "0.401983s"
}
],
"segment": {
"startTimeOffset": "0s",
"endTimeOffset": "0.401983s"
},
"confidence": 0.33914912
},
...
{
"entity": {
"entityId": "/m/0cgh4",
"description": "building",
"languageCode": "en-US"
},
"frames": [
{
"normalizedBoundingBox": {
"left": 0.79324204,
"top": 0.0006896425,
"right": 0.99659824,
"bottom": 0.5324423
},
"timeOffset": "37.585421s"
},
{
"normalizedBoundingBox": {
"left": 0.78935236,
"top": 0.0011992548,
"right": 0.99659824,
"bottom": 0.5374946
},
"timeOffset": "37.685917s"
},
...
{
"normalizedBoundingBox": {
"left": 0.79404694,
"right": 0.99659824,
"bottom": 0.5280966
},
"timeOffset": "38.590379s"
}
],
"segment": {
"startTimeOffset": "37.585421s",
"endTimeOffset": "38.590379s"
},
"confidence": 0.3415429
}
]
}
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment