ShowAPI,互联网API入口
立即注册

人脸识别 官方自营 全部收费

 

通过上传的照片,实现人物脸部的识别,通过分析后可以得到脸部的特征信息。根据特征,可以对人物进行识别,比较,分类。

浏览量: 134518

调用量: 17634

使用人数: 2880

¥ 0.01 元起

接入点说明:
相关文档:
接口地址: http://route.showapi.com/61-16 (注意:接口支持https,更安全,但稍慢一些,你懂的。请根据自己的情况进行选择。)
返回格式: json
请求方式: HTTP协议,支持GET/POST方法。
调用样式及调试工具: 测试工具

查看加密签名方式 请求参数/ Request parameter

非文件上传的POST时,enctype=application/x-www-form-urlencoded。
文件上传的POST时,enctype=multipart/form-data。

1、系统级参数(所有接入点都需要的参数):展开收起
参数名称 类型 示例值 必须 描述
showapi_appid String 100 易源应用id
showapi_sign String 698d51a19d8a121ce581499d7b701668 为了验证用户身份,以及确保参数不被中间人篡改,需要传递调用者的数字签名。
showapi_timestamp String 20141114142239 客户端时间。
格式yyyyMMddHHmmss,如20141114142239
为了在一定程度上防止“重放攻击”,平台只接受在10分钟之内的请求。如果不传或传空串,则系统不再做此字段的检测。
showapi_res_gzip String 1或0 返回值是否用gzip方式压缩。此值为1时将压缩,其他值不压缩。
...
2、应用级参数(每个接入点有自己的参数):
参数名称 类型 默认值 示例值 必须 描述
imgData String
/9j/4AAQSkZJRgABAQAAAQABAAD/2wBDAAYEB......2lSRWJOVnWktJWrO0bFQbCMxLEs1DOYfMS2gw20RnGbxf/Z
图片的base64信息

返回参数/ Return parameter

以JSON格式返回结果。

1、系统级参数(所有接入点都会返回的参数): 展开收起
名称 类型 示例值 描述
showapi_res_body String {"city":"昆明","prov":"云南"} 消息体的JSON封装,所有应用级的返回参数将嵌入此对象 。
showapi_res_code int 0
易源返回标志,0为成功,其他为失败。
0成功
-1,系统调用错误
-2,可调用次数或金额为0
-3,读取超时
-4,服务端返回数据解析错误
-5,后端服务器DNS解析错误
-6,服务不存在或未上线
-1000,系统维护
-1002,showapi_appid字段必传
-1003,showapi_sign字段必传
-1004,签名sign验证有误
-1005,showapi_timestamp无效
-1006,app无权限调用接口
-1007,没有订购套餐
-1008,服务商关闭对您的调用权限
-1009,调用频率受限
-1010,找不到您的应用
-1011,子授权app_child_id无效
-1012,子授权已过期或失效
-1013,子授权ip受限
showapi_res_error String 用户输入有误! 错误信息的展示
...
2、应用级参数(系统级输出参数showapi_res_body字段中的json数据结构): 展开收起
名称 类型 示例值 描述
--- String
返回信息同接入点:"人脸识别",是一致的
ret_code String
0
调用是否成功,0为请求成功并扣费,其他值表示失败
...

返回示例/ Return example

{
	"faces":[
		{
			"landmark":{
				"nose_contour_left1":{
					"y":1933,
					"x":1263
				},
				"nose_contour_left2":{
					"y":1961,
					"x":1263
				},
				"left_eyebrow_lower_middle":{
					"y":1917,
					"x":1221
				},
				"nose_contour_left3":{
					"y":1978,
					"x":1272
				},
				"mouth_upper_lip_left_contour1":{
					"y":2006,
					"x":1267
				},
				"mouth_upper_lip_left_contour2":{
					"y":2015,
					"x":1256
				},
				"left_eye_top":{
					"y":1935,
					"x":1226
				},
				"right_eye_upper_left_quarter":{
					"y":1917,
					"x":1304
				},
				"right_eye_bottom":{
					"y":1924,
					"x":1316
				},
				"nose_contour_lower_middle":{
					"y":1979,
					"x":1285
				},
				"right_eyebrow_lower_right_quarter":{
					"y":1894,
					"x":1326
				},
				"mouth_upper_lip_left_contour3":{
					"y":2019,
					"x":1263
				},
				"left_eyebrow_upper_left_quarter":{
					"y":1910,
					"x":1204
				},
				"left_eyebrow_lower_right_quarter":{
					"y":1916,
					"x":1236
				},
				"left_eye_upper_left_quarter":{
					"y":1938,
					"x":1216
				},
				"nose_contour_right1":{
					"y":1929,
					"x":1287
				},
				"left_eye_upper_right_quarter":{
					"y":1935,
					"x":1235
				},
				"nose_contour_right2":{
					"y":1956,
					"x":1297
				},
				"nose_contour_right3":{
					"y":1974,
					"x":1296
				},
				"mouth_upper_lip_right_contour1":{
					"y":2001,
					"x":1284
				},
				"mouth_upper_lip_right_contour2":{
					"y":2002,
					"x":1302
				},
				"mouth_upper_lip_right_contour3":{
					"y":2009,
					"x":1298
				},
				"left_eyebrow_left_corner":{
					"y":1921,
					"x":1192
				},
				"left_eye_lower_right_quarter":{
					"y":1939,
					"x":1235
				},
				"mouth_lower_lip_right_contour3":{
					"y":2019,
					"x":1296
				},
				"left_eye_center":{
					"y":1938,
					"x":1226
				},
				"nose_left":{
					"y":1976,
					"x":1260
				},
				"mouth_lower_lip_right_contour1":{
					"y":2010,
					"x":1298
				},
				"mouth_lower_lip_right_contour2":{
					"y":2014,
					"x":1308
				},
				"right_eye_lower_right_quarter":{
					"y":1921,
					"x":1324
				},
				"left_eyebrow_right_corner":{
					"y":1913,
					"x":1250
				},
				"nose_right":{
					"y":1968,
					"x":1304
				},
				"right_eye_lower_left_quarter":{
					"y":1925,
					"x":1307
				},
				"left_eye_right_corner":{
					"y":1935,
					"x":1243
				},
				"right_eye_top":{
					"y":1913,
					"x":1313
				},
				"right_eyebrow_right_corner":{
					"y":1893,
					"x":1338
				},
				"mouth_upper_lip_top":{
					"y":2005,
					"x":1276
				},
				"contour_left8":{
					"y":2062,
					"x":1253
				},
				"right_eye_right_corner":{
					"y":1916,
					"x":1330
				},
				"contour_left9":{
					"y":2066,
					"x":1276
				},
				"left_eye_bottom":{
					"y":1941,
					"x":1226
				},
				"left_eye_left_corner":{
					"y":1941,
					"x":1207
				},
				"contour_left4":{
					"y":2011,
					"x":1185
				},
				"left_eyebrow_lower_left_quarter":{
					"y":1919,
					"x":1206
				},
				"contour_left5":{
					"y":2029,
					"x":1197
				},
				"contour_left6":{
					"y":2044,
					"x":1213
				},
				"mouth_upper_lip_bottom":{
					"y":2013,
					"x":1279
				},
				"contour_left7":{
					"y":2055,
					"x":1232
				},
				"contour_right6":{
					"y":2006,
					"x":1355
				},
				"contour_left1":{
					"y":1951,
					"x":1163
				},
				"contour_right5":{
					"y":1987,
					"x":1361
				},
				"contour_left2":{
					"y":1972,
					"x":1169
				},
				"contour_right4":{
					"y":1968,
					"x":1363
				},
				"right_eye_upper_right_quarter":{
					"y":1913,
					"x":1322
				},
				"contour_left3":{
					"y":1992,
					"x":1176
				},
				"contour_right3":{
					"y":1948,
					"x":1363
				},
				"mouth_right_corner":{
					"y":2007,
					"x":1319
				},
				"contour_chin":{
					"y":2063,
					"x":1300
				},
				"contour_right2":{
					"y":1929,
					"x":1362
				},
				"contour_right1":{
					"y":1910,
					"x":1359
				},
				"right_eyebrow_lower_middle":{
					"y":1897,
					"x":1315
				},
				"right_eyebrow_upper_middle":{
					"y":1887,
					"x":1312
				},
				"nose_tip":{
					"y":1961,
					"x":1286
				},
				"right_eye_left_corner":{
					"y":1925,
					"x":1299
				},
				"mouth_lower_lip_top":{
					"y":2014,
					"x":1279
				},
				"right_eyebrow_upper_left_quarter":{
					"y":1892,
					"x":1300
				},
				"right_eye_center":{
					"y":1920,
					"x":1314
				},
				"mouth_lower_lip_left_contour2":{
					"y":2028,
					"x":1260
				},
				"left_eye_lower_left_quarter":{
					"y":1942,
					"x":1217
				},
				"left_eyebrow_upper_middle":{
					"y":1906,
					"x":1220
				},
				"left_eye_pupil":{
					"y":1938,
					"x":1226
				},
				"mouth_lower_lip_left_contour3":{
					"y":2027,
					"x":1271
				},
				"mouth_lower_lip_left_contour1":{
					"y":2020,
					"x":1264
				},
				"right_eyebrow_left_corner":{
					"y":1903,
					"x":1290
				},
				"right_eye_pupil":{
					"y":1918,
					"x":1313
				},
				"right_eyebrow_upper_right_quarter":{
					"y":1886,
					"x":1326
				},
				"mouth_left_corner":{
					"y":2027,
					"x":1250
				},
				"left_eyebrow_upper_right_quarter":{
					"y":1906,
					"x":1236
				},
				"contour_right7":{
					"y":2023,
					"x":1347
				},
				"contour_right8":{
					"y":2039,
					"x":1335
				},
				"contour_right9":{
					"y":2053,
					"x":1320
				},
				"mouth_lower_lip_bottom":{
					"y":2024,
					"x":1282
				},
				"right_eyebrow_lower_left_quarter":{
					"y":1900,
					"x":1303
				}
			},
			"face_rectangle":{
				"height":194,
				"width":194,
				"left":1173,
				"top":1878
			},
			"face_token":"5db957821ae8b32e62b19dba0f5a4d6a",
			"attributes":{
				"facequality":{
					"value":61.458,
					"threshold":70.1
				},
				"mouthstatus":{
					"open":0.0,
					"surgical_mask_or_respirator":0.0,
					"other_occlusion":100.0,
					"close":0.0
				},
				"skinstatus":{
					"dark_circle":0.97,
					"health":4.907,
					"acne":5.057,
					"stain":19.488
				},
				"eyegaze":{
					"right_eye_gaze":{
						"vector_z_component":0.955,
						"vector_y_component":0.251,
						"position_x_coordinate":0.454,
						"position_y_coordinate":0.434,
						"vector_x_component":-0.156
					},
					"left_eye_gaze":{
						"vector_z_component":0.9,
						"vector_y_component":0.358,
						"position_x_coordinate":0.613,
						"position_y_coordinate":0.445,
						"vector_x_component":0.248
					}
				},
				"headpose":{
					"yaw_angle":-7.7480254,
					"roll_angle":-5.082445,
					"pitch_angle":17.546328
				},
				"beauty":{
					"female_score":46.961,
					"male_score":48.578
				},
				"blur":{
					"blurness":{
						"value":9.335,
						"threshold":50.0
					},
					"motionblur":{
						"value":9.335,
						"threshold":50.0
					},
					"gaussianblur":{
						"value":9.335,
						"threshold":50.0
					}
				},
				"emotion":{
					"disgust":0.198,
					"sadness":0.271,
					"anger":0.05,
					"happiness":0.131,
					"neutral":98.772,
					"surprise":0.219,
					"fear":0.359
				},
				"age":{
					"value":8
				},
				"glass":{
					"value":"None"
				},
				"gender":{
					"value":"Female"
				},
				"smile":{
					"value":6.409,
					"threshold":30.1
				},
				"eyestatus":{
					"left_eye_status":{
						"normal_glass_eye_open":0.041,
						"no_glass_eye_close":5.321,
						"occlusion":0.005,
						"dark_glasses":0.0,
						"normal_glass_eye_close":0.0,
						"no_glass_eye_open":94.633
					},
					"right_eye_status":{
						"normal_glass_eye_open":0.471,
						"no_glass_eye_close":0.529,
						"occlusion":0.092,
						"dark_glasses":0.006,
						"normal_glass_eye_close":0.011,
						"no_glass_eye_open":98.891
					}
				},
				"ethnicity":{
					"value":"White"
				}
			}
		},
		...//此处省略
		,
		//超过5个人时,将不返回详细的信息,具体返回的数据结构如下:
		{
			"face_rectangle":{
				"height":141,
				"width":141,
				"left":1328,
				"top":1224
			},
			"face_token":"7740011dad3bc56ad6bb90917584d12f"
		}
	],
	"request_id":"1523511971,81c31a5f-b2df-4dc8-9713-de2fb12ad129",
	"time_used":4216,
	"image_id":"T+y1IVzgePuNNRmzJkZ+jA==",
	"flag":true,
	"ret_code":0
}