Vehicle Detection

Last Updated on : 2021-07-16 07:54:20download

Analyze the uploaded image to detect whether there is a vehicle in the image, and return the confidence level and vehicle location. Up to two vehicles can be recognized simultaneously, and the size of the vehicle is not less than 150 × 150 pixels. >Note: Base64 encoded data does not include the image header, such as data:image/jpg;base64,.

API address

POST: /v1.0/iot-03/ai-vision/car-detection

Request parameter

Return parameter

Parameter name Type Description
result List

Description of result

Parameter name Type Description
confidence Float A greater confidence value indicates higher accuracy. Valid values: 0–1.
coordinates CoordinatesRes The coordinates of the vehicle in the image.

Description of coordinates

Parameter name Type Description
left Integer The distance between the vehicle frame and the left border of the image in pixels.
top Integer The distance between the vehicle frame and the top border of the image, in pixels.
right Integer The distance between the vehicle frame and the right border of the image, in pixels.
bottom Integer The distance between the vehicle frame and the bottom border of the image, in pixels.

Request example

POST: /v1.0/iot-03/ai-vision/car-detection
{ "image": "/9j/4AAQSkxxxxxxxxxxxxxxxx" }

Return example

{ "result": { "confidence": "0.96324956", "coordinates": { "bottom": "932", "right": "777", "top": "10", "left": "0" } }, "success": true }

Error code

For more information, see error code.