rdk_robot_dev_agent/knowledge_hub/人体检测和跟踪算法部署流程.md

2.3 KiB
Raw Permalink Blame History

人体检测和跟踪算法部署流程用MIPI摄像头发布为照片

  1. 配置tros.b环境 foxy版本:source /opt/tros/setup.bash humble版本:source /opt/tros/humble/setup.bash

  2. 从tros.b的安装路径中拷贝出运行示例需要的配置文件。 cp -r /opt/tros/${TROS_DISTRO}/lib/mono2d_body_detection/config/ .

  3. 配置MIPI摄像头 export CAM_TYPE=mipi

  4. 启动launch文件 ros2 launch mono2d_body_detection mono2d_body_detection.launch.py

  5. 测试效果 在PC端的浏览器输入http://IP:8000 即可查看图像和算法人体、人头、人脸、人手检测框检测框类型和目标跟踪ID人体关键点渲染效果IP为RDK/X86设备的IP地址

人体检测和跟踪算法部署流程用usb摄像头发布为照片

  1. 配置tros.b环境 foxy版本:source /opt/tros/setup.bash humble版本:source /opt/tros/humble/setup.bash

  2. 从tros.b的安装路径中拷贝出运行示例需要的配置文件。 cp -r /opt/tros/${TROS_DISTRO}/lib/mono2d_body_detection/config/ .

  3. 配置usb摄像头 export CAM_TYPE=usb

  4. 启动launch文件 ros2 launch mono2d_body_detection mono2d_body_detection.launch.py

  5. 测试效果 在PC端的浏览器输入http://IP:8000 即可查看图像和算法人体、人头、人脸、人手检测框检测框类型和目标跟踪ID人体关键点渲染效果IP为RDK/X86设备的IP地址

人体检测和跟踪算法部署流程:使用本地照片回灌

  1. 配置tros.b环境 foxy版本:source /opt/tros/setup.bash humble版本:source /opt/tros/humble/setup.bash

  2. 从tros.b的安装路径中拷贝出运行示例需要的配置文件。 cp -r /opt/tros/${TROS_DISTRO}/lib/mono2d_body_detection/config/ . cp -r /opt/tros/${TROS_DISTRO}/lib/dnn_node_example/config/ .

  3. 配置本地回灌图片 export CAM_TYPE=fb

  4. 启动launch文件 ros2 launch mono2d_body_detection mono2d_body_detection.launch.py publish_image_source:=config/person_body.jpg publish_image_format:=jpg publish_output_image_w:=960 publish_output_image_h:=544

  5. 测试效果 在PC端的浏览器输入http://IP:8000 即可查看图像和算法人体、人头、人脸、人手检测框检测框类型和目标跟踪ID人体关键点渲染效果IP为RDK/X86设备的IP地址