Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Cloud Vision issue: Incorrect end time for MP4 videos

Hi!
I encountered a weird issue with Cloud Vision.
When processing MP4 videos that were recorded on iPhone (Safari) with 5 fps, the endTimeOffset is incorrectly computed.

For example, processing a 5 seconds MP4 with a frame-rate of 5fps would yield the following start/end time:

 

 "segment": {
        "endTimeOffset": "0.834166s",
        "startTimeOffset": "0s"
      },

 

This is clearly incorrect.
Is this a known issue?
Is there a way to resolve this?

Thanks.

0 3 209
3 REPLIES 3

May I know the documentation that you are currently following?

 

Hi!
Thanks for replying and sorry for the late reply. (the notifications for this forum went to my spam folder for some reason)

Though it was some time ago since I implemented this code section, I believe I relied partly on the following:
https://cloud.google.com/vision/docs/detect-labels-image-client-libraries
https://cloud.google.com/vision/docs/labels
And also on the following reference: 

https://googleapis.github.io/googleapis/java/all/latest/apidocs/com/google/cloud/videointelligence/v1beta2/AnnotateVideoRequest.Builder.html#setInputUri-java.lang.String-

To be honest, it was a bit challenging finding the documentation.

Anyway, I have opened a bug on this issue and it contains some additional info on the exact scenario. Here's the issue:
https://issuetracker.google.com/issues/271896083

If there is some known solution for this issue then I would be happy to know.
Thanks!

Hi,

While we wait for the response of Cloud Vision Engineering Team, please try Video Intelligence API Quickstart. It is more appropriate when detecting labels in videos. This service is free for the first 1000 minutes and $0.10 / minute after exceeding.

Thanks!