-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.yaml.example
More file actions
224 lines (183 loc) · 5.63 KB
/
Copy pathconfig.yaml.example
File metadata and controls
224 lines (183 loc) · 5.63 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
# lerobo机械臂为COM*,piper机械臂为can*
arm_port: can4
arm_offset:
# - 0
# - 0
# - 0
# - 0.0
# - 0
# - 0
# 机械臂类型,lerobo或piper
arm_type: piper
# 机械臂运动速度百分比 1-100,100 为全速,值越小越慢越平稳
arm_move_speed: 50
# 关节角向量允许的均方误差阈值,小于该值认为到达目标点,单位平方度
arm_reach_mse_threshold_deg2: 1.0
# 不用远程摄像头则置空
camera_ip:
camera_port: 8084
# 以web形式显示图片的端口(起一个网络服务器),以便在无图形化环境运行,置空则直接用opencv的图片显示窗口
cv2_headless_port: 8079
# 默认桌面高度,即在机械臂坐标系下桌面的z坐标,单位米
default_desktop_height: 0.135
# 抓取动作间的停顿时间,单位秒
catch_time_interval_s: 0.5
# 获取机械臂各舵机角度值的重试次数
get_arm_angles_retry_times: 3
# 机械臂移动到旁边的位置,以免挡住相机视野,(x,y,z),单位米
# default_gripper_aside_pos:
# - 0.0
# - 0.2
# - 0.15
# =======大模型=======
# 请求大模型的平台url
# llm_base_url: https://openrouter.ai/api/v1
# llm_base_url: https://api.ohmygpt.com/v1
llm_base_url: http://192.168.2.19:8001/v1
# 大模型平台的api_key,本地部署则随便填,但不要为空
llm_api_key: any
# 提示词文件
prompts_file: prompts.toml
# 代理地址,如请求大模型失败可设置或取消代理
https_proxy: 192.168.0.12:7890
# 使用的大模型名称,见https://openrouter.ai/models 或 https://www.ohmygpt.com/models,必须是支持多模态输入的模型
# llm_model: gemini-3-flash-preview
# 或指定本地部署的模型
llm_model: output/merged-qwen3.5-9b-graspdet
# 如果相机是在机械臂对面,视角和机械臂视角相反(机械臂在画面上方),则设为true
# 主要影响大模型的左右判断
RotationCam2Arm: true
# 语音转文字后端: "xunfei" 使用讯飞,其他值使用自部署语音转文字服务
audio2text_backend: no-xunfei
# 自部署语音转文字服务地址
whisper_url: http://192.168.2.19:8000
whisper_username: wowrobo
whisper_password: wowrobo
# 语音转文字APIID(讯飞)
APPID:
# 语音转文字APISecret
APISecret:
# 语音转文字APIKey
APIKey:
# =======物品分类场景=======
# 以项目根目录为基准
classification_YOLO_model_path:
- /home/czn/roboarm/object_detect/runs/best.pt
# 默认YOLO识别置信度阈值
default_conf_thres: 0.5
# 夹爪闭合阈值,小于该值认为夹取失败,范围是[0,1],越大越开,1表示完全张开(不是角度)
default_gripper_close_threshold: 0.05
# 各类别放置位置,(x,y),单位米
# - pos: 录制阶段固定放置位置
# 字符串(符号坐标):x/-x/y/-y 分别表示 target_x/-target_x/target_y/-target_y
# 数值(绝对坐标):如 [0.2, 0.4] 直接使用该固定位置
# - random_pos: auto-reset 阶段随机撒回范围,
# 两元素列表 [[x_min, x_max], [y_min, y_max]],与 pos 格式对齐
# 未匹配到类别时使用下方 default 条目
class_pos:
default:
pos: [0.05, 0.45] #
random_pos:
- [0.0, 0.45]
- [-0.3, 0.3]
potato:
pos: [0.05, 0.4]
random_pos:
- [0.2, 0.45]
- [-0.3, -0.1]
keywords:
- 'potato'
- '土豆'
tomato:
pos: [0.05, 0.4]
random_pos:
- [0.2, 0.45]
- [-0.1, 0.1]
keywords:
- 'tomato'
- '西红柿'
carrot:
pos: [0.05, 0.4]
random_pos:
- [0.2, 0.45]
- [0.1, 0.3]
keywords:
- 'carrot'
- '胡萝卜'
# 各类别放置位置,(x,y),单位米,xy分别表示其原始位置xy,未指定则放回原处
# keywords表示大模型输出的标签中含有其中某个关键词即认为是这个类别
place_pos:
potato:
pos:
- x
- -y
keywords:
- 'potato'
- '土豆'
tomato:
pos:
- x
- -y
keywords:
- 'tomato'
- '西红柿'
carrot:
pos:
- x
- -y
keywords:
- 'carrot'
- '胡萝卜'
random_pos:
potato:
pos:
- x
- -y
keywords:
- 'potato'
- '土豆'
tomato:
pos:
- x
- -y
keywords:
- 'tomato'
- '西红柿'
carrot:
pos:
- x
- -y
keywords:
- 'carrot'
- '胡萝卜'
# 离放置位置多近时无需抓取,以免反复抓放,单位米,未指定则为0
place_distance_threshold: 0.00
# 抓取时为避免刚好顶到物体,夹爪向外偏移一些的距离,单位米
catch_offset: 0.00
# 抓取前抬起的高度,单位米
catch_raise_height: 0.1
# 放置前抬起的高度,单位米
place_raise_height: 0.1
# 放置时是否先下降再松开夹爪,默认否
go_down_before_open_gripper_in_place: true
# --- auto-reset(随机撒回桌面)参数 ---
# 各类别的随机撒回范围已移至上方 class_pos.{类别}.random_pos 中
# 工作空间边界,(x_min, x_max),超出此范围的坐标会被拒绝
workspace_x_range: [-0.1, 0.55]
workspace_y_range: [-0.3, 0.55]
# 随机放置位置离抓取点的最小距离,单位米
reset_min_place_dist_m: 0.20
# 每轮最多随机撒回的物体数量
reset_max_objects_per_cycle: 1
# =======主从臂跟随场景=======
leader_port: COM5
# =======中国象棋场景=======
# 以项目根目录为基准
chinese_chess_YOLO_model_path:
- object_detect\runs\中国象棋\best.pt
# 夹爪张开的角度,张太大会碰到旁边的子,单位度
gripper_open_degree: 30
# 夹爪朝向固定角度,以棋盘对角线方向抓,防止碰到旁边的棋子,单位度
gripper_direction_degree: 45
# 默认YOLO识别置信度阈值
chinese_chess_default_conf_thres: 0.7