gffj
/

Robotics
LeRobot
Safetensors
diffusion
gffj commited on
Commit
5304e4b
·
verified ·
1 Parent(s): 5b5d3a4

Upload policy weights, train config and readme

Browse files
Files changed (4) hide show
  1. README.md +62 -0
  2. config.json +81 -0
  3. model.safetensors +3 -0
  4. train_config.json +228 -0
README.md ADDED
@@ -0,0 +1,62 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ datasets: lerobot/pusht
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
+ python -m lerobot.scripts.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
+ python -m 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,81 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "type": "diffusion",
3
+ "n_obs_steps": 2,
4
+ "normalization_mapping": {
5
+ "VISUAL": "MEAN_STD",
6
+ "STATE": "MIN_MAX",
7
+ "ACTION": "MIN_MAX"
8
+ },
9
+ "input_features": {
10
+ "observation.image": {
11
+ "type": "VISUAL",
12
+ "shape": [
13
+ 3,
14
+ 96,
15
+ 96
16
+ ]
17
+ },
18
+ "observation.state": {
19
+ "type": "STATE",
20
+ "shape": [
21
+ 2
22
+ ]
23
+ }
24
+ },
25
+ "output_features": {
26
+ "action": {
27
+ "type": "ACTION",
28
+ "shape": [
29
+ 2
30
+ ]
31
+ }
32
+ },
33
+ "device": "cuda",
34
+ "use_amp": false,
35
+ "push_to_hub": true,
36
+ "repo_id": "gffj/tset1",
37
+ "private": null,
38
+ "tags": null,
39
+ "license": null,
40
+ "horizon": 16,
41
+ "n_action_steps": 8,
42
+ "drop_n_last_frames": 7,
43
+ "vision_backbone": "resnet18",
44
+ "crop_shape": [
45
+ 84,
46
+ 84
47
+ ],
48
+ "crop_is_random": true,
49
+ "pretrained_backbone_weights": null,
50
+ "use_group_norm": true,
51
+ "spatial_softmax_num_keypoints": 32,
52
+ "use_separate_rgb_encoder_per_camera": false,
53
+ "down_dims": [
54
+ 512,
55
+ 1024,
56
+ 2048
57
+ ],
58
+ "kernel_size": 5,
59
+ "n_groups": 8,
60
+ "diffusion_step_embed_dim": 128,
61
+ "use_film_scale_modulation": true,
62
+ "noise_scheduler_type": "DDPM",
63
+ "num_train_timesteps": 100,
64
+ "beta_schedule": "squaredcos_cap_v2",
65
+ "beta_start": 0.0001,
66
+ "beta_end": 0.02,
67
+ "prediction_type": "epsilon",
68
+ "clip_sample": true,
69
+ "clip_sample_range": 1.0,
70
+ "num_inference_steps": null,
71
+ "do_mask_loss_for_padding": false,
72
+ "optimizer_lr": 0.0001,
73
+ "optimizer_betas": [
74
+ 0.95,
75
+ 0.999
76
+ ],
77
+ "optimizer_eps": 1e-08,
78
+ "optimizer_weight_decay": 1e-06,
79
+ "scheduler_name": "cosine",
80
+ "scheduler_warmup_steps": 500
81
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4134a16880729a38ade980631f0b634f31d2c008580b12ade4860d14a92608b8
3
+ size 1050862408
train_config.json ADDED
@@ -0,0 +1,228 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "dataset": {
3
+ "repo_id": "lerobot/pusht",
4
+ "root": null,
5
+ "episodes": null,
6
+ "image_transforms": {
7
+ "enable": false,
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
+ }
62
+ },
63
+ "revision": null,
64
+ "use_imagenet_stats": true,
65
+ "video_backend": "pyav"
66
+ },
67
+ "env": {
68
+ "type": "pusht",
69
+ "task": "PushT-v0",
70
+ "fps": 10,
71
+ "features": {
72
+ "action": {
73
+ "type": "ACTION",
74
+ "shape": [
75
+ 2
76
+ ]
77
+ },
78
+ "agent_pos": {
79
+ "type": "STATE",
80
+ "shape": [
81
+ 2
82
+ ]
83
+ },
84
+ "pixels": {
85
+ "type": "VISUAL",
86
+ "shape": [
87
+ 384,
88
+ 384,
89
+ 3
90
+ ]
91
+ }
92
+ },
93
+ "features_map": {
94
+ "action": "action",
95
+ "agent_pos": "observation.state",
96
+ "environment_state": "observation.environment_state",
97
+ "pixels": "observation.image"
98
+ },
99
+ "episode_length": 300,
100
+ "obs_type": "pixels_agent_pos",
101
+ "render_mode": "rgb_array",
102
+ "visualization_width": 384,
103
+ "visualization_height": 384
104
+ },
105
+ "policy": {
106
+ "type": "diffusion",
107
+ "n_obs_steps": 2,
108
+ "normalization_mapping": {
109
+ "VISUAL": "MEAN_STD",
110
+ "STATE": "MIN_MAX",
111
+ "ACTION": "MIN_MAX"
112
+ },
113
+ "input_features": {
114
+ "observation.image": {
115
+ "type": "VISUAL",
116
+ "shape": [
117
+ 3,
118
+ 96,
119
+ 96
120
+ ]
121
+ },
122
+ "observation.state": {
123
+ "type": "STATE",
124
+ "shape": [
125
+ 2
126
+ ]
127
+ }
128
+ },
129
+ "output_features": {
130
+ "action": {
131
+ "type": "ACTION",
132
+ "shape": [
133
+ 2
134
+ ]
135
+ }
136
+ },
137
+ "device": "cuda",
138
+ "use_amp": false,
139
+ "push_to_hub": true,
140
+ "repo_id": "gffj/tset1",
141
+ "private": null,
142
+ "tags": null,
143
+ "license": null,
144
+ "horizon": 16,
145
+ "n_action_steps": 8,
146
+ "drop_n_last_frames": 7,
147
+ "vision_backbone": "resnet18",
148
+ "crop_shape": [
149
+ 84,
150
+ 84
151
+ ],
152
+ "crop_is_random": true,
153
+ "pretrained_backbone_weights": null,
154
+ "use_group_norm": true,
155
+ "spatial_softmax_num_keypoints": 32,
156
+ "use_separate_rgb_encoder_per_camera": false,
157
+ "down_dims": [
158
+ 512,
159
+ 1024,
160
+ 2048
161
+ ],
162
+ "kernel_size": 5,
163
+ "n_groups": 8,
164
+ "diffusion_step_embed_dim": 128,
165
+ "use_film_scale_modulation": true,
166
+ "noise_scheduler_type": "DDPM",
167
+ "num_train_timesteps": 100,
168
+ "beta_schedule": "squaredcos_cap_v2",
169
+ "beta_start": 0.0001,
170
+ "beta_end": 0.02,
171
+ "prediction_type": "epsilon",
172
+ "clip_sample": true,
173
+ "clip_sample_range": 1.0,
174
+ "num_inference_steps": null,
175
+ "do_mask_loss_for_padding": false,
176
+ "optimizer_lr": 0.0001,
177
+ "optimizer_betas": [
178
+ 0.95,
179
+ 0.999
180
+ ],
181
+ "optimizer_eps": 1e-08,
182
+ "optimizer_weight_decay": 1e-06,
183
+ "scheduler_name": "cosine",
184
+ "scheduler_warmup_steps": 500
185
+ },
186
+ "output_dir": "outputs/train/2025-01-17/11-51-15_pusht_diffusion",
187
+ "job_name": "pusht_diffusion",
188
+ "resume": false,
189
+ "seed": 100000,
190
+ "num_workers": 4,
191
+ "batch_size": 64,
192
+ "steps": 1000,
193
+ "eval_freq": 50000,
194
+ "log_freq": 200,
195
+ "save_checkpoint": true,
196
+ "save_freq": 25000,
197
+ "use_policy_training_preset": true,
198
+ "optimizer": {
199
+ "type": "adam",
200
+ "lr": 0.0001,
201
+ "weight_decay": 1e-06,
202
+ "grad_clip_norm": 10.0,
203
+ "betas": [
204
+ 0.95,
205
+ 0.999
206
+ ],
207
+ "eps": 1e-08
208
+ },
209
+ "scheduler": {
210
+ "type": "diffuser",
211
+ "num_warmup_steps": 500,
212
+ "name": "cosine"
213
+ },
214
+ "eval": {
215
+ "n_episodes": 50,
216
+ "batch_size": 50,
217
+ "use_async_envs": false
218
+ },
219
+ "wandb": {
220
+ "enable": false,
221
+ "disable_artifact": false,
222
+ "project": "lerobot",
223
+ "entity": null,
224
+ "notes": null,
225
+ "run_id": null,
226
+ "mode": null
227
+ }
228
+ }