Upload folder using huggingface_hub
Browse filesThis view is limited to 50 files because it contains too many changes.
See raw diff
- .gitattributes +4 -0
- adapter_config.json +37 -0
- adapter_model.safetensors +3 -0
- added_tokens.json +24 -0
- checkpoint-1000/README.md +202 -0
- checkpoint-1000/adapter_config.json +37 -0
- checkpoint-1000/adapter_model.safetensors +3 -0
- checkpoint-1000/added_tokens.json +24 -0
- checkpoint-1000/latest +1 -0
- checkpoint-1000/merges.txt +0 -0
- checkpoint-1000/rng_state_0.pth +3 -0
- checkpoint-1000/rng_state_1.pth +3 -0
- checkpoint-1000/special_tokens_map.json +31 -0
- checkpoint-1000/tokenizer.json +3 -0
- checkpoint-1000/tokenizer_config.json +208 -0
- checkpoint-1000/trainer_state.json +0 -0
- checkpoint-1000/training_args.bin +3 -0
- checkpoint-1000/vocab.json +0 -0
- checkpoint-1000/zero_to_fp32.py +674 -0
- checkpoint-1500/README.md +202 -0
- checkpoint-1500/adapter_config.json +37 -0
- checkpoint-1500/adapter_model.safetensors +3 -0
- checkpoint-1500/added_tokens.json +24 -0
- checkpoint-1500/latest +1 -0
- checkpoint-1500/merges.txt +0 -0
- checkpoint-1500/rng_state_0.pth +3 -0
- checkpoint-1500/rng_state_1.pth +3 -0
- checkpoint-1500/special_tokens_map.json +31 -0
- checkpoint-1500/tokenizer.json +3 -0
- checkpoint-1500/tokenizer_config.json +208 -0
- checkpoint-1500/trainer_state.json +0 -0
- checkpoint-1500/training_args.bin +3 -0
- checkpoint-1500/vocab.json +0 -0
- checkpoint-1500/zero_to_fp32.py +674 -0
- checkpoint-500/README.md +202 -0
- checkpoint-500/adapter_config.json +37 -0
- checkpoint-500/adapter_model.safetensors +3 -0
- checkpoint-500/added_tokens.json +24 -0
- checkpoint-500/latest +1 -0
- checkpoint-500/merges.txt +0 -0
- checkpoint-500/rng_state_0.pth +3 -0
- checkpoint-500/rng_state_1.pth +3 -0
- checkpoint-500/special_tokens_map.json +31 -0
- checkpoint-500/tokenizer.json +3 -0
- checkpoint-500/tokenizer_config.json +208 -0
- checkpoint-500/trainer_state.json +3533 -0
- checkpoint-500/training_args.bin +3 -0
- checkpoint-500/vocab.json +0 -0
- checkpoint-500/zero_to_fp32.py +674 -0
- merges.txt +0 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,7 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
checkpoint-1000/tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
| 37 |
+
checkpoint-1500/tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
| 38 |
+
checkpoint-500/tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
| 39 |
+
tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
adapter_config.json
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"alpha_pattern": {},
|
| 3 |
+
"auto_mapping": null,
|
| 4 |
+
"base_model_name_or_path": "Qwen/Qwen2.5-7B",
|
| 5 |
+
"bias": "none",
|
| 6 |
+
"eva_config": null,
|
| 7 |
+
"exclude_modules": null,
|
| 8 |
+
"fan_in_fan_out": false,
|
| 9 |
+
"inference_mode": true,
|
| 10 |
+
"init_lora_weights": true,
|
| 11 |
+
"layer_replication": null,
|
| 12 |
+
"layers_pattern": null,
|
| 13 |
+
"layers_to_transform": null,
|
| 14 |
+
"loftq_config": {},
|
| 15 |
+
"lora_alpha": 32,
|
| 16 |
+
"lora_bias": false,
|
| 17 |
+
"lora_dropout": 0.0,
|
| 18 |
+
"megatron_config": null,
|
| 19 |
+
"megatron_core": "megatron.core",
|
| 20 |
+
"modules_to_save": null,
|
| 21 |
+
"peft_type": "LORA",
|
| 22 |
+
"r": 16,
|
| 23 |
+
"rank_pattern": {},
|
| 24 |
+
"revision": null,
|
| 25 |
+
"target_modules": [
|
| 26 |
+
"k_proj",
|
| 27 |
+
"v_proj",
|
| 28 |
+
"q_proj",
|
| 29 |
+
"up_proj",
|
| 30 |
+
"gate_proj",
|
| 31 |
+
"down_proj",
|
| 32 |
+
"o_proj"
|
| 33 |
+
],
|
| 34 |
+
"task_type": "CAUSAL_LM",
|
| 35 |
+
"use_dora": false,
|
| 36 |
+
"use_rslora": false
|
| 37 |
+
}
|
adapter_model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b1f1ce8c9922c384cf7af3046be04f4ed75efbc3066b8e3ee012e28782155f77
|
| 3 |
+
size 80792880
|
added_tokens.json
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"</tool_call>": 151658,
|
| 3 |
+
"<tool_call>": 151657,
|
| 4 |
+
"<|box_end|>": 151649,
|
| 5 |
+
"<|box_start|>": 151648,
|
| 6 |
+
"<|endoftext|>": 151643,
|
| 7 |
+
"<|file_sep|>": 151664,
|
| 8 |
+
"<|fim_middle|>": 151660,
|
| 9 |
+
"<|fim_pad|>": 151662,
|
| 10 |
+
"<|fim_prefix|>": 151659,
|
| 11 |
+
"<|fim_suffix|>": 151661,
|
| 12 |
+
"<|im_end|>": 151645,
|
| 13 |
+
"<|im_start|>": 151644,
|
| 14 |
+
"<|image_pad|>": 151655,
|
| 15 |
+
"<|object_ref_end|>": 151647,
|
| 16 |
+
"<|object_ref_start|>": 151646,
|
| 17 |
+
"<|quad_end|>": 151651,
|
| 18 |
+
"<|quad_start|>": 151650,
|
| 19 |
+
"<|repo_name|>": 151663,
|
| 20 |
+
"<|video_pad|>": 151656,
|
| 21 |
+
"<|vision_end|>": 151653,
|
| 22 |
+
"<|vision_pad|>": 151654,
|
| 23 |
+
"<|vision_start|>": 151652
|
| 24 |
+
}
|
checkpoint-1000/README.md
ADDED
|
@@ -0,0 +1,202 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
base_model: Qwen/Qwen2.5-7B
|
| 3 |
+
library_name: peft
|
| 4 |
+
---
|
| 5 |
+
|
| 6 |
+
# Model Card for Model ID
|
| 7 |
+
|
| 8 |
+
<!-- Provide a quick summary of what the model is/does. -->
|
| 9 |
+
|
| 10 |
+
|
| 11 |
+
|
| 12 |
+
## Model Details
|
| 13 |
+
|
| 14 |
+
### Model Description
|
| 15 |
+
|
| 16 |
+
<!-- Provide a longer summary of what this model is. -->
|
| 17 |
+
|
| 18 |
+
|
| 19 |
+
|
| 20 |
+
- **Developed by:** [More Information Needed]
|
| 21 |
+
- **Funded by [optional]:** [More Information Needed]
|
| 22 |
+
- **Shared by [optional]:** [More Information Needed]
|
| 23 |
+
- **Model type:** [More Information Needed]
|
| 24 |
+
- **Language(s) (NLP):** [More Information Needed]
|
| 25 |
+
- **License:** [More Information Needed]
|
| 26 |
+
- **Finetuned from model [optional]:** [More Information Needed]
|
| 27 |
+
|
| 28 |
+
### Model Sources [optional]
|
| 29 |
+
|
| 30 |
+
<!-- Provide the basic links for the model. -->
|
| 31 |
+
|
| 32 |
+
- **Repository:** [More Information Needed]
|
| 33 |
+
- **Paper [optional]:** [More Information Needed]
|
| 34 |
+
- **Demo [optional]:** [More Information Needed]
|
| 35 |
+
|
| 36 |
+
## Uses
|
| 37 |
+
|
| 38 |
+
<!-- Address questions around how the model is intended to be used, including the foreseeable users of the model and those affected by the model. -->
|
| 39 |
+
|
| 40 |
+
### Direct Use
|
| 41 |
+
|
| 42 |
+
<!-- This section is for the model use without fine-tuning or plugging into a larger ecosystem/app. -->
|
| 43 |
+
|
| 44 |
+
[More Information Needed]
|
| 45 |
+
|
| 46 |
+
### Downstream Use [optional]
|
| 47 |
+
|
| 48 |
+
<!-- This section is for the model use when fine-tuned for a task, or when plugged into a larger ecosystem/app -->
|
| 49 |
+
|
| 50 |
+
[More Information Needed]
|
| 51 |
+
|
| 52 |
+
### Out-of-Scope Use
|
| 53 |
+
|
| 54 |
+
<!-- This section addresses misuse, malicious use, and uses that the model will not work well for. -->
|
| 55 |
+
|
| 56 |
+
[More Information Needed]
|
| 57 |
+
|
| 58 |
+
## Bias, Risks, and Limitations
|
| 59 |
+
|
| 60 |
+
<!-- This section is meant to convey both technical and sociotechnical limitations. -->
|
| 61 |
+
|
| 62 |
+
[More Information Needed]
|
| 63 |
+
|
| 64 |
+
### Recommendations
|
| 65 |
+
|
| 66 |
+
<!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. -->
|
| 67 |
+
|
| 68 |
+
Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
|
| 69 |
+
|
| 70 |
+
## How to Get Started with the Model
|
| 71 |
+
|
| 72 |
+
Use the code below to get started with the model.
|
| 73 |
+
|
| 74 |
+
[More Information Needed]
|
| 75 |
+
|
| 76 |
+
## Training Details
|
| 77 |
+
|
| 78 |
+
### Training Data
|
| 79 |
+
|
| 80 |
+
<!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
|
| 81 |
+
|
| 82 |
+
[More Information Needed]
|
| 83 |
+
|
| 84 |
+
### Training Procedure
|
| 85 |
+
|
| 86 |
+
<!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
|
| 87 |
+
|
| 88 |
+
#### Preprocessing [optional]
|
| 89 |
+
|
| 90 |
+
[More Information Needed]
|
| 91 |
+
|
| 92 |
+
|
| 93 |
+
#### Training Hyperparameters
|
| 94 |
+
|
| 95 |
+
- **Training regime:** [More Information Needed] <!--fp32, fp16 mixed precision, bf16 mixed precision, bf16 non-mixed precision, fp16 non-mixed precision, fp8 mixed precision -->
|
| 96 |
+
|
| 97 |
+
#### Speeds, Sizes, Times [optional]
|
| 98 |
+
|
| 99 |
+
<!-- This section provides information about throughput, start/end time, checkpoint size if relevant, etc. -->
|
| 100 |
+
|
| 101 |
+
[More Information Needed]
|
| 102 |
+
|
| 103 |
+
## Evaluation
|
| 104 |
+
|
| 105 |
+
<!-- This section describes the evaluation protocols and provides the results. -->
|
| 106 |
+
|
| 107 |
+
### Testing Data, Factors & Metrics
|
| 108 |
+
|
| 109 |
+
#### Testing Data
|
| 110 |
+
|
| 111 |
+
<!-- This should link to a Dataset Card if possible. -->
|
| 112 |
+
|
| 113 |
+
[More Information Needed]
|
| 114 |
+
|
| 115 |
+
#### Factors
|
| 116 |
+
|
| 117 |
+
<!-- These are the things the evaluation is disaggregating by, e.g., subpopulations or domains. -->
|
| 118 |
+
|
| 119 |
+
[More Information Needed]
|
| 120 |
+
|
| 121 |
+
#### Metrics
|
| 122 |
+
|
| 123 |
+
<!-- These are the evaluation metrics being used, ideally with a description of why. -->
|
| 124 |
+
|
| 125 |
+
[More Information Needed]
|
| 126 |
+
|
| 127 |
+
### Results
|
| 128 |
+
|
| 129 |
+
[More Information Needed]
|
| 130 |
+
|
| 131 |
+
#### Summary
|
| 132 |
+
|
| 133 |
+
|
| 134 |
+
|
| 135 |
+
## Model Examination [optional]
|
| 136 |
+
|
| 137 |
+
<!-- Relevant interpretability work for the model goes here -->
|
| 138 |
+
|
| 139 |
+
[More Information Needed]
|
| 140 |
+
|
| 141 |
+
## Environmental Impact
|
| 142 |
+
|
| 143 |
+
<!-- Total emissions (in grams of CO2eq) and additional considerations, such as electricity usage, go here. Edit the suggested text below accordingly -->
|
| 144 |
+
|
| 145 |
+
Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700).
|
| 146 |
+
|
| 147 |
+
- **Hardware Type:** [More Information Needed]
|
| 148 |
+
- **Hours used:** [More Information Needed]
|
| 149 |
+
- **Cloud Provider:** [More Information Needed]
|
| 150 |
+
- **Compute Region:** [More Information Needed]
|
| 151 |
+
- **Carbon Emitted:** [More Information Needed]
|
| 152 |
+
|
| 153 |
+
## Technical Specifications [optional]
|
| 154 |
+
|
| 155 |
+
### Model Architecture and Objective
|
| 156 |
+
|
| 157 |
+
[More Information Needed]
|
| 158 |
+
|
| 159 |
+
### Compute Infrastructure
|
| 160 |
+
|
| 161 |
+
[More Information Needed]
|
| 162 |
+
|
| 163 |
+
#### Hardware
|
| 164 |
+
|
| 165 |
+
[More Information Needed]
|
| 166 |
+
|
| 167 |
+
#### Software
|
| 168 |
+
|
| 169 |
+
[More Information Needed]
|
| 170 |
+
|
| 171 |
+
## Citation [optional]
|
| 172 |
+
|
| 173 |
+
<!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. -->
|
| 174 |
+
|
| 175 |
+
**BibTeX:**
|
| 176 |
+
|
| 177 |
+
[More Information Needed]
|
| 178 |
+
|
| 179 |
+
**APA:**
|
| 180 |
+
|
| 181 |
+
[More Information Needed]
|
| 182 |
+
|
| 183 |
+
## Glossary [optional]
|
| 184 |
+
|
| 185 |
+
<!-- If relevant, include terms and calculations in this section that can help readers understand the model or model card. -->
|
| 186 |
+
|
| 187 |
+
[More Information Needed]
|
| 188 |
+
|
| 189 |
+
## More Information [optional]
|
| 190 |
+
|
| 191 |
+
[More Information Needed]
|
| 192 |
+
|
| 193 |
+
## Model Card Authors [optional]
|
| 194 |
+
|
| 195 |
+
[More Information Needed]
|
| 196 |
+
|
| 197 |
+
## Model Card Contact
|
| 198 |
+
|
| 199 |
+
[More Information Needed]
|
| 200 |
+
### Framework versions
|
| 201 |
+
|
| 202 |
+
- PEFT 0.14.0
|
checkpoint-1000/adapter_config.json
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"alpha_pattern": {},
|
| 3 |
+
"auto_mapping": null,
|
| 4 |
+
"base_model_name_or_path": "Qwen/Qwen2.5-7B",
|
| 5 |
+
"bias": "none",
|
| 6 |
+
"eva_config": null,
|
| 7 |
+
"exclude_modules": null,
|
| 8 |
+
"fan_in_fan_out": false,
|
| 9 |
+
"inference_mode": true,
|
| 10 |
+
"init_lora_weights": true,
|
| 11 |
+
"layer_replication": null,
|
| 12 |
+
"layers_pattern": null,
|
| 13 |
+
"layers_to_transform": null,
|
| 14 |
+
"loftq_config": {},
|
| 15 |
+
"lora_alpha": 32,
|
| 16 |
+
"lora_bias": false,
|
| 17 |
+
"lora_dropout": 0.0,
|
| 18 |
+
"megatron_config": null,
|
| 19 |
+
"megatron_core": "megatron.core",
|
| 20 |
+
"modules_to_save": null,
|
| 21 |
+
"peft_type": "LORA",
|
| 22 |
+
"r": 16,
|
| 23 |
+
"rank_pattern": {},
|
| 24 |
+
"revision": null,
|
| 25 |
+
"target_modules": [
|
| 26 |
+
"k_proj",
|
| 27 |
+
"v_proj",
|
| 28 |
+
"q_proj",
|
| 29 |
+
"up_proj",
|
| 30 |
+
"gate_proj",
|
| 31 |
+
"down_proj",
|
| 32 |
+
"o_proj"
|
| 33 |
+
],
|
| 34 |
+
"task_type": "CAUSAL_LM",
|
| 35 |
+
"use_dora": false,
|
| 36 |
+
"use_rslora": false
|
| 37 |
+
}
|
checkpoint-1000/adapter_model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:ad117196d0adf2eb276e01fe5eda339cfca3825629b58df7e861daf6357260da
|
| 3 |
+
size 80792880
|
checkpoint-1000/added_tokens.json
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"</tool_call>": 151658,
|
| 3 |
+
"<tool_call>": 151657,
|
| 4 |
+
"<|box_end|>": 151649,
|
| 5 |
+
"<|box_start|>": 151648,
|
| 6 |
+
"<|endoftext|>": 151643,
|
| 7 |
+
"<|file_sep|>": 151664,
|
| 8 |
+
"<|fim_middle|>": 151660,
|
| 9 |
+
"<|fim_pad|>": 151662,
|
| 10 |
+
"<|fim_prefix|>": 151659,
|
| 11 |
+
"<|fim_suffix|>": 151661,
|
| 12 |
+
"<|im_end|>": 151645,
|
| 13 |
+
"<|im_start|>": 151644,
|
| 14 |
+
"<|image_pad|>": 151655,
|
| 15 |
+
"<|object_ref_end|>": 151647,
|
| 16 |
+
"<|object_ref_start|>": 151646,
|
| 17 |
+
"<|quad_end|>": 151651,
|
| 18 |
+
"<|quad_start|>": 151650,
|
| 19 |
+
"<|repo_name|>": 151663,
|
| 20 |
+
"<|video_pad|>": 151656,
|
| 21 |
+
"<|vision_end|>": 151653,
|
| 22 |
+
"<|vision_pad|>": 151654,
|
| 23 |
+
"<|vision_start|>": 151652
|
| 24 |
+
}
|
checkpoint-1000/latest
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
global_step1001
|
checkpoint-1000/merges.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
checkpoint-1000/rng_state_0.pth
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:6cb795a5cea0baa625c50007a6c9da09c6bbb5c16b560424070384a479e7d8a6
|
| 3 |
+
size 14512
|
checkpoint-1000/rng_state_1.pth
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:5f19604377bd828eb366c68946ad997a4ff4d69beaeea93ee58915135768ec63
|
| 3 |
+
size 14512
|
checkpoint-1000/special_tokens_map.json
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"additional_special_tokens": [
|
| 3 |
+
"<|im_start|>",
|
| 4 |
+
"<|im_end|>",
|
| 5 |
+
"<|object_ref_start|>",
|
| 6 |
+
"<|object_ref_end|>",
|
| 7 |
+
"<|box_start|>",
|
| 8 |
+
"<|box_end|>",
|
| 9 |
+
"<|quad_start|>",
|
| 10 |
+
"<|quad_end|>",
|
| 11 |
+
"<|vision_start|>",
|
| 12 |
+
"<|vision_end|>",
|
| 13 |
+
"<|vision_pad|>",
|
| 14 |
+
"<|image_pad|>",
|
| 15 |
+
"<|video_pad|>"
|
| 16 |
+
],
|
| 17 |
+
"eos_token": {
|
| 18 |
+
"content": "<|endoftext|>",
|
| 19 |
+
"lstrip": false,
|
| 20 |
+
"normalized": false,
|
| 21 |
+
"rstrip": false,
|
| 22 |
+
"single_word": false
|
| 23 |
+
},
|
| 24 |
+
"pad_token": {
|
| 25 |
+
"content": "<|endoftext|>",
|
| 26 |
+
"lstrip": false,
|
| 27 |
+
"normalized": false,
|
| 28 |
+
"rstrip": false,
|
| 29 |
+
"single_word": false
|
| 30 |
+
}
|
| 31 |
+
}
|
checkpoint-1000/tokenizer.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9c5ae00e602b8860cbd784ba82a8aa14e8feecec692e7076590d014d7b7fdafa
|
| 3 |
+
size 11421896
|
checkpoint-1000/tokenizer_config.json
ADDED
|
@@ -0,0 +1,208 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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os_token": false,
|
| 3 |
+
"add_prefix_space": false,
|
| 4 |
+
"added_tokens_decoder": {
|
| 5 |
+
"151643": {
|
| 6 |
+
"content": "<|endoftext|>",
|
| 7 |
+
"lstrip": false,
|
| 8 |
+
"normalized": false,
|
| 9 |
+
"rstrip": false,
|
| 10 |
+
"single_word": false,
|
| 11 |
+
"special": true
|
| 12 |
+
},
|
| 13 |
+
"151644": {
|
| 14 |
+
"content": "<|im_start|>",
|
| 15 |
+
"lstrip": false,
|
| 16 |
+
"normalized": false,
|
| 17 |
+
"rstrip": false,
|
| 18 |
+
"single_word": false,
|
| 19 |
+
"special": true
|
| 20 |
+
},
|
| 21 |
+
"151645": {
|
| 22 |
+
"content": "<|im_end|>",
|
| 23 |
+
"lstrip": false,
|
| 24 |
+
"normalized": false,
|
| 25 |
+
"rstrip": false,
|
| 26 |
+
"single_word": false,
|
| 27 |
+
"special": true
|
| 28 |
+
},
|
| 29 |
+
"151646": {
|
| 30 |
+
"content": "<|object_ref_start|>",
|
| 31 |
+
"lstrip": false,
|
| 32 |
+
"normalized": false,
|
| 33 |
+
"rstrip": false,
|
| 34 |
+
"single_word": false,
|
| 35 |
+
"special": true
|
| 36 |
+
},
|
| 37 |
+
"151647": {
|
| 38 |
+
"content": "<|object_ref_end|>",
|
| 39 |
+
"lstrip": false,
|
| 40 |
+
"normalized": false,
|
| 41 |
+
"rstrip": false,
|
| 42 |
+
"single_word": false,
|
| 43 |
+
"special": true
|
| 44 |
+
},
|
| 45 |
+
"151648": {
|
| 46 |
+
"content": "<|box_start|>",
|
| 47 |
+
"lstrip": false,
|
| 48 |
+
"normalized": false,
|
| 49 |
+
"rstrip": false,
|
| 50 |
+
"single_word": false,
|
| 51 |
+
"special": true
|
| 52 |
+
},
|
| 53 |
+
"151649": {
|
| 54 |
+
"content": "<|box_end|>",
|
| 55 |
+
"lstrip": false,
|
| 56 |
+
"normalized": false,
|
| 57 |
+
"rstrip": false,
|
| 58 |
+
"single_word": false,
|
| 59 |
+
"special": true
|
| 60 |
+
},
|
| 61 |
+
"151650": {
|
| 62 |
+
"content": "<|quad_start|>",
|
| 63 |
+
"lstrip": false,
|
| 64 |
+
"normalized": false,
|
| 65 |
+
"rstrip": false,
|
| 66 |
+
"single_word": false,
|
| 67 |
+
"special": true
|
| 68 |
+
},
|
| 69 |
+
"151651": {
|
| 70 |
+
"content": "<|quad_end|>",
|
| 71 |
+
"lstrip": false,
|
| 72 |
+
"normalized": false,
|
| 73 |
+
"rstrip": false,
|
| 74 |
+
"single_word": false,
|
| 75 |
+
"special": true
|
| 76 |
+
},
|
| 77 |
+
"151652": {
|
| 78 |
+
"content": "<|vision_start|>",
|
| 79 |
+
"lstrip": false,
|
| 80 |
+
"normalized": false,
|
| 81 |
+
"rstrip": false,
|
| 82 |
+
"single_word": false,
|
| 83 |
+
"special": true
|
| 84 |
+
},
|
| 85 |
+
"151653": {
|
| 86 |
+
"content": "<|vision_end|>",
|
| 87 |
+
"lstrip": false,
|
| 88 |
+
"normalized": false,
|
| 89 |
+
"rstrip": false,
|
| 90 |
+
"single_word": false,
|
| 91 |
+
"special": true
|
| 92 |
+
},
|
| 93 |
+
"151654": {
|
| 94 |
+
"content": "<|vision_pad|>",
|
| 95 |
+
"lstrip": false,
|
| 96 |
+
"normalized": false,
|
| 97 |
+
"rstrip": false,
|
| 98 |
+
"single_word": false,
|
| 99 |
+
"special": true
|
| 100 |
+
},
|
| 101 |
+
"151655": {
|
| 102 |
+
"content": "<|image_pad|>",
|
| 103 |
+
"lstrip": false,
|
| 104 |
+
"normalized": false,
|
| 105 |
+
"rstrip": false,
|
| 106 |
+
"single_word": false,
|
| 107 |
+
"special": true
|
| 108 |
+
},
|
| 109 |
+
"151656": {
|
| 110 |
+
"content": "<|video_pad|>",
|
| 111 |
+
"lstrip": false,
|
| 112 |
+
"normalized": false,
|
| 113 |
+
"rstrip": false,
|
| 114 |
+
"single_word": false,
|
| 115 |
+
"special": true
|
| 116 |
+
},
|
| 117 |
+
"151657": {
|
| 118 |
+
"content": "<tool_call>",
|
| 119 |
+
"lstrip": false,
|
| 120 |
+
"normalized": false,
|
| 121 |
+
"rstrip": false,
|
| 122 |
+
"single_word": false,
|
| 123 |
+
"special": false
|
| 124 |
+
},
|
| 125 |
+
"151658": {
|
| 126 |
+
"content": "</tool_call>",
|
| 127 |
+
"lstrip": false,
|
| 128 |
+
"normalized": false,
|
| 129 |
+
"rstrip": false,
|
| 130 |
+
"single_word": false,
|
| 131 |
+
"special": false
|
| 132 |
+
},
|
| 133 |
+
"151659": {
|
| 134 |
+
"content": "<|fim_prefix|>",
|
| 135 |
+
"lstrip": false,
|
| 136 |
+
"normalized": false,
|
| 137 |
+
"rstrip": false,
|
| 138 |
+
"single_word": false,
|
| 139 |
+
"special": false
|
| 140 |
+
},
|
| 141 |
+
"151660": {
|
| 142 |
+
"content": "<|fim_middle|>",
|
| 143 |
+
"lstrip": false,
|
| 144 |
+
"normalized": false,
|
| 145 |
+
"rstrip": false,
|
| 146 |
+
"single_word": false,
|
| 147 |
+
"special": false
|
| 148 |
+
},
|
| 149 |
+
"151661": {
|
| 150 |
+
"content": "<|fim_suffix|>",
|
| 151 |
+
"lstrip": false,
|
| 152 |
+
"normalized": false,
|
| 153 |
+
"rstrip": false,
|
| 154 |
+
"single_word": false,
|
| 155 |
+
"special": false
|
| 156 |
+
},
|
| 157 |
+
"151662": {
|
| 158 |
+
"content": "<|fim_pad|>",
|
| 159 |
+
"lstrip": false,
|
| 160 |
+
"normalized": false,
|
| 161 |
+
"rstrip": false,
|
| 162 |
+
"single_word": false,
|
| 163 |
+
"special": false
|
| 164 |
+
},
|
| 165 |
+
"151663": {
|
| 166 |
+
"content": "<|repo_name|>",
|
| 167 |
+
"lstrip": false,
|
| 168 |
+
"normalized": false,
|
| 169 |
+
"rstrip": false,
|
| 170 |
+
"single_word": false,
|
| 171 |
+
"special": false
|
| 172 |
+
},
|
| 173 |
+
"151664": {
|
| 174 |
+
"content": "<|file_sep|>",
|
| 175 |
+
"lstrip": false,
|
| 176 |
+
"normalized": false,
|
| 177 |
+
"rstrip": false,
|
| 178 |
+
"single_word": false,
|
| 179 |
+
"special": false
|
| 180 |
+
}
|
| 181 |
+
},
|
| 182 |
+
"additional_special_tokens": [
|
| 183 |
+
"<|im_start|>",
|
| 184 |
+
"<|im_end|>",
|
| 185 |
+
"<|object_ref_start|>",
|
| 186 |
+
"<|object_ref_end|>",
|
| 187 |
+
"<|box_start|>",
|
| 188 |
+
"<|box_end|>",
|
| 189 |
+
"<|quad_start|>",
|
| 190 |
+
"<|quad_end|>",
|
| 191 |
+
"<|vision_start|>",
|
| 192 |
+
"<|vision_end|>",
|
| 193 |
+
"<|vision_pad|>",
|
| 194 |
+
"<|image_pad|>",
|
| 195 |
+
"<|video_pad|>"
|
| 196 |
+
],
|
| 197 |
+
"bos_token": null,
|
| 198 |
+
"chat_template": "{%- if tools %}\n {{- '<|im_start|>system\\n' }}\n {%- if messages[0]['role'] == 'system' %}\n {{- messages[0]['content'] }}\n {%- else %}\n {{- 'You are a helpful assistant.' }}\n {%- endif %}\n {{- \"\\n\\n# Tools\\n\\nYou may call one or more functions to assist with the user query.\\n\\nYou are provided with function signatures within <tools></tools> XML tags:\\n<tools>\" }}\n {%- for tool in tools %}\n {{- \"\\n\" }}\n {{- tool | tojson }}\n {%- endfor %}\n {{- \"\\n</tools>\\n\\nFor each function call, return a json object with function name and arguments within <tool_call></tool_call> XML tags:\\n<tool_call>\\n{\\\"name\\\": <function-name>, \\\"arguments\\\": <args-json-object>}\\n</tool_call><|im_end|>\\n\" }}\n{%- else %}\n {%- if messages[0]['role'] == 'system' %}\n {{- '<|im_start|>system\\n' + messages[0]['content'] + '<|im_end|>\\n' }}\n {%- else %}\n {{- '<|im_start|>system\\nYou are a helpful assistant.<|im_end|>\\n' }}\n {%- endif %}\n{%- endif %}\n{%- for message in messages %}\n {%- if (message.role == \"user\") or (message.role == \"system\" and not loop.first) or (message.role == \"assistant\" and not message.tool_calls) %}\n {{- '<|im_start|>' + message.role + '\\n' + message.content + '<|im_end|>' + '\\n' }}\n {%- elif message.role == \"assistant\" %}\n {{- '<|im_start|>' + message.role }}\n {%- if message.content %}\n {{- '\\n' + message.content }}\n {%- endif %}\n {%- for tool_call in message.tool_calls %}\n {%- if tool_call.function is defined %}\n {%- set tool_call = tool_call.function %}\n {%- endif %}\n {{- '\\n<tool_call>\\n{\"name\": \"' }}\n {{- tool_call.name }}\n {{- '\", \"arguments\": ' }}\n {{- tool_call.arguments | tojson }}\n {{- '}\\n</tool_call>' }}\n {%- endfor %}\n {{- '<|im_end|>\\n' }}\n {%- elif message.role == \"tool\" %}\n {%- if (loop.index0 == 0) or (messages[loop.index0 - 1].role != \"tool\") %}\n {{- '<|im_start|>user' }}\n {%- endif %}\n {{- '\\n<tool_response>\\n' }}\n {{- message.content }}\n {{- '\\n</tool_response>' }}\n {%- if loop.last or (messages[loop.index0 + 1].role != \"tool\") %}\n {{- '<|im_end|>\\n' }}\n {%- endif %}\n {%- endif %}\n{%- endfor %}\n{%- if add_generation_prompt %}\n {{- '<|im_start|>assistant\\n' }}\n{%- endif %}\n",
|
| 199 |
+
"clean_up_tokenization_spaces": false,
|
| 200 |
+
"eos_token": "<|endoftext|>",
|
| 201 |
+
"errors": "replace",
|
| 202 |
+
"extra_special_tokens": {},
|
| 203 |
+
"model_max_length": 131072,
|
| 204 |
+
"pad_token": "<|endoftext|>",
|
| 205 |
+
"split_special_tokens": false,
|
| 206 |
+
"tokenizer_class": "Qwen2Tokenizer",
|
| 207 |
+
"unk_token": null
|
| 208 |
+
}
|
checkpoint-1000/trainer_state.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
checkpoint-1000/training_args.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:754e4ae9d879853457ade197edaf9a4e09b3e2d2a23d8bffcf3f56a687083eb3
|
| 3 |
+
size 6904
|
checkpo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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python
|
| 2 |
+
|
| 3 |
+
# Copyright (c) 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:
|
| 14 |
+
# python zero_to_fp32.py . output_dir/
|
| 15 |
+
# or
|
| 16 |
+
# python zero_to_fp32.py . output_dir/ --safe_serialization
|
| 17 |
+
|
| 18 |
+
import argparse
|
| 19 |
+
import torch
|
| 20 |
+
import glob
|
| 21 |
+
import math
|
| 22 |
+
import os
|
| 23 |
+
import re
|
| 24 |
+
import json
|
| 25 |
+
from tqdm import tqdm
|
| 26 |
+
from collections import OrderedDict
|
| 27 |
+
from dataclasses import dataclass
|
| 28 |
+
|
| 29 |
+
# while this script doesn't use deepspeed to recover data, since the checkpoints are pickled with
|
| 30 |
+
# DeepSpeed data structures it has to be available in the current python environment.
|
| 31 |
+
from deepspeed.utils import logger
|
| 32 |
+
from deepspeed.checkpoint.constants import (DS_VERSION, OPTIMIZER_STATE_DICT, SINGLE_PARTITION_OF_FP32_GROUPS,
|
| 33 |
+
FP32_FLAT_GROUPS, ZERO_STAGE, PARTITION_COUNT, PARAM_SHAPES, BUFFER_NAMES,
|
| 34 |
+
FROZEN_PARAM_SHAPES, FROZEN_PARAM_FRAGMENTS)
|
| 35 |
+
|
| 36 |
+
|
| 37 |
+
@dataclass
|
| 38 |
+
class zero_model_state:
|
| 39 |
+
buffers: dict()
|
| 40 |
+
param_shapes: dict()
|
| 41 |
+
shared_params: list
|
| 42 |
+
ds_version: int
|
| 43 |
+
frozen_param_shapes: dict()
|
| 44 |
+
frozen_param_fragments: dict()
|
| 45 |
+
|
| 46 |
+
|
| 47 |
+
debug = 0
|
| 48 |
+
|
| 49 |
+
# load to cpu
|
| 50 |
+
device = torch.device('cpu')
|
| 51 |
+
|
| 52 |
+
|
| 53 |
+
def atoi(text):
|
| 54 |
+
return int(text) if text.isdigit() else text
|
| 55 |
+
|
| 56 |
+
|
| 57 |
+
def natural_keys(text):
|
| 58 |
+
'''
|
| 59 |
+
alist.sort(key=natural_keys) sorts in human order
|
| 60 |
+
http://nedbatchelder.com/blog/200712/human_sorting.html
|
| 61 |
+
(See Toothy's implementation in the comments)
|
| 62 |
+
'''
|
| 63 |
+
return [atoi(c) for c in re.split(r'(\d+)', text)]
|
| 64 |
+
|
| 65 |
+
|
| 66 |
+
def get_model_state_file(checkpoint_dir, zero_stage):
|
| 67 |
+
if not os.path.isdir(checkpoint_dir):
|
| 68 |
+
raise FileNotFoundError(f"Directory '{checkpoint_dir}' doesn't exist")
|
| 69 |
+
|
| 70 |
+
# there should be only one file
|
| 71 |
+
if zero_stage <= 2:
|
| 72 |
+
file = os.path.join(checkpoint_dir, "mp_rank_00_model_states.pt")
|
| 73 |
+
elif zero_stage == 3:
|
| 74 |
+
file = os.path.join(checkpoint_dir, "zero_pp_rank_0_mp_rank_00_model_states.pt")
|
| 75 |
+
|
| 76 |
+
if not os.path.exists(file):
|
| 77 |
+
raise FileNotFoundError(f"can't find model states file at '{file}'")
|
| 78 |
+
|
| 79 |
+
return file
|
| 80 |
+
|
| 81 |
+
|
| 82 |
+
def get_checkpoint_files(checkpoint_dir, glob_pattern):
|
| 83 |
+
# XXX: need to test that this simple glob rule works for multi-node setup too
|
| 84 |
+
ckpt_files = sorted(glob.glob(os.path.join(checkpoint_dir, glob_pattern)), key=natural_keys)
|
| 85 |
+
|
| 86 |
+
if len(ckpt_files) == 0:
|
| 87 |
+
raise FileNotFoundError(f"can't find {glob_pattern} files in directory '{checkpoint_dir}'")
|
| 88 |
+
|
| 89 |
+
return ckpt_files
|
| 90 |
+
|
| 91 |
+
|
| 92 |
+
def get_optim_files(checkpoint_dir):
|
| 93 |
+
return get_checkpoint_files(checkpoint_dir, "*_optim_states.pt")
|
| 94 |
+
|
| 95 |
+
|
| 96 |
+
def get_model_state_files(checkpoint_dir):
|
| 97 |
+
return get_checkpoint_files(checkpoint_dir, "*_model_states.pt")
|
| 98 |
+
|
| 99 |
+
|
| 100 |
+
def parse_model_states(files):
|
| 101 |
+
zero_model_states = []
|
| 102 |
+
for file in files:
|
| 103 |
+
state_dict = torch.load(file, map_location=device)
|
| 104 |
+
|
| 105 |
+
if BUFFER_NAMES not in state_dict:
|
| 106 |
+
raise ValueError(f"{file} is not a model state checkpoint")
|
| 107 |
+
buffer_names = state_dict[BUFFER_NAMES]
|
| 108 |
+
if debug:
|
| 109 |
+
print("Found buffers:", buffer_names)
|
| 110 |
+
|
| 111 |
+
# recover just the buffers while restoring them to fp32 if they were saved in fp16
|
| 112 |
+
buffers = {k: v.float() for k, v in state_dict["module"].items() if k in buffer_names}
|
| 113 |
+
param_shapes = state_dict[PARAM_SHAPES]
|
| 114 |
+
|
| 115 |
+
# collect parameters that are included in param_shapes
|
| 116 |
+
param_names = []
|
| 117 |
+
for s in param_shapes:
|
| 118 |
+
for name in s.keys():
|
| 119 |
+
param_names.append(name)
|
| 120 |
+
|
| 121 |
+
# update with frozen parameters
|
| 122 |
+
frozen_param_shapes = state_dict.get(FROZEN_PARAM_SHAPES, None)
|
| 123 |
+
if frozen_param_shapes is not None:
|
| 124 |
+
if debug:
|
| 125 |
+
print(f"Found frozen_param_shapes: {frozen_param_shapes}")
|
| 126 |
+
param_names += list(frozen_param_shapes.keys())
|
| 127 |
+
|
| 128 |
+
# handle shared params
|
| 129 |
+
shared_params = [[k, v] for k, v in state_dict["shared_params"].items()]
|
| 130 |
+
|
| 131 |
+
ds_version = state_dict.get(DS_VERSION, None)
|
| 132 |
+
|
| 133 |
+
frozen_param_fragments = state_dict.get(FROZEN_PARAM_FRAGMENTS, None)
|
| 134 |
+
|
| 135 |
+
z_model_state = zero_model_state(buffers=buffers,
|
| 136 |
+
param_shapes=param_shapes,
|
| 137 |
+
shared_params=shared_params,
|
| 138 |
+
ds_version=ds_version,
|
| 139 |
+
frozen_param_shapes=frozen_param_shapes,
|
| 140 |
+
frozen_param_fragments=frozen_param_fragments)
|
| 141 |
+
zero_model_states.append(z_model_state)
|
| 142 |
+
|
| 143 |
+
return zero_model_states
|
| 144 |
+
|
| 145 |
+
|
| 146 |
+
def parse_optim_states(files, ds_checkpoint_dir):
|
| 147 |
+
total_files = len(files)
|
| 148 |
+
state_dicts = []
|
| 149 |
+
for f in files:
|
| 150 |
+
state_dict = torch.load(f, map_location=device)
|
| 151 |
+
# immediately discard the potentially huge 2 optimizer states as we only care for fp32 master weights
|
| 152 |
+
# and also handle the case where it was already removed by another helper script
|
| 153 |
+
state_dict["optimizer_state_dict"].pop("optimizer_state_dict", None)
|
| 154 |
+
state_dicts.append(state_dict)
|
| 155 |
+
|
| 156 |
+
if not ZERO_STAGE in state_dicts[0][OPTIMIZER_STATE_DICT]:
|
| 157 |
+
raise ValueError(f"{files[0]} is not a zero checkpoint")
|
| 158 |
+
zero_stage = state_dicts[0][OPTIMIZER_STATE_DICT][ZERO_STAGE]
|
| 159 |
+
world_size = state_dicts[0][OPTIMIZER_STATE_DICT][PARTITION_COUNT]
|
| 160 |
+
|
| 161 |
+
# For ZeRO-2 each param group can have different partition_count as data parallelism for expert
|
| 162 |
+
# parameters can be different from data parallelism for non-expert parameters. So we can just
|
| 163 |
+
# use the max of the partition_count to get the dp world_size.
|
| 164 |
+
|
| 165 |
+
if type(world_size) is list:
|
| 166 |
+
world_size = max(world_size)
|
| 167 |
+
|
| 168 |
+
if world_size != total_files:
|
| 169 |
+
raise ValueError(
|
| 170 |
+
f"Expected {world_size} of '*_optim_states.pt' under '{ds_checkpoint_dir}' but found {total_files} files. "
|
| 171 |
+
"Possibly due to an overwrite of an old checkpoint, or a checkpoint didn't get saved by one or more processes."
|
| 172 |
+
)
|
| 173 |
+
|
| 174 |
+
# the groups are named differently in each stage
|
| 175 |
+
if zero_stage <= 2:
|
| 176 |
+
fp32_groups_key = SINGLE_PARTITION_OF_FP32_GROUPS
|
| 177 |
+
elif zero_stage == 3:
|
| 178 |
+
fp32_groups_key = FP32_FLAT_GROUPS
|
| 179 |
+
else:
|
| 180 |
+
raise ValueError(f"unknown zero stage {zero_stage}")
|
| 181 |
+
|
| 182 |
+
if zero_stage <= 2:
|
| 183 |
+
fp32_flat_groups = [state_dicts[i][OPTIMIZER_STATE_DICT][fp32_groups_key] for i in range(len(state_dicts))]
|
| 184 |
+
elif zero_stage == 3:
|
| 185 |
+
# if there is more than one param group, there will be multiple flattened tensors - one
|
| 186 |
+
# flattened tensor per group - for simplicity merge them into a single tensor
|
| 187 |
+
#
|
| 188 |
+
# XXX: could make the script more memory efficient for when there are multiple groups - it
|
| 189 |
+
# will require matching the sub-lists of param_shapes for each param group flattened tensor
|
| 190 |
+
|
| 191 |
+
fp32_flat_groups = [
|
| 192 |
+
torch.cat(state_dicts[i][OPTIMIZER_STATE_DICT][fp32_groups_key], 0) for i in range(len(state_dicts))
|
| 193 |
+
]
|
| 194 |
+
|
| 195 |
+
return zero_stage, world_size, fp32_flat_groups
|
| 196 |
+
|
| 197 |
+
|
| 198 |
+
def _get_fp32_state_dict_from_zero_checkpoint(ds_checkpoint_dir, exclude_frozen_parameters):
|
| 199 |
+
"""
|
| 200 |
+
Returns fp32 state_dict reconstructed from ds checkpoint
|
| 201 |
+
|
| 202 |
+
Args:
|
| 203 |
+
- ``ds_checkpoint_dir``: path to the deepspeed checkpoint folder (where the optimizer files are)
|
| 204 |
+
|
| 205 |
+
"""
|
| 206 |
+
print(f"Processing zero checkpoint '{ds_checkpoint_dir}'")
|
| 207 |
+
|
| 208 |
+
optim_files = get_optim_files(ds_checkpoint_dir)
|
| 209 |
+
zero_stage, world_size, fp32_flat_groups = parse_optim_states(optim_files, ds_checkpoint_dir)
|
| 210 |
+
print(f"Detected checkpoint of type zero stage {zero_stage}, world_size: {world_size}")
|
| 211 |
+
|
| 212 |
+
model_files = get_model_state_files(ds_checkpoint_dir)
|
| 213 |
+
|
| 214 |
+
zero_model_states = parse_model_states(model_files)
|
| 215 |
+
print(f'Parsing checkpoint created by deepspeed=={zero_model_states[0].ds_version}')
|
| 216 |
+
|
| 217 |
+
if zero_stage <= 2:
|
| 218 |
+
return _get_fp32_state_dict_from_zero2_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 219 |
+
exclude_frozen_parameters)
|
| 220 |
+
elif zero_stage == 3:
|
| 221 |
+
return _get_fp32_state_dict_from_zero3_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 222 |
+
exclude_frozen_parameters)
|
| 223 |
+
|
| 224 |
+
|
| 225 |
+
def _zero2_merge_frozen_params(state_dict, zero_model_states):
|
| 226 |
+
if zero_model_states[0].frozen_param_shapes is None or len(zero_model_states[0].frozen_param_shapes) == 0:
|
| 227 |
+
return
|
| 228 |
+
|
| 229 |
+
frozen_param_shapes = zero_model_states[0].frozen_param_shapes
|
| 230 |
+
frozen_param_fragments = zero_model_states[0].frozen_param_fragments
|
| 231 |
+
|
| 232 |
+
if debug:
|
| 233 |
+
num_elem = sum(s.numel() for s in frozen_param_shapes.values())
|
| 234 |
+
print(f'rank 0: {FROZEN_PARAM_SHAPES}.numel = {num_elem}')
|
| 235 |
+
|
| 236 |
+
wanted_params = len(frozen_param_shapes)
|
| 237 |
+
wanted_numel = sum(s.numel() for s in frozen_param_shapes.values())
|
| 238 |
+
avail_numel = sum([p.numel() for p in frozen_param_fragments.values()])
|
| 239 |
+
print(f'Frozen params: Have {avail_numel} numels to process.')
|
| 240 |
+
print(f'Frozen params: Need {wanted_numel} numels in {wanted_params} params')
|
| 241 |
+
|
| 242 |
+
total_params = 0
|
| 243 |
+
total_numel = 0
|
| 244 |
+
for name, shape in frozen_param_shapes.items():
|
| 245 |
+
total_params += 1
|
| 246 |
+
unpartitioned_numel = shape.numel()
|
| 247 |
+
total_numel += unpartitioned_numel
|
| 248 |
+
|
| 249 |
+
state_dict[name] = frozen_param_fragments[name]
|
| 250 |
+
|
| 251 |
+
if debug:
|
| 252 |
+
print(f"{name} full shape: {shape} unpartitioned numel {unpartitioned_numel} ")
|
| 253 |
+
|
| 254 |
+
print(f"Reconstructed Frozen fp32 state dict with {total_params} params {total_numel} elements")
|
| 255 |
+
|
| 256 |
+
|
| 257 |
+
def _has_callable(obj, fn):
|
| 258 |
+
attr = getattr(obj, fn, None)
|
| 259 |
+
return callable(attr)
|
| 260 |
+
|
| 261 |
+
|
| 262 |
+
def _zero2_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states):
|
| 263 |
+
param_shapes = zero_model_states[0].param_shapes
|
| 264 |
+
|
| 265 |
+
# Reconstruction protocol:
|
| 266 |
+
#
|
| 267 |
+
# XXX: document this
|
| 268 |
+
|
| 269 |
+
if debug:
|
| 270 |
+
for i in range(world_size):
|
| 271 |
+
for j in range(len(fp32_flat_groups[0])):
|
| 272 |
+
print(f"{FP32_FLAT_GROUPS}[{i}][{j}].shape={fp32_flat_groups[i][j].shape}")
|
| 273 |
+
|
| 274 |
+
# XXX: memory usage doubles here (zero2)
|
| 275 |
+
num_param_groups = len(fp32_flat_groups[0])
|
| 276 |
+
merged_single_partition_of_fp32_groups = []
|
| 277 |
+
for i in range(num_param_groups):
|
| 278 |
+
merged_partitions = [sd[i] for sd in fp32_flat_groups]
|
| 279 |
+
full_single_fp32_vector = torch.cat(merged_partitions, 0)
|
| 280 |
+
merged_single_partition_of_fp32_groups.append(full_single_fp32_vector)
|
| 281 |
+
avail_numel = sum(
|
| 282 |
+
[full_single_fp32_vector.numel() for full_single_fp32_vector in merged_single_partition_of_fp32_groups])
|
| 283 |
+
|
| 284 |
+
if debug:
|
| 285 |
+
wanted_params = sum([len(shapes) for shapes in param_shapes])
|
| 286 |
+
wanted_numel = sum([sum(shape.numel() for shape in shapes.values()) for shapes in param_shapes])
|
| 287 |
+
# not asserting if there is a mismatch due to possible padding
|
| 288 |
+
print(f"Have {avail_numel} numels to process.")
|
| 289 |
+
print(f"Need {wanted_numel} numels in {wanted_params} params.")
|
| 290 |
+
|
| 291 |
+
# params
|
| 292 |
+
# XXX: for huge models that can't fit into the host's RAM we will have to recode this to support
|
| 293 |
+
# out-of-core computing solution
|
| 294 |
+
total_numel = 0
|
| 295 |
+
total_params = 0
|
| 296 |
+
for shapes, full_single_fp32_vector in zip(param_shapes, merged_single_partition_of_fp32_groups):
|
| 297 |
+
offset = 0
|
| 298 |
+
avail_numel = full_single_fp32_vector.numel()
|
| 299 |
+
for name, shape in shapes.items():
|
| 300 |
+
|
| 301 |
+
unpartitioned_numel = shape.numel() if _has_callable(shape, 'numel') else math.prod(shape)
|
| 302 |
+
total_numel += unpartitioned_numel
|
| 303 |
+
total_params += 1
|
| 304 |
+
|
| 305 |
+
if debug:
|
| 306 |
+
print(f"{name} full shape: {shape} unpartitioned numel {unpartitioned_numel} ")
|
| 307 |
+
state_dict[name] = full_single_fp32_vector.narrow(0, offset, unpartitioned_numel).view(shape)
|
| 308 |
+
offset += unpartitioned_numel
|
| 309 |
+
|
| 310 |
+
# Z2 started to align to 2*world_size to improve nccl performance. Therefore both offset and
|
| 311 |
+
# avail_numel can differ by anywhere between 0..2*world_size. Due to two unrelated complex
|
| 312 |
+
# paddings performed in the code it's almost impossible to predict the exact numbers w/o the
|
| 313 |
+
# live optimizer object, so we are checking that the numbers are within the right range
|
| 314 |
+
align_to = 2 * world_size
|
| 315 |
+
|
| 316 |
+
def zero2_align(x):
|
| 317 |
+
return align_to * math.ceil(x / align_to)
|
| 318 |
+
|
| 319 |
+
if debug:
|
| 320 |
+
print(f"original offset={offset}, avail_numel={avail_numel}")
|
| 321 |
+
|
| 322 |
+
offset = zero2_align(offset)
|
| 323 |
+
avail_numel = zero2_align(avail_numel)
|
| 324 |
+
|
| 325 |
+
if debug:
|
| 326 |
+
print(f"aligned offset={offset}, avail_numel={avail_numel}")
|
| 327 |
+
|
| 328 |
+
# Sanity check
|
| 329 |
+
if offset != avail_numel:
|
| 330 |
+
raise ValueError(f"consumed {offset} numels out of {avail_numel} - something is wrong")
|
| 331 |
+
|
| 332 |
+
print(f"Reconstructed fp32 state dict with {total_params} params {total_numel} elements")
|
| 333 |
+
|
| 334 |
+
|
| 335 |
+
def _get_fp32_state_dict_from_zero2_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 336 |
+
exclude_frozen_parameters):
|
| 337 |
+
state_dict = OrderedDict()
|
| 338 |
+
|
| 339 |
+
# buffers
|
| 340 |
+
buffers = zero_model_states[0].buffers
|
| 341 |
+
state_dict.update(buffers)
|
| 342 |
+
if debug:
|
| 343 |
+
print(f"added {len(buffers)} buffers")
|
| 344 |
+
|
| 345 |
+
if not exclude_frozen_parameters:
|
| 346 |
+
_zero2_merge_frozen_params(state_dict, zero_model_states)
|
| 347 |
+
|
| 348 |
+
_zero2_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states)
|
| 349 |
+
|
| 350 |
+
# recover shared parameters
|
| 351 |
+
for pair in zero_model_states[0].shared_params:
|
| 352 |
+
if pair[1] in state_dict:
|
| 353 |
+
state_dict[pair[0]] = state_dict[pair[1]]
|
| 354 |
+
|
| 355 |
+
return state_dict
|
| 356 |
+
|
| 357 |
+
|
| 358 |
+
def zero3_partitioned_param_info(unpartitioned_numel, world_size):
|
| 359 |
+
remainder = unpartitioned_numel % world_size
|
| 360 |
+
padding_numel = (world_size - remainder) if remainder else 0
|
| 361 |
+
partitioned_numel = math.ceil(unpartitioned_numel / world_size)
|
| 362 |
+
return partitioned_numel, padding_numel
|
| 363 |
+
|
| 364 |
+
|
| 365 |
+
def _zero3_merge_frozen_params(state_dict, world_size, zero_model_states):
|
| 366 |
+
if zero_model_states[0].frozen_param_shapes is None or len(zero_model_states[0].frozen_param_shapes) == 0:
|
| 367 |
+
return
|
| 368 |
+
|
| 369 |
+
if debug:
|
| 370 |
+
for i in range(world_size):
|
| 371 |
+
num_elem = sum(s.numel() for s in zero_model_states[i].frozen_param_fragments.values())
|
| 372 |
+
print(f'rank {i}: {FROZEN_PARAM_SHAPES}.numel = {num_elem}')
|
| 373 |
+
|
| 374 |
+
frozen_param_shapes = zero_model_states[0].frozen_param_shapes
|
| 375 |
+
wanted_params = len(frozen_param_shapes)
|
| 376 |
+
wanted_numel = sum(s.numel() for s in frozen_param_shapes.values())
|
| 377 |
+
avail_numel = sum([p.numel() for p in zero_model_states[0].frozen_param_fragments.values()]) * world_size
|
| 378 |
+
print(f'Frozen params: Have {avail_numel} numels to process.')
|
| 379 |
+
print(f'Frozen params: Need {wanted_numel} numels in {wanted_params} params')
|
| 380 |
+
|
| 381 |
+
total_params = 0
|
| 382 |
+
total_numel = 0
|
| 383 |
+
for name, shape in zero_model_states[0].frozen_param_shapes.items():
|
| 384 |
+
total_params += 1
|
| 385 |
+
unpartitioned_numel = shape.numel()
|
| 386 |
+
total_numel += unpartitioned_numel
|
| 387 |
+
|
| 388 |
+
param_frags = tuple(model_state.frozen_param_fragments[name] for model_state in zero_model_states)
|
| 389 |
+
state_dict[name] = torch.cat(param_frags, 0).narrow(0, 0, unpartitioned_numel).view(shape)
|
| 390 |
+
|
| 391 |
+
partitioned_numel, partitioned_padding_numel = zero3_partitioned_param_info(unpartitioned_numel, world_size)
|
| 392 |
+
|
| 393 |
+
if debug:
|
| 394 |
+
print(
|
| 395 |
+
f"Frozen params: {total_params} {name} full shape: {shape} partition0 numel={partitioned_numel} partitioned_padding_numel={partitioned_padding_numel}"
|
| 396 |
+
)
|
| 397 |
+
|
| 398 |
+
print(f"Reconstructed Frozen fp32 state dict with {total_params} params {total_numel} elements")
|
| 399 |
+
|
| 400 |
+
|
| 401 |
+
def _zero3_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states):
|
| 402 |
+
param_shapes = zero_model_states[0].param_shapes
|
| 403 |
+
avail_numel = fp32_flat_groups[0].numel() * world_size
|
| 404 |
+
# Reconstruction protocol: For zero3 we need to zip the partitions together at boundary of each
|
| 405 |
+
# param, re-consolidating each param, while dealing with padding if any
|
| 406 |
+
|
| 407 |
+
# merge list of dicts, preserving order
|
| 408 |
+
param_shapes = {k: v for d in param_shapes for k, v in d.items()}
|
| 409 |
+
|
| 410 |
+
if debug:
|
| 411 |
+
for i in range(world_size):
|
| 412 |
+
print(f"{FP32_FLAT_GROUPS}[{i}].shape={fp32_flat_groups[i].shape}")
|
| 413 |
+
|
| 414 |
+
wanted_params = len(param_shapes)
|
| 415 |
+
wanted_numel = sum(shape.numel() for shape in param_shapes.values())
|
| 416 |
+
# not asserting if there is a mismatch due to possible padding
|
| 417 |
+
avail_numel = fp32_flat_groups[0].numel() * world_size
|
| 418 |
+
print(f"Trainable params: Have {avail_numel} numels to process.")
|
| 419 |
+
print(f"Trainable params: Need {wanted_numel} numels in {wanted_params} params.")
|
| 420 |
+
|
| 421 |
+
# params
|
| 422 |
+
# XXX: for huge models that can't fit into the host's RAM we will have to recode this to support
|
| 423 |
+
# out-of-core computing solution
|
| 424 |
+
offset = 0
|
| 425 |
+
total_numel = 0
|
| 426 |
+
total_params = 0
|
| 427 |
+
for name, shape in tqdm(param_shapes.items(), desc='Gathering Sharded Weights'):
|
| 428 |
+
unpartitioned_numel = shape.numel()
|
| 429 |
+
total_numel += unpartitioned_numel
|
| 430 |
+
total_params += 1
|
| 431 |
+
partitioned_numel, partitioned_padding_numel = zero3_partitioned_param_info(unpartitioned_numel, world_size)
|
| 432 |
+
|
| 433 |
+
if debug:
|
| 434 |
+
print(
|
| 435 |
+
f"Trainable params: {total_params} {name} full shape: {shape} partition0 numel={partitioned_numel} partitioned_padding_numel={partitioned_padding_numel}"
|
| 436 |
+
)
|
| 437 |
+
|
| 438 |
+
# XXX: memory usage doubles here
|
| 439 |
+
state_dict[name] = torch.cat(
|
| 440 |
+
tuple(fp32_flat_groups[i].narrow(0, offset, partitioned_numel) for i in range(world_size)),
|
| 441 |
+
0).narrow(0, 0, unpartitioned_numel).view(shape)
|
| 442 |
+
offset += partitioned_numel
|
| 443 |
+
|
| 444 |
+
offset *= world_size
|
| 445 |
+
|
| 446 |
+
# Sanity check
|
| 447 |
+
if offset != avail_numel:
|
| 448 |
+
raise ValueError(f"consumed {offset} numels out of {avail_numel} - something is wrong")
|
| 449 |
+
|
| 450 |
+
print(f"Reconstructed Trainable fp32 state dict with {total_params} params {total_numel} elements")
|
| 451 |
+
|
| 452 |
+
|
| 453 |
+
def _get_fp32_state_dict_from_zero3_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 454 |
+
exclude_frozen_parameters):
|
| 455 |
+
state_dict = OrderedDict()
|
| 456 |
+
|
| 457 |
+
# buffers
|
| 458 |
+
buffers = zero_model_states[0].buffers
|
| 459 |
+
state_dict.update(buffers)
|
| 460 |
+
if debug:
|
| 461 |
+
print(f"added {len(buffers)} buffers")
|
| 462 |
+
|
| 463 |
+
if not exclude_frozen_parameters:
|
| 464 |
+
_zero3_merge_frozen_params(state_dict, world_size, zero_model_states)
|
| 465 |
+
|
| 466 |
+
_zero3_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states)
|
| 467 |
+
|
| 468 |
+
# recover shared parameters
|
| 469 |
+
for pair in zero_model_states[0].shared_params:
|
| 470 |
+
if pair[1] in state_dict:
|
| 471 |
+
state_dict[pair[0]] = state_dict[pair[1]]
|
| 472 |
+
|
| 473 |
+
return state_dict
|
| 474 |
+
|
| 475 |
+
|
| 476 |
+
def get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag=None, exclude_frozen_parameters=False):
|
| 477 |
+
"""
|
| 478 |
+
Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated state_dict that can be loaded with
|
| 479 |
+
``load_state_dict()`` and used for training without DeepSpeed or shared with others, for example
|
| 480 |
+
via a model hub.
|
| 481 |
+
|
| 482 |
+
Args:
|
| 483 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder
|
| 484 |
+
- ``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``
|
| 485 |
+
- ``exclude_frozen_parameters``: exclude frozen parameters
|
| 486 |
+
|
| 487 |
+
Returns:
|
| 488 |
+
- pytorch ``state_dict``
|
| 489 |
+
|
| 490 |
+
Note: this approach may not work if your application doesn't have sufficient free CPU memory and
|
| 491 |
+
you may need to use the offline approach using the ``zero_to_fp32.py`` script that is saved with
|
| 492 |
+
the checkpoint.
|
| 493 |
+
|
| 494 |
+
A typical usage might be ::
|
| 495 |
+
|
| 496 |
+
from deepspeed.utils.zero_to_fp32 import get_fp32_state_dict_from_zero_checkpoint
|
| 497 |
+
# do the training and checkpoint saving
|
| 498 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir) # already on cpu
|
| 499 |
+
model = model.cpu() # move to cpu
|
| 500 |
+
model.load_state_dict(state_dict)
|
| 501 |
+
# submit to model hub or save the model to share with others
|
| 502 |
+
|
| 503 |
+
In this example the ``model`` will no longer be usable in the deepspeed context of the same
|
| 504 |
+
application. i.e. you will need to re-initialize the deepspeed engine, since
|
| 505 |
+
``model.load_state_dict(state_dict)`` will remove all the deepspeed magic from it.
|
| 506 |
+
|
| 507 |
+
If you want it all done for you, use ``load_state_dict_from_zero_checkpoint`` instead.
|
| 508 |
+
|
| 509 |
+
"""
|
| 510 |
+
if tag is None:
|
| 511 |
+
latest_path = os.path.join(checkpoint_dir, 'latest')
|
| 512 |
+
if os.path.isfile(latest_path):
|
| 513 |
+
with open(latest_path, 'r') as fd:
|
| 514 |
+
tag = fd.read().strip()
|
| 515 |
+
else:
|
| 516 |
+
raise ValueError(f"Unable to find 'latest' file at {latest_path}")
|
| 517 |
+
|
| 518 |
+
ds_checkpoint_dir = os.path.join(checkpoint_dir, tag)
|
| 519 |
+
|
| 520 |
+
if not os.path.isdir(ds_checkpoint_dir):
|
| 521 |
+
raise FileNotFoundError(f"Directory '{ds_checkpoint_dir}' doesn't exist")
|
| 522 |
+
|
| 523 |
+
return _get_fp32_state_dict_from_zero_checkpoint(ds_checkpoint_dir, exclude_frozen_parameters)
|
| 524 |
+
|
| 525 |
+
|
| 526 |
+
def convert_zero_checkpoint_to_fp32_state_dict(checkpoint_dir,
|
| 527 |
+
output_dir,
|
| 528 |
+
max_shard_size="5GB",
|
| 529 |
+
safe_serialization=False,
|
| 530 |
+
tag=None,
|
| 531 |
+
exclude_frozen_parameters=False):
|
| 532 |
+
"""
|
| 533 |
+
Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated ``state_dict`` file that can be
|
| 534 |
+
loaded with ``torch.load(file)`` + ``load_state_dict()`` and used for training without DeepSpeed.
|
| 535 |
+
|
| 536 |
+
Args:
|
| 537 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder. (one that contains the tag-folder, like ``global_step14``)
|
| 538 |
+
- ``output_dir``: directory to the pytorch fp32 state_dict output files
|
| 539 |
+
- ``max_shard_size``: the maximum size for a checkpoint before being sharded, default value is 5GB
|
| 540 |
+
- ``safe_serialization``: whether to save the model using `safetensors` or the traditional PyTorch way (that uses `pickle`).
|
| 541 |
+
- ``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``
|
| 542 |
+
- ``exclude_frozen_parameters``: exclude frozen parameters
|
| 543 |
+
"""
|
| 544 |
+
# Dependency pre-check
|
| 545 |
+
if safe_serialization:
|
| 546 |
+
try:
|
| 547 |
+
from safetensors.torch import save_file
|
| 548 |
+
except ImportError:
|
| 549 |
+
print('If you want to use `safe_serialization`, please `pip install safetensors`')
|
| 550 |
+
raise
|
| 551 |
+
if max_shard_size is not None:
|
| 552 |
+
try:
|
| 553 |
+
from huggingface_hub import split_torch_state_dict_into_shards
|
| 554 |
+
except ImportError:
|
| 555 |
+
print('If you want to use `max_shard_size`, please `pip install huggingface_hub`')
|
| 556 |
+
raise
|
| 557 |
+
|
| 558 |
+
# Convert zero checkpoint to state_dict
|
| 559 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag, exclude_frozen_parameters)
|
| 560 |
+
|
| 561 |
+
# Shard the model if it is too big.
|
| 562 |
+
weights_name = "model.safetensors" if safe_serialization else "pytorch_model.bin"
|
| 563 |
+
if max_shard_size is not None:
|
| 564 |
+
filename_pattern = weights_name.replace(".bin", "{suffix}.bin").replace(".safetensors", "{suffix}.safetensors")
|
| 565 |
+
state_dict_split = split_torch_state_dict_into_shards(state_dict,
|
| 566 |
+
filename_pattern=filename_pattern,
|
| 567 |
+
max_shard_size=max_shard_size)
|
| 568 |
+
else:
|
| 569 |
+
from collections import namedtuple
|
| 570 |
+
StateDictSplit = namedtuple("StateDictSplit", ["is_sharded", "filename_to_tensors"])
|
| 571 |
+
state_dict_split = StateDictSplit(is_sharded=False,
|
| 572 |
+
filename_to_tensors={weights_name: list(state_dict.keys())})
|
| 573 |
+
|
| 574 |
+
# Save the model
|
| 575 |
+
filename_to_tensors = state_dict_split.filename_to_tensors.items()
|
| 576 |
+
for shard_file, tensors in tqdm(filename_to_tensors, desc="Saving checkpoint shards"):
|
| 577 |
+
shard = {tensor: state_dict[tensor].contiguous() for tensor in tensors}
|
| 578 |
+
output_path = os.path.join(output_dir, shard_file)
|
| 579 |
+
if safe_serialization:
|
| 580 |
+
save_file(shard, output_path, metadata={"format": "pt"})
|
| 581 |
+
else:
|
| 582 |
+
torch.save(shard, output_path)
|
| 583 |
+
|
| 584 |
+
# Save index if sharded
|
| 585 |
+
if state_dict_split.is_sharded:
|
| 586 |
+
index = {
|
| 587 |
+
"metadata": state_dict_split.metadata,
|
| 588 |
+
"weight_map": state_dict_split.tensor_to_filename,
|
| 589 |
+
}
|
| 590 |
+
save_index_file = "model.safetensors.index.json" if safe_serialization else "pytorch_model.bin.index.json"
|
| 591 |
+
save_index_file = os.path.join(output_dir, save_index_file)
|
| 592 |
+
with open(save_index_file, "w", encoding="utf-8") as f:
|
| 593 |
+
content = json.dumps(index, indent=2, sort_keys=True) + "\n"
|
| 594 |
+
f.write(content)
|
| 595 |
+
|
| 596 |
+
|
| 597 |
+
def load_state_dict_from_zero_checkpoint(model, checkpoint_dir, tag=None):
|
| 598 |
+
"""
|
| 599 |
+
1. Put the provided model to cpu
|
| 600 |
+
2. Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated ``state_dict``
|
| 601 |
+
3. Load it into the provided model
|
| 602 |
+
|
| 603 |
+
Args:
|
| 604 |
+
- ``model``: the model object to update
|
| 605 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder. (one that contains the tag-folder, like ``global_step14``)
|
| 606 |
+
- ``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``
|
| 607 |
+
|
| 608 |
+
Returns:
|
| 609 |
+
- ``model`: modified model
|
| 610 |
+
|
| 611 |
+
Make sure you have plenty of CPU memory available before you call this function. If you don't
|
| 612 |
+
have enough use the ``zero_to_fp32.py`` utility to do the conversion. You will find it
|
| 613 |
+
conveniently placed for you in the checkpoint folder.
|
| 614 |
+
|
| 615 |
+
A typical usage might be ::
|
| 616 |
+
|
| 617 |
+
from deepspeed.utils.zero_to_fp32 import load_state_dict_from_zero_checkpoint
|
| 618 |
+
model = load_state_dict_from_zero_checkpoint(trainer.model, checkpoint_dir)
|
| 619 |
+
# submit to model hub or save the model to share with others
|
| 620 |
+
|
| 621 |
+
Note, that once this was run, the ``model`` will no longer be usable in the deepspeed context
|
| 622 |
+
of the same application. i.e. you will need to re-initialize the deepspeed engine, since
|
| 623 |
+
``model.load_state_dict(state_dict)`` will remove all the deepspeed magic from it.
|
| 624 |
+
|
| 625 |
+
"""
|
| 626 |
+
logger.info(f"Extracting fp32 weights")
|
| 627 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag)
|
| 628 |
+
|
| 629 |
+
logger.info(f"Overwriting model with fp32 weights")
|
| 630 |
+
model = model.cpu()
|
| 631 |
+
model.load_state_dict(state_dict, strict=False)
|
| 632 |
+
|
| 633 |
+
return model
|
| 634 |
+
|
| 635 |
+
|
| 636 |
+
if __name__ == "__main__":
|
| 637 |
+
parser = argparse.ArgumentParser()
|
| 638 |
+
parser.add_argument("checkpoint_dir",
|
| 639 |
+
type=str,
|
| 640 |
+
help="path to the desired checkpoint folder, e.g., path/checkpoint-12")
|
| 641 |
+
parser.add_argument("output_dir",
|
| 642 |
+
type=str,
|
| 643 |
+
help="directory to the pytorch fp32 state_dict output files"
|
| 644 |
+
"(e.g. path/checkpoint-12-output/)")
|
| 645 |
+
parser.add_argument(
|
| 646 |
+
"--max_shard_size",
|
| 647 |
+
type=str,
|
| 648 |
+
default="5GB",
|
| 649 |
+
help="The maximum size for a checkpoint before being sharded. Checkpoints shard will then be each of size"
|
| 650 |
+
"lower than this size. If expressed as a string, needs to be digits followed by a unit (like `5MB`"
|
| 651 |
+
"We default it to 5GB in order for models to be able to run easily on free-tier google colab instances"
|
| 652 |
+
"without CPU OOM issues.")
|
| 653 |
+
parser.add_argument(
|
| 654 |
+
"--safe_serialization",
|
| 655 |
+
default=False,
|
| 656 |
+
action='store_true',
|
| 657 |
+
help="Whether to save the model using `safetensors` or the traditional PyTorch way (that uses `pickle`).")
|
| 658 |
+
parser.add_argument("-t",
|
| 659 |
+
"--tag",
|
| 660 |
+
type=str,
|
| 661 |
+
default=None,
|
| 662 |
+
help="checkpoint tag used as a unique identifier for checkpoint. e.g., global_step1")
|
| 663 |
+
parser.add_argument("--exclude_frozen_parameters", action='store_true', help="exclude frozen parameters")
|
| 664 |
+
parser.add_argument("-d", "--debug", action='store_true', help="enable debug")
|
| 665 |
+
args = parser.parse_args()
|
| 666 |
+
|
| 667 |
+
debug = args.debug
|
| 668 |
+
|
| 669 |
+
convert_zero_checkpoint_to_fp32_state_dict(args.checkpoint_dir,
|
| 670 |
+
args.output_dir,
|
| 671 |
+
max_shard_size=args.max_shard_size,
|
| 672 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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
base_model: Qwen/Qwen2.5-7B
|
| 3 |
+
library_name: peft
|
| 4 |
+
---
|
| 5 |
+
|
| 6 |
+
# Model Card for Model ID
|
| 7 |
+
|
| 8 |
+
<!-- Provide a quick summary of what the model is/does. -->
|
| 9 |
+
|
| 10 |
+
|
| 11 |
+
|
| 12 |
+
## Model Details
|
| 13 |
+
|
| 14 |
+
### Model Description
|
| 15 |
+
|
| 16 |
+
<!-- Provide a longer summary of what this model is. -->
|
| 17 |
+
|
| 18 |
+
|
| 19 |
+
|
| 20 |
+
- **Developed by:** [More Information Needed]
|
| 21 |
+
- **Funded by [optional]:** [More Information Needed]
|
| 22 |
+
- **Shared by [optional]:** [More Information Needed]
|
| 23 |
+
- **Model type:** [More Information Needed]
|
| 24 |
+
- **Language(s) (NLP):** [More Information Needed]
|
| 25 |
+
- **License:** [More Information Needed]
|
| 26 |
+
- **Finetuned from model [optional]:** [More Information Needed]
|
| 27 |
+
|
| 28 |
+
### Model Sources [optional]
|
| 29 |
+
|
| 30 |
+
<!-- Provide the basic links for the model. -->
|
| 31 |
+
|
| 32 |
+
- **Repository:** [More Information Needed]
|
| 33 |
+
- **Paper [optional]:** [More Information Needed]
|
| 34 |
+
- **Demo [optional]:** [More Information Needed]
|
| 35 |
+
|
| 36 |
+
## Uses
|
| 37 |
+
|
| 38 |
+
<!-- Address questions around how the model is intended to be used, including the foreseeable users of the model and those affected by the model. -->
|
| 39 |
+
|
| 40 |
+
### Direct Use
|
| 41 |
+
|
| 42 |
+
<!-- This section is for the model use without fine-tuning or plugging into a larger ecosystem/app. -->
|
| 43 |
+
|
| 44 |
+
[More Information Needed]
|
| 45 |
+
|
| 46 |
+
### Downstream Use [optional]
|
| 47 |
+
|
| 48 |
+
<!-- This section is for the model use when fine-tuned for a task, or when plugged into a larger ecosystem/app -->
|
| 49 |
+
|
| 50 |
+
[More Information Needed]
|
| 51 |
+
|
| 52 |
+
### Out-of-Scope Use
|
| 53 |
+
|
| 54 |
+
<!-- This section addresses misuse, malicious use, and uses that the model will not work well for. -->
|
| 55 |
+
|
| 56 |
+
[More Information Needed]
|
| 57 |
+
|
| 58 |
+
## Bias, Risks, and Limitations
|
| 59 |
+
|
| 60 |
+
<!-- This section is meant to convey both technical and sociotechnical limitations. -->
|
| 61 |
+
|
| 62 |
+
[More Information Needed]
|
| 63 |
+
|
| 64 |
+
### Recommendations
|
| 65 |
+
|
| 66 |
+
<!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. -->
|
| 67 |
+
|
| 68 |
+
Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
|
| 69 |
+
|
| 70 |
+
## How to Get Started with the Model
|
| 71 |
+
|
| 72 |
+
Use the code below to get started with the model.
|
| 73 |
+
|
| 74 |
+
[More Information Needed]
|
| 75 |
+
|
| 76 |
+
## Training Details
|
| 77 |
+
|
| 78 |
+
### Training Data
|
| 79 |
+
|
| 80 |
+
<!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
|
| 81 |
+
|
| 82 |
+
[More Information Needed]
|
| 83 |
+
|
| 84 |
+
### Training Procedure
|
| 85 |
+
|
| 86 |
+
<!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
|
| 87 |
+
|
| 88 |
+
#### Preprocessing [optional]
|
| 89 |
+
|
| 90 |
+
[More Information Needed]
|
| 91 |
+
|
| 92 |
+
|
| 93 |
+
#### Training Hyperparameters
|
| 94 |
+
|
| 95 |
+
- **Training regime:** [More Information Needed] <!--fp32, fp16 mixed precision, bf16 mixed precision, bf16 non-mixed precision, fp16 non-mixed precision, fp8 mixed precision -->
|
| 96 |
+
|
| 97 |
+
#### Speeds, Sizes, Times [optional]
|
| 98 |
+
|
| 99 |
+
<!-- This section provides information about throughput, start/end time, checkpoint size if relevant, etc. -->
|
| 100 |
+
|
| 101 |
+
[More Information Needed]
|
| 102 |
+
|
| 103 |
+
## Evaluation
|
| 104 |
+
|
| 105 |
+
<!-- This section describes the evaluation protocols and provides the results. -->
|
| 106 |
+
|
| 107 |
+
### Testing Data, Factors & Metrics
|
| 108 |
+
|
| 109 |
+
#### Testing Data
|
| 110 |
+
|
| 111 |
+
<!-- This should link to a Dataset Card if possible. -->
|
| 112 |
+
|
| 113 |
+
[More Information Needed]
|
| 114 |
+
|
| 115 |
+
#### Factors
|
| 116 |
+
|
| 117 |
+
<!-- These are the things the evaluation is disaggregating by, e.g., subpopulations or domains. -->
|
| 118 |
+
|
| 119 |
+
[More Information Needed]
|
| 120 |
+
|
| 121 |
+
#### Metrics
|
| 122 |
+
|
| 123 |
+
<!-- These are the evaluation metrics being used, ideally with a description of why. -->
|
| 124 |
+
|
| 125 |
+
[More Information Needed]
|
| 126 |
+
|
| 127 |
+
### Results
|
| 128 |
+
|
| 129 |
+
[More Information Needed]
|
| 130 |
+
|
| 131 |
+
#### Summary
|
| 132 |
+
|
| 133 |
+
|
| 134 |
+
|
| 135 |
+
## Model Examination [optional]
|
| 136 |
+
|
| 137 |
+
<!-- Relevant interpretability work for the model goes here -->
|
| 138 |
+
|
| 139 |
+
[More Information Needed]
|
| 140 |
+
|
| 141 |
+
## Environmental Impact
|
| 142 |
+
|
| 143 |
+
<!-- Total emissions (in grams of CO2eq) and additional considerations, such as electricity usage, go here. Edit the suggested text below accordingly -->
|
| 144 |
+
|
| 145 |
+
Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700).
|
| 146 |
+
|
| 147 |
+
- **Hardware Type:** [More Information Needed]
|
| 148 |
+
- **Hours used:** [More Information Needed]
|
| 149 |
+
- **Cloud Provider:** [More Information Needed]
|
| 150 |
+
- **Compute Region:** [More Information Needed]
|
| 151 |
+
- **Carbon Emitted:** [More Information Needed]
|
| 152 |
+
|
| 153 |
+
## Technical Specifications [optional]
|
| 154 |
+
|
| 155 |
+
### Model Architecture and Objective
|
| 156 |
+
|
| 157 |
+
[More Information Needed]
|
| 158 |
+
|
| 159 |
+
### Compute Infrastructure
|
| 160 |
+
|
| 161 |
+
[More Information Needed]
|
| 162 |
+
|
| 163 |
+
#### Hardware
|
| 164 |
+
|
| 165 |
+
[More Information Needed]
|
| 166 |
+
|
| 167 |
+
#### Software
|
| 168 |
+
|
| 169 |
+
[More Information Needed]
|
| 170 |
+
|
| 171 |
+
## Citation [optional]
|
| 172 |
+
|
| 173 |
+
<!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. -->
|
| 174 |
+
|
| 175 |
+
**BibTeX:**
|
| 176 |
+
|
| 177 |
+
[More Information Needed]
|
| 178 |
+
|
| 179 |
+
**APA:**
|
| 180 |
+
|
| 181 |
+
[More Information Needed]
|
| 182 |
+
|
| 183 |
+
## Glossary [optional]
|
| 184 |
+
|
| 185 |
+
<!-- If relevant, include terms and calculations in this section that can help readers understand the model or model card. -->
|
| 186 |
+
|
| 187 |
+
[More Information Needed]
|
| 188 |
+
|
| 189 |
+
## More Information [optional]
|
| 190 |
+
|
| 191 |
+
[More Information Needed]
|
| 192 |
+
|
| 193 |
+
## Model Card Authors [optional]
|
| 194 |
+
|
| 195 |
+
[More Information Needed]
|
| 196 |
+
|
| 197 |
+
## Model Card Contact
|
| 198 |
+
|
| 199 |
+
[More Information Needed]
|
| 200 |
+
### Framework versions
|
| 201 |
+
|
| 202 |
+
- PEFT 0.14.0
|
checkpoint-1500/adapter_config.json
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"alpha_pattern": {},
|
| 3 |
+
"auto_mapping": null,
|
| 4 |
+
"base_model_name_or_path": "Qwen/Qwen2.5-7B",
|
| 5 |
+
"bias": "none",
|
| 6 |
+
"eva_config": null,
|
| 7 |
+
"exclude_modules": null,
|
| 8 |
+
"fan_in_fan_out": false,
|
| 9 |
+
"inference_mode": true,
|
| 10 |
+
"init_lora_weights": true,
|
| 11 |
+
"layer_replication": null,
|
| 12 |
+
"layers_pattern": null,
|
| 13 |
+
"layers_to_transform": null,
|
| 14 |
+
"loftq_config": {},
|
| 15 |
+
"lora_alpha": 32,
|
| 16 |
+
"lora_bias": false,
|
| 17 |
+
"lora_dropout": 0.0,
|
| 18 |
+
"megatron_config": null,
|
| 19 |
+
"megatron_core": "megatron.core",
|
| 20 |
+
"modules_to_save": null,
|
| 21 |
+
"peft_type": "LORA",
|
| 22 |
+
"r": 16,
|
| 23 |
+
"rank_pattern": {},
|
| 24 |
+
"revision": null,
|
| 25 |
+
"target_modules": [
|
| 26 |
+
"k_proj",
|
| 27 |
+
"v_proj",
|
| 28 |
+
"q_proj",
|
| 29 |
+
"up_proj",
|
| 30 |
+
"gate_proj",
|
| 31 |
+
"down_proj",
|
| 32 |
+
"o_proj"
|
| 33 |
+
],
|
| 34 |
+
"task_type": "CAUSAL_LM",
|
| 35 |
+
"use_dora": false,
|
| 36 |
+
"use_rslora": false
|
| 37 |
+
}
|
checkpoint-1500/adapter_model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b1f1ce8c9922c384cf7af3046be04f4ed75efbc3066b8e3ee012e28782155f77
|
| 3 |
+
size 80792880
|
checkpoint-1500/added_tokens.json
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"</tool_call>": 151658,
|
| 3 |
+
"<tool_call>": 151657,
|
| 4 |
+
"<|box_end|>": 151649,
|
| 5 |
+
"<|box_start|>": 151648,
|
| 6 |
+
"<|endoftext|>": 151643,
|
| 7 |
+
"<|file_sep|>": 151664,
|
| 8 |
+
"<|fim_middle|>": 151660,
|
| 9 |
+
"<|fim_pad|>": 151662,
|
| 10 |
+
"<|fim_prefix|>": 151659,
|
| 11 |
+
"<|fim_suffix|>": 151661,
|
| 12 |
+
"<|im_end|>": 151645,
|
| 13 |
+
"<|im_start|>": 151644,
|
| 14 |
+
"<|image_pad|>": 151655,
|
| 15 |
+
"<|object_ref_end|>": 151647,
|
| 16 |
+
"<|object_ref_start|>": 151646,
|
| 17 |
+
"<|quad_end|>": 151651,
|
| 18 |
+
"<|quad_start|>": 151650,
|
| 19 |
+
"<|repo_name|>": 151663,
|
| 20 |
+
"<|video_pad|>": 151656,
|
| 21 |
+
"<|vision_end|>": 151653,
|
| 22 |
+
"<|vision_pad|>": 151654,
|
| 23 |
+
"<|vision_start|>": 151652
|
| 24 |
+
}
|
checkpoint-1500/latest
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
global_step1501
|
checkpoint-1500/merges.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
checkpoint-1500/rng_state_0.pth
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:34bcae41c589c7e4cab7b2ef263b878c90c2741404a6af11994dc31537b2319b
|
| 3 |
+
size 14512
|
checkpoint-1500/rng_state_1.pth
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:d05dc84075e8f7dd1191c36f3be9dda12073208e12f7d2cef433c38d6336774a
|
| 3 |
+
size 14512
|
checkpoint-1500/special_tokens_map.json
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"additional_special_tokens": [
|
| 3 |
+
"<|im_start|>",
|
| 4 |
+
"<|im_end|>",
|
| 5 |
+
"<|object_ref_start|>",
|
| 6 |
+
"<|object_ref_end|>",
|
| 7 |
+
"<|box_start|>",
|
| 8 |
+
"<|box_end|>",
|
| 9 |
+
"<|quad_start|>",
|
| 10 |
+
"<|quad_end|>",
|
| 11 |
+
"<|vision_start|>",
|
| 12 |
+
"<|vision_end|>",
|
| 13 |
+
"<|vision_pad|>",
|
| 14 |
+
"<|image_pad|>",
|
| 15 |
+
"<|video_pad|>"
|
| 16 |
+
],
|
| 17 |
+
"eos_token": {
|
| 18 |
+
"content": "<|endoftext|>",
|
| 19 |
+
"lstrip": false,
|
| 20 |
+
"normalized": false,
|
| 21 |
+
"rstrip": false,
|
| 22 |
+
"single_word": false
|
| 23 |
+
},
|
| 24 |
+
"pad_token": {
|
| 25 |
+
"content": "<|endoftext|>",
|
| 26 |
+
"lstrip": false,
|
| 27 |
+
"normalized": false,
|
| 28 |
+
"rstrip": false,
|
| 29 |
+
"single_word": false
|
| 30 |
+
}
|
| 31 |
+
}
|
checkpoint-1500/tokenizer.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9c5ae00e602b8860cbd784ba82a8aa14e8feecec692e7076590d014d7b7fdafa
|
| 3 |
+
size 11421896
|
checkpoint-1500/tokenizer_config.json
ADDED
|
@@ -0,0 +1,208 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"add_bos_token": false,
|
| 3 |
+
"add_prefix_space": false,
|
| 4 |
+
"added_tokens_decoder": {
|
| 5 |
+
"151643": {
|
| 6 |
+
"content": "<|endoftext|>",
|
| 7 |
+
"lstrip": false,
|
| 8 |
+
"normalized": false,
|
| 9 |
+
"rstrip": false,
|
| 10 |
+
"single_word": false,
|
| 11 |
+
"special": true
|
| 12 |
+
},
|
| 13 |
+
"151644": {
|
| 14 |
+
"content": "<|im_start|>",
|
| 15 |
+
"lstrip": false,
|
| 16 |
+
"normalized": false,
|
| 17 |
+
"rstrip": false,
|
| 18 |
+
"single_word": false,
|
| 19 |
+
"special": true
|
| 20 |
+
},
|
| 21 |
+
"151645": {
|
| 22 |
+
"content": "<|im_end|>",
|
| 23 |
+
"lstrip": false,
|
| 24 |
+
"normalized": false,
|
| 25 |
+
"rstrip": false,
|
| 26 |
+
"single_word": false,
|
| 27 |
+
"special": true
|
| 28 |
+
},
|
| 29 |
+
"151646": {
|
| 30 |
+
"content": "<|object_ref_start|>",
|
| 31 |
+
"lstrip": false,
|
| 32 |
+
"normalized": false,
|
| 33 |
+
"rstrip": false,
|
| 34 |
+
"single_word": false,
|
| 35 |
+
"special": true
|
| 36 |
+
},
|
| 37 |
+
"151647": {
|
| 38 |
+
"content": "<|object_ref_end|>",
|
| 39 |
+
"lstrip": false,
|
| 40 |
+
"normalized": false,
|
| 41 |
+
"rstrip": false,
|
| 42 |
+
"single_word": false,
|
| 43 |
+
"special": true
|
| 44 |
+
},
|
| 45 |
+
"151648": {
|
| 46 |
+
"content": "<|box_start|>",
|
| 47 |
+
"lstrip": false,
|
| 48 |
+
"normalized": false,
|
| 49 |
+
"rstrip": false,
|
| 50 |
+
"single_word": false,
|
| 51 |
+
"special": true
|
| 52 |
+
},
|
| 53 |
+
"151649": {
|
| 54 |
+
"content": "<|box_end|>",
|
| 55 |
+
"lstrip": false,
|
| 56 |
+
"normalized": false,
|
| 57 |
+
"rstrip": false,
|
| 58 |
+
"single_word": false,
|
| 59 |
+
"special": true
|
| 60 |
+
},
|
| 61 |
+
"151650": {
|
| 62 |
+
"content": "<|quad_start|>",
|
| 63 |
+
"lstrip": false,
|
| 64 |
+
"normalized": false,
|
| 65 |
+
"rstrip": false,
|
| 66 |
+
"single_word": false,
|
| 67 |
+
"special": true
|
| 68 |
+
},
|
| 69 |
+
"151651": {
|
| 70 |
+
"content": "<|quad_end|>",
|
| 71 |
+
"lstrip": false,
|
| 72 |
+
"normalized": false,
|
| 73 |
+
"rstrip": false,
|
| 74 |
+
"single_word": false,
|
| 75 |
+
"special": true
|
| 76 |
+
},
|
| 77 |
+
"151652": {
|
| 78 |
+
"content": "<|vision_start|>",
|
| 79 |
+
"lstrip": false,
|
| 80 |
+
"normalized": false,
|
| 81 |
+
"rstrip": false,
|
| 82 |
+
"single_word": false,
|
| 83 |
+
"special": true
|
| 84 |
+
},
|
| 85 |
+
"151653": {
|
| 86 |
+
"content": "<|vision_end|>",
|
| 87 |
+
"lstrip": false,
|
| 88 |
+
"normalized": false,
|
| 89 |
+
"rstrip": false,
|
| 90 |
+
"single_word": false,
|
| 91 |
+
"special": true
|
| 92 |
+
},
|
| 93 |
+
"151654": {
|
| 94 |
+
"content": "<|vision_pad|>",
|
| 95 |
+
"lstrip": false,
|
| 96 |
+
"normalized": false,
|
| 97 |
+
"rstrip": false,
|
| 98 |
+
"single_word": false,
|
| 99 |
+
"special": true
|
| 100 |
+
},
|
| 101 |
+
"151655": {
|
| 102 |
+
"content": "<|image_pad|>",
|
| 103 |
+
"lstrip": false,
|
| 104 |
+
"normalized": false,
|
| 105 |
+
"rstrip": false,
|
| 106 |
+
"single_word": false,
|
| 107 |
+
"special": true
|
| 108 |
+
},
|
| 109 |
+
"151656": {
|
| 110 |
+
"content": "<|video_pad|>",
|
| 111 |
+
"lstrip": false,
|
| 112 |
+
"normalized": false,
|
| 113 |
+
"rstrip": false,
|
| 114 |
+
"single_word": false,
|
| 115 |
+
"special": true
|
| 116 |
+
},
|
| 117 |
+
"151657": {
|
| 118 |
+
"content": "<tool_call>",
|
| 119 |
+
"lstrip": false,
|
| 120 |
+
"normalized": false,
|
| 121 |
+
"rstrip": false,
|
| 122 |
+
"single_word": false,
|
| 123 |
+
"special": false
|
| 124 |
+
},
|
| 125 |
+
"151658": {
|
| 126 |
+
"content": "</tool_call>",
|
| 127 |
+
"lstrip": false,
|
| 128 |
+
"normalized": false,
|
| 129 |
+
"rstrip": false,
|
| 130 |
+
"single_word": false,
|
| 131 |
+
"special": false
|
| 132 |
+
},
|
| 133 |
+
"151659": {
|
| 134 |
+
"content": "<|fim_prefix|>",
|
| 135 |
+
"lstrip": false,
|
| 136 |
+
"normalized": false,
|
| 137 |
+
"rstrip": false,
|
| 138 |
+
"single_word": false,
|
| 139 |
+
"special": false
|
| 140 |
+
},
|
| 141 |
+
"151660": {
|
| 142 |
+
"content": "<|fim_middle|>",
|
| 143 |
+
"lstrip": false,
|
| 144 |
+
"normalized": false,
|
| 145 |
+
"rstrip": false,
|
| 146 |
+
"single_word": false,
|
| 147 |
+
"special": false
|
| 148 |
+
},
|
| 149 |
+
"151661": {
|
| 150 |
+
"content": "<|fim_suffix|>",
|
| 151 |
+
"lstrip": false,
|
| 152 |
+
"normalized": false,
|
| 153 |
+
"rstrip": false,
|
| 154 |
+
"single_word": false,
|
| 155 |
+
"special": false
|
| 156 |
+
},
|
| 157 |
+
"151662": {
|
| 158 |
+
"content": "<|fim_pad|>",
|
| 159 |
+
"lstrip": false,
|
| 160 |
+
"normalized": false,
|
| 161 |
+
"rstrip": false,
|
| 162 |
+
"single_word": false,
|
| 163 |
+
"special": false
|
| 164 |
+
},
|
| 165 |
+
"151663": {
|
| 166 |
+
"content": "<|repo_name|>",
|
| 167 |
+
"lstrip": false,
|
| 168 |
+
"normalized": false,
|
| 169 |
+
"rstrip": false,
|
| 170 |
+
"single_word": false,
|
| 171 |
+
"special": false
|
| 172 |
+
},
|
| 173 |
+
"151664": {
|
| 174 |
+
"content": "<|file_sep|>",
|
| 175 |
+
"lstrip": false,
|
| 176 |
+
"normalized": false,
|
| 177 |
+
"rstrip": false,
|
| 178 |
+
"single_word": false,
|
| 179 |
+
"special": false
|
| 180 |
+
}
|
| 181 |
+
},
|
| 182 |
+
"additional_special_tokens": [
|
| 183 |
+
"<|im_start|>",
|
| 184 |
+
"<|im_end|>",
|
| 185 |
+
"<|object_ref_start|>",
|
| 186 |
+
"<|object_ref_end|>",
|
| 187 |
+
"<|box_start|>",
|
| 188 |
+
"<|box_end|>",
|
| 189 |
+
"<|quad_start|>",
|
| 190 |
+
"<|quad_end|>",
|
| 191 |
+
"<|vision_start|>",
|
| 192 |
+
"<|vision_end|>",
|
| 193 |
+
"<|vision_pad|>",
|
| 194 |
+
"<|image_pad|>",
|
| 195 |
+
"<|video_pad|>"
|
| 196 |
+
],
|
| 197 |
+
"bos_token": null,
|
| 198 |
+
"chat_template": "{%- if tools %}\n {{- '<|im_start|>system\\n' }}\n {%- if messages[0]['role'] == 'system' %}\n {{- messages[0]['content'] }}\n {%- else %}\n {{- 'You are a helpful assistant.' }}\n {%- endif %}\n {{- \"\\n\\n# Tools\\n\\nYou may call one or more functions to assist with the user query.\\n\\nYou are provided with function signatures within <tools></tools> XML tags:\\n<tools>\" }}\n {%- for tool in tools %}\n {{- \"\\n\" }}\n {{- tool | tojson }}\n {%- endfor %}\n {{- \"\\n</tools>\\n\\nFor each function call, return a json object with function name and arguments within <tool_call></tool_call> XML tags:\\n<tool_call>\\n{\\\"name\\\": <function-name>, \\\"arguments\\\": <args-json-object>}\\n</tool_call><|im_end|>\\n\" }}\n{%- else %}\n {%- if messages[0]['role'] == 'system' %}\n {{- '<|im_start|>system\\n' + messages[0]['content'] + '<|im_end|>\\n' }}\n {%- else %}\n {{- '<|im_start|>system\\nYou are a helpful assistant.<|im_end|>\\n' }}\n {%- endif %}\n{%- endif %}\n{%- for message in messages %}\n {%- if (message.role == \"user\") or (message.role == \"system\" and not loop.first) or (message.role == \"assistant\" and not message.tool_calls) %}\n {{- '<|im_start|>' + message.role + '\\n' + message.content + '<|im_end|>' + '\\n' }}\n {%- elif message.role == \"assistant\" %}\n {{- '<|im_start|>' + message.role }}\n {%- if message.content %}\n {{- '\\n' + message.content }}\n {%- endif %}\n {%- for tool_call in message.tool_calls %}\n {%- if tool_call.function is defined %}\n {%- set tool_call = tool_call.function %}\n {%- endif %}\n {{- '\\n<tool_call>\\n{\"name\": \"' }}\n {{- tool_call.name }}\n {{- '\", \"arguments\": ' }}\n {{- tool_call.arguments | tojson }}\n {{- '}\\n</tool_call>' }}\n {%- endfor %}\n {{- '<|im_end|>\\n' }}\n {%- elif message.role == \"tool\" %}\n {%- if (loop.index0 == 0) or (messages[loop.index0 - 1].role != \"tool\") %}\n {{- '<|im_start|>user' }}\n {%- endif %}\n {{- '\\n<tool_response>\\n' }}\n {{- message.content }}\n {{- '\\n</tool_response>' }}\n {%- if loop.last or (messages[loop.index0 + 1].role != \"tool\") %}\n {{- '<|im_end|>\\n' }}\n {%- endif %}\n {%- endif %}\n{%- endfor %}\n{%- if add_generation_prompt %}\n {{- '<|im_start|>assistant\\n' }}\n{%- endif %}\n",
|
| 199 |
+
"clean_up_tokenization_spaces": false,
|
| 200 |
+
"eos_token": "<|endoftext|>",
|
| 201 |
+
"errors": "replace",
|
| 202 |
+
"extra_special_tokens": {},
|
| 203 |
+
"model_max_length": 131072,
|
| 204 |
+
"pad_token": "<|endoftext|>",
|
| 205 |
+
"split_special_tokens": false,
|
| 206 |
+
"tokenizer_class": "Qwen2Tokenizer",
|
| 207 |
+
"unk_token": null
|
| 208 |
+
}
|
checkpoint-1500/trainer_state.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
checkpoint-1500/training_args.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:754e4ae9d879853457ade197edaf9a4e09b3e2d2a23d8bffcf3f56a687083eb3
|
| 3 |
+
size 6904
|
checkpoint-1500/vocab.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
checkpoint-1500/zero_to_fp32.py
ADDED
|
@@ -0,0 +1,674 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python
|
| 2 |
+
|
| 3 |
+
# Copyright (c) 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:
|
| 14 |
+
# python zero_to_fp32.py . output_dir/
|
| 15 |
+
# or
|
| 16 |
+
# python zero_to_fp32.py . output_dir/ --safe_serialization
|
| 17 |
+
|
| 18 |
+
import argparse
|
| 19 |
+
import torch
|
| 20 |
+
import glob
|
| 21 |
+
import math
|
| 22 |
+
import os
|
| 23 |
+
import re
|
| 24 |
+
import json
|
| 25 |
+
from tqdm import tqdm
|
| 26 |
+
from collections import OrderedDict
|
| 27 |
+
from dataclasses import dataclass
|
| 28 |
+
|
| 29 |
+
# while this script doesn't use deepspeed to recover data, since the checkpoints are pickled with
|
| 30 |
+
# DeepSpeed data structures it has to be available in the current python environment.
|
| 31 |
+
from deepspeed.utils import logger
|
| 32 |
+
from deepspeed.checkpoint.constants import (DS_VERSION, OPTIMIZER_STATE_DICT, SINGLE_PARTITION_OF_FP32_GROUPS,
|
| 33 |
+
FP32_FLAT_GROUPS, ZERO_STAGE, PARTITION_COUNT, PARAM_SHAPES, BUFFER_NAMES,
|
| 34 |
+
FROZEN_PARAM_SHAPES, FROZEN_PARAM_FRAGMENTS)
|
| 35 |
+
|
| 36 |
+
|
| 37 |
+
@dataclass
|
| 38 |
+
class zero_model_state:
|
| 39 |
+
buffers: dict()
|
| 40 |
+
param_shapes: dict()
|
| 41 |
+
shared_params: list
|
| 42 |
+
ds_version: int
|
| 43 |
+
frozen_param_shapes: dict()
|
| 44 |
+
frozen_param_fragments: dict()
|
| 45 |
+
|
| 46 |
+
|
| 47 |
+
debug = 0
|
| 48 |
+
|
| 49 |
+
# load to cpu
|
| 50 |
+
device = torch.device('cpu')
|
| 51 |
+
|
| 52 |
+
|
| 53 |
+
def atoi(text):
|
| 54 |
+
return int(text) if text.isdigit() else text
|
| 55 |
+
|
| 56 |
+
|
| 57 |
+
def natural_keys(text):
|
| 58 |
+
'''
|
| 59 |
+
alist.sort(key=natural_keys) sorts in human order
|
| 60 |
+
http://nedbatchelder.com/blog/200712/human_sorting.html
|
| 61 |
+
(See Toothy's implementation in the comments)
|
| 62 |
+
'''
|
| 63 |
+
return [atoi(c) for c in re.split(r'(\d+)', text)]
|
| 64 |
+
|
| 65 |
+
|
| 66 |
+
def get_model_state_file(checkpoint_dir, zero_stage):
|
| 67 |
+
if not os.path.isdir(checkpoint_dir):
|
| 68 |
+
raise FileNotFoundError(f"Directory '{checkpoint_dir}' doesn't exist")
|
| 69 |
+
|
| 70 |
+
# there should be only one file
|
| 71 |
+
if zero_stage <= 2:
|
| 72 |
+
file = os.path.join(checkpoint_dir, "mp_rank_00_model_states.pt")
|
| 73 |
+
elif zero_stage == 3:
|
| 74 |
+
file = os.path.join(checkpoint_dir, "zero_pp_rank_0_mp_rank_00_model_states.pt")
|
| 75 |
+
|
| 76 |
+
if not os.path.exists(file):
|
| 77 |
+
raise FileNotFoundError(f"can't find model states file at '{file}'")
|
| 78 |
+
|
| 79 |
+
return file
|
| 80 |
+
|
| 81 |
+
|
| 82 |
+
def get_checkpoint_files(checkpoint_dir, glob_pattern):
|
| 83 |
+
# XXX: need to test that this simple glob rule works for multi-node setup too
|
| 84 |
+
ckpt_files = sorted(glob.glob(os.path.join(checkpoint_dir, glob_pattern)), key=natural_keys)
|
| 85 |
+
|
| 86 |
+
if len(ckpt_files) == 0:
|
| 87 |
+
raise FileNotFoundError(f"can't find {glob_pattern} files in directory '{checkpoint_dir}'")
|
| 88 |
+
|
| 89 |
+
return ckpt_files
|
| 90 |
+
|
| 91 |
+
|
| 92 |
+
def get_optim_files(checkpoint_dir):
|
| 93 |
+
return get_checkpoint_files(checkpoint_dir, "*_optim_states.pt")
|
| 94 |
+
|
| 95 |
+
|
| 96 |
+
def get_model_state_files(checkpoint_dir):
|
| 97 |
+
return get_checkpoint_files(checkpoint_dir, "*_model_states.pt")
|
| 98 |
+
|
| 99 |
+
|
| 100 |
+
def parse_model_states(files):
|
| 101 |
+
zero_model_states = []
|
| 102 |
+
for file in files:
|
| 103 |
+
state_dict = torch.load(file, map_location=device)
|
| 104 |
+
|
| 105 |
+
if BUFFER_NAMES not in state_dict:
|
| 106 |
+
raise ValueError(f"{file} is not a model state checkpoint")
|
| 107 |
+
buffer_names = state_dict[BUFFER_NAMES]
|
| 108 |
+
if debug:
|
| 109 |
+
print("Found buffers:", buffer_names)
|
| 110 |
+
|
| 111 |
+
# recover just the buffers while restoring them to fp32 if they were saved in fp16
|
| 112 |
+
buffers = {k: v.float() for k, v in state_dict["module"].items() if k in buffer_names}
|
| 113 |
+
param_shapes = state_dict[PARAM_SHAPES]
|
| 114 |
+
|
| 115 |
+
# collect parameters that are included in param_shapes
|
| 116 |
+
param_names = []
|
| 117 |
+
for s in param_shapes:
|
| 118 |
+
for name in s.keys():
|
| 119 |
+
param_names.append(name)
|
| 120 |
+
|
| 121 |
+
# update with frozen parameters
|
| 122 |
+
frozen_param_shapes = state_dict.get(FROZEN_PARAM_SHAPES, None)
|
| 123 |
+
if frozen_param_shapes is not None:
|
| 124 |
+
if debug:
|
| 125 |
+
print(f"Found frozen_param_shapes: {frozen_param_shapes}")
|
| 126 |
+
param_names += list(frozen_param_shapes.keys())
|
| 127 |
+
|
| 128 |
+
# handle shared params
|
| 129 |
+
shared_params = [[k, v] for k, v in state_dict["shared_params"].items()]
|
| 130 |
+
|
| 131 |
+
ds_version = state_dict.get(DS_VERSION, None)
|
| 132 |
+
|
| 133 |
+
frozen_param_fragments = state_dict.get(FROZEN_PARAM_FRAGMENTS, None)
|
| 134 |
+
|
| 135 |
+
z_model_state = zero_model_state(buffers=buffers,
|
| 136 |
+
param_shapes=param_shapes,
|
| 137 |
+
shared_params=shared_params,
|
| 138 |
+
ds_version=ds_version,
|
| 139 |
+
frozen_param_shapes=frozen_param_shapes,
|
| 140 |
+
frozen_param_fragments=frozen_param_fragments)
|
| 141 |
+
zero_model_states.append(z_model_state)
|
| 142 |
+
|
| 143 |
+
return zero_model_states
|
| 144 |
+
|
| 145 |
+
|
| 146 |
+
def parse_optim_states(files, ds_checkpoint_dir):
|
| 147 |
+
total_files = len(files)
|
| 148 |
+
state_dicts = []
|
| 149 |
+
for f in files:
|
| 150 |
+
state_dict = torch.load(f, map_location=device)
|
| 151 |
+
# immediately discard the potentially huge 2 optimizer states as we only care for fp32 master weights
|
| 152 |
+
# and also handle the case where it was already removed by another helper script
|
| 153 |
+
state_dict["optimizer_state_dict"].pop("optimizer_state_dict", None)
|
| 154 |
+
state_dicts.append(state_dict)
|
| 155 |
+
|
| 156 |
+
if not ZERO_STAGE in state_dicts[0][OPTIMIZER_STATE_DICT]:
|
| 157 |
+
raise ValueError(f"{files[0]} is not a zero checkpoint")
|
| 158 |
+
zero_stage = state_dicts[0][OPTIMIZER_STATE_DICT][ZERO_STAGE]
|
| 159 |
+
world_size = state_dicts[0][OPTIMIZER_STATE_DICT][PARTITION_COUNT]
|
| 160 |
+
|
| 161 |
+
# For ZeRO-2 each param group can have different partition_count as data parallelism for expert
|
| 162 |
+
# parameters can be different from data parallelism for non-expert parameters. So we can just
|
| 163 |
+
# use the max of the partition_count to get the dp world_size.
|
| 164 |
+
|
| 165 |
+
if type(world_size) is list:
|
| 166 |
+
world_size = max(world_size)
|
| 167 |
+
|
| 168 |
+
if world_size != total_files:
|
| 169 |
+
raise ValueError(
|
| 170 |
+
f"Expected {world_size} of '*_optim_states.pt' under '{ds_checkpoint_dir}' but found {total_files} files. "
|
| 171 |
+
"Possibly due to an overwrite of an old checkpoint, or a checkpoint didn't get saved by one or more processes."
|
| 172 |
+
)
|
| 173 |
+
|
| 174 |
+
# the groups are named differently in each stage
|
| 175 |
+
if zero_stage <= 2:
|
| 176 |
+
fp32_groups_key = SINGLE_PARTITION_OF_FP32_GROUPS
|
| 177 |
+
elif zero_stage == 3:
|
| 178 |
+
fp32_groups_key = FP32_FLAT_GROUPS
|
| 179 |
+
else:
|
| 180 |
+
raise ValueError(f"unknown zero stage {zero_stage}")
|
| 181 |
+
|
| 182 |
+
if zero_stage <= 2:
|
| 183 |
+
fp32_flat_groups = [state_dicts[i][OPTIMIZER_STATE_DICT][fp32_groups_key] for i in range(len(state_dicts))]
|
| 184 |
+
elif zero_stage == 3:
|
| 185 |
+
# if there is more than one param group, there will be multiple flattened tensors - one
|
| 186 |
+
# flattened tensor per group - for simplicity merge them into a single tensor
|
| 187 |
+
#
|
| 188 |
+
# XXX: could make the script more memory efficient for when there are multiple groups - it
|
| 189 |
+
# will require matching the sub-lists of param_shapes for each param group flattened tensor
|
| 190 |
+
|
| 191 |
+
fp32_flat_groups = [
|
| 192 |
+
torch.cat(state_dicts[i][OPTIMIZER_STATE_DICT][fp32_groups_key], 0) for i in range(len(state_dicts))
|
| 193 |
+
]
|
| 194 |
+
|
| 195 |
+
return zero_stage, world_size, fp32_flat_groups
|
| 196 |
+
|
| 197 |
+
|
| 198 |
+
def _get_fp32_state_dict_from_zero_checkpoint(ds_checkpoint_dir, exclude_frozen_parameters):
|
| 199 |
+
"""
|
| 200 |
+
Returns fp32 state_dict reconstructed from ds checkpoint
|
| 201 |
+
|
| 202 |
+
Args:
|
| 203 |
+
- ``ds_checkpoint_dir``: path to the deepspeed checkpoint folder (where the optimizer files are)
|
| 204 |
+
|
| 205 |
+
"""
|
| 206 |
+
print(f"Processing zero checkpoint '{ds_checkpoint_dir}'")
|
| 207 |
+
|
| 208 |
+
optim_files = get_optim_files(ds_checkpoint_dir)
|
| 209 |
+
zero_stage, world_size, fp32_flat_groups = parse_optim_states(optim_files, ds_checkpoint_dir)
|
| 210 |
+
print(f"Detected checkpoint of type zero stage {zero_stage}, world_size: {world_size}")
|
| 211 |
+
|
| 212 |
+
model_files = get_model_state_files(ds_checkpoint_dir)
|
| 213 |
+
|
| 214 |
+
zero_model_states = parse_model_states(model_files)
|
| 215 |
+
print(f'Parsing checkpoint created by deepspeed=={zero_model_states[0].ds_version}')
|
| 216 |
+
|
| 217 |
+
if zero_stage <= 2:
|
| 218 |
+
return _get_fp32_state_dict_from_zero2_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 219 |
+
exclude_frozen_parameters)
|
| 220 |
+
elif zero_stage == 3:
|
| 221 |
+
return _get_fp32_state_dict_from_zero3_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 222 |
+
exclude_frozen_parameters)
|
| 223 |
+
|
| 224 |
+
|
| 225 |
+
def _zero2_merge_frozen_params(state_dict, zero_model_states):
|
| 226 |
+
if zero_model_states[0].frozen_param_shapes is None or len(zero_model_states[0].frozen_param_shapes) == 0:
|
| 227 |
+
return
|
| 228 |
+
|
| 229 |
+
frozen_param_shapes = zero_model_states[0].frozen_param_shapes
|
| 230 |
+
frozen_param_fragments = zero_model_states[0].frozen_param_fragments
|
| 231 |
+
|
| 232 |
+
if debug:
|
| 233 |
+
num_elem = sum(s.numel() for s in frozen_param_shapes.values())
|
| 234 |
+
print(f'rank 0: {FROZEN_PARAM_SHAPES}.numel = {num_elem}')
|
| 235 |
+
|
| 236 |
+
wanted_params = len(frozen_param_shapes)
|
| 237 |
+
wanted_numel = sum(s.numel() for s in frozen_param_shapes.values())
|
| 238 |
+
avail_numel = sum([p.numel() for p in frozen_param_fragments.values()])
|
| 239 |
+
print(f'Frozen params: Have {avail_numel} numels to process.')
|
| 240 |
+
print(f'Frozen params: Need {wanted_numel} numels in {wanted_params} params')
|
| 241 |
+
|
| 242 |
+
total_params = 0
|
| 243 |
+
total_numel = 0
|
| 244 |
+
for name, shape in frozen_param_shapes.items():
|
| 245 |
+
total_params += 1
|
| 246 |
+
unpartitioned_numel = shape.numel()
|
| 247 |
+
total_numel += unpartitioned_numel
|
| 248 |
+
|
| 249 |
+
state_dict[name] = frozen_param_fragments[name]
|
| 250 |
+
|
| 251 |
+
if debug:
|
| 252 |
+
print(f"{name} full shape: {shape} unpartitioned numel {unpartitioned_numel} ")
|
| 253 |
+
|
| 254 |
+
print(f"Reconstructed Frozen fp32 state dict with {total_params} params {total_numel} elements")
|
| 255 |
+
|
| 256 |
+
|
| 257 |
+
def _has_callable(obj, fn):
|
| 258 |
+
attr = getattr(obj, fn, None)
|
| 259 |
+
return callable(attr)
|
| 260 |
+
|
| 261 |
+
|
| 262 |
+
def _zero2_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states):
|
| 263 |
+
param_shapes = zero_model_states[0].param_shapes
|
| 264 |
+
|
| 265 |
+
# Reconstruction protocol:
|
| 266 |
+
#
|
| 267 |
+
# XXX: document this
|
| 268 |
+
|
| 269 |
+
if debug:
|
| 270 |
+
for i in range(world_size):
|
| 271 |
+
for j in range(len(fp32_flat_groups[0])):
|
| 272 |
+
print(f"{FP32_FLAT_GROUPS}[{i}][{j}].shape={fp32_flat_groups[i][j].shape}")
|
| 273 |
+
|
| 274 |
+
# XXX: memory usage doubles here (zero2)
|
| 275 |
+
num_param_groups = len(fp32_flat_groups[0])
|
| 276 |
+
merged_single_partition_of_fp32_groups = []
|
| 277 |
+
for i in range(num_param_groups):
|
| 278 |
+
merged_partitions = [sd[i] for sd in fp32_flat_groups]
|
| 279 |
+
full_single_fp32_vector = torch.cat(merged_partitions, 0)
|
| 280 |
+
merged_single_partition_of_fp32_groups.append(full_single_fp32_vector)
|
| 281 |
+
avail_numel = sum(
|
| 282 |
+
[full_single_fp32_vector.numel() for full_single_fp32_vector in merged_single_partition_of_fp32_groups])
|
| 283 |
+
|
| 284 |
+
if debug:
|
| 285 |
+
wanted_params = sum([len(shapes) for shapes in param_shapes])
|
| 286 |
+
wanted_numel = sum([sum(shape.numel() for shape in shapes.values()) for shapes in param_shapes])
|
| 287 |
+
# not asserting if there is a mismatch due to possible padding
|
| 288 |
+
print(f"Have {avail_numel} numels to process.")
|
| 289 |
+
print(f"Need {wanted_numel} numels in {wanted_params} params.")
|
| 290 |
+
|
| 291 |
+
# params
|
| 292 |
+
# XXX: for huge models that can't fit into the host's RAM we will have to recode this to support
|
| 293 |
+
# out-of-core computing solution
|
| 294 |
+
total_numel = 0
|
| 295 |
+
total_params = 0
|
| 296 |
+
for shapes, full_single_fp32_vector in zip(param_shapes, merged_single_partition_of_fp32_groups):
|
| 297 |
+
offset = 0
|
| 298 |
+
avail_numel = full_single_fp32_vector.numel()
|
| 299 |
+
for name, shape in shapes.items():
|
| 300 |
+
|
| 301 |
+
unpartitioned_numel = shape.numel() if _has_callable(shape, 'numel') else math.prod(shape)
|
| 302 |
+
total_numel += unpartitioned_numel
|
| 303 |
+
total_params += 1
|
| 304 |
+
|
| 305 |
+
if debug:
|
| 306 |
+
print(f"{name} full shape: {shape} unpartitioned numel {unpartitioned_numel} ")
|
| 307 |
+
state_dict[name] = full_single_fp32_vector.narrow(0, offset, unpartitioned_numel).view(shape)
|
| 308 |
+
offset += unpartitioned_numel
|
| 309 |
+
|
| 310 |
+
# Z2 started to align to 2*world_size to improve nccl performance. Therefore both offset and
|
| 311 |
+
# avail_numel can differ by anywhere between 0..2*world_size. Due to two unrelated complex
|
| 312 |
+
# paddings performed in the code it's almost impossible to predict the exact numbers w/o the
|
| 313 |
+
# live optimizer object, so we are checking that the numbers are within the right range
|
| 314 |
+
align_to = 2 * world_size
|
| 315 |
+
|
| 316 |
+
def zero2_align(x):
|
| 317 |
+
return align_to * math.ceil(x / align_to)
|
| 318 |
+
|
| 319 |
+
if debug:
|
| 320 |
+
print(f"original offset={offset}, avail_numel={avail_numel}")
|
| 321 |
+
|
| 322 |
+
offset = zero2_align(offset)
|
| 323 |
+
avail_numel = zero2_align(avail_numel)
|
| 324 |
+
|
| 325 |
+
if debug:
|
| 326 |
+
print(f"aligned offset={offset}, avail_numel={avail_numel}")
|
| 327 |
+
|
| 328 |
+
# Sanity check
|
| 329 |
+
if offset != avail_numel:
|
| 330 |
+
raise ValueError(f"consumed {offset} numels out of {avail_numel} - something is wrong")
|
| 331 |
+
|
| 332 |
+
print(f"Reconstructed fp32 state dict with {total_params} params {total_numel} elements")
|
| 333 |
+
|
| 334 |
+
|
| 335 |
+
def _get_fp32_state_dict_from_zero2_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 336 |
+
exclude_frozen_parameters):
|
| 337 |
+
state_dict = OrderedDict()
|
| 338 |
+
|
| 339 |
+
# buffers
|
| 340 |
+
buffers = zero_model_states[0].buffers
|
| 341 |
+
state_dict.update(buffers)
|
| 342 |
+
if debug:
|
| 343 |
+
print(f"added {len(buffers)} buffers")
|
| 344 |
+
|
| 345 |
+
if not exclude_frozen_parameters:
|
| 346 |
+
_zero2_merge_frozen_params(state_dict, zero_model_states)
|
| 347 |
+
|
| 348 |
+
_zero2_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states)
|
| 349 |
+
|
| 350 |
+
# recover shared parameters
|
| 351 |
+
for pair in zero_model_states[0].shared_params:
|
| 352 |
+
if pair[1] in state_dict:
|
| 353 |
+
state_dict[pair[0]] = state_dict[pair[1]]
|
| 354 |
+
|
| 355 |
+
return state_dict
|
| 356 |
+
|
| 357 |
+
|
| 358 |
+
def zero3_partitioned_param_info(unpartitioned_numel, world_size):
|
| 359 |
+
remainder = unpartitioned_numel % world_size
|
| 360 |
+
padding_numel = (world_size - remainder) if remainder else 0
|
| 361 |
+
partitioned_numel = math.ceil(unpartitioned_numel / world_size)
|
| 362 |
+
return partitioned_numel, padding_numel
|
| 363 |
+
|
| 364 |
+
|
| 365 |
+
def _zero3_merge_frozen_params(state_dict, world_size, zero_model_states):
|
| 366 |
+
if zero_model_states[0].frozen_param_shapes is None or len(zero_model_states[0].frozen_param_shapes) == 0:
|
| 367 |
+
return
|
| 368 |
+
|
| 369 |
+
if debug:
|
| 370 |
+
for i in range(world_size):
|
| 371 |
+
num_elem = sum(s.numel() for s in zero_model_states[i].frozen_param_fragments.values())
|
| 372 |
+
print(f'rank {i}: {FROZEN_PARAM_SHAPES}.numel = {num_elem}')
|
| 373 |
+
|
| 374 |
+
frozen_param_shapes = zero_model_states[0].frozen_param_shapes
|
| 375 |
+
wanted_params = len(frozen_param_shapes)
|
| 376 |
+
wanted_numel = sum(s.numel() for s in frozen_param_shapes.values())
|
| 377 |
+
avail_numel = sum([p.numel() for p in zero_model_states[0].frozen_param_fragments.values()]) * world_size
|
| 378 |
+
print(f'Frozen params: Have {avail_numel} numels to process.')
|
| 379 |
+
print(f'Frozen params: Need {wanted_numel} numels in {wanted_params} params')
|
| 380 |
+
|
| 381 |
+
total_params = 0
|
| 382 |
+
total_numel = 0
|
| 383 |
+
for name, shape in zero_model_states[0].frozen_param_shapes.items():
|
| 384 |
+
total_params += 1
|
| 385 |
+
unpartitioned_numel = shape.numel()
|
| 386 |
+
total_numel += unpartitioned_numel
|
| 387 |
+
|
| 388 |
+
param_frags = tuple(model_state.frozen_param_fragments[name] for model_state in zero_model_states)
|
| 389 |
+
state_dict[name] = torch.cat(param_frags, 0).narrow(0, 0, unpartitioned_numel).view(shape)
|
| 390 |
+
|
| 391 |
+
partitioned_numel, partitioned_padding_numel = zero3_partitioned_param_info(unpartitioned_numel, world_size)
|
| 392 |
+
|
| 393 |
+
if debug:
|
| 394 |
+
print(
|
| 395 |
+
f"Frozen params: {total_params} {name} full shape: {shape} partition0 numel={partitioned_numel} partitioned_padding_numel={partitioned_padding_numel}"
|
| 396 |
+
)
|
| 397 |
+
|
| 398 |
+
print(f"Reconstructed Frozen fp32 state dict with {total_params} params {total_numel} elements")
|
| 399 |
+
|
| 400 |
+
|
| 401 |
+
def _zero3_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states):
|
| 402 |
+
param_shapes = zero_model_states[0].param_shapes
|
| 403 |
+
avail_numel = fp32_flat_groups[0].numel() * world_size
|
| 404 |
+
# Reconstruction protocol: For zero3 we need to zip the partitions together at boundary of each
|
| 405 |
+
# param, re-consolidating each param, while dealing with padding if any
|
| 406 |
+
|
| 407 |
+
# merge list of dicts, preserving order
|
| 408 |
+
param_shapes = {k: v for d in param_shapes for k, v in d.items()}
|
| 409 |
+
|
| 410 |
+
if debug:
|
| 411 |
+
for i in range(world_size):
|
| 412 |
+
print(f"{FP32_FLAT_GROUPS}[{i}].shape={fp32_flat_groups[i].shape}")
|
| 413 |
+
|
| 414 |
+
wanted_params = len(param_shapes)
|
| 415 |
+
wanted_numel = sum(shape.numel() for shape in param_shapes.values())
|
| 416 |
+
# not asserting if there is a mismatch due to possible padding
|
| 417 |
+
avail_numel = fp32_flat_groups[0].numel() * world_size
|
| 418 |
+
print(f"Trainable params: Have {avail_numel} numels to process.")
|
| 419 |
+
print(f"Trainable params: Need {wanted_numel} numels in {wanted_params} params.")
|
| 420 |
+
|
| 421 |
+
# params
|
| 422 |
+
# XXX: for huge models that can't fit into the host's RAM we will have to recode this to support
|
| 423 |
+
# out-of-core computing solution
|
| 424 |
+
offset = 0
|
| 425 |
+
total_numel = 0
|
| 426 |
+
total_params = 0
|
| 427 |
+
for name, shape in tqdm(param_shapes.items(), desc='Gathering Sharded Weights'):
|
| 428 |
+
unpartitioned_numel = shape.numel()
|
| 429 |
+
total_numel += unpartitioned_numel
|
| 430 |
+
total_params += 1
|
| 431 |
+
partitioned_numel, partitioned_padding_numel = zero3_partitioned_param_info(unpartitioned_numel, world_size)
|
| 432 |
+
|
| 433 |
+
if debug:
|
| 434 |
+
print(
|
| 435 |
+
f"Trainable params: {total_params} {name} full shape: {shape} partition0 numel={partitioned_numel} partitioned_padding_numel={partitioned_padding_numel}"
|
| 436 |
+
)
|
| 437 |
+
|
| 438 |
+
# XXX: memory usage doubles here
|
| 439 |
+
state_dict[name] = torch.cat(
|
| 440 |
+
tuple(fp32_flat_groups[i].narrow(0, offset, partitioned_numel) for i in range(world_size)),
|
| 441 |
+
0).narrow(0, 0, unpartitioned_numel).view(shape)
|
| 442 |
+
offset += partitioned_numel
|
| 443 |
+
|
| 444 |
+
offset *= world_size
|
| 445 |
+
|
| 446 |
+
# Sanity check
|
| 447 |
+
if offset != avail_numel:
|
| 448 |
+
raise ValueError(f"consumed {offset} numels out of {avail_numel} - something is wrong")
|
| 449 |
+
|
| 450 |
+
print(f"Reconstructed Trainable fp32 state dict with {total_params} params {total_numel} elements")
|
| 451 |
+
|
| 452 |
+
|
| 453 |
+
def _get_fp32_state_dict_from_zero3_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 454 |
+
exclude_frozen_parameters):
|
| 455 |
+
state_dict = OrderedDict()
|
| 456 |
+
|
| 457 |
+
# buffers
|
| 458 |
+
buffers = zero_model_states[0].buffers
|
| 459 |
+
state_dict.update(buffers)
|
| 460 |
+
if debug:
|
| 461 |
+
print(f"added {len(buffers)} buffers")
|
| 462 |
+
|
| 463 |
+
if not exclude_frozen_parameters:
|
| 464 |
+
_zero3_merge_frozen_params(state_dict, world_size, zero_model_states)
|
| 465 |
+
|
| 466 |
+
_zero3_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states)
|
| 467 |
+
|
| 468 |
+
# recover shared parameters
|
| 469 |
+
for pair in zero_model_states[0].shared_params:
|
| 470 |
+
if pair[1] in state_dict:
|
| 471 |
+
state_dict[pair[0]] = state_dict[pair[1]]
|
| 472 |
+
|
| 473 |
+
return state_dict
|
| 474 |
+
|
| 475 |
+
|
| 476 |
+
def get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag=None, exclude_frozen_parameters=False):
|
| 477 |
+
"""
|
| 478 |
+
Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated state_dict that can be loaded with
|
| 479 |
+
``load_state_dict()`` and used for training without DeepSpeed or shared with others, for example
|
| 480 |
+
via a model hub.
|
| 481 |
+
|
| 482 |
+
Args:
|
| 483 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder
|
| 484 |
+
- ``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``
|
| 485 |
+
- ``exclude_frozen_parameters``: exclude frozen parameters
|
| 486 |
+
|
| 487 |
+
Returns:
|
| 488 |
+
- pytorch ``state_dict``
|
| 489 |
+
|
| 490 |
+
Note: this approach may not work if your application doesn't have sufficient free CPU memory and
|
| 491 |
+
you may need to use the offline approach using the ``zero_to_fp32.py`` script that is saved with
|
| 492 |
+
the checkpoint.
|
| 493 |
+
|
| 494 |
+
A typical usage might be ::
|
| 495 |
+
|
| 496 |
+
from deepspeed.utils.zero_to_fp32 import get_fp32_state_dict_from_zero_checkpoint
|
| 497 |
+
# do the training and checkpoint saving
|
| 498 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir) # already on cpu
|
| 499 |
+
model = model.cpu() # move to cpu
|
| 500 |
+
model.load_state_dict(state_dict)
|
| 501 |
+
# submit to model hub or save the model to share with others
|
| 502 |
+
|
| 503 |
+
In this example the ``model`` will no longer be usable in the deepspeed context of the same
|
| 504 |
+
application. i.e. you will need to re-initialize the deepspeed engine, since
|
| 505 |
+
``model.load_state_dict(state_dict)`` will remove all the deepspeed magic from it.
|
| 506 |
+
|
| 507 |
+
If you want it all done for you, use ``load_state_dict_from_zero_checkpoint`` instead.
|
| 508 |
+
|
| 509 |
+
"""
|
| 510 |
+
if tag is None:
|
| 511 |
+
latest_path = os.path.join(checkpoint_dir, 'latest')
|
| 512 |
+
if os.path.isfile(latest_path):
|
| 513 |
+
with open(latest_path, 'r') as fd:
|
| 514 |
+
tag = fd.read().strip()
|
| 515 |
+
else:
|
| 516 |
+
raise ValueError(f"Unable to find 'latest' file at {latest_path}")
|
| 517 |
+
|
| 518 |
+
ds_checkpoint_dir = os.path.join(checkpoint_dir, tag)
|
| 519 |
+
|
| 520 |
+
if not os.path.isdir(ds_checkpoint_dir):
|
| 521 |
+
raise FileNotFoundError(f"Directory '{ds_checkpoint_dir}' doesn't exist")
|
| 522 |
+
|
| 523 |
+
return _get_fp32_state_dict_from_zero_checkpoint(ds_checkpoint_dir, exclude_frozen_parameters)
|
| 524 |
+
|
| 525 |
+
|
| 526 |
+
def convert_zero_checkpoint_to_fp32_state_dict(checkpoint_dir,
|
| 527 |
+
output_dir,
|
| 528 |
+
max_shard_size="5GB",
|
| 529 |
+
safe_serialization=False,
|
| 530 |
+
tag=None,
|
| 531 |
+
exclude_frozen_parameters=False):
|
| 532 |
+
"""
|
| 533 |
+
Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated ``state_dict`` file that can be
|
| 534 |
+
loaded with ``torch.load(file)`` + ``load_state_dict()`` and used for training without DeepSpeed.
|
| 535 |
+
|
| 536 |
+
Args:
|
| 537 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder. (one that contains the tag-folder, like ``global_step14``)
|
| 538 |
+
- ``output_dir``: directory to the pytorch fp32 state_dict output files
|
| 539 |
+
- ``max_shard_size``: the maximum size for a checkpoint before being sharded, default value is 5GB
|
| 540 |
+
- ``safe_serialization``: whether to save the model using `safetensors` or the traditional PyTorch way (that uses `pickle`).
|
| 541 |
+
- ``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``
|
| 542 |
+
- ``exclude_frozen_parameters``: exclude frozen parameters
|
| 543 |
+
"""
|
| 544 |
+
# Dependency pre-check
|
| 545 |
+
if safe_serialization:
|
| 546 |
+
try:
|
| 547 |
+
from safetensors.torch import save_file
|
| 548 |
+
except ImportError:
|
| 549 |
+
print('If you want to use `safe_serialization`, please `pip install safetensors`')
|
| 550 |
+
raise
|
| 551 |
+
if max_shard_size is not None:
|
| 552 |
+
try:
|
| 553 |
+
from huggingface_hub import split_torch_state_dict_into_shards
|
| 554 |
+
except ImportError:
|
| 555 |
+
print('If you want to use `max_shard_size`, please `pip install huggingface_hub`')
|
| 556 |
+
raise
|
| 557 |
+
|
| 558 |
+
# Convert zero checkpoint to state_dict
|
| 559 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag, exclude_frozen_parameters)
|
| 560 |
+
|
| 561 |
+
# Shard the model if it is too big.
|
| 562 |
+
weights_name = "model.safetensors" if safe_serialization else "pytorch_model.bin"
|
| 563 |
+
if max_shard_size is not None:
|
| 564 |
+
filename_pattern = weights_name.replace(".bin", "{suffix}.bin").replace(".safetensors", "{suffix}.safetensors")
|
| 565 |
+
state_dict_split = split_torch_state_dict_into_shards(state_dict,
|
| 566 |
+
filename_pattern=filename_pattern,
|
| 567 |
+
max_shard_size=max_shard_size)
|
| 568 |
+
else:
|
| 569 |
+
from collections import namedtuple
|
| 570 |
+
StateDictSplit = namedtuple("StateDictSplit", ["is_sharded", "filename_to_tensors"])
|
| 571 |
+
state_dict_split = StateDictSplit(is_sharded=False,
|
| 572 |
+
filename_to_tensors={weights_name: list(state_dict.keys())})
|
| 573 |
+
|
| 574 |
+
# Save the model
|
| 575 |
+
filename_to_tensors = state_dict_split.filename_to_tensors.items()
|
| 576 |
+
for shard_file, tensors in tqdm(filename_to_tensors, desc="Saving checkpoint shards"):
|
| 577 |
+
shard = {tensor: state_dict[tensor].contiguous() for tensor in tensors}
|
| 578 |
+
output_path = os.path.join(output_dir, shard_file)
|
| 579 |
+
if safe_serialization:
|
| 580 |
+
save_file(shard, output_path, metadata={"format": "pt"})
|
| 581 |
+
else:
|
| 582 |
+
torch.save(shard, output_path)
|
| 583 |
+
|
| 584 |
+
# Save index if sharded
|
| 585 |
+
if state_dict_split.is_sharded:
|
| 586 |
+
index = {
|
| 587 |
+
"metadata": state_dict_split.metadata,
|
| 588 |
+
"weight_map": state_dict_split.tensor_to_filename,
|
| 589 |
+
}
|
| 590 |
+
save_index_file = "model.safetensors.index.json" if safe_serialization else "pytorch_model.bin.index.json"
|
| 591 |
+
save_index_file = os.path.join(output_dir, save_index_file)
|
| 592 |
+
with open(save_index_file, "w", encoding="utf-8") as f:
|
| 593 |
+
content = json.dumps(index, indent=2, sort_keys=True) + "\n"
|
| 594 |
+
f.write(content)
|
| 595 |
+
|
| 596 |
+
|
| 597 |
+
def load_state_dict_from_zero_checkpoint(model, checkpoint_dir, tag=None):
|
| 598 |
+
"""
|
| 599 |
+
1. Put the provided model to cpu
|
| 600 |
+
2. Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated ``state_dict``
|
| 601 |
+
3. Load it into the provided model
|
| 602 |
+
|
| 603 |
+
Args:
|
| 604 |
+
- ``model``: the model object to update
|
| 605 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder. (one that contains the tag-folder, like ``global_step14``)
|
| 606 |
+
- ``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``
|
| 607 |
+
|
| 608 |
+
Returns:
|
| 609 |
+
- ``model`: modified model
|
| 610 |
+
|
| 611 |
+
Make sure you have plenty of CPU memory available before you call this function. If you don't
|
| 612 |
+
have enough use the ``zero_to_fp32.py`` utility to do the conversion. You will find it
|
| 613 |
+
conveniently placed for you in the checkpoint folder.
|
| 614 |
+
|
| 615 |
+
A typical usage might be ::
|
| 616 |
+
|
| 617 |
+
from deepspeed.utils.zero_to_fp32 import load_state_dict_from_zero_checkpoint
|
| 618 |
+
model = load_state_dict_from_zero_checkpoint(trainer.model, checkpoint_dir)
|
| 619 |
+
# submit to model hub or save the model to share with others
|
| 620 |
+
|
| 621 |
+
Note, that once this was run, the ``model`` will no longer be usable in the deepspeed context
|
| 622 |
+
of the same application. i.e. you will need to re-initialize the deepspeed engine, since
|
| 623 |
+
``model.load_state_dict(state_dict)`` will remove all the deepspeed magic from it.
|
| 624 |
+
|
| 625 |
+
"""
|
| 626 |
+
logger.info(f"Extracting fp32 weights")
|
| 627 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag)
|
| 628 |
+
|
| 629 |
+
logger.info(f"Overwriting model with fp32 weights")
|
| 630 |
+
model = model.cpu()
|
| 631 |
+
model.load_state_dict(state_dict, strict=False)
|
| 632 |
+
|
| 633 |
+
return model
|
| 634 |
+
|
| 635 |
+
|
| 636 |
+
if __name__ == "__main__":
|
| 637 |
+
parser = argparse.ArgumentParser()
|
| 638 |
+
parser.add_argument("checkpoint_dir",
|
| 639 |
+
type=str,
|
| 640 |
+
help="path to the desired checkpoint folder, e.g., path/checkpoint-12")
|
| 641 |
+
parser.add_argument("output_dir",
|
| 642 |
+
type=str,
|
| 643 |
+
help="directory to the pytorch fp32 state_dict output files"
|
| 644 |
+
"(e.g. path/checkpoint-12-output/)")
|
| 645 |
+
parser.add_argument(
|
| 646 |
+
"--max_shard_size",
|
| 647 |
+
type=str,
|
| 648 |
+
default="5GB",
|
| 649 |
+
help="The maximum size for a checkpoint before being sharded. Checkpoints shard will then be each of size"
|
| 650 |
+
"lower than this size. If expressed as a string, needs to be digits followed by a unit (like `5MB`"
|
| 651 |
+
"We default it to 5GB in order for models to be able to run easily on free-tier google colab instances"
|
| 652 |
+
"without CPU OOM issues.")
|
| 653 |
+
parser.add_argument(
|
| 654 |
+
"--safe_serialization",
|
| 655 |
+
default=False,
|
| 656 |
+
action='store_true',
|
| 657 |
+
help="Whether to save the model using `safetensors` or the traditional PyTorch way (that uses `pickle`).")
|
| 658 |
+
parser.add_argument("-t",
|
| 659 |
+
"--tag",
|
| 660 |
+
type=str,
|
| 661 |
+
default=None,
|
| 662 |
+
help="checkpoint tag used as a unique identifier for checkpoint. e.g., global_step1")
|
| 663 |
+
parser.add_argument("--exclude_frozen_parameters", action='store_true', help="exclude frozen parameters")
|
| 664 |
+
parser.add_argument("-d", "--debug", action='store_true', help="enable debug")
|
| 665 |
+
args = parser.parse_args()
|
| 666 |
+
|
| 667 |
+
debug = args.debug
|
| 668 |
+
|
| 669 |
+
convert_zero_checkpoint_to_fp32_state_dict(args.checkpoint_dir,
|
| 670 |
+
args.output_dir,
|
| 671 |
+
max_shard_size=args.max_shard_size,
|
| 672 |
+
safe_serialization=args.safe_serialization,
|
| 673 |
+
tag=args.tag,
|
| 674 |
+
exclude_frozen_parameters=args.exclude_frozen_parameters)
|
checkpoint-500/README.md
ADDED
|
@@ -0,0 +1,202 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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
+
---
|
| 5 |
+
|
| 6 |
+
# Model Card for Model ID
|
| 7 |
+
|
| 8 |
+
<!-- Provide a quick summary of what the model is/does. -->
|
| 9 |
+
|
| 10 |
+
|
| 11 |
+
|
| 12 |
+
## Model Details
|
| 13 |
+
|
| 14 |
+
### Model Description
|
| 15 |
+
|
| 16 |
+
<!-- Provide a longer summary of what this model is. -->
|
| 17 |
+
|
| 18 |
+
|
| 19 |
+
|
| 20 |
+
- **Developed by:** [More Information Needed]
|
| 21 |
+
- **Funded by [optional]:** [More Information Needed]
|
| 22 |
+
- **Shared by [optional]:** [More Information Needed]
|
| 23 |
+
- **Model type:** [More Information Needed]
|
| 24 |
+
- **Language(s) (NLP):** [More Information Needed]
|
| 25 |
+
- **License:** [More Information Needed]
|
| 26 |
+
- **Finetuned from model [optional]:** [More Information Needed]
|
| 27 |
+
|
| 28 |
+
### Model Sources [optional]
|
| 29 |
+
|
| 30 |
+
<!-- Provide the basic links for the model. -->
|
| 31 |
+
|
| 32 |
+
- **Repository:** [More Information Needed]
|
| 33 |
+
- **Paper [optional]:** [More Information Needed]
|
| 34 |
+
- **Demo [optional]:** [More Information Needed]
|
| 35 |
+
|
| 36 |
+
## Uses
|
| 37 |
+
|
| 38 |
+
<!-- Address questions around how the model is intended to be used, including the foreseeable users of the model and those affected by the model. -->
|
| 39 |
+
|
| 40 |
+
### Direct Use
|
| 41 |
+
|
| 42 |
+
<!-- This section is for the model use without fine-tuning or plugging into a larger ecosystem/app. -->
|
| 43 |
+
|
| 44 |
+
[More Information Needed]
|
| 45 |
+
|
| 46 |
+
### Downstream Use [optional]
|
| 47 |
+
|
| 48 |
+
<!-- This section is for the model use when fine-tuned for a task, or when plugged into a larger ecosystem/app -->
|
| 49 |
+
|
| 50 |
+
[More Information Needed]
|
| 51 |
+
|
| 52 |
+
### Out-of-Scope Use
|
| 53 |
+
|
| 54 |
+
<!-- This section addresses misuse, malicious use, and uses that the model will not work well for. -->
|
| 55 |
+
|
| 56 |
+
[More Information Needed]
|
| 57 |
+
|
| 58 |
+
## Bias, Risks, and Limitations
|
| 59 |
+
|
| 60 |
+
<!-- This section is meant to convey both technical and sociotechnical limitations. -->
|
| 61 |
+
|
| 62 |
+
[More Information Needed]
|
| 63 |
+
|
| 64 |
+
### Recommendations
|
| 65 |
+
|
| 66 |
+
<!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. -->
|
| 67 |
+
|
| 68 |
+
Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
|
| 69 |
+
|
| 70 |
+
## How to Get Started with the Model
|
| 71 |
+
|
| 72 |
+
Use the code below to get started with the model.
|
| 73 |
+
|
| 74 |
+
[More Information Needed]
|
| 75 |
+
|
| 76 |
+
## Training Details
|
| 77 |
+
|
| 78 |
+
### Training Data
|
| 79 |
+
|
| 80 |
+
<!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
|
| 81 |
+
|
| 82 |
+
[More Information Needed]
|
| 83 |
+
|
| 84 |
+
### Training Procedure
|
| 85 |
+
|
| 86 |
+
<!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
|
| 87 |
+
|
| 88 |
+
#### Preprocessing [optional]
|
| 89 |
+
|
| 90 |
+
[More Information Needed]
|
| 91 |
+
|
| 92 |
+
|
| 93 |
+
#### Training Hyperparameters
|
| 94 |
+
|
| 95 |
+
- **Training regime:** [More Information Needed] <!--fp32, fp16 mixed precision, bf16 mixed precision, bf16 non-mixed precision, fp16 non-mixed precision, fp8 mixed precision -->
|
| 96 |
+
|
| 97 |
+
#### Speeds, Sizes, Times [optional]
|
| 98 |
+
|
| 99 |
+
<!-- This section provides information about throughput, start/end time, checkpoint size if relevant, etc. -->
|
| 100 |
+
|
| 101 |
+
[More Information Needed]
|
| 102 |
+
|
| 103 |
+
## Evaluation
|
| 104 |
+
|
| 105 |
+
<!-- This section describes the evaluation protocols and provides the results. -->
|
| 106 |
+
|
| 107 |
+
### Testing Data, Factors & Metrics
|
| 108 |
+
|
| 109 |
+
#### Testing Data
|
| 110 |
+
|
| 111 |
+
<!-- This should link to a Dataset Card if possible. -->
|
| 112 |
+
|
| 113 |
+
[More Information Needed]
|
| 114 |
+
|
| 115 |
+
#### Factors
|
| 116 |
+
|
| 117 |
+
<!-- These are the things the evaluation is disaggregating by, e.g., subpopulations or domains. -->
|
| 118 |
+
|
| 119 |
+
[More Information Needed]
|
| 120 |
+
|
| 121 |
+
#### Metrics
|
| 122 |
+
|
| 123 |
+
<!-- These are the evaluation metrics being used, ideally with a description of why. -->
|
| 124 |
+
|
| 125 |
+
[More Information Needed]
|
| 126 |
+
|
| 127 |
+
### Results
|
| 128 |
+
|
| 129 |
+
[More Information Needed]
|
| 130 |
+
|
| 131 |
+
#### Summary
|
| 132 |
+
|
| 133 |
+
|
| 134 |
+
|
| 135 |
+
## Model Examination [optional]
|
| 136 |
+
|
| 137 |
+
<!-- Relevant interpretability work for the model goes here -->
|
| 138 |
+
|
| 139 |
+
[More Information Needed]
|
| 140 |
+
|
| 141 |
+
## Environmental Impact
|
| 142 |
+
|
| 143 |
+
<!-- Total emissions (in grams of CO2eq) and additional considerations, such as electricity usage, go here. Edit the suggested text below accordingly -->
|
| 144 |
+
|
| 145 |
+
Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700).
|
| 146 |
+
|
| 147 |
+
- **Hardware Type:** [More Information Needed]
|
| 148 |
+
- **Hours used:** [More Information Needed]
|
| 149 |
+
- **Cloud Provider:** [More Information Needed]
|
| 150 |
+
- **Compute Region:** [More Information Needed]
|
| 151 |
+
- **Carbon Emitted:** [More Information Needed]
|
| 152 |
+
|
| 153 |
+
## Technical Specifications [optional]
|
| 154 |
+
|
| 155 |
+
### Model Architecture and Objective
|
| 156 |
+
|
| 157 |
+
[More Information Needed]
|
| 158 |
+
|
| 159 |
+
### Compute Infrastructure
|
| 160 |
+
|
| 161 |
+
[More Information Needed]
|
| 162 |
+
|
| 163 |
+
#### Hardware
|
| 164 |
+
|
| 165 |
+
[More Information Needed]
|
| 166 |
+
|
| 167 |
+
#### Software
|
| 168 |
+
|
| 169 |
+
[More Information Needed]
|
| 170 |
+
|
| 171 |
+
## Citation [optional]
|
| 172 |
+
|
| 173 |
+
<!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. -->
|
| 174 |
+
|
| 175 |
+
**BibTeX:**
|
| 176 |
+
|
| 177 |
+
[More Information Needed]
|
| 178 |
+
|
| 179 |
+
**APA:**
|
| 180 |
+
|
| 181 |
+
[More Information Needed]
|
| 182 |
+
|
| 183 |
+
## Glossary [optional]
|
| 184 |
+
|
| 185 |
+
<!-- If relevant, include terms and calculations in this section that can help readers understand the model or model card. -->
|
| 186 |
+
|
| 187 |
+
[More Information Needed]
|
| 188 |
+
|
| 189 |
+
## More Information [optional]
|
| 190 |
+
|
| 191 |
+
[More Information Needed]
|
| 192 |
+
|
| 193 |
+
## Model Card Authors [optional]
|
| 194 |
+
|
| 195 |
+
[More Information Needed]
|
| 196 |
+
|
| 197 |
+
## Model Card Contact
|
| 198 |
+
|
| 199 |
+
[More Information Needed]
|
| 200 |
+
### Framework versions
|
| 201 |
+
|
| 202 |
+
- PEFT 0.14.0
|
checkpoint-500/adapter_config.json
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"alpha_pattern": {},
|
| 3 |
+
"auto_mapping": null,
|
| 4 |
+
"base_model_name_or_path": "Qwen/Qwen2.5-7B",
|
| 5 |
+
"bias": "none",
|
| 6 |
+
"eva_config": null,
|
| 7 |
+
"exclude_modules": null,
|
| 8 |
+
"fan_in_fan_out": false,
|
| 9 |
+
"inference_mode": true,
|
| 10 |
+
"init_lora_weights": true,
|
| 11 |
+
"layer_replication": null,
|
| 12 |
+
"layers_pattern": null,
|
| 13 |
+
"layers_to_transform": null,
|
| 14 |
+
"loftq_config": {},
|
| 15 |
+
"lora_alpha": 32,
|
| 16 |
+
"lora_bias": false,
|
| 17 |
+
"lora_dropout": 0.0,
|
| 18 |
+
"megatron_config": null,
|
| 19 |
+
"megatron_core": "megatron.core",
|
| 20 |
+
"modules_to_save": null,
|
| 21 |
+
"peft_type": "LORA",
|
| 22 |
+
"r": 16,
|
| 23 |
+
"rank_pattern": {},
|
| 24 |
+
"revision": null,
|
| 25 |
+
"target_modules": [
|
| 26 |
+
"k_proj",
|
| 27 |
+
"v_proj",
|
| 28 |
+
"q_proj",
|
| 29 |
+
"up_proj",
|
| 30 |
+
"gate_proj",
|
| 31 |
+
"down_proj",
|
| 32 |
+
"o_proj"
|
| 33 |
+
],
|
| 34 |
+
"task_type": "CAUSAL_LM",
|
| 35 |
+
"use_dora": false,
|
| 36 |
+
"use_rslora": false
|
| 37 |
+
}
|
checkpoint-500/adapter_model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:888aea7ce26863acfdec85b6f9309e6828f7053858e3f88f6021c493e1e745c7
|
| 3 |
+
size 80792880
|
checkpoint-500/added_tokens.json
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"</tool_call>": 151658,
|
| 3 |
+
"<tool_call>": 151657,
|
| 4 |
+
"<|box_end|>": 151649,
|
| 5 |
+
"<|box_start|>": 151648,
|
| 6 |
+
"<|endoftext|>": 151643,
|
| 7 |
+
"<|file_sep|>": 151664,
|
| 8 |
+
"<|fim_middle|>": 151660,
|
| 9 |
+
"<|fim_pad|>": 151662,
|
| 10 |
+
"<|fim_prefix|>": 151659,
|
| 11 |
+
"<|fim_suffix|>": 151661,
|
| 12 |
+
"<|im_end|>": 151645,
|
| 13 |
+
"<|im_start|>": 151644,
|
| 14 |
+
"<|image_pad|>": 151655,
|
| 15 |
+
"<|object_ref_end|>": 151647,
|
| 16 |
+
"<|object_ref_start|>": 151646,
|
| 17 |
+
"<|quad_end|>": 151651,
|
| 18 |
+
"<|quad_start|>": 151650,
|
| 19 |
+
"<|repo_name|>": 151663,
|
| 20 |
+
"<|video_pad|>": 151656,
|
| 21 |
+
"<|vision_end|>": 151653,
|
| 22 |
+
"<|vision_pad|>": 151654,
|
| 23 |
+
"<|vision_start|>": 151652
|
| 24 |
+
}
|
checkpoint-500/latest
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
global_step500
|
checkpoint-500/merges.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
checkpoint-500/rng_state_0.pth
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:c8d6a959372d5e0c2ea025dd26c9d0ad2046fce19352056cae8074dcbd0a6fd4
|
| 3 |
+
size 14512
|
checkpoint-500/rng_state_1.pth
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:0f68a37892a1b445d21bb35cc10bf7a058a6f9ec8c363f5ed156ff4f49d90fb6
|
| 3 |
+
size 14512
|
checkpoint-500/special_tokens_map.json
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"additional_special_tokens": [
|
| 3 |
+
"<|im_start|>",
|
| 4 |
+
"<|im_end|>",
|
| 5 |
+
"<|object_ref_start|>",
|
| 6 |
+
"<|object_ref_end|>",
|
| 7 |
+
"<|box_start|>",
|
| 8 |
+
"<|box_end|>",
|
| 9 |
+
"<|quad_start|>",
|
| 10 |
+
"<|quad_end|>",
|
| 11 |
+
"<|vision_start|>",
|
| 12 |
+
"<|vision_end|>",
|
| 13 |
+
"<|vision_pad|>",
|
| 14 |
+
"<|image_pad|>",
|
| 15 |
+
"<|video_pad|>"
|
| 16 |
+
],
|
| 17 |
+
"eos_token": {
|
| 18 |
+
"content": "<|endoftext|>",
|
| 19 |
+
"lstrip": false,
|
| 20 |
+
"normalized": false,
|
| 21 |
+
"rstrip": false,
|
| 22 |
+
"single_word": false
|
| 23 |
+
},
|
| 24 |
+
"pad_token": {
|
| 25 |
+
"content": "<|endoftext|>",
|
| 26 |
+
"lstrip": false,
|
| 27 |
+
"normalized": false,
|
| 28 |
+
"rstrip": false,
|
| 29 |
+
"single_word": false
|
| 30 |
+
}
|
| 31 |
+
}
|
checkpoint-500/tokenizer.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9c5ae00e602b8860cbd784ba82a8aa14e8feecec692e7076590d014d7b7fdafa
|
| 3 |
+
size 11421896
|
checkpoint-500/tokenizer_config.json
ADDED
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"add_bos_token": false,
|
| 3 |
+
"add_prefix_space": false,
|
| 4 |
+
"added_tokens_decoder": {
|
| 5 |
+
"151643": {
|
| 6 |
+
"content": "<|endoftext|>",
|
| 7 |
+
"lstrip": false,
|
| 8 |
+
"normalized": false,
|
| 9 |
+
"rstrip": false,
|
| 10 |
+
"single_word": false,
|
| 11 |
+
"special": true
|
| 12 |
+
},
|
| 13 |
+
"151644": {
|
| 14 |
+
"content": "<|im_start|>",
|
| 15 |
+
"lstrip": false,
|
| 16 |
+
"normalized": false,
|
| 17 |
+
"rstrip": false,
|
| 18 |
+
"single_word": false,
|
| 19 |
+
"special": true
|
| 20 |
+
},
|
| 21 |
+
"151645": {
|
| 22 |
+
"content": "<|im_end|>",
|
| 23 |
+
"lstrip": false,
|
| 24 |
+
"normalized": false,
|
| 25 |
+
"rstrip": false,
|
| 26 |
+
"single_word": false,
|
| 27 |
+
"special": true
|
| 28 |
+
},
|
| 29 |
+
"151646": {
|
| 30 |
+
"content": "<|object_ref_start|>",
|
| 31 |
+
"lstrip": false,
|
| 32 |
+
"normalized": false,
|
| 33 |
+
"rstrip": false,
|
| 34 |
+
"single_word": false,
|
| 35 |
+
"special": true
|
| 36 |
+
},
|
| 37 |
+
"151647": {
|
| 38 |
+
"content": "<|object_ref_end|>",
|
| 39 |
+
"lstrip": false,
|
| 40 |
+
"normalized": false,
|
| 41 |
+
"rstrip": false,
|
| 42 |
+
"single_word": false,
|
| 43 |
+
"special": true
|
| 44 |
+
},
|
| 45 |
+
"151648": {
|
| 46 |
+
"content": "<|box_start|>",
|
| 47 |
+
"lstrip": false,
|
| 48 |
+
"normalized": false,
|
| 49 |
+
"rstrip": false,
|
| 50 |
+
"single_word": false,
|
| 51 |
+
"special": true
|
| 52 |
+
},
|
| 53 |
+
"151649": {
|
| 54 |
+
"content": "<|box_end|>",
|
| 55 |
+
"lstrip": false,
|
| 56 |
+
"normalized": false,
|
| 57 |
+
"rstrip": false,
|
| 58 |
+
"single_word": false,
|
| 59 |
+
"special": true
|
| 60 |
+
},
|
| 61 |
+
"151650": {
|
| 62 |
+
"content": "<|quad_start|>",
|
| 63 |
+
"lstrip": false,
|
| 64 |
+
"normalized": false,
|
| 65 |
+
"rstrip": false,
|
| 66 |
+
"single_word": false,
|
| 67 |
+
"special": true
|
| 68 |
+
},
|
| 69 |
+
"151651": {
|
| 70 |
+
"content": "<|quad_end|>",
|
| 71 |
+
"lstrip": false,
|
| 72 |
+
"normalized": false,
|
| 73 |
+
"rstrip": false,
|
| 74 |
+
"single_word": false,
|
| 75 |
+
"special": true
|
| 76 |
+
},
|
| 77 |
+
"151652": {
|
| 78 |
+
"content": "<|vision_start|>",
|
| 79 |
+
"lstrip": false,
|
| 80 |
+
"normalized": false,
|
| 81 |
+
"rstrip": false,
|
| 82 |
+
"single_word": false,
|
| 83 |
+
"special": true
|
| 84 |
+
},
|
| 85 |
+
"151653": {
|
| 86 |
+
"content": "<|vision_end|>",
|
| 87 |
+
"lstrip": false,
|
| 88 |
+
"normalized": false,
|
| 89 |
+
"rstrip": false,
|
| 90 |
+
"single_word": false,
|
| 91 |
+
"special": true
|
| 92 |
+
},
|
| 93 |
+
"151654": {
|
| 94 |
+
"content": "<|vision_pad|>",
|
| 95 |
+
"lstrip": false,
|
| 96 |
+
"normalized": false,
|
| 97 |
+
"rstrip": false,
|
| 98 |
+
"single_word": false,
|
| 99 |
+
"special": true
|
| 100 |
+
},
|
| 101 |
+
"151655": {
|
| 102 |
+
"content": "<|image_pad|>",
|
| 103 |
+
"lstrip": false,
|
| 104 |
+
"normalized": false,
|
| 105 |
+
"rstrip": false,
|
| 106 |
+
"single_word": false,
|
| 107 |
+
"special": true
|
| 108 |
+
},
|
| 109 |
+
"151656": {
|
| 110 |
+
"content": "<|video_pad|>",
|
| 111 |
+
"lstrip": false,
|
| 112 |
+
"normalized": false,
|
| 113 |
+
"rstrip": false,
|
| 114 |
+
"single_word": false,
|
| 115 |
+
"special": true
|
| 116 |
+
},
|
| 117 |
+
"151657": {
|
| 118 |
+
"content": "<tool_call>",
|
| 119 |
+
"lstrip": false,
|
| 120 |
+
"normalized": false,
|
| 121 |
+
"rstrip": false,
|
| 122 |
+
"single_word": false,
|
| 123 |
+
"special": false
|
| 124 |
+
},
|
| 125 |
+
"151658": {
|
| 126 |
+
"content": "</tool_call>",
|
| 127 |
+
"lstrip": false,
|
| 128 |
+
"normalized": false,
|
| 129 |
+
"rstrip": false,
|
| 130 |
+
"single_word": false,
|
| 131 |
+
"special": false
|
| 132 |
+
},
|
| 133 |
+
"151659": {
|
| 134 |
+
"content": "<|fim_prefix|>",
|
| 135 |
+
"lstrip": false,
|
| 136 |
+
"normalized": false,
|
| 137 |
+
"rstrip": false,
|
| 138 |
+
"single_word": false,
|
| 139 |
+
"special": false
|
| 140 |
+
},
|
| 141 |
+
"151660": {
|
| 142 |
+
"content": "<|fim_middle|>",
|
| 143 |
+
"lstrip": false,
|
| 144 |
+
"normalized": false,
|
| 145 |
+
"rstrip": false,
|
| 146 |
+
"single_word": false,
|
| 147 |
+
"special": false
|
| 148 |
+
},
|
| 149 |
+
"151661": {
|
| 150 |
+
"content": "<|fim_suffix|>",
|
| 151 |
+
"lstrip": false,
|
| 152 |
+
"normalized": false,
|
| 153 |
+
"rstrip": false,
|
| 154 |
+
"single_word": false,
|
| 155 |
+
"special": false
|
| 156 |
+
},
|
| 157 |
+
"151662": {
|
| 158 |
+
"content": "<|fim_pad|>",
|
| 159 |
+
"lstrip": false,
|
| 160 |
+
"normalized": false,
|
| 161 |
+
"rstrip": false,
|
| 162 |
+
"single_word": false,
|
| 163 |
+
"special": false
|
| 164 |
+
},
|
| 165 |
+
"151663": {
|
| 166 |
+
"content": "<|repo_name|>",
|
| 167 |
+
"lstrip": false,
|
| 168 |
+
"normalized": false,
|
| 169 |
+
"rstrip": false,
|
| 170 |
+
"single_word": false,
|
| 171 |
+
"special": false
|
| 172 |
+
},
|
| 173 |
+
"151664": {
|
| 174 |
+
"content": "<|file_sep|>",
|
| 175 |
+
"lstrip": false,
|
| 176 |
+
"normalized": false,
|
| 177 |
+
"rstrip": false,
|
| 178 |
+
"single_word": false,
|
| 179 |
+
"special": false
|
| 180 |
+
}
|
| 181 |
+
},
|
| 182 |
+
"additional_special_tokens": [
|
| 183 |
+
"<|im_start|>",
|
| 184 |
+
"<|im_end|>",
|
| 185 |
+
"<|object_ref_start|>",
|
| 186 |
+
"<|object_ref_end|>",
|
| 187 |
+
"<|box_start|>",
|
| 188 |
+
"<|box_end|>",
|
| 189 |
+
"<|quad_start|>",
|
| 190 |
+
"<|quad_end|>",
|
| 191 |
+
"<|vision_start|>",
|
| 192 |
+
"<|vision_end|>",
|
| 193 |
+
"<|vision_pad|>",
|
| 194 |
+
"<|image_pad|>",
|
| 195 |
+
"<|video_pad|>"
|
| 196 |
+
],
|
| 197 |
+
"bos_token": null,
|
| 198 |
+
"chat_template": "{%- if tools %}\n {{- '<|im_start|>system\\n' }}\n {%- if messages[0]['role'] == 'system' %}\n {{- messages[0]['content'] }}\n {%- else %}\n {{- 'You are a helpful assistant.' }}\n {%- endif %}\n {{- \"\\n\\n# Tools\\n\\nYou may call one or more functions to assist with the user query.\\n\\nYou are provided with function signatures within <tools></tools> XML tags:\\n<tools>\" }}\n {%- for tool in tools %}\n {{- \"\\n\" }}\n {{- tool | tojson }}\n {%- endfor %}\n {{- \"\\n</tools>\\n\\nFor each function call, return a json object with function name and arguments within <tool_call></tool_call> XML tags:\\n<tool_call>\\n{\\\"name\\\": <function-name>, \\\"arguments\\\": <args-json-object>}\\n</tool_call><|im_end|>\\n\" }}\n{%- else %}\n {%- if messages[0]['role'] == 'system' %}\n {{- '<|im_start|>system\\n' + messages[0]['content'] + '<|im_end|>\\n' }}\n {%- else %}\n {{- '<|im_start|>system\\nYou are a helpful assistant.<|im_end|>\\n' }}\n {%- endif %}\n{%- endif %}\n{%- for message in messages %}\n {%- if (message.role == \"user\") or (message.role == \"system\" and not loop.first) or (message.role == \"assistant\" and not message.tool_calls) %}\n {{- '<|im_start|>' + message.role + '\\n' + message.content + '<|im_end|>' + '\\n' }}\n {%- elif message.role == \"assistant\" %}\n {{- '<|im_start|>' + message.role }}\n {%- if message.content %}\n {{- '\\n' + message.content }}\n {%- endif %}\n {%- for tool_call in message.tool_calls %}\n {%- if tool_call.function is defined %}\n {%- set tool_call = tool_call.function %}\n {%- endif %}\n {{- '\\n<tool_call>\\n{\"name\": \"' }}\n {{- tool_call.name }}\n {{- '\", \"arguments\": ' }}\n {{- tool_call.arguments | tojson }}\n {{- '}\\n</tool_call>' }}\n {%- endfor %}\n {{- '<|im_end|>\\n' }}\n {%- elif message.role == \"tool\" %}\n {%- if (loop.index0 == 0) or (messages[loop.index0 - 1].role != \"tool\") %}\n {{- '<|im_start|>user' }}\n {%- endif %}\n {{- '\\n<tool_response>\\n' }}\n {{- message.content }}\n {{- '\\n</tool_response>' }}\n {%- if loop.last or (messages[loop.index0 + 1].role != \"tool\") %}\n {{- '<|im_end|>\\n' }}\n {%- endif %}\n {%- endif %}\n{%- endfor %}\n{%- if add_generation_prompt %}\n {{- '<|im_start|>assistant\\n' }}\n{%- endif %}\n",
|
| 199 |
+
"clean_up_tokenization_spaces": false,
|
| 200 |
+
"eos_token": "<|endoftext|>",
|
| 201 |
+
"errors": "replace",
|
| 202 |
+
"extra_special_tokens": {},
|
| 203 |
+
"model_max_length": 131072,
|
| 204 |
+
"pad_token": "<|endoftext|>",
|
| 205 |
+
"split_special_tokens": false,
|
| 206 |
+
"tokeniz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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"best_metric": null,
|
| 3 |
+
"best_model_checkpoint": null,
|
| 4 |
+
"epoch": 0.998377636340946,
|
| 5 |
+
"eval_steps": 500,
|
| 6 |
+
"global_step": 500,
|
| 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.001996755272681892,
|
| 13 |
+
"grad_norm": 0.7412710189819336,
|
| 14 |
+
"learning_rate": 2.5000000000000004e-07,
|
| 15 |
+
"loss": 1.5868,
|
| 16 |
+
"step": 1
|
| 17 |
+
},
|
| 18 |
+
{
|
| 19 |
+
"epoch": 0.003993510545363784,
|
| 20 |
+
"grad_norm": 0.706846296787262,
|
| 21 |
+
"learning_rate": 5.000000000000001e-07,
|
| 22 |
+
"loss": 1.5439,
|
| 23 |
+
"step": 2
|
| 24 |
+
},
|
| 25 |
+
{
|
| 26 |
+
"epoch": 0.005990265818045676,
|
| 27 |
+
"grad_norm": 0.7040128707885742,
|
| 28 |
+
"learning_rate": 7.5e-07,
|
| 29 |
+
"loss": 1.5332,
|
| 30 |
+
"step": 3
|
| 31 |
+
},
|
| 32 |
+
{
|
| 33 |
+
"epoch": 0.007987021090727568,
|
| 34 |
+
"grad_norm": 0.7102969884872437,
|
| 35 |
+
"learning_rate": 1.0000000000000002e-06,
|
| 36 |
+
"loss": 1.5666,
|
| 37 |
+
"step": 4
|
| 38 |
+
},
|
| 39 |
+
{
|
| 40 |
+
"epoch": 0.00998377636340946,
|
| 41 |
+
"grad_norm": 0.7481162548065186,
|
| 42 |
+
"learning_rate": 1.25e-06,
|
| 43 |
+
"loss": 1.5532,
|
| 44 |
+
"step": 5
|
| 45 |
+
},
|
| 46 |
+
{
|
| 47 |
+
"epoch": 0.011980531636091352,
|
| 48 |
+
"grad_norm": 0.7318422198295593,
|
| 49 |
+
"learning_rate": 1.5e-06,
|
| 50 |
+
"loss": 1.5908,
|
| 51 |
+
"step": 6
|
| 52 |
+
},
|
| 53 |
+
{
|
| 54 |
+
"epoch": 0.013977286908773243,
|
| 55 |
+
"grad_norm": 0.6923463344573975,
|
| 56 |
+
"learning_rate": 1.75e-06,
|
| 57 |
+
"loss": 1.5761,
|
| 58 |
+
"step": 7
|
| 59 |
+
},
|
| 60 |
+
{
|
| 61 |
+
"epoch": 0.015974042181455136,
|
| 62 |
+
"grad_norm": 0.6836492419242859,
|
| 63 |
+
"learning_rate": 2.0000000000000003e-06,
|
| 64 |
+
"loss": 1.5314,
|
| 65 |
+
"step": 8
|
| 66 |
+
},
|
| 67 |
+
{
|
| 68 |
+
"epoch": 0.017970797454137027,
|
| 69 |
+
"grad_norm": 0.742129921913147,
|
| 70 |
+
"learning_rate": 2.25e-06,
|
| 71 |
+
"loss": 1.5662,
|
| 72 |
+
"step": 9
|
| 73 |
+
},
|
| 74 |
+
{
|
| 75 |
+
"epoch": 0.01996755272681892,
|
| 76 |
+
"grad_norm": 0.7376399636268616,
|
| 77 |
+
"learning_rate": 2.5e-06,
|
| 78 |
+
"loss": 1.5888,
|
| 79 |
+
"step": 10
|
| 80 |
+
},
|
| 81 |
+
{
|
| 82 |
+
"epoch": 0.02196430799950081,
|
| 83 |
+
"grad_norm": 0.7043939828872681,
|
| 84 |
+
"learning_rate": 2.7500000000000004e-06,
|
| 85 |
+
"loss": 1.5691,
|
| 86 |
+
"step": 11
|
| 87 |
+
},
|
| 88 |
+
{
|
| 89 |
+
"epoch": 0.023961063272182705,
|
| 90 |
+
"grad_norm": 0.8563888072967529,
|
| 91 |
+
"learning_rate": 3e-06,
|
| 92 |
+
"loss": 1.5439,
|
| 93 |
+
"step": 12
|
| 94 |
+
},
|
| 95 |
+
{
|
| 96 |
+
"epoch": 0.025957818544864595,
|
| 97 |
+
"grad_norm": 0.7369752526283264,
|
| 98 |
+
"learning_rate": 3.2500000000000002e-06,
|
| 99 |
+
"loss": 1.5735,
|
| 100 |
+
"step": 13
|
| 101 |
+
},
|
| 102 |
+
{
|
| 103 |
+
"epoch": 0.027954573817546485,
|
| 104 |
+
"grad_norm": 0.7235389351844788,
|
| 105 |
+
"learning_rate": 3.5e-06,
|
| 106 |
+
"loss": 1.5216,
|
| 107 |
+
"step": 14
|
| 108 |
+
},
|
| 109 |
+
{
|
| 110 |
+
"epoch": 0.02995132909022838,
|
| 111 |
+
"grad_norm": 0.7691176533699036,
|
| 112 |
+
"learning_rate": 3.7500000000000005e-06,
|
| 113 |
+
"loss": 1.5382,
|
| 114 |
+
"step": 15
|
| 115 |
+
},
|
| 116 |
+
{
|
| 117 |
+
"epoch": 0.03194808436291027,
|
| 118 |
+
"grad_norm": 1.0237406492233276,
|
| 119 |
+
"learning_rate": 4.000000000000001e-06,
|
| 120 |
+
"loss": 1.5465,
|
| 121 |
+
"step": 16
|
| 122 |
+
},
|
| 123 |
+
{
|
| 124 |
+
"epoch": 0.03394483963559216,
|
| 125 |
+
"grad_norm": 0.7893355488777161,
|
| 126 |
+
"learning_rate": 4.25e-06,
|
| 127 |
+
"loss": 1.5353,
|
| 128 |
+
"step": 17
|
| 129 |
+
},
|
| 130 |
+
{
|
| 131 |
+
"epoch": 0.035941594908274054,
|
| 132 |
+
"grad_norm": 1.089913010597229,
|
| 133 |
+
"learning_rate": 4.5e-06,
|
| 134 |
+
"loss": 1.5779,
|
| 135 |
+
"step": 18
|
| 136 |
+
},
|
| 137 |
+
{
|
| 138 |
+
"epoch": 0.03793835018095595,
|
| 139 |
+
"grad_norm": 0.7530987858772278,
|
| 140 |
+
"learning_rate": 4.75e-06,
|
| 141 |
+
"loss": 1.5248,
|
| 142 |
+
"step": 19
|
| 143 |
+
},
|
| 144 |
+
{
|
| 145 |
+
"epoch": 0.03993510545363784,
|
| 146 |
+
"grad_norm": 0.8638855814933777,
|
| 147 |
+
"learning_rate": 5e-06,
|
| 148 |
+
"loss": 1.5888,
|
| 149 |
+
"step": 20
|
| 150 |
+
},
|
| 151 |
+
{
|
| 152 |
+
"epoch": 0.04193186072631973,
|
| 153 |
+
"grad_norm": 0.9727922081947327,
|
| 154 |
+
"learning_rate": 5.2500000000000006e-06,
|
| 155 |
+
"loss": 1.5495,
|
| 156 |
+
"step": 21
|
| 157 |
+
},
|
| 158 |
+
{
|
| 159 |
+
"epoch": 0.04392861599900162,
|
| 160 |
+
"grad_norm": 0.9645998477935791,
|
| 161 |
+
"learning_rate": 5.500000000000001e-06,
|
| 162 |
+
"loss": 1.5365,
|
| 163 |
+
"step": 22
|
| 164 |
+
},
|
| 165 |
+
{
|
| 166 |
+
"epoch": 0.045925371271683516,
|
| 167 |
+
"grad_norm": 1.1736634969711304,
|
| 168 |
+
"learning_rate": 5.75e-06,
|
| 169 |
+
"loss": 1.5407,
|
| 170 |
+
"step": 23
|
| 171 |
+
},
|
| 172 |
+
{
|
| 173 |
+
"epoch": 0.04792212654436541,
|
| 174 |
+
"grad_norm": 1.091434121131897,
|
| 175 |
+
"learning_rate": 6e-06,
|
| 176 |
+
"loss": 1.5231,
|
| 177 |
+
"step": 24
|
| 178 |
+
},
|
| 179 |
+
{
|
| 180 |
+
"epoch": 0.049918881817047296,
|
| 181 |
+
"grad_norm": 1.1759644746780396,
|
| 182 |
+
"learning_rate": 6.25e-06,
|
| 183 |
+
"loss": 1.4901,
|
| 184 |
+
"step": 25
|
| 185 |
+
},
|
| 186 |
+
{
|
| 187 |
+
"epoch": 0.05191563708972919,
|
| 188 |
+
"grad_norm": 1.1277236938476562,
|
| 189 |
+
"learning_rate": 6.5000000000000004e-06,
|
| 190 |
+
"loss": 1.5326,
|
| 191 |
+
"step": 26
|
| 192 |
+
},
|
| 193 |
+
{
|
| 194 |
+
"epoch": 0.053912392362411084,
|
| 195 |
+
"grad_norm": 0.863665759563446,
|
| 196 |
+
"learning_rate": 6.750000000000001e-06,
|
| 197 |
+
"loss": 1.5185,
|
| 198 |
+
"step": 27
|
| 199 |
+
},
|
| 200 |
+
{
|
| 201 |
+
"epoch": 0.05590914763509297,
|
| 202 |
+
"grad_norm": 0.5838161706924438,
|
| 203 |
+
"learning_rate": 7e-06,
|
| 204 |
+
"loss": 1.5053,
|
| 205 |
+
"step": 28
|
| 206 |
+
},
|
| 207 |
+
{
|
| 208 |
+
"epoch": 0.057905902907774864,
|
| 209 |
+
"grad_norm": 0.541231095790863,
|
| 210 |
+
"learning_rate": 7.25e-06,
|
| 211 |
+
"loss": 1.4914,
|
| 212 |
+
"step": 29
|
| 213 |
+
},
|
| 214 |
+
{
|
| 215 |
+
"epoch": 0.05990265818045676,
|
| 216 |
+
"grad_norm": 0.5768315196037292,
|
| 217 |
+
"learning_rate": 7.500000000000001e-06,
|
| 218 |
+
"loss": 1.5208,
|
| 219 |
+
"step": 30
|
| 220 |
+
},
|
| 221 |
+
{
|
| 222 |
+
"epoch": 0.06189941345313865,
|
| 223 |
+
"grad_norm": 0.5609717965126038,
|
| 224 |
+
"learning_rate": 7.75e-06,
|
| 225 |
+
"loss": 1.4928,
|
| 226 |
+
"step": 31
|
| 227 |
+
},
|
| 228 |
+
{
|
| 229 |
+
"epoch": 0.06389616872582055,
|
| 230 |
+
"grad_norm": 0.5491043329238892,
|
| 231 |
+
"learning_rate": 8.000000000000001e-06,
|
| 232 |
+
"loss": 1.5208,
|
| 233 |
+
"step": 32
|
| 234 |
+
},
|
| 235 |
+
{
|
| 236 |
+
"epoch": 0.06589292399850244,
|
| 237 |
+
"grad_norm": 0.4885888695716858,
|
| 238 |
+
"learning_rate": 8.25e-06,
|
| 239 |
+
"loss": 1.4811,
|
| 240 |
+
"step": 33
|
| 241 |
+
},
|
| 242 |
+
{
|
| 243 |
+
"epoch": 0.06788967927118432,
|
| 244 |
+
"grad_norm": 0.5466718077659607,
|
| 245 |
+
"learning_rate": 8.5e-06,
|
| 246 |
+
"loss": 1.4608,
|
| 247 |
+
"step": 34
|
| 248 |
+
},
|
| 249 |
+
{
|
| 250 |
+
"epoch": 0.06988643454386621,
|
| 251 |
+
"grad_norm": 0.8744406700134277,
|
| 252 |
+
"learning_rate": 8.750000000000001e-06,
|
| 253 |
+
"loss": 1.465,
|
| 254 |
+
"step": 35
|
| 255 |
+
},
|
| 256 |
+
{
|
| 257 |
+
"epoch": 0.07188318981654811,
|
| 258 |
+
"grad_norm": 0.7382685542106628,
|
| 259 |
+
"learning_rate": 9e-06,
|
| 260 |
+
"loss": 1.454,
|
| 261 |
+
"step": 36
|
| 262 |
+
},
|
| 263 |
+
{
|
| 264 |
+
"epoch": 0.07387994508923,
|
| 265 |
+
"grad_norm": 0.6689203977584839,
|
| 266 |
+
"learning_rate": 9.250000000000001e-06,
|
| 267 |
+
"loss": 1.4707,
|
| 268 |
+
"step": 37
|
| 269 |
+
},
|
| 270 |
+
{
|
| 271 |
+
"epoch": 0.0758767003619119,
|
| 272 |
+
"grad_norm": 0.4725808799266815,
|
| 273 |
+
"learning_rate": 9.5e-06,
|
| 274 |
+
"loss": 1.4593,
|
| 275 |
+
"step": 38
|
| 276 |
+
},
|
| 277 |
+
{
|
| 278 |
+
"epoch": 0.07787345563459379,
|
| 279 |
+
"grad_norm": 0.4035033881664276,
|
| 280 |
+
"learning_rate": 9.75e-06,
|
| 281 |
+
"loss": 1.3955,
|
| 282 |
+
"step": 39
|
| 283 |
+
},
|
| 284 |
+
{
|
| 285 |
+
"epoch": 0.07987021090727568,
|
| 286 |
+
"grad_norm": 0.36325860023498535,
|
| 287 |
+
"learning_rate": 1e-05,
|
| 288 |
+
"loss": 1.4006,
|
| 289 |
+
"step": 40
|
| 290 |
+
},
|
| 291 |
+
{
|
| 292 |
+
"epoch": 0.08186696617995756,
|
| 293 |
+
"grad_norm": 0.33312714099884033,
|
| 294 |
+
"learning_rate": 9.993150684931508e-06,
|
| 295 |
+
"loss": 1.4212,
|
| 296 |
+
"step": 41
|
| 297 |
+
},
|
| 298 |
+
{
|
| 299 |
+
"epoch": 0.08386372145263946,
|
| 300 |
+
"grad_norm": 0.3342682719230652,
|
| 301 |
+
"learning_rate": 9.986301369863014e-06,
|
| 302 |
+
"loss": 1.4458,
|
| 303 |
+
"step": 42
|
| 304 |
+
},
|
| 305 |
+
{
|
| 306 |
+
"epoch": 0.08586047672532135,
|
| 307 |
+
"grad_norm": 0.4984380900859833,
|
| 308 |
+
"learning_rate": 9.979452054794521e-06,
|
| 309 |
+
"loss": 1.3925,
|
| 310 |
+
"step": 43
|
| 311 |
+
},
|
| 312 |
+
{
|
| 313 |
+
"epoch": 0.08785723199800324,
|
| 314 |
+
"grad_norm": 0.36669808626174927,
|
| 315 |
+
"learning_rate": 9.972602739726028e-06,
|
| 316 |
+
"loss": 1.3997,
|
| 317 |
+
"step": 44
|
| 318 |
+
},
|
| 319 |
+
{
|
| 320 |
+
"epoch": 0.08985398727068514,
|
| 321 |
+
"grad_norm": 0.3464302122592926,
|
| 322 |
+
"learning_rate": 9.965753424657536e-06,
|
| 323 |
+
"loss": 1.4019,
|
| 324 |
+
"step": 45
|
| 325 |
+
},
|
| 326 |
+
{
|
| 327 |
+
"epoch": 0.09185074254336703,
|
| 328 |
+
"grad_norm": 0.36931392550468445,
|
| 329 |
+
"learning_rate": 9.958904109589041e-06,
|
| 330 |
+
"loss": 1.3793,
|
| 331 |
+
"step": 46
|
| 332 |
+
},
|
| 333 |
+
{
|
| 334 |
+
"epoch": 0.09384749781604892,
|
| 335 |
+
"grad_norm": 0.35277390480041504,
|
| 336 |
+
"learning_rate": 9.952054794520548e-06,
|
| 337 |
+
"loss": 1.3854,
|
| 338 |
+
"step": 47
|
| 339 |
+
},
|
| 340 |
+
{
|
| 341 |
+
"epoch": 0.09584425308873082,
|
| 342 |
+
"grad_norm": 0.3395546078681946,
|
| 343 |
+
"learning_rate": 9.945205479452056e-06,
|
| 344 |
+
"loss": 1.3622,
|
| 345 |
+
"step": 48
|
| 346 |
+
},
|
| 347 |
+
{
|
| 348 |
+
"epoch": 0.0978410083614127,
|
| 349 |
+
"grad_norm": 0.37092125415802,
|
| 350 |
+
"learning_rate": 9.938356164383563e-06,
|
| 351 |
+
"loss": 1.347,
|
| 352 |
+
"step": 49
|
| 353 |
+
},
|
| 354 |
+
{
|
| 355 |
+
"epoch": 0.09983776363409459,
|
| 356 |
+
"grad_norm": 0.3518228232860565,
|
| 357 |
+
"learning_rate": 9.931506849315069e-06,
|
| 358 |
+
"loss": 1.3419,
|
| 359 |
+
"step": 50
|
| 360 |
+
},
|
| 361 |
+
{
|
| 362 |
+
"epoch": 0.10183451890677649,
|
| 363 |
+
"grad_norm": 0.3498891294002533,
|
| 364 |
+
"learning_rate": 9.924657534246576e-06,
|
| 365 |
+
"loss": 1.3374,
|
| 366 |
+
"step": 51
|
| 367 |
+
},
|
| 368 |
+
{
|
| 369 |
+
"epoch": 0.10383127417945838,
|
| 370 |
+
"grad_norm": 0.35601961612701416,
|
| 371 |
+
"learning_rate": 9.917808219178083e-06,
|
| 372 |
+
"loss": 1.3229,
|
| 373 |
+
"step": 52
|
| 374 |
+
},
|
| 375 |
+
{
|
| 376 |
+
"epoch": 0.10582802945214027,
|
| 377 |
+
"grad_norm": 0.3646593391895294,
|
| 378 |
+
"learning_rate": 9.91095890410959e-06,
|
| 379 |
+
"loss": 1.3361,
|
| 380 |
+
"step": 53
|
| 381 |
+
},
|
| 382 |
+
{
|
| 383 |
+
"epoch": 0.10782478472482217,
|
| 384 |
+
"grad_norm": 0.37503260374069214,
|
| 385 |
+
"learning_rate": 9.904109589041096e-06,
|
| 386 |
+
"loss": 1.3202,
|
| 387 |
+
"step": 54
|
| 388 |
+
},
|
| 389 |
+
{
|
| 390 |
+
"epoch": 0.10982153999750406,
|
| 391 |
+
"grad_norm": 0.36810755729675293,
|
| 392 |
+
"learning_rate": 9.897260273972603e-06,
|
| 393 |
+
"loss": 1.3012,
|
| 394 |
+
"step": 55
|
| 395 |
+
},
|
| 396 |
+
{
|
| 397 |
+
"epoch": 0.11181829527018594,
|
| 398 |
+
"grad_norm": 0.38846829533576965,
|
| 399 |
+
"learning_rate": 9.89041095890411e-06,
|
| 400 |
+
"loss": 1.2971,
|
| 401 |
+
"step": 56
|
| 402 |
+
},
|
| 403 |
+
{
|
| 404 |
+
"epoch": 0.11381505054286783,
|
| 405 |
+
"grad_norm": 0.3800796866416931,
|
| 406 |
+
"learning_rate": 9.883561643835618e-06,
|
| 407 |
+
"loss": 1.2568,
|
| 408 |
+
"step": 57
|
| 409 |
+
},
|
| 410 |
+
{
|
| 411 |
+
"epoch": 0.11581180581554973,
|
| 412 |
+
"grad_norm": 0.44192200899124146,
|
| 413 |
+
"learning_rate": 9.876712328767123e-06,
|
| 414 |
+
"loss": 1.2972,
|
| 415 |
+
"step": 58
|
| 416 |
+
},
|
| 417 |
+
{
|
| 418 |
+
"epoch": 0.11780856108823162,
|
| 419 |
+
"grad_norm": 0.4018876254558563,
|
| 420 |
+
"learning_rate": 9.86986301369863e-06,
|
| 421 |
+
"loss": 1.2712,
|
| 422 |
+
"step": 59
|
| 423 |
+
},
|
| 424 |
+
{
|
| 425 |
+
"epoch": 0.11980531636091352,
|
| 426 |
+
"grad_norm": 0.40182632207870483,
|
| 427 |
+
"learning_rate": 9.863013698630138e-06,
|
| 428 |
+
"loss": 1.2547,
|
| 429 |
+
"step": 60
|
| 430 |
+
},
|
| 431 |
+
{
|
| 432 |
+
"epoch": 0.12180207163359541,
|
| 433 |
+
"grad_norm": 0.40880608558654785,
|
| 434 |
+
"learning_rate": 9.856164383561645e-06,
|
| 435 |
+
"loss": 1.2776,
|
| 436 |
+
"step": 61
|
| 437 |
+
},
|
| 438 |
+
{
|
| 439 |
+
"epoch": 0.1237988269062773,
|
| 440 |
+
"grad_norm": 0.404816597700119,
|
| 441 |
+
"learning_rate": 9.849315068493151e-06,
|
| 442 |
+
"loss": 1.2258,
|
| 443 |
+
"step": 62
|
| 444 |
+
},
|
| 445 |
+
{
|
| 446 |
+
"epoch": 0.1257955821789592,
|
| 447 |
+
"grad_norm": 0.4100593030452728,
|
| 448 |
+
"learning_rate": 9.842465753424658e-06,
|
| 449 |
+
"loss": 1.228,
|
| 450 |
+
"step": 63
|
| 451 |
+
},
|
| 452 |
+
{
|
| 453 |
+
"epoch": 0.1277923374516411,
|
| 454 |
+
"grad_norm": 0.4166107773780823,
|
| 455 |
+
"learning_rate": 9.835616438356166e-06,
|
| 456 |
+
"loss": 1.1834,
|
| 457 |
+
"step": 64
|
| 458 |
+
},
|
| 459 |
+
{
|
| 460 |
+
"epoch": 0.12978909272432299,
|
| 461 |
+
"grad_norm": 0.44978272914886475,
|
| 462 |
+
"learning_rate": 9.828767123287673e-06,
|
| 463 |
+
"loss": 1.1874,
|
| 464 |
+
"step": 65
|
| 465 |
+
},
|
| 466 |
+
{
|
| 467 |
+
"epoch": 0.13178584799700488,
|
| 468 |
+
"grad_norm": 0.4174051582813263,
|
| 469 |
+
"learning_rate": 9.821917808219178e-06,
|
| 470 |
+
"loss": 1.1884,
|
| 471 |
+
"step": 66
|
| 472 |
+
},
|
| 473 |
+
{
|
| 474 |
+
"epoch": 0.13378260326968677,
|
| 475 |
+
"grad_norm": 0.453905314207077,
|
| 476 |
+
"learning_rate": 9.815068493150686e-06,
|
| 477 |
+
"loss": 1.1646,
|
| 478 |
+
"step": 67
|
| 479 |
+
},
|
| 480 |
+
{
|
| 481 |
+
"epoch": 0.13577935854236864,
|
| 482 |
+
"grad_norm": 0.5017035007476807,
|
| 483 |
+
"learning_rate": 9.808219178082193e-06,
|
| 484 |
+
"loss": 1.1491,
|
| 485 |
+
"step": 68
|
| 486 |
+
},
|
| 487 |
+
{
|
| 488 |
+
"epoch": 0.13777611381505053,
|
| 489 |
+
"grad_norm": 0.44494616985321045,
|
| 490 |
+
"learning_rate": 9.8013698630137e-06,
|
| 491 |
+
"loss": 1.1516,
|
| 492 |
+
"step": 69
|
| 493 |
+
},
|
| 494 |
+
{
|
| 495 |
+
"epoch": 0.13977286908773243,
|
| 496 |
+
"grad_norm": 0.43786314129829407,
|
| 497 |
+
"learning_rate": 9.794520547945206e-06,
|
| 498 |
+
"loss": 1.1131,
|
| 499 |
+
"step": 70
|
| 500 |
+
},
|
| 501 |
+
{
|
| 502 |
+
"epoch": 0.14176962436041432,
|
| 503 |
+
"grad_norm": 0.4679386615753174,
|
| 504 |
+
"learning_rate": 9.787671232876713e-06,
|
| 505 |
+
"loss": 1.1154,
|
| 506 |
+
"step": 71
|
| 507 |
+
},
|
| 508 |
+
{
|
| 509 |
+
"epoch": 0.14376637963309621,
|
| 510 |
+
"grad_norm": 0.4783805310726166,
|
| 511 |
+
"learning_rate": 9.78082191780822e-06,
|
| 512 |
+
"loss": 1.1102,
|
| 513 |
+
"step": 72
|
| 514 |
+
},
|
| 515 |
+
{
|
| 516 |
+
"epoch": 0.1457631349057781,
|
| 517 |
+
"grad_norm": 0.4883531332015991,
|
| 518 |
+
"learning_rate": 9.773972602739726e-06,
|
| 519 |
+
"loss": 1.0969,
|
| 520 |
+
"step": 73
|
| 521 |
+
},
|
| 522 |
+
{
|
| 523 |
+
"epoch": 0.14775989017846,
|
| 524 |
+
"grad_norm": 0.497222363948822,
|
| 525 |
+
"learning_rate": 9.767123287671233e-06,
|
| 526 |
+
"loss": 1.0894,
|
| 527 |
+
"step": 74
|
| 528 |
+
},
|
| 529 |
+
{
|
| 530 |
+
"epoch": 0.1497566454511419,
|
| 531 |
+
"grad_norm": 0.5368260741233826,
|
| 532 |
+
"learning_rate": 9.76027397260274e-06,
|
| 533 |
+
"loss": 1.0872,
|
| 534 |
+
"step": 75
|
| 535 |
+
},
|
| 536 |
+
{
|
| 537 |
+
"epoch": 0.1517534007238238,
|
| 538 |
+
"grad_norm": 0.5358818173408508,
|
| 539 |
+
"learning_rate": 9.753424657534248e-06,
|
| 540 |
+
"loss": 1.0771,
|
| 541 |
+
"step": 76
|
| 542 |
+
},
|
| 543 |
+
{
|
| 544 |
+
"epoch": 0.15375015599650568,
|
| 545 |
+
"grad_norm": 0.5469568371772766,
|
| 546 |
+
"learning_rate": 9.746575342465753e-06,
|
| 547 |
+
"loss": 1.0142,
|
| 548 |
+
"step": 77
|
| 549 |
+
},
|
| 550 |
+
{
|
| 551 |
+
"epoch": 0.15574691126918758,
|
| 552 |
+
"grad_norm": 0.5410879254341125,
|
| 553 |
+
"learning_rate": 9.73972602739726e-06,
|
| 554 |
+
"loss": 1.0019,
|
| 555 |
+
"step": 78
|
| 556 |
+
},
|
| 557 |
+
{
|
| 558 |
+
"epoch": 0.15774366654186947,
|
| 559 |
+
"grad_norm": 0.5405011177062988,
|
| 560 |
+
"learning_rate": 9.732876712328768e-06,
|
| 561 |
+
"loss": 0.9998,
|
| 562 |
+
"step": 79
|
| 563 |
+
},
|
| 564 |
+
{
|
| 565 |
+
"epoch": 0.15974042181455136,
|
| 566 |
+
"grad_norm": 0.532302737236023,
|
| 567 |
+
"learning_rate": 9.726027397260275e-06,
|
| 568 |
+
"loss": 0.9659,
|
| 569 |
+
"step": 80
|
| 570 |
+
},
|
| 571 |
+
{
|
| 572 |
+
"epoch": 0.16173717708723326,
|
| 573 |
+
"grad_norm": 0.5053435564041138,
|
| 574 |
+
"learning_rate": 9.719178082191781e-06,
|
| 575 |
+
"loss": 0.9679,
|
| 576 |
+
"step": 81
|
| 577 |
+
},
|
| 578 |
+
{
|
| 579 |
+
"epoch": 0.16373393235991512,
|
| 580 |
+
"grad_norm": 0.49565696716308594,
|
| 581 |
+
"learning_rate": 9.712328767123288e-06,
|
| 582 |
+
"loss": 0.9246,
|
| 583 |
+
"step": 82
|
| 584 |
+
},
|
| 585 |
+
{
|
| 586 |
+
"epoch": 0.16573068763259702,
|
| 587 |
+
"grad_norm": 0.5060250759124756,
|
| 588 |
+
"learning_rate": 9.705479452054795e-06,
|
| 589 |
+
"loss": 0.938,
|
| 590 |
+
"step": 83
|
| 591 |
+
},
|
| 592 |
+
{
|
| 593 |
+
"epoch": 0.1677274429052789,
|
| 594 |
+
"grad_norm": 0.4905273914337158,
|
| 595 |
+
"learning_rate": 9.698630136986303e-06,
|
| 596 |
+
"loss": 0.9137,
|
| 597 |
+
"step": 84
|
| 598 |
+
},
|
| 599 |
+
{
|
| 600 |
+
"epoch": 0.1697241981779608,
|
| 601 |
+
"grad_norm": 0.6356221437454224,
|
| 602 |
+
"learning_rate": 9.691780821917808e-06,
|
| 603 |
+
"loss": 0.8919,
|
| 604 |
+
"step": 85
|
| 605 |
+
},
|
| 606 |
+
{
|
| 607 |
+
"epoch": 0.1717209534506427,
|
| 608 |
+
"grad_norm": 0.5084801316261292,
|
| 609 |
+
"learning_rate": 9.684931506849316e-06,
|
| 610 |
+
"loss": 0.9097,
|
| 611 |
+
"step": 86
|
| 612 |
+
},
|
| 613 |
+
{
|
| 614 |
+
"epoch": 0.1737177087233246,
|
| 615 |
+
"grad_norm": 0.44582366943359375,
|
| 616 |
+
"learning_rate": 9.678082191780823e-06,
|
| 617 |
+
"loss": 0.849,
|
| 618 |
+
"step": 87
|
| 619 |
+
},
|
| 620 |
+
{
|
| 621 |
+
"epoch": 0.1757144639960065,
|
| 622 |
+
"grad_norm": 0.45911890268325806,
|
| 623 |
+
"learning_rate": 9.67123287671233e-06,
|
| 624 |
+
"loss": 0.8481,
|
| 625 |
+
"step": 88
|
| 626 |
+
},
|
| 627 |
+
{
|
| 628 |
+
"epoch": 0.17771121926868838,
|
| 629 |
+
"grad_norm": 0.44006654620170593,
|
| 630 |
+
"learning_rate": 9.664383561643836e-06,
|
| 631 |
+
"loss": 0.8248,
|
| 632 |
+
"step": 89
|
| 633 |
+
},
|
| 634 |
+
{
|
| 635 |
+
"epoch": 0.17970797454137027,
|
| 636 |
+
"grad_norm": 0.4369649589061737,
|
| 637 |
+
"learning_rate": 9.657534246575343e-06,
|
| 638 |
+
"loss": 0.8159,
|
| 639 |
+
"step": 90
|
| 640 |
+
},
|
| 641 |
+
{
|
| 642 |
+
"epoch": 0.18170472981405217,
|
| 643 |
+
"grad_norm": 0.407516747713089,
|
| 644 |
+
"learning_rate": 9.65068493150685e-06,
|
| 645 |
+
"loss": 0.8087,
|
| 646 |
+
"step": 91
|
| 647 |
+
},
|
| 648 |
+
{
|
| 649 |
+
"epoch": 0.18370148508673406,
|
| 650 |
+
"grad_norm": 0.403859943151474,
|
| 651 |
+
"learning_rate": 9.643835616438358e-06,
|
| 652 |
+
"loss": 0.8072,
|
| 653 |
+
"step": 92
|
| 654 |
+
},
|
| 655 |
+
{
|
| 656 |
+
"epoch": 0.18569824035941596,
|
| 657 |
+
"grad_norm": 0.39687636494636536,
|
| 658 |
+
"learning_rate": 9.636986301369863e-06,
|
| 659 |
+
"loss": 0.7441,
|
| 660 |
+
"step": 93
|
| 661 |
+
},
|
| 662 |
+
{
|
| 663 |
+
"epoch": 0.18769499563209785,
|
| 664 |
+
"grad_norm": 0.3767126202583313,
|
| 665 |
+
"learning_rate": 9.63013698630137e-06,
|
| 666 |
+
"loss": 0.7648,
|
| 667 |
+
"step": 94
|
| 668 |
+
},
|
| 669 |
+
{
|
| 670 |
+
"epoch": 0.18969175090477974,
|
| 671 |
+
"grad_norm": 0.361546128988266,
|
| 672 |
+
"learning_rate": 9.623287671232878e-06,
|
| 673 |
+
"loss": 0.7611,
|
| 674 |
+
"step": 95
|
| 675 |
+
},
|
| 676 |
+
{
|
| 677 |
+
"epoch": 0.19168850617746164,
|
| 678 |
+
"grad_norm": 0.34515851736068726,
|
| 679 |
+
"learning_rate": 9.616438356164385e-06,
|
| 680 |
+
"loss": 0.7625,
|
| 681 |
+
"step": 96
|
| 682 |
+
},
|
| 683 |
+
{
|
| 684 |
+
"epoch": 0.1936852614501435,
|
| 685 |
+
"grad_norm": 0.3361088037490845,
|
| 686 |
+
"learning_rate": 9.60958904109589e-06,
|
| 687 |
+
"loss": 0.7827,
|
| 688 |
+
"step": 97
|
| 689 |
+
},
|
| 690 |
+
{
|
| 691 |
+
"epoch": 0.1956820167228254,
|
| 692 |
+
"grad_norm": 0.3142891228199005,
|
| 693 |
+
"learning_rate": 9.602739726027398e-06,
|
| 694 |
+
"loss": 0.7339,
|
| 695 |
+
"step": 98
|
| 696 |
+
},
|
| 697 |
+
{
|
| 698 |
+
"epoch": 0.1976787719955073,
|
| 699 |
+
"grad_norm": 0.3227478265762329,
|
| 700 |
+
"learning_rate": 9.595890410958905e-06,
|
| 701 |
+
"loss": 0.7389,
|
| 702 |
+
"step": 99
|
| 703 |
+
},
|
| 704 |
+
{
|
| 705 |
+
"epoch": 0.19967552726818918,
|
| 706 |
+
"grad_norm": 0.3079572319984436,
|
| 707 |
+
"learning_rate": 9.589041095890411e-06,
|
| 708 |
+
"loss": 0.7268,
|
| 709 |
+
"step": 100
|
| 710 |
+
},
|
| 711 |
+
{
|
| 712 |
+
"epoch": 0.20167228254087108,
|
| 713 |
+
"grad_norm": 0.3069862127304077,
|
| 714 |
+
"learning_rate": 9.582191780821918e-06,
|
| 715 |
+
"loss": 0.7198,
|
| 716 |
+
"step": 101
|
| 717 |
+
},
|
| 718 |
+
{
|
| 719 |
+
"epoch": 0.20366903781355297,
|
| 720 |
+
"grad_norm": 0.29050567746162415,
|
| 721 |
+
"learning_rate": 9.575342465753425e-06,
|
| 722 |
+
"loss": 0.7549,
|
| 723 |
+
"step": 102
|
| 724 |
+
},
|
| 725 |
+
{
|
| 726 |
+
"epoch": 0.20566579308623487,
|
| 727 |
+
"grad_norm": 0.29106447100639343,
|
| 728 |
+
"learning_rate": 9.568493150684933e-06,
|
| 729 |
+
"loss": 0.7167,
|
| 730 |
+
"step": 103
|
| 731 |
+
},
|
| 732 |
+
{
|
| 733 |
+
"epoch": 0.20766254835891676,
|
| 734 |
+
"grad_norm": 0.2757619619369507,
|
| 735 |
+
"learning_rate": 9.561643835616438e-06,
|
| 736 |
+
"loss": 0.7239,
|
| 737 |
+
"step": 104
|
| 738 |
+
},
|
| 739 |
+
{
|
| 740 |
+
"epoch": 0.20965930363159865,
|
| 741 |
+
"grad_norm": 0.2644850015640259,
|
| 742 |
+
"learning_rate": 9.554794520547946e-06,
|
| 743 |
+
"loss": 0.7028,
|
| 744 |
+
"step": 105
|
| 745 |
+
},
|
| 746 |
+
{
|
| 747 |
+
"epoch": 0.21165605890428055,
|
| 748 |
+
"grad_norm": 0.2568458318710327,
|
| 749 |
+
"learning_rate": 9.547945205479453e-06,
|
| 750 |
+
"loss": 0.7312,
|
| 751 |
+
"step": 106
|
| 752 |
+
},
|
| 753 |
+
{
|
| 754 |
+
"epoch": 0.21365281417696244,
|
| 755 |
+
"grad_norm": 0.24979732930660248,
|
| 756 |
+
"learning_rate": 9.54109589041096e-06,
|
| 757 |
+
"loss": 0.6933,
|
| 758 |
+
"step": 107
|
| 759 |
+
},
|
| 760 |
+
{
|
| 761 |
+
"epoch": 0.21564956944964433,
|
| 762 |
+
"grad_norm": 0.2434425950050354,
|
| 763 |
+
"learning_rate": 9.534246575342466e-06,
|
| 764 |
+
"loss": 0.6824,
|
| 765 |
+
"step": 108
|
| 766 |
+
},
|
| 767 |
+
{
|
| 768 |
+
"epoch": 0.21764632472232623,
|
| 769 |
+
"grad_norm": 0.27341383695602417,
|
| 770 |
+
"learning_rate": 9.527397260273975e-06,
|
| 771 |
+
"loss": 0.6832,
|
| 772 |
+
"step": 109
|
| 773 |
+
},
|
| 774 |
+
{
|
| 775 |
+
"epoch": 0.21964307999500812,
|
| 776 |
+
"grad_norm": 0.22272831201553345,
|
| 777 |
+
"learning_rate": 9.52054794520548e-06,
|
| 778 |
+
"loss": 0.6889,
|
| 779 |
+
"step": 110
|
| 780 |
+
},
|
| 781 |
+
{
|
| 782 |
+
"epoch": 0.22163983526769002,
|
| 783 |
+
"grad_norm": 0.2114173024892807,
|
| 784 |
+
"learning_rate": 9.513698630136988e-06,
|
| 785 |
+
"loss": 0.7047,
|
| 786 |
+
"step": 111
|
| 787 |
+
},
|
| 788 |
+
{
|
| 789 |
+
"epoch": 0.22363659054037188,
|
| 790 |
+
"grad_norm": 0.20138710737228394,
|
| 791 |
+
"learning_rate": 9.506849315068493e-06,
|
| 792 |
+
"loss": 0.6926,
|
| 793 |
+
"step": 112
|
| 794 |
+
},
|
| 795 |
+
{
|
| 796 |
+
"epoch": 0.22563334581305378,
|
| 797 |
+
"grad_norm": 0.18181370198726654,
|
| 798 |
+
"learning_rate": 9.5e-06,
|
| 799 |
+
"loss": 0.7121,
|
| 800 |
+
"step": 113
|
| 801 |
+
},
|
| 802 |
+
{
|
| 803 |
+
"epoch": 0.22763010108573567,
|
| 804 |
+
"grad_norm": 0.16511252522468567,
|
| 805 |
+
"learning_rate": 9.493150684931508e-06,
|
| 806 |
+
"loss": 0.6879,
|
| 807 |
+
"step": 114
|
| 808 |
+
},
|
| 809 |
+
{
|
| 810 |
+
"epoch": 0.22962685635841756,
|
| 811 |
+
"grad_norm": 0.15935856103897095,
|
| 812 |
+
"learning_rate": 9.486301369863015e-06,
|
| 813 |
+
"loss": 0.692,
|
| 814 |
+
"step": 115
|
| 815 |
+
},
|
| 816 |
+
{
|
| 817 |
+
"epoch": 0.23162361163109946,
|
| 818 |
+
"grad_norm": 0.15437360107898712,
|
| 819 |
+
"learning_rate": 9.47945205479452e-06,
|
| 820 |
+
"loss": 0.6365,
|
| 821 |
+
"step": 116
|
| 822 |
+
},
|
| 823 |
+
{
|
| 824 |
+
"epoch": 0.23362036690378135,
|
| 825 |
+
"grad_norm": 0.15790362656116486,
|
| 826 |
+
"learning_rate": 9.472602739726028e-06,
|
| 827 |
+
"loss": 0.6734,
|
| 828 |
+
"step": 117
|
| 829 |
+
},
|
| 830 |
+
{
|
| 831 |
+
"epoch": 0.23561712217646325,
|
| 832 |
+
"grad_norm": 0.1540212631225586,
|
| 833 |
+
"learning_rate": 9.465753424657535e-06,
|
| 834 |
+
"loss": 0.6785,
|
| 835 |
+
"step": 118
|
| 836 |
+
},
|
| 837 |
+
{
|
| 838 |
+
"epoch": 0.23761387744914514,
|
| 839 |
+
"grad_norm": 0.14174145460128784,
|
| 840 |
+
"learning_rate": 9.458904109589043e-06,
|
| 841 |
+
"loss": 0.662,
|
| 842 |
+
"step": 119
|
| 843 |
+
},
|
| 844 |
+
{
|
| 845 |
+
"epoch": 0.23961063272182703,
|
| 846 |
+
"grad_norm": 0.13557200133800507,
|
| 847 |
+
"learning_rate": 9.452054794520548e-06,
|
| 848 |
+
"loss": 0.6576,
|
| 849 |
+
"step": 120
|
| 850 |
+
},
|
| 851 |
+
{
|
| 852 |
+
"epoch": 0.24160738799450893,
|
| 853 |
+
"grad_norm": 0.13709504902362823,
|
| 854 |
+
"learning_rate": 9.445205479452055e-06,
|
| 855 |
+
"loss": 0.6776,
|
| 856 |
+
"step": 121
|
| 857 |
+
},
|
| 858 |
+
{
|
| 859 |
+
"epoch": 0.24360414326719082,
|
| 860 |
+
"grad_norm": 0.13799452781677246,
|
| 861 |
+
"learning_rate": 9.438356164383563e-06,
|
| 862 |
+
"loss": 0.6678,
|
| 863 |
+
"step": 122
|
| 864 |
+
},
|
| 865 |
+
{
|
| 866 |
+
"epoch": 0.24560089853987271,
|
| 867 |
+
"grad_norm": 0.13457225263118744,
|
| 868 |
+
"learning_rate": 9.43150684931507e-06,
|
| 869 |
+
"loss": 0.678,
|
| 870 |
+
"step": 123
|
| 871 |
+
},
|
| 872 |
+
{
|
| 873 |
+
"epoch": 0.2475976538125546,
|
| 874 |
+
"grad_norm": 0.12947948276996613,
|
| 875 |
+
"learning_rate": 9.424657534246576e-06,
|
| 876 |
+
"loss": 0.6735,
|
| 877 |
+
"step": 124
|
| 878 |
+
},
|
| 879 |
+
{
|
| 880 |
+
"epoch": 0.2495944090852365,
|
| 881 |
+
"grad_norm": 0.12308862805366516,
|
| 882 |
+
"learning_rate": 9.417808219178083e-06,
|
| 883 |
+
"loss": 0.6912,
|
| 884 |
+
"step": 125
|
| 885 |
+
},
|
| 886 |
+
{
|
| 887 |
+
"epoch": 0.2515911643579184,
|
| 888 |
+
"grad_norm": 0.14674226939678192,
|
| 889 |
+
"learning_rate": 9.41095890410959e-06,
|
| 890 |
+
"loss": 0.6533,
|
| 891 |
+
"step": 126
|
| 892 |
+
},
|
| 893 |
+
{
|
| 894 |
+
"epoch": 0.2535879196306003,
|
| 895 |
+
"grad_norm": 0.12698639929294586,
|
| 896 |
+
"learning_rate": 9.404109589041097e-06,
|
| 897 |
+
"loss": 0.6876,
|
| 898 |
+
"step": 127
|
| 899 |
+
},
|
| 900 |
+
{
|
| 901 |
+
"epoch": 0.2555846749032822,
|
| 902 |
+
"grad_norm": 0.11984587460756302,
|
| 903 |
+
"learning_rate": 9.397260273972603e-06,
|
| 904 |
+
"loss": 0.6555,
|
| 905 |
+
"step": 128
|
| 906 |
+
},
|
| 907 |
+
{
|
| 908 |
+
"epoch": 0.2575814301759641,
|
| 909 |
+
"grad_norm": 0.11617796868085861,
|
| 910 |
+
"learning_rate": 9.39041095890411e-06,
|
| 911 |
+
"loss": 0.6641,
|
| 912 |
+
"step": 129
|
| 913 |
+
},
|
| 914 |
+
{
|
| 915 |
+
"epoch": 0.25957818544864597,
|
| 916 |
+
"grad_norm": 0.11317376047372818,
|
| 917 |
+
"learning_rate": 9.383561643835618e-06,
|
| 918 |
+
"loss": 0.6563,
|
| 919 |
+
"step": 130
|
| 920 |
+
},
|
| 921 |
+
{
|
| 922 |
+
"epoch": 0.26157494072132786,
|
| 923 |
+
"grad_norm": 0.12450871616601944,
|
| 924 |
+
"learning_rate": 9.376712328767123e-06,
|
| 925 |
+
"loss": 0.6778,
|
| 926 |
+
"step": 131
|
| 927 |
+
},
|
| 928 |
+
{
|
| 929 |
+
"epoch": 0.26357169599400976,
|
| 930 |
+
"grad_norm": 0.11382495611906052,
|
| 931 |
+
"learning_rate": 9.36986301369863e-06,
|
| 932 |
+
"loss": 0.6472,
|
| 933 |
+
"step": 132
|
| 934 |
+
},
|
| 935 |
+
{
|
| 936 |
+
"epoch": 0.26556845126669165,
|
| 937 |
+
"grad_norm": 0.11967656016349792,
|
| 938 |
+
"learning_rate": 9.363013698630138e-06,
|
| 939 |
+
"loss": 0.6584,
|
| 940 |
+
"step": 133
|
| 941 |
+
},
|
| 942 |
+
{
|
| 943 |
+
"epoch": 0.26756520653937355,
|
| 944 |
+
"grad_norm": 0.10746151208877563,
|
| 945 |
+
"learning_rate": 9.356164383561645e-06,
|
| 946 |
+
"loss": 0.6605,
|
| 947 |
+
"step": 134
|
| 948 |
+
},
|
| 949 |
+
{
|
| 950 |
+
"epoch": 0.2695619618120554,
|
| 951 |
+
"grad_norm": 0.11343806982040405,
|
| 952 |
+
"learning_rate": 9.34931506849315e-06,
|
| 953 |
+
"loss": 0.6699,
|
| 954 |
+
"step": 135
|
| 955 |
+
},
|
| 956 |
+
{
|
| 957 |
+
"epoch": 0.2715587170847373,
|
| 958 |
+
"grad_norm": 0.10874643176794052,
|
| 959 |
+
"learning_rate": 9.342465753424658e-06,
|
| 960 |
+
"loss": 0.6396,
|
| 961 |
+
"step": 136
|
| 962 |
+
},
|
| 963 |
+
{
|
| 964 |
+
"epoch": 0.27355547235741917,
|
| 965 |
+
"grad_norm": 0.11221782863140106,
|
| 966 |
+
"learning_rate": 9.335616438356165e-06,
|
| 967 |
+
"loss": 0.6517,
|
| 968 |
+
"step": 137
|
| 969 |
+
},
|
| 970 |
+
{
|
| 971 |
+
"epoch": 0.27555222763010107,
|
| 972 |
+
"grad_norm": 0.12015150487422943,
|
| 973 |
+
"learning_rate": 9.328767123287673e-06,
|
| 974 |
+
"loss": 0.6561,
|
| 975 |
+
"step": 138
|
| 976 |
+
},
|
| 977 |
+
{
|
| 978 |
+
"epoch": 0.27754898290278296,
|
| 979 |
+
"grad_norm": 0.10812759399414062,
|
| 980 |
+
"learning_rate": 9.321917808219178e-06,
|
| 981 |
+
"loss": 0.6505,
|
| 982 |
+
"step": 139
|
| 983 |
+
},
|
| 984 |
+
{
|
| 985 |
+
"epoch": 0.27954573817546485,
|
| 986 |
+
"grad_norm": 0.10647746920585632,
|
| 987 |
+
"learning_rate": 9.315068493150685e-06,
|
| 988 |
+
"loss": 0.6433,
|
| 989 |
+
"step": 140
|
| 990 |
+
},
|
| 991 |
+
{
|
| 992 |
+
"epoch": 0.28154249344814675,
|
| 993 |
+
"grad_norm": 0.10739017277956009,
|
| 994 |
+
"learning_rate": 9.308219178082193e-06,
|
| 995 |
+
"loss": 0.6504,
|
| 996 |
+
"step": 141
|
| 997 |
+
},
|
| 998 |
+
{
|
| 999 |
+
"epoch": 0.28353924872082864,
|
| 1000 |
+
"grad_norm": 0.09796225279569626,
|
| 1001 |
+
"learning_rate": 9.3013698630137e-06,
|
| 1002 |
+
"loss": 0.6766,
|
| 1003 |
+
"step": 142
|
| 1004 |
+
},
|
| 1005 |
+
{
|
| 1006 |
+
"epoch": 0.28553600399351053,
|
| 1007 |
+
"grad_norm": 0.10549402981996536,
|
| 1008 |
+
"learning_rate": 9.294520547945206e-06,
|
| 1009 |
+
"loss": 0.6401,
|
| 1010 |
+
"step": 143
|
| 1011 |
+
},
|
| 1012 |
+
{
|
| 1013 |
+
"epoch": 0.28753275926619243,
|
| 1014 |
+
"grad_norm": 0.10363396257162094,
|
| 1015 |
+
"learning_rate": 9.287671232876713e-06,
|
| 1016 |
+
"loss": 0.6711,
|
| 1017 |
+
"step": 144
|
| 1018 |
+
},
|
| 1019 |
+
{
|
| 1020 |
+
"epoch": 0.2895295145388743,
|
| 1021 |
+
"grad_norm": 0.10072599351406097,
|
| 1022 |
+
"learning_rate": 9.28082191780822e-06,
|
| 1023 |
+
"loss": 0.6294,
|
| 1024 |
+
"step": 145
|
| 1025 |
+
},
|
| 1026 |
+
{
|
| 1027 |
+
"epoch": 0.2915262698115562,
|
| 1028 |
+
"grad_norm": 0.09450184553861618,
|
| 1029 |
+
"learning_rate": 9.273972602739727e-06,
|
| 1030 |
+
"loss": 0.6511,
|
| 1031 |
+
"step": 146
|
| 1032 |
+
},
|
| 1033 |
+
{
|
| 1034 |
+
"epoch": 0.2935230250842381,
|
| 1035 |
+
"grad_norm": 0.09612888097763062,
|
| 1036 |
+
"learning_rate": 9.267123287671233e-06,
|
| 1037 |
+
"loss": 0.6441,
|
| 1038 |
+
"step": 147
|
| 1039 |
+
},
|
| 1040 |
+
{
|
| 1041 |
+
"epoch": 0.29551978035692,
|
| 1042 |
+
"grad_norm": 0.09231892973184586,
|
| 1043 |
+
"learning_rate": 9.26027397260274e-06,
|
| 1044 |
+
"loss": 0.6474,
|
| 1045 |
+
"step": 148
|
| 1046 |
+
},
|
| 1047 |
+
{
|
| 1048 |
+
"epoch": 0.2975165356296019,
|
| 1049 |
+
"grad_norm": 0.0949755609035492,
|
| 1050 |
+
"learning_rate": 9.253424657534248e-06,
|
| 1051 |
+
"loss": 0.633,
|
| 1052 |
+
"step": 149
|
| 1053 |
+
},
|
| 1054 |
+
{
|
| 1055 |
+
"epoch": 0.2995132909022838,
|
| 1056 |
+
"grad_norm": 0.09723283350467682,
|
| 1057 |
+
"learning_rate": 9.246575342465755e-06,
|
| 1058 |
+
"loss": 0.641,
|
| 1059 |
+
"step": 150
|
| 1060 |
+
},
|
| 1061 |
+
{
|
| 1062 |
+
"epoch": 0.3015100461749657,
|
| 1063 |
+
"grad_norm": 0.09414070099592209,
|
| 1064 |
+
"learning_rate": 9.23972602739726e-06,
|
| 1065 |
+
"loss": 0.6646,
|
| 1066 |
+
"step": 151
|
| 1067 |
+
},
|
| 1068 |
+
{
|
| 1069 |
+
"epoch": 0.3035068014476476,
|
| 1070 |
+
"grad_norm": 0.0909348651766777,
|
| 1071 |
+
"learning_rate": 9.232876712328768e-06,
|
| 1072 |
+
"loss": 0.6629,
|
| 1073 |
+
"step": 152
|
| 1074 |
+
},
|
| 1075 |
+
{
|
| 1076 |
+
"epoch": 0.30550355672032947,
|
| 1077 |
+
"grad_norm": 0.09564705193042755,
|
| 1078 |
+
"learning_rate": 9.226027397260275e-06,
|
| 1079 |
+
"loss": 0.6727,
|
| 1080 |
+
"step": 153
|
| 1081 |
+
},
|
| 1082 |
+
{
|
| 1083 |
+
"epoch": 0.30750031199301137,
|
| 1084 |
+
"grad_norm": 0.09434914588928223,
|
| 1085 |
+
"learning_rate": 9.219178082191782e-06,
|
| 1086 |
+
"loss": 0.6885,
|
| 1087 |
+
"step": 154
|
| 1088 |
+
},
|
| 1089 |
+
{
|
| 1090 |
+
"epoch": 0.30949706726569326,
|
| 1091 |
+
"grad_norm": 0.1040414348244667,
|
| 1092 |
+
"learning_rate": 9.212328767123288e-06,
|
| 1093 |
+
"loss": 0.6516,
|
| 1094 |
+
"step": 155
|
| 1095 |
+
},
|
| 1096 |
+
{
|
| 1097 |
+
"epoch": 0.31149382253837515,
|
| 1098 |
+
"grad_norm": 0.08882972598075867,
|
| 1099 |
+
"learning_rate": 9.205479452054795e-06,
|
| 1100 |
+
"loss": 0.6564,
|
| 1101 |
+
"step": 156
|
| 1102 |
+
},
|
| 1103 |
+
{
|
| 1104 |
+
"epoch": 0.31349057781105705,
|
| 1105 |
+
"grad_norm": 0.09209997206926346,
|
| 1106 |
+
"learning_rate": 9.198630136986302e-06,
|
| 1107 |
+
"loss": 0.6756,
|
| 1108 |
+
"step": 157
|
| 1109 |
+
},
|
| 1110 |
+
{
|
| 1111 |
+
"epoch": 0.31548733308373894,
|
| 1112 |
+
"grad_norm": 0.0916871652007103,
|
| 1113 |
+
"learning_rate": 9.19178082191781e-06,
|
| 1114 |
+
"loss": 0.6568,
|
| 1115 |
+
"step": 158
|
| 1116 |
+
},
|
| 1117 |
+
{
|
| 1118 |
+
"epoch": 0.31748408835642083,
|
| 1119 |
+
"grad_norm": 0.08956406265497208,
|
| 1120 |
+
"learning_rate": 9.184931506849315e-06,
|
| 1121 |
+
"loss": 0.6464,
|
| 1122 |
+
"step": 159
|
| 1123 |
+
},
|
| 1124 |
+
{
|
| 1125 |
+
"epoch": 0.31948084362910273,
|
| 1126 |
+
"grad_norm": 0.08891318738460541,
|
| 1127 |
+
"learning_rate": 9.178082191780823e-06,
|
| 1128 |
+
"loss": 0.6665,
|
| 1129 |
+
"step": 160
|
| 1130 |
+
},
|
| 1131 |
+
{
|
| 1132 |
+
"epoch": 0.3214775989017846,
|
| 1133 |
+
"grad_norm": 0.08891268819570541,
|
| 1134 |
+
"learning_rate": 9.17123287671233e-06,
|
| 1135 |
+
"loss": 0.6491,
|
| 1136 |
+
"step": 161
|
| 1137 |
+
},
|
| 1138 |
+
{
|
| 1139 |
+
"epoch": 0.3234743541744665,
|
| 1140 |
+
"grad_norm": 0.08686690032482147,
|
| 1141 |
+
"learning_rate": 9.164383561643836e-06,
|
| 1142 |
+
"loss": 0.6221,
|
| 1143 |
+
"step": 162
|
| 1144 |
+
},
|
| 1145 |
+
{
|
| 1146 |
+
"epoch": 0.3254711094471484,
|
| 1147 |
+
"grad_norm": 0.0884203389286995,
|
| 1148 |
+
"learning_rate": 9.157534246575343e-06,
|
| 1149 |
+
"loss": 0.6676,
|
| 1150 |
+
"step": 163
|
| 1151 |
+
},
|
| 1152 |
+
{
|
| 1153 |
+
"epoch": 0.32746786471983025,
|
| 1154 |
+
"grad_norm": 0.09307505935430527,
|
| 1155 |
+
"learning_rate": 9.15068493150685e-06,
|
| 1156 |
+
"loss": 0.6568,
|
| 1157 |
+
"step": 164
|
| 1158 |
+
},
|
| 1159 |
+
{
|
| 1160 |
+
"epoch": 0.32946461999251214,
|
| 1161 |
+
"grad_norm": 0.08617405593395233,
|
| 1162 |
+
"learning_rate": 9.143835616438357e-06,
|
| 1163 |
+
"loss": 0.6641,
|
| 1164 |
+
"step": 165
|
| 1165 |
+
},
|
| 1166 |
+
{
|
| 1167 |
+
"epoch": 0.33146137526519404,
|
| 1168 |
+
"grad_norm": 0.09388285130262375,
|
| 1169 |
+
"learning_rate": 9.136986301369863e-06,
|
| 1170 |
+
"loss": 0.6617,
|
| 1171 |
+
"step": 166
|
| 1172 |
+
},
|
| 1173 |
+
{
|
| 1174 |
+
"epoch": 0.33345813053787593,
|
| 1175 |
+
"grad_norm": 0.09413463622331619,
|
| 1176 |
+
"learning_rate": 9.130136986301372e-06,
|
| 1177 |
+
"loss": 0.6669,
|
| 1178 |
+
"step": 167
|
| 1179 |
+
},
|
| 1180 |
+
{
|
| 1181 |
+
"epoch": 0.3354548858105578,
|
| 1182 |
+
"grad_norm": 0.09485959261655807,
|
| 1183 |
+
"learning_rate": 9.123287671232878e-06,
|
| 1184 |
+
"loss": 0.6408,
|
| 1185 |
+
"step": 168
|
| 1186 |
+
},
|
| 1187 |
+
{
|
| 1188 |
+
"epoch": 0.3374516410832397,
|
| 1189 |
+
"grad_norm": 0.0874333456158638,
|
| 1190 |
+
"learning_rate": 9.116438356164385e-06,
|
| 1191 |
+
"loss": 0.656,
|
| 1192 |
+
"step": 169
|
| 1193 |
+
},
|
| 1194 |
+
{
|
| 1195 |
+
"epoch": 0.3394483963559216,
|
| 1196 |
+
"grad_norm": 0.08628030866384506,
|
| 1197 |
+
"learning_rate": 9.10958904109589e-06,
|
| 1198 |
+
"loss": 0.6534,
|
| 1199 |
+
"step": 170
|
| 1200 |
+
},
|
| 1201 |
+
{
|
| 1202 |
+
"epoch": 0.3414451516286035,
|
| 1203 |
+
"grad_norm": 0.0860527902841568,
|
| 1204 |
+
"learning_rate": 9.102739726027398e-06,
|
| 1205 |
+
"loss": 0.6417,
|
| 1206 |
+
"step": 171
|
| 1207 |
+
},
|
| 1208 |
+
{
|
| 1209 |
+
"epoch": 0.3434419069012854,
|
| 1210 |
+
"grad_norm": 0.08399222046136856,
|
| 1211 |
+
"learning_rate": 9.095890410958905e-06,
|
| 1212 |
+
"loss": 0.6233,
|
| 1213 |
+
"step": 172
|
| 1214 |
+
},
|
| 1215 |
+
{
|
| 1216 |
+
"epoch": 0.3454386621739673,
|
| 1217 |
+
"grad_norm": 0.08794861286878586,
|
| 1218 |
+
"learning_rate": 9.089041095890412e-06,
|
| 1219 |
+
"loss": 0.6612,
|
| 1220 |
+
"step": 173
|
| 1221 |
+
},
|
| 1222 |
+
{
|
| 1223 |
+
"epoch": 0.3474354174466492,
|
| 1224 |
+
"grad_norm": 0.08727024495601654,
|
| 1225 |
+
"learning_rate": 9.082191780821918e-06,
|
| 1226 |
+
"loss": 0.6725,
|
| 1227 |
+
"step": 174
|
| 1228 |
+
},
|
| 1229 |
+
{
|
| 1230 |
+
"epoch": 0.3494321727193311,
|
| 1231 |
+
"grad_norm": 0.08527853339910507,
|
| 1232 |
+
"learning_rate": 9.075342465753425e-06,
|
| 1233 |
+
"loss": 0.6381,
|
| 1234 |
+
"step": 175
|
| 1235 |
+
},
|
| 1236 |
+
{
|
| 1237 |
+
"epoch": 0.351428927992013,
|
| 1238 |
+
"grad_norm": 0.08497577905654907,
|
| 1239 |
+
"learning_rate": 9.068493150684932e-06,
|
| 1240 |
+
"loss": 0.6353,
|
| 1241 |
+
"step": 176
|
| 1242 |
+
},
|
| 1243 |
+
{
|
| 1244 |
+
"epoch": 0.35342568326469487,
|
| 1245 |
+
"grad_norm": 0.08887533843517303,
|
| 1246 |
+
"learning_rate": 9.06164383561644e-06,
|
| 1247 |
+
"loss": 0.6392,
|
| 1248 |
+
"step": 177
|
| 1249 |
+
},
|
| 1250 |
+
{
|
| 1251 |
+
"epoch": 0.35542243853737676,
|
| 1252 |
+
"grad_norm": 0.08368115872144699,
|
| 1253 |
+
"learning_rate": 9.054794520547945e-06,
|
| 1254 |
+
"loss": 0.6041,
|
| 1255 |
+
"step": 178
|
| 1256 |
+
},
|
| 1257 |
+
{
|
| 1258 |
+
"epoch": 0.35741919381005866,
|
| 1259 |
+
"grad_norm": 0.08194791525602341,
|
| 1260 |
+
"learning_rate": 9.047945205479453e-06,
|
| 1261 |
+
"loss": 0.6507,
|
| 1262 |
+
"step": 179
|
| 1263 |
+
},
|
| 1264 |
+
{
|
| 1265 |
+
"epoch": 0.35941594908274055,
|
| 1266 |
+
"grad_norm": 0.07991446554660797,
|
| 1267 |
+
"learning_rate": 9.04109589041096e-06,
|
| 1268 |
+
"loss": 0.6309,
|
| 1269 |
+
"step": 180
|
| 1270 |
+
},
|
| 1271 |
+
{
|
| 1272 |
+
"epoch": 0.36141270435542244,
|
| 1273 |
+
"grad_norm": 0.08230883628129959,
|
| 1274 |
+
"learning_rate": 9.034246575342467e-06,
|
| 1275 |
+
"loss": 0.6348,
|
| 1276 |
+
"step": 181
|
| 1277 |
+
},
|
| 1278 |
+
{
|
| 1279 |
+
"epoch": 0.36340945962810434,
|
| 1280 |
+
"grad_norm": 0.08559627085924149,
|
| 1281 |
+
"learning_rate": 9.027397260273973e-06,
|
| 1282 |
+
"loss": 0.6358,
|
| 1283 |
+
"step": 182
|
| 1284 |
+
},
|
| 1285 |
+
{
|
| 1286 |
+
"epoch": 0.36540621490078623,
|
| 1287 |
+
"grad_norm": 0.08570659905672073,
|
| 1288 |
+
"learning_rate": 9.02054794520548e-06,
|
| 1289 |
+
"loss": 0.5993,
|
| 1290 |
+
"step": 183
|
| 1291 |
+
},
|
| 1292 |
+
{
|
| 1293 |
+
"epoch": 0.3674029701734681,
|
| 1294 |
+
"grad_norm": 0.08620599657297134,
|
| 1295 |
+
"learning_rate": 9.013698630136987e-06,
|
| 1296 |
+
"loss": 0.6587,
|
| 1297 |
+
"step": 184
|
| 1298 |
+
},
|
| 1299 |
+
{
|
| 1300 |
+
"epoch": 0.36939972544615,
|
| 1301 |
+
"grad_norm": 0.0859847143292427,
|
| 1302 |
+
"learning_rate": 9.006849315068495e-06,
|
| 1303 |
+
"loss": 0.6533,
|
| 1304 |
+
"step": 185
|
| 1305 |
+
},
|
| 1306 |
+
{
|
| 1307 |
+
"epoch": 0.3713964807188319,
|
| 1308 |
+
"grad_norm": 0.08272071182727814,
|
| 1309 |
+
"learning_rate": 9e-06,
|
| 1310 |
+
"loss": 0.6121,
|
| 1311 |
+
"step": 186
|
| 1312 |
+
},
|
| 1313 |
+
{
|
| 1314 |
+
"epoch": 0.3733932359915138,
|
| 1315 |
+
"grad_norm": 0.08778800070285797,
|
| 1316 |
+
"learning_rate": 8.993150684931508e-06,
|
| 1317 |
+
"loss": 0.6396,
|
| 1318 |
+
"step": 187
|
| 1319 |
+
},
|
| 1320 |
+
{
|
| 1321 |
+
"epoch": 0.3753899912641957,
|
| 1322 |
+
"grad_norm": 0.08992988616228104,
|
| 1323 |
+
"learning_rate": 8.986301369863015e-06,
|
| 1324 |
+
"loss": 0.6381,
|
| 1325 |
+
"step": 188
|
| 1326 |
+
},
|
| 1327 |
+
{
|
| 1328 |
+
"epoch": 0.3773867465368776,
|
| 1329 |
+
"grad_norm": 0.08496169745922089,
|
| 1330 |
+
"learning_rate": 8.97945205479452e-06,
|
| 1331 |
+
"loss": 0.6475,
|
| 1332 |
+
"step": 189
|
| 1333 |
+
},
|
| 1334 |
+
{
|
| 1335 |
+
"epoch": 0.3793835018095595,
|
| 1336 |
+
"grad_norm": 0.08212533593177795,
|
| 1337 |
+
"learning_rate": 8.972602739726028e-06,
|
| 1338 |
+
"loss": 0.6709,
|
| 1339 |
+
"step": 190
|
| 1340 |
+
},
|
| 1341 |
+
{
|
| 1342 |
+
"epoch": 0.3813802570822414,
|
| 1343 |
+
"grad_norm": 0.08200209587812424,
|
| 1344 |
+
"learning_rate": 8.965753424657535e-06,
|
| 1345 |
+
"loss": 0.6338,
|
| 1346 |
+
"step": 191
|
| 1347 |
+
},
|
| 1348 |
+
{
|
| 1349 |
+
"epoch": 0.3833770123549233,
|
| 1350 |
+
"grad_norm": 0.09153922647237778,
|
| 1351 |
+
"learning_rate": 8.958904109589042e-06,
|
| 1352 |
+
"loss": 0.6158,
|
| 1353 |
+
"step": 192
|
| 1354 |
+
},
|
| 1355 |
+
{
|
| 1356 |
+
"epoch": 0.38537376762760517,
|
| 1357 |
+
"grad_norm": 0.08760355412960052,
|
| 1358 |
+
"learning_rate": 8.952054794520548e-06,
|
| 1359 |
+
"loss": 0.6041,
|
| 1360 |
+
"step": 193
|
| 1361 |
+
},
|
| 1362 |
+
{
|
| 1363 |
+
"epoch": 0.387370522900287,
|
| 1364 |
+
"grad_norm": 0.08381730318069458,
|
| 1365 |
+
"learning_rate": 8.945205479452055e-06,
|
| 1366 |
+
"loss": 0.6337,
|
| 1367 |
+
"step": 194
|
| 1368 |
+
},
|
| 1369 |
+
{
|
| 1370 |
+
"epoch": 0.3893672781729689,
|
| 1371 |
+
"grad_norm": 0.08099182695150375,
|
| 1372 |
+
"learning_rate": 8.938356164383562e-06,
|
| 1373 |
+
"loss": 0.6073,
|
| 1374 |
+
"step": 195
|
| 1375 |
+
},
|
| 1376 |
+
{
|
| 1377 |
+
"epoch": 0.3913640334456508,
|
| 1378 |
+
"grad_norm": 0.08702554553747177,
|
| 1379 |
+
"learning_rate": 8.93150684931507e-06,
|
| 1380 |
+
"loss": 0.6497,
|
| 1381 |
+
"step": 196
|
| 1382 |
+
},
|
| 1383 |
+
{
|
| 1384 |
+
"epoch": 0.3933607887183327,
|
| 1385 |
+
"grad_norm": 0.08087313920259476,
|
| 1386 |
+
"learning_rate": 8.924657534246575e-06,
|
| 1387 |
+
"loss": 0.6036,
|
| 1388 |
+
"step": 197
|
| 1389 |
+
},
|
| 1390 |
+
{
|
| 1391 |
+
"epoch": 0.3953575439910146,
|
| 1392 |
+
"grad_norm": 0.08589271456003189,
|
| 1393 |
+
"learning_rate": 8.917808219178083e-06,
|
| 1394 |
+
"loss": 0.6498,
|
| 1395 |
+
"step": 198
|
| 1396 |
+
},
|
| 1397 |
+
{
|
| 1398 |
+
"epoch": 0.3973542992636965,
|
| 1399 |
+
"grad_norm": 0.0862244963645935,
|
| 1400 |
+
"learning_rate": 8.91095890410959e-06,
|
| 1401 |
+
"loss": 0.6331,
|
| 1402 |
+
"step": 199
|
| 1403 |
+
},
|
| 1404 |
+
{
|
| 1405 |
+
"epoch": 0.39935105453637837,
|
| 1406 |
+
"grad_norm": 0.0803682953119278,
|
| 1407 |
+
"learning_rate": 8.904109589041097e-06,
|
| 1408 |
+
"loss": 0.6508,
|
| 1409 |
+
"step": 200
|
| 1410 |
+
},
|
| 1411 |
+
{
|
| 1412 |
+
"epoch": 0.40134780980906026,
|
| 1413 |
+
"grad_norm": 0.07755322754383087,
|
| 1414 |
+
"learning_rate": 8.897260273972603e-06,
|
| 1415 |
+
"loss": 0.6409,
|
| 1416 |
+
"step": 201
|
| 1417 |
+
},
|
| 1418 |
+
{
|
| 1419 |
+
"epoch": 0.40334456508174216,
|
| 1420 |
+
"grad_norm": 0.08488644659519196,
|
| 1421 |
+
"learning_rate": 8.89041095890411e-06,
|
| 1422 |
+
"loss": 0.6293,
|
| 1423 |
+
"step": 202
|
| 1424 |
+
},
|
| 1425 |
+
{
|
| 1426 |
+
"epoch": 0.40534132035442405,
|
| 1427 |
+
"grad_norm": 0.08399825543165207,
|
| 1428 |
+
"learning_rate": 8.883561643835617e-06,
|
| 1429 |
+
"loss": 0.6517,
|
| 1430 |
+
"step": 203
|
| 1431 |
+
},
|
| 1432 |
+
{
|
| 1433 |
+
"epoch": 0.40733807562710594,
|
| 1434 |
+
"grad_norm": 0.093985915184021,
|
| 1435 |
+
"learning_rate": 8.876712328767125e-06,
|
| 1436 |
+
"loss": 0.6482,
|
| 1437 |
+
"step": 204
|
| 1438 |
+
},
|
| 1439 |
+
{
|
| 1440 |
+
"epoch": 0.40933483089978784,
|
| 1441 |
+
"grad_norm": 0.08805140852928162,
|
| 1442 |
+
"learning_rate": 8.86986301369863e-06,
|
| 1443 |
+
"loss": 0.6415,
|
| 1444 |
+
"step": 205
|
| 1445 |
+
},
|
| 1446 |
+
{
|
| 1447 |
+
"epoch": 0.41133158617246973,
|
| 1448 |
+
"grad_norm": 0.08228921890258789,
|
| 1449 |
+
"learning_rate": 8.863013698630137e-06,
|
| 1450 |
+
"loss": 0.658,
|
| 1451 |
+
"step": 206
|
| 1452 |
+
},
|
| 1453 |
+
{
|
| 1454 |
+
"epoch": 0.4133283414451516,
|
| 1455 |
+
"grad_norm": 0.08415067940950394,
|
| 1456 |
+
"learning_rate": 8.856164383561645e-06,
|
| 1457 |
+
"loss": 0.6492,
|
| 1458 |
+
"step": 207
|
| 1459 |
+
},
|
| 1460 |
+
{
|
| 1461 |
+
"epoch": 0.4153250967178335,
|
| 1462 |
+
"grad_norm": 0.08831077814102173,
|
| 1463 |
+
"learning_rate": 8.849315068493152e-06,
|
| 1464 |
+
"loss": 0.6421,
|
| 1465 |
+
"step": 208
|
| 1466 |
+
},
|
| 1467 |
+
{
|
| 1468 |
+
"epoch": 0.4173218519905154,
|
| 1469 |
+
"grad_norm": 0.07943451404571533,
|
| 1470 |
+
"learning_rate": 8.842465753424658e-06,
|
| 1471 |
+
"loss": 0.6445,
|
| 1472 |
+
"step": 209
|
| 1473 |
+
},
|
| 1474 |
+
{
|
| 1475 |
+
"epoch": 0.4193186072631973,
|
| 1476 |
+
"grad_norm": 0.08044181019067764,
|
| 1477 |
+
"learning_rate": 8.835616438356165e-06,
|
| 1478 |
+
"loss": 0.6753,
|
| 1479 |
+
"step": 210
|
| 1480 |
+
},
|
| 1481 |
+
{
|
| 1482 |
+
"epoch": 0.4213153625358792,
|
| 1483 |
+
"grad_norm": 0.08346639573574066,
|
| 1484 |
+
"learning_rate": 8.828767123287672e-06,
|
| 1485 |
+
"loss": 0.6702,
|
| 1486 |
+
"step": 211
|
| 1487 |
+
},
|
| 1488 |
+
{
|
| 1489 |
+
"epoch": 0.4233121178085611,
|
| 1490 |
+
"grad_norm": 0.08326448500156403,
|
| 1491 |
+
"learning_rate": 8.82191780821918e-06,
|
| 1492 |
+
"loss": 0.6206,
|
| 1493 |
+
"step": 212
|
| 1494 |
+
},
|
| 1495 |
+
{
|
| 1496 |
+
"epoch": 0.425308873081243,
|
| 1497 |
+
"grad_norm": 0.08394528925418854,
|
| 1498 |
+
"learning_rate": 8.815068493150685e-06,
|
| 1499 |
+
"loss": 0.6387,
|
| 1500 |
+
"step": 213
|
| 1501 |
+
},
|
| 1502 |
+
{
|
| 1503 |
+
"epoch": 0.4273056283539249,
|
| 1504 |
+
"grad_norm": 0.07964486628770828,
|
| 1505 |
+
"learning_rate": 8.808219178082192e-06,
|
| 1506 |
+
"loss": 0.6416,
|
| 1507 |
+
"step": 214
|
| 1508 |
+
},
|
| 1509 |
+
{
|
| 1510 |
+
"epoch": 0.4293023836266068,
|
| 1511 |
+
"grad_norm": 0.08593829721212387,
|
| 1512 |
+
"learning_rate": 8.8013698630137e-06,
|
| 1513 |
+
"loss": 0.6467,
|
| 1514 |
+
"step": 215
|
| 1515 |
+
},
|
| 1516 |
+
{
|
| 1517 |
+
"epoch": 0.43129913889928867,
|
| 1518 |
+
"grad_norm": 0.08312725275754929,
|
| 1519 |
+
"learning_rate": 8.794520547945207e-06,
|
| 1520 |
+
"loss": 0.6337,
|
| 1521 |
+
"step": 216
|
| 1522 |
+
},
|
| 1523 |
+
{
|
| 1524 |
+
"epoch": 0.43329589417197056,
|
| 1525 |
+
"grad_norm": 0.07907330989837646,
|
| 1526 |
+
"learning_rate": 8.787671232876713e-06,
|
| 1527 |
+
"loss": 0.6182,
|
| 1528 |
+
"step": 217
|
| 1529 |
+
},
|
| 1530 |
+
{
|
| 1531 |
+
"epoch": 0.43529264944465246,
|
| 1532 |
+
"grad_norm": 0.0807236060500145,
|
| 1533 |
+
"learning_rate": 8.78082191780822e-06,
|
| 1534 |
+
"loss": 0.648,
|
| 1535 |
+
"step": 218
|
| 1536 |
+
},
|
| 1537 |
+
{
|
| 1538 |
+
"epoch": 0.43728940471733435,
|
| 1539 |
+
"grad_norm": 0.08214370906352997,
|
| 1540 |
+
"learning_rate": 8.773972602739727e-06,
|
| 1541 |
+
"loss": 0.6159,
|
| 1542 |
+
"step": 219
|
| 1543 |
+
},
|
| 1544 |
+
{
|
| 1545 |
+
"epoch": 0.43928615999001625,
|
| 1546 |
+
"grad_norm": 0.07902273535728455,
|
| 1547 |
+
"learning_rate": 8.767123287671233e-06,
|
| 1548 |
+
"loss": 0.6209,
|
| 1549 |
+
"step": 220
|
| 1550 |
+
},
|
| 1551 |
+
{
|
| 1552 |
+
"epoch": 0.44128291526269814,
|
| 1553 |
+
"grad_norm": 0.08463626354932785,
|
| 1554 |
+
"learning_rate": 8.76027397260274e-06,
|
| 1555 |
+
"loss": 0.6388,
|
| 1556 |
+
"step": 221
|
| 1557 |
+
},
|
| 1558 |
+
{
|
| 1559 |
+
"epoch": 0.44327967053538003,
|
| 1560 |
+
"grad_norm": 0.08723177760839462,
|
| 1561 |
+
"learning_rate": 8.753424657534247e-06,
|
| 1562 |
+
"loss": 0.6639,
|
| 1563 |
+
"step": 222
|
| 1564 |
+
},
|
| 1565 |
+
{
|
| 1566 |
+
"epoch": 0.4452764258080619,
|
| 1567 |
+
"grad_norm": 0.08998522907495499,
|
| 1568 |
+
"learning_rate": 8.746575342465755e-06,
|
| 1569 |
+
"loss": 0.6491,
|
| 1570 |
+
"step": 223
|
| 1571 |
+
},
|
| 1572 |
+
{
|
| 1573 |
+
"epoch": 0.44727318108074376,
|
| 1574 |
+
"grad_norm": 0.08876420557498932,
|
| 1575 |
+
"learning_rate": 8.73972602739726e-06,
|
| 1576 |
+
"loss": 0.6434,
|
| 1577 |
+
"step": 224
|
| 1578 |
+
},
|
| 1579 |
+
{
|
| 1580 |
+
"epoch": 0.44926993635342566,
|
| 1581 |
+
"grad_norm": 0.08207367360591888,
|
| 1582 |
+
"learning_rate": 8.732876712328769e-06,
|
| 1583 |
+
"loss": 0.6159,
|
| 1584 |
+
"step": 225
|
| 1585 |
+
},
|
| 1586 |
+
{
|
| 1587 |
+
"epoch": 0.45126669162610755,
|
| 1588 |
+
"grad_norm": 0.08738122880458832,
|
| 1589 |
+
"learning_rate": 8.726027397260275e-06,
|
| 1590 |
+
"loss": 0.6383,
|
| 1591 |
+
"step": 226
|
| 1592 |
+
},
|
| 1593 |
+
{
|
| 1594 |
+
"epoch": 0.45326344689878945,
|
| 1595 |
+
"grad_norm": 0.08093910664319992,
|
| 1596 |
+
"learning_rate": 8.719178082191782e-06,
|
| 1597 |
+
"loss": 0.6863,
|
| 1598 |
+
"step": 227
|
| 1599 |
+
},
|
| 1600 |
+
{
|
| 1601 |
+
"epoch": 0.45526020217147134,
|
| 1602 |
+
"grad_norm": 0.0844852477312088,
|
| 1603 |
+
"learning_rate": 8.712328767123288e-06,
|
| 1604 |
+
"loss": 0.6308,
|
| 1605 |
+
"step": 228
|
| 1606 |
+
},
|
| 1607 |
+
{
|
| 1608 |
+
"epoch": 0.45725695744415323,
|
| 1609 |
+
"grad_norm": 0.0834694430232048,
|
| 1610 |
+
"learning_rate": 8.705479452054795e-06,
|
| 1611 |
+
"loss": 0.647,
|
| 1612 |
+
"step": 229
|
| 1613 |
+
},
|
| 1614 |
+
{
|
| 1615 |
+
"epoch": 0.4592537127168351,
|
| 1616 |
+
"grad_norm": 0.08448044210672379,
|
| 1617 |
+
"learning_rate": 8.698630136986302e-06,
|
| 1618 |
+
"loss": 0.6408,
|
| 1619 |
+
"step": 230
|
| 1620 |
+
},
|
| 1621 |
+
{
|
| 1622 |
+
"epoch": 0.461250467989517,
|
| 1623 |
+
"grad_norm": 0.0820637121796608,
|
| 1624 |
+
"learning_rate": 8.69178082191781e-06,
|
| 1625 |
+
"loss": 0.6268,
|
| 1626 |
+
"step": 231
|
| 1627 |
+
},
|
| 1628 |
+
{
|
| 1629 |
+
"epoch": 0.4632472232621989,
|
| 1630 |
+
"grad_norm": 0.08034293353557587,
|
| 1631 |
+
"learning_rate": 8.684931506849315e-06,
|
| 1632 |
+
"loss": 0.6308,
|
| 1633 |
+
"step": 232
|
| 1634 |
+
},
|
| 1635 |
+
{
|
| 1636 |
+
"epoch": 0.4652439785348808,
|
| 1637 |
+
"grad_norm": 0.08095631003379822,
|
| 1638 |
+
"learning_rate": 8.678082191780822e-06,
|
| 1639 |
+
"loss": 0.6236,
|
| 1640 |
+
"step": 233
|
| 1641 |
+
},
|
| 1642 |
+
{
|
| 1643 |
+
"epoch": 0.4672407338075627,
|
| 1644 |
+
"grad_norm": 0.08462950587272644,
|
| 1645 |
+
"learning_rate": 8.67123287671233e-06,
|
| 1646 |
+
"loss": 0.6479,
|
| 1647 |
+
"step": 234
|
| 1648 |
+
},
|
| 1649 |
+
{
|
| 1650 |
+
"epoch": 0.4692374890802446,
|
| 1651 |
+
"grad_norm": 0.07999172806739807,
|
| 1652 |
+
"learning_rate": 8.664383561643837e-06,
|
| 1653 |
+
"loss": 0.6523,
|
| 1654 |
+
"step": 235
|
| 1655 |
+
},
|
| 1656 |
+
{
|
| 1657 |
+
"epoch": 0.4712342443529265,
|
| 1658 |
+
"grad_norm": 0.08923690766096115,
|
| 1659 |
+
"learning_rate": 8.657534246575343e-06,
|
| 1660 |
+
"loss": 0.634,
|
| 1661 |
+
"step": 236
|
| 1662 |
+
},
|
| 1663 |
+
{
|
| 1664 |
+
"epoch": 0.4732309996256084,
|
| 1665 |
+
"grad_norm": 0.08821967989206314,
|
| 1666 |
+
"learning_rate": 8.65068493150685e-06,
|
| 1667 |
+
"loss": 0.6412,
|
| 1668 |
+
"step": 237
|
| 1669 |
+
},
|
| 1670 |
+
{
|
| 1671 |
+
"epoch": 0.4752277548982903,
|
| 1672 |
+
"grad_norm": 0.08308009803295135,
|
| 1673 |
+
"learning_rate": 8.643835616438357e-06,
|
| 1674 |
+
"loss": 0.5984,
|
| 1675 |
+
"step": 238
|
| 1676 |
+
},
|
| 1677 |
+
{
|
| 1678 |
+
"epoch": 0.47722451017097217,
|
| 1679 |
+
"grad_norm": 0.08100554347038269,
|
| 1680 |
+
"learning_rate": 8.636986301369864e-06,
|
| 1681 |
+
"loss": 0.6221,
|
| 1682 |
+
"step": 239
|
| 1683 |
+
},
|
| 1684 |
+
{
|
| 1685 |
+
"epoch": 0.47922126544365407,
|
| 1686 |
+
"grad_norm": 0.08808869123458862,
|
| 1687 |
+
"learning_rate": 8.63013698630137e-06,
|
| 1688 |
+
"loss": 0.6387,
|
| 1689 |
+
"step": 240
|
| 1690 |
+
},
|
| 1691 |
+
{
|
| 1692 |
+
"epoch": 0.48121802071633596,
|
| 1693 |
+
"grad_norm": 0.08174411207437515,
|
| 1694 |
+
"learning_rate": 8.623287671232877e-06,
|
| 1695 |
+
"loss": 0.6384,
|
| 1696 |
+
"step": 241
|
| 1697 |
+
},
|
| 1698 |
+
{
|
| 1699 |
+
"epoch": 0.48321477598901785,
|
| 1700 |
+
"grad_norm": 0.08261357247829437,
|
| 1701 |
+
"learning_rate": 8.616438356164385e-06,
|
| 1702 |
+
"loss": 0.6512,
|
| 1703 |
+
"step": 242
|
| 1704 |
+
},
|
| 1705 |
+
{
|
| 1706 |
+
"epoch": 0.48521153126169975,
|
| 1707 |
+
"grad_norm": 0.0868501365184784,
|
| 1708 |
+
"learning_rate": 8.609589041095892e-06,
|
| 1709 |
+
"loss": 0.6355,
|
| 1710 |
+
"step": 243
|
| 1711 |
+
},
|
| 1712 |
+
{
|
| 1713 |
+
"epoch": 0.48720828653438164,
|
| 1714 |
+
"grad_norm": 0.07903306931257248,
|
| 1715 |
+
"learning_rate": 8.602739726027397e-06,
|
| 1716 |
+
"loss": 0.6758,
|
| 1717 |
+
"step": 244
|
| 1718 |
+
},
|
| 1719 |
+
{
|
| 1720 |
+
"epoch": 0.48920504180706353,
|
| 1721 |
+
"grad_norm": 0.0908120647072792,
|
| 1722 |
+
"learning_rate": 8.595890410958905e-06,
|
| 1723 |
+
"loss": 0.6165,
|
| 1724 |
+
"step": 245
|
| 1725 |
+
},
|
| 1726 |
+
{
|
| 1727 |
+
"epoch": 0.49120179707974543,
|
| 1728 |
+
"grad_norm": 0.08266864717006683,
|
| 1729 |
+
"learning_rate": 8.589041095890412e-06,
|
| 1730 |
+
"loss": 0.6642,
|
| 1731 |
+
"step": 246
|
| 1732 |
+
},
|
| 1733 |
+
{
|
| 1734 |
+
"epoch": 0.4931985523524273,
|
| 1735 |
+
"grad_norm": 0.08055173605680466,
|
| 1736 |
+
"learning_rate": 8.58219178082192e-06,
|
| 1737 |
+
"loss": 0.617,
|
| 1738 |
+
"step": 247
|
| 1739 |
+
},
|
| 1740 |
+
{
|
| 1741 |
+
"epoch": 0.4951953076251092,
|
| 1742 |
+
"grad_norm": 0.08168390393257141,
|
| 1743 |
+
"learning_rate": 8.575342465753425e-06,
|
| 1744 |
+
"loss": 0.6268,
|
| 1745 |
+
"step": 248
|
| 1746 |
+
},
|
| 1747 |
+
{
|
| 1748 |
+
"epoch": 0.4971920628977911,
|
| 1749 |
+
"grad_norm": 0.0787629634141922,
|
| 1750 |
+
"learning_rate": 8.568493150684932e-06,
|
| 1751 |
+
"loss": 0.6398,
|
| 1752 |
+
"step": 249
|
| 1753 |
+
},
|
| 1754 |
+
{
|
| 1755 |
+
"epoch": 0.499188818170473,
|
| 1756 |
+
"grad_norm": 0.09043371677398682,
|
| 1757 |
+
"learning_rate": 8.56164383561644e-06,
|
| 1758 |
+
"loss": 0.6239,
|
| 1759 |
+
"step": 250
|
| 1760 |
+
},
|
| 1761 |
+
{
|
| 1762 |
+
"epoch": 0.5011855734431548,
|
| 1763 |
+
"grad_norm": 0.08357525616884232,
|
| 1764 |
+
"learning_rate": 8.554794520547945e-06,
|
| 1765 |
+
"loss": 0.659,
|
| 1766 |
+
"step": 251
|
| 1767 |
+
},
|
| 1768 |
+
{
|
| 1769 |
+
"epoch": 0.5031823287158368,
|
| 1770 |
+
"grad_norm": 0.09504301100969315,
|
| 1771 |
+
"learning_rate": 8.547945205479454e-06,
|
| 1772 |
+
"loss": 0.6239,
|
| 1773 |
+
"step": 252
|
| 1774 |
+
},
|
| 1775 |
+
{
|
| 1776 |
+
"epoch": 0.5051790839885186,
|
| 1777 |
+
"grad_norm": 0.08067186176776886,
|
| 1778 |
+
"learning_rate": 8.54109589041096e-06,
|
| 1779 |
+
"loss": 0.6158,
|
| 1780 |
+
"step": 253
|
| 1781 |
+
},
|
| 1782 |
+
{
|
| 1783 |
+
"epoch": 0.5071758392612006,
|
| 1784 |
+
"grad_norm": 0.08868859708309174,
|
| 1785 |
+
"learning_rate": 8.534246575342467e-06,
|
| 1786 |
+
"loss": 0.6434,
|
| 1787 |
+
"step": 254
|
| 1788 |
+
},
|
| 1789 |
+
{
|
| 1790 |
+
"epoch": 0.5091725945338824,
|
| 1791 |
+
"grad_norm": 0.08489713072776794,
|
| 1792 |
+
"learning_rate": 8.527397260273972e-06,
|
| 1793 |
+
"loss": 0.6417,
|
| 1794 |
+
"step": 255
|
| 1795 |
+
},
|
| 1796 |
+
{
|
| 1797 |
+
"epoch": 0.5111693498065644,
|
| 1798 |
+
"grad_norm": 0.08246369659900665,
|
| 1799 |
+
"learning_rate": 8.520547945205481e-06,
|
| 1800 |
+
"loss": 0.6137,
|
| 1801 |
+
"step": 256
|
| 1802 |
+
},
|
| 1803 |
+
{
|
| 1804 |
+
"epoch": 0.5131661050792462,
|
| 1805 |
+
"grad_norm": 0.08800794929265976,
|
| 1806 |
+
"learning_rate": 8.513698630136987e-06,
|
| 1807 |
+
"loss": 0.622,
|
| 1808 |
+
"step": 257
|
| 1809 |
+
},
|
| 1810 |
+
{
|
| 1811 |
+
"epoch": 0.5151628603519282,
|
| 1812 |
+
"grad_norm": 0.0991496592760086,
|
| 1813 |
+
"learning_rate": 8.506849315068494e-06,
|
| 1814 |
+
"loss": 0.6392,
|
| 1815 |
+
"step": 258
|
| 1816 |
+
},
|
| 1817 |
+
{
|
| 1818 |
+
"epoch": 0.51715961562461,
|
| 1819 |
+
"grad_norm": 0.09626424312591553,
|
| 1820 |
+
"learning_rate": 8.5e-06,
|
| 1821 |
+
"loss": 0.6226,
|
| 1822 |
+
"step": 259
|
| 1823 |
+
},
|
| 1824 |
+
{
|
| 1825 |
+
"epoch": 0.5191563708972919,
|
| 1826 |
+
"grad_norm": 0.08874102681875229,
|
| 1827 |
+
"learning_rate": 8.493150684931507e-06,
|
| 1828 |
+
"loss": 0.6269,
|
| 1829 |
+
"step": 260
|
| 1830 |
+
},
|
| 1831 |
+
{
|
| 1832 |
+
"epoch": 0.5211531261699738,
|
| 1833 |
+
"grad_norm": 0.0876912996172905,
|
| 1834 |
+
"learning_rate": 8.486301369863015e-06,
|
| 1835 |
+
"loss": 0.6441,
|
| 1836 |
+
"step": 261
|
| 1837 |
+
},
|
| 1838 |
+
{
|
| 1839 |
+
"epoch": 0.5231498814426557,
|
| 1840 |
+
"grad_norm": 0.08492390066385269,
|
| 1841 |
+
"learning_rate": 8.479452054794522e-06,
|
| 1842 |
+
"loss": 0.6558,
|
| 1843 |
+
"step": 262
|
| 1844 |
+
},
|
| 1845 |
+
{
|
| 1846 |
+
"epoch": 0.5251466367153376,
|
| 1847 |
+
"grad_norm": 0.08091188222169876,
|
| 1848 |
+
"learning_rate": 8.472602739726027e-06,
|
| 1849 |
+
"loss": 0.6603,
|
| 1850 |
+
"step": 263
|
| 1851 |
+
},
|
| 1852 |
+
{
|
| 1853 |
+
"epoch": 0.5271433919880195,
|
| 1854 |
+
"grad_norm": 0.08319351822137833,
|
| 1855 |
+
"learning_rate": 8.465753424657535e-06,
|
| 1856 |
+
"loss": 0.6495,
|
| 1857 |
+
"step": 264
|
| 1858 |
+
},
|
| 1859 |
+
{
|
| 1860 |
+
"epoch": 0.5291401472607014,
|
| 1861 |
+
"grad_norm": 0.08336567878723145,
|
| 1862 |
+
"learning_rate": 8.458904109589042e-06,
|
| 1863 |
+
"loss": 0.6361,
|
| 1864 |
+
"step": 265
|
| 1865 |
+
},
|
| 1866 |
+
{
|
| 1867 |
+
"epoch": 0.5311369025333833,
|
| 1868 |
+
"grad_norm": 0.0845741406083107,
|
| 1869 |
+
"learning_rate": 8.45205479452055e-06,
|
| 1870 |
+
"loss": 0.6435,
|
| 1871 |
+
"step": 266
|
| 1872 |
+
},
|
| 1873 |
+
{
|
| 1874 |
+
"epoch": 0.5331336578060651,
|
| 1875 |
+
"grad_norm": 0.08287670463323593,
|
| 1876 |
+
"learning_rate": 8.445205479452055e-06,
|
| 1877 |
+
"loss": 0.6368,
|
| 1878 |
+
"step": 267
|
| 1879 |
+
},
|
| 1880 |
+
{
|
| 1881 |
+
"epoch": 0.5351304130787471,
|
| 1882 |
+
"grad_norm": 0.17075520753860474,
|
| 1883 |
+
"learning_rate": 8.438356164383562e-06,
|
| 1884 |
+
"loss": 0.6565,
|
| 1885 |
+
"step": 268
|
| 1886 |
+
},
|
| 1887 |
+
{
|
| 1888 |
+
"epoch": 0.5371271683514289,
|
| 1889 |
+
"grad_norm": 0.08212152868509293,
|
| 1890 |
+
"learning_rate": 8.43150684931507e-06,
|
| 1891 |
+
"loss": 0.6207,
|
| 1892 |
+
"step": 269
|
| 1893 |
+
},
|
| 1894 |
+
{
|
| 1895 |
+
"epoch": 0.5391239236241108,
|
| 1896 |
+
"grad_norm": 0.08784583956003189,
|
| 1897 |
+
"learning_rate": 8.424657534246577e-06,
|
| 1898 |
+
"loss": 0.633,
|
| 1899 |
+
"step": 270
|
| 1900 |
+
},
|
| 1901 |
+
{
|
| 1902 |
+
"epoch": 0.5411206788967927,
|
| 1903 |
+
"grad_norm": 0.08179745078086853,
|
| 1904 |
+
"learning_rate": 8.417808219178082e-06,
|
| 1905 |
+
"loss": 0.6232,
|
| 1906 |
+
"step": 271
|
| 1907 |
+
},
|
| 1908 |
+
{
|
| 1909 |
+
"epoch": 0.5431174341694746,
|
| 1910 |
+
"grad_norm": 0.08889183402061462,
|
| 1911 |
+
"learning_rate": 8.41095890410959e-06,
|
| 1912 |
+
"loss": 0.6284,
|
| 1913 |
+
"step": 272
|
| 1914 |
+
},
|
| 1915 |
+
{
|
| 1916 |
+
"epoch": 0.5451141894421565,
|
| 1917 |
+
"grad_norm": 0.0841706246137619,
|
| 1918 |
+
"learning_rate": 8.404109589041097e-06,
|
| 1919 |
+
"loss": 0.621,
|
| 1920 |
+
"step": 273
|
| 1921 |
+
},
|
| 1922 |
+
{
|
| 1923 |
+
"epoch": 0.5471109447148383,
|
| 1924 |
+
"grad_norm": 0.0807892307639122,
|
| 1925 |
+
"learning_rate": 8.397260273972604e-06,
|
| 1926 |
+
"loss": 0.629,
|
| 1927 |
+
"step": 274
|
| 1928 |
+
},
|
| 1929 |
+
{
|
| 1930 |
+
"epoch": 0.5491076999875203,
|
| 1931 |
+
"grad_norm": 0.09147186577320099,
|
| 1932 |
+
"learning_rate": 8.39041095890411e-06,
|
| 1933 |
+
"loss": 0.6723,
|
| 1934 |
+
"step": 275
|
| 1935 |
+
},
|
| 1936 |
+
{
|
| 1937 |
+
"epoch": 0.5511044552602021,
|
| 1938 |
+
"grad_norm": 0.10155276209115982,
|
| 1939 |
+
"learning_rate": 8.383561643835617e-06,
|
| 1940 |
+
"loss": 0.6366,
|
| 1941 |
+
"step": 276
|
| 1942 |
+
},
|
| 1943 |
+
{
|
| 1944 |
+
"epoch": 0.5531012105328841,
|
| 1945 |
+
"grad_norm": 0.08878958970308304,
|
| 1946 |
+
"learning_rate": 8.376712328767124e-06,
|
| 1947 |
+
"loss": 0.6082,
|
| 1948 |
+
"step": 277
|
| 1949 |
+
},
|
| 1950 |
+
{
|
| 1951 |
+
"epoch": 0.5550979658055659,
|
| 1952 |
+
"grad_norm": 0.08273486793041229,
|
| 1953 |
+
"learning_rate": 8.36986301369863e-06,
|
| 1954 |
+
"loss": 0.6477,
|
| 1955 |
+
"step": 278
|
| 1956 |
+
},
|
| 1957 |
+
{
|
| 1958 |
+
"epoch": 0.5570947210782479,
|
| 1959 |
+
"grad_norm": 0.08911009132862091,
|
| 1960 |
+
"learning_rate": 8.363013698630137e-06,
|
| 1961 |
+
"loss": 0.641,
|
| 1962 |
+
"step": 279
|
| 1963 |
+
},
|
| 1964 |
+
{
|
| 1965 |
+
"epoch": 0.5590914763509297,
|
| 1966 |
+
"grad_norm": 0.08673524856567383,
|
| 1967 |
+
"learning_rate": 8.356164383561644e-06,
|
| 1968 |
+
"loss": 0.6658,
|
| 1969 |
+
"step": 280
|
| 1970 |
+
},
|
| 1971 |
+
{
|
| 1972 |
+
"epoch": 0.5610882316236117,
|
| 1973 |
+
"grad_norm": 0.0841827318072319,
|
| 1974 |
+
"learning_rate": 8.349315068493152e-06,
|
| 1975 |
+
"loss": 0.6732,
|
| 1976 |
+
"step": 281
|
| 1977 |
+
},
|
| 1978 |
+
{
|
| 1979 |
+
"epoch": 0.5630849868962935,
|
| 1980 |
+
"grad_norm": 0.09424469619989395,
|
| 1981 |
+
"learning_rate": 8.342465753424657e-06,
|
| 1982 |
+
"loss": 0.6609,
|
| 1983 |
+
"step": 282
|
| 1984 |
+
},
|
| 1985 |
+
{
|
| 1986 |
+
"epoch": 0.5650817421689754,
|
| 1987 |
+
"grad_norm": 0.08211454004049301,
|
| 1988 |
+
"learning_rate": 8.335616438356166e-06,
|
| 1989 |
+
"loss": 0.6376,
|
| 1990 |
+
"step": 283
|
| 1991 |
+
},
|
| 1992 |
+
{
|
| 1993 |
+
"epoch": 0.5670784974416573,
|
| 1994 |
+
"grad_norm": 0.07968860119581223,
|
| 1995 |
+
"learning_rate": 8.328767123287672e-06,
|
| 1996 |
+
"loss": 0.6386,
|
| 1997 |
+
"step": 284
|
| 1998 |
+
},
|
| 1999 |
+
{
|
| 2000 |
+
"epoch": 0.5690752527143392,
|
| 2001 |
+
"grad_norm": 0.08694186806678772,
|
| 2002 |
+
"learning_rate": 8.32191780821918e-06,
|
| 2003 |
+
"loss": 0.6348,
|
| 2004 |
+
"step": 285
|
| 2005 |
+
},
|
| 2006 |
+
{
|
| 2007 |
+
"epoch": 0.5710720079870211,
|
| 2008 |
+
"grad_norm": 0.08228432387113571,
|
| 2009 |
+
"learning_rate": 8.315068493150685e-06,
|
| 2010 |
+
"loss": 0.6388,
|
| 2011 |
+
"step": 286
|
| 2012 |
+
},
|
| 2013 |
+
{
|
| 2014 |
+
"epoch": 0.573068763259703,
|
| 2015 |
+
"grad_norm": 0.08904524892568588,
|
| 2016 |
+
"learning_rate": 8.308219178082192e-06,
|
| 2017 |
+
"loss": 0.6369,
|
| 2018 |
+
"step": 287
|
| 2019 |
+
},
|
| 2020 |
+
{
|
| 2021 |
+
"epoch": 0.5750655185323849,
|
| 2022 |
+
"grad_norm": 0.07731188088655472,
|
| 2023 |
+
"learning_rate": 8.3013698630137e-06,
|
| 2024 |
+
"loss": 0.5778,
|
| 2025 |
+
"step": 288
|
| 2026 |
+
},
|
| 2027 |
+
{
|
| 2028 |
+
"epoch": 0.5770622738050668,
|
| 2029 |
+
"grad_norm": 0.12828634679317474,
|
| 2030 |
+
"learning_rate": 8.294520547945207e-06,
|
| 2031 |
+
"loss": 0.6044,
|
| 2032 |
+
"step": 289
|
| 2033 |
+
},
|
| 2034 |
+
{
|
| 2035 |
+
"epoch": 0.5790590290777486,
|
| 2036 |
+
"grad_norm": 0.09142670780420303,
|
| 2037 |
+
"learning_rate": 8.287671232876712e-06,
|
| 2038 |
+
"loss": 0.612,
|
| 2039 |
+
"step": 290
|
| 2040 |
+
},
|
| 2041 |
+
{
|
| 2042 |
+
"epoch": 0.5810557843504306,
|
| 2043 |
+
"grad_norm": 0.08378866314888,
|
| 2044 |
+
"learning_rate": 8.28082191780822e-06,
|
| 2045 |
+
"loss": 0.5937,
|
| 2046 |
+
"step": 291
|
| 2047 |
+
},
|
| 2048 |
+
{
|
| 2049 |
+
"epoch": 0.5830525396231124,
|
| 2050 |
+
"grad_norm": 0.08074430376291275,
|
| 2051 |
+
"learning_rate": 8.273972602739727e-06,
|
| 2052 |
+
"loss": 0.626,
|
| 2053 |
+
"step": 292
|
| 2054 |
+
},
|
| 2055 |
+
{
|
| 2056 |
+
"epoch": 0.5850492948957944,
|
| 2057 |
+
"grad_norm": 0.1017611101269722,
|
| 2058 |
+
"learning_rate": 8.267123287671234e-06,
|
| 2059 |
+
"loss": 0.5893,
|
| 2060 |
+
"step": 293
|
| 2061 |
+
},
|
| 2062 |
+
{
|
| 2063 |
+
"epoch": 0.5870460501684762,
|
| 2064 |
+
"grad_norm": 0.08989594131708145,
|
| 2065 |
+
"learning_rate": 8.26027397260274e-06,
|
| 2066 |
+
"loss": 0.6521,
|
| 2067 |
+
"step": 294
|
| 2068 |
+
},
|
| 2069 |
+
{
|
| 2070 |
+
"epoch": 0.5890428054411582,
|
| 2071 |
+
"grad_norm": 0.08201949298381805,
|
| 2072 |
+
"learning_rate": 8.253424657534247e-06,
|
| 2073 |
+
"loss": 0.6315,
|
| 2074 |
+
"step": 295
|
| 2075 |
+
},
|
| 2076 |
+
{
|
| 2077 |
+
"epoch": 0.59103956071384,
|
| 2078 |
+
"grad_norm": 0.08401259034872055,
|
| 2079 |
+
"learning_rate": 8.246575342465754e-06,
|
| 2080 |
+
"loss": 0.6177,
|
| 2081 |
+
"step": 296
|
| 2082 |
+
},
|
| 2083 |
+
{
|
| 2084 |
+
"epoch": 0.593036315986522,
|
| 2085 |
+
"grad_norm": 0.10680308938026428,
|
| 2086 |
+
"learning_rate": 8.239726027397262e-06,
|
| 2087 |
+
"loss": 0.646,
|
| 2088 |
+
"step": 297
|
| 2089 |
+
},
|
| 2090 |
+
{
|
| 2091 |
+
"epoch": 0.5950330712592038,
|
| 2092 |
+
"grad_norm": 0.09091546386480331,
|
| 2093 |
+
"learning_rate": 8.232876712328767e-06,
|
| 2094 |
+
"loss": 0.6334,
|
| 2095 |
+
"step": 298
|
| 2096 |
+
},
|
| 2097 |
+
{
|
| 2098 |
+
"epoch": 0.5970298265318856,
|
| 2099 |
+
"grad_norm": 0.08410380780696869,
|
| 2100 |
+
"learning_rate": 8.226027397260274e-06,
|
| 2101 |
+
"loss": 0.6465,
|
| 2102 |
+
"step": 299
|
| 2103 |
+
},
|
| 2104 |
+
{
|
| 2105 |
+
"epoch": 0.5990265818045676,
|
| 2106 |
+
"grad_norm": 0.08529913425445557,
|
| 2107 |
+
"learning_rate": 8.219178082191782e-06,
|
| 2108 |
+
"loss": 0.6545,
|
| 2109 |
+
"step": 300
|
| 2110 |
+
},
|
| 2111 |
+
{
|
| 2112 |
+
"epoch": 0.6010233370772494,
|
| 2113 |
+
"grad_norm": 0.08057110011577606,
|
| 2114 |
+
"learning_rate": 8.212328767123289e-06,
|
| 2115 |
+
"loss": 0.6415,
|
| 2116 |
+
"step": 301
|
| 2117 |
+
},
|
| 2118 |
+
{
|
| 2119 |
+
"epoch": 0.6030200923499314,
|
| 2120 |
+
"grad_norm": 0.08814297616481781,
|
| 2121 |
+
"learning_rate": 8.205479452054795e-06,
|
| 2122 |
+
"loss": 0.6522,
|
| 2123 |
+
"step": 302
|
| 2124 |
+
},
|
| 2125 |
+
{
|
| 2126 |
+
"epoch": 0.6050168476226132,
|
| 2127 |
+
"grad_norm": 0.08834853768348694,
|
| 2128 |
+
"learning_rate": 8.198630136986302e-06,
|
| 2129 |
+
"loss": 0.6369,
|
| 2130 |
+
"step": 303
|
| 2131 |
+
},
|
| 2132 |
+
{
|
| 2133 |
+
"epoch": 0.6070136028952952,
|
| 2134 |
+
"grad_norm": 0.08998329937458038,
|
| 2135 |
+
"learning_rate": 8.19178082191781e-06,
|
| 2136 |
+
"loss": 0.6136,
|
| 2137 |
+
"step": 304
|
| 2138 |
+
},
|
| 2139 |
+
{
|
| 2140 |
+
"epoch": 0.609010358167977,
|
| 2141 |
+
"grad_norm": 0.08033844828605652,
|
| 2142 |
+
"learning_rate": 8.184931506849316e-06,
|
| 2143 |
+
"loss": 0.6479,
|
| 2144 |
+
"step": 305
|
| 2145 |
+
},
|
| 2146 |
+
{
|
| 2147 |
+
"epoch": 0.6110071134406589,
|
| 2148 |
+
"grad_norm": 0.08053375780582428,
|
| 2149 |
+
"learning_rate": 8.178082191780822e-06,
|
| 2150 |
+
"loss": 0.6177,
|
| 2151 |
+
"step": 306
|
| 2152 |
+
},
|
| 2153 |
+
{
|
| 2154 |
+
"epoch": 0.6130038687133408,
|
| 2155 |
+
"grad_norm": 0.08807919919490814,
|
| 2156 |
+
"learning_rate": 8.17123287671233e-06,
|
| 2157 |
+
"loss": 0.6227,
|
| 2158 |
+
"step": 307
|
| 2159 |
+
},
|
| 2160 |
+
{
|
| 2161 |
+
"epoch": 0.6150006239860227,
|
| 2162 |
+
"grad_norm": 0.09442495554685593,
|
| 2163 |
+
"learning_rate": 8.164383561643837e-06,
|
| 2164 |
+
"loss": 0.6372,
|
| 2165 |
+
"step": 308
|
| 2166 |
+
},
|
| 2167 |
+
{
|
| 2168 |
+
"epoch": 0.6169973792587046,
|
| 2169 |
+
"grad_norm": 0.08191791921854019,
|
| 2170 |
+
"learning_rate": 8.157534246575342e-06,
|
| 2171 |
+
"loss": 0.6146,
|
| 2172 |
+
"step": 309
|
| 2173 |
+
},
|
| 2174 |
+
{
|
| 2175 |
+
"epoch": 0.6189941345313865,
|
| 2176 |
+
"grad_norm": 0.08474911749362946,
|
| 2177 |
+
"learning_rate": 8.150684931506851e-06,
|
| 2178 |
+
"loss": 0.6334,
|
| 2179 |
+
"step": 310
|
| 2180 |
+
},
|
| 2181 |
+
{
|
| 2182 |
+
"epoch": 0.6209908898040684,
|
| 2183 |
+
"grad_norm": 0.0809718444943428,
|
| 2184 |
+
"learning_rate": 8.143835616438357e-06,
|
| 2185 |
+
"loss": 0.6417,
|
| 2186 |
+
"step": 311
|
| 2187 |
+
},
|
| 2188 |
+
{
|
| 2189 |
+
"epoch": 0.6229876450767503,
|
| 2190 |
+
"grad_norm": 0.09069975465536118,
|
| 2191 |
+
"learning_rate": 8.136986301369864e-06,
|
| 2192 |
+
"loss": 0.6224,
|
| 2193 |
+
"step": 312
|
| 2194 |
+
},
|
| 2195 |
+
{
|
| 2196 |
+
"epoch": 0.6249844003494321,
|
| 2197 |
+
"grad_norm": 0.08229870349168777,
|
| 2198 |
+
"learning_rate": 8.13013698630137e-06,
|
| 2199 |
+
"loss": 0.6477,
|
| 2200 |
+
"step": 313
|
| 2201 |
+
},
|
| 2202 |
+
{
|
| 2203 |
+
"epoch": 0.6269811556221141,
|
| 2204 |
+
"grad_norm": 0.0842418447136879,
|
| 2205 |
+
"learning_rate": 8.123287671232879e-06,
|
| 2206 |
+
"loss": 0.6155,
|
| 2207 |
+
"step": 314
|
| 2208 |
+
},
|
| 2209 |
+
{
|
| 2210 |
+
"epoch": 0.6289779108947959,
|
| 2211 |
+
"grad_norm": 0.09184005856513977,
|
| 2212 |
+
"learning_rate": 8.116438356164384e-06,
|
| 2213 |
+
"loss": 0.6256,
|
| 2214 |
+
"step": 315
|
| 2215 |
+
},
|
| 2216 |
+
{
|
| 2217 |
+
"epoch": 0.6309746661674779,
|
| 2218 |
+
"grad_norm": 0.08636561781167984,
|
| 2219 |
+
"learning_rate": 8.109589041095892e-06,
|
| 2220 |
+
"loss": 0.6178,
|
| 2221 |
+
"step": 316
|
| 2222 |
+
},
|
| 2223 |
+
{
|
| 2224 |
+
"epoch": 0.6329714214401597,
|
| 2225 |
+
"grad_norm": 0.08534813672304153,
|
| 2226 |
+
"learning_rate": 8.102739726027397e-06,
|
| 2227 |
+
"loss": 0.6478,
|
| 2228 |
+
"step": 317
|
| 2229 |
+
},
|
| 2230 |
+
{
|
| 2231 |
+
"epoch": 0.6349681767128417,
|
| 2232 |
+
"grad_norm": 0.07706432789564133,
|
| 2233 |
+
"learning_rate": 8.095890410958904e-06,
|
| 2234 |
+
"loss": 0.6434,
|
| 2235 |
+
"step": 318
|
| 2236 |
+
},
|
| 2237 |
+
{
|
| 2238 |
+
"epoch": 0.6369649319855235,
|
| 2239 |
+
"grad_norm": 0.09776600450277328,
|
| 2240 |
+
"learning_rate": 8.089041095890412e-06,
|
| 2241 |
+
"loss": 0.6417,
|
| 2242 |
+
"step": 319
|
| 2243 |
+
},
|
| 2244 |
+
{
|
| 2245 |
+
"epoch": 0.6389616872582055,
|
| 2246 |
+
"grad_norm": 0.08862747251987457,
|
| 2247 |
+
"learning_rate": 8.082191780821919e-06,
|
| 2248 |
+
"loss": 0.6475,
|
| 2249 |
+
"step": 320
|
| 2250 |
+
},
|
| 2251 |
+
{
|
| 2252 |
+
"epoch": 0.6409584425308873,
|
| 2253 |
+
"grad_norm": 0.08816659450531006,
|
| 2254 |
+
"learning_rate": 8.075342465753425e-06,
|
| 2255 |
+
"loss": 0.6326,
|
| 2256 |
+
"step": 321
|
| 2257 |
+
},
|
| 2258 |
+
{
|
| 2259 |
+
"epoch": 0.6429551978035692,
|
| 2260 |
+
"grad_norm": 0.1188221126794815,
|
| 2261 |
+
"learning_rate": 8.068493150684932e-06,
|
| 2262 |
+
"loss": 0.6336,
|
| 2263 |
+
"step": 322
|
| 2264 |
+
},
|
| 2265 |
+
{
|
| 2266 |
+
"epoch": 0.6449519530762511,
|
| 2267 |
+
"grad_norm": 0.09697777777910233,
|
| 2268 |
+
"learning_rate": 8.061643835616439e-06,
|
| 2269 |
+
"loss": 0.5971,
|
| 2270 |
+
"step": 323
|
| 2271 |
+
},
|
| 2272 |
+
{
|
| 2273 |
+
"epoch": 0.646948708348933,
|
| 2274 |
+
"grad_norm": 0.08567334711551666,
|
| 2275 |
+
"learning_rate": 8.054794520547946e-06,
|
| 2276 |
+
"loss": 0.6417,
|
| 2277 |
+
"step": 324
|
| 2278 |
+
},
|
| 2279 |
+
{
|
| 2280 |
+
"epoch": 0.6489454636216149,
|
| 2281 |
+
"grad_norm": 0.0873376801609993,
|
| 2282 |
+
"learning_rate": 8.047945205479452e-06,
|
| 2283 |
+
"loss": 0.613,
|
| 2284 |
+
"step": 325
|
| 2285 |
+
},
|
| 2286 |
+
{
|
| 2287 |
+
"epoch": 0.6509422188942968,
|
| 2288 |
+
"grad_norm": 0.08814659714698792,
|
| 2289 |
+
"learning_rate": 8.04109589041096e-06,
|
| 2290 |
+
"loss": 0.6378,
|
| 2291 |
+
"step": 326
|
| 2292 |
+
},
|
| 2293 |
+
{
|
| 2294 |
+
"epoch": 0.6529389741669787,
|
| 2295 |
+
"grad_norm": 0.10195590555667877,
|
| 2296 |
+
"learning_rate": 8.034246575342467e-06,
|
| 2297 |
+
"loss": 0.616,
|
| 2298 |
+
"step": 327
|
| 2299 |
+
},
|
| 2300 |
+
{
|
| 2301 |
+
"epoch": 0.6549357294396605,
|
| 2302 |
+
"grad_norm": 0.09628842771053314,
|
| 2303 |
+
"learning_rate": 8.027397260273974e-06,
|
| 2304 |
+
"loss": 0.6555,
|
| 2305 |
+
"step": 328
|
| 2306 |
+
},
|
| 2307 |
+
{
|
| 2308 |
+
"epoch": 0.6569324847123424,
|
| 2309 |
+
"grad_norm": 0.09534582495689392,
|
| 2310 |
+
"learning_rate": 8.02054794520548e-06,
|
| 2311 |
+
"loss": 0.6322,
|
| 2312 |
+
"step": 329
|
| 2313 |
+
},
|
| 2314 |
+
{
|
| 2315 |
+
"epoch": 0.6589292399850243,
|
| 2316 |
+
"grad_norm": 0.08554988354444504,
|
| 2317 |
+
"learning_rate": 8.013698630136987e-06,
|
| 2318 |
+
"loss": 0.6686,
|
| 2319 |
+
"step": 330
|
| 2320 |
+
},
|
| 2321 |
+
{
|
| 2322 |
+
"epoch": 0.6609259952577062,
|
| 2323 |
+
"grad_norm": 0.08279106765985489,
|
| 2324 |
+
"learning_rate": 8.006849315068494e-06,
|
| 2325 |
+
"loss": 0.6272,
|
| 2326 |
+
"step": 331
|
| 2327 |
+
},
|
| 2328 |
+
{
|
| 2329 |
+
"epoch": 0.6629227505303881,
|
| 2330 |
+
"grad_norm": 0.0819801315665245,
|
| 2331 |
+
"learning_rate": 8.000000000000001e-06,
|
| 2332 |
+
"loss": 0.6284,
|
| 2333 |
+
"step": 332
|
| 2334 |
+
},
|
| 2335 |
+
{
|
| 2336 |
+
"epoch": 0.66491950580307,
|
| 2337 |
+
"grad_norm": 0.10195945203304291,
|
| 2338 |
+
"learning_rate": 7.993150684931507e-06,
|
| 2339 |
+
"loss": 0.6218,
|
| 2340 |
+
"step": 333
|
| 2341 |
+
},
|
| 2342 |
+
{
|
| 2343 |
+
"epoch": 0.6669162610757519,
|
| 2344 |
+
"grad_norm": 0.08146601915359497,
|
| 2345 |
+
"learning_rate": 7.986301369863014e-06,
|
| 2346 |
+
"loss": 0.631,
|
| 2347 |
+
"step": 334
|
| 2348 |
+
},
|
| 2349 |
+
{
|
| 2350 |
+
"epoch": 0.6689130163484338,
|
| 2351 |
+
"grad_norm": 0.08729390054941177,
|
| 2352 |
+
"learning_rate": 7.979452054794521e-06,
|
| 2353 |
+
"loss": 0.6534,
|
| 2354 |
+
"step": 335
|
| 2355 |
+
},
|
| 2356 |
+
{
|
| 2357 |
+
"epoch": 0.6709097716211156,
|
| 2358 |
+
"grad_norm": 0.09326784312725067,
|
| 2359 |
+
"learning_rate": 7.972602739726027e-06,
|
| 2360 |
+
"loss": 0.6107,
|
| 2361 |
+
"step": 336
|
| 2362 |
+
},
|
| 2363 |
+
{
|
| 2364 |
+
"epoch": 0.6729065268937976,
|
| 2365 |
+
"grad_norm": 0.08763978630304337,
|
| 2366 |
+
"learning_rate": 7.965753424657534e-06,
|
| 2367 |
+
"loss": 0.6302,
|
| 2368 |
+
"step": 337
|
| 2369 |
+
},
|
| 2370 |
+
{
|
| 2371 |
+
"epoch": 0.6749032821664794,
|
| 2372 |
+
"grad_norm": 0.0776083841919899,
|
| 2373 |
+
"learning_rate": 7.958904109589042e-06,
|
| 2374 |
+
"loss": 0.6259,
|
| 2375 |
+
"step": 338
|
| 2376 |
+
},
|
| 2377 |
+
{
|
| 2378 |
+
"epoch": 0.6769000374391614,
|
| 2379 |
+
"grad_norm": 0.08602346479892731,
|
| 2380 |
+
"learning_rate": 7.952054794520549e-06,
|
| 2381 |
+
"loss": 0.6129,
|
| 2382 |
+
"step": 339
|
| 2383 |
+
},
|
| 2384 |
+
{
|
| 2385 |
+
"epoch": 0.6788967927118432,
|
| 2386 |
+
"grad_norm": 0.09022011607885361,
|
| 2387 |
+
"learning_rate": 7.945205479452055e-06,
|
| 2388 |
+
"loss": 0.6292,
|
| 2389 |
+
"step": 340
|
| 2390 |
+
},
|
| 2391 |
+
{
|
| 2392 |
+
"epoch": 0.6808935479845252,
|
| 2393 |
+
"grad_norm": 0.08988498151302338,
|
| 2394 |
+
"learning_rate": 7.938356164383564e-06,
|
| 2395 |
+
"loss": 0.6245,
|
| 2396 |
+
"step": 341
|
| 2397 |
+
},
|
| 2398 |
+
{
|
| 2399 |
+
"epoch": 0.682890303257207,
|
| 2400 |
+
"grad_norm": 0.10817273706197739,
|
| 2401 |
+
"learning_rate": 7.931506849315069e-06,
|
| 2402 |
+
"loss": 0.6399,
|
| 2403 |
+
"step": 342
|
| 2404 |
+
},
|
| 2405 |
+
{
|
| 2406 |
+
"epoch": 0.684887058529889,
|
| 2407 |
+
"grad_norm": 0.0887124165892601,
|
| 2408 |
+
"learning_rate": 7.924657534246576e-06,
|
| 2409 |
+
"loss": 0.6235,
|
| 2410 |
+
"step": 343
|
| 2411 |
+
},
|
| 2412 |
+
{
|
| 2413 |
+
"epoch": 0.6868838138025708,
|
| 2414 |
+
"grad_norm": 0.09099099785089493,
|
| 2415 |
+
"learning_rate": 7.917808219178082e-06,
|
| 2416 |
+
"loss": 0.6446,
|
| 2417 |
+
"step": 344
|
| 2418 |
+
},
|
| 2419 |
+
{
|
| 2420 |
+
"epoch": 0.6888805690752527,
|
| 2421 |
+
"grad_norm": 0.08027100563049316,
|
| 2422 |
+
"learning_rate": 7.910958904109591e-06,
|
| 2423 |
+
"loss": 0.6331,
|
| 2424 |
+
"step": 345
|
| 2425 |
+
},
|
| 2426 |
+
{
|
| 2427 |
+
"epoch": 0.6908773243479346,
|
| 2428 |
+
"grad_norm": 0.08706498146057129,
|
| 2429 |
+
"learning_rate": 7.904109589041097e-06,
|
| 2430 |
+
"loss": 0.6098,
|
| 2431 |
+
"step": 346
|
| 2432 |
+
},
|
| 2433 |
+
{
|
| 2434 |
+
"epoch": 0.6928740796206165,
|
| 2435 |
+
"grad_norm": 0.08696519583463669,
|
| 2436 |
+
"learning_rate": 7.897260273972604e-06,
|
| 2437 |
+
"loss": 0.621,
|
| 2438 |
+
"step": 347
|
| 2439 |
+
},
|
| 2440 |
+
{
|
| 2441 |
+
"epoch": 0.6948708348932984,
|
| 2442 |
+
"grad_norm": 0.09188802540302277,
|
| 2443 |
+
"learning_rate": 7.89041095890411e-06,
|
| 2444 |
+
"loss": 0.6342,
|
| 2445 |
+
"step": 348
|
| 2446 |
+
},
|
| 2447 |
+
{
|
| 2448 |
+
"epoch": 0.6968675901659803,
|
| 2449 |
+
"grad_norm": 0.09153212606906891,
|
| 2450 |
+
"learning_rate": 7.883561643835617e-06,
|
| 2451 |
+
"loss": 0.6569,
|
| 2452 |
+
"step": 349
|
| 2453 |
+
},
|
| 2454 |
+
{
|
| 2455 |
+
"epoch": 0.6988643454386622,
|
| 2456 |
+
"grad_norm": 0.10127896070480347,
|
| 2457 |
+
"learning_rate": 7.876712328767124e-06,
|
| 2458 |
+
"loss": 0.6281,
|
| 2459 |
+
"step": 350
|
| 2460 |
+
},
|
| 2461 |
+
{
|
| 2462 |
+
"epoch": 0.7008611007113441,
|
| 2463 |
+
"grad_norm": 0.10001371800899506,
|
| 2464 |
+
"learning_rate": 7.869863013698631e-06,
|
| 2465 |
+
"loss": 0.6669,
|
| 2466 |
+
"step": 351
|
| 2467 |
+
},
|
| 2468 |
+
{
|
| 2469 |
+
"epoch": 0.702857855984026,
|
| 2470 |
+
"grad_norm": 0.08944805711507797,
|
| 2471 |
+
"learning_rate": 7.863013698630137e-06,
|
| 2472 |
+
"loss": 0.6561,
|
| 2473 |
+
"step": 352
|
| 2474 |
+
},
|
| 2475 |
+
{
|
| 2476 |
+
"epoch": 0.7048546112567079,
|
| 2477 |
+
"grad_norm": 0.1012006402015686,
|
| 2478 |
+
"learning_rate": 7.856164383561644e-06,
|
| 2479 |
+
"loss": 0.6303,
|
| 2480 |
+
"step": 353
|
| 2481 |
+
},
|
| 2482 |
+
{
|
| 2483 |
+
"epoch": 0.7068513665293897,
|
| 2484 |
+
"grad_norm": 0.08384621888399124,
|
| 2485 |
+
"learning_rate": 7.849315068493151e-06,
|
| 2486 |
+
"loss": 0.6044,
|
| 2487 |
+
"step": 354
|
| 2488 |
+
},
|
| 2489 |
+
{
|
| 2490 |
+
"epoch": 0.7088481218020717,
|
| 2491 |
+
"grad_norm": 0.10328217595815659,
|
| 2492 |
+
"learning_rate": 7.842465753424659e-06,
|
| 2493 |
+
"loss": 0.6311,
|
| 2494 |
+
"step": 355
|
| 2495 |
+
},
|
| 2496 |
+
{
|
| 2497 |
+
"epoch": 0.7108448770747535,
|
| 2498 |
+
"grad_norm": 0.09059418737888336,
|
| 2499 |
+
"learning_rate": 7.835616438356164e-06,
|
| 2500 |
+
"loss": 0.6575,
|
| 2501 |
+
"step": 356
|
| 2502 |
+
},
|
| 2503 |
+
{
|
| 2504 |
+
"epoch": 0.7128416323474355,
|
| 2505 |
+
"grad_norm": 0.09650541841983795,
|
| 2506 |
+
"learning_rate": 7.828767123287672e-06,
|
| 2507 |
+
"loss": 0.6305,
|
| 2508 |
+
"step": 357
|
| 2509 |
+
},
|
| 2510 |
+
{
|
| 2511 |
+
"epoch": 0.7148383876201173,
|
| 2512 |
+
"grad_norm": 0.08358507603406906,
|
| 2513 |
+
"learning_rate": 7.821917808219179e-06,
|
| 2514 |
+
"loss": 0.6182,
|
| 2515 |
+
"step": 358
|
| 2516 |
+
},
|
| 2517 |
+
{
|
| 2518 |
+
"epoch": 0.7168351428927991,
|
| 2519 |
+
"grad_norm": 0.10657758265733719,
|
| 2520 |
+
"learning_rate": 7.815068493150686e-06,
|
| 2521 |
+
"loss": 0.6341,
|
| 2522 |
+
"step": 359
|
| 2523 |
+
},
|
| 2524 |
+
{
|
| 2525 |
+
"epoch": 0.7188318981654811,
|
| 2526 |
+
"grad_norm": 0.09342513978481293,
|
| 2527 |
+
"learning_rate": 7.808219178082192e-06,
|
| 2528 |
+
"loss": 0.6292,
|
| 2529 |
+
"step": 360
|
| 2530 |
+
},
|
| 2531 |
+
{
|
| 2532 |
+
"epoch": 0.7208286534381629,
|
| 2533 |
+
"grad_norm": 0.08470805734395981,
|
| 2534 |
+
"learning_rate": 7.801369863013699e-06,
|
| 2535 |
+
"loss": 0.6188,
|
| 2536 |
+
"step": 361
|
| 2537 |
+
},
|
| 2538 |
+
{
|
| 2539 |
+
"epoch": 0.7228254087108449,
|
| 2540 |
+
"grad_norm": 0.0813937783241272,
|
| 2541 |
+
"learning_rate": 7.794520547945206e-06,
|
| 2542 |
+
"loss": 0.6133,
|
| 2543 |
+
"step": 362
|
| 2544 |
+
},
|
| 2545 |
+
{
|
| 2546 |
+
"epoch": 0.7248221639835267,
|
| 2547 |
+
"grad_norm": 0.08287567645311356,
|
| 2548 |
+
"learning_rate": 7.787671232876714e-06,
|
| 2549 |
+
"loss": 0.6281,
|
| 2550 |
+
"step": 363
|
| 2551 |
+
},
|
| 2552 |
+
{
|
| 2553 |
+
"epoch": 0.7268189192562087,
|
| 2554 |
+
"grad_norm": 0.09619621187448502,
|
| 2555 |
+
"learning_rate": 7.78082191780822e-06,
|
| 2556 |
+
"loss": 0.6386,
|
| 2557 |
+
"step": 364
|
| 2558 |
+
},
|
| 2559 |
+
{
|
| 2560 |
+
"epoch": 0.7288156745288905,
|
| 2561 |
+
"grad_norm": 0.10158401727676392,
|
| 2562 |
+
"learning_rate": 7.773972602739727e-06,
|
| 2563 |
+
"loss": 0.6355,
|
| 2564 |
+
"step": 365
|
| 2565 |
+
},
|
| 2566 |
+
{
|
| 2567 |
+
"epoch": 0.7308124298015725,
|
| 2568 |
+
"grad_norm": 0.09512092918157578,
|
| 2569 |
+
"learning_rate": 7.767123287671234e-06,
|
| 2570 |
+
"loss": 0.6112,
|
| 2571 |
+
"step": 366
|
| 2572 |
+
},
|
| 2573 |
+
{
|
| 2574 |
+
"epoch": 0.7328091850742543,
|
| 2575 |
+
"grad_norm": 0.08900922536849976,
|
| 2576 |
+
"learning_rate": 7.76027397260274e-06,
|
| 2577 |
+
"loss": 0.6219,
|
| 2578 |
+
"step": 367
|
| 2579 |
+
},
|
| 2580 |
+
{
|
| 2581 |
+
"epoch": 0.7348059403469362,
|
| 2582 |
+
"grad_norm": 0.08434482663869858,
|
| 2583 |
+
"learning_rate": 7.753424657534248e-06,
|
| 2584 |
+
"loss": 0.6343,
|
| 2585 |
+
"step": 368
|
| 2586 |
+
},
|
| 2587 |
+
{
|
| 2588 |
+
"epoch": 0.7368026956196181,
|
| 2589 |
+
"grad_norm": 0.08434830605983734,
|
| 2590 |
+
"learning_rate": 7.746575342465754e-06,
|
| 2591 |
+
"loss": 0.6218,
|
| 2592 |
+
"step": 369
|
| 2593 |
+
},
|
| 2594 |
+
{
|
| 2595 |
+
"epoch": 0.7387994508923,
|
| 2596 |
+
"grad_norm": 0.08528321981430054,
|
| 2597 |
+
"learning_rate": 7.739726027397261e-06,
|
| 2598 |
+
"loss": 0.6285,
|
| 2599 |
+
"step": 370
|
| 2600 |
+
},
|
| 2601 |
+
{
|
| 2602 |
+
"epoch": 0.7407962061649819,
|
| 2603 |
+
"grad_norm": 0.0943007618188858,
|
| 2604 |
+
"learning_rate": 7.732876712328767e-06,
|
| 2605 |
+
"loss": 0.611,
|
| 2606 |
+
"step": 371
|
| 2607 |
+
},
|
| 2608 |
+
{
|
| 2609 |
+
"epoch": 0.7427929614376638,
|
| 2610 |
+
"grad_norm": 0.09442902356386185,
|
| 2611 |
+
"learning_rate": 7.726027397260276e-06,
|
| 2612 |
+
"loss": 0.6212,
|
| 2613 |
+
"step": 372
|
| 2614 |
+
},
|
| 2615 |
+
{
|
| 2616 |
+
"epoch": 0.7447897167103457,
|
| 2617 |
+
"grad_norm": 0.09973379969596863,
|
| 2618 |
+
"learning_rate": 7.719178082191781e-06,
|
| 2619 |
+
"loss": 0.6493,
|
| 2620 |
+
"step": 373
|
| 2621 |
+
},
|
| 2622 |
+
{
|
| 2623 |
+
"epoch": 0.7467864719830276,
|
| 2624 |
+
"grad_norm": 0.09333740174770355,
|
| 2625 |
+
"learning_rate": 7.712328767123289e-06,
|
| 2626 |
+
"loss": 0.6189,
|
| 2627 |
+
"step": 374
|
| 2628 |
+
},
|
| 2629 |
+
{
|
| 2630 |
+
"epoch": 0.7487832272557094,
|
| 2631 |
+
"grad_norm": 0.07975912094116211,
|
| 2632 |
+
"learning_rate": 7.705479452054794e-06,
|
| 2633 |
+
"loss": 0.5907,
|
| 2634 |
+
"step": 375
|
| 2635 |
+
},
|
| 2636 |
+
{
|
| 2637 |
+
"epoch": 0.7507799825283914,
|
| 2638 |
+
"grad_norm": 0.09251334518194199,
|
| 2639 |
+
"learning_rate": 7.698630136986302e-06,
|
| 2640 |
+
"loss": 0.6249,
|
| 2641 |
+
"step": 376
|
| 2642 |
+
},
|
| 2643 |
+
{
|
| 2644 |
+
"epoch": 0.7527767378010732,
|
| 2645 |
+
"grad_norm": 0.0966658890247345,
|
| 2646 |
+
"learning_rate": 7.691780821917809e-06,
|
| 2647 |
+
"loss": 0.6074,
|
| 2648 |
+
"step": 377
|
| 2649 |
+
},
|
| 2650 |
+
{
|
| 2651 |
+
"epoch": 0.7547734930737552,
|
| 2652 |
+
"grad_norm": 0.09172848612070084,
|
| 2653 |
+
"learning_rate": 7.684931506849316e-06,
|
| 2654 |
+
"loss": 0.6623,
|
| 2655 |
+
"step": 378
|
| 2656 |
+
},
|
| 2657 |
+
{
|
| 2658 |
+
"epoch": 0.756770248346437,
|
| 2659 |
+
"grad_norm": 0.0874529704451561,
|
| 2660 |
+
"learning_rate": 7.678082191780822e-06,
|
| 2661 |
+
"loss": 0.6219,
|
| 2662 |
+
"step": 379
|
| 2663 |
+
},
|
| 2664 |
+
{
|
| 2665 |
+
"epoch": 0.758767003619119,
|
| 2666 |
+
"grad_norm": 0.08857685327529907,
|
| 2667 |
+
"learning_rate": 7.671232876712329e-06,
|
| 2668 |
+
"loss": 0.6153,
|
| 2669 |
+
"step": 380
|
| 2670 |
+
},
|
| 2671 |
+
{
|
| 2672 |
+
"epoch": 0.7607637588918008,
|
| 2673 |
+
"grad_norm": 0.08565176278352737,
|
| 2674 |
+
"learning_rate": 7.664383561643836e-06,
|
| 2675 |
+
"loss": 0.6378,
|
| 2676 |
+
"step": 381
|
| 2677 |
+
},
|
| 2678 |
+
{
|
| 2679 |
+
"epoch": 0.7627605141644828,
|
| 2680 |
+
"grad_norm": 0.09114093333482742,
|
| 2681 |
+
"learning_rate": 7.657534246575344e-06,
|
| 2682 |
+
"loss": 0.6344,
|
| 2683 |
+
"step": 382
|
| 2684 |
+
},
|
| 2685 |
+
{
|
| 2686 |
+
"epoch": 0.7647572694371646,
|
| 2687 |
+
"grad_norm": 0.0963209792971611,
|
| 2688 |
+
"learning_rate": 7.65068493150685e-06,
|
| 2689 |
+
"loss": 0.6565,
|
| 2690 |
+
"step": 383
|
| 2691 |
+
},
|
| 2692 |
+
{
|
| 2693 |
+
"epoch": 0.7667540247098465,
|
| 2694 |
+
"grad_norm": 0.08320071548223495,
|
| 2695 |
+
"learning_rate": 7.643835616438356e-06,
|
| 2696 |
+
"loss": 0.6533,
|
| 2697 |
+
"step": 384
|
| 2698 |
+
},
|
| 2699 |
+
{
|
| 2700 |
+
"epoch": 0.7687507799825284,
|
| 2701 |
+
"grad_norm": 0.08294820040464401,
|
| 2702 |
+
"learning_rate": 7.636986301369864e-06,
|
| 2703 |
+
"loss": 0.6681,
|
| 2704 |
+
"step": 385
|
| 2705 |
+
},
|
| 2706 |
+
{
|
| 2707 |
+
"epoch": 0.7707475352552103,
|
| 2708 |
+
"grad_norm": 0.08448363840579987,
|
| 2709 |
+
"learning_rate": 7.630136986301371e-06,
|
| 2710 |
+
"loss": 0.6294,
|
| 2711 |
+
"step": 386
|
| 2712 |
+
},
|
| 2713 |
+
{
|
| 2714 |
+
"epoch": 0.7727442905278922,
|
| 2715 |
+
"grad_norm": 0.09567107260227203,
|
| 2716 |
+
"learning_rate": 7.6232876712328775e-06,
|
| 2717 |
+
"loss": 0.6301,
|
| 2718 |
+
"step": 387
|
| 2719 |
+
},
|
| 2720 |
+
{
|
| 2721 |
+
"epoch": 0.774741045800574,
|
| 2722 |
+
"grad_norm": 0.08810196071863174,
|
| 2723 |
+
"learning_rate": 7.616438356164384e-06,
|
| 2724 |
+
"loss": 0.633,
|
| 2725 |
+
"step": 388
|
| 2726 |
+
},
|
| 2727 |
+
{
|
| 2728 |
+
"epoch": 0.776737801073256,
|
| 2729 |
+
"grad_norm": 0.08176866173744202,
|
| 2730 |
+
"learning_rate": 7.60958904109589e-06,
|
| 2731 |
+
"loss": 0.6035,
|
| 2732 |
+
"step": 389
|
| 2733 |
+
},
|
| 2734 |
+
{
|
| 2735 |
+
"epoch": 0.7787345563459378,
|
| 2736 |
+
"grad_norm": 0.09339761734008789,
|
| 2737 |
+
"learning_rate": 7.6027397260273985e-06,
|
| 2738 |
+
"loss": 0.6663,
|
| 2739 |
+
"step": 390
|
| 2740 |
+
},
|
| 2741 |
+
{
|
| 2742 |
+
"epoch": 0.7807313116186197,
|
| 2743 |
+
"grad_norm": 0.08789702504873276,
|
| 2744 |
+
"learning_rate": 7.595890410958905e-06,
|
| 2745 |
+
"loss": 0.6,
|
| 2746 |
+
"step": 391
|
| 2747 |
+
},
|
| 2748 |
+
{
|
| 2749 |
+
"epoch": 0.7827280668913016,
|
| 2750 |
+
"grad_norm": 0.08306291699409485,
|
| 2751 |
+
"learning_rate": 7.589041095890411e-06,
|
| 2752 |
+
"loss": 0.6306,
|
| 2753 |
+
"step": 392
|
| 2754 |
+
},
|
| 2755 |
+
{
|
| 2756 |
+
"epoch": 0.7847248221639835,
|
| 2757 |
+
"grad_norm": 0.09348531812429428,
|
| 2758 |
+
"learning_rate": 7.582191780821918e-06,
|
| 2759 |
+
"loss": 0.6443,
|
| 2760 |
+
"step": 393
|
| 2761 |
+
},
|
| 2762 |
+
{
|
| 2763 |
+
"epoch": 0.7867215774366654,
|
| 2764 |
+
"grad_norm": 0.08978314697742462,
|
| 2765 |
+
"learning_rate": 7.575342465753426e-06,
|
| 2766 |
+
"loss": 0.6573,
|
| 2767 |
+
"step": 394
|
| 2768 |
+
},
|
| 2769 |
+
{
|
| 2770 |
+
"epoch": 0.7887183327093473,
|
| 2771 |
+
"grad_norm": 0.08130855113267899,
|
| 2772 |
+
"learning_rate": 7.568493150684932e-06,
|
| 2773 |
+
"loss": 0.5953,
|
| 2774 |
+
"step": 395
|
| 2775 |
+
},
|
| 2776 |
+
{
|
| 2777 |
+
"epoch": 0.7907150879820292,
|
| 2778 |
+
"grad_norm": 0.0940231904387474,
|
| 2779 |
+
"learning_rate": 7.561643835616439e-06,
|
| 2780 |
+
"loss": 0.6101,
|
| 2781 |
+
"step": 396
|
| 2782 |
+
},
|
| 2783 |
+
{
|
| 2784 |
+
"epoch": 0.7927118432547111,
|
| 2785 |
+
"grad_norm": 0.08444412052631378,
|
| 2786 |
+
"learning_rate": 7.554794520547945e-06,
|
| 2787 |
+
"loss": 0.6373,
|
| 2788 |
+
"step": 397
|
| 2789 |
+
},
|
| 2790 |
+
{
|
| 2791 |
+
"epoch": 0.794708598527393,
|
| 2792 |
+
"grad_norm": 0.08339810371398926,
|
| 2793 |
+
"learning_rate": 7.5479452054794526e-06,
|
| 2794 |
+
"loss": 0.5962,
|
| 2795 |
+
"step": 398
|
| 2796 |
+
},
|
| 2797 |
+
{
|
| 2798 |
+
"epoch": 0.7967053538000749,
|
| 2799 |
+
"grad_norm": 0.09607964754104614,
|
| 2800 |
+
"learning_rate": 7.54109589041096e-06,
|
| 2801 |
+
"loss": 0.6595,
|
| 2802 |
+
"step": 399
|
| 2803 |
+
},
|
| 2804 |
+
{
|
| 2805 |
+
"epoch": 0.7987021090727567,
|
| 2806 |
+
"grad_norm": 0.0899866372346878,
|
| 2807 |
+
"learning_rate": 7.534246575342466e-06,
|
| 2808 |
+
"loss": 0.6422,
|
| 2809 |
+
"step": 400
|
| 2810 |
+
},
|
| 2811 |
+
{
|
| 2812 |
+
"epoch": 0.8006988643454387,
|
| 2813 |
+
"grad_norm": 0.09215114265680313,
|
| 2814 |
+
"learning_rate": 7.527397260273973e-06,
|
| 2815 |
+
"loss": 0.648,
|
| 2816 |
+
"step": 401
|
| 2817 |
+
},
|
| 2818 |
+
{
|
| 2819 |
+
"epoch": 0.8026956196181205,
|
| 2820 |
+
"grad_norm": 0.09480249136686325,
|
| 2821 |
+
"learning_rate": 7.52054794520548e-06,
|
| 2822 |
+
"loss": 0.6101,
|
| 2823 |
+
"step": 402
|
| 2824 |
+
},
|
| 2825 |
+
{
|
| 2826 |
+
"epoch": 0.8046923748908025,
|
| 2827 |
+
"grad_norm": 0.08409575372934341,
|
| 2828 |
+
"learning_rate": 7.513698630136987e-06,
|
| 2829 |
+
"loss": 0.6149,
|
| 2830 |
+
"step": 403
|
| 2831 |
+
},
|
| 2832 |
+
{
|
| 2833 |
+
"epoch": 0.8066891301634843,
|
| 2834 |
+
"grad_norm": 0.09122111648321152,
|
| 2835 |
+
"learning_rate": 7.506849315068494e-06,
|
| 2836 |
+
"loss": 0.6078,
|
| 2837 |
+
"step": 404
|
| 2838 |
+
},
|
| 2839 |
+
{
|
| 2840 |
+
"epoch": 0.8086858854361663,
|
| 2841 |
+
"grad_norm": 0.08759909123182297,
|
| 2842 |
+
"learning_rate": 7.500000000000001e-06,
|
| 2843 |
+
"loss": 0.664,
|
| 2844 |
+
"step": 405
|
| 2845 |
+
},
|
| 2846 |
+
{
|
| 2847 |
+
"epoch": 0.8106826407088481,
|
| 2848 |
+
"grad_norm": 0.08290824294090271,
|
| 2849 |
+
"learning_rate": 7.4931506849315075e-06,
|
| 2850 |
+
"loss": 0.6229,
|
| 2851 |
+
"step": 406
|
| 2852 |
+
},
|
| 2853 |
+
{
|
| 2854 |
+
"epoch": 0.81267939598153,
|
| 2855 |
+
"grad_norm": 0.10028953105211258,
|
| 2856 |
+
"learning_rate": 7.486301369863014e-06,
|
| 2857 |
+
"loss": 0.6266,
|
| 2858 |
+
"step": 407
|
| 2859 |
+
},
|
| 2860 |
+
{
|
| 2861 |
+
"epoch": 0.8146761512542119,
|
| 2862 |
+
"grad_norm": 0.10031448304653168,
|
| 2863 |
+
"learning_rate": 7.479452054794521e-06,
|
| 2864 |
+
"loss": 0.6356,
|
| 2865 |
+
"step": 408
|
| 2866 |
+
},
|
| 2867 |
+
{
|
| 2868 |
+
"epoch": 0.8166729065268938,
|
| 2869 |
+
"grad_norm": 0.08541914820671082,
|
| 2870 |
+
"learning_rate": 7.4726027397260285e-06,
|
| 2871 |
+
"loss": 0.6375,
|
| 2872 |
+
"step": 409
|
| 2873 |
+
},
|
| 2874 |
+
{
|
| 2875 |
+
"epoch": 0.8186696617995757,
|
| 2876 |
+
"grad_norm": 0.08713380247354507,
|
| 2877 |
+
"learning_rate": 7.465753424657535e-06,
|
| 2878 |
+
"loss": 0.6394,
|
| 2879 |
+
"step": 410
|
| 2880 |
+
},
|
| 2881 |
+
{
|
| 2882 |
+
"epoch": 0.8206664170722576,
|
| 2883 |
+
"grad_norm": 0.09178909659385681,
|
| 2884 |
+
"learning_rate": 7.458904109589041e-06,
|
| 2885 |
+
"loss": 0.5901,
|
| 2886 |
+
"step": 411
|
| 2887 |
+
},
|
| 2888 |
+
{
|
| 2889 |
+
"epoch": 0.8226631723449395,
|
| 2890 |
+
"grad_norm": 0.08403053879737854,
|
| 2891 |
+
"learning_rate": 7.452054794520549e-06,
|
| 2892 |
+
"loss": 0.6128,
|
| 2893 |
+
"step": 412
|
| 2894 |
+
},
|
| 2895 |
+
{
|
| 2896 |
+
"epoch": 0.8246599276176214,
|
| 2897 |
+
"grad_norm": 0.09222221374511719,
|
| 2898 |
+
"learning_rate": 7.445205479452056e-06,
|
| 2899 |
+
"loss": 0.6172,
|
| 2900 |
+
"step": 413
|
| 2901 |
+
},
|
| 2902 |
+
{
|
| 2903 |
+
"epoch": 0.8266566828903033,
|
| 2904 |
+
"grad_norm": 0.07988160848617554,
|
| 2905 |
+
"learning_rate": 7.438356164383562e-06,
|
| 2906 |
+
"loss": 0.6301,
|
| 2907 |
+
"step": 414
|
| 2908 |
+
},
|
| 2909 |
+
{
|
| 2910 |
+
"epoch": 0.8286534381629852,
|
| 2911 |
+
"grad_norm": 0.08793946355581284,
|
| 2912 |
+
"learning_rate": 7.431506849315069e-06,
|
| 2913 |
+
"loss": 0.6482,
|
| 2914 |
+
"step": 415
|
| 2915 |
+
},
|
| 2916 |
+
{
|
| 2917 |
+
"epoch": 0.830650193435667,
|
| 2918 |
+
"grad_norm": 0.08366432040929794,
|
| 2919 |
+
"learning_rate": 7.424657534246575e-06,
|
| 2920 |
+
"loss": 0.63,
|
| 2921 |
+
"step": 416
|
| 2922 |
+
},
|
| 2923 |
+
{
|
| 2924 |
+
"epoch": 0.832646948708349,
|
| 2925 |
+
"grad_norm": 0.08675362914800644,
|
| 2926 |
+
"learning_rate": 7.417808219178083e-06,
|
| 2927 |
+
"loss": 0.6145,
|
| 2928 |
+
"step": 417
|
| 2929 |
+
},
|
| 2930 |
+
{
|
| 2931 |
+
"epoch": 0.8346437039810308,
|
| 2932 |
+
"grad_norm": 0.08647222071886063,
|
| 2933 |
+
"learning_rate": 7.41095890410959e-06,
|
| 2934 |
+
"loss": 0.6525,
|
| 2935 |
+
"step": 418
|
| 2936 |
+
},
|
| 2937 |
+
{
|
| 2938 |
+
"epoch": 0.8366404592537127,
|
| 2939 |
+
"grad_norm": 0.08656927198171616,
|
| 2940 |
+
"learning_rate": 7.404109589041096e-06,
|
| 2941 |
+
"loss": 0.6316,
|
| 2942 |
+
"step": 419
|
| 2943 |
+
},
|
| 2944 |
+
{
|
| 2945 |
+
"epoch": 0.8386372145263946,
|
| 2946 |
+
"grad_norm": 0.10375358909368515,
|
| 2947 |
+
"learning_rate": 7.397260273972603e-06,
|
| 2948 |
+
"loss": 0.632,
|
| 2949 |
+
"step": 420
|
| 2950 |
+
},
|
| 2951 |
+
{
|
| 2952 |
+
"epoch": 0.8406339697990765,
|
| 2953 |
+
"grad_norm": 0.08459735661745071,
|
| 2954 |
+
"learning_rate": 7.390410958904111e-06,
|
| 2955 |
+
"loss": 0.6264,
|
| 2956 |
+
"step": 421
|
| 2957 |
+
},
|
| 2958 |
+
{
|
| 2959 |
+
"epoch": 0.8426307250717584,
|
| 2960 |
+
"grad_norm": 0.08126968145370483,
|
| 2961 |
+
"learning_rate": 7.383561643835617e-06,
|
| 2962 |
+
"loss": 0.6052,
|
| 2963 |
+
"step": 422
|
| 2964 |
+
},
|
| 2965 |
+
{
|
| 2966 |
+
"epoch": 0.8446274803444402,
|
| 2967 |
+
"grad_norm": 0.08688778430223465,
|
| 2968 |
+
"learning_rate": 7.376712328767124e-06,
|
| 2969 |
+
"loss": 0.6554,
|
| 2970 |
+
"step": 423
|
| 2971 |
+
},
|
| 2972 |
+
{
|
| 2973 |
+
"epoch": 0.8466242356171222,
|
| 2974 |
+
"grad_norm": 0.08540894836187363,
|
| 2975 |
+
"learning_rate": 7.36986301369863e-06,
|
| 2976 |
+
"loss": 0.6349,
|
| 2977 |
+
"step": 424
|
| 2978 |
+
},
|
| 2979 |
+
{
|
| 2980 |
+
"epoch": 0.848620990889804,
|
| 2981 |
+
"grad_norm": 0.0881495550274849,
|
| 2982 |
+
"learning_rate": 7.3630136986301374e-06,
|
| 2983 |
+
"loss": 0.6212,
|
| 2984 |
+
"step": 425
|
| 2985 |
+
},
|
| 2986 |
+
{
|
| 2987 |
+
"epoch": 0.850617746162486,
|
| 2988 |
+
"grad_norm": 0.09146378934383392,
|
| 2989 |
+
"learning_rate": 7.356164383561645e-06,
|
| 2990 |
+
"loss": 0.6251,
|
| 2991 |
+
"step": 426
|
| 2992 |
+
},
|
| 2993 |
+
{
|
| 2994 |
+
"epoch": 0.8526145014351678,
|
| 2995 |
+
"grad_norm": 0.08816662430763245,
|
| 2996 |
+
"learning_rate": 7.349315068493151e-06,
|
| 2997 |
+
"loss": 0.6403,
|
| 2998 |
+
"step": 427
|
| 2999 |
+
},
|
| 3000 |
+
{
|
| 3001 |
+
"epoch": 0.8546112567078498,
|
| 3002 |
+
"grad_norm": 0.08613763749599457,
|
| 3003 |
+
"learning_rate": 7.342465753424658e-06,
|
| 3004 |
+
"loss": 0.6314,
|
| 3005 |
+
"step": 428
|
| 3006 |
+
},
|
| 3007 |
+
{
|
| 3008 |
+
"epoch": 0.8566080119805316,
|
| 3009 |
+
"grad_norm": 0.08418456465005875,
|
| 3010 |
+
"learning_rate": 7.335616438356165e-06,
|
| 3011 |
+
"loss": 0.6524,
|
| 3012 |
+
"step": 429
|
| 3013 |
+
},
|
| 3014 |
+
{
|
| 3015 |
+
"epoch": 0.8586047672532136,
|
| 3016 |
+
"grad_norm": 0.08402597904205322,
|
| 3017 |
+
"learning_rate": 7.328767123287672e-06,
|
| 3018 |
+
"loss": 0.6229,
|
| 3019 |
+
"step": 430
|
| 3020 |
+
},
|
| 3021 |
+
{
|
| 3022 |
+
"epoch": 0.8606015225258954,
|
| 3023 |
+
"grad_norm": 0.08308534324169159,
|
| 3024 |
+
"learning_rate": 7.321917808219179e-06,
|
| 3025 |
+
"loss": 0.6203,
|
| 3026 |
+
"step": 431
|
| 3027 |
+
},
|
| 3028 |
+
{
|
| 3029 |
+
"epoch": 0.8625982777985773,
|
| 3030 |
+
"grad_norm": 0.10041052848100662,
|
| 3031 |
+
"learning_rate": 7.315068493150685e-06,
|
| 3032 |
+
"loss": 0.6021,
|
| 3033 |
+
"step": 432
|
| 3034 |
+
},
|
| 3035 |
+
{
|
| 3036 |
+
"epoch": 0.8645950330712592,
|
| 3037 |
+
"grad_norm": 0.10795553028583527,
|
| 3038 |
+
"learning_rate": 7.308219178082192e-06,
|
| 3039 |
+
"loss": 0.6234,
|
| 3040 |
+
"step": 433
|
| 3041 |
+
},
|
| 3042 |
+
{
|
| 3043 |
+
"epoch": 0.8665917883439411,
|
| 3044 |
+
"grad_norm": 0.08625102043151855,
|
| 3045 |
+
"learning_rate": 7.3013698630137e-06,
|
| 3046 |
+
"loss": 0.6344,
|
| 3047 |
+
"step": 434
|
| 3048 |
+
},
|
| 3049 |
+
{
|
| 3050 |
+
"epoch": 0.868588543616623,
|
| 3051 |
+
"grad_norm": 0.08903323858976364,
|
| 3052 |
+
"learning_rate": 7.294520547945206e-06,
|
| 3053 |
+
"loss": 0.6404,
|
| 3054 |
+
"step": 435
|
| 3055 |
+
},
|
| 3056 |
+
{
|
| 3057 |
+
"epoch": 0.8705852988893049,
|
| 3058 |
+
"grad_norm": 0.08824340999126434,
|
| 3059 |
+
"learning_rate": 7.287671232876713e-06,
|
| 3060 |
+
"loss": 0.6542,
|
| 3061 |
+
"step": 436
|
| 3062 |
+
},
|
| 3063 |
+
{
|
| 3064 |
+
"epoch": 0.8725820541619868,
|
| 3065 |
+
"grad_norm": 0.09185468405485153,
|
| 3066 |
+
"learning_rate": 7.28082191780822e-06,
|
| 3067 |
+
"loss": 0.6218,
|
| 3068 |
+
"step": 437
|
| 3069 |
+
},
|
| 3070 |
+
{
|
| 3071 |
+
"epoch": 0.8745788094346687,
|
| 3072 |
+
"grad_norm": 0.08986788243055344,
|
| 3073 |
+
"learning_rate": 7.273972602739726e-06,
|
| 3074 |
+
"loss": 0.6411,
|
| 3075 |
+
"step": 438
|
| 3076 |
+
},
|
| 3077 |
+
{
|
| 3078 |
+
"epoch": 0.8765755647073505,
|
| 3079 |
+
"grad_norm": 0.08936543017625809,
|
| 3080 |
+
"learning_rate": 7.2671232876712335e-06,
|
| 3081 |
+
"loss": 0.614,
|
| 3082 |
+
"step": 439
|
| 3083 |
+
},
|
| 3084 |
+
{
|
| 3085 |
+
"epoch": 0.8785723199800325,
|
| 3086 |
+
"grad_norm": 0.09536322206258774,
|
| 3087 |
+
"learning_rate": 7.260273972602741e-06,
|
| 3088 |
+
"loss": 0.6505,
|
| 3089 |
+
"step": 440
|
| 3090 |
+
},
|
| 3091 |
+
{
|
| 3092 |
+
"epoch": 0.8805690752527143,
|
| 3093 |
+
"grad_norm": 0.08595971018075943,
|
| 3094 |
+
"learning_rate": 7.253424657534247e-06,
|
| 3095 |
+
"loss": 0.6027,
|
| 3096 |
+
"step": 441
|
| 3097 |
+
},
|
| 3098 |
+
{
|
| 3099 |
+
"epoch": 0.8825658305253963,
|
| 3100 |
+
"grad_norm": 0.08551914989948273,
|
| 3101 |
+
"learning_rate": 7.246575342465754e-06,
|
| 3102 |
+
"loss": 0.5974,
|
| 3103 |
+
"step": 442
|
| 3104 |
+
},
|
| 3105 |
+
{
|
| 3106 |
+
"epoch": 0.8845625857980781,
|
| 3107 |
+
"grad_norm": 0.08609256148338318,
|
| 3108 |
+
"learning_rate": 7.239726027397261e-06,
|
| 3109 |
+
"loss": 0.6302,
|
| 3110 |
+
"step": 443
|
| 3111 |
+
},
|
| 3112 |
+
{
|
| 3113 |
+
"epoch": 0.8865593410707601,
|
| 3114 |
+
"grad_norm": 0.09731276333332062,
|
| 3115 |
+
"learning_rate": 7.232876712328768e-06,
|
| 3116 |
+
"loss": 0.6385,
|
| 3117 |
+
"step": 444
|
| 3118 |
+
},
|
| 3119 |
+
{
|
| 3120 |
+
"epoch": 0.8885560963434419,
|
| 3121 |
+
"grad_norm": 0.11011891067028046,
|
| 3122 |
+
"learning_rate": 7.226027397260275e-06,
|
| 3123 |
+
"loss": 0.6109,
|
| 3124 |
+
"step": 445
|
| 3125 |
+
},
|
| 3126 |
+
{
|
| 3127 |
+
"epoch": 0.8905528516161239,
|
| 3128 |
+
"grad_norm": 0.08579560369253159,
|
| 3129 |
+
"learning_rate": 7.219178082191781e-06,
|
| 3130 |
+
"loss": 0.6168,
|
| 3131 |
+
"step": 446
|
| 3132 |
+
},
|
| 3133 |
+
{
|
| 3134 |
+
"epoch": 0.8925496068888057,
|
| 3135 |
+
"grad_norm": 0.08741603791713715,
|
| 3136 |
+
"learning_rate": 7.2123287671232876e-06,
|
| 3137 |
+
"loss": 0.6375,
|
| 3138 |
+
"step": 447
|
| 3139 |
+
},
|
| 3140 |
+
{
|
| 3141 |
+
"epoch": 0.8945463621614875,
|
| 3142 |
+
"grad_norm": 0.08839676529169083,
|
| 3143 |
+
"learning_rate": 7.205479452054796e-06,
|
| 3144 |
+
"loss": 0.6221,
|
| 3145 |
+
"step": 448
|
| 3146 |
+
},
|
| 3147 |
+
{
|
| 3148 |
+
"epoch": 0.8965431174341695,
|
| 3149 |
+
"grad_norm": 0.09800486266613007,
|
| 3150 |
+
"learning_rate": 7.198630136986302e-06,
|
| 3151 |
+
"loss": 0.6525,
|
| 3152 |
+
"step": 449
|
| 3153 |
+
},
|
| 3154 |
+
{
|
| 3155 |
+
"epoch": 0.8985398727068513,
|
| 3156 |
+
"grad_norm": 0.08749247342348099,
|
| 3157 |
+
"learning_rate": 7.191780821917809e-06,
|
| 3158 |
+
"loss": 0.6122,
|
| 3159 |
+
"step": 450
|
| 3160 |
+
},
|
| 3161 |
+
{
|
| 3162 |
+
"epoch": 0.9005366279795333,
|
| 3163 |
+
"grad_norm": 0.08808398246765137,
|
| 3164 |
+
"learning_rate": 7.184931506849315e-06,
|
| 3165 |
+
"loss": 0.6203,
|
| 3166 |
+
"step": 451
|
| 3167 |
+
},
|
| 3168 |
+
{
|
| 3169 |
+
"epoch": 0.9025333832522151,
|
| 3170 |
+
"grad_norm": 0.0888322964310646,
|
| 3171 |
+
"learning_rate": 7.178082191780823e-06,
|
| 3172 |
+
"loss": 0.6496,
|
| 3173 |
+
"step": 452
|
| 3174 |
+
},
|
| 3175 |
+
{
|
| 3176 |
+
"epoch": 0.904530138524897,
|
| 3177 |
+
"grad_norm": 0.08242765069007874,
|
| 3178 |
+
"learning_rate": 7.17123287671233e-06,
|
| 3179 |
+
"loss": 0.6271,
|
| 3180 |
+
"step": 453
|
| 3181 |
+
},
|
| 3182 |
+
{
|
| 3183 |
+
"epoch": 0.9065268937975789,
|
| 3184 |
+
"grad_norm": 0.08684896677732468,
|
| 3185 |
+
"learning_rate": 7.164383561643836e-06,
|
| 3186 |
+
"loss": 0.6436,
|
| 3187 |
+
"step": 454
|
| 3188 |
+
},
|
| 3189 |
+
{
|
| 3190 |
+
"epoch": 0.9085236490702608,
|
| 3191 |
+
"grad_norm": 0.10484038293361664,
|
| 3192 |
+
"learning_rate": 7.1575342465753425e-06,
|
| 3193 |
+
"loss": 0.6502,
|
| 3194 |
+
"step": 455
|
| 3195 |
+
},
|
| 3196 |
+
{
|
| 3197 |
+
"epoch": 0.9105204043429427,
|
| 3198 |
+
"grad_norm": 0.08097124844789505,
|
| 3199 |
+
"learning_rate": 7.15068493150685e-06,
|
| 3200 |
+
"loss": 0.6401,
|
| 3201 |
+
"step": 456
|
| 3202 |
+
},
|
| 3203 |
+
{
|
| 3204 |
+
"epoch": 0.9125171596156246,
|
| 3205 |
+
"grad_norm": 0.08406626433134079,
|
| 3206 |
+
"learning_rate": 7.143835616438357e-06,
|
| 3207 |
+
"loss": 0.6399,
|
| 3208 |
+
"step": 457
|
| 3209 |
+
},
|
| 3210 |
+
{
|
| 3211 |
+
"epoch": 0.9145139148883065,
|
| 3212 |
+
"grad_norm": 0.08640296757221222,
|
| 3213 |
+
"learning_rate": 7.1369863013698635e-06,
|
| 3214 |
+
"loss": 0.6613,
|
| 3215 |
+
"step": 458
|
| 3216 |
+
},
|
| 3217 |
+
{
|
| 3218 |
+
"epoch": 0.9165106701609884,
|
| 3219 |
+
"grad_norm": 0.08418799191713333,
|
| 3220 |
+
"learning_rate": 7.13013698630137e-06,
|
| 3221 |
+
"loss": 0.6334,
|
| 3222 |
+
"step": 459
|
| 3223 |
+
},
|
| 3224 |
+
{
|
| 3225 |
+
"epoch": 0.9185074254336703,
|
| 3226 |
+
"grad_norm": 0.08541527390480042,
|
| 3227 |
+
"learning_rate": 7.123287671232877e-06,
|
| 3228 |
+
"loss": 0.6263,
|
| 3229 |
+
"step": 460
|
| 3230 |
+
},
|
| 3231 |
+
{
|
| 3232 |
+
"epoch": 0.9205041807063522,
|
| 3233 |
+
"grad_norm": 0.09964878857135773,
|
| 3234 |
+
"learning_rate": 7.1164383561643845e-06,
|
| 3235 |
+
"loss": 0.6313,
|
| 3236 |
+
"step": 461
|
| 3237 |
+
},
|
| 3238 |
+
{
|
| 3239 |
+
"epoch": 0.922500935979034,
|
| 3240 |
+
"grad_norm": 0.08737082034349442,
|
| 3241 |
+
"learning_rate": 7.109589041095891e-06,
|
| 3242 |
+
"loss": 0.6295,
|
| 3243 |
+
"step": 462
|
| 3244 |
+
},
|
| 3245 |
+
{
|
| 3246 |
+
"epoch": 0.924497691251716,
|
| 3247 |
+
"grad_norm": 0.08089511096477509,
|
| 3248 |
+
"learning_rate": 7.102739726027398e-06,
|
| 3249 |
+
"loss": 0.6327,
|
| 3250 |
+
"step": 463
|
| 3251 |
+
},
|
| 3252 |
+
{
|
| 3253 |
+
"epoch": 0.9264944465243978,
|
| 3254 |
+
"grad_norm": 0.08780577033758163,
|
| 3255 |
+
"learning_rate": 7.095890410958905e-06,
|
| 3256 |
+
"loss": 0.6457,
|
| 3257 |
+
"step": 464
|
| 3258 |
+
},
|
| 3259 |
+
{
|
| 3260 |
+
"epoch": 0.9284912017970798,
|
| 3261 |
+
"grad_norm": 0.08980534970760345,
|
| 3262 |
+
"learning_rate": 7.089041095890411e-06,
|
| 3263 |
+
"loss": 0.6208,
|
| 3264 |
+
"step": 465
|
| 3265 |
+
},
|
| 3266 |
+
{
|
| 3267 |
+
"epoch": 0.9304879570697616,
|
| 3268 |
+
"grad_norm": 0.08758597820997238,
|
| 3269 |
+
"learning_rate": 7.082191780821918e-06,
|
| 3270 |
+
"loss": 0.6306,
|
| 3271 |
+
"step": 466
|
| 3272 |
+
},
|
| 3273 |
+
{
|
| 3274 |
+
"epoch": 0.9324847123424436,
|
| 3275 |
+
"grad_norm": 0.09077585488557816,
|
| 3276 |
+
"learning_rate": 7.075342465753426e-06,
|
| 3277 |
+
"loss": 0.6196,
|
| 3278 |
+
"step": 467
|
| 3279 |
+
},
|
| 3280 |
+
{
|
| 3281 |
+
"epoch": 0.9344814676151254,
|
| 3282 |
+
"grad_norm": 0.08882813900709152,
|
| 3283 |
+
"learning_rate": 7.068493150684932e-06,
|
| 3284 |
+
"loss": 0.6564,
|
| 3285 |
+
"step": 468
|
| 3286 |
+
},
|
| 3287 |
+
{
|
| 3288 |
+
"epoch": 0.9364782228878074,
|
| 3289 |
+
"grad_norm": 0.08457037806510925,
|
| 3290 |
+
"learning_rate": 7.0616438356164386e-06,
|
| 3291 |
+
"loss": 0.6163,
|
| 3292 |
+
"step": 469
|
| 3293 |
+
},
|
| 3294 |
+
{
|
| 3295 |
+
"epoch": 0.9384749781604892,
|
| 3296 |
+
"grad_norm": 0.08448978513479233,
|
| 3297 |
+
"learning_rate": 7.054794520547946e-06,
|
| 3298 |
+
"loss": 0.6185,
|
| 3299 |
+
"step": 470
|
| 3300 |
+
},
|
| 3301 |
+
{
|
| 3302 |
+
"epoch": 0.9404717334331711,
|
| 3303 |
+
"grad_norm": 0.09043850004673004,
|
| 3304 |
+
"learning_rate": 7.047945205479453e-06,
|
| 3305 |
+
"loss": 0.6508,
|
| 3306 |
+
"step": 471
|
| 3307 |
+
},
|
| 3308 |
+
{
|
| 3309 |
+
"epoch": 0.942468488705853,
|
| 3310 |
+
"grad_norm": 0.0870198905467987,
|
| 3311 |
+
"learning_rate": 7.0410958904109596e-06,
|
| 3312 |
+
"loss": 0.6457,
|
| 3313 |
+
"step": 472
|
| 3314 |
+
},
|
| 3315 |
+
{
|
| 3316 |
+
"epoch": 0.9444652439785349,
|
| 3317 |
+
"grad_norm": 0.09303230792284012,
|
| 3318 |
+
"learning_rate": 7.034246575342466e-06,
|
| 3319 |
+
"loss": 0.6437,
|
| 3320 |
+
"step": 473
|
| 3321 |
+
},
|
| 3322 |
+
{
|
| 3323 |
+
"epoch": 0.9464619992512168,
|
| 3324 |
+
"grad_norm": 0.09160307794809341,
|
| 3325 |
+
"learning_rate": 7.027397260273974e-06,
|
| 3326 |
+
"loss": 0.6648,
|
| 3327 |
+
"step": 474
|
| 3328 |
+
},
|
| 3329 |
+
{
|
| 3330 |
+
"epoch": 0.9484587545238987,
|
| 3331 |
+
"grad_norm": 0.10001704841852188,
|
| 3332 |
+
"learning_rate": 7.020547945205481e-06,
|
| 3333 |
+
"loss": 0.622,
|
| 3334 |
+
"step": 475
|
| 3335 |
+
},
|
| 3336 |
+
{
|
| 3337 |
+
"epoch": 0.9504555097965806,
|
| 3338 |
+
"grad_norm": 0.08349056541919708,
|
| 3339 |
+
"learning_rate": 7.013698630136987e-06,
|
| 3340 |
+
"loss": 0.6618,
|
| 3341 |
+
"step": 476
|
| 3342 |
+
},
|
| 3343 |
+
{
|
| 3344 |
+
"epoch": 0.9524522650692624,
|
| 3345 |
+
"grad_norm": 0.08756298571825027,
|
| 3346 |
+
"learning_rate": 7.0068493150684935e-06,
|
| 3347 |
+
"loss": 0.6304,
|
| 3348 |
+
"step": 477
|
| 3349 |
+
},
|
| 3350 |
+
{
|
| 3351 |
+
"epoch": 0.9544490203419443,
|
| 3352 |
+
"grad_norm": 0.09010770916938782,
|
| 3353 |
+
"learning_rate": 7e-06,
|
| 3354 |
+
"loss": 0.6269,
|
| 3355 |
+
"step": 478
|
| 3356 |
+
},
|
| 3357 |
+
{
|
| 3358 |
+
"epoch": 0.9564457756146262,
|
| 3359 |
+
"grad_norm": 0.09259214997291565,
|
| 3360 |
+
"learning_rate": 6.993150684931508e-06,
|
| 3361 |
+
"loss": 0.6567,
|
| 3362 |
+
"step": 479
|
| 3363 |
+
},
|
| 3364 |
+
{
|
| 3365 |
+
"epoch": 0.9584425308873081,
|
| 3366 |
+
"grad_norm": 0.08488563448190689,
|
| 3367 |
+
"learning_rate": 6.9863013698630145e-06,
|
| 3368 |
+
"loss": 0.5926,
|
| 3369 |
+
"step": 480
|
| 3370 |
+
},
|
| 3371 |
+
{
|
| 3372 |
+
"epoch": 0.96043928615999,
|
| 3373 |
+
"grad_norm": 0.08800887316465378,
|
| 3374 |
+
"learning_rate": 6.979452054794521e-06,
|
| 3375 |
+
"loss": 0.6667,
|
| 3376 |
+
"step": 481
|
| 3377 |
+
},
|
| 3378 |
+
{
|
| 3379 |
+
"epoch": 0.9624360414326719,
|
| 3380 |
+
"grad_norm": 0.09012701362371445,
|
| 3381 |
+
"learning_rate": 6.972602739726027e-06,
|
| 3382 |
+
"loss": 0.6063,
|
| 3383 |
+
"step": 482
|
| 3384 |
+
},
|
| 3385 |
+
{
|
| 3386 |
+
"epoch": 0.9644327967053538,
|
| 3387 |
+
"grad_norm": 0.08592038601636887,
|
| 3388 |
+
"learning_rate": 6.9657534246575355e-06,
|
| 3389 |
+
"loss": 0.6396,
|
| 3390 |
+
"step": 483
|
| 3391 |
+
},
|
| 3392 |
+
{
|
| 3393 |
+
"epoch": 0.9664295519780357,
|
| 3394 |
+
"grad_norm": 0.09730264544487,
|
| 3395 |
+
"learning_rate": 6.958904109589042e-06,
|
| 3396 |
+
"loss": 0.6169,
|
| 3397 |
+
"step": 484
|
| 3398 |
+
},
|
| 3399 |
+
{
|
| 3400 |
+
"epoch": 0.9684263072507175,
|
| 3401 |
+
"grad_norm": 0.08748991042375565,
|
| 3402 |
+
"learning_rate": 6.952054794520548e-06,
|
| 3403 |
+
"loss": 0.6209,
|
| 3404 |
+
"step": 485
|
| 3405 |
+
},
|
| 3406 |
+
{
|
| 3407 |
+
"epoch": 0.9704230625233995,
|
| 3408 |
+
"grad_norm": 0.08917925506830215,
|
| 3409 |
+
"learning_rate": 6.945205479452055e-06,
|
| 3410 |
+
"loss": 0.6248,
|
| 3411 |
+
"step": 486
|
| 3412 |
+
},
|
| 3413 |
+
{
|
| 3414 |
+
"epoch": 0.9724198177960813,
|
| 3415 |
+
"grad_norm": 0.08646436780691147,
|
| 3416 |
+
"learning_rate": 6.938356164383562e-06,
|
| 3417 |
+
"loss": 0.595,
|
| 3418 |
+
"step": 487
|
| 3419 |
+
},
|
| 3420 |
+
{
|
| 3421 |
+
"epoch": 0.9744165730687633,
|
| 3422 |
+
"grad_norm": 0.08982618153095245,
|
| 3423 |
+
"learning_rate": 6.931506849315069e-06,
|
| 3424 |
+
"loss": 0.6173,
|
| 3425 |
+
"step": 488
|
| 3426 |
+
},
|
| 3427 |
+
{
|
| 3428 |
+
"epoch": 0.9764133283414451,
|
| 3429 |
+
"grad_norm": 0.091037318110466,
|
| 3430 |
+
"learning_rate": 6.924657534246576e-06,
|
| 3431 |
+
"loss": 0.6465,
|
| 3432 |
+
"step": 489
|
| 3433 |
+
},
|
| 3434 |
+
{
|
| 3435 |
+
"epoch": 0.9784100836141271,
|
| 3436 |
+
"grad_norm": 0.08660898357629776,
|
| 3437 |
+
"learning_rate": 6.917808219178082e-06,
|
| 3438 |
+
"loss": 0.5961,
|
| 3439 |
+
"step": 490
|
| 3440 |
+
},
|
| 3441 |
+
{
|
| 3442 |
+
"epoch": 0.9804068388868089,
|
| 3443 |
+
"grad_norm": 0.09286137670278549,
|
| 3444 |
+
"learning_rate": 6.9109589041095895e-06,
|
| 3445 |
+
"loss": 0.6001,
|
| 3446 |
+
"step": 491
|
| 3447 |
+
},
|
| 3448 |
+
{
|
| 3449 |
+
"epoch": 0.9824035941594909,
|
| 3450 |
+
"grad_norm": 0.09190206974744797,
|
| 3451 |
+
"learning_rate": 6.904109589041097e-06,
|
| 3452 |
+
"loss": 0.652,
|
| 3453 |
+
"step": 492
|
| 3454 |
+
},
|
| 3455 |
+
{
|
| 3456 |
+
"epoch": 0.9844003494321727,
|
| 3457 |
+
"grad_norm": 0.09255805611610413,
|
| 3458 |
+
"learning_rate": 6.897260273972603e-06,
|
| 3459 |
+
"loss": 0.6105,
|
| 3460 |
+
"step": 493
|
| 3461 |
+
},
|
| 3462 |
+
{
|
| 3463 |
+
"epoch": 0.9863971047048546,
|
| 3464 |
+
"grad_norm": 0.08385660499334335,
|
| 3465 |
+
"learning_rate": 6.8904109589041105e-06,
|
| 3466 |
+
"loss": 0.6054,
|
| 3467 |
+
"step": 494
|
| 3468 |
+
},
|
| 3469 |
+
{
|
| 3470 |
+
"epoch": 0.9883938599775365,
|
| 3471 |
+
"grad_norm": 0.08500760793685913,
|
| 3472 |
+
"learning_rate": 6.883561643835617e-06,
|
| 3473 |
+
"loss": 0.6044,
|
| 3474 |
+
"step": 495
|
| 3475 |
+
},
|
| 3476 |
+
{
|
| 3477 |
+
"epoch": 0.9903906152502184,
|
| 3478 |
+
"grad_norm": 0.08311589807271957,
|
| 3479 |
+
"learning_rate": 6.876712328767123e-06,
|
| 3480 |
+
"loss": 0.6161,
|
| 3481 |
+
"step": 496
|
| 3482 |
+
},
|
| 3483 |
+
{
|
| 3484 |
+
"epoch": 0.9923873705229003,
|
| 3485 |
+
"grad_norm": 0.08439301699399948,
|
| 3486 |
+
"learning_rate": 6.869863013698631e-06,
|
| 3487 |
+
"loss": 0.6253,
|
| 3488 |
+
"step": 497
|
| 3489 |
+
},
|
| 3490 |
+
{
|
| 3491 |
+
"epoch": 0.9943841257955822,
|
| 3492 |
+
"grad_norm": 0.08830545842647552,
|
| 3493 |
+
"learning_rate": 6.863013698630138e-06,
|
| 3494 |
+
"loss": 0.6301,
|
| 3495 |
+
"step": 498
|
| 3496 |
+
},
|
| 3497 |
+
{
|
| 3498 |
+
"epoch": 0.9963808810682641,
|
| 3499 |
+
"grad_norm": 0.08998648822307587,
|
| 3500 |
+
"learning_rate": 6.8561643835616444e-06,
|
| 3501 |
+
"loss": 0.6576,
|
| 3502 |
+
"step": 499
|
| 3503 |
+
},
|
| 3504 |
+
{
|
| 3505 |
+
"epoch": 0.998377636340946,
|
| 3506 |
+
"grad_norm": 0.08443831652402878,
|
| 3507 |
+
"learning_rate": 6.849315068493151e-06,
|
| 3508 |
+
"loss": 0.5919,
|
| 3509 |
+
"step": 500
|
| 3510 |
+
}
|
| 3511 |
+
],
|
| 3512 |
+
"logging_steps": 1,
|
| 3513 |
+
"max_steps": 1500,
|
| 3514 |
+
"num_input_tokens_seen": 0,
|
| 3515 |
+
"num_train_epochs": 3,
|
| 3516 |
+
"save_steps": 500,
|
| 3517 |
+
"stateful_callbacks": {
|
| 3518 |
+
"TrainerControl": {
|
| 3519 |
+
"args": {
|
| 3520 |
+
"should_epoch_stop": false,
|
| 3521 |
+
"should_evaluate": false,
|
| 3522 |
+
"should_log": false,
|
| 3523 |
+
"should_save": true,
|
| 3524 |
+
"should_training_stop": false
|
| 3525 |
+
},
|
| 3526 |
+
"attributes": {}
|
| 3527 |
+
}
|
| 3528 |
+
},
|
| 3529 |
+
"total_flos": 1.1536860580434412e+18,
|
| 3530 |
+
"train_batch_size": 1,
|
| 3531 |
+
"trial_name": null,
|
| 3532 |
+
"trial_params": null
|
| 3533 |
+
}
|
checkpoint-500/training_args.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:754e4ae9d879853457ade197edaf9a4e09b3e2d2a23d8bffcf3f56a687083eb3
|
| 3 |
+
size 6904
|
checkpoint-500/vocab.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
checkpoint-500/zero_to_fp32.py
ADDED
|
@@ -0,0 +1,674 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python
|
| 2 |
+
|
| 3 |
+
# Copyright (c) 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:
|
| 14 |
+
# python zero_to_fp32.py . output_dir/
|
| 15 |
+
# or
|
| 16 |
+
# python zero_to_fp32.py . output_dir/ --safe_serialization
|
| 17 |
+
|
| 18 |
+
import argparse
|
| 19 |
+
import torch
|
| 20 |
+
import glob
|
| 21 |
+
import math
|
| 22 |
+
import os
|
| 23 |
+
import re
|
| 24 |
+
import json
|
| 25 |
+
from tqdm import tqdm
|
| 26 |
+
from collections import OrderedDict
|
| 27 |
+
from dataclasses import dataclass
|
| 28 |
+
|
| 29 |
+
# while this script doesn't use deepspeed to recover data, since the checkpoints are pickled with
|
| 30 |
+
# DeepSpeed data structures it has to be available in the current python environment.
|
| 31 |
+
from deepspeed.utils import logger
|
| 32 |
+
from deepspeed.checkpoint.constants import (DS_VERSION, OPTIMIZER_STATE_DICT, SINGLE_PARTITION_OF_FP32_GROUPS,
|
| 33 |
+
FP32_FLAT_GROUPS, ZERO_STAGE, PARTITION_COUNT, PARAM_SHAPES, BUFFER_NAMES,
|
| 34 |
+
FROZEN_PARAM_SHAPES, FROZEN_PARAM_FRAGMENTS)
|
| 35 |
+
|
| 36 |
+
|
| 37 |
+
@dataclass
|
| 38 |
+
class zero_model_state:
|
| 39 |
+
buffers: dict()
|
| 40 |
+
param_shapes: dict()
|
| 41 |
+
shared_params: list
|
| 42 |
+
ds_version: int
|
| 43 |
+
frozen_param_shapes: dict()
|
| 44 |
+
frozen_param_fragments: dict()
|
| 45 |
+
|
| 46 |
+
|
| 47 |
+
debug = 0
|
| 48 |
+
|
| 49 |
+
# load to cpu
|
| 50 |
+
device = torch.device('cpu')
|
| 51 |
+
|
| 52 |
+
|
| 53 |
+
def atoi(text):
|
| 54 |
+
return int(text) if text.isdigit() else text
|
| 55 |
+
|
| 56 |
+
|
| 57 |
+
def natural_keys(text):
|
| 58 |
+
'''
|
| 59 |
+
alist.sort(key=natural_keys) sorts in human order
|
| 60 |
+
http://nedbatchelder.com/blog/200712/human_sorting.html
|
| 61 |
+
(See Toothy's implementation in the comments)
|
| 62 |
+
'''
|
| 63 |
+
return [atoi(c) for c in re.split(r'(\d+)', text)]
|
| 64 |
+
|
| 65 |
+
|
| 66 |
+
def get_model_state_file(checkpoint_dir, zero_stage):
|
| 67 |
+
if not os.path.isdir(checkpoint_dir):
|
| 68 |
+
raise FileNotFoundError(f"Directory '{checkpoint_dir}' doesn't exist")
|
| 69 |
+
|
| 70 |
+
# there should be only one file
|
| 71 |
+
if zero_stage <= 2:
|
| 72 |
+
file = os.path.join(checkpoint_dir, "mp_rank_00_model_states.pt")
|
| 73 |
+
elif zero_stage == 3:
|
| 74 |
+
file = os.path.join(checkpoint_dir, "zero_pp_rank_0_mp_rank_00_model_states.pt")
|
| 75 |
+
|
| 76 |
+
if not os.path.exists(file):
|
| 77 |
+
raise FileNotFoundError(f"can't find model states file at '{file}'")
|
| 78 |
+
|
| 79 |
+
return file
|
| 80 |
+
|
| 81 |
+
|
| 82 |
+
def get_checkpoint_files(checkpoint_dir, glob_pattern):
|
| 83 |
+
# XXX: need to test that this simple glob rule works for multi-node setup too
|
| 84 |
+
ckpt_files = sorted(glob.glob(os.path.join(checkpoint_dir, glob_pattern)), key=natural_keys)
|
| 85 |
+
|
| 86 |
+
if len(ckpt_files) == 0:
|
| 87 |
+
raise FileNotFoundError(f"can't find {glob_pattern} files in directory '{checkpoint_dir}'")
|
| 88 |
+
|
| 89 |
+
return ckpt_files
|
| 90 |
+
|
| 91 |
+
|
| 92 |
+
def get_optim_files(checkpoint_dir):
|
| 93 |
+
return get_checkpoint_files(checkpoint_dir, "*_optim_states.pt")
|
| 94 |
+
|
| 95 |
+
|
| 96 |
+
def get_model_state_files(checkpoint_dir):
|
| 97 |
+
return get_checkpoint_files(checkpoint_dir, "*_model_states.pt")
|
| 98 |
+
|
| 99 |
+
|
| 100 |
+
def parse_model_states(files):
|
| 101 |
+
zero_model_states = []
|
| 102 |
+
for file in files:
|
| 103 |
+
state_dict = torch.load(file, map_location=device)
|
| 104 |
+
|
| 105 |
+
if BUFFER_NAMES not in state_dict:
|
| 106 |
+
raise ValueError(f"{file} is not a model state checkpoint")
|
| 107 |
+
buffer_names = state_dict[BUFFER_NAMES]
|
| 108 |
+
if debug:
|
| 109 |
+
print("Found buffers:", buffer_names)
|
| 110 |
+
|
| 111 |
+
# recover just the buffers while restoring them to fp32 if they were saved in fp16
|
| 112 |
+
buffers = {k: v.float() for k, v in state_dict["module"].items() if k in buffer_names}
|
| 113 |
+
param_shapes = state_dict[PARAM_SHAPES]
|
| 114 |
+
|
| 115 |
+
# collect parameters that are included in param_shapes
|
| 116 |
+
param_names = []
|
| 117 |
+
for s in param_shapes:
|
| 118 |
+
for name in s.keys():
|
| 119 |
+
param_names.append(name)
|
| 120 |
+
|
| 121 |
+
# update with frozen parameters
|
| 122 |
+
frozen_param_shapes = state_dict.get(FROZEN_PARAM_SHAPES, None)
|
| 123 |
+
if frozen_param_shapes is not None:
|
| 124 |
+
if debug:
|
| 125 |
+
print(f"Found frozen_param_shapes: {frozen_param_shapes}")
|
| 126 |
+
param_names += list(frozen_param_shapes.keys())
|
| 127 |
+
|
| 128 |
+
# handle shared params
|
| 129 |
+
shared_params = [[k, v] for k, v in state_dict["shared_params"].items()]
|
| 130 |
+
|
| 131 |
+
ds_version = state_dict.get(DS_VERSION, None)
|
| 132 |
+
|
| 133 |
+
frozen_param_fragments = state_dict.get(FROZEN_PARAM_FRAGMENTS, None)
|
| 134 |
+
|
| 135 |
+
z_model_state = zero_model_state(buffers=buffers,
|
| 136 |
+
param_shapes=param_shapes,
|
| 137 |
+
shared_params=shared_params,
|
| 138 |
+
ds_version=ds_version,
|
| 139 |
+
frozen_param_shapes=frozen_param_shapes,
|
| 140 |
+
frozen_param_fragments=frozen_param_fragments)
|
| 141 |
+
zero_model_states.append(z_model_state)
|
| 142 |
+
|
| 143 |
+
return zero_model_states
|
| 144 |
+
|
| 145 |
+
|
| 146 |
+
def parse_optim_states(files, ds_checkpoint_dir):
|
| 147 |
+
total_files = len(files)
|
| 148 |
+
state_dicts = []
|
| 149 |
+
for f in files:
|
| 150 |
+
state_dict = torch.load(f, map_location=device)
|
| 151 |
+
# immediately discard the potentially huge 2 optimizer states as we only care for fp32 master weights
|
| 152 |
+
# and also handle the case where it was already removed by another helper script
|
| 153 |
+
state_dict["optimizer_state_dict"].pop("optimizer_state_dict", None)
|
| 154 |
+
state_dicts.append(state_dict)
|
| 155 |
+
|
| 156 |
+
if not ZERO_STAGE in state_dicts[0][OPTIMIZER_STATE_DICT]:
|
| 157 |
+
raise ValueError(f"{files[0]} is not a zero checkpoint")
|
| 158 |
+
zero_stage = state_dicts[0][OPTIMIZER_STATE_DICT][ZERO_STAGE]
|
| 159 |
+
world_size = state_dicts[0][OPTIMIZER_STATE_DICT][PARTITION_COUNT]
|
| 160 |
+
|
| 161 |
+
# For ZeRO-2 each param group can have different partition_count as data parallelism for expert
|
| 162 |
+
# parameters can be different from data parallelism for non-expert parameters. So we can just
|
| 163 |
+
# use the max of the partition_count to get the dp world_size.
|
| 164 |
+
|
| 165 |
+
if type(world_size) is list:
|
| 166 |
+
world_size = max(world_size)
|
| 167 |
+
|
| 168 |
+
if world_size != total_files:
|
| 169 |
+
raise ValueError(
|
| 170 |
+
f"Expected {world_size} of '*_optim_states.pt' under '{ds_checkpoint_dir}' but found {total_files} files. "
|
| 171 |
+
"Possibly due to an overwrite of an old checkpoint, or a checkpoint didn't get saved by one or more processes."
|
| 172 |
+
)
|
| 173 |
+
|
| 174 |
+
# the groups are named differently in each stage
|
| 175 |
+
if zero_stage <= 2:
|
| 176 |
+
fp32_groups_key = SINGLE_PARTITION_OF_FP32_GROUPS
|
| 177 |
+
elif zero_stage == 3:
|
| 178 |
+
fp32_groups_key = FP32_FLAT_GROUPS
|
| 179 |
+
else:
|
| 180 |
+
raise ValueError(f"unknown zero stage {zero_stage}")
|
| 181 |
+
|
| 182 |
+
if zero_stage <= 2:
|
| 183 |
+
fp32_flat_groups = [state_dicts[i][OPTIMIZER_STATE_DICT][fp32_groups_key] for i in range(len(state_dicts))]
|
| 184 |
+
elif zero_stage == 3:
|
| 185 |
+
# if there is more than one param group, there will be multiple flattened tensors - one
|
| 186 |
+
# flattened tensor per group - for simplicity merge them into a single tensor
|
| 187 |
+
#
|
| 188 |
+
# XXX: could make the script more memory efficient for when there are multiple groups - it
|
| 189 |
+
# will require matching the sub-lists of param_shapes for each param group flattened tensor
|
| 190 |
+
|
| 191 |
+
fp32_flat_groups = [
|
| 192 |
+
torch.cat(state_dicts[i][OPTIMIZER_STATE_DICT][fp32_groups_key], 0) for i in range(len(state_dicts))
|
| 193 |
+
]
|
| 194 |
+
|
| 195 |
+
return zero_stage, world_size, fp32_flat_groups
|
| 196 |
+
|
| 197 |
+
|
| 198 |
+
def _get_fp32_state_dict_from_zero_checkpoint(ds_checkpoint_dir, exclude_frozen_parameters):
|
| 199 |
+
"""
|
| 200 |
+
Returns fp32 state_dict reconstructed from ds checkpoint
|
| 201 |
+
|
| 202 |
+
Args:
|
| 203 |
+
- ``ds_checkpoint_dir``: path to the deepspeed checkpoint folder (where the optimizer files are)
|
| 204 |
+
|
| 205 |
+
"""
|
| 206 |
+
print(f"Processing zero checkpoint '{ds_checkpoint_dir}'")
|
| 207 |
+
|
| 208 |
+
optim_files = get_optim_files(ds_checkpoint_dir)
|
| 209 |
+
zero_stage, world_size, fp32_flat_groups = parse_optim_states(optim_files, ds_checkpoint_dir)
|
| 210 |
+
print(f"Detected checkpoint of type zero stage {zero_stage}, world_size: {world_size}")
|
| 211 |
+
|
| 212 |
+
model_files = get_model_state_files(ds_checkpoint_dir)
|
| 213 |
+
|
| 214 |
+
zero_model_states = parse_model_states(model_files)
|
| 215 |
+
print(f'Parsing checkpoint created by deepspeed=={zero_model_states[0].ds_version}')
|
| 216 |
+
|
| 217 |
+
if zero_stage <= 2:
|
| 218 |
+
return _get_fp32_state_dict_from_zero2_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 219 |
+
exclude_frozen_parameters)
|
| 220 |
+
elif zero_stage == 3:
|
| 221 |
+
return _get_fp32_state_dict_from_zero3_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 222 |
+
exclude_frozen_parameters)
|
| 223 |
+
|
| 224 |
+
|
| 225 |
+
def _zero2_merge_frozen_params(state_dict, zero_model_states):
|
| 226 |
+
if zero_model_states[0].frozen_param_shapes is None or len(zero_model_states[0].frozen_param_shapes) == 0:
|
| 227 |
+
return
|
| 228 |
+
|
| 229 |
+
frozen_param_shapes = zero_model_states[0].frozen_param_shapes
|
| 230 |
+
frozen_param_fragments = zero_model_states[0].frozen_param_fragments
|
| 231 |
+
|
| 232 |
+
if debug:
|
| 233 |
+
num_elem = sum(s.numel() for s in frozen_param_shapes.values())
|
| 234 |
+
print(f'rank 0: {FROZEN_PARAM_SHAPES}.numel = {num_elem}')
|
| 235 |
+
|
| 236 |
+
wanted_params = len(frozen_param_shapes)
|
| 237 |
+
wanted_numel = sum(s.numel() for s in frozen_param_shapes.values())
|
| 238 |
+
avail_numel = sum([p.numel() for p in frozen_param_fragments.values()])
|
| 239 |
+
print(f'Frozen params: Have {avail_numel} numels to process.')
|
| 240 |
+
print(f'Frozen params: Need {wanted_numel} numels in {wanted_params} params')
|
| 241 |
+
|
| 242 |
+
total_params = 0
|
| 243 |
+
total_numel = 0
|
| 244 |
+
for name, shape in frozen_param_shapes.items():
|
| 245 |
+
total_params += 1
|
| 246 |
+
unpartitioned_numel = shape.numel()
|
| 247 |
+
total_numel += unpartitioned_numel
|
| 248 |
+
|
| 249 |
+
state_dict[name] = frozen_param_fragments[name]
|
| 250 |
+
|
| 251 |
+
if debug:
|
| 252 |
+
print(f"{name} full shape: {shape} unpartitioned numel {unpartitioned_numel} ")
|
| 253 |
+
|
| 254 |
+
print(f"Reconstructed Frozen fp32 state dict with {total_params} params {total_numel} elements")
|
| 255 |
+
|
| 256 |
+
|
| 257 |
+
def _has_callable(obj, fn):
|
| 258 |
+
attr = getattr(obj, fn, None)
|
| 259 |
+
return callable(attr)
|
| 260 |
+
|
| 261 |
+
|
| 262 |
+
def _zero2_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states):
|
| 263 |
+
param_shapes = zero_model_states[0].param_shapes
|
| 264 |
+
|
| 265 |
+
# Reconstruction protocol:
|
| 266 |
+
#
|
| 267 |
+
# XXX: document this
|
| 268 |
+
|
| 269 |
+
if debug:
|
| 270 |
+
for i in range(world_size):
|
| 271 |
+
for j in range(len(fp32_flat_groups[0])):
|
| 272 |
+
print(f"{FP32_FLAT_GROUPS}[{i}][{j}].shape={fp32_flat_groups[i][j].shape}")
|
| 273 |
+
|
| 274 |
+
# XXX: memory usage doubles here (zero2)
|
| 275 |
+
num_param_groups = len(fp32_flat_groups[0])
|
| 276 |
+
merged_single_partition_of_fp32_groups = []
|
| 277 |
+
for i in range(num_param_groups):
|
| 278 |
+
merged_partitions = [sd[i] for sd in fp32_flat_groups]
|
| 279 |
+
full_single_fp32_vector = torch.cat(merged_partitions, 0)
|
| 280 |
+
merged_single_partition_of_fp32_groups.append(full_single_fp32_vector)
|
| 281 |
+
avail_numel = sum(
|
| 282 |
+
[full_single_fp32_vector.numel() for full_single_fp32_vector in merged_single_partition_of_fp32_groups])
|
| 283 |
+
|
| 284 |
+
if debug:
|
| 285 |
+
wanted_params = sum([len(shapes) for shapes in param_shapes])
|
| 286 |
+
wanted_numel = sum([sum(shape.numel() for shape in shapes.values()) for shapes in param_shapes])
|
| 287 |
+
# not asserting if there is a mismatch due to possible padding
|
| 288 |
+
print(f"Have {avail_numel} numels to process.")
|
| 289 |
+
print(f"Need {wanted_numel} numels in {wanted_params} params.")
|
| 290 |
+
|
| 291 |
+
# params
|
| 292 |
+
# XXX: for huge models that can't fit into the host's RAM we will have to recode this to support
|
| 293 |
+
# out-of-core computing solution
|
| 294 |
+
total_numel = 0
|
| 295 |
+
total_params = 0
|
| 296 |
+
for shapes, full_single_fp32_vector in zip(param_shapes, merged_single_partition_of_fp32_groups):
|
| 297 |
+
offset = 0
|
| 298 |
+
avail_numel = full_single_fp32_vector.numel()
|
| 299 |
+
for name, shape in shapes.items():
|
| 300 |
+
|
| 301 |
+
unpartitioned_numel = shape.numel() if _has_callable(shape, 'numel') else math.prod(shape)
|
| 302 |
+
total_numel += unpartitioned_numel
|
| 303 |
+
total_params += 1
|
| 304 |
+
|
| 305 |
+
if debug:
|
| 306 |
+
print(f"{name} full shape: {shape} unpartitioned numel {unpartitioned_numel} ")
|
| 307 |
+
state_dict[name] = full_single_fp32_vector.narrow(0, offset, unpartitioned_numel).view(shape)
|
| 308 |
+
offset += unpartitioned_numel
|
| 309 |
+
|
| 310 |
+
# Z2 started to align to 2*world_size to improve nccl performance. Therefore both offset and
|
| 311 |
+
# avail_numel can differ by anywhere between 0..2*world_size. Due to two unrelated complex
|
| 312 |
+
# paddings performed in the code it's almost impossible to predict the exact numbers w/o the
|
| 313 |
+
# live optimizer object, so we are checking that the numbers are within the right range
|
| 314 |
+
align_to = 2 * world_size
|
| 315 |
+
|
| 316 |
+
def zero2_align(x):
|
| 317 |
+
return align_to * math.ceil(x / align_to)
|
| 318 |
+
|
| 319 |
+
if debug:
|
| 320 |
+
print(f"original offset={offset}, avail_numel={avail_numel}")
|
| 321 |
+
|
| 322 |
+
offset = zero2_align(offset)
|
| 323 |
+
avail_numel = zero2_align(avail_numel)
|
| 324 |
+
|
| 325 |
+
if debug:
|
| 326 |
+
print(f"aligned offset={offset}, avail_numel={avail_numel}")
|
| 327 |
+
|
| 328 |
+
# Sanity check
|
| 329 |
+
if offset != avail_numel:
|
| 330 |
+
raise ValueError(f"consumed {offset} numels out of {avail_numel} - something is wrong")
|
| 331 |
+
|
| 332 |
+
print(f"Reconstructed fp32 state dict with {total_params} params {total_numel} elements")
|
| 333 |
+
|
| 334 |
+
|
| 335 |
+
def _get_fp32_state_dict_from_zero2_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 336 |
+
exclude_frozen_parameters):
|
| 337 |
+
state_dict = OrderedDict()
|
| 338 |
+
|
| 339 |
+
# buffers
|
| 340 |
+
buffers = zero_model_states[0].buffers
|
| 341 |
+
state_dict.update(buffers)
|
| 342 |
+
if debug:
|
| 343 |
+
print(f"added {len(buffers)} buffers")
|
| 344 |
+
|
| 345 |
+
if not exclude_frozen_parameters:
|
| 346 |
+
_zero2_merge_frozen_params(state_dict, zero_model_states)
|
| 347 |
+
|
| 348 |
+
_zero2_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states)
|
| 349 |
+
|
| 350 |
+
# recover shared parameters
|
| 351 |
+
for pair in zero_model_states[0].shared_params:
|
| 352 |
+
if pair[1] in state_dict:
|
| 353 |
+
state_dict[pair[0]] = state_dict[pair[1]]
|
| 354 |
+
|
| 355 |
+
return state_dict
|
| 356 |
+
|
| 357 |
+
|
| 358 |
+
def zero3_partitioned_param_info(unpartitioned_numel, world_size):
|
| 359 |
+
remainder = unpartitioned_numel % world_size
|
| 360 |
+
padding_numel = (world_size - remainder) if remainder else 0
|
| 361 |
+
partitioned_numel = math.ceil(unpartitioned_numel / world_size)
|
| 362 |
+
return partitioned_numel, padding_numel
|
| 363 |
+
|
| 364 |
+
|
| 365 |
+
def _zero3_merge_frozen_params(state_dict, world_size, zero_model_states):
|
| 366 |
+
if zero_model_states[0].frozen_param_shapes is None or len(zero_model_states[0].frozen_param_shapes) == 0:
|
| 367 |
+
return
|
| 368 |
+
|
| 369 |
+
if debug:
|
| 370 |
+
for i in range(world_size):
|
| 371 |
+
num_elem = sum(s.numel() for s in zero_model_states[i].frozen_param_fragments.values())
|
| 372 |
+
print(f'rank {i}: {FROZEN_PARAM_SHAPES}.numel = {num_elem}')
|
| 373 |
+
|
| 374 |
+
frozen_param_shapes = zero_model_states[0].frozen_param_shapes
|
| 375 |
+
wanted_params = len(frozen_param_shapes)
|
| 376 |
+
wanted_numel = sum(s.numel() for s in frozen_param_shapes.values())
|
| 377 |
+
avail_numel = sum([p.numel() for p in zero_model_states[0].frozen_param_fragments.values()]) * world_size
|
| 378 |
+
print(f'Frozen params: Have {avail_numel} numels to process.')
|
| 379 |
+
print(f'Frozen params: Need {wanted_numel} numels in {wanted_params} params')
|
| 380 |
+
|
| 381 |
+
total_params = 0
|
| 382 |
+
total_numel = 0
|
| 383 |
+
for name, shape in zero_model_states[0].frozen_param_shapes.items():
|
| 384 |
+
total_params += 1
|
| 385 |
+
unpartitioned_numel = shape.numel()
|
| 386 |
+
total_numel += unpartitioned_numel
|
| 387 |
+
|
| 388 |
+
param_frags = tuple(model_state.frozen_param_fragments[name] for model_state in zero_model_states)
|
| 389 |
+
state_dict[name] = torch.cat(param_frags, 0).narrow(0, 0, unpartitioned_numel).view(shape)
|
| 390 |
+
|
| 391 |
+
partitioned_numel, partitioned_padding_numel = zero3_partitioned_param_info(unpartitioned_numel, world_size)
|
| 392 |
+
|
| 393 |
+
if debug:
|
| 394 |
+
print(
|
| 395 |
+
f"Frozen params: {total_params} {name} full shape: {shape} partition0 numel={partitioned_numel} partitioned_padding_numel={partitioned_padding_numel}"
|
| 396 |
+
)
|
| 397 |
+
|
| 398 |
+
print(f"Reconstructed Frozen fp32 state dict with {total_params} params {total_numel} elements")
|
| 399 |
+
|
| 400 |
+
|
| 401 |
+
def _zero3_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states):
|
| 402 |
+
param_shapes = zero_model_states[0].param_shapes
|
| 403 |
+
avail_numel = fp32_flat_groups[0].numel() * world_size
|
| 404 |
+
# Reconstruction protocol: For zero3 we need to zip the partitions together at boundary of each
|
| 405 |
+
# param, re-consolidating each param, while dealing with padding if any
|
| 406 |
+
|
| 407 |
+
# merge list of dicts, preserving order
|
| 408 |
+
param_shapes = {k: v for d in param_shapes for k, v in d.items()}
|
| 409 |
+
|
| 410 |
+
if debug:
|
| 411 |
+
for i in range(world_size):
|
| 412 |
+
print(f"{FP32_FLAT_GROUPS}[{i}].shape={fp32_flat_groups[i].shape}")
|
| 413 |
+
|
| 414 |
+
wanted_params = len(param_shapes)
|
| 415 |
+
wanted_numel = sum(shape.numel() for shape in param_shapes.values())
|
| 416 |
+
# not asserting if there is a mismatch due to possible padding
|
| 417 |
+
avail_numel = fp32_flat_groups[0].numel() * world_size
|
| 418 |
+
print(f"Trainable params: Have {avail_numel} numels to process.")
|
| 419 |
+
print(f"Trainable params: Need {wanted_numel} numels in {wanted_params} params.")
|
| 420 |
+
|
| 421 |
+
# params
|
| 422 |
+
# XXX: for huge models that can't fit into the host's RAM we will have to recode this to support
|
| 423 |
+
# out-of-core computing solution
|
| 424 |
+
offset = 0
|
| 425 |
+
total_numel = 0
|
| 426 |
+
total_params = 0
|
| 427 |
+
for name, shape in tqdm(param_shapes.items(), desc='Gathering Sharded Weights'):
|
| 428 |
+
unpartitioned_numel = shape.numel()
|
| 429 |
+
total_numel += unpartitioned_numel
|
| 430 |
+
total_params += 1
|
| 431 |
+
partitioned_numel, partitioned_padding_numel = zero3_partitioned_param_info(unpartitioned_numel, world_size)
|
| 432 |
+
|
| 433 |
+
if debug:
|
| 434 |
+
print(
|
| 435 |
+
f"Trainable params: {total_params} {name} full shape: {shape} partition0 numel={partitioned_numel} partitioned_padding_numel={partitioned_padding_numel}"
|
| 436 |
+
)
|
| 437 |
+
|
| 438 |
+
# XXX: memory usage doubles here
|
| 439 |
+
state_dict[name] = torch.cat(
|
| 440 |
+
tuple(fp32_flat_groups[i].narrow(0, offset, partitioned_numel) for i in range(world_size)),
|
| 441 |
+
0).narrow(0, 0, unpartitioned_numel).view(shape)
|
| 442 |
+
offset += partitioned_numel
|
| 443 |
+
|
| 444 |
+
offset *= world_size
|
| 445 |
+
|
| 446 |
+
# Sanity check
|
| 447 |
+
if offset != avail_numel:
|
| 448 |
+
raise ValueError(f"consumed {offset} numels out of {avail_numel} - something is wrong")
|
| 449 |
+
|
| 450 |
+
print(f"Reconstructed Trainable fp32 state dict with {total_params} params {total_numel} elements")
|
| 451 |
+
|
| 452 |
+
|
| 453 |
+
def _get_fp32_state_dict_from_zero3_checkpoint(world_size, fp32_flat_groups, zero_model_states,
|
| 454 |
+
exclude_frozen_parameters):
|
| 455 |
+
state_dict = OrderedDict()
|
| 456 |
+
|
| 457 |
+
# buffers
|
| 458 |
+
buffers = zero_model_states[0].buffers
|
| 459 |
+
state_dict.update(buffers)
|
| 460 |
+
if debug:
|
| 461 |
+
print(f"added {len(buffers)} buffers")
|
| 462 |
+
|
| 463 |
+
if not exclude_frozen_parameters:
|
| 464 |
+
_zero3_merge_frozen_params(state_dict, world_size, zero_model_states)
|
| 465 |
+
|
| 466 |
+
_zero3_merge_trainable_params(state_dict, world_size, fp32_flat_groups, zero_model_states)
|
| 467 |
+
|
| 468 |
+
# recover shared parameters
|
| 469 |
+
for pair in zero_model_states[0].shared_params:
|
| 470 |
+
if pair[1] in state_dict:
|
| 471 |
+
state_dict[pair[0]] = state_dict[pair[1]]
|
| 472 |
+
|
| 473 |
+
return state_dict
|
| 474 |
+
|
| 475 |
+
|
| 476 |
+
def get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag=None, exclude_frozen_parameters=False):
|
| 477 |
+
"""
|
| 478 |
+
Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated state_dict that can be loaded with
|
| 479 |
+
``load_state_dict()`` and used for training without DeepSpeed or shared with others, for example
|
| 480 |
+
via a model hub.
|
| 481 |
+
|
| 482 |
+
Args:
|
| 483 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder
|
| 484 |
+
- ``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``
|
| 485 |
+
- ``exclude_frozen_parameters``: exclude frozen parameters
|
| 486 |
+
|
| 487 |
+
Returns:
|
| 488 |
+
- pytorch ``state_dict``
|
| 489 |
+
|
| 490 |
+
Note: this approach may not work if your application doesn't have sufficient free CPU memory and
|
| 491 |
+
you may need to use the offline approach using the ``zero_to_fp32.py`` script that is saved with
|
| 492 |
+
the checkpoint.
|
| 493 |
+
|
| 494 |
+
A typical usage might be ::
|
| 495 |
+
|
| 496 |
+
from deepspeed.utils.zero_to_fp32 import get_fp32_state_dict_from_zero_checkpoint
|
| 497 |
+
# do the training and checkpoint saving
|
| 498 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir) # already on cpu
|
| 499 |
+
model = model.cpu() # move to cpu
|
| 500 |
+
model.load_state_dict(state_dict)
|
| 501 |
+
# submit to model hub or save the model to share with others
|
| 502 |
+
|
| 503 |
+
In this example the ``model`` will no longer be usable in the deepspeed context of the same
|
| 504 |
+
application. i.e. you will need to re-initialize the deepspeed engine, since
|
| 505 |
+
``model.load_state_dict(state_dict)`` will remove all the deepspeed magic from it.
|
| 506 |
+
|
| 507 |
+
If you want it all done for you, use ``load_state_dict_from_zero_checkpoint`` instead.
|
| 508 |
+
|
| 509 |
+
"""
|
| 510 |
+
if tag is None:
|
| 511 |
+
latest_path = os.path.join(checkpoint_dir, 'latest')
|
| 512 |
+
if os.path.isfile(latest_path):
|
| 513 |
+
with open(latest_path, 'r') as fd:
|
| 514 |
+
tag = fd.read().strip()
|
| 515 |
+
else:
|
| 516 |
+
raise ValueError(f"Unable to find 'latest' file at {latest_path}")
|
| 517 |
+
|
| 518 |
+
ds_checkpoint_dir = os.path.join(checkpoint_dir, tag)
|
| 519 |
+
|
| 520 |
+
if not os.path.isdir(ds_checkpoint_dir):
|
| 521 |
+
raise FileNotFoundError(f"Directory '{ds_checkpoint_dir}' doesn't exist")
|
| 522 |
+
|
| 523 |
+
return _get_fp32_state_dict_from_zero_checkpoint(ds_checkpoint_dir, exclude_frozen_parameters)
|
| 524 |
+
|
| 525 |
+
|
| 526 |
+
def convert_zero_checkpoint_to_fp32_state_dict(checkpoint_dir,
|
| 527 |
+
output_dir,
|
| 528 |
+
max_shard_size="5GB",
|
| 529 |
+
safe_serialization=False,
|
| 530 |
+
tag=None,
|
| 531 |
+
exclude_frozen_parameters=False):
|
| 532 |
+
"""
|
| 533 |
+
Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated ``state_dict`` file that can be
|
| 534 |
+
loaded with ``torch.load(file)`` + ``load_state_dict()`` and used for training without DeepSpeed.
|
| 535 |
+
|
| 536 |
+
Args:
|
| 537 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder. (one that contains the tag-folder, like ``global_step14``)
|
| 538 |
+
- ``output_dir``: directory to the pytorch fp32 state_dict output files
|
| 539 |
+
- ``max_shard_size``: the maximum size for a checkpoint before being sharded, default value is 5GB
|
| 540 |
+
- ``safe_serialization``: whether to save the model using `safetensors` or the traditional PyTorch way (that uses `pickle`).
|
| 541 |
+
- ``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``
|
| 542 |
+
- ``exclude_frozen_parameters``: exclude frozen parameters
|
| 543 |
+
"""
|
| 544 |
+
# Dependency pre-check
|
| 545 |
+
if safe_serialization:
|
| 546 |
+
try:
|
| 547 |
+
from safetensors.torch import save_file
|
| 548 |
+
except ImportError:
|
| 549 |
+
print('If you want to use `safe_serialization`, please `pip install safetensors`')
|
| 550 |
+
raise
|
| 551 |
+
if max_shard_size is not None:
|
| 552 |
+
try:
|
| 553 |
+
from huggingface_hub import split_torch_state_dict_into_shards
|
| 554 |
+
except ImportError:
|
| 555 |
+
print('If you want to use `max_shard_size`, please `pip install huggingface_hub`')
|
| 556 |
+
raise
|
| 557 |
+
|
| 558 |
+
# Convert zero checkpoint to state_dict
|
| 559 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag, exclude_frozen_parameters)
|
| 560 |
+
|
| 561 |
+
# Shard the model if it is too big.
|
| 562 |
+
weights_name = "model.safetensors" if safe_serialization else "pytorch_model.bin"
|
| 563 |
+
if max_shard_size is not None:
|
| 564 |
+
filename_pattern = weights_name.replace(".bin", "{suffix}.bin").replace(".safetensors", "{suffix}.safetensors")
|
| 565 |
+
state_dict_split = split_torch_state_dict_into_shards(state_dict,
|
| 566 |
+
filename_pattern=filename_pattern,
|
| 567 |
+
max_shard_size=max_shard_size)
|
| 568 |
+
else:
|
| 569 |
+
from collections import namedtuple
|
| 570 |
+
StateDictSplit = namedtuple("StateDictSplit", ["is_sharded", "filename_to_tensors"])
|
| 571 |
+
state_dict_split = StateDictSplit(is_sharded=False,
|
| 572 |
+
filename_to_tensors={weights_name: list(state_dict.keys())})
|
| 573 |
+
|
| 574 |
+
# Save the model
|
| 575 |
+
filename_to_tensors = state_dict_split.filename_to_tensors.items()
|
| 576 |
+
for shard_file, tensors in tqdm(filename_to_tensors, desc="Saving checkpoint shards"):
|
| 577 |
+
shard = {tensor: state_dict[tensor].contiguous() for tensor in tensors}
|
| 578 |
+
output_path = os.path.join(output_dir, shard_file)
|
| 579 |
+
if safe_serialization:
|
| 580 |
+
save_file(shard, output_path, metadata={"format": "pt"})
|
| 581 |
+
else:
|
| 582 |
+
torch.save(shard, output_path)
|
| 583 |
+
|
| 584 |
+
# Save index if sharded
|
| 585 |
+
if state_dict_split.is_sharded:
|
| 586 |
+
index = {
|
| 587 |
+
"metadata": state_dict_split.metadata,
|
| 588 |
+
"weight_map": state_dict_split.tensor_to_filename,
|
| 589 |
+
}
|
| 590 |
+
save_index_file = "model.safetensors.index.json" if safe_serialization else "pytorch_model.bin.index.json"
|
| 591 |
+
save_index_file = os.path.join(output_dir, save_index_file)
|
| 592 |
+
with open(save_index_file, "w", encoding="utf-8") as f:
|
| 593 |
+
content = json.dumps(index, indent=2, sort_keys=True) + "\n"
|
| 594 |
+
f.write(content)
|
| 595 |
+
|
| 596 |
+
|
| 597 |
+
def load_state_dict_from_zero_checkpoint(model, checkpoint_dir, tag=None):
|
| 598 |
+
"""
|
| 599 |
+
1. Put the provided model to cpu
|
| 600 |
+
2. Convert ZeRO 2 or 3 checkpoint into a single fp32 consolidated ``state_dict``
|
| 601 |
+
3. Load it into the provided model
|
| 602 |
+
|
| 603 |
+
Args:
|
| 604 |
+
- ``model``: the model object to update
|
| 605 |
+
- ``checkpoint_dir``: path to the desired checkpoint folder. (one that contains the tag-folder, like ``global_step14``)
|
| 606 |
+
- ``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``
|
| 607 |
+
|
| 608 |
+
Returns:
|
| 609 |
+
- ``model`: modified model
|
| 610 |
+
|
| 611 |
+
Make sure you have plenty of CPU memory available before you call this function. If you don't
|
| 612 |
+
have enough use the ``zero_to_fp32.py`` utility to do the conversion. You will find it
|
| 613 |
+
conveniently placed for you in the checkpoint folder.
|
| 614 |
+
|
| 615 |
+
A typical usage might be ::
|
| 616 |
+
|
| 617 |
+
from deepspeed.utils.zero_to_fp32 import load_state_dict_from_zero_checkpoint
|
| 618 |
+
model = load_state_dict_from_zero_checkpoint(trainer.model, checkpoint_dir)
|
| 619 |
+
# submit to model hub or save the model to share with others
|
| 620 |
+
|
| 621 |
+
Note, that once this was run, the ``model`` will no longer be usable in the deepspeed context
|
| 622 |
+
of the same application. i.e. you will need to re-initialize the deepspeed engine, since
|
| 623 |
+
``model.load_state_dict(state_dict)`` will remove all the deepspeed magic from it.
|
| 624 |
+
|
| 625 |
+
"""
|
| 626 |
+
logger.info(f"Extracting fp32 weights")
|
| 627 |
+
state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir, tag)
|
| 628 |
+
|
| 629 |
+
logger.info(f"Overwriting model with fp32 weights")
|
| 630 |
+
model = model.cpu()
|
| 631 |
+
model.load_state_dict(state_dict, strict=False)
|
| 632 |
+
|
| 633 |
+
return model
|
| 634 |
+
|
| 635 |
+
|
| 636 |
+
if __name__ == "__main__":
|
| 637 |
+
parser = argparse.ArgumentParser()
|
| 638 |
+
parser.add_argument("checkpoint_dir",
|
| 639 |
+
type=str,
|
| 640 |
+
help="path to the desired checkpoint folder, e.g., path/checkpoint-12")
|
| 641 |
+
parser.add_argument("output_dir",
|
| 642 |
+
type=str,
|
| 643 |
+
help="directory to the pytorch fp32 state_dict output files"
|
| 644 |
+
"(e.g. path/checkpoint-12-output/)")
|
| 645 |
+
parser.add_argument(
|
| 646 |
+
"--max_shard_size",
|
| 647 |
+
type=str,
|
| 648 |
+
default="5GB",
|
| 649 |
+
help="The maximum size for a checkpoint before being sharded. Checkpoints shard will then be each of size"
|
| 650 |
+
"lower than this size. If expressed as a string, needs to be digits followed by a unit (like `5MB`"
|
| 651 |
+
"We default it to 5GB in order for models to be able to run easily on free-tier google colab instances"
|
| 652 |
+
"without CPU OOM issues.")
|
| 653 |
+
parser.add_argument(
|
| 654 |
+
"--safe_serialization",
|
| 655 |
+
default=False,
|
| 656 |
+
action='store_true',
|
| 657 |
+
help="Whether to save the model using `safetensors` or the traditional PyTorch way (that uses `pickle`).")
|
| 658 |
+
parser.add_argument("-t",
|
| 659 |
+
"--tag",
|
| 660 |
+
type=str,
|
| 661 |
+
default=None,
|
| 662 |
+
help="checkpoint tag used as a unique identifier for checkpoint. e.g., global_step1")
|
| 663 |
+
parser.add_argument("--exclude_frozen_parameters", action='store_true', help="exclude frozen parameters")
|
| 664 |
+
parser.add_argument("-d", "--debug", action='store_true', help="enable debug")
|
| 665 |
+
args = parser.parse_args()
|
| 666 |
+
|
| 667 |
+
debug = args.debug
|
| 668 |
+
|
| 669 |
+
convert_zero_checkpoint_to_fp32_state_dict(args.checkpoint_dir,
|
| 670 |
+
args.output_dir,
|
| 671 |
+
max_shard_size=args.max_shard_size,
|
| 672 |
+
safe_serialization=args.safe_serialization,
|
| 673 |
+
tag=args.tag,
|
| 674 |
+
exclude_frozen_parameters=args.exclude_frozen_parameters)
|
merges.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|