CompressedGemma commited on
Commit
5defcdf
·
verified ·
1 Parent(s): 8cd21f4

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +32 -0
README.md CHANGED
@@ -12,6 +12,38 @@ This requires a CUDA GPU, expect a 50GB model to take around 3-4 hours to quanti
12
 
13
  I prefer to llama-quantize to 8_0, then to generate a imatrix from that 8_0, and finally to quantize the 8_0 file to Q2K.
14
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
15
  # HPC-Quantize V2
16
 
17
  ## Holographic Phase Contraction, Geometry-Preserving Weight Analogs, and Algebraic Coupled Bilinear Factorization for Ultra-Low-Bit (`Q2_K`) LLM Quantization
 
12
 
13
  I prefer to llama-quantize to 8_0, then to generate a imatrix from that 8_0, and finally to quantize the 8_0 file to Q2K.
14
 
15
+ # Lattice Repair
16
+
17
+ This is NOT yet included in the quantizers automated pipeline but DOES function.
18
+
19
+ It is invoked by doing the following:
20
+
21
+ python3 lattice_repair.py \
22
+ --source BF16GGUF.gguf \
23
+ --quant QUANTGGUF.gguf \
24
+ --output OUTPUT.gguf \
25
+ --force \
26
+ --thresh 1.0 \
27
+ --fix-frames \
28
+ --dc-lambda 5.0 \
29
+ --ulp-radius 8 \
30
+ --refit-batch 512 \
31
+ --catalog ./lr_moved.csv
32
+ Or wherever you want to point the weight dumps.
33
+
34
+ Output looks like this:
35
+
36
+ blk.11.attn_output.weight [Q2_K] outliers 60829/31457280 moved 26504 (blocks 23737/122880) frame-limited 34410 in 28363 blocks, frames fixed 13822 | rmse 4.2478e-03->4.1842e-03 max|e| 5.834e-01->3.314e-01 mean|DC| 1.380e-03->4.602e-03
37
+
38
+ Numbers to pay attention to: rmse 4.2478e-03->4.1842e-03 max|e| 5.834e-01->3.314e-01.
39
+
40
+ RMSE ends up cut a little, Max Error is absolutely shattered and cut in half recovering critical function, at the cost of DC.
41
+
42
+ DC is my heuristic to assemble the LLM with a initial pass, then Lattice Repair polishes things off.
43
+
44
+ Q2K and Q3K don't really have a lot of space to move, so the weights are mostly recalculated with fix-frame to bring them closer to the source GGUF.
45
+
46
+
47
  # HPC-Quantize V2
48
 
49
  ## Holographic Phase Contraction, Geometry-Preserving Weight Analogs, and Algebraic Coupled Bilinear Factorization for Ultra-Low-Bit (`Q2_K`) LLM Quantization