Operator registration method and apparatus for deep learning framework, device and storage medium

US11625248B2 · US · B2

Patent metadata
FieldValue
Publication numberUS-11625248-B2
Application numberUS-202217572140-A
CountryUS
Kind codeB2
Filing dateJan 10, 2022
Priority dateMay 18, 2021
Publication dateApr 11, 2023
Grant dateApr 11, 2023

How to read this patent

A practical reading order for non-experts. Skip the full description unless you need deep technical detail.

  1. Title

    What the patent document calls the invention.

  2. Abstract

    A short plain-language summary of the technical disclosure.

  3. Assignees and inventors

    Who owns or filed the patent and who is credited as inventor.

  4. Key dates

    Filing, priority, publication, and grant dates set the timeline.

  5. First independent claim

    The legal scope of protection — read this for what is actually claimed.

  6. CPC / IPC classifications

    Technology tags used to group this patent with similar filings.

  7. Citations and related patents

    Prior art links and similar publications in this corpus.

Abstract

Official abstract text for this publication.

The present disclosure provides an operator registration method and apparatus for a deep learning framework, a device and a storage medium, relates to the field of computer technologies, and specifically to the field of artificial intelligence such as deep learning. The operator registration method for a deep learning framework includes: receiving registration information provided by a user for registering operators with the deep learning framework, the registration information including: a custom calculation function, the custom calculation function being written in a manner irrelevant to the deep learning framework; building operator meta-information in the deep learning framework based on the registration information; and constructing a to-be-registered operator within the deep learning framework based on the operator meta-information, and registering the to-be-registered operator in a global operator table within the deep learning framework. The present disclosure can simplify an operator registration process.

First claim

Opening claim text (preview).

What is claimed is: 1. An operator registration method for a deep learning framework, the method comprising: receiving registration information provided by a user for registering operators with the deep learning framework, the registration information comprising: a custom calculation function, the custom calculation function being written in a manner irrelevant to the deep learning framework; building operator meta-information in the deep learning framework based on the registration information; and constructing a to-be-registered operator within the deep learning framework based on the operator meta-information, and registering the to-be-registered operator in a global operator table within the deep learning framework. 2. The method according to claim 1 , wherein the registration information further comprises: custom input information and custom output information, and the step of building operator meta-information in the deep learning framework based on the registration information comprises: converting the custom input information into standard input information within the deep learning framework; converting the custom output information into standard output information within the deep learning framework; processing the custom calculation function by using macros, so as to obtain a calculation function after macro processing; and building the operator meta-information in the deep learning framework based on the standard input information, the standard output information and the calculation function after macro processing. 3. The method according to claim 2 , wherein the to-be-registered operator comprises to-be-registered operator description information and a to-be-registered operator kernel function, and the step of constructing a to-be-registered operator within the deep learning framework based on the operator meta-information comprises: constructing the to-be-registered operator description information based on the standard input information and the standard output information; and constructing the to-be-registered operator kernel function based on the calculation function after macro processing. 4. The method according to claim 3 , wherein the to-be-registered operator kernel function comprises unified-form input information and a unified function pointer, and the step of constructing the to-be-registered operator kernel function based on the calculation function after macro processing comprises: determining a structure for replacing the calculation function after macro processing, the structure comprising a static function, the static function having a unified form corresponding to different custom calculation functions; taking input information of the static function as the unified-form input information; and taking a function pointer of the static function as the unified function pointer. 5. The method according to claim 4 , wherein the input information of the static function forms an input information list, the input information list comprises an input tensor list, the custom input information comprises custom input information of at least one data type, the structure comprises at least one specialized substructure, different specialized substructures correspond to different data types, the data type comprises tensors, and the step of constructing the to-be-registered operator kernel function based on the calculation function after macro processing further comprises: obtaining custom input information of the data types corresponding to the specialized substructures by using specialized substructures in the at least one specialized substructure; forming the input tensor list with the custom input information whose data type are tensors; and if the data type further comprises non-tensors and the input information list further comprises another data type list, forming the another data type list with the custom input information whose data type are non-tensors. 6. The method according to claim 1 , wherein the step of constructing a to-be-registered operator within the deep learning framework based on the operator meta-information, and registering the to-be-registered operator in a global operator table within the deep learning framework comprises: determining a current constructor corresponding to a current scenario based on the current scenario; and constructing the to-be-registered operator within the deep learning framework based on the operator meta-information by using the current constructor, and registering the to-be-registered operator in the global operator table within the deep learning framework. 7. The method according to claim 2 , wherein the step of constructing a to-be-registered operator within the deep learning framework based on the operator meta-information, and registering the to-be-registered operator in a global operator table within the deep learning framework comprises: determining a current constructor corresponding to a current scenario based on the current scenario; and constructing the to-be-registered operator within the deep learning framework based on the operator meta-information by using the current constructor, and registering the to-be-registered operator in the global operator table within the deep learning framework. 8. The method according to claim 3 , wherein the step of constructing a to-be-registered operator within the deep learning framework based on the operator meta-information, and registering the to-be-registered operator in a global operator table within the deep learning framework comprises: determining a current constructor corresponding to a current scenario based on the current scenario; and constructing the to-be-registered operator within the deep learning framework based on the operator meta-information by using the current constructor, and registering the to-be-registered operator in the global operator table within the deep learning framework. 9. The method according to claim 4 , wherein the step of constructing a to-be-registered operator within the deep learning framework based on the operator meta-information, and registering the to-be-registered operator in a global operator table within the deep learning framework comprises: determining a current constructor corresponding to a current scenario based on the current scenario; and constructing the to-be-registered operator within the deep learning framework based on the operator meta-information by using the current constructor, and registering the to-be-registered operator in the global operator table within the deep learning framework. 10. The method according to claim 5 , wherein the step of constructing a to-be-registered operator within the deep learning framework based on the operator meta-information, and registering the to-be-registered operator in a global operator table within the deep learning framework comprises: determining a current constructor corresponding to a current scenario based on the current scenario; and constructing the to-be-registered operator within the deep learning framework based on the operator meta-information by using the current constructor, and registering the to-be-registered operator in the global operator table within the deep learning framework. 11. An electronic device, comprising: at least one processor; and a memory communicatively connected with the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform an operator registration method for a deep learning framework, wherein the method comprises: receiving registration information provided by a u

Assignees

Inventors

Classifications

Patent family

Related publications grouped by family.

External sources

Frequently asked questions

Answers are generated from the same data shown on this page.

What does patent US11625248B2 cover?
The present disclosure provides an operator registration method and apparatus for a deep learning framework, a device and a storage medium, relates to the field of computer technologies, and specifically to the field of artificial intelligence such as deep learning. The operator registration method for a deep learning framework includes: receiving registration information provided by a user for…
Who is the assignee on this patent?
Beijing Baidu Netcom Sci & Tech Co Ltd
What technology area does this patent fall under?
Primary CPC classification G06F8/41. Mapped technology areas include Physics.
When was this patent published?
Publication date Tue Apr 11 2023 00:00:00 GMT+0000 (Coordinated Universal Time) (B2). Legal status and post-grant events are not shown on this page.
What related patents are in patentsdb?
We list 5 related publications on this page (citations in our corpus or others sharing the same primary CPC).