视频智能:呼叫方没有权限

2024-03-28 15:15:09 发布

您现在位置:Python中文网/ 问答频道 /正文

在JupyterLab上使用以下代码以运行Google视频智能包:

from google.cloud import videointelligence
import os

client = videointelligence.VideoIntelligenceServiceClient.from_service_account_json("VidIntelligence.json")
job = client.annotate_video(
input_uri='gs://vidintelligencebucket/The Simpsons - Monopoly Night.mp4',
features=['LABEL_DETECTION', 'SHOT_CHANGE_DETECTION'])
result = job.result()

运行时,会出现以下错误:

PermissionDenied: 403 The caller does not have permission

有什么建议吗


Tags: the代码fromimportclientjson视频智能