node-red-node-rdk-tools
Version:
配合RDK硬件及TROS使用的Node-RED功能包(Node-RED nodes for using TROS on a RDK hardware and TROS)
563 lines (562 loc) • 13.3 kB
JSON
[
{
"id": "bev_pro_final_tab",
"type": "tab",
"label": "TROS BodyDetection",
"disabled": false,
"info": ""
},
{
"id": "group_bev_ctrl_final",
"type": "group",
"z": "bev_pro_final_tab",
"name": "核心算法控制",
"style": {
"fill": "#e3f3d3",
"fill-opacity": "0.6",
"label": true
},
"nodes": [
"change_bev_config_final",
"node_execute_bev_final",
"exec_init_bev_final"
],
"x": 394,
"y": 291.5,
"w": 552,
"h": 97
},
{
"id": "group_viz_bev_final",
"type": "group",
"z": "bev_pro_final_tab",
"name": "结果可视化",
"style": {
"fill": "#d1e7f5",
"fill-opacity": "0.6",
"label": true
},
"nodes": [
"delay_preview_bev_final",
"set_ws_url_bev_final",
"video_preview_bev_final"
],
"x": 394,
"y": 439,
"w": 372,
"h": 129.5
},
{
"id": "group_env_bev_final",
"type": "group",
"z": "bev_pro_final_tab",
"name": "环境准备 & 说明",
"style": {
"fill": "#fff9c4",
"fill-opacity": "0.6",
"label": true
},
"nodes": [
"audio_notify_bev_final",
"smart_update_bev_final",
"change_notify_bev_final"
],
"x": 394,
"y": 159,
"w": 552,
"h": 82
},
{
"id": "inject_start_bev_final",
"type": "inject",
"z": "bev_pro_final_tab",
"name": "启动 BEV 算法",
"props": [
{
"p": "payload"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"payload": "",
"payloadType": "date",
"x": 280,
"y": 320,
"wires": [
[
"exec_init_bev_final"
]
]
},
{
"id": "exec_init_bev_final",
"type": "exec",
"z": "bev_pro_final_tab",
"g": "group_bev_ctrl_final",
"command": "source /opt/tros/humble/setup.bash && rm -rf qat nuscenes_bev_val && ln -s $(ros2 pkg prefix hobot_bev)/lib/hobot_bev/qat/ qat && ln -sf ~/hobot_bev_data/nuscenes_bev_val nuscenes_bev_val",
"addpay": false,
"append": "",
"useSpawn": "false",
"timer": "",
"winHide": false,
"oldrc": false,
"name": "初始化环境",
"x": 490,
"y": 340,
"wires": [
[
"change_bev_config_final",
"delay_preview_bev_final"
],
[],
[]
]
},
{
"id": "change_bev_config_final",
"type": "change",
"z": "bev_pro_final_tab",
"g": "group_bev_ctrl_final",
"name": "配置流参数",
"rules": [
{
"t": "set",
"p": "launch",
"pt": "msg",
"to": "hobot_bev hobot_bev.launch.py",
"tot": "str"
},
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 670,
"y": 340,
"wires": [
[
"node_execute_bev_final"
]
]
},
{
"id": "node_execute_bev_final",
"type": "rdk-tools checkexecute",
"z": "bev_pro_final_tab",
"g": "group_bev_ctrl_final",
"name": "",
"x": 850,
"y": 340,
"wires": [
[
"cc5dd0d798dc6428"
],
[
"6060ba20131dbb91"
]
]
},
{
"id": "inject_stop_bev_final",
"type": "inject",
"z": "bev_pro_final_tab",
"name": "关闭",
"props": [
{
"p": "kill",
"v": "",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"x": 250,
"y": 360,
"wires": [
[
"node_execute_bev_final"
]
]
},
{
"id": "inject_browser_bev_final",
"type": "inject",
"z": "bev_pro_final_tab",
"name": "打开浏览器",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"payload": "http://{host}:8000",
"payloadType": "str",
"x": 240,
"y": 600,
"wires": [
[
"open_browser_bev_final"
]
]
},
{
"id": "open_browser_bev_final",
"type": "rdk-tools openurl",
"z": "bev_pro_final_tab",
"name": "",
"x": 420,
"y": 600,
"wires": []
},
{
"id": "delay_preview_bev_final",
"type": "delay",
"z": "bev_pro_final_tab",
"g": "group_viz_bev_final",
"name": "延迟5秒",
"pauseType": "delay",
"timeout": "5",
"timeoutUnits": "seconds",
"rate": "1",
"nbRateUnits": "1",
"rateUnits": "second",
"randomFirst": "1",
"randomLast": "5",
"randomUnits": "seconds",
"drop": false,
"allowrate": false,
"outputs": 1,
"x": 480,
"y": 480,
"wires": [
[
"set_ws_url_bev_final"
]
]
},
{
"id": "set_ws_url_bev_final",
"type": "change",
"z": "bev_pro_final_tab",
"g": "group_viz_bev_final",
"name": "设定视频流",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "ws://{host}:8000",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 490,
"y": 520,
"wires": [
[
"video_preview_bev_final"
]
]
},
{
"id": "video_preview_bev_final",
"type": "rdk-tools videows",
"z": "bev_pro_final_tab",
"g": "group_viz_bev_final",
"name": "Web预览",
"fps": "10",
"width": "480",
"active": true,
"x": 660,
"y": 520,
"wires": [
[
"e0f244b9b748332b"
],
[
"35c740c6421cb176"
],
[]
]
},
{
"id": "audio_notify_bev_final",
"type": "rdk-tools texttoaudio",
"z": "bev_pro_final_tab",
"g": "group_env_bev_final",
"name": "",
"x": 850,
"y": 200,
"wires": []
},
{
"id": "45d4d69e47688ced",
"type": "comment",
"z": "bev_pro_final_tab",
"name": "名称:TROS应用 目标检测",
"info": "",
"x": 250,
"y": 40,
"wires": []
},
{
"id": "40b2c37e897f1c42",
"type": "inject",
"z": "bev_pro_final_tab",
"name": "了解更多",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"payload": "https://developer.d-robotics.cc/rdk_doc/Robot_development/boxs/body/mono2d_body_detection",
"payloadType": "str",
"x": 480,
"y": 40,
"wires": [
[
"5aa95791392357b3"
]
]
},
{
"id": "5aa95791392357b3",
"type": "rdk-tools openurl",
"z": "bev_pro_final_tab",
"name": "",
"x": 740,
"y": 40,
"wires": []
},
{
"id": "inject_update_bev_final",
"type": "inject",
"z": "bev_pro_final_tab",
"name": "检查更新",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"payload": "",
"payloadType": "date",
"x": 260,
"y": 200,
"wires": [
[
"smart_update_bev_final"
]
]
},
{
"id": "smart_update_bev_final",
"type": "rdk-tools smartupdate",
"z": "bev_pro_final_tab",
"g": "group_env_bev_final",
"name": "",
"x": 480,
"y": 200,
"wires": [
[
"change_notify_bev_final"
],
[]
]
},
{
"id": "change_notify_bev_final",
"type": "change",
"z": "bev_pro_final_tab",
"g": "group_env_bev_final",
"name": "更新提示",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "环境检查完成",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 660,
"y": 200,
"wires": [
[
"audio_notify_bev_final"
]
]
},
{
"id": "inject_doc_link",
"type": "inject",
"z": "bev_pro_final_tab",
"name": "首次使用必读 (下载数据集)",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"payload": "https://developer.d-robotics.cc/rdk_doc/Robot_development/boxs/perception/bev",
"payloadType": "str",
"x": 530,
"y": 80,
"wires": [
[
"open_doc_link"
]
]
},
{
"id": "open_doc_link",
"type": "rdk-tools openurl",
"z": "bev_pro_final_tab",
"name": "",
"x": 740,
"y": 80,
"wires": []
},
{
"id": "comment_data_tip",
"type": "comment",
"z": "bev_pro_final_tab",
"name": "⚠️ 注意:运行前请先点击上方按钮,按官方文档手动下载数据集!",
"info": "需要下载 nuscenes_bev_val.tar.gz 并解压到板端指定目录。",
"x": 380,
"y": 120,
"wires": []
},
{
"id": "6060ba20131dbb91",
"type": "debug",
"z": "bev_pro_final_tab",
"name": "错误执行提示",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"targetType": "msg",
"statusVal": "",
"statusType": "auto",
"x": 1060,
"y": 360,
"wires": []
},
{
"id": "cc5dd0d798dc6428",
"type": "debug",
"z": "bev_pro_final_tab",
"name": "正确执行提示",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"targetType": "msg",
"statusVal": "",
"statusType": "auto",
"x": 1060,
"y": 320,
"wires": []
},
{
"id": "e0f244b9b748332b",
"type": "debug",
"z": "bev_pro_final_tab",
"name": "算法结果输出",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"targetType": "msg",
"statusVal": "",
"statusType": "auto",
"x": 860,
"y": 480,
"wires": []
},
{
"id": "35c740c6421cb176",
"type": "debug",
"z": "bev_pro_final_tab",
"name": "性能信息输出",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "true",
"targetType": "full",
"statusVal": "",
"statusType": "auto",
"x": 860,
"y": 520,
"wires": []
},
{
"id": "7eca6ca0dd22e9a2",
"type": "global-config",
"env": [],
"modules": {
"node-red-node-rdk-tools": "0.0.27"
}
}
]