Robotics
LeRobot
Safetensors
diffusion
K-vr commited on
Commit
5e23da1
·
verified ·
1 Parent(s): 70ceb2a

Upload policy weights, train config and readme

Browse files
Files changed (4) hide show
  1. README.md +62 -0
  2. config.json +140 -0
  3. model.safetensors +3 -0
  4. train_config.json +276 -0
README.md ADDED
@@ -0,0 +1,62 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ datasets: K-vr/bimanual_task_cubemove
3
+ library_name: lerobot
4
+ license: apache-2.0
5
+ model_name: diffusion
6
+ pipeline_tag: robotics
7
+ tags:
8
+ - diffusion
9
+ - lerobot
10
+ - robotics
11
+ ---
12
+
13
+ # Model Card for diffusion
14
+
15
+ <!-- Provide a quick summary of what the model is/does. -->
16
+
17
+
18
+ [Diffusion Policy](https://huggingface.co/papers/2303.04137) treats visuomotor control as a generative diffusion process, producing smooth, multi-step action trajectories that excel at contact-rich manipulation.
19
+
20
+
21
+ This policy has been trained and pushed to the Hub using [LeRobot](https://github.com/huggingface/lerobot).
22
+ See the full documentation at [LeRobot Docs](https://huggingface.co/docs/lerobot/index).
23
+
24
+ ---
25
+
26
+ ## How to Get Started with the Model
27
+
28
+ For a complete walkthrough, see the [training guide](https://huggingface.co/docs/lerobot/il_robots#train-a-policy).
29
+ Below is the short version on how to train and run inference/eval:
30
+
31
+ ### Train from scratch
32
+
33
+ ```bash
34
+ lerobot-train \
35
+ --dataset.repo_id=${HF_USER}/<dataset> \
36
+ --policy.type=act \
37
+ --output_dir=outputs/train/<desired_policy_repo_id> \
38
+ --job_name=lerobot_training \
39
+ --policy.device=cuda \
40
+ --policy.repo_id=${HF_USER}/<desired_policy_repo_id>
41
+ --wandb.enable=true
42
+ ```
43
+
44
+ _Writes checkpoints to `outputs/train/<desired_policy_repo_id>/checkpoints/`._
45
+
46
+ ### Evaluate the policy/run inference
47
+
48
+ ```bash
49
+ lerobot-record \
50
+ --robot.type=so100_follower \
51
+ --dataset.repo_id=<hf_user>/eval_<dataset> \
52
+ --policy.path=<hf_user>/<desired_policy_repo_id> \
53
+ --episodes=10
54
+ ```
55
+
56
+ Prefix the dataset repo with **eval\_** and supply `--policy.path` pointing to a local or hub checkpoint.
57
+
58
+ ---
59
+
60
+ ## Model Details
61
+
62
+ - **License:** apache-2.0
config.json ADDED
@@ -0,0 +1,140 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "type": "diffusion",
3
+ "n_obs_steps": 2,
4
+ "input_features": {
5
+ "observation.state": {
6
+ "type": "STATE",
7
+ "shape": [
8
+ 12
9
+ ]
10
+ },
11
+ "observation.images.left_cam_left": {
12
+ "type": "VISUAL",
13
+ "shape": [
14
+ 3,
15
+ 480,
16
+ 640
17
+ ]
18
+ },
19
+ "observation.images.left_cam_scene": {
20
+ "type": "VISUAL",
21
+ "shape": [
22
+ 3,
23
+ 480,
24
+ 640
25
+ ]
26
+ },
27
+ "observation.images.right_cam_right": {
28
+ "type": "VISUAL",
29
+ "shape": [
30
+ 3,
31
+ 480,
32
+ 640
33
+ ]
34
+ },
35
+ "observation.images.cam_realsense_rgb": {
36
+ "type": "VISUAL",
37
+ "shape": [
38
+ 3,
39
+ 480,
40
+ 640
41
+ ]
42
+ },
43
+ "observation.depth.cam_realsense": {
44
+ "type": "STATE",
45
+ "shape": [
46
+ 480,
47
+ 640
48
+ ]
49
+ },
50
+ "observation.images.cam_realsense_ir_left": {
51
+ "type": "VISUAL",
52
+ "shape": [
53
+ 3,
54
+ 480,
55
+ 640
56
+ ]
57
+ },
58
+ "observation.images.cam_realsense_ir_right": {
59
+ "type": "VISUAL",
60
+ "shape": [
61
+ 3,
62
+ 480,
63
+ 640
64
+ ]
65
+ },
66
+ "observation.camera_intrinsics.realsense": {
67
+ "type": "STATE",
68
+ "shape": [
69
+ 5
70
+ ]
71
+ }
72
+ },
73
+ "output_features": {
74
+ "action": {
75
+ "type": "ACTION",
76
+ "shape": [
77
+ 12
78
+ ]
79
+ }
80
+ },
81
+ "device": "cuda",
82
+ "use_amp": true,
83
+ "use_peft": false,
84
+ "push_to_hub": true,
85
+ "repo_id": "K-vr/bimanual_diffusion",
86
+ "private": null,
87
+ "tags": null,
88
+ "license": null,
89
+ "pretrained_path": null,
90
+ "horizon": 16,
91
+ "n_action_steps": 8,
92
+ "normalization_mapping": {
93
+ "VISUAL": "MEAN_STD",
94
+ "STATE": "MIN_MAX",
95
+ "ACTION": "MIN_MAX"
96
+ },
97
+ "drop_n_last_frames": 7,
98
+ "vision_backbone": "resnet18",
99
+ "resize_shape": [
100
+ 96,
101
+ 96
102
+ ],
103
+ "crop_ratio": 1.0,
104
+ "crop_shape": null,
105
+ "crop_is_random": true,
106
+ "pretrained_backbone_weights": null,
107
+ "use_group_norm": true,
108
+ "spatial_softmax_num_keypoints": 32,
109
+ "use_separate_rgb_encoder_per_camera": false,
110
+ "down_dims": [
111
+ 128,
112
+ 256,
113
+ 512
114
+ ],
115
+ "kernel_size": 5,
116
+ "n_groups": 8,
117
+ "diffusion_step_embed_dim": 128,
118
+ "use_film_scale_modulation": true,
119
+ "noise_scheduler_type": "DDPM",
120
+ "num_train_timesteps": 100,
121
+ "beta_schedule": "squaredcos_cap_v2",
122
+ "beta_start": 0.0001,
123
+ "beta_end": 0.02,
124
+ "prediction_type": "epsilon",
125
+ "clip_sample": true,
126
+ "clip_sample_range": 1.0,
127
+ "num_inference_steps": null,
128
+ "compile_model": false,
129
+ "compile_mode": "reduce-overhead",
130
+ "do_mask_loss_for_padding": false,
131
+ "optimizer_lr": 0.0001,
132
+ "optimizer_betas": [
133
+ 0.95,
134
+ 0.999
135
+ ],
136
+ "optimizer_eps": 1e-08,
137
+ "optimizer_weight_decay": 1e-06,
138
+ "scheduler_name": "cosine",
139
+ "scheduler_warmup_steps": 500
140
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a1429715f2c6aee8cc264a89ff97c64dfff79f3652b636c3a4bbe909f2b47656
3
+ size 132834472
train_config.json ADDED
@@ -0,0 +1,276 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "dataset": {
3
+ "repo_id": "K-vr/bimanual_task_cubemove",
4
+ "root": null,
5
+ "episodes": null,
6
+ "image_transforms": {
7
+ "enable": true,
8
+ "max_num_transforms": 3,
9
+ "random_order": false,
10
+ "tfs": {
11
+ "brightness": {
12
+ "weight": 1.0,
13
+ "type": "ColorJitter",
14
+ "kwargs": {
15
+ "brightness": [
16
+ 0.8,
17
+ 1.2
18
+ ]
19
+ }
20
+ },
21
+ "contrast": {
22
+ "weight": 1.0,
23
+ "type": "ColorJitter",
24
+ "kwargs": {
25
+ "contrast": [
26
+ 0.8,
27
+ 1.2
28
+ ]
29
+ }
30
+ },
31
+ "saturation": {
32
+ "weight": 1.0,
33
+ "type": "ColorJitter",
34
+ "kwargs": {
35
+ "saturation": [
36
+ 0.5,
37
+ 1.5
38
+ ]
39
+ }
40
+ },
41
+ "hue": {
42
+ "weight": 1.0,
43
+ "type": "ColorJitter",
44
+ "kwargs": {
45
+ "hue": [
46
+ -0.05,
47
+ 0.05
48
+ ]
49
+ }
50
+ },
51
+ "sharpness": {
52
+ "weight": 1.0,
53
+ "type": "SharpnessJitter",
54
+ "kwargs": {
55
+ "sharpness": [
56
+ 0.5,
57
+ 1.5
58
+ ]
59
+ }
60
+ },
61
+ "affine": {
62
+ "weight": 1.0,
63
+ "type": "RandomAffine",
64
+ "kwargs": {
65
+ "degrees": [
66
+ -5.0,
67
+ 5.0
68
+ ],
69
+ "translate": [
70
+ 0.05,
71
+ 0.05
72
+ ]
73
+ }
74
+ }
75
+ }
76
+ },
77
+ "revision": null,
78
+ "use_imagenet_stats": true,
79
+ "video_backend": "torchcodec",
80
+ "streaming": false
81
+ },
82
+ "env": null,
83
+ "policy": {
84
+ "type": "diffusion",
85
+ "n_obs_steps": 2,
86
+ "input_features": {
87
+ "observation.state": {
88
+ "type": "STATE",
89
+ "shape": [
90
+ 12
91
+ ]
92
+ },
93
+ "observation.images.left_cam_left": {
94
+ "type": "VISUAL",
95
+ "shape": [
96
+ 3,
97
+ 480,
98
+ 640
99
+ ]
100
+ },
101
+ "observation.images.left_cam_scene": {
102
+ "type": "VISUAL",
103
+ "shape": [
104
+ 3,
105
+ 480,
106
+ 640
107
+ ]
108
+ },
109
+ "observation.images.right_cam_right": {
110
+ "type": "VISUAL",
111
+ "shape": [
112
+ 3,
113
+ 480,
114
+ 640
115
+ ]
116
+ },
117
+ "observation.images.cam_realsense_rgb": {
118
+ "type": "VISUAL",
119
+ "shape": [
120
+ 3,
121
+ 480,
122
+ 640
123
+ ]
124
+ },
125
+ "observation.depth.cam_realsense": {
126
+ "type": "STATE",
127
+ "shape": [
128
+ 480,
129
+ 640
130
+ ]
131
+ },
132
+ "observation.images.cam_realsense_ir_left": {
133
+ "type": "VISUAL",
134
+ "shape": [
135
+ 3,
136
+ 480,
137
+ 640
138
+ ]
139
+ },
140
+ "observation.images.cam_realsense_ir_right": {
141
+ "type": "VISUAL",
142
+ "shape": [
143
+ 3,
144
+ 480,
145
+ 640
146
+ ]
147
+ },
148
+ "observation.camera_intrinsics.realsense": {
149
+ "type": "STATE",
150
+ "shape": [
151
+ 5
152
+ ]
153
+ }
154
+ },
155
+ "output_features": {
156
+ "action": {
157
+ "type": "ACTION",
158
+ "shape": [
159
+ 12
160
+ ]
161
+ }
162
+ },
163
+ "device": "cuda",
164
+ "use_amp": true,
165
+ "use_peft": false,
166
+ "push_to_hub": true,
167
+ "repo_id": "K-vr/bimanual_diffusion",
168
+ "private": null,
169
+ "tags": null,
170
+ "license": null,
171
+ "pretrained_path": null,
172
+ "horizon": 16,
173
+ "n_action_steps": 8,
174
+ "normalization_mapping": {
175
+ "VISUAL": "MEAN_STD",
176
+ "STATE": "MIN_MAX",
177
+ "ACTION": "MIN_MAX"
178
+ },
179
+ "drop_n_last_frames": 7,
180
+ "vision_backbone": "resnet18",
181
+ "resize_shape": [
182
+ 96,
183
+ 96
184
+ ],
185
+ "crop_ratio": 1.0,
186
+ "crop_shape": null,
187
+ "crop_is_random": true,
188
+ "pretrained_backbone_weights": null,
189
+ "use_group_norm": true,
190
+ "spatial_softmax_num_keypoints": 32,
191
+ "use_separate_rgb_encoder_per_camera": false,
192
+ "down_dims": [
193
+ 128,
194
+ 256,
195
+ 512
196
+ ],
197
+ "kernel_size": 5,
198
+ "n_groups": 8,
199
+ "diffusion_step_embed_dim": 128,
200
+ "use_film_scale_modulation": true,
201
+ "noise_scheduler_type": "DDPM",
202
+ "num_train_timesteps": 100,
203
+ "beta_schedule": "squaredcos_cap_v2",
204
+ "beta_start": 0.0001,
205
+ "beta_end": 0.02,
206
+ "prediction_type": "epsilon",
207
+ "clip_sample": true,
208
+ "clip_sample_range": 1.0,
209
+ "num_inference_steps": null,
210
+ "compile_model": false,
211
+ "compile_mode": "reduce-overhead",
212
+ "do_mask_loss_for_padding": false,
213
+ "optimizer_lr": 0.0001,
214
+ "optimizer_betas": [
215
+ 0.95,
216
+ 0.999
217
+ ],
218
+ "optimizer_eps": 1e-08,
219
+ "optimizer_weight_decay": 1e-06,
220
+ "scheduler_name": "cosine",
221
+ "scheduler_warmup_steps": 500
222
+ },
223
+ "output_dir": "outputs/train/bimanual_diffusion",
224
+ "job_name": "bimanual_diffusion",
225
+ "resume": false,
226
+ "seed": 1000,
227
+ "cudnn_deterministic": false,
228
+ "num_workers": 8,
229
+ "batch_size": 12,
230
+ "steps": 20000,
231
+ "eval_freq": 20000,
232
+ "log_freq": 100,
233
+ "tolerance_s": 0.0001,
234
+ "save_checkpoint": true,
235
+ "save_freq": 5000,
236
+ "use_policy_training_preset": true,
237
+ "optimizer": {
238
+ "type": "adam",
239
+ "lr": 0.0001,
240
+ "weight_decay": 1e-06,
241
+ "grad_clip_norm": 10.0,
242
+ "betas": [
243
+ 0.95,
244
+ 0.999
245
+ ],
246
+ "eps": 1e-08
247
+ },
248
+ "scheduler": {
249
+ "type": "diffuser",
250
+ "num_warmup_steps": 500,
251
+ "name": "cosine"
252
+ },
253
+ "eval": {
254
+ "n_episodes": 50,
255
+ "batch_size": 50,
256
+ "use_async_envs": false
257
+ },
258
+ "wandb": {
259
+ "enable": false,
260
+ "disable_artifact": false,
261
+ "project": "lerobot",
262
+ "entity": null,
263
+ "notes": null,
264
+ "run_id": null,
265
+ "mode": null,
266
+ "add_tags": true
267
+ },
268
+ "peft": null,
269
+ "use_rabc": false,
270
+ "rabc_progress_path": null,
271
+ "rabc_kappa": 0.01,
272
+ "rabc_epsilon": 1e-06,
273
+ "rabc_head_mode": "sparse",
274
+ "rename_map": {},
275
+ "checkpoint_path": null
276
+ }