Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/355.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 拉动';外部图像ID';运行“按图像搜索面”时的数据_Python_Amazon Web Services - Fatal编程技术网

Python 拉动';外部图像ID';运行“按图像搜索面”时的数据

Python 拉动';外部图像ID';运行“按图像搜索面”时的数据,python,amazon-web-services,Python,Amazon Web Services,我是AWS的新手,在过去的一周里,我一直在关注网站上所有有用的文档 我目前无法从一个“逐图像搜索”后的Reko集合中提取外部图像Id数据,我只需要能够将该数据放入一个变量或打印它,有人知道我如何做到这一点吗 基本上,这是我的代码: import boto3 如果name==“main”: 最后,我收到: Matching faces FaceId:8081ad90-b3bf-47e0-9745-dfb5a530a1a7 Similarity: 96.12% Process finished

我是AWS的新手,在过去的一周里,我一直在关注网站上所有有用的文档

我目前无法从一个“逐图像搜索”后的Reko集合中提取外部图像Id数据,我只需要能够将该数据放入一个变量或打印它,有人知道我如何做到这一点吗

基本上,这是我的代码:

import boto3
如果name==“main”:

最后,我收到:

Matching faces
FaceId:8081ad90-b3bf-47e0-9745-dfb5a530a1a7
Similarity: 96.12%

Process finished with exit code 0
我需要的是外部图像Id而不是FaceId


谢谢

指示响应中的每个
FaceMatches
成员都有一个带有
ExternalImageId
Face
。结构似乎很简单,所以我们需要对这个问题进行一些澄清——请显示您的代码,以及运行该代码的意外结果。更新了OP,再次感谢!解决方案不是简单的
print('externalmageid:'+match['Face']['externalmageid'])
内部的
for match
循环吗?是的,原来('anystringhere:'+match['Face']['externalmageid'])就是这样做的方法!非常感谢!
Matching faces
FaceId:8081ad90-b3bf-47e0-9745-dfb5a530a1a7
Similarity: 96.12%

Process finished with exit code 0