Upload folder using huggingface_hub
Browse files- .gitattributes +2 -0
- README.md +67 -0
- llama-3-8b-spectrum-25.Q3_K_M.gguf +3 -0
- llama-3-8b-spectrum-25.bf16.gguf +3 -0
.gitattributes
CHANGED
@@ -33,3 +33,5 @@ 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 |
+
llama-3-8b-spectrum-25.Q3_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
37 |
+
llama-3-8b-spectrum-25.bf16.gguf filter=lfs diff=lfs merge=lfs -text
|
README.md
ADDED
@@ -0,0 +1,67 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
base_model: meta-llama/Meta-Llama-3-8B-Instruct
|
3 |
+
library_name: transformers
|
4 |
+
license: llama3
|
5 |
+
tags:
|
6 |
+
- axolotl
|
7 |
+
- generated_from_trainer
|
8 |
+
- spectrum finetuning
|
9 |
+
- Deepspeed MultiGPU
|
10 |
+
- autoquant
|
11 |
+
- gguf
|
12 |
+
model-index:
|
13 |
+
- name: Llama-3-8B-spectrum-25
|
14 |
+
results: []
|
15 |
+
---
|
16 |
+
|
17 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
18 |
+
should probably proofread and complete it, then remove this comment. -->
|
19 |
+
|
20 |
+
|
21 |
+
# Llama-3-8B-spectrum-25
|
22 |
+
|
23 |
+
This model is a fine-tuned version of [meta-llama/Meta-Llama-3-8B-Instruct](https://huggingface.co/meta-llama/Meta-Llama-3-8B-Instruct) on the [yuvraj17/finetune_alpaca_1K](https://huggingface.co/datasets/yuvraj17/finetune_alpaca_1K) dataset.
|
24 |
+
It achieves the following results on the evaluation set:
|
25 |
+
- Loss: 1.2791
|
26 |
+
|
27 |
+
## Spectrum Fine-tuning:
|
28 |
+
I have used the **Spectrum Fine-tuning** method as described in [Eric Hartford et. al 2024](https://arxiv.org/abs/2406.06623), which selectively targets some ***t%*** of the model layers with the highest **Signal-to-Noise Ratio (SNR)**. By focusing on the most information-dense layers, this approach maximizes fine-tuning efficiency while minimizing compute resources.
|
29 |
+
|
30 |
+
**The key goal of Spectrum Fine-tuning is:** *minimize the memory footprint and accelerate LLM training without sacrificing performance.*
|
31 |
+
|
32 |
+
The 25% layer selection ensures minimal computational overhead for fine-tuning.
|
33 |
+
|
34 |
+
## Training:
|
35 |
+
- Trained on **2x A40s (48GB VRAM each)** for over 1 hour using the **Axolotl**.
|
36 |
+
|
37 |
+
|
38 |
+
### Training hyperparameters
|
39 |
+
|
40 |
+
The following hyperparameters were used during training:
|
41 |
+
- learning_rate: 0.0002
|
42 |
+
- train_batch_size: 4
|
43 |
+
- eval_batch_size: 4
|
44 |
+
- seed: 42
|
45 |
+
- distributed_type: multi-GPU
|
46 |
+
- num_devices: 2
|
47 |
+
- gradient_accumulation_steps: 4
|
48 |
+
- total_train_batch_size: 32
|
49 |
+
- total_eval_batch_size: 8
|
50 |
+
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
51 |
+
- lr_scheduler_type: cosine
|
52 |
+
- lr_scheduler_warmup_steps: 100
|
53 |
+
- num_epochs: 2
|
54 |
+
|
55 |
+
|
56 |
+
![Train/loss Curve Image](https://cdn-uploads.huggingface.co/production/uploads/66137d95e8d2cda230ddcea6/eSBh0SmeGYYUfx9pKgMIv.png)
|
57 |
+
|
58 |
+
![eval/loss Curve Image](https://cdn-uploads.huggingface.co/production/uploads/66137d95e8d2cda230ddcea6/xNslkLH1pKot7tzWtIiu9.png)
|
59 |
+
|
60 |
+
|
61 |
+
### Framework versions
|
62 |
+
|
63 |
+
- Axolotl 0.4.1
|
64 |
+
- Transformers 4.44.2
|
65 |
+
- Pytorch 2.4.0+cu121
|
66 |
+
- Datasets 2.20.0
|
67 |
+
- Tokenizers 0.19.1
|
llama-3-8b-spectrum-25.Q3_K_M.gguf
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:6ae792bae84df7b4dea2af9b840cc701d237affcdc82fb3d5c49bfabeff51135
|
3 |
+
size 4018918432
|
llama-3-8b-spectrum-25.bf16.gguf
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:06b867950170fd81e415110edb331489f05ec4a37a723effbf052773695b256f
|
3 |
+
size 16068891680
|