IP Library Granted Patent US 11,087,203
Granted Patent B2
US 11,087,203 · App. 15/618,415 · Granted Aug 10, 2021

Method and apparatus for processing data sequence

Inventors: Yong Wang (Beijing, CN); Jian Ouyang (Beijing, CN); Wei Qi (Beijing, CN); Sizhong Li (Beijing, CN)
Assignee: Beijing Baidu Netcom Science and Technology, Co., Ltd
G06N3/0445G06N3/063
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,087,203
App. No.
15/618,415
Granted
Aug 10, 2021
Kind
B2
Abstract

The present application discloses a method and apparatus for processing a data sequence. A specific implementation of the method includes: receiving an inputted to-be-processed data sequence; copying a weight matrix in a recurrent neural network model to an embedded block random access memory (RAM) of a field-programmable gate array (FPGA); processing sequentially each piece of to-be-processed data in the to-be-processed data sequence by using an activation function in the recurrent neural network model and the weight matrix stored in the embedded block RAM; and outputting a processed data sequence corresponding to the to-be-processed data sequence. This implementation improves the data sequence processing efficiency of the recurrent neural network model.

Claims (47)

1. A method for processing a data sequence, comprising:

receiving an inputted to-be-processed data sequence;

copying a weight matrix in a recurrent neural network model to an embedded block random access memory (RAM) of a field-programmable gate array (FPGA);

processing sequentially each piece of to-be-processed data in the to-be-processed data sequence by using an activation function in the recurrent neural network model and the weight matrix stored in the embedded block RAM; and

outputting a processed data sequence corresponding to the to-be-processed data sequence,

wherein before the copying, the method further comprises:

calling an address assignment interface to assign a storage address in the embedded block RAM to the weight matrix, and

wherein the copying comprises:

calling a copying interface to copy the weight matrix stored in a double data rate synchronous dynamic random access memory to the storage address in the embedded block RAM that is assigned to the weight matrix,

wherein the copying of the weight matrix is performed only once during the process of processing the to-be-processed data sequence.

2. The method according to claim 1 , further comprising:

deleting the weight matrix stored in the embedded block RAM after the processed data sequence is output.

3. The method according to claim 2 , wherein the deleting the weight matrix stored in the embedded block RAM comprises:

calling a deletion interface to delete the weight matrix stored in the embedded block RAM.

4. The method according to claim 1 , wherein the embedded block RAM is a static random access memory.

5. An apparatus for processing a data sequence, comprising:

at least one processor; and

a memory storing instructions, which when executed by the at least one processor, cause the at least one processor to perform operations, the operations comprising:

receiving an inputted to-be-processed data sequence;

copying a weight matrix in a recurrent neural network model to an embedded block random access memory (RAM) of a field-programmable gate array (FPGA);

processing sequentially each piece of to-be-processed data in the to-be-processed data sequence by using an activation function in the recurrent neural network model and the weight matrix stored in the embedded block RAM; and

outputting a processed data sequence corresponding to the to-be-processed data sequence,

wherein, the operations further comprises, before the copying:

calling an address assignment interface to assign a storage address in the embedded block RAM to the weight matrix, and

wherein the copying comprises;

calling a copying interface to copy the weight matrix stored in a double data rate synchronous dynamic random access memory to the storage address in the embedded block RAM that is assigned to the weight matrix,

wherein the copying of the weight matrix is performed only once during the process of processing the to-be-processed data sequence.

6. The apparatus according to claim 5 , wherein the operations further comprises:

deleting the weight matrix stored in the embedded block RAM after the processed data sequence is output.

7. The apparatus according to claim 6 , wherein the deleting the weight matrix stored in the embedded block RAM comprises:

calling a deletion interface to delete the weight matrix stored in the embedded block RAM.

8. The apparatus according to claim 5 , wherein the embedded block RAM is a static random access memory.

9. A non-transitory storage medium storing one or more programs, the one or more programs when executed by an apparatus, causing the apparatus to perform operations, the operations comprising:

receiving an inputted to-be-processed data sequence;

copying a weight matrix in a recurrent neural network model to an embedded block random access memory (RAM) of a field-programmable gate array (FPGA);

processing sequentially each piece of to-be-processed data in the to-be-processed data sequence by using an activation function in the recurrent neural network model and the weight matrix stored in the embedded block RAM; and

outputting a processed data sequence corresponding to the to-be-processed data sequence,

wherein the operations further comprises, before the copying:

calling an address assignment interface to assign a storage address in the embedded block RAM to the weight matrix, and

wherein the copying comprises:

calling a copying interface to copy the weight matrix stored in a double data rate synchronous dynamic random access memory to the storage address in the embedded block RAM that is assigned to the weight matrix,

wherein the copying of the weight matrix is performed only once during the process of processing the to-be-processed data sequence.

10. The non-transitory storage medium according to claim 9 , wherein the operations further comprises:

deleting the weight matrix stored in the embedded block RAM after the processed data sequence is output.

11. The non-transitory storage medium according to claim 10 , wherein the deleting the weight matrix stored in the embedded block RAM comprises:

calling a deletion interface to delete the weight matrix stored in the embedded block RAM.

12. The non-transitory storage medium according to claim 9 , wherein the embedded block RAM is a static random access memory.

Assignments (3)
CHANGE OF NAME Recorded Sep 28, 2021
From: XINGYUN RONGCHUANG (BEIJING) TECHNOLOGY CO., LTD.
To: KUNLUNXIN TECHNOLOGY (BEIJING) COMPANY LIMITED
Reel/Frame 057635/0014 →
LICENSE Recorded Sep 28, 2021
From: BAIDU ONLINE NETWORK TECHNOLOGY (BEIJING) CO., LTD.; BEIJING BAIDU NETCOM SCIENCE AND TECHNOLOGY CO., LTD.
To: XINGYUN RONGCHUANG (BEIJING) TECHNOLOGY CO., LTD.
Reel/Frame 057635/0018 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jun 9, 2017
From: WANG, YONG; OUYANG, JIAN; QI, WEI; LI, SIZHONG
To: BEIJING BAIDU NETCOM SCIENCE AND TECHNOLOGY CO., LTD.
Reel/Frame 042755/0039 →
Priority Claims (1)
CN 201610990113.X · Nov 10, 2016 · national
Continuity (1)
Related Publication 20180129933A1 · May 10, 2018