-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathOLMo-1B.yaml
More file actions
223 lines (179 loc) · 5.54 KB
/
OLMo-1B.yaml
File metadata and controls
223 lines (179 loc) · 5.54 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
run_name: OLMo-1B-dolma2-tokenizer-wiki_${oc.env:TIME}
seed: 6198
dry_run: false
wandb:
name: ${run_name}
project: olmo-small
entity: jhchen-ai-4s
model:
d_model: 2048
n_heads: 16
n_layers: 16
mlp_ratio: 8
weight_tying: true
alibi: false
rope: true
flash_attention: true # not available on AMD
attention_dropout: 0.0
attention_layer_norm: false
multi_query_attention: false
include_bias: false
block_type: sequential
layer_norm_type: default
layer_norm_with_affine: false
bias_for_layer_norm: false
attention_layer_norm_with_affine: false
activation_type: swiglu
residual_dropout: 0.0
embedding_dropout: 0.0
max_sequence_length: 2048
vocab_size: 100278
embedding_size: 100352
eos_token_id: 100257
pad_token_id: 100277
init_device: meta
init_fn: mitchell
compile: null # causes instability on AMD GPUs
optimizer:
name: adamw
learning_rate: 4.0e-4
weight_decay: 0.1
betas:
- 0.9
- 0.95
metrics_log_interval: 10
scheduler:
name: cosine_with_warmup
t_warmup: 2000
alpha_f: 0.1
tokenizer:
identifier: tokenizers/allenai_dolma2.json
truncate_direction: right
save_folder: workspace/${run_name}_${oc.env:SLURM_JOB_ID}
save_overwrite: false
# Sharded checkpoints (best for restarts)
save_interval: 50
save_num_checkpoints_to_keep: 9
# Unsharded checkpoints (for final storage)
save_interval_unsharded: 100
save_num_unsharded_checkpoints_to_keep: -1
load_path: null
max_duration: 739_328 # 3.1T tokens
global_train_batch_size: 2048
device_train_microbatch_size: 2
precision: amp_bf16
fsdp:
wrapping_strategy: null
precision: mixed
max_grad_norm: 1.0
max_grad_norm_ratio: null
speed_monitor:
window_size: 20
eval_interval: ${save_interval}
eval_subset_num_batches: -1
device_eval_batch_size: ${device_train_microbatch_size}
evaluators:
# - label: all-small-ppl-validation
# data:
# num_workers: 0
# drop_last: true
# # generate_doc_lengths: true
# memmap_dtype: uint32
# datasets:
# c4_en-validation:
# - http://olmo-data.org/eval-data/perplexity/v3_small_dolma2-tokenizer/c4_en/val/part-0-00000.npy
# dolma_books-validation:
# - http://olmo-data.org/eval-data/perplexity/v3_small_dolma2-tokenizer/dolma_books/val/part-0-00000.npy
# dolma_common-crawl-validation:
# - http://olmo-data.org/eval-data/perplexity/v3_small_dolma2-tokenizer/dolma_common-crawl/val/part-0-00000.npy
# dolma_pes2o-validation:
# - http://olmo-data.org/eval-data/perplexity/v3_small_dolma2-tokenizer/dolma_pes2o/val/part-0-00000.npy
# dolma_reddit-validation:
# - http://olmo-data.org/eval-data/perplexity/v3_small_dolma2-tokenizer/dolma_reddit/val/part-0-00000.npy
# dolma_stack-validation:
# - http://olmo-data.org/eval-data/perplexity/v3_small_dolma2-tokenizer/dolma_stack/val/part-0-00000.npy
# dolma_wiki-validation:
# - http://olmo-data.org/eval-data/perplexity/v3_small_dolma2-tokenizer/dolma_wiki/val/part-0-00000.npy
# ice-validation:
# - http://olmo-data.org/eval-data/perplexity/v3_small_dolma2-tokenizer/ice/val/part-0-00000.npy
# m2d2_s2orc-validation:
# - http://olmo-data.org/eval-data/perplexity/v3_small_dolma2-tokenizer/m2d2_s2orc/val/part-0-00000.npy
# pile-validation:
# - http://olmo-data.org/eval-data/perplexity/v3_small_dolma2-tokenizer/pile/val/part-0-00000.npy
# wikitext_103-validation:
# - http://olmo-data.org/eval-data/perplexity/v3_small_dolma2-tokenizer/wikitext_103/val/part-0-00000.npy
##########################
# Downstream evaluations #
##########################
- label: piqa
type: downstream
- label: hellaswag
type: downstream
- label: winogrande
type: downstream
- label: openbook_qa
type: downstream
- label: boolq
type: downstream
- label: sciq
type: downstream
- label: arc_easy
type: downstream
- label: arc_challenge
type: downstream
- label: copa
type: downstream
- label: commonsense_qa
type: downstream
- label: social_iqa
type: downstream
- label: mmlu_stem_var
type: downstream
- label: mmlu_humanities_var
type: downstream
- label: mmlu_social_sciences_var
type: downstream
- label: mmlu_other_var
type: downstream
- label: mmlu_stem_mc_5shot
type: downstream
- label: mmlu_humanities_mc_5shot
type: downstream
- label: mmlu_social_sciences_mc_5shot
type: downstream
- label: mmlu_other_mc_5shot
type: downstream
- label: mmlu_stem_mc_5shot_test
type: downstream
- label: mmlu_humanities_mc_5shot_test
type: downstream
- label: mmlu_social_sciences_mc_5shot_test
type: downstream
- label: mmlu_other_mc_5shot_test
type: downstream
- label: basic_arithmetic
type: downstream
- label: trivia_qa_wiki_ppl
type: downstream
- label: natural_qs_open_ppl
type: downstream
- label: arc_easy_ppl
type: downstream
data:
pad_direction: right
num_workers: 4
drop_last: true
pin_memory: true
prefetch_factor: 8
persistent_workers: true
# be careful of the dtype, verify by using inspect_train_data.py
memmap_dtype: uint32
timeout: 0
instance_filter:
repetition_max_period: 13
repetition_min_period: 1
repetition_max_count: 32
paths:
# Wikipedia
- http://olmo-data.org/preprocessed/olmo-mix/danyh-compiled-v1_7/documents/wiki/allenai/dolma2-tokenizer/part-0-00000.npy
- http://olmo-data.org/preprocessed/olmo-mix/danyh-compiled-v1_7/documents/wiki/allenai/dolma2-tokenizer/part-1-00000.npy