An Empirical Study of OpenPangu Quantization on Ascend NPUs
This paper presents an empirical study evaluating various post-training quantization methods for OpenPangu 1B and 7B models on Huawei Ascend 910B1 NPUs, revealing that 8-bit quantization is effectively lossless while 4-bit remains practical only for the larger model, and ultra-low precision settings largely fail.
Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer
Imagine you have two very smart robots, one small (the 1B model) and one large (the 7B model). These robots are like brilliant librarians who can read, write, and solve problems. However, they are currently wearing heavy, bulky coats (the original "FP16" format) that take up a lot of space in your backpack. You want to shrink these coats down so you can carry them on a specific type of hiking gear called an Ascend NPU (a special chip made by Huawei), but you're worried that if you shrink the coats too much, the robots might forget how to think.
This paper is a "stress test" to see how much we can shrink these robot coats before they stop working properly. The researchers tried different ways to compress the data, ranging from a slight trim down to a drastic reduction.
Here is what they found, explained through simple analogies:
1. The "Light Trimming" (8-bit Quantization)
The Result: If you trim the coats just a little bit (down to 8 bits), the robots are indistinguishable from their original, heavy-coat selves.
- The Analogy: It's like taking a heavy winter coat and removing the extra lining. It's lighter and easier to carry, but the robot still feels exactly the same and can solve math problems, write code, and tell jokes just as well as before.
- Verdict: This is the safest bet. If you want to save space without losing any smarts, do this.
2. The "Drastic Shrink" (4-bit Quantization)
The Result: This is where the size of the robot matters.
- The Big Robot (7B): When you shrink the big robot's coat to 4 bits, it still works pretty well. It can still do most things, though it might stumble a little on very hard math or coding puzzles.
- The Small Robot (1B): When you try to shrink the small robot's coat to 4 bits, it starts to lose its mind. It gets confused on reasoning tasks, math, and coding.
- The Analogy: Imagine the big robot is a strong adult who can still run a marathon even if you take away their heavy boots. The small robot is a child; if you take away their heavy boots, they can't even walk across the room without tripping.
- Verdict: For the big robot, 4 bits is okay. For the small robot, 4 bits is too risky for serious tasks.
3. The "Extreme Compression" (2-bit and Binary)
The Result: When the researchers tried to shrink the coats down to 2 bits or even 1 bit (binary), the robots completely broke.
- The Analogy: This is like trying to fit a full encyclopedia into a single sticky note. The robots started guessing randomly. Their answers became nonsense, and their "perplexity" (a score for how confused they are) went off the charts, essentially becoming infinite.
- Verdict: Don't do this. The robots are effectively useless at this level of compression.
4. The "Special Shrink Wraps" (Different Methods)
The researchers tried different "techniques" to shrink the coats, like AWQ, GPTQ, and SmoothQuant.
- AWQ was like a tailor who knew exactly where to cut the fabric to keep the shape perfect. It worked the best, especially for the big robot at 4 bits.
- SmoothQuant tried to shrink both the coat and the robot's internal nervous system (activations). While it worked okay at 8 bits, when they tried to shrink it to 4 bits, the robot's nervous system short-circuited, causing it to crash (non-finite errors).
- Verdict: Some shrinkage methods are smarter than others. AWQ is the best tailor for this job, but shrinking the internal nervous system (activations) is currently too dangerous.
5. The "Granularity" (How you cut the fabric)
The paper also looked at how they cut the fabric. They found that cutting the fabric into small, specific patches (per-group) worked better than cutting it in one long strip (per-channel).
- The Analogy: Imagine patching a quilt. If you patch the whole quilt with one giant piece of fabric, it looks weird and doesn't fit well. If you cut the fabric into small squares that fit each specific patch, the quilt looks perfect.
- Verdict: Always use the "small patch" method (per-group) if your hardware supports it. It keeps the robot smarter.
Summary for the Hiker
If you are packing your Ascend NPU gear:
- Safe Choice: Shrink the coat to 8 bits. The robot stays smart, and you save space.
- Risky Choice: Shrink to 4 bits only if you have the Big Robot (7B) and you use the AWQ method. Avoid this for the Small Robot (1B) if you need it to do math or coding.
- Avoid: Do not try to shrink to 2 bits or 1 bit. The robot will stop working.
- Warning: Don't try to shrink the robot's internal nervous system (activations) yet; it causes crashes.
The paper concludes that while we can make these robots smaller and more portable, there is a hard limit. We can't just keep shrinking them forever without breaking their brains.
Drowning in papers in your field?
Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.