Stochastic Data Type Conversion for Repeated AI Computation

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing deep learning models face challenges in balancing computing power demand and precision during data type conversions, leading to reduced accuracy over multiple iterations due to repeated data type conversions.

Innovation Solution

A method for converting input data from a first data type to a second data type using stochastic rounding, where comparison data is generated and compared with random data to determine if the mantissa bit needs to be carried or rounded, maintaining precision during multiple iterations.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Use of energy by moving object

If data type conversion from high-precision to low-precision is performed, then resource consumption is reduced, but precision is lost after repeated conversions

Engineering Contradiction:
Improveresource consumptionVSAvoiddata precision
Core Design Contradiction:
Use of energy by moving objectVSMeasurement precision

Solution Approach 1:

The patent changes the rounding parameter from deterministic (always round down or to nearest) to stochastic (randomized rounding). By introducing randomization in the rounding process, the patent transforms the data type conversion from a precision-degrading operation to one that maintains statistical precision over multiple iterations, thus resolving the contradiction between resource consumption and precision maintenance.

Inventive Principle:
Principle #35Parameter changes

Solution Approach 2:

The patent introduces dynamic behavior into the rounding process by using random number generation. Instead of a static rounding rule, the system dynamically adjusts rounding decisions based on random values, which prevents systematic bias accumulation during repeated conversions and maintains precision while still using low-precision data types.

Inventive Principle:
Principle #15Dynamics

2Ease of manufacture

If deterministic rounding is used for data type conversion, then conversion is simple, but precision degrades over multiple iterations

Engineering Contradiction:
Improveconversion simplicityVSAvoidmodel accuracy
Core Design Contradiction:
Ease of manufactureVSMeasurement precision

Solution Approach 1:

The patent modifies the rounding parameter from fixed/deterministic to variable/stochastic. By changing how rounding decisions are made (from always rounding in one direction to randomizing the rounding direction), the patent maintains conversion simplicity while dramatically improving precision retention over multiple iterations through statistical cancellation of rounding errors.

Inventive Principle:
Principle #35Parameter changes

3Measurement precision

If high-precision data types are used throughout, then model accuracy is maintained, but computing power demand increases

Engineering Contradiction:
Improvemodel accuracyVSAvoidcomputing power demand
Core Design Contradiction:
Measurement precisionVSPower

Solution Approach 1:

The patent applies local quality by using different precision levels in different contexts: low-precision data types are used for storage and computation to reduce power demand, while stochastic rounding mechanisms locally compensate for precision loss. This allows the system to enjoy the benefits of low-precision operations while maintaining overall model accuracy through targeted precision preservation at critical conversion points.

Inventive Principle:
Principle #3Local quality

Data Source

PatentUS12481640B2Data type conversion method, storage medium, device, and printed circuit board
Publication Date: 2025.11.25 CAMBRICON (XIAN) SEMICON CO LTD
  • US12481640B2 patent drawing
  • US12481640B2 patent drawing
  • US12481640B2 patent drawing

AI summary

The present disclosure relates to a method for converting a data type, a computer readable storage medium, an apparatus, and a board card. The computing apparatus of the present disclosure is included in an integrated circuit apparatus. The integrated circuit apparatus includes a general interconnection interface and other processing apparatus. The computing apparatus interacts with other processing apparatus to jointly complete a computing operation specified by a user. The integrated circuit apparatus further includes a storage apparatus. The storage apparatus is connected to the computing apparatus and other processing apparatus, respectively. The storage apparatus is used for data storage of the computing apparatus and other processing apparatus.