mad-bot commited on
Commit
6e70cb1
·
verified ·
1 Parent(s): e9e70a9

Use the YouTube cut as replay, add config.json for download tracking, from_hub usage

Browse files
Files changed (3) hide show
  1. README.md +4 -9
  2. config.json +156 -0
  3. replay.mp4 +2 -2
README.md CHANGED
@@ -26,6 +26,7 @@ In one sentence: 4 frames × 41 frozen DINOv3 tokens → a 6-layer 384-d transfo
26
 
27
  - `cortex_quake_bc.pt` — release checkpoint (fp32, 43.9 MB): model weights, architecture arguments, and the embedded action schema. The frozen DINOv3 encoder (28.7M parameters, ≈39.7M total executed per decision) is **not** included; it downloads separately from Meta under its own license.
28
  - `replay.mp4` — a recorded episode of this checkpoint playing E1M1 (rendered in the Video Preview panel).
 
29
 
30
  ## Usage
31
 
@@ -34,15 +35,9 @@ pip install git+https://github.com/kvark/cortex-actor
34
  ```
35
 
36
  ```python
37
- import torch
38
- from huggingface_hub import hf_hub_download
39
- from cortex_actor import cortex_from_args
40
-
41
- path = hf_hub_download("mad-bot/cortex", "cortex_quake_bc.pt")
42
- ck = torch.load(path, map_location="cpu", weights_only=False)
43
- model = cortex_from_args(ck["args_dict"])
44
- model.load_state_dict(ck["model"])
45
- model.eval()
46
 
47
  # Per step: cls (B, T, 384) and patches (B, T, 5, 8, 384) from frozen
48
  # DINOv3 ViT-S+/16 at 640x400, T = 4 most recent frames at 10 Hz.
 
26
 
27
  - `cortex_quake_bc.pt` — release checkpoint (fp32, 43.9 MB): model weights, architecture arguments, and the embedded action schema. The frozen DINOv3 encoder (28.7M parameters, ≈39.7M total executed per decision) is **not** included; it downloads separately from Meta under its own license.
28
  - `replay.mp4` — a recorded episode of this checkpoint playing E1M1 (rendered in the Video Preview panel).
29
+ - `config.json` — machine-readable architecture arguments and action schema (mirrors what the checkpoint stores).
30
 
31
  ## Usage
32
 
 
35
  ```
36
 
37
  ```python
38
+ from cortex_actor import from_hub
39
+
40
+ model, ck = from_hub("mad-bot/cortex")
 
 
 
 
 
 
41
 
42
  # Per step: cls (B, T, 384) and patches (B, T, 5, 8, 384) from frozen
43
  # DINOv3 ViT-S+/16 at 640x400, T = 4 most recent frames at 10 Hz.
config.json ADDED
@@ -0,0 +1,156 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "model_type": "cortex",
3
+ "schema_version": 3,
4
+ "step": 30000,
5
+ "args": {
6
+ "game": "quake",
7
+ "steps": 32320,
8
+ "epochs": 1,
9
+ "batch_size": 16,
10
+ "seq_len": 4,
11
+ "windows_per_chunk": 4,
12
+ "ego_k": 16,
13
+ "ego_horizon": 50,
14
+ "ego_log_spaced": false,
15
+ "no_ego": true,
16
+ "ego_pos_scale": 5.0,
17
+ "d_model": 384,
18
+ "n_layers": 6,
19
+ "n_heads": 6,
20
+ "lr": 0.0003,
21
+ "mouse_scale": 1.0,
22
+ "num_workers": 8,
23
+ "val_workers": 4,
24
+ "shard_buffer_size": 32,
25
+ "seed": 0,
26
+ "ckpt_every": 2500,
27
+ "log_every": 50,
28
+ "val_frac": 0.05,
29
+ "val_every": 2500,
30
+ "val_batches": 20,
31
+ "motion_weight": false,
32
+ "mouse_loss_weight": 2.0,
33
+ "held_transition_weight": 0.0,
34
+ "tap_events": false,
35
+ "tap_loss_weight": 1.0,
36
+ "tap_positive_weight_cap": 100.0,
37
+ "mouse_loss_beta": 0.1,
38
+ "mouse_mode": "regress",
39
+ "mouse_n_bins": 9,
40
+ "chunk_codes": 64,
41
+ "vision_tokens": "patches",
42
+ "target_advance_ms": 100,
43
+ "yaw_aux_weight": 0.0,
44
+ "future_yaw_weight": 0.0,
45
+ "future_yaw_horizon": 10,
46
+ "motion_input": false,
47
+ "action_context": false,
48
+ "action_persistence_skip": false,
49
+ "init_checkpoint": null,
50
+ "patch_grid": [
51
+ 5,
52
+ 8
53
+ ],
54
+ "data_horizon": 1,
55
+ "require_future_pose": false
56
+ },
57
+ "action_schema": {
58
+ "game": "quake",
59
+ "keys": [
60
+ "w",
61
+ "a",
62
+ "s",
63
+ "d",
64
+ "space"
65
+ ],
66
+ "mouse_dx": true,
67
+ "mouse_dy": true,
68
+ "mouse_buttons": [
69
+ 1
70
+ ],
71
+ "held_names": [
72
+ "w",
73
+ "a",
74
+ "s",
75
+ "d",
76
+ "Up",
77
+ "Down",
78
+ "Left",
79
+ "Right",
80
+ "space",
81
+ "Shift_L",
82
+ "Control_L",
83
+ "Alt_L",
84
+ "Tab",
85
+ "Escape",
86
+ "Return",
87
+ "e",
88
+ "f",
89
+ "g",
90
+ "q",
91
+ "r",
92
+ "t",
93
+ "1",
94
+ "2",
95
+ "3",
96
+ "4",
97
+ "5",
98
+ "6",
99
+ "7",
100
+ "8",
101
+ "9",
102
+ "0",
103
+ "Delete",
104
+ "F12",
105
+ "mouse_1",
106
+ "mouse_2",
107
+ "mouse_3"
108
+ ],
109
+ "active_held": [
110
+ true,
111
+ true,
112
+ true,
113
+ true,
114
+ false,
115
+ false,
116
+ false,
117
+ false,
118
+ true,
119
+ false,
120
+ false,
121
+ false,
122
+ false,
123
+ false,
124
+ false,
125
+ false,
126
+ false,
127
+ false,
128
+ false,
129
+ false,
130
+ false,
131
+ false,
132
+ false,
133
+ false,
134
+ false,
135
+ false,
136
+ false,
137
+ false,
138
+ false,
139
+ false,
140
+ false,
141
+ false,
142
+ false,
143
+ true,
144
+ false,
145
+ false
146
+ ],
147
+ "previous_held_context": false,
148
+ "previous_held_skip": false,
149
+ "transient_taps": false,
150
+ "training_alignment": {
151
+ "source_stride": 2,
152
+ "source_fps": 20,
153
+ "observation_to_action_offset": 1
154
+ }
155
+ }
156
+ }
replay.mp4 CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:ae68d08d6bb8facac3d570b409ad5ebcd7984dafc566ee2efc655d40a9060463
3
- size 21394993
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c4f142651c1008d205c307a6ec6b5f467ab17758197f00af32285cf0ff373253
3
+ size 17135374