Image Matrix Processing Without Channel Filling Overhead

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing matrix operation methods for image data in neural networks are computationally intensive and inefficient, particularly for small matrices, due to the additional time and resource consumption caused by data rearrangement and channel filling.

Innovation Solution

A method that involves reading matrix data, calculating column data with a single instruction, multiplexing and rearranging the intermediate result into cached rows, and performing further calculations to obtain an image processing result without channel filling, optimizing the operation efficiency for small matrices.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If data rearrangement is performed on source matrix data (e.g., NC4HW4 format), then the matrix operation can be optimized for large matrices, but additional time is consumed due to large-scale data adjustment and channel filling is required

Engineering Contradiction:
Improvematrix operation efficiencyVSAvoiddata rearrangement time
Core Design Contradiction:
ProductivityVSLoss of time

Solution Approach 1:

The patent segments the matrix operation into distinct phases: data reading, column calculation, intermediate result generation, and final result computation. By dividing the operation into manageable segments, the patent avoids the need for complete data rearrangement while maintaining operational efficiency.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent performs preliminary column calculations on the source matrix data before final processing. By calculating column data in advance and storing intermediate results, the patent eliminates the need for time-consuming data rearrangement and channel filling operations that would otherwise be required.

Inventive Principle:
Principle #10Preliminary action

2Adaptability or versatility

If channel filling is performed for matrices with channels not divisible by 4, then the matrix operation can proceed, but additional resource consumption and time are required

Engineering Contradiction:
Improvecompatibility with various channel numbersVSAvoidchannel filling resource consumption
Core Design Contradiction:
Adaptability or versatilityVSLoss of energy

Solution Approach 1:

The patent changes the computational approach by calculating column data independently rather than requiring channel alignment. This parameter change in the calculation method allows the system to handle any channel number without padding or filling operations, thereby eliminating the associated resource consumption.

Inventive Principle:
Principle #35Parameter changes

3Ease of manufacture

If conventional matrix operation methods are used, then the process is simple to implement, but the operation efficiency is low due to computational intensity and redundant calculations

Engineering Contradiction:
Improveimplementation simplicityVSAvoidoperation efficiency
Core Design Contradiction:
Ease of manufactureVSProductivity

Solution Approach 1:

The patent performs preliminary column calculations and stores intermediate results before the final matrix operation. This preliminary action eliminates redundant calculations during the main operation, significantly improving efficiency while maintaining implementation simplicity through a clear two-stage process.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent creates intermediate result copies from the source matrix data through column calculations. These copied intermediate results are then used in the final operation, avoiding repeated access to the original data and reducing computational overhead.

Inventive Principle:
Principle #26Copying

Data Source

PatentUS12524827B2Method and apparatus for operating image data
Publication Date: 2026.01.13 TENCENT TECHNOLOGY (SHENZHEN) CO LTD
  • US12524827B2 patent drawing
  • US12524827B2 patent drawing
  • US12524827B2 patent drawing

AI summary

The disclosure relates to method and apparatus for operating image data. The method includes: reading matrix data from the image data based on a matrix size, M rows and N columns, of an image operator (220); calculating column data in the matrix data with a single calculation instruction corresponding to the image operator, to obtain an intermediate calculation result (240); multiplexing and rearranging the intermediate calculation result into N rows of cached data (260); calculating matrix elements of a target column in the N rows of cached data with the single calculation instruction, to obtain a calculation result of the matrix data under the single calculation instruction (280); and outputting the calculation result as an image processing result of the matrix data by the image operator (300).