Blockwise Model Quantization for Low-Power ML Inference
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing machine learning models, particularly large models like deep neural networks and large language models, are computationally expensive and intractable on resource-constrained devices due to their high memory and power requirements, necessitating efficient quantization techniques to reduce memory bandwidth and power consumption.
Innovation Solution
Implementing blockwise quantization without dedicated hardware, using software to divide model parameters into logical blocks with unique quantization parameters, allowing efficient utilization of existing compute units and reducing memory footprint while preserving model accuracy.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Use of energy by moving object
If standard quantization techniques are used to reduce memory footprint and power consumption, then resource efficiency is improved, but model accuracy deteriorates
Solution Approach 1:
The patent divides model parameters into multiple blocks, where each block is quantized independently with its own quantization parameters. This segmentation allows different precision levels to be applied to different parameter blocks, reducing overall memory footprint and power consumption while preserving accuracy-critical parameters at higher precision
Solution Approach 2:
The patent applies different quantization precision levels to different blocks of parameters based on their importance and sensitivity. Critical parameters maintain higher precision while less sensitive parameters use lower precision, achieving local optimization of the accuracy-power tradeoff
2Adaptability or versatility
If blockwise quantization is implemented without dedicated hardware, then device compatibility is improved, but computational complexity increases
Solution Approach 1:
The patent segments the quantization process into manageable blocks that can be processed independently, making the complex blockwise quantization operation compatible with standard hardware compute units without requiring specialized dedicated hardware blocks
Solution Approach 2:
The patent designs the blockwise quantization approach to work with existing standard hardware compute units, making the same hardware capable of handling both standard and quantized operations, thus avoiding the need for dedicated hardware while maintaining device compatibility
3Quantity of substance
If quantization is applied to reduce memory bandwidth requirements, then memory efficiency is improved, but inference quality deteriorates
Solution Approach 1:
The patent divides parameters into blocks with different quantization levels, allowing critical parameters to maintain higher precision while less critical parameters use lower precision, thereby reducing overall memory bandwidth requirements while preserving inference quality for important computations
Solution Approach 2:
Different precision levels are applied locally to different parameter blocks based on their sensitivity to quantization, ensuring that inference quality is maintained for parameters where it matters most while achieving memory bandwidth reduction overall
Data Source
AI summary
Certain aspects of the present disclosure provide techniques and apparatus for machine learning. In an example method, a first plurality of quantization scales for a set of machine learning model parameters is accessed, and a shared quantization scale for the set of machine learning model parameters is accessed. A second plurality of quantization scales is generated based on the shared quantization scale and the first plurality of quantization scales. A dequantized set of machine learning model parameters is generated based on the shared quantization scale and the second plurality of quantization scales. A machine learning model output is generated based on the dequantized set of machine learning model parameters.


