Upload model
#2
by
romrawinjp
- opened
- added_tokens.json +7 -0
- config.json +28 -0
- latest +1 -0
- special_tokens_map.json +29 -0
- tokenizer.model +3 -0
- tokenizer_config.json +88 -0
- trainer_state.json +2025 -0
- training_args.bin +3 -0
- zero_to_fp32.py +604 -0
added_tokens.json
ADDED
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"<CLS>": 41070,
|
3 |
+
"<EOD>": 41072,
|
4 |
+
"<MASK>": 41073,
|
5 |
+
"<PAD>": 41074,
|
6 |
+
"<SEP>": 41071
|
7 |
+
}
|
config.json
ADDED
@@ -0,0 +1,28 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "/project/lt900048-ai24tn/models/openthaigpt/openthaigpt-1.0.0-7b-chat",
|
3 |
+
"architectures": [
|
4 |
+
"LlamaForCausalLM"
|
5 |
+
],
|
6 |
+
"attention_bias": false,
|
7 |
+
"attention_dropout": 0.0,
|
8 |
+
"bos_token_id": 1,
|
9 |
+
"eos_token_id": 2,
|
10 |
+
"hidden_act": "silu",
|
11 |
+
"hidden_size": 4096,
|
12 |
+
"initializer_range": 0.02,
|
13 |
+
"intermediate_size": 11008,
|
14 |
+
"max_position_embeddings": 4096,
|
15 |
+
"model_type": "llama",
|
16 |
+
"num_attention_heads": 32,
|
17 |
+
"num_hidden_layers": 32,
|
18 |
+
"num_key_value_heads": 32,
|
19 |
+
"pretraining_tp": 1,
|
20 |
+
"rms_norm_eps": 1e-05,
|
21 |
+
"rope_scaling": null,
|
22 |
+
"rope_theta": 10000.0,
|
23 |
+
"tie_word_embeddings": false,
|
24 |
+
"torch_dtype": "bfloat16",
|
25 |
+
"transformers_version": "4.40.1",
|
26 |
+
"use_cache": false,
|
27 |
+
"vocab_size": 41088
|
28 |
+
}
|
latest
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
global_step285
|
special_tokens_map.json
ADDED
@@ -0,0 +1,29 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"additional_special_tokens": [
|
3 |
+
"<unk>",
|
4 |
+
"<s>",
|
5 |
+
"</s>"
|
6 |
+
],
|
7 |
+
"bos_token": {
|
8 |
+
"content": "<s>",
|
9 |
+
"lstrip": false,
|
10 |
+
"normalized": true,
|
11 |
+
"rstrip": false,
|
12 |
+
"single_word": false
|
13 |
+
},
|
14 |
+
"eos_token": {
|
15 |
+
"content": "</s>",
|
16 |
+
"lstrip": false,
|
17 |
+
"normalized": true,
|
18 |
+
"rstrip": false,
|
19 |
+
"single_word": false
|
20 |
+
},
|
21 |
+
"pad_token": "</s>",
|
22 |
+
"unk_token": {
|
23 |
+
"content": "<unk>",
|
24 |
+
"lstrip": false,
|
25 |
+
"normalized": true,
|
26 |
+
"rstrip": false,
|
27 |
+
"single_word": false
|
28 |
+
}
|
29 |
+
}
|
tokenizer.model
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:02df43dcae8c7b5b122d45f642e42c96577cdd09fd949c6996051886c72ab002
|
3 |
+
size 717508
|
tokenizer_config.json
ADDED
@@ -0,0 +1,88 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"add_bos_token": true,
|
3 |
+
"add_eos_token": false,
|
4 |
+
"add_prefix_space": true,
|
5 |
+
"added_tokens_decoder": {
|
6 |
+
"0": {
|
7 |
+
"content": "<unk>",
|
8 |
+
"lstrip": false,
|
9 |
+
"normalized": true,
|
10 |
+
"rstrip": false,
|
11 |
+
"single_word": false,
|
12 |
+
"special": true
|
13 |
+
},
|
14 |
+
"1": {
|
15 |
+
"content": "<s>",
|
16 |
+
"lstrip": false,
|
17 |
+
"normalized": true,
|
18 |
+
"rstrip": false,
|
19 |
+
"single_word": false,
|
20 |
+
"special": true
|
21 |
+
},
|
22 |
+
"2": {
|
23 |
+
"content": "</s>",
|
24 |
+
"lstrip": false,
|
25 |
+
"normalized": true,
|
26 |
+
"rstrip": false,
|
27 |
+
"single_word": false,
|
28 |
+
"special": true
|
29 |
+
},
|
30 |
+
"41070": {
|
31 |
+
"content": "<CLS>",
|
32 |
+
"lstrip": false,
|
33 |
+
"normalized": false,
|
34 |
+
"rstrip": false,
|
35 |
+
"single_word": false,
|
36 |
+
"special": true
|
37 |
+
},
|
38 |
+
"41071": {
|
39 |
+
"content": "<SEP>",
|
40 |
+
"lstrip": false,
|
41 |
+
"normalized": false,
|
42 |
+
"rstrip": false,
|
43 |
+
"single_word": false,
|
44 |
+
"special": true
|
45 |
+
},
|
46 |
+
"41072": {
|
47 |
+
"content": "<EOD>",
|
48 |
+
"lstrip": false,
|
49 |
+
"normalized": false,
|
50 |
+
"rstrip": false,
|
51 |
+
"single_word": false,
|
52 |
+
"special": true
|
53 |
+
},
|
54 |
+
"41073": {
|
55 |
+
"content": "<MASK>",
|
56 |
+
"lstrip": false,
|
57 |
+
"normalized": false,
|
58 |
+
"rstrip": false,
|
59 |
+
"single_word": false,
|
60 |
+
"special": true
|
61 |
+
},
|
62 |
+
"41074": {
|
63 |
+
"content": "<PAD>",
|
64 |
+
"lstrip": false,
|
65 |
+
"normalized": false,
|
66 |
+
"rstrip": false,
|
67 |
+
"single_word": false,
|
68 |
+
"special": true
|
69 |
+
}
|
70 |
+
},
|
71 |
+
"additional_special_tokens": [
|
72 |
+
"<unk>",
|
73 |
+
"<s>",
|
74 |
+
"</s>"
|
75 |
+
],
|
76 |
+
"bos_token": "<s>",
|
77 |
+
"clean_up_tokenization_spaces": false,
|
78 |
+
"eos_token": "</s>",
|
79 |
+
"legacy": true,
|
80 |
+
"model_max_length": 2048,
|
81 |
+
"pad_token": "</s>",
|
82 |
+
"padding_side": "right",
|
83 |
+
"sp_model_kwargs": {},
|
84 |
+
"spaces_between_special_tokens": false,
|
85 |
+
"tokenizer_class": "LlamaTokenizer",
|
86 |
+
"unk_token": "<unk>",
|
87 |
+
"use_default_system_prompt": true
|
88 |
+
}
|
trainer_state.json
ADDED
@@ -0,0 +1,2025 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"best_metric": null,
|
3 |
+
"best_model_checkpoint": null,
|
4 |
+
"epoch": 1.0,
|
5 |
+
"eval_steps": 500,
|
6 |
+
"global_step": 285,
|
7 |
+
"is_hyper_param_search": false,
|
8 |
+
"is_local_process_zero": true,
|
9 |
+
"is_world_process_zero": true,
|
10 |
+
"log_history": [
|
11 |
+
{
|
12 |
+
"epoch": 0.0035087719298245615,
|
13 |
+
"grad_norm": 18.65219621501764,
|
14 |
+
"learning_rate": 0.0,
|
15 |
+
"loss": 1.9653,
|
16 |
+
"step": 1
|
17 |
+
},
|
18 |
+
{
|
19 |
+
"epoch": 0.007017543859649123,
|
20 |
+
"grad_norm": 5.5068522642682325,
|
21 |
+
"learning_rate": 2.5237190142858296e-05,
|
22 |
+
"loss": 1.4912,
|
23 |
+
"step": 2
|
24 |
+
},
|
25 |
+
{
|
26 |
+
"epoch": 0.010526315789473684,
|
27 |
+
"grad_norm": 5.300187955783763,
|
28 |
+
"learning_rate": 4e-05,
|
29 |
+
"loss": 1.488,
|
30 |
+
"step": 3
|
31 |
+
},
|
32 |
+
{
|
33 |
+
"epoch": 0.014035087719298246,
|
34 |
+
"grad_norm": 3.607547540937298,
|
35 |
+
"learning_rate": 5.047438028571659e-05,
|
36 |
+
"loss": 1.3376,
|
37 |
+
"step": 4
|
38 |
+
},
|
39 |
+
{
|
40 |
+
"epoch": 0.017543859649122806,
|
41 |
+
"grad_norm": 2.8856871756952254,
|
42 |
+
"learning_rate": 5.859894082871708e-05,
|
43 |
+
"loss": 1.2775,
|
44 |
+
"step": 5
|
45 |
+
},
|
46 |
+
{
|
47 |
+
"epoch": 0.021052631578947368,
|
48 |
+
"grad_norm": 2.1943773684803283,
|
49 |
+
"learning_rate": 6.52371901428583e-05,
|
50 |
+
"loss": 1.1621,
|
51 |
+
"step": 6
|
52 |
+
},
|
53 |
+
{
|
54 |
+
"epoch": 0.02456140350877193,
|
55 |
+
"grad_norm": 1.6148482128986932,
|
56 |
+
"learning_rate": 7.08497499664569e-05,
|
57 |
+
"loss": 1.1393,
|
58 |
+
"step": 7
|
59 |
+
},
|
60 |
+
{
|
61 |
+
"epoch": 0.028070175438596492,
|
62 |
+
"grad_norm": 1.4378600160323183,
|
63 |
+
"learning_rate": 7.571157042857488e-05,
|
64 |
+
"loss": 1.1342,
|
65 |
+
"step": 8
|
66 |
+
},
|
67 |
+
{
|
68 |
+
"epoch": 0.031578947368421054,
|
69 |
+
"grad_norm": 1.3979572631886956,
|
70 |
+
"learning_rate": 8e-05,
|
71 |
+
"loss": 1.1196,
|
72 |
+
"step": 9
|
73 |
+
},
|
74 |
+
{
|
75 |
+
"epoch": 0.03508771929824561,
|
76 |
+
"grad_norm": 1.3666278253029815,
|
77 |
+
"learning_rate": 8e-05,
|
78 |
+
"loss": 1.1479,
|
79 |
+
"step": 10
|
80 |
+
},
|
81 |
+
{
|
82 |
+
"epoch": 0.03859649122807018,
|
83 |
+
"grad_norm": 1.2483549253543214,
|
84 |
+
"learning_rate": 7.971014492753623e-05,
|
85 |
+
"loss": 1.1125,
|
86 |
+
"step": 11
|
87 |
+
},
|
88 |
+
{
|
89 |
+
"epoch": 0.042105263157894736,
|
90 |
+
"grad_norm": 1.347256910957925,
|
91 |
+
"learning_rate": 7.942028985507246e-05,
|
92 |
+
"loss": 1.1588,
|
93 |
+
"step": 12
|
94 |
+
},
|
95 |
+
{
|
96 |
+
"epoch": 0.0456140350877193,
|
97 |
+
"grad_norm": 1.3748876632936469,
|
98 |
+
"learning_rate": 7.91304347826087e-05,
|
99 |
+
"loss": 1.0846,
|
100 |
+
"step": 13
|
101 |
+
},
|
102 |
+
{
|
103 |
+
"epoch": 0.04912280701754386,
|
104 |
+
"grad_norm": 1.329787006205099,
|
105 |
+
"learning_rate": 7.884057971014494e-05,
|
106 |
+
"loss": 1.1839,
|
107 |
+
"step": 14
|
108 |
+
},
|
109 |
+
{
|
110 |
+
"epoch": 0.05263157894736842,
|
111 |
+
"grad_norm": 1.1855019705035863,
|
112 |
+
"learning_rate": 7.855072463768117e-05,
|
113 |
+
"loss": 1.1546,
|
114 |
+
"step": 15
|
115 |
+
},
|
116 |
+
{
|
117 |
+
"epoch": 0.056140350877192984,
|
118 |
+
"grad_norm": 1.2020228064951217,
|
119 |
+
"learning_rate": 7.82608695652174e-05,
|
120 |
+
"loss": 1.0999,
|
121 |
+
"step": 16
|
122 |
+
},
|
123 |
+
{
|
124 |
+
"epoch": 0.05964912280701754,
|
125 |
+
"grad_norm": 1.2879067395522685,
|
126 |
+
"learning_rate": 7.797101449275363e-05,
|
127 |
+
"loss": 1.1466,
|
128 |
+
"step": 17
|
129 |
+
},
|
130 |
+
{
|
131 |
+
"epoch": 0.06315789473684211,
|
132 |
+
"grad_norm": 1.256590992120541,
|
133 |
+
"learning_rate": 7.768115942028987e-05,
|
134 |
+
"loss": 1.1593,
|
135 |
+
"step": 18
|
136 |
+
},
|
137 |
+
{
|
138 |
+
"epoch": 0.06666666666666667,
|
139 |
+
"grad_norm": 1.1654027316591642,
|
140 |
+
"learning_rate": 7.73913043478261e-05,
|
141 |
+
"loss": 1.1806,
|
142 |
+
"step": 19
|
143 |
+
},
|
144 |
+
{
|
145 |
+
"epoch": 0.07017543859649122,
|
146 |
+
"grad_norm": 1.2007307897010868,
|
147 |
+
"learning_rate": 7.710144927536232e-05,
|
148 |
+
"loss": 1.1416,
|
149 |
+
"step": 20
|
150 |
+
},
|
151 |
+
{
|
152 |
+
"epoch": 0.07368421052631578,
|
153 |
+
"grad_norm": 1.1499545393774593,
|
154 |
+
"learning_rate": 7.681159420289856e-05,
|
155 |
+
"loss": 1.1203,
|
156 |
+
"step": 21
|
157 |
+
},
|
158 |
+
{
|
159 |
+
"epoch": 0.07719298245614035,
|
160 |
+
"grad_norm": 1.0810536737354983,
|
161 |
+
"learning_rate": 7.652173913043479e-05,
|
162 |
+
"loss": 1.0875,
|
163 |
+
"step": 22
|
164 |
+
},
|
165 |
+
{
|
166 |
+
"epoch": 0.08070175438596491,
|
167 |
+
"grad_norm": 1.249217128847186,
|
168 |
+
"learning_rate": 7.623188405797102e-05,
|
169 |
+
"loss": 1.1878,
|
170 |
+
"step": 23
|
171 |
+
},
|
172 |
+
{
|
173 |
+
"epoch": 0.08421052631578947,
|
174 |
+
"grad_norm": 1.171401194067982,
|
175 |
+
"learning_rate": 7.594202898550726e-05,
|
176 |
+
"loss": 1.1416,
|
177 |
+
"step": 24
|
178 |
+
},
|
179 |
+
{
|
180 |
+
"epoch": 0.08771929824561403,
|
181 |
+
"grad_norm": 1.1864422136018933,
|
182 |
+
"learning_rate": 7.565217391304349e-05,
|
183 |
+
"loss": 1.1559,
|
184 |
+
"step": 25
|
185 |
+
},
|
186 |
+
{
|
187 |
+
"epoch": 0.0912280701754386,
|
188 |
+
"grad_norm": 1.1084100899911409,
|
189 |
+
"learning_rate": 7.536231884057971e-05,
|
190 |
+
"loss": 1.127,
|
191 |
+
"step": 26
|
192 |
+
},
|
193 |
+
{
|
194 |
+
"epoch": 0.09473684210526316,
|
195 |
+
"grad_norm": 1.0848431056969332,
|
196 |
+
"learning_rate": 7.507246376811594e-05,
|
197 |
+
"loss": 1.1621,
|
198 |
+
"step": 27
|
199 |
+
},
|
200 |
+
{
|
201 |
+
"epoch": 0.09824561403508772,
|
202 |
+
"grad_norm": 1.160465065160364,
|
203 |
+
"learning_rate": 7.478260869565218e-05,
|
204 |
+
"loss": 1.1086,
|
205 |
+
"step": 28
|
206 |
+
},
|
207 |
+
{
|
208 |
+
"epoch": 0.10175438596491228,
|
209 |
+
"grad_norm": 1.0888824123502896,
|
210 |
+
"learning_rate": 7.449275362318841e-05,
|
211 |
+
"loss": 1.1402,
|
212 |
+
"step": 29
|
213 |
+
},
|
214 |
+
{
|
215 |
+
"epoch": 0.10526315789473684,
|
216 |
+
"grad_norm": 1.136530946229479,
|
217 |
+
"learning_rate": 7.420289855072465e-05,
|
218 |
+
"loss": 1.1533,
|
219 |
+
"step": 30
|
220 |
+
},
|
221 |
+
{
|
222 |
+
"epoch": 0.10877192982456141,
|
223 |
+
"grad_norm": 1.1193975180437097,
|
224 |
+
"learning_rate": 7.391304347826088e-05,
|
225 |
+
"loss": 1.1194,
|
226 |
+
"step": 31
|
227 |
+
},
|
228 |
+
{
|
229 |
+
"epoch": 0.11228070175438597,
|
230 |
+
"grad_norm": 1.032391835314362,
|
231 |
+
"learning_rate": 7.36231884057971e-05,
|
232 |
+
"loss": 1.086,
|
233 |
+
"step": 32
|
234 |
+
},
|
235 |
+
{
|
236 |
+
"epoch": 0.11578947368421053,
|
237 |
+
"grad_norm": 1.1734719012857107,
|
238 |
+
"learning_rate": 7.333333333333333e-05,
|
239 |
+
"loss": 1.1515,
|
240 |
+
"step": 33
|
241 |
+
},
|
242 |
+
{
|
243 |
+
"epoch": 0.11929824561403508,
|
244 |
+
"grad_norm": 1.1223429839275594,
|
245 |
+
"learning_rate": 7.304347826086957e-05,
|
246 |
+
"loss": 1.1067,
|
247 |
+
"step": 34
|
248 |
+
},
|
249 |
+
{
|
250 |
+
"epoch": 0.12280701754385964,
|
251 |
+
"grad_norm": 1.0919749212433656,
|
252 |
+
"learning_rate": 7.27536231884058e-05,
|
253 |
+
"loss": 1.1298,
|
254 |
+
"step": 35
|
255 |
+
},
|
256 |
+
{
|
257 |
+
"epoch": 0.12631578947368421,
|
258 |
+
"grad_norm": 1.061313889855867,
|
259 |
+
"learning_rate": 7.246376811594204e-05,
|
260 |
+
"loss": 1.1323,
|
261 |
+
"step": 36
|
262 |
+
},
|
263 |
+
{
|
264 |
+
"epoch": 0.12982456140350876,
|
265 |
+
"grad_norm": 0.9886502393238654,
|
266 |
+
"learning_rate": 7.217391304347827e-05,
|
267 |
+
"loss": 1.1358,
|
268 |
+
"step": 37
|
269 |
+
},
|
270 |
+
{
|
271 |
+
"epoch": 0.13333333333333333,
|
272 |
+
"grad_norm": 1.090149070089068,
|
273 |
+
"learning_rate": 7.18840579710145e-05,
|
274 |
+
"loss": 1.1083,
|
275 |
+
"step": 38
|
276 |
+
},
|
277 |
+
{
|
278 |
+
"epoch": 0.1368421052631579,
|
279 |
+
"grad_norm": 1.2141824886927202,
|
280 |
+
"learning_rate": 7.159420289855072e-05,
|
281 |
+
"loss": 1.1659,
|
282 |
+
"step": 39
|
283 |
+
},
|
284 |
+
{
|
285 |
+
"epoch": 0.14035087719298245,
|
286 |
+
"grad_norm": 1.2804981481033841,
|
287 |
+
"learning_rate": 7.130434782608696e-05,
|
288 |
+
"loss": 1.1769,
|
289 |
+
"step": 40
|
290 |
+
},
|
291 |
+
{
|
292 |
+
"epoch": 0.14385964912280702,
|
293 |
+
"grad_norm": 1.085391641580103,
|
294 |
+
"learning_rate": 7.101449275362319e-05,
|
295 |
+
"loss": 1.1307,
|
296 |
+
"step": 41
|
297 |
+
},
|
298 |
+
{
|
299 |
+
"epoch": 0.14736842105263157,
|
300 |
+
"grad_norm": 1.0432511632089205,
|
301 |
+
"learning_rate": 7.072463768115943e-05,
|
302 |
+
"loss": 1.1152,
|
303 |
+
"step": 42
|
304 |
+
},
|
305 |
+
{
|
306 |
+
"epoch": 0.15087719298245614,
|
307 |
+
"grad_norm": 1.0805636921488617,
|
308 |
+
"learning_rate": 7.043478260869566e-05,
|
309 |
+
"loss": 1.1131,
|
310 |
+
"step": 43
|
311 |
+
},
|
312 |
+
{
|
313 |
+
"epoch": 0.1543859649122807,
|
314 |
+
"grad_norm": 1.0831222641710494,
|
315 |
+
"learning_rate": 7.014492753623189e-05,
|
316 |
+
"loss": 1.1585,
|
317 |
+
"step": 44
|
318 |
+
},
|
319 |
+
{
|
320 |
+
"epoch": 0.15789473684210525,
|
321 |
+
"grad_norm": 0.9919690920164701,
|
322 |
+
"learning_rate": 6.985507246376811e-05,
|
323 |
+
"loss": 1.1235,
|
324 |
+
"step": 45
|
325 |
+
},
|
326 |
+
{
|
327 |
+
"epoch": 0.16140350877192983,
|
328 |
+
"grad_norm": 0.9498489248223517,
|
329 |
+
"learning_rate": 6.956521739130436e-05,
|
330 |
+
"loss": 1.0856,
|
331 |
+
"step": 46
|
332 |
+
},
|
333 |
+
{
|
334 |
+
"epoch": 0.1649122807017544,
|
335 |
+
"grad_norm": 1.0276715714307674,
|
336 |
+
"learning_rate": 6.927536231884058e-05,
|
337 |
+
"loss": 1.1378,
|
338 |
+
"step": 47
|
339 |
+
},
|
340 |
+
{
|
341 |
+
"epoch": 0.16842105263157894,
|
342 |
+
"grad_norm": 1.094458012231917,
|
343 |
+
"learning_rate": 6.898550724637682e-05,
|
344 |
+
"loss": 1.117,
|
345 |
+
"step": 48
|
346 |
+
},
|
347 |
+
{
|
348 |
+
"epoch": 0.17192982456140352,
|
349 |
+
"grad_norm": 1.089782170199694,
|
350 |
+
"learning_rate": 6.869565217391305e-05,
|
351 |
+
"loss": 1.1471,
|
352 |
+
"step": 49
|
353 |
+
},
|
354 |
+
{
|
355 |
+
"epoch": 0.17543859649122806,
|
356 |
+
"grad_norm": 1.0908602591310133,
|
357 |
+
"learning_rate": 6.840579710144928e-05,
|
358 |
+
"loss": 1.1711,
|
359 |
+
"step": 50
|
360 |
+
},
|
361 |
+
{
|
362 |
+
"epoch": 0.17894736842105263,
|
363 |
+
"grad_norm": 1.126099914721245,
|
364 |
+
"learning_rate": 6.811594202898552e-05,
|
365 |
+
"loss": 1.1437,
|
366 |
+
"step": 51
|
367 |
+
},
|
368 |
+
{
|
369 |
+
"epoch": 0.1824561403508772,
|
370 |
+
"grad_norm": 1.1004469394026717,
|
371 |
+
"learning_rate": 6.782608695652175e-05,
|
372 |
+
"loss": 1.1502,
|
373 |
+
"step": 52
|
374 |
+
},
|
375 |
+
{
|
376 |
+
"epoch": 0.18596491228070175,
|
377 |
+
"grad_norm": 1.0690976698679064,
|
378 |
+
"learning_rate": 6.753623188405797e-05,
|
379 |
+
"loss": 1.1436,
|
380 |
+
"step": 53
|
381 |
+
},
|
382 |
+
{
|
383 |
+
"epoch": 0.18947368421052632,
|
384 |
+
"grad_norm": 1.0893372270742567,
|
385 |
+
"learning_rate": 6.72463768115942e-05,
|
386 |
+
"loss": 1.1028,
|
387 |
+
"step": 54
|
388 |
+
},
|
389 |
+
{
|
390 |
+
"epoch": 0.19298245614035087,
|
391 |
+
"grad_norm": 1.038406028318434,
|
392 |
+
"learning_rate": 6.695652173913044e-05,
|
393 |
+
"loss": 1.1601,
|
394 |
+
"step": 55
|
395 |
+
},
|
396 |
+
{
|
397 |
+
"epoch": 0.19649122807017544,
|
398 |
+
"grad_norm": 0.9960149874705063,
|
399 |
+
"learning_rate": 6.666666666666667e-05,
|
400 |
+
"loss": 1.102,
|
401 |
+
"step": 56
|
402 |
+
},
|
403 |
+
{
|
404 |
+
"epoch": 0.2,
|
405 |
+
"grad_norm": 1.073973228867499,
|
406 |
+
"learning_rate": 6.637681159420291e-05,
|
407 |
+
"loss": 1.1213,
|
408 |
+
"step": 57
|
409 |
+
},
|
410 |
+
{
|
411 |
+
"epoch": 0.20350877192982456,
|
412 |
+
"grad_norm": 1.1952354445407958,
|
413 |
+
"learning_rate": 6.608695652173914e-05,
|
414 |
+
"loss": 1.1046,
|
415 |
+
"step": 58
|
416 |
+
},
|
417 |
+
{
|
418 |
+
"epoch": 0.20701754385964913,
|
419 |
+
"grad_norm": 1.0175331854073473,
|
420 |
+
"learning_rate": 6.579710144927537e-05,
|
421 |
+
"loss": 1.1192,
|
422 |
+
"step": 59
|
423 |
+
},
|
424 |
+
{
|
425 |
+
"epoch": 0.21052631578947367,
|
426 |
+
"grad_norm": 1.053567224648277,
|
427 |
+
"learning_rate": 6.550724637681159e-05,
|
428 |
+
"loss": 1.1514,
|
429 |
+
"step": 60
|
430 |
+
},
|
431 |
+
{
|
432 |
+
"epoch": 0.21403508771929824,
|
433 |
+
"grad_norm": 1.1549538449027954,
|
434 |
+
"learning_rate": 6.521739130434783e-05,
|
435 |
+
"loss": 1.161,
|
436 |
+
"step": 61
|
437 |
+
},
|
438 |
+
{
|
439 |
+
"epoch": 0.21754385964912282,
|
440 |
+
"grad_norm": 0.9980361090477836,
|
441 |
+
"learning_rate": 6.492753623188406e-05,
|
442 |
+
"loss": 1.0715,
|
443 |
+
"step": 62
|
444 |
+
},
|
445 |
+
{
|
446 |
+
"epoch": 0.22105263157894736,
|
447 |
+
"grad_norm": 1.0664047714210805,
|
448 |
+
"learning_rate": 6.46376811594203e-05,
|
449 |
+
"loss": 1.172,
|
450 |
+
"step": 63
|
451 |
+
},
|
452 |
+
{
|
453 |
+
"epoch": 0.22456140350877193,
|
454 |
+
"grad_norm": 1.0338684936573976,
|
455 |
+
"learning_rate": 6.434782608695653e-05,
|
456 |
+
"loss": 1.0547,
|
457 |
+
"step": 64
|
458 |
+
},
|
459 |
+
{
|
460 |
+
"epoch": 0.22807017543859648,
|
461 |
+
"grad_norm": 1.0164199027592216,
|
462 |
+
"learning_rate": 6.405797101449276e-05,
|
463 |
+
"loss": 1.0821,
|
464 |
+
"step": 65
|
465 |
+
},
|
466 |
+
{
|
467 |
+
"epoch": 0.23157894736842105,
|
468 |
+
"grad_norm": 1.08287922650492,
|
469 |
+
"learning_rate": 6.376811594202898e-05,
|
470 |
+
"loss": 1.112,
|
471 |
+
"step": 66
|
472 |
+
},
|
473 |
+
{
|
474 |
+
"epoch": 0.23508771929824562,
|
475 |
+
"grad_norm": 1.012260870534961,
|
476 |
+
"learning_rate": 6.347826086956523e-05,
|
477 |
+
"loss": 1.1339,
|
478 |
+
"step": 67
|
479 |
+
},
|
480 |
+
{
|
481 |
+
"epoch": 0.23859649122807017,
|
482 |
+
"grad_norm": 0.9284957156873009,
|
483 |
+
"learning_rate": 6.318840579710145e-05,
|
484 |
+
"loss": 1.0655,
|
485 |
+
"step": 68
|
486 |
+
},
|
487 |
+
{
|
488 |
+
"epoch": 0.24210526315789474,
|
489 |
+
"grad_norm": 0.9699566883456087,
|
490 |
+
"learning_rate": 6.28985507246377e-05,
|
491 |
+
"loss": 1.0447,
|
492 |
+
"step": 69
|
493 |
+
},
|
494 |
+
{
|
495 |
+
"epoch": 0.24561403508771928,
|
496 |
+
"grad_norm": 0.9953128820241032,
|
497 |
+
"learning_rate": 6.260869565217392e-05,
|
498 |
+
"loss": 1.0979,
|
499 |
+
"step": 70
|
500 |
+
},
|
501 |
+
{
|
502 |
+
"epoch": 0.24912280701754386,
|
503 |
+
"grad_norm": 1.2255506094662556,
|
504 |
+
"learning_rate": 6.231884057971015e-05,
|
505 |
+
"loss": 1.1266,
|
506 |
+
"step": 71
|
507 |
+
},
|
508 |
+
{
|
509 |
+
"epoch": 0.25263157894736843,
|
510 |
+
"grad_norm": 1.1053469341884643,
|
511 |
+
"learning_rate": 6.202898550724638e-05,
|
512 |
+
"loss": 1.1083,
|
513 |
+
"step": 72
|
514 |
+
},
|
515 |
+
{
|
516 |
+
"epoch": 0.256140350877193,
|
517 |
+
"grad_norm": 1.0471395283209621,
|
518 |
+
"learning_rate": 6.173913043478262e-05,
|
519 |
+
"loss": 1.1081,
|
520 |
+
"step": 73
|
521 |
+
},
|
522 |
+
{
|
523 |
+
"epoch": 0.2596491228070175,
|
524 |
+
"grad_norm": 1.1372933010569457,
|
525 |
+
"learning_rate": 6.144927536231884e-05,
|
526 |
+
"loss": 1.1191,
|
527 |
+
"step": 74
|
528 |
+
},
|
529 |
+
{
|
530 |
+
"epoch": 0.2631578947368421,
|
531 |
+
"grad_norm": 1.094007360015913,
|
532 |
+
"learning_rate": 6.115942028985507e-05,
|
533 |
+
"loss": 1.1498,
|
534 |
+
"step": 75
|
535 |
+
},
|
536 |
+
{
|
537 |
+
"epoch": 0.26666666666666666,
|
538 |
+
"grad_norm": 1.037731837007179,
|
539 |
+
"learning_rate": 6.086956521739131e-05,
|
540 |
+
"loss": 1.078,
|
541 |
+
"step": 76
|
542 |
+
},
|
543 |
+
{
|
544 |
+
"epoch": 0.27017543859649124,
|
545 |
+
"grad_norm": 0.9878690341929469,
|
546 |
+
"learning_rate": 6.057971014492755e-05,
|
547 |
+
"loss": 1.0925,
|
548 |
+
"step": 77
|
549 |
+
},
|
550 |
+
{
|
551 |
+
"epoch": 0.2736842105263158,
|
552 |
+
"grad_norm": 1.0251650017115257,
|
553 |
+
"learning_rate": 6.0289855072463774e-05,
|
554 |
+
"loss": 1.0992,
|
555 |
+
"step": 78
|
556 |
+
},
|
557 |
+
{
|
558 |
+
"epoch": 0.2771929824561403,
|
559 |
+
"grad_norm": 0.9677079627985357,
|
560 |
+
"learning_rate": 6.000000000000001e-05,
|
561 |
+
"loss": 1.0228,
|
562 |
+
"step": 79
|
563 |
+
},
|
564 |
+
{
|
565 |
+
"epoch": 0.2807017543859649,
|
566 |
+
"grad_norm": 1.03084630118753,
|
567 |
+
"learning_rate": 5.9710144927536236e-05,
|
568 |
+
"loss": 1.1026,
|
569 |
+
"step": 80
|
570 |
+
},
|
571 |
+
{
|
572 |
+
"epoch": 0.28421052631578947,
|
573 |
+
"grad_norm": 1.149025536043054,
|
574 |
+
"learning_rate": 5.942028985507246e-05,
|
575 |
+
"loss": 1.0971,
|
576 |
+
"step": 81
|
577 |
+
},
|
578 |
+
{
|
579 |
+
"epoch": 0.28771929824561404,
|
580 |
+
"grad_norm": 0.8977367483124615,
|
581 |
+
"learning_rate": 5.91304347826087e-05,
|
582 |
+
"loss": 1.0665,
|
583 |
+
"step": 82
|
584 |
+
},
|
585 |
+
{
|
586 |
+
"epoch": 0.2912280701754386,
|
587 |
+
"grad_norm": 0.982319885338846,
|
588 |
+
"learning_rate": 5.884057971014494e-05,
|
589 |
+
"loss": 1.0987,
|
590 |
+
"step": 83
|
591 |
+
},
|
592 |
+
{
|
593 |
+
"epoch": 0.29473684210526313,
|
594 |
+
"grad_norm": 0.8863683819755959,
|
595 |
+
"learning_rate": 5.8550724637681166e-05,
|
596 |
+
"loss": 1.0603,
|
597 |
+
"step": 84
|
598 |
+
},
|
599 |
+
{
|
600 |
+
"epoch": 0.2982456140350877,
|
601 |
+
"grad_norm": 1.0566465114428347,
|
602 |
+
"learning_rate": 5.82608695652174e-05,
|
603 |
+
"loss": 1.0961,
|
604 |
+
"step": 85
|
605 |
+
},
|
606 |
+
{
|
607 |
+
"epoch": 0.3017543859649123,
|
608 |
+
"grad_norm": 0.9391730832092359,
|
609 |
+
"learning_rate": 5.797101449275363e-05,
|
610 |
+
"loss": 1.1184,
|
611 |
+
"step": 86
|
612 |
+
},
|
613 |
+
{
|
614 |
+
"epoch": 0.30526315789473685,
|
615 |
+
"grad_norm": 0.9725750087741657,
|
616 |
+
"learning_rate": 5.768115942028986e-05,
|
617 |
+
"loss": 1.1131,
|
618 |
+
"step": 87
|
619 |
+
},
|
620 |
+
{
|
621 |
+
"epoch": 0.3087719298245614,
|
622 |
+
"grad_norm": 0.9134535098625444,
|
623 |
+
"learning_rate": 5.739130434782609e-05,
|
624 |
+
"loss": 1.0635,
|
625 |
+
"step": 88
|
626 |
+
},
|
627 |
+
{
|
628 |
+
"epoch": 0.312280701754386,
|
629 |
+
"grad_norm": 0.9210153237928186,
|
630 |
+
"learning_rate": 5.710144927536232e-05,
|
631 |
+
"loss": 1.0208,
|
632 |
+
"step": 89
|
633 |
+
},
|
634 |
+
{
|
635 |
+
"epoch": 0.3157894736842105,
|
636 |
+
"grad_norm": 1.073076083662152,
|
637 |
+
"learning_rate": 5.681159420289856e-05,
|
638 |
+
"loss": 1.1314,
|
639 |
+
"step": 90
|
640 |
+
},
|
641 |
+
{
|
642 |
+
"epoch": 0.3192982456140351,
|
643 |
+
"grad_norm": 0.9246736723369094,
|
644 |
+
"learning_rate": 5.652173913043479e-05,
|
645 |
+
"loss": 1.0458,
|
646 |
+
"step": 91
|
647 |
+
},
|
648 |
+
{
|
649 |
+
"epoch": 0.32280701754385965,
|
650 |
+
"grad_norm": 0.9415979605613132,
|
651 |
+
"learning_rate": 5.623188405797102e-05,
|
652 |
+
"loss": 1.0432,
|
653 |
+
"step": 92
|
654 |
+
},
|
655 |
+
{
|
656 |
+
"epoch": 0.3263157894736842,
|
657 |
+
"grad_norm": 1.0029090729561863,
|
658 |
+
"learning_rate": 5.594202898550725e-05,
|
659 |
+
"loss": 1.1045,
|
660 |
+
"step": 93
|
661 |
+
},
|
662 |
+
{
|
663 |
+
"epoch": 0.3298245614035088,
|
664 |
+
"grad_norm": 1.0012689311514984,
|
665 |
+
"learning_rate": 5.565217391304348e-05,
|
666 |
+
"loss": 1.0923,
|
667 |
+
"step": 94
|
668 |
+
},
|
669 |
+
{
|
670 |
+
"epoch": 0.3333333333333333,
|
671 |
+
"grad_norm": 0.9253904632856298,
|
672 |
+
"learning_rate": 5.5362318840579714e-05,
|
673 |
+
"loss": 1.028,
|
674 |
+
"step": 95
|
675 |
+
},
|
676 |
+
{
|
677 |
+
"epoch": 0.3368421052631579,
|
678 |
+
"grad_norm": 1.006794875176782,
|
679 |
+
"learning_rate": 5.507246376811594e-05,
|
680 |
+
"loss": 1.0772,
|
681 |
+
"step": 96
|
682 |
+
},
|
683 |
+
{
|
684 |
+
"epoch": 0.34035087719298246,
|
685 |
+
"grad_norm": 0.9652341181001821,
|
686 |
+
"learning_rate": 5.478260869565218e-05,
|
687 |
+
"loss": 1.0544,
|
688 |
+
"step": 97
|
689 |
+
},
|
690 |
+
{
|
691 |
+
"epoch": 0.34385964912280703,
|
692 |
+
"grad_norm": 0.9633053495992878,
|
693 |
+
"learning_rate": 5.449275362318841e-05,
|
694 |
+
"loss": 1.0369,
|
695 |
+
"step": 98
|
696 |
+
},
|
697 |
+
{
|
698 |
+
"epoch": 0.3473684210526316,
|
699 |
+
"grad_norm": 0.889193134564978,
|
700 |
+
"learning_rate": 5.4202898550724644e-05,
|
701 |
+
"loss": 1.0571,
|
702 |
+
"step": 99
|
703 |
+
},
|
704 |
+
{
|
705 |
+
"epoch": 0.3508771929824561,
|
706 |
+
"grad_norm": 1.0688458576983824,
|
707 |
+
"learning_rate": 5.391304347826087e-05,
|
708 |
+
"loss": 1.0875,
|
709 |
+
"step": 100
|
710 |
+
},
|
711 |
+
{
|
712 |
+
"epoch": 0.3543859649122807,
|
713 |
+
"grad_norm": 0.9618220162761959,
|
714 |
+
"learning_rate": 5.3623188405797106e-05,
|
715 |
+
"loss": 1.0989,
|
716 |
+
"step": 101
|
717 |
+
},
|
718 |
+
{
|
719 |
+
"epoch": 0.35789473684210527,
|
720 |
+
"grad_norm": 1.0116504967458333,
|
721 |
+
"learning_rate": 5.333333333333333e-05,
|
722 |
+
"loss": 1.1362,
|
723 |
+
"step": 102
|
724 |
+
},
|
725 |
+
{
|
726 |
+
"epoch": 0.36140350877192984,
|
727 |
+
"grad_norm": 0.9446835004736188,
|
728 |
+
"learning_rate": 5.304347826086957e-05,
|
729 |
+
"loss": 1.0549,
|
730 |
+
"step": 103
|
731 |
+
},
|
732 |
+
{
|
733 |
+
"epoch": 0.3649122807017544,
|
734 |
+
"grad_norm": 1.2634297228252125,
|
735 |
+
"learning_rate": 5.27536231884058e-05,
|
736 |
+
"loss": 1.0865,
|
737 |
+
"step": 104
|
738 |
+
},
|
739 |
+
{
|
740 |
+
"epoch": 0.3684210526315789,
|
741 |
+
"grad_norm": 1.0070752681998931,
|
742 |
+
"learning_rate": 5.2463768115942036e-05,
|
743 |
+
"loss": 1.071,
|
744 |
+
"step": 105
|
745 |
+
},
|
746 |
+
{
|
747 |
+
"epoch": 0.3719298245614035,
|
748 |
+
"grad_norm": 1.0889370997100492,
|
749 |
+
"learning_rate": 5.217391304347826e-05,
|
750 |
+
"loss": 1.1063,
|
751 |
+
"step": 106
|
752 |
+
},
|
753 |
+
{
|
754 |
+
"epoch": 0.37543859649122807,
|
755 |
+
"grad_norm": 0.9667935705662773,
|
756 |
+
"learning_rate": 5.18840579710145e-05,
|
757 |
+
"loss": 1.0666,
|
758 |
+
"step": 107
|
759 |
+
},
|
760 |
+
{
|
761 |
+
"epoch": 0.37894736842105264,
|
762 |
+
"grad_norm": 0.9817859943047047,
|
763 |
+
"learning_rate": 5.1594202898550725e-05,
|
764 |
+
"loss": 1.1025,
|
765 |
+
"step": 108
|
766 |
+
},
|
767 |
+
{
|
768 |
+
"epoch": 0.3824561403508772,
|
769 |
+
"grad_norm": 0.8710066297645505,
|
770 |
+
"learning_rate": 5.130434782608696e-05,
|
771 |
+
"loss": 1.1057,
|
772 |
+
"step": 109
|
773 |
+
},
|
774 |
+
{
|
775 |
+
"epoch": 0.38596491228070173,
|
776 |
+
"grad_norm": 1.0647772098482442,
|
777 |
+
"learning_rate": 5.1014492753623186e-05,
|
778 |
+
"loss": 1.1315,
|
779 |
+
"step": 110
|
780 |
+
},
|
781 |
+
{
|
782 |
+
"epoch": 0.3894736842105263,
|
783 |
+
"grad_norm": 0.9399046787831713,
|
784 |
+
"learning_rate": 5.072463768115943e-05,
|
785 |
+
"loss": 1.0572,
|
786 |
+
"step": 111
|
787 |
+
},
|
788 |
+
{
|
789 |
+
"epoch": 0.3929824561403509,
|
790 |
+
"grad_norm": 0.8768124884597763,
|
791 |
+
"learning_rate": 5.043478260869566e-05,
|
792 |
+
"loss": 1.0401,
|
793 |
+
"step": 112
|
794 |
+
},
|
795 |
+
{
|
796 |
+
"epoch": 0.39649122807017545,
|
797 |
+
"grad_norm": 1.009086025516714,
|
798 |
+
"learning_rate": 5.014492753623189e-05,
|
799 |
+
"loss": 1.0604,
|
800 |
+
"step": 113
|
801 |
+
},
|
802 |
+
{
|
803 |
+
"epoch": 0.4,
|
804 |
+
"grad_norm": 0.9419034237826691,
|
805 |
+
"learning_rate": 4.9855072463768116e-05,
|
806 |
+
"loss": 1.0858,
|
807 |
+
"step": 114
|
808 |
+
},
|
809 |
+
{
|
810 |
+
"epoch": 0.40350877192982454,
|
811 |
+
"grad_norm": 0.9876303358742554,
|
812 |
+
"learning_rate": 4.956521739130435e-05,
|
813 |
+
"loss": 1.083,
|
814 |
+
"step": 115
|
815 |
+
},
|
816 |
+
{
|
817 |
+
"epoch": 0.4070175438596491,
|
818 |
+
"grad_norm": 0.934675922910989,
|
819 |
+
"learning_rate": 4.927536231884058e-05,
|
820 |
+
"loss": 1.0749,
|
821 |
+
"step": 116
|
822 |
+
},
|
823 |
+
{
|
824 |
+
"epoch": 0.4105263157894737,
|
825 |
+
"grad_norm": 0.9813286336072813,
|
826 |
+
"learning_rate": 4.898550724637682e-05,
|
827 |
+
"loss": 1.0721,
|
828 |
+
"step": 117
|
829 |
+
},
|
830 |
+
{
|
831 |
+
"epoch": 0.41403508771929826,
|
832 |
+
"grad_norm": 1.0168504955660564,
|
833 |
+
"learning_rate": 4.869565217391305e-05,
|
834 |
+
"loss": 1.0276,
|
835 |
+
"step": 118
|
836 |
+
},
|
837 |
+
{
|
838 |
+
"epoch": 0.41754385964912283,
|
839 |
+
"grad_norm": 0.9087837180593036,
|
840 |
+
"learning_rate": 4.840579710144928e-05,
|
841 |
+
"loss": 1.0104,
|
842 |
+
"step": 119
|
843 |
+
},
|
844 |
+
{
|
845 |
+
"epoch": 0.42105263157894735,
|
846 |
+
"grad_norm": 0.8834303398491904,
|
847 |
+
"learning_rate": 4.8115942028985514e-05,
|
848 |
+
"loss": 1.032,
|
849 |
+
"step": 120
|
850 |
+
},
|
851 |
+
{
|
852 |
+
"epoch": 0.4245614035087719,
|
853 |
+
"grad_norm": 0.9525280076015293,
|
854 |
+
"learning_rate": 4.782608695652174e-05,
|
855 |
+
"loss": 1.0257,
|
856 |
+
"step": 121
|
857 |
+
},
|
858 |
+
{
|
859 |
+
"epoch": 0.4280701754385965,
|
860 |
+
"grad_norm": 0.9493713737636021,
|
861 |
+
"learning_rate": 4.7536231884057976e-05,
|
862 |
+
"loss": 1.0273,
|
863 |
+
"step": 122
|
864 |
+
},
|
865 |
+
{
|
866 |
+
"epoch": 0.43157894736842106,
|
867 |
+
"grad_norm": 0.9098239721172197,
|
868 |
+
"learning_rate": 4.72463768115942e-05,
|
869 |
+
"loss": 0.981,
|
870 |
+
"step": 123
|
871 |
+
},
|
872 |
+
{
|
873 |
+
"epoch": 0.43508771929824563,
|
874 |
+
"grad_norm": 0.9664557596159875,
|
875 |
+
"learning_rate": 4.6956521739130444e-05,
|
876 |
+
"loss": 1.1167,
|
877 |
+
"step": 124
|
878 |
+
},
|
879 |
+
{
|
880 |
+
"epoch": 0.43859649122807015,
|
881 |
+
"grad_norm": 0.8663800542676098,
|
882 |
+
"learning_rate": 4.666666666666667e-05,
|
883 |
+
"loss": 1.0566,
|
884 |
+
"step": 125
|
885 |
+
},
|
886 |
+
{
|
887 |
+
"epoch": 0.4421052631578947,
|
888 |
+
"grad_norm": 0.8587329676076015,
|
889 |
+
"learning_rate": 4.6376811594202906e-05,
|
890 |
+
"loss": 1.0457,
|
891 |
+
"step": 126
|
892 |
+
},
|
893 |
+
{
|
894 |
+
"epoch": 0.4456140350877193,
|
895 |
+
"grad_norm": 1.0139380452518938,
|
896 |
+
"learning_rate": 4.608695652173913e-05,
|
897 |
+
"loss": 1.0871,
|
898 |
+
"step": 127
|
899 |
+
},
|
900 |
+
{
|
901 |
+
"epoch": 0.44912280701754387,
|
902 |
+
"grad_norm": 0.87218312389074,
|
903 |
+
"learning_rate": 4.579710144927537e-05,
|
904 |
+
"loss": 0.9934,
|
905 |
+
"step": 128
|
906 |
+
},
|
907 |
+
{
|
908 |
+
"epoch": 0.45263157894736844,
|
909 |
+
"grad_norm": 0.945265788938204,
|
910 |
+
"learning_rate": 4.5507246376811595e-05,
|
911 |
+
"loss": 1.0598,
|
912 |
+
"step": 129
|
913 |
+
},
|
914 |
+
{
|
915 |
+
"epoch": 0.45614035087719296,
|
916 |
+
"grad_norm": 1.0447712876512982,
|
917 |
+
"learning_rate": 4.521739130434783e-05,
|
918 |
+
"loss": 1.0208,
|
919 |
+
"step": 130
|
920 |
+
},
|
921 |
+
{
|
922 |
+
"epoch": 0.45964912280701753,
|
923 |
+
"grad_norm": 0.8863649966336605,
|
924 |
+
"learning_rate": 4.492753623188406e-05,
|
925 |
+
"loss": 0.9916,
|
926 |
+
"step": 131
|
927 |
+
},
|
928 |
+
{
|
929 |
+
"epoch": 0.4631578947368421,
|
930 |
+
"grad_norm": 0.9389072020523048,
|
931 |
+
"learning_rate": 4.46376811594203e-05,
|
932 |
+
"loss": 1.039,
|
933 |
+
"step": 132
|
934 |
+
},
|
935 |
+
{
|
936 |
+
"epoch": 0.4666666666666667,
|
937 |
+
"grad_norm": 1.00128465703121,
|
938 |
+
"learning_rate": 4.4347826086956525e-05,
|
939 |
+
"loss": 1.007,
|
940 |
+
"step": 133
|
941 |
+
},
|
942 |
+
{
|
943 |
+
"epoch": 0.47017543859649125,
|
944 |
+
"grad_norm": 0.9218948102233011,
|
945 |
+
"learning_rate": 4.405797101449276e-05,
|
946 |
+
"loss": 1.0489,
|
947 |
+
"step": 134
|
948 |
+
},
|
949 |
+
{
|
950 |
+
"epoch": 0.47368421052631576,
|
951 |
+
"grad_norm": 0.8980509099966125,
|
952 |
+
"learning_rate": 4.3768115942028986e-05,
|
953 |
+
"loss": 1.0539,
|
954 |
+
"step": 135
|
955 |
+
},
|
956 |
+
{
|
957 |
+
"epoch": 0.47719298245614034,
|
958 |
+
"grad_norm": 0.8922781997772711,
|
959 |
+
"learning_rate": 4.347826086956522e-05,
|
960 |
+
"loss": 1.0653,
|
961 |
+
"step": 136
|
962 |
+
},
|
963 |
+
{
|
964 |
+
"epoch": 0.4807017543859649,
|
965 |
+
"grad_norm": 0.9229578265481162,
|
966 |
+
"learning_rate": 4.318840579710145e-05,
|
967 |
+
"loss": 1.0359,
|
968 |
+
"step": 137
|
969 |
+
},
|
970 |
+
{
|
971 |
+
"epoch": 0.4842105263157895,
|
972 |
+
"grad_norm": 0.9864176248898312,
|
973 |
+
"learning_rate": 4.289855072463769e-05,
|
974 |
+
"loss": 1.0711,
|
975 |
+
"step": 138
|
976 |
+
},
|
977 |
+
{
|
978 |
+
"epoch": 0.48771929824561405,
|
979 |
+
"grad_norm": 0.9040178292405336,
|
980 |
+
"learning_rate": 4.2608695652173916e-05,
|
981 |
+
"loss": 1.0615,
|
982 |
+
"step": 139
|
983 |
+
},
|
984 |
+
{
|
985 |
+
"epoch": 0.49122807017543857,
|
986 |
+
"grad_norm": 0.9065042000785789,
|
987 |
+
"learning_rate": 4.231884057971015e-05,
|
988 |
+
"loss": 1.0267,
|
989 |
+
"step": 140
|
990 |
+
},
|
991 |
+
{
|
992 |
+
"epoch": 0.49473684210526314,
|
993 |
+
"grad_norm": 0.9289938532156966,
|
994 |
+
"learning_rate": 4.202898550724638e-05,
|
995 |
+
"loss": 1.0269,
|
996 |
+
"step": 141
|
997 |
+
},
|
998 |
+
{
|
999 |
+
"epoch": 0.4982456140350877,
|
1000 |
+
"grad_norm": 0.8703398745310128,
|
1001 |
+
"learning_rate": 4.173913043478261e-05,
|
1002 |
+
"loss": 0.9952,
|
1003 |
+
"step": 142
|
1004 |
+
},
|
1005 |
+
{
|
1006 |
+
"epoch": 0.5017543859649123,
|
1007 |
+
"grad_norm": 0.9754555079004449,
|
1008 |
+
"learning_rate": 4.144927536231884e-05,
|
1009 |
+
"loss": 1.0744,
|
1010 |
+
"step": 143
|
1011 |
+
},
|
1012 |
+
{
|
1013 |
+
"epoch": 0.5052631578947369,
|
1014 |
+
"grad_norm": 1.0698316819851512,
|
1015 |
+
"learning_rate": 4.115942028985507e-05,
|
1016 |
+
"loss": 1.0179,
|
1017 |
+
"step": 144
|
1018 |
+
},
|
1019 |
+
{
|
1020 |
+
"epoch": 0.5087719298245614,
|
1021 |
+
"grad_norm": 0.9380968706540932,
|
1022 |
+
"learning_rate": 4.0869565217391314e-05,
|
1023 |
+
"loss": 0.9932,
|
1024 |
+
"step": 145
|
1025 |
+
},
|
1026 |
+
{
|
1027 |
+
"epoch": 0.512280701754386,
|
1028 |
+
"grad_norm": 0.9380079488737321,
|
1029 |
+
"learning_rate": 4.057971014492754e-05,
|
1030 |
+
"loss": 1.0655,
|
1031 |
+
"step": 146
|
1032 |
+
},
|
1033 |
+
{
|
1034 |
+
"epoch": 0.5157894736842106,
|
1035 |
+
"grad_norm": 0.9764065323167558,
|
1036 |
+
"learning_rate": 4.0289855072463776e-05,
|
1037 |
+
"loss": 1.0096,
|
1038 |
+
"step": 147
|
1039 |
+
},
|
1040 |
+
{
|
1041 |
+
"epoch": 0.519298245614035,
|
1042 |
+
"grad_norm": 0.917590332443622,
|
1043 |
+
"learning_rate": 4e-05,
|
1044 |
+
"loss": 1.0376,
|
1045 |
+
"step": 148
|
1046 |
+
},
|
1047 |
+
{
|
1048 |
+
"epoch": 0.5228070175438596,
|
1049 |
+
"grad_norm": 0.9466091457378278,
|
1050 |
+
"learning_rate": 3.971014492753623e-05,
|
1051 |
+
"loss": 1.0722,
|
1052 |
+
"step": 149
|
1053 |
+
},
|
1054 |
+
{
|
1055 |
+
"epoch": 0.5263157894736842,
|
1056 |
+
"grad_norm": 0.9998149019870339,
|
1057 |
+
"learning_rate": 3.942028985507247e-05,
|
1058 |
+
"loss": 1.0747,
|
1059 |
+
"step": 150
|
1060 |
+
},
|
1061 |
+
{
|
1062 |
+
"epoch": 0.5298245614035088,
|
1063 |
+
"grad_norm": 0.9592124249246545,
|
1064 |
+
"learning_rate": 3.91304347826087e-05,
|
1065 |
+
"loss": 0.9772,
|
1066 |
+
"step": 151
|
1067 |
+
},
|
1068 |
+
{
|
1069 |
+
"epoch": 0.5333333333333333,
|
1070 |
+
"grad_norm": 0.8702377525213307,
|
1071 |
+
"learning_rate": 3.884057971014493e-05,
|
1072 |
+
"loss": 1.0416,
|
1073 |
+
"step": 152
|
1074 |
+
},
|
1075 |
+
{
|
1076 |
+
"epoch": 0.5368421052631579,
|
1077 |
+
"grad_norm": 0.9408998854641563,
|
1078 |
+
"learning_rate": 3.855072463768116e-05,
|
1079 |
+
"loss": 1.053,
|
1080 |
+
"step": 153
|
1081 |
+
},
|
1082 |
+
{
|
1083 |
+
"epoch": 0.5403508771929825,
|
1084 |
+
"grad_norm": 0.913519043609596,
|
1085 |
+
"learning_rate": 3.8260869565217395e-05,
|
1086 |
+
"loss": 1.0653,
|
1087 |
+
"step": 154
|
1088 |
+
},
|
1089 |
+
{
|
1090 |
+
"epoch": 0.543859649122807,
|
1091 |
+
"grad_norm": 1.0325941411560875,
|
1092 |
+
"learning_rate": 3.797101449275363e-05,
|
1093 |
+
"loss": 1.0248,
|
1094 |
+
"step": 155
|
1095 |
+
},
|
1096 |
+
{
|
1097 |
+
"epoch": 0.5473684210526316,
|
1098 |
+
"grad_norm": 1.0088857759548826,
|
1099 |
+
"learning_rate": 3.7681159420289856e-05,
|
1100 |
+
"loss": 1.0984,
|
1101 |
+
"step": 156
|
1102 |
+
},
|
1103 |
+
{
|
1104 |
+
"epoch": 0.5508771929824562,
|
1105 |
+
"grad_norm": 0.9428277439596274,
|
1106 |
+
"learning_rate": 3.739130434782609e-05,
|
1107 |
+
"loss": 1.0176,
|
1108 |
+
"step": 157
|
1109 |
+
},
|
1110 |
+
{
|
1111 |
+
"epoch": 0.5543859649122806,
|
1112 |
+
"grad_norm": 0.9286332315925182,
|
1113 |
+
"learning_rate": 3.7101449275362325e-05,
|
1114 |
+
"loss": 1.0141,
|
1115 |
+
"step": 158
|
1116 |
+
},
|
1117 |
+
{
|
1118 |
+
"epoch": 0.5578947368421052,
|
1119 |
+
"grad_norm": 0.8869336003769103,
|
1120 |
+
"learning_rate": 3.681159420289855e-05,
|
1121 |
+
"loss": 1.0075,
|
1122 |
+
"step": 159
|
1123 |
+
},
|
1124 |
+
{
|
1125 |
+
"epoch": 0.5614035087719298,
|
1126 |
+
"grad_norm": 0.8749772917176272,
|
1127 |
+
"learning_rate": 3.6521739130434786e-05,
|
1128 |
+
"loss": 0.9922,
|
1129 |
+
"step": 160
|
1130 |
+
},
|
1131 |
+
{
|
1132 |
+
"epoch": 0.5649122807017544,
|
1133 |
+
"grad_norm": 0.9177592855322187,
|
1134 |
+
"learning_rate": 3.623188405797102e-05,
|
1135 |
+
"loss": 1.047,
|
1136 |
+
"step": 161
|
1137 |
+
},
|
1138 |
+
{
|
1139 |
+
"epoch": 0.5684210526315789,
|
1140 |
+
"grad_norm": 0.9681450836764032,
|
1141 |
+
"learning_rate": 3.594202898550725e-05,
|
1142 |
+
"loss": 0.9947,
|
1143 |
+
"step": 162
|
1144 |
+
},
|
1145 |
+
{
|
1146 |
+
"epoch": 0.5719298245614035,
|
1147 |
+
"grad_norm": 0.8944949579910934,
|
1148 |
+
"learning_rate": 3.565217391304348e-05,
|
1149 |
+
"loss": 1.0414,
|
1150 |
+
"step": 163
|
1151 |
+
},
|
1152 |
+
{
|
1153 |
+
"epoch": 0.5754385964912281,
|
1154 |
+
"grad_norm": 0.823418699987978,
|
1155 |
+
"learning_rate": 3.5362318840579716e-05,
|
1156 |
+
"loss": 0.9991,
|
1157 |
+
"step": 164
|
1158 |
+
},
|
1159 |
+
{
|
1160 |
+
"epoch": 0.5789473684210527,
|
1161 |
+
"grad_norm": 0.9010716175104698,
|
1162 |
+
"learning_rate": 3.5072463768115943e-05,
|
1163 |
+
"loss": 0.957,
|
1164 |
+
"step": 165
|
1165 |
+
},
|
1166 |
+
{
|
1167 |
+
"epoch": 0.5824561403508772,
|
1168 |
+
"grad_norm": 0.8553233244911422,
|
1169 |
+
"learning_rate": 3.478260869565218e-05,
|
1170 |
+
"loss": 0.9758,
|
1171 |
+
"step": 166
|
1172 |
+
},
|
1173 |
+
{
|
1174 |
+
"epoch": 0.5859649122807018,
|
1175 |
+
"grad_norm": 0.8955709532913586,
|
1176 |
+
"learning_rate": 3.449275362318841e-05,
|
1177 |
+
"loss": 1.0323,
|
1178 |
+
"step": 167
|
1179 |
+
},
|
1180 |
+
{
|
1181 |
+
"epoch": 0.5894736842105263,
|
1182 |
+
"grad_norm": 0.9632249383426715,
|
1183 |
+
"learning_rate": 3.420289855072464e-05,
|
1184 |
+
"loss": 1.0214,
|
1185 |
+
"step": 168
|
1186 |
+
},
|
1187 |
+
{
|
1188 |
+
"epoch": 0.5929824561403508,
|
1189 |
+
"grad_norm": 1.0070882268479324,
|
1190 |
+
"learning_rate": 3.391304347826087e-05,
|
1191 |
+
"loss": 1.0443,
|
1192 |
+
"step": 169
|
1193 |
+
},
|
1194 |
+
{
|
1195 |
+
"epoch": 0.5964912280701754,
|
1196 |
+
"grad_norm": 0.9089812750457459,
|
1197 |
+
"learning_rate": 3.36231884057971e-05,
|
1198 |
+
"loss": 0.9986,
|
1199 |
+
"step": 170
|
1200 |
+
},
|
1201 |
+
{
|
1202 |
+
"epoch": 0.6,
|
1203 |
+
"grad_norm": 0.9687903432716775,
|
1204 |
+
"learning_rate": 3.3333333333333335e-05,
|
1205 |
+
"loss": 1.0469,
|
1206 |
+
"step": 171
|
1207 |
+
},
|
1208 |
+
{
|
1209 |
+
"epoch": 0.6035087719298246,
|
1210 |
+
"grad_norm": 0.9065456102432492,
|
1211 |
+
"learning_rate": 3.304347826086957e-05,
|
1212 |
+
"loss": 1.0736,
|
1213 |
+
"step": 172
|
1214 |
+
},
|
1215 |
+
{
|
1216 |
+
"epoch": 0.6070175438596491,
|
1217 |
+
"grad_norm": 0.8191700226087758,
|
1218 |
+
"learning_rate": 3.2753623188405796e-05,
|
1219 |
+
"loss": 0.9516,
|
1220 |
+
"step": 173
|
1221 |
+
},
|
1222 |
+
{
|
1223 |
+
"epoch": 0.6105263157894737,
|
1224 |
+
"grad_norm": 0.910478607503674,
|
1225 |
+
"learning_rate": 3.246376811594203e-05,
|
1226 |
+
"loss": 1.0594,
|
1227 |
+
"step": 174
|
1228 |
+
},
|
1229 |
+
{
|
1230 |
+
"epoch": 0.6140350877192983,
|
1231 |
+
"grad_norm": 0.9847223979786262,
|
1232 |
+
"learning_rate": 3.2173913043478265e-05,
|
1233 |
+
"loss": 1.0592,
|
1234 |
+
"step": 175
|
1235 |
+
},
|
1236 |
+
{
|
1237 |
+
"epoch": 0.6175438596491228,
|
1238 |
+
"grad_norm": 0.9377862201207361,
|
1239 |
+
"learning_rate": 3.188405797101449e-05,
|
1240 |
+
"loss": 1.0477,
|
1241 |
+
"step": 176
|
1242 |
+
},
|
1243 |
+
{
|
1244 |
+
"epoch": 0.6210526315789474,
|
1245 |
+
"grad_norm": 0.9077059344710785,
|
1246 |
+
"learning_rate": 3.1594202898550726e-05,
|
1247 |
+
"loss": 1.0394,
|
1248 |
+
"step": 177
|
1249 |
+
},
|
1250 |
+
{
|
1251 |
+
"epoch": 0.624561403508772,
|
1252 |
+
"grad_norm": 1.038075786423051,
|
1253 |
+
"learning_rate": 3.130434782608696e-05,
|
1254 |
+
"loss": 1.0548,
|
1255 |
+
"step": 178
|
1256 |
+
},
|
1257 |
+
{
|
1258 |
+
"epoch": 0.6280701754385964,
|
1259 |
+
"grad_norm": 0.9160209790965669,
|
1260 |
+
"learning_rate": 3.101449275362319e-05,
|
1261 |
+
"loss": 0.9976,
|
1262 |
+
"step": 179
|
1263 |
+
},
|
1264 |
+
{
|
1265 |
+
"epoch": 0.631578947368421,
|
1266 |
+
"grad_norm": 0.8109415841452218,
|
1267 |
+
"learning_rate": 3.072463768115942e-05,
|
1268 |
+
"loss": 1.0091,
|
1269 |
+
"step": 180
|
1270 |
+
},
|
1271 |
+
{
|
1272 |
+
"epoch": 0.6350877192982456,
|
1273 |
+
"grad_norm": 0.8492567440061373,
|
1274 |
+
"learning_rate": 3.0434782608695656e-05,
|
1275 |
+
"loss": 1.0038,
|
1276 |
+
"step": 181
|
1277 |
+
},
|
1278 |
+
{
|
1279 |
+
"epoch": 0.6385964912280702,
|
1280 |
+
"grad_norm": 0.9589169451188458,
|
1281 |
+
"learning_rate": 3.0144927536231887e-05,
|
1282 |
+
"loss": 1.0207,
|
1283 |
+
"step": 182
|
1284 |
+
},
|
1285 |
+
{
|
1286 |
+
"epoch": 0.6421052631578947,
|
1287 |
+
"grad_norm": 0.8848409951191845,
|
1288 |
+
"learning_rate": 2.9855072463768118e-05,
|
1289 |
+
"loss": 0.9767,
|
1290 |
+
"step": 183
|
1291 |
+
},
|
1292 |
+
{
|
1293 |
+
"epoch": 0.6456140350877193,
|
1294 |
+
"grad_norm": 0.8955318088948372,
|
1295 |
+
"learning_rate": 2.956521739130435e-05,
|
1296 |
+
"loss": 1.0078,
|
1297 |
+
"step": 184
|
1298 |
+
},
|
1299 |
+
{
|
1300 |
+
"epoch": 0.6491228070175439,
|
1301 |
+
"grad_norm": 0.8900555696345945,
|
1302 |
+
"learning_rate": 2.9275362318840583e-05,
|
1303 |
+
"loss": 1.058,
|
1304 |
+
"step": 185
|
1305 |
+
},
|
1306 |
+
{
|
1307 |
+
"epoch": 0.6526315789473685,
|
1308 |
+
"grad_norm": 0.9579354937026371,
|
1309 |
+
"learning_rate": 2.8985507246376814e-05,
|
1310 |
+
"loss": 1.0052,
|
1311 |
+
"step": 186
|
1312 |
+
},
|
1313 |
+
{
|
1314 |
+
"epoch": 0.656140350877193,
|
1315 |
+
"grad_norm": 0.8773237300221255,
|
1316 |
+
"learning_rate": 2.8695652173913044e-05,
|
1317 |
+
"loss": 1.0132,
|
1318 |
+
"step": 187
|
1319 |
+
},
|
1320 |
+
{
|
1321 |
+
"epoch": 0.6596491228070176,
|
1322 |
+
"grad_norm": 0.9290671958630004,
|
1323 |
+
"learning_rate": 2.840579710144928e-05,
|
1324 |
+
"loss": 0.9978,
|
1325 |
+
"step": 188
|
1326 |
+
},
|
1327 |
+
{
|
1328 |
+
"epoch": 0.6631578947368421,
|
1329 |
+
"grad_norm": 0.9098091343168585,
|
1330 |
+
"learning_rate": 2.811594202898551e-05,
|
1331 |
+
"loss": 0.986,
|
1332 |
+
"step": 189
|
1333 |
+
},
|
1334 |
+
{
|
1335 |
+
"epoch": 0.6666666666666666,
|
1336 |
+
"grad_norm": 0.9494694332915156,
|
1337 |
+
"learning_rate": 2.782608695652174e-05,
|
1338 |
+
"loss": 1.0194,
|
1339 |
+
"step": 190
|
1340 |
+
},
|
1341 |
+
{
|
1342 |
+
"epoch": 0.6701754385964912,
|
1343 |
+
"grad_norm": 0.8801338941113726,
|
1344 |
+
"learning_rate": 2.753623188405797e-05,
|
1345 |
+
"loss": 0.969,
|
1346 |
+
"step": 191
|
1347 |
+
},
|
1348 |
+
{
|
1349 |
+
"epoch": 0.6736842105263158,
|
1350 |
+
"grad_norm": 0.9510753232451794,
|
1351 |
+
"learning_rate": 2.7246376811594205e-05,
|
1352 |
+
"loss": 0.9742,
|
1353 |
+
"step": 192
|
1354 |
+
},
|
1355 |
+
{
|
1356 |
+
"epoch": 0.6771929824561403,
|
1357 |
+
"grad_norm": 0.9589458183246781,
|
1358 |
+
"learning_rate": 2.6956521739130436e-05,
|
1359 |
+
"loss": 1.0525,
|
1360 |
+
"step": 193
|
1361 |
+
},
|
1362 |
+
{
|
1363 |
+
"epoch": 0.6807017543859649,
|
1364 |
+
"grad_norm": 0.879997612951922,
|
1365 |
+
"learning_rate": 2.6666666666666667e-05,
|
1366 |
+
"loss": 0.9824,
|
1367 |
+
"step": 194
|
1368 |
+
},
|
1369 |
+
{
|
1370 |
+
"epoch": 0.6842105263157895,
|
1371 |
+
"grad_norm": 0.8389910470867041,
|
1372 |
+
"learning_rate": 2.63768115942029e-05,
|
1373 |
+
"loss": 1.0056,
|
1374 |
+
"step": 195
|
1375 |
+
},
|
1376 |
+
{
|
1377 |
+
"epoch": 0.6877192982456141,
|
1378 |
+
"grad_norm": 0.9163566396967311,
|
1379 |
+
"learning_rate": 2.608695652173913e-05,
|
1380 |
+
"loss": 0.9976,
|
1381 |
+
"step": 196
|
1382 |
+
},
|
1383 |
+
{
|
1384 |
+
"epoch": 0.6912280701754386,
|
1385 |
+
"grad_norm": 0.9772320516342279,
|
1386 |
+
"learning_rate": 2.5797101449275362e-05,
|
1387 |
+
"loss": 1.0338,
|
1388 |
+
"step": 197
|
1389 |
+
},
|
1390 |
+
{
|
1391 |
+
"epoch": 0.6947368421052632,
|
1392 |
+
"grad_norm": 0.960770516269451,
|
1393 |
+
"learning_rate": 2.5507246376811593e-05,
|
1394 |
+
"loss": 1.0611,
|
1395 |
+
"step": 198
|
1396 |
+
},
|
1397 |
+
{
|
1398 |
+
"epoch": 0.6982456140350877,
|
1399 |
+
"grad_norm": 0.8890098864104716,
|
1400 |
+
"learning_rate": 2.521739130434783e-05,
|
1401 |
+
"loss": 1.0168,
|
1402 |
+
"step": 199
|
1403 |
+
},
|
1404 |
+
{
|
1405 |
+
"epoch": 0.7017543859649122,
|
1406 |
+
"grad_norm": 0.8658933316106927,
|
1407 |
+
"learning_rate": 2.4927536231884058e-05,
|
1408 |
+
"loss": 1.011,
|
1409 |
+
"step": 200
|
1410 |
+
},
|
1411 |
+
{
|
1412 |
+
"epoch": 0.7052631578947368,
|
1413 |
+
"grad_norm": 0.8576704263418472,
|
1414 |
+
"learning_rate": 2.463768115942029e-05,
|
1415 |
+
"loss": 0.9807,
|
1416 |
+
"step": 201
|
1417 |
+
},
|
1418 |
+
{
|
1419 |
+
"epoch": 0.7087719298245614,
|
1420 |
+
"grad_norm": 0.9186773959277461,
|
1421 |
+
"learning_rate": 2.4347826086956526e-05,
|
1422 |
+
"loss": 0.9284,
|
1423 |
+
"step": 202
|
1424 |
+
},
|
1425 |
+
{
|
1426 |
+
"epoch": 0.712280701754386,
|
1427 |
+
"grad_norm": 0.858587966202896,
|
1428 |
+
"learning_rate": 2.4057971014492757e-05,
|
1429 |
+
"loss": 0.9795,
|
1430 |
+
"step": 203
|
1431 |
+
},
|
1432 |
+
{
|
1433 |
+
"epoch": 0.7157894736842105,
|
1434 |
+
"grad_norm": 0.9422658689165894,
|
1435 |
+
"learning_rate": 2.3768115942028988e-05,
|
1436 |
+
"loss": 0.9764,
|
1437 |
+
"step": 204
|
1438 |
+
},
|
1439 |
+
{
|
1440 |
+
"epoch": 0.7192982456140351,
|
1441 |
+
"grad_norm": 1.0137944232610083,
|
1442 |
+
"learning_rate": 2.3478260869565222e-05,
|
1443 |
+
"loss": 1.0627,
|
1444 |
+
"step": 205
|
1445 |
+
},
|
1446 |
+
{
|
1447 |
+
"epoch": 0.7228070175438597,
|
1448 |
+
"grad_norm": 0.9853442185067721,
|
1449 |
+
"learning_rate": 2.3188405797101453e-05,
|
1450 |
+
"loss": 1.0289,
|
1451 |
+
"step": 206
|
1452 |
+
},
|
1453 |
+
{
|
1454 |
+
"epoch": 0.7263157894736842,
|
1455 |
+
"grad_norm": 0.8923047177872453,
|
1456 |
+
"learning_rate": 2.2898550724637684e-05,
|
1457 |
+
"loss": 1.0172,
|
1458 |
+
"step": 207
|
1459 |
+
},
|
1460 |
+
{
|
1461 |
+
"epoch": 0.7298245614035088,
|
1462 |
+
"grad_norm": 0.8439161677593868,
|
1463 |
+
"learning_rate": 2.2608695652173914e-05,
|
1464 |
+
"loss": 1.0484,
|
1465 |
+
"step": 208
|
1466 |
+
},
|
1467 |
+
{
|
1468 |
+
"epoch": 0.7333333333333333,
|
1469 |
+
"grad_norm": 0.8201410283081917,
|
1470 |
+
"learning_rate": 2.231884057971015e-05,
|
1471 |
+
"loss": 1.0168,
|
1472 |
+
"step": 209
|
1473 |
+
},
|
1474 |
+
{
|
1475 |
+
"epoch": 0.7368421052631579,
|
1476 |
+
"grad_norm": 0.8442899557106462,
|
1477 |
+
"learning_rate": 2.202898550724638e-05,
|
1478 |
+
"loss": 0.9728,
|
1479 |
+
"step": 210
|
1480 |
+
},
|
1481 |
+
{
|
1482 |
+
"epoch": 0.7403508771929824,
|
1483 |
+
"grad_norm": 0.9098630031184369,
|
1484 |
+
"learning_rate": 2.173913043478261e-05,
|
1485 |
+
"loss": 1.0304,
|
1486 |
+
"step": 211
|
1487 |
+
},
|
1488 |
+
{
|
1489 |
+
"epoch": 0.743859649122807,
|
1490 |
+
"grad_norm": 0.8217923688708064,
|
1491 |
+
"learning_rate": 2.1449275362318844e-05,
|
1492 |
+
"loss": 1.0334,
|
1493 |
+
"step": 212
|
1494 |
+
},
|
1495 |
+
{
|
1496 |
+
"epoch": 0.7473684210526316,
|
1497 |
+
"grad_norm": 0.8420848196609938,
|
1498 |
+
"learning_rate": 2.1159420289855075e-05,
|
1499 |
+
"loss": 0.9665,
|
1500 |
+
"step": 213
|
1501 |
+
},
|
1502 |
+
{
|
1503 |
+
"epoch": 0.7508771929824561,
|
1504 |
+
"grad_norm": 0.8810436312516507,
|
1505 |
+
"learning_rate": 2.0869565217391306e-05,
|
1506 |
+
"loss": 0.9792,
|
1507 |
+
"step": 214
|
1508 |
+
},
|
1509 |
+
{
|
1510 |
+
"epoch": 0.7543859649122807,
|
1511 |
+
"grad_norm": 0.9749166994556522,
|
1512 |
+
"learning_rate": 2.0579710144927537e-05,
|
1513 |
+
"loss": 1.0163,
|
1514 |
+
"step": 215
|
1515 |
+
},
|
1516 |
+
{
|
1517 |
+
"epoch": 0.7578947368421053,
|
1518 |
+
"grad_norm": 0.9619307294480671,
|
1519 |
+
"learning_rate": 2.028985507246377e-05,
|
1520 |
+
"loss": 1.0276,
|
1521 |
+
"step": 216
|
1522 |
+
},
|
1523 |
+
{
|
1524 |
+
"epoch": 0.7614035087719299,
|
1525 |
+
"grad_norm": 0.8475320304538961,
|
1526 |
+
"learning_rate": 2e-05,
|
1527 |
+
"loss": 1.0175,
|
1528 |
+
"step": 217
|
1529 |
+
},
|
1530 |
+
{
|
1531 |
+
"epoch": 0.7649122807017544,
|
1532 |
+
"grad_norm": 0.9215056645276478,
|
1533 |
+
"learning_rate": 1.9710144927536236e-05,
|
1534 |
+
"loss": 1.0349,
|
1535 |
+
"step": 218
|
1536 |
+
},
|
1537 |
+
{
|
1538 |
+
"epoch": 0.7684210526315789,
|
1539 |
+
"grad_norm": 0.8318566015217065,
|
1540 |
+
"learning_rate": 1.9420289855072467e-05,
|
1541 |
+
"loss": 0.9736,
|
1542 |
+
"step": 219
|
1543 |
+
},
|
1544 |
+
{
|
1545 |
+
"epoch": 0.7719298245614035,
|
1546 |
+
"grad_norm": 0.8841348427961992,
|
1547 |
+
"learning_rate": 1.9130434782608697e-05,
|
1548 |
+
"loss": 1.0028,
|
1549 |
+
"step": 220
|
1550 |
+
},
|
1551 |
+
{
|
1552 |
+
"epoch": 0.775438596491228,
|
1553 |
+
"grad_norm": 0.8726663458778539,
|
1554 |
+
"learning_rate": 1.8840579710144928e-05,
|
1555 |
+
"loss": 0.9837,
|
1556 |
+
"step": 221
|
1557 |
+
},
|
1558 |
+
{
|
1559 |
+
"epoch": 0.7789473684210526,
|
1560 |
+
"grad_norm": 0.8933308297868434,
|
1561 |
+
"learning_rate": 1.8550724637681162e-05,
|
1562 |
+
"loss": 0.9875,
|
1563 |
+
"step": 222
|
1564 |
+
},
|
1565 |
+
{
|
1566 |
+
"epoch": 0.7824561403508772,
|
1567 |
+
"grad_norm": 0.8473190274519702,
|
1568 |
+
"learning_rate": 1.8260869565217393e-05,
|
1569 |
+
"loss": 0.9822,
|
1570 |
+
"step": 223
|
1571 |
+
},
|
1572 |
+
{
|
1573 |
+
"epoch": 0.7859649122807018,
|
1574 |
+
"grad_norm": 0.8786630261494585,
|
1575 |
+
"learning_rate": 1.7971014492753624e-05,
|
1576 |
+
"loss": 0.9785,
|
1577 |
+
"step": 224
|
1578 |
+
},
|
1579 |
+
{
|
1580 |
+
"epoch": 0.7894736842105263,
|
1581 |
+
"grad_norm": 0.8769937018569535,
|
1582 |
+
"learning_rate": 1.7681159420289858e-05,
|
1583 |
+
"loss": 0.9863,
|
1584 |
+
"step": 225
|
1585 |
+
},
|
1586 |
+
{
|
1587 |
+
"epoch": 0.7929824561403509,
|
1588 |
+
"grad_norm": 0.9418240902774399,
|
1589 |
+
"learning_rate": 1.739130434782609e-05,
|
1590 |
+
"loss": 0.997,
|
1591 |
+
"step": 226
|
1592 |
+
},
|
1593 |
+
{
|
1594 |
+
"epoch": 0.7964912280701755,
|
1595 |
+
"grad_norm": 0.9360134126214504,
|
1596 |
+
"learning_rate": 1.710144927536232e-05,
|
1597 |
+
"loss": 0.9863,
|
1598 |
+
"step": 227
|
1599 |
+
},
|
1600 |
+
{
|
1601 |
+
"epoch": 0.8,
|
1602 |
+
"grad_norm": 0.999458819703,
|
1603 |
+
"learning_rate": 1.681159420289855e-05,
|
1604 |
+
"loss": 0.9498,
|
1605 |
+
"step": 228
|
1606 |
+
},
|
1607 |
+
{
|
1608 |
+
"epoch": 0.8035087719298246,
|
1609 |
+
"grad_norm": 0.8238131544325801,
|
1610 |
+
"learning_rate": 1.6521739130434785e-05,
|
1611 |
+
"loss": 0.9609,
|
1612 |
+
"step": 229
|
1613 |
+
},
|
1614 |
+
{
|
1615 |
+
"epoch": 0.8070175438596491,
|
1616 |
+
"grad_norm": 0.9110168722541372,
|
1617 |
+
"learning_rate": 1.6231884057971015e-05,
|
1618 |
+
"loss": 0.9726,
|
1619 |
+
"step": 230
|
1620 |
+
},
|
1621 |
+
{
|
1622 |
+
"epoch": 0.8105263157894737,
|
1623 |
+
"grad_norm": 0.915280887700176,
|
1624 |
+
"learning_rate": 1.5942028985507246e-05,
|
1625 |
+
"loss": 0.9687,
|
1626 |
+
"step": 231
|
1627 |
+
},
|
1628 |
+
{
|
1629 |
+
"epoch": 0.8140350877192982,
|
1630 |
+
"grad_norm": 0.8997906447720105,
|
1631 |
+
"learning_rate": 1.565217391304348e-05,
|
1632 |
+
"loss": 1.0236,
|
1633 |
+
"step": 232
|
1634 |
+
},
|
1635 |
+
{
|
1636 |
+
"epoch": 0.8175438596491228,
|
1637 |
+
"grad_norm": 0.8927454629454755,
|
1638 |
+
"learning_rate": 1.536231884057971e-05,
|
1639 |
+
"loss": 0.96,
|
1640 |
+
"step": 233
|
1641 |
+
},
|
1642 |
+
{
|
1643 |
+
"epoch": 0.8210526315789474,
|
1644 |
+
"grad_norm": 0.9150163082832309,
|
1645 |
+
"learning_rate": 1.5072463768115944e-05,
|
1646 |
+
"loss": 0.9843,
|
1647 |
+
"step": 234
|
1648 |
+
},
|
1649 |
+
{
|
1650 |
+
"epoch": 0.8245614035087719,
|
1651 |
+
"grad_norm": 0.9497695522124332,
|
1652 |
+
"learning_rate": 1.4782608695652174e-05,
|
1653 |
+
"loss": 1.0254,
|
1654 |
+
"step": 235
|
1655 |
+
},
|
1656 |
+
{
|
1657 |
+
"epoch": 0.8280701754385965,
|
1658 |
+
"grad_norm": 0.8134079237524361,
|
1659 |
+
"learning_rate": 1.4492753623188407e-05,
|
1660 |
+
"loss": 0.9874,
|
1661 |
+
"step": 236
|
1662 |
+
},
|
1663 |
+
{
|
1664 |
+
"epoch": 0.8315789473684211,
|
1665 |
+
"grad_norm": 0.854532647109886,
|
1666 |
+
"learning_rate": 1.420289855072464e-05,
|
1667 |
+
"loss": 0.9697,
|
1668 |
+
"step": 237
|
1669 |
+
},
|
1670 |
+
{
|
1671 |
+
"epoch": 0.8350877192982457,
|
1672 |
+
"grad_norm": 0.902401593136911,
|
1673 |
+
"learning_rate": 1.391304347826087e-05,
|
1674 |
+
"loss": 1.0083,
|
1675 |
+
"step": 238
|
1676 |
+
},
|
1677 |
+
{
|
1678 |
+
"epoch": 0.8385964912280702,
|
1679 |
+
"grad_norm": 0.8365313967364223,
|
1680 |
+
"learning_rate": 1.3623188405797103e-05,
|
1681 |
+
"loss": 0.9479,
|
1682 |
+
"step": 239
|
1683 |
+
},
|
1684 |
+
{
|
1685 |
+
"epoch": 0.8421052631578947,
|
1686 |
+
"grad_norm": 0.8385782446580461,
|
1687 |
+
"learning_rate": 1.3333333333333333e-05,
|
1688 |
+
"loss": 0.998,
|
1689 |
+
"step": 240
|
1690 |
+
},
|
1691 |
+
{
|
1692 |
+
"epoch": 0.8456140350877193,
|
1693 |
+
"grad_norm": 0.9130856203558422,
|
1694 |
+
"learning_rate": 1.3043478260869566e-05,
|
1695 |
+
"loss": 0.9934,
|
1696 |
+
"step": 241
|
1697 |
+
},
|
1698 |
+
{
|
1699 |
+
"epoch": 0.8491228070175438,
|
1700 |
+
"grad_norm": 0.8261442785562587,
|
1701 |
+
"learning_rate": 1.2753623188405797e-05,
|
1702 |
+
"loss": 0.9274,
|
1703 |
+
"step": 242
|
1704 |
+
},
|
1705 |
+
{
|
1706 |
+
"epoch": 0.8526315789473684,
|
1707 |
+
"grad_norm": 0.8560538840518993,
|
1708 |
+
"learning_rate": 1.2463768115942029e-05,
|
1709 |
+
"loss": 0.9511,
|
1710 |
+
"step": 243
|
1711 |
+
},
|
1712 |
+
{
|
1713 |
+
"epoch": 0.856140350877193,
|
1714 |
+
"grad_norm": 0.8699104552871371,
|
1715 |
+
"learning_rate": 1.2173913043478263e-05,
|
1716 |
+
"loss": 0.958,
|
1717 |
+
"step": 244
|
1718 |
+
},
|
1719 |
+
{
|
1720 |
+
"epoch": 0.8596491228070176,
|
1721 |
+
"grad_norm": 0.9107920631411749,
|
1722 |
+
"learning_rate": 1.1884057971014494e-05,
|
1723 |
+
"loss": 1.0177,
|
1724 |
+
"step": 245
|
1725 |
+
},
|
1726 |
+
{
|
1727 |
+
"epoch": 0.8631578947368421,
|
1728 |
+
"grad_norm": 0.8776802277406592,
|
1729 |
+
"learning_rate": 1.1594202898550726e-05,
|
1730 |
+
"loss": 0.9261,
|
1731 |
+
"step": 246
|
1732 |
+
},
|
1733 |
+
{
|
1734 |
+
"epoch": 0.8666666666666667,
|
1735 |
+
"grad_norm": 0.8999713914824392,
|
1736 |
+
"learning_rate": 1.1304347826086957e-05,
|
1737 |
+
"loss": 0.9973,
|
1738 |
+
"step": 247
|
1739 |
+
},
|
1740 |
+
{
|
1741 |
+
"epoch": 0.8701754385964913,
|
1742 |
+
"grad_norm": 0.8835866950552989,
|
1743 |
+
"learning_rate": 1.101449275362319e-05,
|
1744 |
+
"loss": 1.0028,
|
1745 |
+
"step": 248
|
1746 |
+
},
|
1747 |
+
{
|
1748 |
+
"epoch": 0.8736842105263158,
|
1749 |
+
"grad_norm": 0.9243563863707843,
|
1750 |
+
"learning_rate": 1.0724637681159422e-05,
|
1751 |
+
"loss": 0.9971,
|
1752 |
+
"step": 249
|
1753 |
+
},
|
1754 |
+
{
|
1755 |
+
"epoch": 0.8771929824561403,
|
1756 |
+
"grad_norm": 0.9287603572835252,
|
1757 |
+
"learning_rate": 1.0434782608695653e-05,
|
1758 |
+
"loss": 0.9902,
|
1759 |
+
"step": 250
|
1760 |
+
},
|
1761 |
+
{
|
1762 |
+
"epoch": 0.8807017543859649,
|
1763 |
+
"grad_norm": 0.8670790287211418,
|
1764 |
+
"learning_rate": 1.0144927536231885e-05,
|
1765 |
+
"loss": 1.0039,
|
1766 |
+
"step": 251
|
1767 |
+
},
|
1768 |
+
{
|
1769 |
+
"epoch": 0.8842105263157894,
|
1770 |
+
"grad_norm": 0.8663791969051364,
|
1771 |
+
"learning_rate": 9.855072463768118e-06,
|
1772 |
+
"loss": 0.9817,
|
1773 |
+
"step": 252
|
1774 |
+
},
|
1775 |
+
{
|
1776 |
+
"epoch": 0.887719298245614,
|
1777 |
+
"grad_norm": 0.8631015068740149,
|
1778 |
+
"learning_rate": 9.565217391304349e-06,
|
1779 |
+
"loss": 1.0173,
|
1780 |
+
"step": 253
|
1781 |
+
},
|
1782 |
+
{
|
1783 |
+
"epoch": 0.8912280701754386,
|
1784 |
+
"grad_norm": 0.8829365467183184,
|
1785 |
+
"learning_rate": 9.275362318840581e-06,
|
1786 |
+
"loss": 0.9578,
|
1787 |
+
"step": 254
|
1788 |
+
},
|
1789 |
+
{
|
1790 |
+
"epoch": 0.8947368421052632,
|
1791 |
+
"grad_norm": 0.9001038483145964,
|
1792 |
+
"learning_rate": 8.985507246376812e-06,
|
1793 |
+
"loss": 1.0258,
|
1794 |
+
"step": 255
|
1795 |
+
},
|
1796 |
+
{
|
1797 |
+
"epoch": 0.8982456140350877,
|
1798 |
+
"grad_norm": 0.8834099073060356,
|
1799 |
+
"learning_rate": 8.695652173913044e-06,
|
1800 |
+
"loss": 0.9726,
|
1801 |
+
"step": 256
|
1802 |
+
},
|
1803 |
+
{
|
1804 |
+
"epoch": 0.9017543859649123,
|
1805 |
+
"grad_norm": 0.8221574328830703,
|
1806 |
+
"learning_rate": 8.405797101449275e-06,
|
1807 |
+
"loss": 0.9318,
|
1808 |
+
"step": 257
|
1809 |
+
},
|
1810 |
+
{
|
1811 |
+
"epoch": 0.9052631578947369,
|
1812 |
+
"grad_norm": 0.8603145991699224,
|
1813 |
+
"learning_rate": 8.115942028985508e-06,
|
1814 |
+
"loss": 0.9663,
|
1815 |
+
"step": 258
|
1816 |
+
},
|
1817 |
+
{
|
1818 |
+
"epoch": 0.9087719298245615,
|
1819 |
+
"grad_norm": 0.8557514339905812,
|
1820 |
+
"learning_rate": 7.82608695652174e-06,
|
1821 |
+
"loss": 0.9968,
|
1822 |
+
"step": 259
|
1823 |
+
},
|
1824 |
+
{
|
1825 |
+
"epoch": 0.9122807017543859,
|
1826 |
+
"grad_norm": 0.8263665060539463,
|
1827 |
+
"learning_rate": 7.536231884057972e-06,
|
1828 |
+
"loss": 1.0022,
|
1829 |
+
"step": 260
|
1830 |
+
},
|
1831 |
+
{
|
1832 |
+
"epoch": 0.9157894736842105,
|
1833 |
+
"grad_norm": 0.9157072836324722,
|
1834 |
+
"learning_rate": 7.246376811594203e-06,
|
1835 |
+
"loss": 0.9387,
|
1836 |
+
"step": 261
|
1837 |
+
},
|
1838 |
+
{
|
1839 |
+
"epoch": 0.9192982456140351,
|
1840 |
+
"grad_norm": 0.9233305451677062,
|
1841 |
+
"learning_rate": 6.956521739130435e-06,
|
1842 |
+
"loss": 0.9934,
|
1843 |
+
"step": 262
|
1844 |
+
},
|
1845 |
+
{
|
1846 |
+
"epoch": 0.9228070175438596,
|
1847 |
+
"grad_norm": 0.903604456186341,
|
1848 |
+
"learning_rate": 6.666666666666667e-06,
|
1849 |
+
"loss": 0.9502,
|
1850 |
+
"step": 263
|
1851 |
+
},
|
1852 |
+
{
|
1853 |
+
"epoch": 0.9263157894736842,
|
1854 |
+
"grad_norm": 0.9285076793745337,
|
1855 |
+
"learning_rate": 6.376811594202898e-06,
|
1856 |
+
"loss": 0.9645,
|
1857 |
+
"step": 264
|
1858 |
+
},
|
1859 |
+
{
|
1860 |
+
"epoch": 0.9298245614035088,
|
1861 |
+
"grad_norm": 0.888909609341721,
|
1862 |
+
"learning_rate": 6.086956521739132e-06,
|
1863 |
+
"loss": 0.946,
|
1864 |
+
"step": 265
|
1865 |
+
},
|
1866 |
+
{
|
1867 |
+
"epoch": 0.9333333333333333,
|
1868 |
+
"grad_norm": 0.9438455431857006,
|
1869 |
+
"learning_rate": 5.797101449275363e-06,
|
1870 |
+
"loss": 1.0153,
|
1871 |
+
"step": 266
|
1872 |
+
},
|
1873 |
+
{
|
1874 |
+
"epoch": 0.9368421052631579,
|
1875 |
+
"grad_norm": 0.8551557910334344,
|
1876 |
+
"learning_rate": 5.507246376811595e-06,
|
1877 |
+
"loss": 0.958,
|
1878 |
+
"step": 267
|
1879 |
+
},
|
1880 |
+
{
|
1881 |
+
"epoch": 0.9403508771929825,
|
1882 |
+
"grad_norm": 0.8234220234488231,
|
1883 |
+
"learning_rate": 5.2173913043478265e-06,
|
1884 |
+
"loss": 0.96,
|
1885 |
+
"step": 268
|
1886 |
+
},
|
1887 |
+
{
|
1888 |
+
"epoch": 0.9438596491228071,
|
1889 |
+
"grad_norm": 0.9003874584417242,
|
1890 |
+
"learning_rate": 4.927536231884059e-06,
|
1891 |
+
"loss": 0.9757,
|
1892 |
+
"step": 269
|
1893 |
+
},
|
1894 |
+
{
|
1895 |
+
"epoch": 0.9473684210526315,
|
1896 |
+
"grad_norm": 0.89021747241037,
|
1897 |
+
"learning_rate": 4.637681159420291e-06,
|
1898 |
+
"loss": 0.9511,
|
1899 |
+
"step": 270
|
1900 |
+
},
|
1901 |
+
{
|
1902 |
+
"epoch": 0.9508771929824561,
|
1903 |
+
"grad_norm": 0.850549521859951,
|
1904 |
+
"learning_rate": 4.347826086956522e-06,
|
1905 |
+
"loss": 0.9619,
|
1906 |
+
"step": 271
|
1907 |
+
},
|
1908 |
+
{
|
1909 |
+
"epoch": 0.9543859649122807,
|
1910 |
+
"grad_norm": 0.8477206031920781,
|
1911 |
+
"learning_rate": 4.057971014492754e-06,
|
1912 |
+
"loss": 0.9169,
|
1913 |
+
"step": 272
|
1914 |
+
},
|
1915 |
+
{
|
1916 |
+
"epoch": 0.9578947368421052,
|
1917 |
+
"grad_norm": 0.9199733593357698,
|
1918 |
+
"learning_rate": 3.768115942028986e-06,
|
1919 |
+
"loss": 1.0299,
|
1920 |
+
"step": 273
|
1921 |
+
},
|
1922 |
+
{
|
1923 |
+
"epoch": 0.9614035087719298,
|
1924 |
+
"grad_norm": 0.8038841148302012,
|
1925 |
+
"learning_rate": 3.4782608695652175e-06,
|
1926 |
+
"loss": 0.9584,
|
1927 |
+
"step": 274
|
1928 |
+
},
|
1929 |
+
{
|
1930 |
+
"epoch": 0.9649122807017544,
|
1931 |
+
"grad_norm": 0.8488075839645941,
|
1932 |
+
"learning_rate": 3.188405797101449e-06,
|
1933 |
+
"loss": 0.9868,
|
1934 |
+
"step": 275
|
1935 |
+
},
|
1936 |
+
{
|
1937 |
+
"epoch": 0.968421052631579,
|
1938 |
+
"grad_norm": 0.8355215697229909,
|
1939 |
+
"learning_rate": 2.8985507246376816e-06,
|
1940 |
+
"loss": 1.009,
|
1941 |
+
"step": 276
|
1942 |
+
},
|
1943 |
+
{
|
1944 |
+
"epoch": 0.9719298245614035,
|
1945 |
+
"grad_norm": 0.9354156162463755,
|
1946 |
+
"learning_rate": 2.6086956521739132e-06,
|
1947 |
+
"loss": 0.9914,
|
1948 |
+
"step": 277
|
1949 |
+
},
|
1950 |
+
{
|
1951 |
+
"epoch": 0.9754385964912281,
|
1952 |
+
"grad_norm": 0.8504047654484729,
|
1953 |
+
"learning_rate": 2.3188405797101453e-06,
|
1954 |
+
"loss": 1.0137,
|
1955 |
+
"step": 278
|
1956 |
+
},
|
1957 |
+
{
|
1958 |
+
"epoch": 0.9789473684210527,
|
1959 |
+
"grad_norm": 0.9106574593705012,
|
1960 |
+
"learning_rate": 2.028985507246377e-06,
|
1961 |
+
"loss": 0.9963,
|
1962 |
+
"step": 279
|
1963 |
+
},
|
1964 |
+
{
|
1965 |
+
"epoch": 0.9824561403508771,
|
1966 |
+
"grad_norm": 0.8356909679028329,
|
1967 |
+
"learning_rate": 1.7391304347826088e-06,
|
1968 |
+
"loss": 1.0176,
|
1969 |
+
"step": 280
|
1970 |
+
},
|
1971 |
+
{
|
1972 |
+
"epoch": 0.9859649122807017,
|
1973 |
+
"grad_norm": 0.8904235043433295,
|
1974 |
+
"learning_rate": 1.4492753623188408e-06,
|
1975 |
+
"loss": 0.9684,
|
1976 |
+
"step": 281
|
1977 |
+
},
|
1978 |
+
{
|
1979 |
+
"epoch": 0.9894736842105263,
|
1980 |
+
"grad_norm": 0.8663330662929399,
|
1981 |
+
"learning_rate": 1.1594202898550726e-06,
|
1982 |
+
"loss": 0.9852,
|
1983 |
+
"step": 282
|
1984 |
+
},
|
1985 |
+
{
|
1986 |
+
"epoch": 0.9929824561403509,
|
1987 |
+
"grad_norm": 0.8453724734461978,
|
1988 |
+
"learning_rate": 8.695652173913044e-07,
|
1989 |
+
"loss": 0.9599,
|
1990 |
+
"step": 283
|
1991 |
+
},
|
1992 |
+
{
|
1993 |
+
"epoch": 0.9964912280701754,
|
1994 |
+
"grad_norm": 0.8659094349837689,
|
1995 |
+
"learning_rate": 5.797101449275363e-07,
|
1996 |
+
"loss": 1.0253,
|
1997 |
+
"step": 284
|
1998 |
+
},
|
1999 |
+
{
|
2000 |
+
"epoch": 1.0,
|
2001 |
+
"grad_norm": 0.8132420261672163,
|
2002 |
+
"learning_rate": 2.8985507246376816e-07,
|
2003 |
+
"loss": 0.8957,
|
2004 |
+
"step": 285
|
2005 |
+
},
|
2006 |
+
{
|
2007 |
+
"epoch": 1.0,
|
2008 |
+
"step": 285,
|
2009 |
+
"total_flos": 224781354270720.0,
|
2010 |
+
"train_loss": 1.0555618083267881,
|
2011 |
+
"train_runtime": 2779.4288,
|
2012 |
+
"train_samples_per_second": 52.454,
|
2013 |
+
"train_steps_per_second": 0.103
|
2014 |
+
}
|
2015 |
+
],
|
2016 |
+
"logging_steps": 1.0,
|
2017 |
+
"max_steps": 285,
|
2018 |
+
"num_input_tokens_seen": 0,
|
2019 |
+
"num_train_epochs": 1,
|
2020 |
+
"save_steps": 700,
|
2021 |
+
"total_flos": 224781354270720.0,
|
2022 |
+
"train_batch_size": 8,
|
2023 |
+
"trial_name": null,
|
2024 |
+
"trial_params": null
|
2025 |
+
}
|
training_args.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:1dca7fb36802253051575e9de9c44be43e98f54a18c8c686f622a8da95a7669a
|
3 |
+
size 7096
|
zero_to_fp32.py
ADDED
@@ -0,0 +1,604 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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Microsoft Corporation.
|
4 |
+
# SPDX-License-Identifier: Apache-2.0
|
5 |
+
|
6 |
+
# DeepSpeed Team
|
7 |
+
|
8 |
+
# This script extracts fp32 consolidated weights from a zero 1, 2 and 3 DeepSpeed checkpoints. It gets
|
9 |
+
# copied into the top level checkpoint dir, so the user can easily do the conversion at any point in
|
10 |
+
# the future. Once extracted, the weights don't require DeepSpeed and can be used in any
|
11 |
+
# application.
|
12 |
+
#
|
13 |
+
# example: python zero_to_fp32.py . pytorch_model.bin
|
14 |
+
|
15 |
+
import argparse
|
16 |
+
import torch
|
17 |
+
import glob
|
18 |
+
import math
|
19 |
+
import os
|
20 |
+
import re
|
21 |
+
from collections import OrderedDict
|
22 |
+
from dataclasses import dataclass
|
23 |
+
|
24 |
+
# while this script doesn't use deepspeed to recover data, since the checkpoints are pickled with
|
25 |
+
# DeepSpeed data structures it has to be available in the current python environment.
|
26 |
+
from deepspeed.utils import logger
|
27 |
+
from deepspeed.checkpoint.constants import (DS_VERSION, OPTIMIZER_STATE_DICT, SINGLE_PARTITION_OF_FP32_GROUPS,
|
28 |
+
FP32_FLAT_GROUPS, ZERO_STAGE, PARTITION_COUNT, PARAM_SHAPES, BUFFER_NAMES,
|
29 |
+
FROZEN_PARAM_SHAPES, FROZEN_PARAM_FRAGMENTS)
|
30 |
+
|
31 |
+
|
32 |
+
@dataclass
|
33 |
+
class zero_model_state:
|
34 |
+
buffers: dict()
|
35 |
+
param_shapes: dict()
|
36 |
+
shared_params: list
|
37 |
+
ds_version: int
|
38 |
+
frozen_param_shapes: dict()
|
39 |
+
frozen_param_fragments: dict()
|
40 |
+
|
41 |
+
|
42 |
+
debug = 0
|
43 |
+
|
44 |
+
# load to cpu
|
45 |
+
device = torch.device('cpu')
|
46 |
+
|
47 |
+
|
48 |
+
def atoi(text):
|
49 |
+
return int(text) if text.isdigit() else text
|
50 |
+
|
51 |
+
|
52 |
+
def natural_keys(text):
|
53 |
+
'''
|
54 |
+
alist.sort(key=natural_keys) sorts in human order
|
55 |
+
http://nedbatchelder.com/blog/200712/human_sorting.html
|
56 |
+
(See Toothy's implementation in the comments)
|
57 |
+
'''
|
58 |
+
return [atoi(c) for c in re.split(r'(\d+)', text)]
|
59 |
+
|
60 |
+
|
61 |
+
def get_model_state_file(checkpoint_dir, zero_stage):
|
62 |
+
if not os.path.isdir(checkpoint_dir):
|
63 |
+
raise FileNotFoundError(f"Directory '{checkpoint_dir}' doesn't exist")
|
64 |
+
|
65 |
+
# there should be only one file
|
66 |
+
if zero_stage <= 2:
|
67 |
+
file = os.path.join(checkpoint_dir, "mp_rank_00_model_states.pt")
|
68 |
+
elif zero_stage == 3:
|
69 |
+
file = os.path.join(checkpoint_dir, "zero_pp_rank_0_mp_rank_00_model_states.pt")
|
70 |
+
|
71 |
+
if not os.path.exists(file):
|
72 |
+
raise FileNotFoundError(f"can't find model states file at '{file}'")
|
73 |
+
|
74 |
+
return file
|
75 |
+
|
76 |
+
|
77 |
+
def get_checkpoint_files(checkpoint_dir, glob_pattern):
|
78 |
+
# XXX: need to test that this simple glob rule works for multi-node setup too
|
79 |
+
ckpt_files = sorted(glob.glob(os.path.join(checkpoint_dir, glob_pattern)), key=natural_keys)
|
80 |
+
|
81 |
+
if len(ckpt_files) == 0:
|
82 |
+
raise FileNotFoundError(f"can't find {glob_pattern} files in directory '{checkpoint_dir}'")
|
83 |
+
|
84 |
+
return ckpt_files
|
85 |
+
|
86 |
+
|
87 |
+
def get_optim_files(checkpoint_dir):
|
88 |
+
return get_checkpoint_files(checkpoint_dir, "*_optim_states.pt")
|
89 |
+
|
90 |
+
|
91 |
+
def get_model_state_files(checkpoint_dir):
|
92 |
+
return get_checkpoint_files(checkpoint_dir, "*_model_states.pt")
|
93 |
+
|
94 |
+
|
95 |
+
def parse_model_states(files):
|
96 |
+
zero_model_states = []
|
97 |
+
for file in files:
|
98 |
+
state_dict = torch.load(file, map_location=device)
|
99 |
+
|
100 |
+
if BUFFER_NAMES not in state_dict:
|
101 |
+
raise ValueError(f"{file} is not a model state checkpoint")
|
102 |
+
buffer_names = state_dict[BUFFER_NAMES]
|
103 |
+
if debug:
|
104 |
+
print("Found buffers:", buffer_names)
|
105 |
+
|
106 |
+
# recover just the buffers while restoring them to fp32 if they were saved in fp16
|
107 |
+
buffers = {k: v.float() for k, v in state_dict["module"].items() if k in buffer_names}
|
108 |
+
param_shapes = state_dict[PARAM_SHAPES]
|
109 |
+
|
110 |
+
# collect parameters that are included in param_shapes
|
111 |
+
param_names = []
|
112 |
+
for s in param_shapes:
|
113 |
+
for name in s.keys():
|
114 |
+
param_names.append(name)
|
115 |
+
|
116 |
+
# update with frozen parameters
|
117 |
+
frozen_param_shapes = state_dict.get(FROZEN_PARAM_SHAPES, None)
|
118 |
+
if frozen_param_shapes is not None:
|
119 |
+
if debug:
|
120 |
+
print(f"Found frozen_param_shapes: {frozen_param_shapes}")
|
121 |
+
param_names += list(frozen_param_shapes.keys())
|
122 |
+
|
123 |
+
# handle shared params
|
124 |
+
shared_params = [[k, v] for k, v in state_dict["shared_params"].items()]
|
125 |
+
|
126 |
+
ds_version = state_dict.get(DS_VERSION, None)
|
127 |
+
|
128 |
+
frozen_param_fragments = state_dict.get(FROZEN_PARAM_FRAGMENTS, None)
|
129 |
+
|
130 |
+
z_model_state = zero_model_state(buffers=buffers,
|
131 |
+
param_shapes=param_shapes,
|
132 |
+
shared_params=shared_params,
|
133 |
+
ds_version=ds_version,
|
134 |
+
frozen_param_shapes=frozen_param_shapes,
|
135 |
+
frozen_param_fragments=frozen_param_fragments)
|
136 |
+
zero_model_states.append(z_model_state)
|
137 |
+
|
138 |
+
return zero_model_states
|
139 |
+
|
140 |
+
|
141 |
+
def parse_optim_states(files, ds_checkpoint_dir):
|
142 |
+
|
143 |
+
total_files = len(files)
|
144 |
+
state_dicts = []
|
145 |
+
for f in files:
|
146 |
+
state_dict = torch.load(f, map_location=device)
|
147 |
+
# immediately discard the potentially huge 2 optimizer states as we only care for fp32 master weights
|
148 |
+
# and also handle the case where it was already removed by another helper script
|
149 |
+
state_dict["optimizer_state_dict"].pop("optimizer_state_dict", None)
|
150 |
+
state_dicts.append(state_dict)
|
151 |
+
|
152 |
+
if not ZERO_STAGE in state_dicts[0][OPTIMIZER_STATE_DICT]:
|
153 |
+
raise ValueError(f"{files[0]} is not a zero checkpoint")
|
154 |
+
zero_stage = state_dicts[0][OPTIMIZER_STATE_DICT][ZERO_STAGE]
|
155 |
+
world_size = state_dicts[0][OPTIMIZER_STATE_DICT][PARTITION_COUNT]
|
156 |
+
|
157 |
+
# For ZeRO-2 each param group can have different partition_count as data parallelism for expert
|
158 |
+
# parameters can be different from data parallelism for non-expert parameters. So we can just
|
159 |
+
# use the max of the partition_count to get the dp world_size.
|
160 |
+
|
161 |
+
if type(world_size) is list:
|
162 |
+
world_size = max(world_size)
|
163 |
+
|
164 |
+
if world_size != total_files:
|
165 |
+
raise ValueError(
|
166 |
+
f"Expected {world_size} of '*_optim_states.pt' under '{ds_checkpoint_dir}' but found {total_files} files. "
|
167 |
+
"Possibly due to an overwrite of an old checkpoint, or a checkpoint didn't get saved by one or more processes."
|
168 |
+
)
|
169 |
+
|
170 |
+
# the groups are named differently in each stage
|
171 |
+
if zero_stage <= 2:
|
172 |
+
fp32_groups_key = SINGLE_PARTITION_OF_FP32_GROUPS
|
173 |
+
elif zero_stage == 3:
|
174 |
+
fp32_groups_key = FP32_FLAT_GROUPS
|
175 |
+
else:
|
176 |
+
raise ValueError(f"unknown zero stage {zero_stage}")
|
177 |
+
|
178 |
+
if zero_stage <= 2:
|
179 |
+
fp32_flat_groups = [state_dicts[i][OPTIMIZER_STATE_DICT][fp32_groups_key] for i in range(len(state_dicts))]
|
180 |
+
elif zero_stage == 3:
|
181 |
+
# if there is more than one param group, there will be multiple flattened tensors - one
|
182 |
+
# flattened tensor per group - for simplicity merge them into a single tensor
|
183 |
+
#
|
184 |
+
# XXX: could make the script more memory efficient for when there are multiple groups - it
|
185 |
+
# will require matching the sub-lists of param_shapes for each param group flattened tensor
|
186 |
+
|
187 |
+
fp32_flat_groups = [
|
188 |
+
torch.cat(state_dicts[i][OPTIMIZER_STATE_DICT][fp32_groups_key], 0) for i in range(len(state_dicts))
|
189 |
+
]
|
190 |
+
|
191 |
+
return zero_stage, world_size, fp32_flat_groups
|
192 |
+
|
193 |
+
|
194 |
+
def _get_fp32_state_dict_from_zero_checkpoint(ds_checkpoint_dir, exclude_frozen_parameters):
|
195 |
+
"""
|
196 |
+
Returns fp32 state_dict reconstructed from ds checkpoint
|
197 |
+
|
198 |
+
Args:
|
199 |
+
- ``ds_checkpoint_dir``: path to the deepspeed checkpoint folder (where the optimizer files are)
|
200 |
+
|
201 |
+
"""
|
202 |
+
print(f"Processing zero checkpoint '{ds_checkpoint_dir}'")
|
203 |
+
|
204 |
+
optim_files = get_optim_files(ds_checkpoint_dir)
|
205 |
+
zero_stage, world_size, fp32_flat_groups = parse_optim_states(optim_files, ds_checkpoint_dir)
|
206 |
+
print(f"Detected checkpoint of type zero stage {zero_stage}, world_size: {world_size}")
|
207 |
+
|
208 |
+
model_files = get_model_state_files(ds_checkpoint_dir)
|
209 |
+
|
210 |
+
zero_model_states = parse_model_states(model_files)
|
211 |
+
print(f'Parsing checkpoint created by deepspeed=={zero_model_states[0].ds_version}')
|
212 |
+
|
213 |
+
if zero_stage <= 2:
|
214 |
+
return _get_fp32_state_dict_from_zero2_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
215 |
+
exclude_frozen_parameters)
|
216 |
+
elif zero_stage == 3:
|
217 |
+
return _get_fp32_state_dict_from_zero3_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
218 |
+
exclude_frozen_parameters)
|
219 |
+
|
220 |
+
|
221 |
+
def _zero2_merge_frozen_params(state_dict, zero_model_states):
|
222 |
+
if zero_model_states[0].frozen_param_shapes is None or len(zero_model_states[0].frozen_param_shapes) == 0:
|
223 |
+
return
|
224 |
+
|
225 |
+
frozen_param_shapes = zero_model_states[0].frozen_param_shapes
|
226 |
+
frozen_param_fragments = zero_model_states[0].frozen_param_fragments
|
227 |
+
|
228 |
+
if debug:
|
229 |
+
num_elem = sum(s.numel() for s in frozen_param_shapes.values())
|
230 |
+
print(f'rank 0: {FROZEN_PARAM_SHAPES}.numel = {num_elem}')
|
231 |
+
|
232 |
+
wanted_params = len(frozen_param_shapes)
|
233 |
+
wanted_numel = sum(s.numel() for s in frozen_param_shapes.values())
|
234 |
+
avail_numel = sum([p.numel() for p in frozen_param_fragments.values()])
|
235 |
+
print(f'Frozen params: Have {avail_numel} numels to process.')
|
236 |
+
print(f'Frozen params: Need {wanted_numel} numels in {wanted_params} params')
|
237 |
+
|
238 |
+
total_params = 0
|
239 |
+
total_numel = 0
|
240 |
+
for name, shape in frozen_param_shapes.items():
|
241 |
+
total_params += 1
|
242 |
+
unpartitioned_numel = shape.numel()
|
243 |
+
total_numel += unpartitioned_numel
|
244 |
+
|
245 |
+
state_dict[name] = frozen_param_fragments[name]
|
246 |
+
|
247 |
+
if debug:
|
248 |
+
print(f"{name} full shape: {shape} unpartitioned numel {unpartitioned_numel} ")
|
249 |
+
|
250 |
+
print(f"Reconstructed Frozen fp32 state dict with {total_params} params {total_numel} elements")
|
251 |
+
|
252 |
+
|
253 |
+
def _has_callable(obj, fn):
|
254 |
+
attr = getattr(obj, fn, None)
|
255 |
+
return callable(attr)
|
256 |
+
|
257 |
+
|
258 |
+
def _zero2_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states):
|
259 |
+
param_shapes = zero_model_states[0].param_shapes
|
260 |
+
|
261 |
+
# Reconstruction protocol:
|
262 |
+
#
|
263 |
+
# XXX: document this
|
264 |
+
|
265 |
+
if debug:
|
266 |
+
for i in range(world_size):
|
267 |
+
for j in range(len(fp32_flat_groups[0])):
|
268 |
+
print(f"{FP32_FLAT_GROUPS}[{i}][{j}].shape={fp32_flat_groups[i][j].shape}")
|
269 |
+
|
270 |
+
# XXX: memory usage doubles here (zero2)
|
271 |
+
num_param_groups = len(fp32_flat_groups[0])
|
272 |
+
merged_single_partition_of_fp32_groups = []
|
273 |
+
for i in range(num_param_groups):
|
274 |
+
merged_partitions = [sd[i] for sd in fp32_flat_groups]
|
275 |
+
full_single_fp32_vector = torch.cat(merged_partitions, 0)
|
276 |
+
merged_single_partition_of_fp32_groups.append(full_single_fp32_vector)
|
277 |
+
avail_numel = sum(
|
278 |
+
[full_single_fp32_vector.numel() for full_single_fp32_vector in merged_single_partition_of_fp32_groups])
|
279 |
+
|
280 |
+
if debug:
|
281 |
+
wanted_params = sum([len(shapes) for shapes in param_shapes])
|
282 |
+
wanted_numel = sum([sum(shape.numel() for shape in shapes.values()) for shapes in param_shapes])
|
283 |
+
# not asserting if there is a mismatch due to possible padding
|
284 |
+
print(f"Have {avail_numel} numels to process.")
|
285 |
+
print(f"Need {wanted_numel} numels in {wanted_params} params.")
|
286 |
+
|
287 |
+
# params
|
288 |
+
# XXX: for huge models that can't fit into the host's RAM we will have to recode this to support
|
289 |
+
# out-of-core computing solution
|
290 |
+
total_numel = 0
|
291 |
+
total_params = 0
|
292 |
+
for shapes, full_single_fp32_vector in zip(param_shapes, merged_single_partition_of_fp32_groups):
|
293 |
+
offset = 0
|
294 |
+
avail_numel = full_single_fp32_vector.numel()
|
295 |
+
for name, shape in shapes.items():
|
296 |
+
|
297 |
+
unpartitioned_numel = shape.numel() if _has_callable(shape, 'numel') else math.prod(shape)
|
298 |
+
total_numel += unpartitioned_numel
|
299 |
+
total_params += 1
|
300 |
+
|
301 |
+
if debug:
|
302 |
+
print(f"{name} full shape: {shape} unpartitioned numel {unpartitioned_numel} ")
|
303 |
+
state_dict[name] = full_single_fp32_vector.narrow(0, offset, unpartitioned_numel).view(shape)
|
304 |
+
offset += unpartitioned_numel
|
305 |
+
|
306 |
+
# Z2 started to align to 2*world_size to improve nccl performance. Therefore both offset and
|
307 |
+
# avail_numel can differ by anywhere between 0..2*world_size. Due to two unrelated complex
|
308 |
+
# paddings performed in the code it's almost impossible to predict the exact numbers w/o the
|
309 |
+
# live optimizer object, so we are checking that the numbers are within the right range
|
310 |
+
align_to = 2 * world_size
|
311 |
+
|
312 |
+
def zero2_align(x):
|
313 |
+
return align_to * math.ceil(x / align_to)
|
314 |
+
|
315 |
+
if debug:
|
316 |
+
print(f"original offset={offset}, avail_numel={avail_numel}")
|
317 |
+
|
318 |
+
offset = zero2_align(offset)
|
319 |
+
avail_numel = zero2_align(avail_numel)
|
320 |
+
|
321 |
+
if debug:
|
322 |
+
print(f"aligned offset={offset}, avail_numel={avail_numel}")
|
323 |
+
|
324 |
+
# Sanity check
|
325 |
+
if offset != avail_numel:
|
326 |
+
raise ValueError(f"consumed {offset} numels out of {avail_numel} - something is wrong")
|
327 |
+
|
328 |
+
print(f"Reconstructed fp32 state dict with {total_params} params {total_numel} elements")
|
329 |
+
|
330 |
+
|
331 |
+
def _get_fp32_state_dict_from_zero2_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
332 |
+
exclude_frozen_parameters):
|
333 |
+
state_dict = OrderedDict()
|
334 |
+
|
335 |
+
# buffers
|
336 |
+
buffers = zero_model_states[0].buffers
|
337 |
+
state_dict.update(buffers)
|
338 |
+
if debug:
|
339 |
+
print(f"added {len(buffers)} buffers")
|
340 |
+
|
341 |
+
if not exclude_frozen_parameters:
|
342 |
+
_zero2_merge_frozen_params(state_dict, zero_model_states)
|
343 |
+
|
344 |
+
_zero2_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states)
|
345 |
+
|
346 |
+
# recover shared parameters
|
347 |
+
for pair in zero_model_states[0].shared_params:
|
348 |
+
if pair[1] in state_dict:
|
349 |
+
state_dict[pair[0]] = state_dict[pair[1]]
|
350 |
+
|
351 |
+
return state_dict
|
352 |
+
|
353 |
+
|
354 |
+
def zero3_partitioned_param_info(unpartitioned_numel, world_size):
|
355 |
+
remainder = unpartitioned_numel % world_size
|
356 |
+
padding_numel = (world_size - remainder) if remainder else 0
|
357 |
+
partitioned_numel = math.ceil(unpartitioned_numel / world_size)
|
358 |
+
return partitioned_numel, padding_numel
|
359 |
+
|
360 |
+
|
361 |
+
def _zero3_merge_frozen_params(state_dict, world_size, zero_model_states):
|
362 |
+
if zero_model_states[0].frozen_param_shapes is None or len(zero_model_states[0].frozen_param_shapes) == 0:
|
363 |
+
return
|
364 |
+
|
365 |
+
if debug:
|
366 |
+
for i in range(world_size):
|
367 |
+
num_elem = sum(s.numel() for s in zero_model_states[i].frozen_param_fragments.values())
|
368 |
+
print(f'rank {i}: {FROZEN_PARAM_SHAPES}.numel = {num_elem}')
|
369 |
+
|
370 |
+
frozen_param_shapes = zero_model_states[0].frozen_param_shapes
|
371 |
+
wanted_params = len(frozen_param_shapes)
|
372 |
+
wanted_numel = sum(s.numel() for s in frozen_param_shapes.values())
|
373 |
+
avail_numel = sum([p.numel() for p in zero_model_states[0].frozen_param_fragments.values()]) * world_size
|
374 |
+
print(f'Frozen params: Have {avail_numel} numels to process.')
|
375 |
+
print(f'Frozen params: Need {wanted_numel} numels in {wanted_params} params')
|
376 |
+
|
377 |
+
total_params = 0
|
378 |
+
total_numel = 0
|
379 |
+
for name, shape in zero_model_states[0].frozen_param_shapes.items():
|
380 |
+
total_params += 1
|
381 |
+
unpartitioned_numel = shape.numel()
|
382 |
+
total_numel += unpartitioned_numel
|
383 |
+
|
384 |
+
param_frags = tuple(model_state.frozen_param_fragments[name] for model_state in zero_model_states)
|
385 |
+
state_dict[name] = torch.cat(param_frags, 0).narrow(0, 0, unpartitioned_numel).view(shape)
|
386 |
+
|
387 |
+
partitioned_numel, partitioned_padding_numel = zero3_partitioned_param_info(unpartitioned_numel, world_size)
|
388 |
+
|
389 |
+
if debug:
|
390 |
+
print(
|
391 |
+
f"Frozen params: {total_params} {name} full shape: {shape} partition0 numel={partitioned_numel} partitioned_padding_numel={partitioned_padding_numel}"
|
392 |
+
)
|
393 |
+
|
394 |
+
print(f"Reconstructed Frozen fp32 state dict with {total_params} params {total_numel} elements")
|
395 |
+
|
396 |
+
|
397 |
+
def _zero3_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states):
|
398 |
+
param_shapes = zero_model_states[0].param_shapes
|
399 |
+
avail_numel = fp32_flat_groups[0].numel() * world_size
|
400 |
+
# Reconstruction protocol: For zero3 we need to zip the partitions together at boundary of each
|
401 |
+
# param, re-consolidating each param, while dealing with padding if any
|
402 |
+
|
403 |
+
# merge list of dicts, preserving order
|
404 |
+
param_shapes = {k: v for d in param_shapes for k, v in d.items()}
|
405 |
+
|
406 |
+
if debug:
|
407 |
+
for i in range(world_size):
|
408 |
+
print(f"{FP32_FLAT_GROUPS}[{i}].shape={fp32_flat_groups[i].shape}")
|
409 |
+
|
410 |
+
wanted_params = len(param_shapes)
|
411 |
+
wanted_numel = sum(shape.numel() for shape in param_shapes.values())
|
412 |
+
# not asserting if there is a mismatch due to possible padding
|
413 |
+
avail_numel = fp32_flat_groups[0].numel() * world_size
|
414 |
+
print(f"Trainable params: Have {avail_numel} numels to process.")
|
415 |
+
print(f"Trainable params: Need {wanted_numel} numels in {wanted_params} params.")
|
416 |
+
|
417 |
+
# params
|
418 |
+
# XXX: for huge models that can't fit into the host's RAM we will have to recode this to support
|
419 |
+
# out-of-core computing solution
|
420 |
+
offset = 0
|
421 |
+
total_numel = 0
|
422 |
+
total_params = 0
|
423 |
+
for name, shape in param_shapes.items():
|
424 |
+
|
425 |
+
unpartitioned_numel = shape.numel()
|
426 |
+
total_numel += unpartitioned_numel
|
427 |
+
total_params += 1
|
428 |
+
|
429 |
+
partitioned_numel, partitioned_padding_numel = zero3_partitioned_param_info(unpartitioned_numel, world_size)
|
430 |
+
|
431 |
+
if debug:
|
432 |
+
print(
|
433 |
+
f"Trainable params: {total_params} {name} full shape: {shape} partition0 numel={partitioned_numel} partitioned_padding_numel={partitioned_padding_numel}"
|
434 |
+
)
|
435 |
+
|
436 |
+
# XXX: memory usage doubles here
|
437 |
+
state_dict[name] = torch.cat(
|
438 |
+
tuple(fp32_flat_groups[i].narrow(0, offset, partitioned_numel) for i in range(world_size)),
|
439 |
+
0).narrow(0, 0, unpartitioned_numel).view(shape)
|
440 |
+
offset += partitioned_numel
|
441 |
+
|
442 |
+
offset *= world_size
|
443 |
+
|
444 |
+
# Sanity check
|
445 |
+
if offset != avail_numel:
|
446 |
+
raise ValueError(f"consumed {offset} numels out of {avail_numel} - something is wrong")
|
447 |
+
|
448 |
+
print(f"Reconstructed Trainable fp32 state dict with {total_params} params {total_numel} elements")
|
449 |
+
|
450 |
+
|
451 |
+
def _get_fp32_state_dict_from_zero3_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
452 |
+
exclude_frozen_parameters):
|
453 |
+
state_dict = OrderedDict()
|
454 |
+
|
455 |
+
# buffers
|
456 |
+
buffers = zero_model_states[0].buffers
|
457 |
+
state_dict.update(buffers)
|
458 |
+
if debug:
|
459 |
+
print(f"added {len(buffers)} buffers")
|
460 |
+
|
461 |
+
if not exclude_frozen_parameters:
|
462 |
+
_zero3_merge_frozen_params(state_dict, world_size, zero_model_states)
|
463 |
+
|
464 |
+
_zero3_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states)
|
465 |
+
|
466 |
+
# recover shared parameters
|
467 |
+
for pair in zero_model_states[0].shared_params:
|
468 |
+
if pair[1] in state_dict:
|
469 |
+
state_dict[pair[0]] = state_dict[pair[1]]
|
470 |
+
|
471 |
+
return state_dict
|
472 |
+
|
473 |
+
|
474 |
+
def get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag=None, exclude_frozen_parameters=False):
|
475 |
+
"""
|
476 |
+
Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated state_dict that can be loaded with
|
477 |
+
``load_state_dict()`` and used for training without DeepSpeed or shared with others, for example
|
478 |
+
via a model hub.
|
479 |
+
|
480 |
+
Args:
|
481 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder
|
482 |
+
- ``tag``: checkpoint tag used as a unique identifier for checkpoint. If not provided will attempt to load tag in 'latest' file. e.g., ``global_step14``
|
483 |
+
- ``exclude_frozen_parameters``: exclude frozen parameters
|
484 |
+
|
485 |
+
Returns:
|
486 |
+
- pytorch ``state_dict``
|
487 |
+
|
488 |
+
Note: this approach may not work if your application doesn't have sufficient free CPU memory and
|
489 |
+
you may need to use the offline approach using the ``zero_to_fp32.py`` script that is saved with
|
490 |
+
the checkpoint.
|
491 |
+
|
492 |
+
A typical usage might be ::
|
493 |
+
|
494 |
+
from deepspeed.utils.zero_to_fp32 import get_fp32_state_dict_from_zero_checkpoint
|
495 |
+
# do the training and checkpoint saving
|
496 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir) # already on cpu
|
497 |
+
model = model.cpu() # move to cpu
|
498 |
+
model.load_state_dict(state_dict)
|
499 |
+
# submit to model hub or save the model to share with others
|
500 |
+
|
501 |
+
In this example the ``model`` will no longer be usable in the deepspeed context of the same
|
502 |
+
application. i.e. you will need to re-initialize the deepspeed engine, since
|
503 |
+
``model.load_state_dict(state_dict)`` will remove all the deepspeed magic from it.
|
504 |
+
|
505 |
+
If you want it all done for you, use ``load_state_dict_from_zero_checkpoint`` instead.
|
506 |
+
|
507 |
+
"""
|
508 |
+
if tag is None:
|
509 |
+
latest_path = os.path.join(checkpoint_dir, 'latest')
|
510 |
+
if os.path.isfile(latest_path):
|
511 |
+
with open(latest_path, 'r') as fd:
|
512 |
+
tag = fd.read().strip()
|
513 |
+
else:
|
514 |
+
raise ValueError(f"Unable to find 'latest' file at {latest_path}")
|
515 |
+
|
516 |
+
ds_checkpoint_dir = os.path.join(checkpoint_dir, tag)
|
517 |
+
|
518 |
+
if not os.path.isdir(ds_checkpoint_dir):
|
519 |
+
raise FileNotFoundError(f"Directory '{ds_checkpoint_dir}' doesn't exist")
|
520 |
+
|
521 |
+
return _get_fp32_state_dict_from_zero_checkpoint(ds_checkpoint_dir, exclude_frozen_parameters)
|
522 |
+
|
523 |
+
|
524 |
+
def convert_zero_checkpoint_to_fp32_state_dict(checkpoint_dir, output_file, tag=None, exclude_frozen_parameters=False):
|
525 |
+
"""
|
526 |
+
Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated ``state_dict`` file that can be
|
527 |
+
loaded with ``torch.load(file)`` + ``load_state_dict()`` and used for training without DeepSpeed.
|
528 |
+
|
529 |
+
Args:
|
530 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder. (one that contains the tag-folder, like ``global_step14``)
|
531 |
+
- ``output_file``: path to the pytorch fp32 state_dict output file (e.g. path/pytorch_model.bin)
|
532 |
+
- ``tag``: checkpoint tag used as a unique identifier for checkpoint. If not provided will attempt to load tag in the file named ``latest`` in the checkpoint folder, e.g., ``global_step14``
|
533 |
+
- ``exclude_frozen_parameters``: exclude frozen parameters
|
534 |
+
"""
|
535 |
+
|
536 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag, exclude_frozen_parameters)
|
537 |
+
print(f"Saving fp32 state dict to {output_file}")
|
538 |
+
torch.save(state_dict, output_file)
|
539 |
+
|
540 |
+
|
541 |
+
def load_state_dict_from_zero_checkpoint(model, checkpoint_dir, tag=None):
|
542 |
+
"""
|
543 |
+
1. Put the provided model to cpu
|
544 |
+
2. Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated ``state_dict``
|
545 |
+
3. Load it into the provided model
|
546 |
+
|
547 |
+
Args:
|
548 |
+
- ``model``: the model object to update
|
549 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder. (one that contains the tag-folder, like ``global_step14``)
|
550 |
+
- ``tag``: checkpoint tag used as a unique identifier for checkpoint. If not provided will attempt to load tag in the file named ``latest`` in the checkpoint folder, e.g., ``global_step14``
|
551 |
+
|
552 |
+
Returns:
|
553 |
+
- ``model`: modified model
|
554 |
+
|
555 |
+
Make sure you have plenty of CPU memory available before you call this function. If you don't
|
556 |
+
have enough use the ``zero_to_fp32.py`` utility to do the conversion. You will find it
|
557 |
+
conveniently placed for you in the checkpoint folder.
|
558 |
+
|
559 |
+
A typical usage might be ::
|
560 |
+
|
561 |
+
from deepspeed.utils.zero_to_fp32 import load_state_dict_from_zero_checkpoint
|
562 |
+
model = load_state_dict_from_zero_checkpoint(trainer.model, checkpoint_dir)
|
563 |
+
# submit to model hub or save the model to share with others
|
564 |
+
|
565 |
+
Note, that once this was run, the ``model`` will no longer be usable in the deepspeed context
|
566 |
+
of the same application. i.e. you will need to re-initialize the deepspeed engine, since
|
567 |
+
``model.load_state_dict(state_dict)`` will remove all the deepspeed magic from it.
|
568 |
+
|
569 |
+
"""
|
570 |
+
logger.info(f"Extracting fp32 weights")
|
571 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag)
|
572 |
+
|
573 |
+
logger.info(f"Overwriting model with fp32 weights")
|
574 |
+
model = model.cpu()
|
575 |
+
model.load_state_dict(state_dict, strict=False)
|
576 |
+
|
577 |
+
return model
|
578 |
+
|
579 |
+
|
580 |
+
if __name__ == "__main__":
|
581 |
+
|
582 |
+
parser = argparse.ArgumentParser()
|
583 |
+
parser.add_argument("checkpoint_dir",
|
584 |
+
type=str,
|
585 |
+
help="path to the desired checkpoint folder, e.g., path/checkpoint-12")
|
586 |
+
parser.add_argument(
|
587 |
+
"output_file",
|
588 |
+
type=str,
|
589 |
+
help="path to the pytorch fp32 state_dict output file (e.g. path/checkpoint-12/pytorch_model.bin)")
|
590 |
+
parser.add_argument("-t",
|
591 |
+
"--tag",
|
592 |
+
type=str,
|
593 |
+
default=None,
|
594 |
+
help="checkpoint tag used as a unique identifier for checkpoint. e.g., global_step1")
|
595 |
+
parser.add_argument("--exclude_frozen_parameters", action='store_true', help="exclude frozen parameters")
|
596 |
+
parser.add_argument("-d", "--debug", action='store_true', help="enable debug")
|
597 |
+
args = parser.parse_args()
|
598 |
+
|
599 |
+
debug = args.debug
|
600 |
+
|
601 |
+
convert_zero_checkpoint_to_fp32_state_dict(args.checkpoint_dir,
|
602 |
+
args.output_file,
|
603 |
+
tag=args.tag,
|
604 |
+
exclude_frozen_parameters=args.exclude_frozen_parameters)
|