# US 2020/0349433 A1 · Streaming-based artificial intelligence convolution processing method and apparatus, readable storage medium and terminal

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2020/0349433 A1
- Document ID: US20200349433A1
- Status: Published application
- Kind: A1
- Application number: 16/929,819
- Filed: 2020-07-15
- Published: 2020-11-05
- Earliest claimed: 2018-01-15
- Assignees: Shenzhen Corerain Technologies Co., Ltd.
- Applicants: Shenzhen Corerain Technologies Co., Ltd.
- Inventors: Mengqiu Xiao
- Web page: https://patentgrep.com/patent/US20200349433A1

## CPC

- G06F 17/16: Matrix or vector computation {, e.g. matrix-matrix or matrix-vector multiplication, matrix factorization (matrix transposition G06F7/78)}
- G06F 17/15: Correlation function computation {including computation of convolution operations (arithmetic circuits for sum of products per se, e.g. multiply-accumulators G06F7/5443; digital filters, e.g. FIR, IIR, adaptive filters H03H17/00)}
- G06F 18/213: Feature extraction, e.g. by transforming the feature space; Summarisation; Mappings, e.g. subspace methods
- G06F 18/251: {of input or preprocessed data}
- G06N 3/045: Combinations of networks
- G06N 3/0464: Convolutional networks [CNN, ConvNet]
- G06N 3/08: Learning methods
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

Provided is a streaming-based artificial intelligence convolution processing method, applied to a processing module. The method includes: adding invalid data to a starting point of a first to-be-processed data matrix stored in a first streaming lake to form a second to-be-processed data matrix, where a number of columns of the second to-be-processed data matrix is an integral multiple of a degree of parallelism of data transmission; using a data transmission module to take out the second to-be-processed data matrix from the first streaming lake in a preset manner for a convolution operation. Also provided are a streaming-based artificial intelligence convolution processing apparatus, a readable storage medium and a terminal.

## Claims

### Claim 1

A streaming-based artificial intelligence convolution processing method, applied to a processing module, comprising:
adding invalid data to a starting point of a first to-be-processed data matrix stored in a first streaming lake to form a second to-be-processed data matrix, wherein a number of columns of the second to-be-processed data matrix is an integral multiple of a degree of parallelism of data transmission; and
using a data transmission module to take out the second to-be-processed data matrix from the first streaming lake to a convolution module in a preset manner for a convolution operation.

### Claim 2 (depends on 1)

The streaming-based artificial intelligence convolution processing method of claim 1, wherein the degree of parallelism of data transmission is set to be pv,
wherein adding the invalid data to the starting point of the first to-be-processed data matrix stored in the first streaming lake to form the second to-be-processed data matrix specifically comprises:
adding (pv−2) columns of invalid data to the starting point of the first to-be-processed data matrix to form pv columns of data with first two columns of valid data of the first to-be-processed data matrix.

### Claim 3 (depends on 2)

The streaming-based artificial intelligence convolution processing method of claim 2, wherein using the data transmission module to take out the second to-be-processed data matrix from the first streaming lake to the convolution module in the preset manner for the convolution operation comprising:
according to rows and a data size of pv*1, using the data transmission module to take out the second to-be-processed data matrix from the first streaming lake and place into a second streaming lake in batches;
according to rows and a data size of pv*k, using the data transmission module to take out the second to-be-processed data matrix from the second streaming lake and place into a matrix module in batches for data combination, wherein k is a size of a convolution kernel matrix; and
according to a data size of pv*k*k, using the data transmission module to take out the second to-be-processed data matrix after the data combination and place into the convolution module.

### Claim 4 (depends on 3)

The streaming-based artificial intelligence convolution processing method of claim 3, wherein according to the rows and the data size of pv*k, using the data transmission module to take out the second to-be-processed data matrix from the second streaming lake and placing into the matrix module in batches for data combination specifically comprising:
taking each k rows of second to-be-processed data matrices to be a group of data; and
using the data transmission module to sequentially perform a following operation on each group of data: in each clock cycle, sequentially taking out a third to-be-processed data matrix with the data size of pv*k from the each group of data and placing into the matrix module until the each group of data is taken out entirely.

### Claim 5 (depends on 4)

The streaming-based artificial intelligence convolution processing method of claim 4, wherein in the each group of data, a first third to-be-processed data matrix with the data size of pv*k taken out by the data transmission module comprises (pv−2) columns of invalid data and 2 columns of valid data, so that a calculation result value is an invalid value, and
starting from a second third to-be-processed data matrix taken out by the data transmission module, each third to-be-processed data matrix and last 2 columns of a previous third to-be-processed data matrix are combined to form a k*(pv+2) order fourth to-be-processed data matrix, each k*(pv+2) order fourth to-be-processed data matrix can perform matrix extraction according to a step length of 1 to obtain a number pv of k*k order fifth to-be-processed data matrices, and the k*k order fifth to-be-processed data matrices are transmitted to a convolution module for convolution calculation with the convolution kernel matrix.

### Claim 6 (depends on 5)

The streaming-based artificial intelligence convolution processing method of claim 5, wherein the first streaming lake stores a plurality of first to-be-processed data matrices, each of the first to-be-processed data matrices corresponds to one channel data of multi-channel data, wherein the convolution module includes a plurality of convolution kernel matrices.

### Claim 7 (depends on 6)

The streaming-based artificial intelligence convolution processing method of claim 6, wherein the plurality of convolution kernel matrices comprises a plurality of weight matrices with different weights, and the plurality of weight matrices is used for separately performing a convolution operation with the third to-be-processed data matrix at the same time.

### Claim 8 (depends on 5)

The streaming-based artificial intelligence convolution processing method of claim 5, further comprising:
according to a data size of 1*1, using the data transmission module to take out the first to-be-processed data matrix from an external storage module and place into the first streaming lake.

### Claim 9

A streaming-based artificial intelligence convolution processing apparatus comprising:
a first streaming lake, storing a first to-be-processed data matrix;
a processing module, which is configured to add invalid data to a starting point of a first to-be-processed data matrix to form a second to-be-processed data matrix, wherein a number of columns of the second to-be-processed data matrix is an integral multiple of a degree of parallelism of data transmission; and
a data transmission module, which is communicatively connected and controlled by the processing module and is configured to take out the second to-be-processed data matrix from the first streaming lake to a convolution module in a preset manner for a convolution operation.

### Claim 10 (depends on 9)

The streaming-based artificial intelligence convolution processing apparatus of claim 9, wherein adding the plurality of columns of invalid data to the starting point of the first to-be-processed data matrix comprising:
setting a value of the degree of parallelism of data transmission as pv, adding, by the processing module, (pv−2) columns of invalid data to the starting point of the first to-be-processed data matrix to form pv columns of data with first two columns of valid data of the first to-be-processed data matrix.

### Claim 11 (depends on 10)

The streaming-based artificial intelligence convolution processing apparatus of claim 10 comprising:
a second streaming lake, which is configured to store the second to-be-processed data matrix from the first streaming lake; and
a matrix module, which is configured to store the second to-be-processed data matrix from the second streaming lake.

### Claim 12 (depends on 11)

The streaming-based artificial intelligence convolution processing apparatus of claim 11, wherein
each k rows of second to-be-processed data matrices is taken to be a group of data; and the data transmission module sequentially performs following operations on each group of data: in each clock cycle, sequentially taking out a number pv*k of third to-be-processed data matrices from the each group of data until the each group of data is taken out entirely;
wherein the matrix module is further configured to: starting from a second third to-be-processed data matrix taken out from the each group of data by the data transmission module, combine each third to-be-processed data matrix and last 2 columns of a previous third to-be-processed data matrix are combined to form a k*(pv+2) order fourth to-be-processed data matrix; and wherein each k*(pv+2) order fourth to-be-processed data matrix can perform matrix extraction according to a step length of 1 to obtain a number pv of k*k order fifth to-be-processed data matrices, and the k*k order fifth to-be-processed data matrices are transmitted to a convolution module to perform convolution calculation with the convolution kernel matrix.

### Claim 13 (depends on 12)

The streaming-based artificial intelligence convolution processing apparatus of claim 12, wherein the first streaming lake stores a plurality of first to-be-processed data matrices, each of the first to-be-processed data matrices corresponds to one channel data of multi-channel data, wherein the convolution module includes a plurality of convolution kernel matrices.

### Claim 14 (depends on 13)

The streaming-based artificial intelligence convolution processing apparatus of claim 13, wherein the plurality of convolution kernel matrices comprises a plurality of weight matrices with different weights, and the plurality of weight matrices is used for separately performing a convolution operation with the third to-be-processed data matrix at the same time.

### Claim 15 (depends on 9)

The streaming-based artificial intelligence convolution processing apparatus of claim 9, wherein the data transmission module is further configured to:
according to a data size of 1*1, take out the first to-be-processed data matrix from an external storage module and place into the first streaming lake.

### Claim 16 (depends on 1)

Anon-transitory computer-readable storage medium, which is configured to store a computer program for implementing the streaming-based artificial intelligence convolution processing method of claim 1 when the program is executed by a processor.

### Claim 17 (depends on 1)

An streaming-based artificial intelligence convolution processing terminal comprising: a processor and a memory,
wherein the memory is configured to store a computer program and the processor is configured to execute the computer program stored so that the terminal executes the streaming-based artificial intelligence convolution processing method of claim 1.
