Neural Network Gradient Correction for Low-Bit Quantization

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing methods for training low-bit quantization neural networks focus solely on minimizing forward propagation quantization error, neglecting its impact on gradient calculation, which leads to inconsistency in forward and backward calculations, making them unsuitable for resource-constrained devices.

Innovation Solution

A training method that quantizes continuous real-valued network parameters, calculates and corrects the gradient based on quantization error in both magnitude and direction, and updates the network model using the corrected gradient to reduce inconsistency and enhance performance.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Power

If low-bit quantization is applied to reduce calculation amount, then device resource requirements are reduced, but gradient calculation accuracy deteriorates due to non-differentiable step functions

Engineering Contradiction:
Improvecalculation amountVSAvoidgradient calculation accuracy
Core Design Contradiction:
PowerVSMeasurement precision

Solution Approach 1:

The patent introduces a gradient correction term as an intermediary to bridge the gap between forward propagation quantization error and backward propagation gradient calculation. This correction term compensates for the non-differentiable nature of quantization by adding an auxiliary gradient component that accounts for quantization effects, thereby maintaining gradient accuracy while preserving low-bit quantization benefits

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The patent modifies the gradient calculation parameters by incorporating quantization error compensation terms. Specifically, it adjusts the gradient update rule to include correction factors derived from quantization characteristics, transforming the standard gradient descent into a quantization-aware gradient descent that maintains accuracy in low-bit representations

Inventive Principle:
Principle #35Parameter changes

2Measurement precision

If quantization error minimization is focused in forward propagation, then quantization accuracy improves, but gradient calculation consistency deteriorates due to ignoring quantization error impact on backward propagation

Engineering Contradiction:
Improvequantization accuracyVSAvoidgradient calculation consistency
Core Design Contradiction:
Measurement precisionVSStability of the object's composition

Solution Approach 1:

The patent implements a feedback mechanism where quantization error information from forward propagation is fed back into the backward propagation gradient calculation. The quantization error and its derivatives are used to generate correction terms that adjust the gradient updates, creating a closed-loop system that maintains consistency between forward and backward calculations

Inventive Principle:
Principle #23Feedback

Solution Approach 2:

The patent converts the harmful effect of quantization error into a beneficial correction signal. Instead of treating quantization error purely as noise to be minimized, it utilizes the error information to generate gradient correction terms that improve the consistency and accuracy of backward propagation, transforming a detrimental factor into a useful component

Inventive Principle:
Principle #22Blessing in disguise (Convert harm into benefit)

Data Source

PatentUS20240020519A1Training and application method and apparatus for neural network model, and storage medium
Publication Date: 2024.01.18 CANON KK
  • US20240020519A1 patent drawing
  • US20240020519A1 patent drawing
  • US20240020519A1 patent drawing

AI summary

The present disclosure provides training and application methods and apparatuses for a neural network model, and a storage medium. The training method includes: quantizing, in a forward transfer process, a network parameter represented by a continuous real value, and calculating a quantization error; determining, in a backward transfer process, a gradient of a weight in the neural network model; correcting the gradient of the weight based on the calculated quantization error, wherein the correcting includes correcting a magnitude of the gradient and correcting a direction of the gradient; and updating the neural network model according to the corrected gradient.