内地车牌识别

接口描述

提供中国大陆车牌云端识别功能。

请求说明

接口ID 协议 方法 PATH
17 HTTPS POST /openapi/v1/prs_cn/plates/detect

PATH参数

URL参数

参数 类型 必填 说明
accesskey_id string 参见用户签名认证
expires int 参见用户签名认证
signature string 参见用户签名认证

HTTP请求头

字段
Content-Type application/json

请求参数

请求参数以Json格式放置于Body中,如下:

参数 类型 必填 说明
image_type string 图片类型,固定为BASE64
image string 图片的Base64编码字符串,切记需要去掉前缀data:image/jpeg;base64,并且确保图片大小在2M以内!
rect_list array 图片中车牌区域,比如一张图片里左、中、右三辆车,只希望获得中间位置的车牌,通过传入中间车牌的大致区域即可识别该区域的车牌
+ id string 区域ID,便于在检测结果中进行区分
+ left int 区域的左边距离
+ top int 区域的上边距离
+ width int 区域的宽度
+ height int 区域的高度
max_count int 最大返回的车牌数,默认为1

注意:rect_listmax_count不能同时存在,如果同时存在,则忽略max_count

请求示例

POST https://open.vzicloud.com/openapi/v1/prs_cn/plates/detect?accesskey_id=8d9EsDAD2115Q5PM8tuP6g1IdAglkayp&expires=1619022787&signature=G29eTBjMm0gZF7cpXNLX7Hrn0yM%3D HTTP/1.1
Host: open.vzicloud.com
Content-Length: 586678
Content-Type: application/json

{"image_type":"BASE64","image":"/9j/4AAQSkZJRgABAQAAAQABAAD/2wBDAAMCAgMCAgMDAw...","max_count":10}

返回说明

返回参数

参数 类型 说明
result_list array 车牌列表
+ license string 检测到车牌号
+ plate_score float 车牌置信度,范围0-100
+ plate_type string 车牌类型,比如单层蓝色普通车牌
+ plate_color string 车牌颜色
+ plate_location object 车牌在图片中的位置信息
++ left int 车牌距离图片左边的距离
++ top int 车牌距离图片上边的距离
++ width int 车牌的宽度
++ height int 车牌的高度
+ detect_rect object 如果请求参数存在rect_list,则存在此参数,否则不存在
++ id string 区域ID,便于在检测结果中进行区分
++ left int 区域的左边距离
++ top int 区域的上边距离
++ width int 区域的宽度
++ height int 区域的高度
+ vehicle_type string 车型
+ vehicle_type_score float 车型置信度,范围0-100
+ vehicle_location object 车型在图片中的位置信息
++ left int 车型距离图片左边的距离
++ top int 车型距离图片上边的距离
++ width int 车型的宽度
++ height int 车型的高度
detect_msec int 识别所用时间,单位:毫秒

返回示例

{
  "detect_msec": 58,
  "result_list": [
    {
      "plate_score": 98.226982116699,
      "plate_type": "单层蓝色普通车牌",
      "plate_layer": "单层",
      "license": "黑A0U1A7",
      "plate_color": "蓝色",
      "plate_location": {
        "left": 652,
        "top": 720,
        "height": 118,
        "width": 244
      },
      "vehicle_location": {
        "left": 546,
        "top": 0,
        "width": 1311,
        "height": 1023
      },
      "vehicle_type": "大型货车",
      "vehicle_type_score": 98.226982116699
    },
    {
      "plate_score": 81.834831237793,
      "plate_type": "单层蓝色普通车牌",
      "plate_layer": "单层",
      "license": "黑AX6789",
      "plate_color": "蓝色",
      "plate_location": {
        "left": 794,
        "top": 45,
        "height": 23,
        "width": 59
      },
      "vehicle_location": {
        "left": 546,
        "top": 0,
        "width": 1311,
        "height": 1023
      },
      "vehicle_type": "大型货车",
      "vehicle_type_score": 98.226982116699
    }
  ]
}

results matching ""

    No results matching ""