README: plain phrasing
Browse files
README.md
CHANGED
|
@@ -18,18 +18,16 @@ Precomputed [UMT5-XXL](https://huggingface.co/google/umt5-xxl) text embeddings f
|
|
| 18 |
([`flex-pi/robotwin_3d`](https://huggingface.co/datasets/flex-pi/robotwin_3d)), as consumed by
|
| 19 |
Wan2.2-TI2V-5B / FastWAM. Precomputing these costs substantial GPU time; this cache skips it.
|
| 20 |
|
| 21 |
-
##
|
| 22 |
|
| 23 |
-
Task strings from `meta/tasks.jsonl` are wrapped in a fixed template before encoding
|
| 24 |
-
|
| 25 |
|
| 26 |
```python
|
| 27 |
DEFAULT_PROMPT = "A video recorded from a robot's point of view executing the following instruction: {task}"
|
| 28 |
key = hashlib.sha256(DEFAULT_PROMPT.format(task=task).encode("utf-8")).hexdigest()
|
| 29 |
```
|
| 30 |
|
| 31 |
-
Worked example:
|
| 32 |
-
|
| 33 |
| | |
|
| 34 |
|---|---|
|
| 35 |
| task | `Lift the medium-sized green bottle ensuring it remains upright.` |
|
|
@@ -51,14 +49,14 @@ keys in row order):
|
|
| 51 |
| `contexts` | `[N, 128, 4096]` | `bfloat16` |
|
| 52 |
| `masks` | `[N, 128]` | `bool` |
|
| 53 |
|
| 54 |
-
`masks` marks valid tokens (mean 40.9 of 128). Values past the mask are
|
| 55 |
-
|
| 56 |
-
|
| 57 |
|
| 58 |
## Converting back to the per-file `.pt` layout
|
| 59 |
|
| 60 |
FastWAM reads a flat directory of `{key}.t5_len128.wan22ti2v5b.pt` files, each a `{"context", "mask"}`
|
| 61 |
-
dict
|
| 62 |
|
| 63 |
```python
|
| 64 |
# unpack_to_pt.py -- rebuild the flat .pt cache from the sharded release.
|
|
|
|
| 18 |
([`flex-pi/robotwin_3d`](https://huggingface.co/datasets/flex-pi/robotwin_3d)), as consumed by
|
| 19 |
Wan2.2-TI2V-5B / FastWAM. Precomputing these costs substantial GPU time; this cache skips it.
|
| 20 |
|
| 21 |
+
## Cache key
|
| 22 |
|
| 23 |
+
Task strings from `meta/tasks.jsonl` are wrapped in a fixed template before encoding, and the cache
|
| 24 |
+
key is the sha256 of that templated prompt:
|
| 25 |
|
| 26 |
```python
|
| 27 |
DEFAULT_PROMPT = "A video recorded from a robot's point of view executing the following instruction: {task}"
|
| 28 |
key = hashlib.sha256(DEFAULT_PROMPT.format(task=task).encode("utf-8")).hexdigest()
|
| 29 |
```
|
| 30 |
|
|
|
|
|
|
|
| 31 |
| | |
|
| 32 |
|---|---|
|
| 33 |
| task | `Lift the medium-sized green bottle ensuring it remains upright.` |
|
|
|
|
| 49 |
| `contexts` | `[N, 128, 4096]` | `bfloat16` |
|
| 50 |
| `masks` | `[N, 128]` | `bool` |
|
| 51 |
|
| 52 |
+
`masks` marks valid tokens (mean 40.9 of 128). Values past the mask are raw T5 outputs rather than
|
| 53 |
+
zeros. FastWAM zeroes them on load (`context[~mask] = 0`); do the same if your model does not apply
|
| 54 |
+
the mask.
|
| 55 |
|
| 56 |
## Converting back to the per-file `.pt` layout
|
| 57 |
|
| 58 |
FastWAM reads a flat directory of `{key}.t5_len128.wan22ti2v5b.pt` files, each a `{"context", "mask"}`
|
| 59 |
+
dict, rather than shards. This script reconstructs that layout:
|
| 60 |
|
| 61 |
```python
|
| 62 |
# unpack_to_pt.py -- rebuild the flat .pt cache from the sharded release.
|