v3python人脸对比成功
Ta的回复 :# -*- coding: UTF-8 -*- from aip import AipFace # 定义常量 APP_ID = '9851066' API_KEY = 'LUGBatgyRGoerR9FZbV4SQYk' SECRET_KEY = 'fB2MNz1c2UHLTximFlC4laXPg7CVfyjV' # 初始化AipFace对象 aipFace = AipFace(APP_ID, API_KEY, SECRET_KEY) # 读取图片 filePath = "WechatIMG1.jpeg" def get_file_content(filePath): with open(filePath, 'rb') as fp: return fp.read() # 定义参数变量 options = { 'max_face_num': 1, 'face_fields': "age,beauty,expression,faceshape", } # 调用人脸属性检测接口 result = aipFace.detect(get_file_content(filePath),options) print(result) print(type(result)) 楼主请问这段代码运行出错 提示{u'log_id': 1520120155451L, u'timestamp': 1529996449, u'cached': 0, u'result': None, u'error_code': 222001, u'error_msg': u'param[image] is null'} <type 'dict'> 要如何修改呢? 谢谢