为什么我不将Viseme的时间与Python一起使用Amazon Polly?

问题描述

我正在使用boto3与Amazon Polly合作,我尝试通过语音速度来获取视位时间,如AWS documentation

所述

但是它并不能按我的意愿工作。我得到一个200的响应,到目前为止还可以,但是在响应中我看不到任何涉及所需结果的信息,而且坦率地说,我不知道如何将结果保存到示例中的文本文件中通过亚马逊。

这是我的代码

    response = polly_client.synthesize_speech(LanguageCode='en-US',VoiceId='Joanna',OutputFormat='json',Text = 'This is a sample text to be synthesized.',TextType='text',SpeechMarkTypes=['viseme','word','sentence'])
print(response)

这是我的回复

{'ResponseMetadata': {'RequestId': 'ea3eb25f-73d1-45cf-b6e0-dbc4271921ac','HTTPStatusCode': 200,'HTTPHeaders': {'x-amzn-requestid': 'ea3eb25f-73d1-45cf-b6e0-dbc4271921ac','x-amzn-requestcharacters': '40','content-type': 'application/x-json-stream','transfer-encoding': 'chunked','date': 'Sun,08 Nov 2020 11:44:47 GMT'},'RetryAttempts': 0},'ContentType': 'application/x-json-stream','RequestCharacters': '40','AudioStream': <botocore.response.StreamingBody object at 0x1024b4ac0>}

所以我似乎缺少一点,但是通过搜索引擎搜索发现的任何内容都无法解决此问题。我该如何实现?

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)