luow-amd haoyang-amd commited on
Commit
2f1694e
·
verified ·
1 Parent(s): bd5a67b

Update README.md (#2)

Browse files

- Update README.md (4424bc0175b9a641f564ce38ee0fa8ce7adaac99)


Co-authored-by: haoyanli <[email protected]>

Files changed (1) hide show
  1. README.md +48 -3
README.md CHANGED
@@ -1,3 +1,48 @@
1
- ---
2
- license: llama3.2
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model:
3
+ - meta-llama/Llama-3.2-90B-Vision-Instruct
4
+ license: llama3.2
5
+ ---
6
+ # Llama-3.2-90B-Vision-Instruct-FP8-KV
7
+ - ## Introduction
8
+ This model was created by applying [Quark](https://quark.docs.amd.com/latest/index.html) with calibration samples from Pile dataset.
9
+ - ## Quantization Stragegy
10
+ - ***Weight***: FP8 symmetric per-tensor
11
+ - ***Activation***: FP8 symmetric per-tensor
12
+ - ***KV Cache***: FP8 symmetric per-tensor
13
+ - ***Note***: The Llama-3.2-90B-Vision-Instruct consists of two parts: the language model (MllamaForCausalLM) and the vision model (MllamaVisionModel). Here, we only quantize the MllamaForCausalLM.
14
+ - ## Quick Start
15
+ 1. [Download and install Quark](https://quark.docs.amd.com/latest/install.html)
16
+ 2. Run the quantization script in the example folder using the following command line:
17
+ ```sh
18
+ export MODEL_DIR = [local model checkpoint folder] or meta-llama/Llama-3.2-90B-Vision-Instruct
19
+ # single GPU
20
+ python3 quantize_quark.py \
21
+ --model_dir $MODEL_DIR \
22
+ --output_dir Llama-3.2-90B-Vision-Instruct-FP8-KV \
23
+ --quant_scheme w_fp8_a_fp8 \
24
+ --kv_cache_dtype fp8 \
25
+ --num_calib_data 128 \
26
+ # If model size is too large for single GPU, please use multi GPU instead.
27
+ python3 quantize_quark.py \
28
+ --model_dir $MODEL_DIR \
29
+ --output_dir Llama-3.2-90B-Vision-Instruct-FP8-KV \
30
+ --quant_scheme w_fp8_a_fp8 \
31
+ --kv_cache_dtype fp8 \
32
+ --num_calib_data 128 \
33
+ <tr>
34
+ <td><strong>Benchmark</strong>
35
+ </td>
36
+ <td><strong>Llama-3.2-90B-Vision-Instruct </strong>
37
+ </td>
38
+ <td><strong>Llama-3.2-90B-Vision-Instruct-FP8-KV(this model)</strong>
39
+ </td>
40
+ </tr>
41
+ <tr>
42
+ <td>Perplexity-wikitext2
43
+ </td>
44
+ <td>3.7805
45
+ </td>
46
+ <td>3.8570
47
+ </td>
48
+ </tr>