我上传了一个视频到谷歌的云存储桶,并在视频智能API中引用了他们的URL。当我试图获取上传视频的视频持续时间时,视频智能API不会返回任何内容。
这是我使用的代码:
require "google/cloud/video_intelligence"
video_intelligence_client = Google::Cloud::VideoIntelligence.new
features_element = :LABEL_DETECTION
features = [features_element]
operation = video_intelligence_client.annotate_video input_uri: input_uri, features: features
p "PROCESSING......"
p operation
raise operation.results.message? if operation.error?
operation.wait_until_done!
metadata = operation.metadata
puts metadata
使用视频智能API可以获得视频持续时间吗?或者,我应该如何从获得它呢?
发布于 2019-08-15 09:56:26
https://stackoverflow.com/questions/56934647
复制相似问题