文档中心 > API类目 > 天眼工作室API

alibaba.security.deepvision.onen.cloths.imagecompare (服装管理,服装照片比对)

服装管理,服装照片比对

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
param DpClothsManageRecognizeParam 必须 参数param
  • └ token
  • String
  • 必须
  • 137 CC4D408D18C69B548D196E1EE18EDE04F401862377BF5E03755F5F020002BAF9378BE89858C6F4D777839A3023F3F288ACF29EA6A14867B06455D8C3D2E74
  • token
  • └ request_id
  • String
  • 可选
  • 214324
  • 用于跟踪请求,便于开发调试和问题定位,建议用uuid保证唯一
  • └ tenant_code
  • String
  • 必须
  • 8888
  • 租户编码
  • └ type_id
  • Number
  • 可选
  • 220
  • 底库ID
  • └ type
  • String
  • 必须
  • type
  • 类型
  • └ pic_url
  • String
  • 必须
  • https://image.baidu.com/search/down?tn=download&word=download&ie=utf8&fr=detail&url=https%3A%2F%2Fimg.tukuppt.com%2Fphoto-big%2F00%2F00%2F94%2F6152bc0ce6e5d805.jpg&thumburl=https%3A%2F%2Fimg2.baidu.com%2Fit%2Fu%3D174991003%2C1991123578%26fm%3D253%26fmt%3Dauto%26app%3D120%26f%3DJPEG%3Fw%3D780%26h%3D1170
  • 图片url
  • └ scene_code
  • String
  • 必须
  • staff
  • 场景编码

响应参数

名称 类型 示例值 描述
result DpClothsRecognizeVo 服装照片比对集合
  • └ tenant_code
  • String
  • 8888
  • 租户ID
  • └ scene_code
  • String
  • 132
  • 场景ID
  • └ type
  • String
  • type
  • 类型
  • └ name
  • String
  • name
  • 类型名称
  • └ version
  • Number
  • 1
  • 版本号
  • └ algo_version
  • String
  • 1
  • 算法版本
  • └ similar
  • String
  • 1
  • 相似度
  • └ type_id
  • String
  • 123
  • 底库ID
resp_code Number 1 返回码
resp_success Boolean true 是否成功
resp_request_id String 123123 请求唯一ID
message String 成功 返回描述

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AlibabaSecurityDeepvisionOnenClothsImagecompareRequest req = new AlibabaSecurityDeepvisionOnenClothsImagecompareRequest();
AlibabaSecurityDeepvisionOnenClothsImagecompareRequest.DpClothsManageRecognizeParam obj1 = new AlibabaSecurityDeepvisionOnenClothsImagecompareRequest.DpClothsManageRecognizeParam();
obj1.setToken("137 CC4D408D18C69B548D196E1EE18EDE04F401862377BF5E03755F5F020002BAF9378BE89858C6F4D777839A3023F3F288ACF29EA6A14867B06455D8C3D2E74");
obj1.setRequestId("214324");
obj1.setTenantCode("8888");
obj1.setTypeId(220L);
obj1.setType("type");
obj1.setPicUrl("https://image.baidu.com/search/down?tn=download&word=download&ie=utf8&fr=detail&url=https%3A%2F%2Fimg.tukuppt.com%2Fphoto-big%2F00%2F00%2F94%2F6152bc0ce6e5d805.jpg&thumburl=https%3A%2F%2Fimg2.baidu.com%2Fit%2Fu%3D174991003%2C1991123578%26fm%3D253%26fmt%3Dauto%26app%3D120%26f%3DJPEG%3Fw%3D780%26h%3D1170");
obj1.setSceneCode("staff");
req.setParam(obj1);
AlibabaSecurityDeepvisionOnenClothsImagecompareResponse rsp = client.execute(req);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<alibaba_security_deepvision_onen_cloths_imagecompare_response>
    <result>
        <tenant_code>8888</tenant_code>
        <scene_code>132</scene_code>
        <type>type</type>
        <name>name</name>
        <version>1</version>
        <algo_version>1</algo_version>
        <similar>1</similar>
        <type_id>123</type_id>
    </result>
    <resp_code>1</resp_code>
    <resp_success>true</resp_success>
    <resp_request_id>123123</resp_request_id>
    <message>成功</message>
</alibaba_security_deepvision_onen_cloths_imagecompare_response>

异常示例

  • XML示例
  • JSON示例
<error_response>
    <code>50</code>
    <msg>Remote service error</msg>
    <sub_code>isv.invalid-parameter</sub_code>
    <sub_msg>非法参数</sub_msg>
</error_response>

错误码解释

错误码 错误描述 解决方案

API工具

如何获得此API

FAQ

返回
顶部