Repository navigation
Expand file tree
/
Copy pathdataflow.yaml
More file actions
131 lines (124 loc) · 4.29 KB
/
Copy pathdataflow.yaml
File metadata and controls
131 lines (124 loc) · 4.29 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
# Copyright 2026 Enactic, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# Teleoperation and data collection. The leader and the robot are modules
# picked by environment variables:
#
# LEADER=ker|vr|webxr|dummy modules/leader-$LEADER.yaml (default: dummy)
# ROBOT=cell|pedestal|mujoco|dummy modules/robot-$ROBOT.yaml (default: dummy)
#
# dora doesn't expand environment variables in `module:`, so run it through
# scripts/dora-envsubst, which does:
#
# LEADER=webxr ROBOT=mujoco scripts/dora-envsubst run dataflow.yaml --uv
#
# See docs/design.md for the rules to follow when changing the modules.
nodes:
- id: ui
path: dora-openarm-data-collection-ui
env:
METADATA_FILE: "metadata_${ROBOT:-dummy}.yaml"
inputs:
# We need at least one input to keep this node alive.
tick: dora/timer/secs/1
# Episode buttons and receive rate of a VR leader.
button_a:
source: leader/button_a
queue_size: 100
button_b:
source: leader/button_b
queue_size: 100
vr_receive_times:
source: leader/vr_receive_times
queue_size: 100
# KER receive rate and device information for the UI leader panel.
ker_position: leader/ker_position
ker_metadata: leader/metadata
camera_wrist_right:
source: robot/camera_wrist_right
queue_size: 1
camera_wrist_left:
source: robot/camera_wrist_left
queue_size: 1
camera_head_left:
source: robot/camera_head_left
queue_size: 1
camera_head_right:
source: robot/camera_head_right
queue_size: 1
camera_ceiling:
source: robot/camera_ceiling
queue_size: 1
arm_status_right: robot/status_right
arm_status_left: robot/status_left
# Motor temperatures and CAN bus state for the UI motor panel.
arm_state_right: robot/arm_state_right
arm_state_left: robot/arm_state_left
outputs:
- command
- arm_command
- id: quittable-tick-leader
path: dora-openarm-quitter
inputs:
command: ui/command
# 250Hz
tick: dora/timer/millis/4
outputs:
- tick
- id: quittable-tick-camera
path: dora-openarm-quitter
inputs:
command: ui/command
# 30fps
tick: dora/timer/millis/33
outputs:
- tick
- id: leader
module: modules/leader-${LEADER:-dummy}.yaml
inputs:
tick: quittable-tick-leader/tick
camera_head_left: robot/camera_head_left
camera_head_right: robot/camera_head_right
- id: robot
module: modules/robot-${ROBOT:-dummy}.yaml
inputs:
tick: quittable-tick-leader/tick
camera_tick: quittable-tick-camera/tick
command: ui/command
arm_command: ui/arm_command
position_right: leader/follower_position_right
position_left: leader/follower_position_left
joystick_y: leader/joystick_y_left
button_x: leader/button_x
pose_right: leader/pose_right
pose_left: leader/pose_left
- id: recorder
path: dora-openarm-dataset-recorder
env:
METADATA_FILE: "metadata_${ROBOT:-dummy}.yaml"
# Output directory for recorded datasets, e.g. data/webxr-mujoco.
DIRECTORY: "data/${LEADER:-dummy}-${ROBOT:-dummy}"
inputs:
command: ui/command
arm_right_action: leader/follower_position_right
arm_left_action: leader/follower_position_left
arm_right_observation: robot/state_right
arm_left_observation: robot/state_left
camera_wrist_right: robot/camera_wrist_right
camera_wrist_left: robot/camera_wrist_left
camera_head_left: robot/camera_head_left
camera_head_right: robot/camera_head_right
camera_ceiling: robot/camera_ceiling
ker_metadata: leader/metadata
elevation_action: robot/elevation_action
elevation_observation: robot/elevation_observation