Robotics
LeRobot
Safetensors
diffusion
cagedBirdy commited on
Commit
2dd80a9
·
verified ·
1 Parent(s): bc09a7d

Upload policy weights, train config and readme

Browse files
Files changed (4) hide show
  1. README.md +62 -0
  2. config.json +101 -0
  3. model.safetensors +3 -0
  4. train_config.json +237 -0
README.md ADDED
@@ -0,0 +1,62 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ datasets: radoolonto/angled_peg_05_21_tip_ref
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,101 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "type": "diffusion",
3
+ "n_obs_steps": 4,
4
+ "input_features": {
5
+ "observation.image.cam0": {
6
+ "type": "VISUAL",
7
+ "shape": [
8
+ 3,
9
+ 240,
10
+ 320
11
+ ]
12
+ },
13
+ "observation.image.cam1": {
14
+ "type": "VISUAL",
15
+ "shape": [
16
+ 3,
17
+ 240,
18
+ 320
19
+ ]
20
+ },
21
+ "observation.state": {
22
+ "type": "STATE",
23
+ "shape": [
24
+ 3
25
+ ]
26
+ }
27
+ },
28
+ "output_features": {
29
+ "action": {
30
+ "type": "ACTION",
31
+ "shape": [
32
+ 10
33
+ ]
34
+ }
35
+ },
36
+ "device": "cuda",
37
+ "use_amp": false,
38
+ "use_peft": false,
39
+ "push_to_hub": true,
40
+ "repo_id": "cagedBirdy/angled_peg_05_21_tip_ref_4",
41
+ "private": null,
42
+ "tags": null,
43
+ "license": null,
44
+ "pretrained_path": null,
45
+ "horizon": 16,
46
+ "n_action_steps": 8,
47
+ "normalization_mapping": {
48
+ "VISUAL": "MEAN_STD",
49
+ "STATE": "MIN_MAX",
50
+ "ACTION": "MIN_MAX"
51
+ },
52
+ "drop_n_last_frames": 7,
53
+ "vision_backbone": "resnet18",
54
+ "resize_shape": null,
55
+ "crop_ratio": 1.0,
56
+ "crop_shape": [
57
+ 216,
58
+ 288
59
+ ],
60
+ "crop_is_random": true,
61
+ "pretrained_backbone_weights": null,
62
+ "use_group_norm": true,
63
+ "spatial_softmax_num_keypoints": 32,
64
+ "use_separate_rgb_encoder_per_camera": true,
65
+ "use_vit_encoder": true,
66
+ "use_multi_camera_shared_vit": false,
67
+ "vit_embed_dim": 512,
68
+ "vit_depth": 6,
69
+ "vit_num_heads": 8,
70
+ "vit_dropout": 0.1,
71
+ "down_dims": [
72
+ 512,
73
+ 1024,
74
+ 2048
75
+ ],
76
+ "kernel_size": 5,
77
+ "n_groups": 8,
78
+ "diffusion_step_embed_dim": 128,
79
+ "use_film_scale_modulation": true,
80
+ "noise_scheduler_type": "DDPM",
81
+ "num_train_timesteps": 100,
82
+ "beta_schedule": "squaredcos_cap_v2",
83
+ "beta_start": 0.0001,
84
+ "beta_end": 0.02,
85
+ "prediction_type": "epsilon",
86
+ "clip_sample": true,
87
+ "clip_sample_range": 1.0,
88
+ "num_inference_steps": 8,
89
+ "compile_model": false,
90
+ "compile_mode": "reduce-overhead",
91
+ "do_mask_loss_for_padding": false,
92
+ "optimizer_lr": 0.0001,
93
+ "optimizer_betas": [
94
+ 0.95,
95
+ 0.999
96
+ ],
97
+ "optimizer_eps": 1e-08,
98
+ "optimizer_weight_decay": 1e-06,
99
+ "scheduler_name": "cosine",
100
+ "scheduler_warmup_steps": 500
101
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e86d955cba924d06fb0afe41f8474e04430c77ea5fe0e90603ac4cf8bedf8f8f
3
+ size 1703205720
train_config.json ADDED
@@ -0,0 +1,237 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "dataset": {
3
+ "repo_id": "radoolonto/angled_peg_05_21_tip_ref",
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.7,
17
+ 1.3
18
+ ]
19
+ }
20
+ },
21
+ "contrast": {
22
+ "weight": 1.0,
23
+ "type": "ColorJitter",
24
+ "kwargs": {
25
+ "contrast": [
26
+ 0.6,
27
+ 1.4
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
+ "return_uint8": false,
81
+ "streaming": false
82
+ },
83
+ "env": null,
84
+ "policy": {
85
+ "type": "diffusion",
86
+ "n_obs_steps": 4,
87
+ "input_features": {
88
+ "observation.image.cam0": {
89
+ "type": "VISUAL",
90
+ "shape": [
91
+ 3,
92
+ 240,
93
+ 320
94
+ ]
95
+ },
96
+ "observation.image.cam1": {
97
+ "type": "VISUAL",
98
+ "shape": [
99
+ 3,
100
+ 240,
101
+ 320
102
+ ]
103
+ },
104
+ "observation.state": {
105
+ "type": "STATE",
106
+ "shape": [
107
+ 3
108
+ ]
109
+ }
110
+ },
111
+ "output_features": {
112
+ "action": {
113
+ "type": "ACTION",
114
+ "shape": [
115
+ 10
116
+ ]
117
+ }
118
+ },
119
+ "device": "cuda",
120
+ "use_amp": false,
121
+ "use_peft": false,
122
+ "push_to_hub": true,
123
+ "repo_id": "cagedBirdy/angled_peg_05_21_tip_ref_4",
124
+ "private": null,
125
+ "tags": null,
126
+ "license": null,
127
+ "pretrained_path": null,
128
+ "horizon": 16,
129
+ "n_action_steps": 8,
130
+ "normalization_mapping": {
131
+ "VISUAL": "MEAN_STD",
132
+ "STATE": "MIN_MAX",
133
+ "ACTION": "MIN_MAX"
134
+ },
135
+ "drop_n_last_frames": 7,
136
+ "vision_backbone": "resnet18",
137
+ "resize_shape": null,
138
+ "crop_ratio": 1.0,
139
+ "crop_shape": [
140
+ 216,
141
+ 288
142
+ ],
143
+ "crop_is_random": true,
144
+ "pretrained_backbone_weights": null,
145
+ "use_group_norm": true,
146
+ "spatial_softmax_num_keypoints": 32,
147
+ "use_separate_rgb_encoder_per_camera": true,
148
+ "use_vit_encoder": true,
149
+ "use_multi_camera_shared_vit": false,
150
+ "vit_embed_dim": 512,
151
+ "vit_depth": 6,
152
+ "vit_num_heads": 8,
153
+ "vit_dropout": 0.1,
154
+ "down_dims": [
155
+ 512,
156
+ 1024,
157
+ 2048
158
+ ],
159
+ "kernel_size": 5,
160
+ "n_groups": 8,
161
+ "diffusion_step_embed_dim": 128,
162
+ "use_film_scale_modulation": true,
163
+ "noise_scheduler_type": "DDPM",
164
+ "num_train_timesteps": 100,
165
+ "beta_schedule": "squaredcos_cap_v2",
166
+ "beta_start": 0.0001,
167
+ "beta_end": 0.02,
168
+ "prediction_type": "epsilon",
169
+ "clip_sample": true,
170
+ "clip_sample_range": 1.0,
171
+ "num_inference_steps": 8,
172
+ "compile_model": false,
173
+ "compile_mode": "reduce-overhead",
174
+ "do_mask_loss_for_padding": false,
175
+ "optimizer_lr": 0.0001,
176
+ "optimizer_betas": [
177
+ 0.95,
178
+ 0.999
179
+ ],
180
+ "optimizer_eps": 1e-08,
181
+ "optimizer_weight_decay": 1e-06,
182
+ "scheduler_name": "cosine",
183
+ "scheduler_warmup_steps": 500
184
+ },
185
+ "reward_model": null,
186
+ "output_dir": "/scratch/nirmal/franka_toolbox/medcvr-il/runs/41375355/checkpoints",
187
+ "job_name": "cagedBirdy/angle_peg_transfer_05_21_cam01",
188
+ "resume": false,
189
+ "seed": 1000,
190
+ "cudnn_deterministic": false,
191
+ "num_workers": 8,
192
+ "batch_size": 32,
193
+ "prefetch_factor": 4,
194
+ "persistent_workers": true,
195
+ "steps": 100000,
196
+ "eval_freq": 20000,
197
+ "log_freq": 200,
198
+ "tolerance_s": 0.0001,
199
+ "save_checkpoint": true,
200
+ "save_freq": 20000,
201
+ "use_policy_training_preset": true,
202
+ "optimizer": {
203
+ "type": "adam",
204
+ "lr": 0.0001,
205
+ "weight_decay": 1e-06,
206
+ "grad_clip_norm": 10.0,
207
+ "betas": [
208
+ 0.95,
209
+ 0.999
210
+ ],
211
+ "eps": 1e-08
212
+ },
213
+ "scheduler": {
214
+ "type": "diffuser",
215
+ "num_warmup_steps": 500,
216
+ "name": "cosine"
217
+ },
218
+ "eval": {
219
+ "n_episodes": 50,
220
+ "batch_size": 33,
221
+ "use_async_envs": true
222
+ },
223
+ "wandb": {
224
+ "enable": true,
225
+ "disable_artifact": false,
226
+ "project": "nirmal_peg_05_07_08",
227
+ "entity": "nirmalpol2012-university-of-toronto",
228
+ "notes": null,
229
+ "run_id": "owq3alfq",
230
+ "mode": null,
231
+ "add_tags": true
232
+ },
233
+ "peft": null,
234
+ "sample_weighting": null,
235
+ "rename_map": {},
236
+ "checkpoint_path": null
237
+ }