Update convert.py
Browse files- convert.py +18 -14
convert.py
CHANGED
|
@@ -2,20 +2,24 @@
|
|
| 2 |
`trust_remote_code` model directory, re-sizing (and re-initializing) the
|
| 3 |
embedding + lm-head to the OLMo tokenizer vocabulary.
|
| 4 |
"""
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 19 |
import os
|
| 20 |
import sys
|
| 21 |
import math
|
|
|
|
| 2 |
`trust_remote_code` model directory, re-sizing (and re-initializing) the
|
| 3 |
embedding + lm-head to the OLMo tokenizer vocabulary.
|
| 4 |
"""
|
| 5 |
+
"""Convert the BlinkDL rwkv7-g1d-0.1b .pth checkpoint into a HuggingFace
|
| 6 |
+
`trust_remote_code` model directory, re-sizing (and re-initializing) the
|
| 7 |
+
embedding + lm-head to the OLMo tokenizer vocabulary.
|
| 8 |
+
"""
|
| 9 |
+
"""
|
| 10 |
+
from huggingface_hub import snapshot_download
|
| 11 |
+
|
| 12 |
+
snapshot_download(
|
| 13 |
+
repo_id="allenai/Olmo-3-1025-7B",
|
| 14 |
+
local_dir="./olmo",
|
| 15 |
+
ignore_patterns=[
|
| 16 |
+
"*.bin",
|
| 17 |
+
"*.safetensors",
|
| 18 |
+
"*.pt",
|
| 19 |
+
"*.ckpt",
|
| 20 |
+
],
|
| 21 |
+
)
|
| 22 |
+
"""
|
| 23 |
import os
|
| 24 |
import sys
|
| 25 |
import math
|