RDK X5 provides multiple target detection algorithm models. After the program is started, MIPI cameras can be used to detect objects.
You can view the recognition results in the PC browser.
Note: This case needs to be run as root user, and administrator privileges are required to call the MIPI camera!
Switch to root user
xxxxxxxxxx
su root
Password: yahboom
FCOS is an open source Onnx model from Horizon, trained using the COCO dataset, and supports 80 types of target detection, including people, animals, fruits, and vehicles.
Application scenarios: FCOS was released in 2019 and is a single-stage target detection algorithm that can realize pedestrian detection, vehicle detection and other functions. It is mainly used in autonomous driving, smart home and other fields.
After SSH connects to the car, run the terminal,
ros2 launch dnn_node_example dnn_node_example.launch.py dnn_example_config_file:=config/fcosworkconfig.json dnn_example_image_width:=480 dnn_example_image_height:=272
Open the browser on the PC (note that the computer and RDK X5 network must be in the same LAN), enter the URL: car IP: 8000, for example, my car IP is 192.168.2.67, enter the URL in the browser of the virtual machine,
xxxxxxxxxx
192.168.2.67:8000
Click to enter the Web display terminal, the display screen is as follows,
The YOLO target detection algorithm example uses images as input, uses BPU for algorithm reasoning, and publishes the algorithm msg containing the target category and detection box. Currently supports three versions of yolov2, yolov3, and yolov5. The model is trained using the COCO dataset and supports 80 types of target detection, including people, animals, fruits, vehicles, etc.
Application scenarios: As a representative algorithm in single-stage target detection, the YOLO series has the advantages of fast speed and good generalization. It can realize functions such as garbage recognition and vehicle detection. It is mainly used in fields such as autonomous driving and smart home.
After SSH connects to the car, the terminal runs,
xxxxxxxxxx
ros2 launch dnn_node_example dnn_node_example.launch.py dnn_example_config_file:=config/yolov2workconfig.json dnn_example_image_width:=480 dnn_example_image_height:=272
The web display terminal displays the following screen,
Mobilenet_SSD is a caffe model obtained from https://github.com/chuanqi305/MobileNet-SSD, trained using the VOC dataset, and supports 20 types of target detection, including people, animals, fruits, and vehicles.
Application scenarios: MobileNet_SSD is a target detection algorithm based on MobileNet. It has the advantages of fast speed and easy deployment. It can realize functions such as object detection and garbage recognition. It is mainly used in fields such as autonomous driving and smart home.
After SSH connects to the car, run the terminal,
xxxxxxxxxx
ros2 launch dnn_node_example dnn_node_example.launch.py dnn_example_config_file:=config/mobilenet_ssd_workconfig.json dnn_example_image_width:=480 dnn_example_image_height:=272
The web display terminal displays the following screen,
EfficientNet_Det is an Onnx model obtained from https://github.com/HorizonRobotics-Platform/ModelZoo/tree/master/EfficientDet, trained using the COCO dataset, and supports 80 types of target detection, including people, animals, fruits, and vehicles.
Application scenarios: EfficientNet_Det can realize functions such as vehicle detection, and is mainly used in fields such as autonomous driving and smart home.
After SSH connects to the car, the terminal runs,
xxxxxxxxxx
ros2 launch dnn_node_example dnn_node_example.launch.py dnn_example_config_file:=config/efficientnet_lite0_workconfig.json dnn_example_image_width:=480 dnn_example_image_height:=272
The Web display terminal displays the following screen,