Target Recognition
Service
Enable Target Recognition
Topic: thing/product/{gateway_sn}/services
Direction: down
Method: target_detect_open
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| ai_lens_type | Detection lens | int | 0: Visible light, 1: Infrared, 2: Night vision (currently unsupported) | Lens type used for AI recognition |
| scene_type | Current recognition scene | int | 0: General | Default value is 0 |
| target_type_list | List of selected detection types by the user; an empty list indicates recognition of all supported detection types in the current scene | list<int> | See definition of "Target recognition types" below | NULL is acceptable |
Example**:**
Topic: thing/product/{gateway_sn}/services_reply
Direction: up
Method: target_detect_open
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| result | Is AI recognition enabled | int | 0: Success, Non-zero: Failure |
Turn Off Target Recognition
Topic: thing/product/{gateway_sn}/services
Direction: down
Method: target_detect_close
Data:
Example**:**
Topic: thing/product/{gateway_sn}/services_reply
Direction: up
Method: target_detect_close
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| result | Disable AI recognition operation result | int | 0: Success, Non-zero: Failure |
Select Tracking Target Information
The tracking target function allows the aircraft to adjust its body to face the target, making that target point the center of the camera's view.
Topic: thing/product/{gateway_sn}/services
Direction: down
Method: select_tracking_target
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| locked | Whether the relative position of the nose and gimbal is locked | bool | false: only the gimbal turns, the body does not turn; true: locks the nose, the gimbal and body turn together | When locked, the gimbal and body rotate together |
| start_x | Starting point x-coordinate | double | Starting X coordinate of the target bounding box | |
| start_y | Starting point y-coordinate | double | Starting Y coordinate of the target bounding box | |
| width | Width of the target point | double | Width of the target bounding box | |
| height | Height of the target point | double | Height of the target bounding box | |
| tracker_id | Detection target ID | int | Target tracking ID |
Example:
{
"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"data": {
"start_x": 0.5,
"start_y": 0.5,
"locked": true,
"width": 0.8,
"height": 0.3,
"tracker_id": 123456
},
"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"timestamp": 1654070968655,
"method": "select_tracking_target"
}
Topic: thing/product/{gateway_sn}/services_reply
Direction: up
Method: select_tracking_target
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| result | Return code | int | Non-zero indicates an error |
Example:
{
"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"data": {
"result": 0
},
"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
"timestamp": 1654070968655,
"method": "select_tracking_target"
}
Exit Target Lock
Exiting the target lock will continue target detection; the target will not stop being detected unless target recognition is turned off.
Topic: thing/product/{gateway_sn}/services
Direction: down
Method: target_tracking_close
Data:
Example:
Topic: thing/product/{gateway_sn}/services_reply
Direction: up
Method: target_tracking_close
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| result | Result of closing AI recognition operation | int | 0 for success; non-zero for failure |
Intelligent Lock Enter
Topic: thing/product/{gateway_sn}/services
Direction: down
Method: intelligent_lock_enter
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| payload_index | Camera payload index | string | Camera payload enumeration index |
Topic: thing/product/{gateway_sn}/services_reply
Direction: up
Method: intelligent_lock_enter
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| result | Return code | int | 0: Success, Non-zero: Failure |
Intelligent Lock Exit
Topic: thing/product/{gateway_sn}/services
Direction: down
Method: intelligent_lock_exit
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| payload_index | Camera payload index | string | Camera payload enumeration index |
Topic: thing/product/{gateway_sn}/services_reply
Direction: up
Method: intelligent_lock_exit
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| result | Return code | int | 0: Success, Non-zero: Failure |
Select Illegal Parking Target
Topic: thing/product/{gateway_sn}/services
Direction: down
Method: select_illegal_parking_target
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| payload_index | Camera payload index | string | Camera payload enumeration index | |
| x | Screen X coordinate | float | 0~1 | X coordinate ratio of the target on screen |
| y | Screen Y coordinate | float | 0~1 | Y coordinate ratio of the target on screen |
Topic: thing/product/{gateway_sn}/services_reply
Direction: up
Method: select_illegal_parking_target
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| result | Return code | int | 0: Success, Non-zero: Failure |
AI Illegal Parking Data Service
Topic: thing/product/{gateway_sn}/services
Direction: down
Method: aiservice_illegal_data
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| payload_index | Camera payload index | string | Camera payload enumeration index | |
| action | Action type | int | Illegal parking data operation type |
Topic: thing/product/{gateway_sn}/services_reply
Direction: up
Method: aiservice_illegal_data
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| result | Return code | int | 0: Success, Non-zero: Failure |
Status
Target Recognition Result Reporting
Topic: topic: thing/product/{gateway_sn}/state
Direction: up
Method: target_detect_result_report
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| time | Timestamp | long | Detection timestamp | |
| uav_id | UAV ID | String | UAV device identifier | |
| camera_id | Camera ID | int | 0: visible light, 1: infrared | Camera ID used for detection |
| global_pos | UAV Latitude/Longitude | GlobalPos | Current latitude and longitude of the aircraft | |
| camera | Camera Parameters | CameraBean | Camera parameter information | |
| obj_cnt | Detected Target Count | int | Total number of detected targets | |
| objs | Detected Contents | List<ObjCnts> | Detected target list |
ObjCnts
| Column | Name | Type | constraint | Description | |
|---|---|---|---|---|---|
| tracker_id | Detected Target ID | String | Target tracking ID | ||
| cls_id | Detected Target Type | int | Target classification ID | ||
| bbox | Target Detection Box | BBox | Target detection bounding box coordinates | ||
| pos | Target Latitude/Longitude | GlobalPos | Target latitude and longitude | ||
| pic | First Frame Image Path | String | (This may change as the base station and UAV currently cannot capture screenshots) | ||
| timestamp | Detection timestamp |
BBox
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| x | Target X Coordinate | float | Proportion of the screen | |
| y | Target Y Coordinate | float | Proportion of the screen | |
| w | Target Width | float | Proportion of the screen | |
| h | Target Height | float | Proportion of the screen |
CameraBean
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| roll | Gimbal Roll Angle | float | Gimbal roll angle | |
| pitch | Gimbal Pitch Angle | float | Gimbal pitch angle | |
| yaw | Gimbal Yaw Angle (Horizontal) | float | Gimbal yaw angle | |
| longitude | UAV Longitude | float | UAV longitude | |
| latitude | UAV Latitude | float | UAV latitude | |
| height | UAV Relative Height | float | Relative altitude of the aircraft | |
| fov | Field of View (FOV) | flaot[] | Camera field of view | |
| resolution | Original Image Resolution | `int[] | Image resolution | |
| focal_type | Focal Type | String | Lens focal type |
GlobalPos
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| latitude | Latitude | float | Angle value. Negative for south, positive for north, accurate to 6 decimal places. | |
| longitude | Longitude | float | Angle value. Positive for east, negative for west, accurate to 6 decimal places. | |
| altitude | Altitude | float | Target point altitude (ellipsoid height) |
Target Types
| Target Type ID | Target Name |
|---|---|
| 0 | Background(Not supported yet) |
| 1 | Animal(Not supported yet) |
| 2 | Boat |
| 3 | Car |
| 4 | Pedestrian |
| 5 | Cyclist |
| 6 | Large Vehicle |
| 34 | Drone |
| 35 | Smoke |
| 36 | Fire |
| 99 | No Target Detected |
Event
AI Detection Shooting Result Reporting
Topic: thing/product/{gateway_sn}/events
Direction: up
Method: AI_detect_shoot_notify
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| File | File | text | File information | |
| path | Business path of the file | text | Business storage path of the file | |
| ext | File extension content | struct | Extended information of the file | |
| »flight_id | Task ID | text | Unique identifier for the flight task | |
| »uav_id | Drone SN | text | Drone SN | |
| »waypoint_id | Waypoint ID | text | Unique identifier for the waypoint | |
| »drone_model_key | Drone product enumeration value | text | Product enumeration value of the drone model | |
| »payload_model_key | Payload product enumeration value | textt | Product enumeration value of the payload model | |
| »is_original | Is it the original image | bool | :"No", "1":"Yes" | Whether the image is the original |
| metadata | Media metadata | struct | Metadata of the media file | |
| »gimbal_yaw_degree | Gimbal yaw angle | float | Gimbal yaw angle in degrees | |
| »absolute_altitude | Absolute shooting height | float | Absolute altitude when shooting | |
| »relative_altitude | Relative shooting height | float | Relative altitude when shooting | |
| »create_time | Media shooting time | date | "format":"iso8601" | Creation time of the media file |
| »shoot_position | Shooting position | struct | GPS position when the photo was taken | |
| »»lat | Shooting position latitude | float | Latitude of the shooting position | |
| »»lng | Shooting position longitude | float | Longitude of the shooting position | |
| obj_num | Number of detected targets in a frame | int | Total number of detected targets in the current frame | |
| ObjInfo | Detected target array | struct | Array of detected target information | |
| »tracker_id | Detected target ID | String | Unique tracking ID of the detected target | |
| »cls_id | Detected target type | int | Classification type of the detected target | |
| »timestamp | Detection timestamp | |||
| »object_position | Target latitude and longitude | Latitude and longitude of the target | ||
| »»object_lat | Latitude | Latitude of the detected target | ||
| »»object_lng | Longitude | Longitude of the detected target | ||
| »»object_altitude | Altitude | float | Altitude of the detected target | |
| »bbox | Target detection box | Bounding box of the detected target | ||
| »»x | Target X coordinate on screen | float | X coordinate ratio on screen | |
| »»y | Target Y coordinate on screen | float | Y coordinate ratio on screen | |
| »»w | Target width on screen | float | Width ratio on screen | |
| »»h | Target height on screen | float | Height ratio on screen |
Evidence Collection Status Reporting
Topic: thing/product/{gateway_sn}/events
Direction: up
Method: evidence_collection_status
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| timestamp | Timestamp | int | Unit: milliseconds | |
| index | Target index | int | Index number of the current target vehicle | |
| car_sum | Total number of vehicles | int | Total count of detected vehicles | |
| flight_id | Task name | string | Temporarily stores mission_id | |
| status | Task status | int | 1: Paused, 2: Executing, 3: Task completed, 4: Task stopped abnormally, 5: Single vehicle collection completed | Current task execution status |
| stop_reason | Abnormal stop reason | int | Reason for task abnormal stop | |
| pos | Target latitude/longitude | GlobalPos | Latitude and longitude of the target vehicle | |
| car_color | Vehicle color | string | Color of the detected vehicle | |
| plate_color | License plate color | string | Represents license plate type, requires mapping | |
| car_num | License plate number | string | License plate number of the vehicle | |
| car_brand | Vehicle brand | string | Brand of the detected vehicle | |
| car_id | Vehicle ID | int | Unique identifier of the vehicle | |
| is_driver_seat_occupied | Is driver seat occupied | bool | Whether the driver seat is occupied | |
| photo_path_top | Top photo path | string | Storage path of the top-view photo | |
| photo_path_front | Front photo path | string | Storage path of the front-view photo | |
| photo_path_num | License plate photo path | string | Storage path of the license plate photo |
GlobalPos
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| latitude | Latitude | double | max 90, min -90 | Angle value. Negative for south, positive for north, accurate to 6 decimal places. |
| longitude | Longitude | double | max 180, min -180 | Angle value. Positive for east, negative for west, accurate to 6 decimal places. |
| altitude | Altitude | float | Target point altitude (ellipsoid height) |
Illegal Parking Detection Info Reporting
Topic: thing/product/{gateway_sn}/events
Direction: up
Method: aiservice_illegal_parking_info
Data:
| Column | Name | Type | constraint | Description |
|---|---|---|---|---|
| timestamp | Timestamp | long | Frame acquisition timestamp | |
| frame_id | Frame ID | int | Unique identifier for the video frame | |
| flight_id | Task ID | string | Unique identifier for the flight task | |
| resolution_width | Image width | int | Image resolution width | |
| resolution_height | Image height | int | Image resolution height | |
| lens_id | Lens ID | int | Lens ID corresponding to the published result | |
| index | Vehicle index | int | Index number of the vehicle | |
| car_color | Vehicle color | string | Color of the vehicle | |
| score | Confidence | int | [0,100] | Detection confidence score |
| car_lat | Latitude | double | Latitude of the vehicle | |
| car_lon | Longitude | double | Longitude of the vehicle | |
| car_alt | Altitude | double | Altitude of the vehicle | |
| car_center_w | Target center width ratio | int | [0,10000] | Ratio of the target center point in the width direction |
| car_center_h | Target center height ratio | int | [0,10000] | Ratio of the target center point in the height direction |
| car_grid_w | Target box width ratio | int | [0,10000] | Width percentage of the target box |
| car_grid_h | Target box height ratio | int | [0,10000] | Height percentage of the target box |