Upload folder using huggingface_hub
Browse files
README.md
CHANGED
|
@@ -1,20 +1,40 @@
|
|
| 1 |
---
|
| 2 |
library_name: pytorch
|
| 3 |
license: apache-2.0
|
| 4 |
-
model_name: space-invaders-world-model
|
| 5 |
tags:
|
| 6 |
- world-model
|
| 7 |
- diffusion
|
| 8 |
- atari
|
| 9 |
- space-invaders
|
| 10 |
- video-generation
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 11 |
---
|
| 12 |
|
| 13 |
# space-invaders-world-model
|
| 14 |
|
| 15 |
A diffusion world model of Atari Space Invaders, trained from scratch. Given the last 4 frames and actions, a small U-Net denoises the next 64×64 frame; fed its own frames, it generates a video that your actions steer. After [DIAMOND](https://arxiv.org/abs/2405.12399). `atari.py` in this repo collects the data, trains, plays and doubles as the loader.
|
| 16 |
|
|
|
|
| 17 |
|
|
|
|
| 18 |
|
| 19 |
## 🚀 Usage
|
| 20 |
|
|
@@ -41,13 +61,24 @@ Actions: 0 NOOP, 1 FIRE, 2 RIGHT, 3 LEFT, 4 RIGHTFIRE, 5 LEFTFIRE.
|
|
| 41 |
|
| 42 |
## 🏋️ Training
|
| 43 |
|
| 44 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 45 |
|
| 46 |
## 📊 Results
|
| 47 |
|
| 48 |
-
Rollouts on
|
| 49 |
|
| 50 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 51 |
|
| 52 |
## ⚠️ Limitations
|
| 53 |
|
|
|
|
| 1 |
---
|
| 2 |
library_name: pytorch
|
| 3 |
license: apache-2.0
|
|
|
|
| 4 |
tags:
|
| 5 |
- world-model
|
| 6 |
- diffusion
|
| 7 |
- atari
|
| 8 |
- space-invaders
|
| 9 |
- video-generation
|
| 10 |
+
model-index:
|
| 11 |
+
- name: space-invaders-world-model
|
| 12 |
+
results:
|
| 13 |
+
- task:
|
| 14 |
+
type: other
|
| 15 |
+
name: Next-frame rollout
|
| 16 |
+
dataset:
|
| 17 |
+
name: Space Invaders, held-out random play
|
| 18 |
+
type: ale/space-invaders
|
| 19 |
+
metrics:
|
| 20 |
+
- type: psnr_changed_1
|
| 21 |
+
value: 18.17
|
| 22 |
+
name: PSNR on changed pixels at 1 frames
|
| 23 |
+
- type: psnr_changed_5
|
| 24 |
+
value: 18.35
|
| 25 |
+
name: PSNR on changed pixels at 5 frames
|
| 26 |
+
- type: psnr_changed_15
|
| 27 |
+
value: 16.64
|
| 28 |
+
name: PSNR on changed pixels at 15 frames
|
| 29 |
---
|
| 30 |
|
| 31 |
# space-invaders-world-model
|
| 32 |
|
| 33 |
A diffusion world model of Atari Space Invaders, trained from scratch. Given the last 4 frames and actions, a small U-Net denoises the next 64×64 frame; fed its own frames, it generates a video that your actions steer. After [DIAMOND](https://arxiv.org/abs/2405.12399). `atari.py` in this repo collects the data, trains, plays and doubles as the loader.
|
| 34 |
|
| 35 |
+

|
| 36 |
|
| 37 |
+
Left: real game. Right: the model, from the same four starting frames and the same actions, never seeing a real frame again.
|
| 38 |
|
| 39 |
## 🚀 Usage
|
| 40 |
|
|
|
|
| 61 |
|
| 62 |
## 🏋️ Training
|
| 63 |
|
| 64 |
+
| | |
|
| 65 |
+
|---|---|
|
| 66 |
+
| Model | U-Net, channels 64, 128, 256, 4.2M parameters; noise level and the last 4 actions modulate every block |
|
| 67 |
+
| Diffusion | EDM preconditioning, σ_data 0.5, log-normal training noise; 3 Euler steps per frame from σ=5.0 |
|
| 68 |
+
| Data | 200,000 frames (382 episodes) of a random policy that holds each uniformly random action for 1 to 6 steps; frameskip 4, no sticky actions |
|
| 69 |
+
| Steps | 50,000, batch size 64 |
|
| 70 |
+
| Optimizer | AdamW, lr 0.0001, gradient clipping 1.0 |
|
| 71 |
+
| Hardware | NVIDIA A10G, 55.9 min |
|
| 72 |
|
| 73 |
## 📊 Results
|
| 74 |
|
| 75 |
+
Rollouts on 256 windows from episodes whose seeds never appear in training. The model gets four real frames and the real actions, then only its own frames. **Repeat** keeps showing the last real frame. Much of an Atari frame never changes, so **changed pixels** scores only the pixels where the real or the predicted frame differs from the last real frame.
|
| 76 |
|
| 77 |
+
| Frames ahead | Model, all pixels (dB) | Repeat, all pixels (dB) | Model, changed pixels (dB) | Repeat, changed pixels (dB) |
|
| 78 |
+
|---|---|---|---|---|
|
| 79 |
+
| 1 | 35.43 | 36.56 | 18.17 | 16.0 |
|
| 80 |
+
| 5 | 31.07 | 30.94 | 18.35 | 15.9 |
|
| 81 |
+
| 15 | 27.33 | 26.77 | 16.64 | 14.54 |
|
| 82 |
|
| 83 |
## ⚠️ Limitations
|
| 84 |
|