JP2020091855A - Training model, method of generating model, and program - Google Patents
Training model, method of generating model, and program Download PDFInfo
- Publication number
- JP2020091855A JP2020091855A JP2019209063A JP2019209063A JP2020091855A JP 2020091855 A JP2020091855 A JP 2020091855A JP 2019209063 A JP2019209063 A JP 2019209063A JP 2019209063 A JP2019209063 A JP 2019209063A JP 2020091855 A JP2020091855 A JP 2020091855A
- Authority
- JP
- Japan
- Prior art keywords
- graph
- node
- backpropagation
- back propagation
- propagation
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
Description
本開示は、訓練装置、モデルの生成方法及びプログラムに関する。 The present disclosure relates to a training device, a model generation method, and a program.
機械学習において、ニューラルネットワークモデルは、入力層から出力層までのデータの遷移をグラフとして表し、グラフの接続に基づいて順伝播及び逆伝播が行われて訓練される。ネットワークの構築として、例えば、訓練の実行中にネットワークを定義するDefine-by-Run形式がある。Define-by-Run形式においては、非特許文献1に示すように、訓練中にグラフの形状が変化していくため、順伝播時にデータの処理を示すグラフを形成し、そのグラフを用いて逆伝播を行う。この結果、グラフを記憶する相当の領域が必要となり、メモリ領域を圧迫するため、効率的にネットワークの訓練を行うことが困難な場合がある。
In machine learning, a neural network model represents a transition of data from an input layer to an output layer as a graph, and forward propagation and back propagation are performed and training is performed based on the connection of the graph. As a network construction, for example, there is a Define-by-Run form in which the network is defined during execution of training. In the Define-by-Run format, as shown in
本実施形態においては、効率的にグラフを用いた演算を行う、グラフ演算装置、グラフ演算方法及びプログラムを提供する。 In the present embodiment, a graph calculation device, a graph calculation method, and a program for efficiently performing calculation using a graph are provided.
一実施形態によれば、訓練装置は、誤差逆伝播の経路に基づいてグラフを生成する、グラフ生成部と、前記グラフにおいて、前記誤差逆伝播の経路に基づいて識別子を各ノードに付与する、ID付与部と、前記グラフ及び前記識別子に基づいて誤差逆伝播を実行する、逆伝播部と、を備える。 According to one embodiment, the training device generates a graph based on a path of error backpropagation, a graph generation unit, and in the graph, assigns an identifier to each node based on the path of error backpropagation, An ID assigning unit and a backpropagation unit that performs error backpropagation based on the graph and the identifier.
以下、図面を参照して実施形態について説明する。 Hereinafter, embodiments will be described with reference to the drawings.
図1は、一実施形態に係る訓練装置の機能を示すブロック図である。訓練装置1は、入力部10と、記憶部12と、グラフ生成部14と、順伝播部16と、ID付与部18と、逆伝播部20と、出力部22と、を備え、入力データに対して所定の処理を行った出力データを出力する学習済みモデルを訓練する。
FIG. 1 is a block diagram showing functions of the training device according to the embodiment. The
入力部10は、データの入力を受け付ける。入力データは、例えば、訓練データであり、訓練するネットワークに入力されるデータと、損失の計算に用いるための教師データ(label)データ等、必要となるデータである。
The
記憶部12は、訓練装置1において訓練に必要となるデータあるいは訓練の結果を記憶する。この記憶部12は、例えば、訓練の対象となるネットワークについて、構成、訓練において更新されるパラメータ等を記憶する。また、入力部10から入力されたデータを一時的に記憶してもよい。さらに、訓練が終了した後の最終的なパラメータを記憶してもよい。訓練装置1に記憶部12が備えられる構成としているが、記憶部12の一部又は全部は、訓練装置1の外部に備えられ、通信回線等を介して訓練装置1がデータの送受信できるようにしてもよい。
The
グラフ生成部14は、ネットワークにデータが入力されるタイミングにおいて、演算グラフを生成する。順伝播部16は、記憶部12に記憶されているネットワーク形成の定義の記述に基づいて、入力データの演算を行う。別の例として、ネットワークを形成する定義を記述するネットワーク定義記述部が備えられ、当該ネットワーク定義記述部に記述されているネットワークの定義に基づいて、順伝播を実行しながらグラフを生成してもよい。このように、所定のネットワーク定義に基づいてあらかじめグラフが生成されて順伝播、逆伝播等の処理が行われるのではなく、上記のように、ネットワークの定義の記述に基づいて、順伝播のタイミングでグラフが生成され、生成されたグラフに基づいて以降の処理が行われる。グラフは、例えば、入出力変数の形態等により異なるものが形成されてもよい。
The
より具体的には、グラフ生成部14と、順伝播部16は、別個の動作を行うのではなく、訓練の対象となるネットワークの構造に基づいて、順伝播部16が順伝播の処理を実行するとともにグラフ生成部14がグラフを生成する。すなわち、訓練装置1は、あるデータ又はデータ群に対して、それぞれのデータに基づいてネットワークの順伝播を実行するとともに、逆伝播のためのグラフを生成する。このように、あらかじめ決められたネットワークの演算グラフを生成してから順伝播以降の処理を行うのではなく、順伝播処理とともに入力されたデータがどのような演算を行うかによりグラフを都度生成し、それ以降の処理(例えば、逆伝播)を実行する。
More specifically, the
ID付与部18は、グラフ生成部14が生成したグラフに対して、逆伝播する経路を示す識別子(以下、逆伝播IDと記載する)を付与する。逆伝播においてデータに含まれる変数ごとに異なる演算経路を辿る場合、この演算経路ごとにユニークな逆伝播IDを当該演算経路に含まれるノード、例えば、変数ノード及び演算ノードに付与する。例えば、バッチが同種の変数を有する場合には、バッチごとにグラフが生成され、この変数ごとに逆伝播IDが付与されてもよい。逆伝播IDは、グラフごとに一意的に与えられる。
The
逆伝播部20は、順伝播部16がネットワークを順伝播させて出力した結果と、教師データ(ラベル)とを比較して損失を算出し、当該損失に基づいて誤差逆伝播処理を実行する。この逆伝播処理は、ID付与部18が付与した逆伝播IDごとに実行される。逆伝播部20は、逆伝播が終了したグラフを削除してもよい。削除とは、グラフ自体を破棄してもよいし、グラフが保存されているメモリ領域等を上書きできる状態にする(例えば、メモリを解放する)ことによりグラフデータを実質的に破棄してもよい。また、このグラフの削除は、逆伝播部20が実行するのではなく、別途グラフ削除部(図示しない)を備え、当該グラフ削除部が逆伝播部20の動作に基づいてグラフを削除する構成としてもよい。
The back-
バッチ演算等を行う場合には、同種の変数が存在する場合がある。このような場合、これらの同種の変数において、演算経路が異ならない、又は、2回以上微分を行わない等の条件がある場合には、変数群として変数ノード、演算ノードを生成して、同一の逆伝播IDを用いて演算を行ってもよい。 When performing a batch operation or the like, the same type of variable may exist. In such a case, if there is a condition that the calculation paths do not differ for these variables of the same type or that differentiation is not performed twice or more, a variable node and a calculation node are generated as a variable group, and the same variables are generated. The calculation may be performed using the back-propagation ID of.
逆伝播部20の動作が終了した後、必要であれば、さらにネットワークを訓練するために、グラフ生成部14、順伝播部16、ID付与部18及び逆伝播部20により上記の処理が訓練の終了条件を満たすまで繰り返される。
After the operation of the
出力部22は、訓練が終了した後、学習済みのモデルを出力する。学習済みのモデルの出力は、モデル全体を出力するものであってもよいし、モデルに関する形状、パラメータ等のデータを出力し、外部で同じ学習済みモデルを構築することが可能なデータを出力するものであってもよい。さらに、出力部22を介して外部に出力するのではなく、記憶部12に学習済みモデルを格納し、記憶させてもよく、この場合、訓練が終了した訓練装置1を、学習済みモデルを用いた推定装置等として機能させてもよい。
The
図2は、本実施形態に係るグラフ生成の一例を示す図である。例えば、変数A、Bが入力され、変数Cが出力される状態(C=F(A,B))について示している。各グラフにおいてノード間を接続するエッジ(破線)は、出力から入力へと向かっているが、逆伝播をわかりやすく図示したものであり、順伝播時には、逆方向へとノード間を遷移する。なお、有向グラフとして示したが、逆伝播の順序が判断できるのであれば、必ずしも有向グラフではなくともよい。例えば、出力から入力へ向けて演算が行われるようにノードを辿るための指示をしてもよい。具体的には、出力から入力へ向けた演算ノードの列を記憶し、それを順番に実行していってもよい。 FIG. 2 is a diagram showing an example of graph generation according to this embodiment. For example, a state in which the variables A and B are input and the variable C is output (C=F(A, B)) is shown. The edges (broken lines) connecting the nodes in each graph are directed from the output to the input, but the back propagation is illustrated in an easy-to-understand manner, and during forward propagation, transitions occur between the nodes in the reverse direction. Although it is shown as a directed graph, it may not necessarily be a directed graph as long as the order of back propagation can be determined. For example, an instruction may be given to follow a node so that an operation is performed from output to input. Specifically, a sequence of operation nodes from output to input may be stored and executed in order.
変数A、Bが入力されると、関数Fの処理が行われ、変数Cが出力される。これらの処理は、順伝播部16により実行される。この順伝播の処理と並行して、グラフ生成部14がグラフを生成する。例えば、グラフ生成部14は、関数Fの処理を順伝播部16が定義するタイミングで、逆伝播の経路を判断し、経路が複数ある場合には、それぞれの経路に対応するグラフを生成する。この結果、例えば、変数A、Bのそれぞれに対して逆伝播の経路が存在する場合には、変数ノードA、関数演算ノードF1及び変数ノードC1を含むグラフと、変数ノードB、関数演算ノードF2及び変数ノードC2を含むグラフと、が生成される。
When the variables A and B are input, the function F is processed, and the variable C is output. These processes are executed by the
逆伝播される経路ごとに、ID付与部18は、グラフについて逆伝播IDを付与する。図2において、変数ノードA、演算ノードF1、変数ノードC1が属するグラフにおいては、各ノードに対して逆伝播ID1が付与される。一方で、変数ノードB、演算ノードF2、変数ノードC2が属するグラフにおいては、各ノードに対して逆伝播ID2が付与される。なお、逆伝播IDの付与がこのようにグラフ生成の後、又は、グラフ生成と並列に行われるのではなく、逆伝播IDがあり、これに基づいたグラフ生成を行うようにしてもよい。この場合にも、グラフ生成とともに、グラフを構成する各ノードにID付与部18が逆伝播IDを付与してもよい。
The
なお、各グラフについて演算ノードは、1つずつしか示されていないが、これは説明の簡単のためであり、実際には複数の演算ノードが連なるグラフを形成していてもよい。以下の説明においても同様に、演算ノードはグラフに対して1つしか示されないが、2以上の演算ノードが存在していてもよく、順伝播において逆伝播が必要となる演算ごとに演算ノードが生成され、この各演算ノードにしたがい逆伝播の演算を行う。また、演算ノードに接続する入出力変数ノードについても、必ずしも最初の演算ノード(例えば、入力層)又は最後の演算ノード(例えば、出力層)に対して入出力される訳ではなく、複数ある演算ノードのうち、途中のノードに対する入出力がされてもよい。この関係は、訓練する対象となるネットワークに対する変数の入出力、特に逆伝播する経路と同等の関係となる。 Although only one operation node is shown for each graph, this is for simplicity of explanation, and in practice, a graph in which a plurality of operation nodes are connected may be formed. Similarly, in the following description, only one operation node is shown for the graph, but there may be two or more operation nodes, and there is an operation node for each operation that requires back propagation in forward propagation. The back propagation is generated and the back propagation is calculated according to each calculation node. Also, regarding the input/output variable node connected to the operation node, it is not necessarily input/output to/from the first operation node (for example, input layer) or the last operation node (for example, output layer), and there are a plurality of operations. Input/output may be performed with respect to a node in the middle of the nodes. This relationship is equivalent to the input/output of variables with respect to the network to be trained, especially the backpropagating path.
複数の演算ノードが存在する場合、演算ノード同士の接続についても同様であり、逆伝播の経路により、ある関数から他の複数の関数へと分岐するような場合には、異なる逆伝播IDが付与される複数のグラフが生成されてもよい。このように、変数、関数に基づいて逆伝播の経路ごとにグラフ、当該グラフに属するノードが生成され、各グラフにおいて一意的にノードに逆伝播IDが付与される。 When there are a plurality of operation nodes, the same applies to the connection between the operation nodes, and when a function branches to another function due to a back propagation path, different back propagation IDs are assigned. Multiple graphs may be generated. In this way, a graph and a node belonging to the graph are generated for each backpropagation route based on the variables and functions, and the backpropagation ID is uniquely assigned to the node in each graph.
逆伝播部20は、付与された逆伝播IDごとに誤差逆伝播の処理を行い、ネットワークを更新する。例えば、逆伝播ID1のグラフを辿ることにより、変数ノードC1から、関数F1におけるパラメータについて逆伝播を実行し、パラメータを更新する。付与されたIDについて全ての演算が終了する、例えば、変数ノードAまで逆伝播を行うと、逆伝播ID1が付与されたノード、エッジの情報が破棄されることにより、当該グラフが破棄される。あるいは、グラフの情報ごと破棄されてもよい。さらに別の例として、逆伝播部20は、必要がなくなったタイミングにおいて、ノードごとに情報を破棄してもよい。ノードごとに破棄することで、より早いタイミングで使用しているリソースを解放することが可能となる。
The
この段階においては、逆伝播ID2が付与されているグラフは、まだ存在している。そこで、逆伝播部20は、この逆伝播ID2が付与されているノードについて誤差逆伝播を上記と同様に実行することで、ネットワークを更新する。
At this stage, the graph to which the back propagation ID2 is assigned still exists. Therefore, the back-
一般的な機械学習と同様に、この後に、別の変数を入力してさらにネットワークを更新してもよい。この場合、さらに、入力された変数に対して同様にグラフを生成して順伝播し、逆伝播IDを付与して、逆伝播を行いつつ、自動的に不要となるグラフを破棄する。なお、訓練については、一般的な機械学習の手法を用いることができる。もちろん、ミニバッチ等を用いて並列的に処理することも可能である。 Similar to general machine learning, another variable may be input after this to further update the network. In this case, a graph is similarly generated with respect to the input variables and forward-propagated, a back-propagation ID is given, and back-propagation is performed, while unnecessary graphs are automatically discarded. For training, a general machine learning method can be used. Of course, it is also possible to perform processing in parallel using a mini batch or the like.
図3は、本実施形態に係る処理を示すフローチャートである。 FIG. 3 is a flowchart showing the processing according to this embodiment.
まず、入力部10を介してデータの入力を受け付ける(S100)。データの入力は、個々のデータごとに入力を受け付けてもよいし、所定の数又は所定のサイズのデータを一度に受け付けてもよい。また、入力の受け付けは、外部から明示的に入力されるものには限られず、外部のストレージ等に記憶されているデータを入力部10が取得して入力を受け付けてもよいし、記憶部12に記憶されているデータから取得するものであってもよい。
First, the input of data is accepted via the input unit 10 (S100). The data may be input for each individual data, or a predetermined number or a predetermined size of data may be received at once. Further, the input is not limited to being explicitly input from the outside, and the
次に、順伝播部16は、入力されたデータを順伝播させる(S102)。順伝播を行うことにより、当該入力されたデータを学習対象となるモデルに入力した場合における出力を取得する。
Next, the
次に、グラフ生成部14は、グラフを生成する(S104)。グラフの生成は、ネットワークの構成に基づいて変数(すなわち、受け付けた入力データ)ごとに実行される、又は、関数ごとに逆伝播される経路に基づいて実行される。すなわち、逆伝播する経路が複数である場合には、複数のグラフが生成される。この経路は、ネットワークの定義の記述から取得することが可能である。
Next, the
次に、ID付与部18は、入力変数の保持する変数ノードに基づいて、逆伝播IDを生成されたグラフの各ノードに対して付与する(S106)。入力変数により訓練対象のモデルにおいて逆伝播において辿る経路が異なる場合等に、入力変数、パラメータ、出力変数等により逆伝播において必要となる経路ごとに異なる逆伝播IDが付与される。なお、フローチャート上では、S104とS106の処理は、別々に示されるが、実際には、ID付与部18は、変数ノードが有する逆伝播IDに基づいて、S104のグラフの生成とともに、逆伝播IDを付与する。すなわち、S102からS106の処理は、個々に実行されるのではなく、協働して実行されてもよい。
Next, the
なお、別の例として、S102からS106の処理については、逐次的に実行されるものであってもよい。例えば、S102、S104、S106の順番で、順伝播して、グラフを生成して、ID付与をしてもよいし、S102の後に、S104とS106の処理を併せて実行、すなわち、順伝播が終了した後にグラフを作成とID付与とを併せて実行してもよい。あるいは、S104の後にS102が行われる、すなわち、逆伝播のためのグラフを生成した後に、順伝播を行ってもよい。このように、S102からS106の処理は、順伝播された結果を取得でき、かつ、逆伝播の経路ごとにグラフを生成し逆伝播IDを付与することができる実装であればいずれにも適用することができる。 As another example, the processes of S102 to S106 may be sequentially executed. For example, in order of S102, S104, and S106, forward propagation may be performed to generate a graph and IDs may be assigned. After S102, the processes of S104 and S106 may be executed together, that is, forward propagation may be performed. After completion, the graph creation and the ID assignment may be executed together. Alternatively, S102 may be performed after S104, that is, forward propagation may be performed after a graph for back propagation is generated. As described above, the processes of S102 to S106 are applied to any implementation as long as the result of forward propagation can be acquired, and a graph can be generated for each route of back propagation and a back propagation ID can be given. be able to.
次に、逆伝播部20は、付与された逆伝播IDに基づいて誤差逆伝播の処理を実行する(S108)。また、演算が終了し、以後の後の演算で必要となる逆伝播IDが付与されていないグラフデータ、例えば、ノードについては、当該逆伝播IDに基づいた誤差逆伝播が終了した後に破棄する(S110)。別の例として、誤差逆伝播を行いつつ再利用されないノードを破棄してもよい。グラフ間に参照関係がある場合には、逆伝播する順番を逆伝播部20が決定し、当該順番通りに逆伝播処理を行なってもよい。
Next, the
次に、逆伝播部20は、逆伝播されていないグラフ、すなわち、破棄されていないグラフがあるかにより処理を分岐させる(S112)。破棄されていないグラフが存在する場合(S112:NO)、逆伝播はまだ終了していないので、当該破棄されていないグラフについて誤差逆伝播を実行する(S108〜S110)。
Next, the back-
例えば、逆伝播ID1のグラフについて逆伝播とグラフの破棄が終了した後、続いて、逆伝播ID2のグラフについて処理が実行される。このフローチャートにおける分岐は、あくまで便宜的に記載したものであり、動的に形成されるものではなくてもよく、生成されたグラフの全てについて逆伝播とグラフの破棄を行うということを意味する。 For example, after the back propagation and the discarding of the graph are completed for the graph of back propagation ID1, the process is subsequently executed for the graph of back propagation ID2. The branch in this flowchart is described for convenience only, and may not be dynamically formed, and means that back propagation and graph discard are performed for all generated graphs.
さらに、破線で示したように、あるグラフを用いて逆伝播が終了した後、別の順伝播処理が実行されてもよい。この場合、あるグラフの処理の後に、別の逆伝播IDに関する順伝播処理が実行され、グラフが生成され、逆伝播が行われてもよい(S102〜S110)。このように、逆伝播の処理の後に他の順伝播処理、グラフ生成処理が行われてもよい。 Further, as indicated by the broken line, another forward propagation process may be executed after the back propagation is completed using a certain graph. In this case, after the processing of a certain graph, the forward propagation processing for another back propagation ID may be executed to generate a graph and back propagation may be performed (S102 to S110). In this way, other forward propagation processing and graph generation processing may be performed after the back propagation processing.
さらにまた、例えば、逆伝播ID1、2の順伝播、グラフ生成が実行され、逆伝播ID1の逆伝播、グラフ破棄が実行され、逆伝播ID3の順伝播、グラフ生成をし、その後に逆伝播ID2の逆伝播、グラフ破棄が実行されるといった複雑な処理であってもよい。この処理の順番は、上述したように、ネットワーク定義の記述に基づいて、例えば、入力変数に基づいた順伝播処理が定義され、順伝播が実行されはじめた場合に、一意的に決定されて実行されてもよい。別の例としては、後の順伝播処理の開始のタイミングで、さらなる順伝播処理の分岐が存在してもよい。このように、一般的なDefine-by-Runの形式により実行されるいかなる処理に対しても、S102〜S112の処理が適切に実行されうる。
Furthermore, for example, the forward propagation of the
すなわち、フローチャートにおけるS102からS110の処理の記載は、便宜的に順番に並べられているだけであり、それぞれの逆伝播の経路に対して順伝播及びグラフ生成と、逆伝播と、グラフ破棄と、の処理が順番に実行されればよく、同一の逆伝播IDを有する処理が連続して行われることは、要求されない。上述したように、逆伝播ID1の処理は、連続して順番に行われる一方で、逆伝播ID2の処理及び逆伝播ID3の処理がそれぞれのIDに対して連続して順番に行われなくてもよい。さらに複雑な場合にも、同様に処理の順番を適切に入れ替えることが可能である。 That is, the description of the processing from S102 to S110 in the flowchart is merely arranged in order for convenience, and forward propagation and graph generation, back propagation, and graph discard are performed for each back propagation path. It is sufficient that the processes of 1) are executed in order, and it is not required that the processes having the same back propagation ID be continuously executed. As described above, the processing of the back propagation ID1 is continuously performed in order, while the processing of the back propagation ID2 and the processing of the back propagation ID3 are not performed consecutively in order for each ID. Good. Even in more complicated cases, it is possible to appropriately change the order of processing.
一方で、全てのグラフが破棄されている場合(S112:YES)、訓練が終了しているか否かを判断する(S114)。訓練の終了は、一般的な学習と同様に、所定のエポック数の訓練がおこなわれた、損失の値が所定の値よりも小さくなった、アキュラシーが所定の値よりも大きくなった、等の終了条件により判断される。 On the other hand, when all the graphs have been discarded (S112: YES), it is determined whether or not the training is completed (S114). The end of the training is the same as general learning, the training of a predetermined number of epochs was performed, the loss value was smaller than the predetermined value, the accuracy was larger than the predetermined value, etc. Judgment is made according to the termination condition of.
訓練が終了していない場合(S114:NO)、新たな入力変数に対して、新たなグラフを作成し(S102)、訓練の処理を繰り返す(S104〜S112)。 When the training is not completed (S114: NO), a new graph is created for the new input variable (S102), and the training process is repeated (S104 to S112).
一方で、訓練が終了している場合(S114:YES)、結果を出力、格納等し(S116)、訓練処理を終了する。 On the other hand, when the training is completed (S114: YES), the result is output, stored, etc. (S116), and the training process is ended.
以上のように、本実施形態によれば、生成したグラフの情報を全ての変数、関数等についての逆伝播を行うまで保持する必要がなくなるため、Define-by-Runの処理を行いながらもメモリの使用について効率化を図ることが可能となる。より具体的には、複数のグラフが使用できることにより、誤差逆伝播の計算のために、グラフにおいて保持する部分と、保持しない部分とをより明確に細かく制御することが可能となり、メモリの効率化を図ることができる。 As described above, according to the present embodiment, it is not necessary to retain the information of the generated graph until back propagation is performed for all variables and functions. Therefore, while performing Define-by-Run processing, memory It is possible to improve the efficiency of using the. More specifically, since multiple graphs can be used, it is possible to more clearly and finely control which part of the graph is retained and which part is not, for the purpose of calculating the error backpropagation, which improves memory efficiency. Can be planned.
例えば、誤差逆伝播において、演算ノードに対して2回以上の微分を行う等、グラフが複数の経路を有する場合には、さらに効率よく訓練を行うことが可能となる。これは、損失関数において実行される誤差逆伝播では、入力に関する勾配を計算するが、損失関数に対する誤差逆伝播においては入力に関する勾配を計算しない場合にも用いることができる。このようにグラフを生成、破棄することにより、例えば、変数の一部において誤差逆伝播が完了したタイミングにおいて、必要のなくなるグラフを破棄し、当該グラフのために使用されていたメモリ領域を解放することが可能となる。 For example, in the error back propagation, when the graph has a plurality of paths, such as performing differentiation twice or more with respect to the operation node, it becomes possible to perform the training more efficiently. This can also be used when the error backpropagation performed in the loss function calculates the gradient with respect to the input, but the error backpropagation with respect to the loss function does not calculate the gradient with respect to the input. By generating and discarding the graph in this way, for example, when the error backpropagation is completed for a part of the variables, the unnecessary graph is discarded and the memory area used for the graph is released. It becomes possible.
図2において、グラフ生成の一例について説明したが、さらに異なる例について以下説明する。いずれの場合においても、全体的な処理の流れは、上述したフローチャートと同様である。 In FIG. 2, an example of graph generation has been described, but a further different example will be described below. In any case, the overall processing flow is the same as the above-mentioned flowchart.
図4は、入力ノードにおいて、変数Aが2つのノードを有する場合のグラフ生成を示す図である。例えば、B=F(A)という計算において、変数Aが2つのノードA1、A2を有している場合、図4のように逆伝播においてそれぞれのノードA1、A2に対応する演算ノードが生成される。以下の図において、実線は、グラフのエッジ、一点鎖線は、変数等からのノード生成を示す。 FIG. 4 is a diagram showing graph generation when the variable A has two nodes in the input node. For example, in the calculation of B=F(A), when the variable A has two nodes A1 and A2, operation nodes corresponding to the respective nodes A1 and A2 are generated in the back propagation as shown in FIG. It In the following figures, the solid line indicates the edge of the graph, and the alternate long and short dash line indicates node generation from variables and the like.
変数Aに対して、ノードA1、F1、B1を有し、各ノードに逆伝播ID1が付与されたグラフと、ノードA2、F2、B2を有し、各ノードに逆伝播ID2が付与されたグラフとがそれぞれ生成される。より具体的には、順伝播においては、演算Fにより、変数Bが出力される。そして、逆伝播の経路が2つ存在する場合、図4に示すように逆伝播の経路に基づいて、ノードA1、F1、B1を含む逆伝播ID1のグラフと、ノードA2、F2、B2を含む逆伝播ID2のグラフとが生成される。 A graph having nodes A1, F1, and B1 and a back propagation ID1 assigned to each node for the variable A, and a graph having nodes A2, F2, and B2 having a back propagation ID2 assigned to each node And are generated respectively. More specifically, in forward propagation, the variable F is output by the operation F. When there are two backpropagation routes, the graph of the backpropagation ID1 including the nodes A1, F1, and B1 and the nodes A2, F2, and B2 are included based on the backpropagation routes as shown in FIG. And a graph of back propagation ID2.
図5は、2変数を入力すると1変数を出力する場合のグラフ生成を示す図である。例えば、C=F(A,B)のような引数を2つ必要とする演算の場合である。 FIG. 5 is a diagram showing graph generation when two variables are input and one variable is output. For example, it is a case of an operation that requires two arguments such as C=F(A,B).
この場合、AとBが異なる逆伝播IDを持つ変数ノードを有すると、それぞれの逆伝播IDに対応する演算ノードが生成され、出力変数Cに対して、その全てに対応する変数ノードC1、C2が生成される。例えば、演算ノードF1においては、変数Aに対する出力である変数ノードC1から誤差逆伝播の処理が実行され、一方、演算ノードF2においては、変数Bに対する出力である変数ノードC2から誤差逆伝播の処理が実行される。 In this case, when A and B have variable nodes having different backpropagation IDs, operation nodes corresponding to the respective backpropagation IDs are generated, and for output variable C, variable nodes C1 and C2 corresponding to all of them are generated. Is generated. For example, in the operation node F1, the error backpropagation process is executed from the variable node C1 which is an output for the variable A, while in the operation node F2, the error backpropagation process is executed from the variable node C2 which is an output for the variable B. Is executed.
このように、別々の変数からの出力、及び、同一又は異なる演算に対して、別々の逆伝播IDが付与されるグラフが、それぞれ生成される。 In this way, graphs to which different backpropagation IDs are given for outputs from different variables and the same or different operations are generated.
上述の全ての例においては、変数が異なるノードを有する一方で、演算ノードは、各変数に対して1つの経路からしか接続されない場合を説明したが、これには限られず、例えば、同一の演算ノードに異なる入力変数ノードへの接続が存在する場合もある。 In all the above-mentioned examples, it has been described that the variables have different nodes, but the operation node is connected to each variable from only one path. However, the present invention is not limited to this. There may be connections to different input variable nodes in the node.
図6は、このように、1つの演算ノードに対して複数の入力ノード及び出力ノードが接続する場合におけるグラフ生成を示す。一例として、B=F(A)となる演算において、入力ノードと出力ノードを参照する場合について説明する。以下の図において、破線は、参照関係を示す。例えば、グラフ生成部14が逆伝播経路に基づいて、ノード間にこの参照関係を持つように設定する。
FIG. 6 shows graph generation in the case where a plurality of input nodes and output nodes are connected to one operation node as described above. As an example, a case where the input node and the output node are referred to in the operation of B=F(A) will be described. In the following figures, broken lines indicate reference relationships. For example, the
変数ノードA1、B1及び演算ノードF1には、逆伝播ID1が付与され、変数ノードA2、B2及び演算ノードF2には、逆伝播ID2が付与される。ただし、演算ノードF2の演算においては、変数ノードA1、B1の変数が使用されるため、演算ノードF2には、変数ノードA1、B1への参照関係(図中の破線矢印)をさらに持たせる。 The backpropagation ID1 is given to the variable nodes A1 and B1 and the operation node F1, and the backpropagation ID2 is given to the variable nodes A2 and B2 and the operation node F2. However, since the variables of the variable nodes A1 and B1 are used in the calculation of the calculation node F2, the calculation node F2 is further provided with a reference relationship (broken line arrow in the figure) to the variable nodes A1 and B1.
逆伝播部20は、このような場合、参照しているノードを有する逆伝播IDのグラフから演算を実行する。図6の例を用いて説明する。逆伝播ID1、2を有する2つのグラフが存在し、逆伝播ID2が付与されている演算ノードF2には、逆伝播ID1が付与されている変数ノードA1、B1への参照が存在する。
In such a case, the
この場合、逆伝播部20は、逆伝播ID2に係るグラフから演算を開始する。まず、変数ノードB2において、損失を算出し、演算ノードF2において、逆伝播された損失に基づいて勾配を算出する。例えば、この勾配の算出に、変数A1、B1を用いる。前述と同様に、演算ノードは1つしか示されていないが複数であってもよい。そして、ある1つの演算ノードに対する勾配の算出に変数A1、B1が用いられてもよいし、異なる演算ノードに対する勾配の算出にそれぞれ変数A1、B1が用いられてもよいし、これらの組み合わせであってもよい。入出力される変数が3以上であっても同様である。
In this case, the
逆伝播部20により演算ノードF2の勾配が算出され、変数ノードA2まで誤差逆伝播の処理が実行され、逆伝播ID2に関するグラフの誤差逆伝播の処理が終了すると、逆伝播部20は、逆伝播ID2が付与されている各ノードを有するグラフを破棄する。その後、逆伝播ID1に関する誤差逆伝播の処理を実行する。
When the
このように、参照関係を持たせておくことにより、複数のグラフ間で変数ノード又は演算ノードとの間に相互に関係性を有する場合にも、グラフの生成、破棄を実行することにより、メモリの使用効率を向上させることが可能である。逆伝播の処理(演算)を行う順番は、例えば、逆伝播部20が各グラフにおける参照関係を抽出し、抽出結果に基づいて決定する。
In this way, by having a reference relationship, even when there is a mutual relationship between a variable node or an operation node among multiple graphs, the graphs are created and discarded to save memory. It is possible to improve the use efficiency of. The order of performing the back propagation processing (calculation) is determined, for example, by the
微分の演算が他の逆伝播IDの変数ノードに依存する場合には、微分の計算自体を通常の逆伝播の計算と同様に演算ノード及び変数ノードを用いて記憶しておき、参照関係に基づいて演算を行う。 When the differential operation depends on another backpropagation ID variable node, the differential calculation itself is stored using the operation node and the variable node in the same manner as the normal backpropagation calculation, and based on the reference relationship. And calculate.
なお、図7のように、変数ノードに対して参照関係を持たせておいてもよい。別の例として、参照関係を示す変数ノードを各グラフに備え、他のグラフ内のノードから、又は、他のグラフ内のノードへの参照関係を格納しておき、逆伝播を実行するタイミングで当該変数ノードへの参照を確認することにより、グラフが効率よく破棄できる順番で逆伝播を行ってもよい。例えば、他の逆伝播IDを有するノードへの参照関係を確認し、他のグラフへの参照があるグラフから逆伝播を実行する。 As shown in FIG. 7, variable nodes may have a reference relationship. As another example, each graph is provided with a variable node that indicates a reference relationship, and a reference relationship from a node in another graph or to a node in another graph is stored, and at the timing of performing back propagation. By confirming the reference to the variable node, backpropagation may be performed in an order in which the graph can be efficiently discarded. For example, the back-propagation is executed from a graph having a reference to another graph by confirming a reference relation to a node having another back-propagation ID.
別の例として、参照関係を示す参照グラフをさらに備えてもよく、参照グラフの末端となるノードに対応する逆伝播IDを有するグラフから演算を実行してもよい。このようにすると、参照関係が複雑となる複数のグラフを有する場合にも、容易に適用することが可能となる。 As another example, a reference graph showing a reference relationship may be further provided, and the operation may be executed from the graph having the backpropagation ID corresponding to the terminal node of the reference graph. By doing so, it is possible to easily apply even when there are a plurality of graphs having complicated reference relationships.
参照関係は、他のグラフのノードを参照するグラフに対して持たせるようにしたが、逆に、他のグラフから参照されるノードを有する関係をグラフとともに記憶させてもよい。この場合、上述と同様に適切に参照するノードから逆伝播の演算を実行することにより、演算が終了したグラフの情報から破棄することが可能となる。 The reference relationship is provided for a graph that refers to a node of another graph, but conversely, a relationship having a node referred to by another graph may be stored together with the graph. In this case, it is possible to discard the information from the graph for which the computation is completed by executing the computation of the back propagation from the node that appropriately refers to the same as described above.
図8は、さらに複雑な場合のグラフ生成の例を示す。入出力と演算の関係は、上記と同様にB=F(A)であるとする。さらに、演算Fの微分F’が入出力変数A、Bを用いた計算であるとする。図8において、点線は、破棄されたノード、エッジを示す。 FIG. 8 shows an example of graph generation in a more complicated case. It is assumed that the relationship between input/output and calculation is B=F(A) as in the above. Further, it is assumed that the differential F′ of the operation F is a calculation using the input/output variables A and B. In FIG. 8, dotted lines indicate discarded nodes and edges.
まず、グラフ生成時において、演算ノードF2から変数ノードA1、B1への参照がされる。ΔBは、誤差逆伝播の途中結果として得られている変数Bに対する勾配を表し、ΔAは、演算Fに対する誤差逆伝播の結果として得られる変数Aに対する勾配を表す。この図8においては、ΔBについて逆伝播ID1が付与されているノードを有する場合を示している。 First, at the time of graph generation, the calculation node F2 refers to the variable nodes A1 and B1. ΔB represents a gradient for the variable B obtained as a result of the error back propagation, and ΔA represents a gradient for the variable A obtained as a result of the error back propagation for the operation F. FIG. 8 shows the case where there is a node to which the back propagation ID1 is assigned for ΔB.
逆伝播ID2が付与されているグラフから逆伝播の処理が実行される。F2の微分F2’を算出すると、F2’の演算ノードには、逆伝播ID1が付与される。そして、この演算ノードF2’から変数ノードA1、B1への参照がされる。そして、逆伝播が終了した変数ノードB2、演算ノードF2、変数ノードA2は、破棄される。 The back propagation processing is executed from the graph to which the back propagation ID2 is assigned. When the differential F2' of F2 is calculated, the back propagation ID1 is given to the operation node of F2'. Then, reference is made from the operation node F2' to the variable nodes A1 and B1. Then, the variable node B2, the operation node F2, and the variable node A2 for which the back propagation is completed are discarded.
このように、他のグラフに依存するノードを有する場合には、逆伝播IDが付与された変数の入力を伝達するノードを生成することにより、逆伝播の経路ごとに前述と同様にグラフを破棄することが可能となる。参照しているノードの誤差逆伝播が完了した後に、当該逆伝播IDが付与された変数ノード、演算ノードは破棄され、特に、演算ノードが保持していたリソースのうち、他の逆伝播IDの演算ノードと共有していないものについてリソースが解放される。一方で、他の逆伝播IDの計算グラフに対する誤差逆伝播は、例えば、演算ノードF2’が保持されることにより、正しく演算を行うことが可能である。 In this way, when there is a node that depends on another graph, by generating a node that transmits the input of the variable to which the backpropagation ID is assigned, the graph is discarded for each backpropagation route as described above. It becomes possible to do. After the error backpropagation of the referenced node is completed, the variable node and the operation node to which the backpropagation ID is assigned are discarded, and in particular, of the resources held by the operation node, other backpropagation IDs Resources are released for those that are not shared with compute nodes. On the other hand, the error backpropagation with respect to the calculation graph of the other backpropagation ID can be correctly calculated by, for example, holding the calculation node F2'.
本実施形態においては、単純な場合についていくつか例を挙げて説明したが、グラフを生成し、生成したグラフごとにノードに一意性を有する逆伝播IDを付与し、必要であれば異なる逆伝播IDが付与されたノード間において参照関係を持たせることにより、逆伝播が完了した計算グラフから順にリソースを解放することが可能である。これは、前述で示したものよりも複雑なグラフになっても同様に適用することができる。 In this embodiment, a simple case has been described with some examples, but a graph is generated, a backpropagation ID having uniqueness is given to a node for each generated graph, and different backpropagation is performed if necessary. By providing the reference relationship between the nodes to which the IDs are assigned, it is possible to release the resources in order from the calculation graph in which the back propagation is completed. This can be similarly applied to a more complicated graph than that shown above.
このように、ネットワークの逆伝播をする場合に、そのネットワーク全体についてグラフを生成するのではなく、逆伝播する経路に基づいてグラフを生成することにより、リソースの利用効率を向上することができる。これにより、複雑な演算を行うDefine-by-Run方式においても、メモリの効率化を図ることが可能となる。 In this way, when backpropagating a network, a graph is not generated for the entire network, but a graph is generated based on a backpropagating path, so that resource utilization efficiency can be improved. As a result, it is possible to improve the efficiency of the memory even in the Define-by-Run method that performs complicated calculation.
前述した実施形態における訓練装置1において、各機能は、アナログ回路、デジタル回路又はアナログ・デジタル混合回路で構成された回路であってもよい。また、各機能の制御を行う制御回路を備えていてもよい。各回路の実装は、ASIC(Application Specific Integrated Circuit)、FPGA(Field Programmable Gate Array)等によるものであってもよい。
In the
上記の全ての記載において、訓練装置1の少なくとも一部はハードウェアで構成されていてもよいし、ソフトウェアで構成され、ソフトウェアの情報処理によりCPU(Central Processing Unit)等が実施をしてもよい。ソフトウェアで構成される場合には、訓練装置1及びその少なくとも一部の機能を実現するプログラムをフレキシブルディスクやCD−ROM等の記憶媒体に収納し、コンピュータに読み込ませて実行させるものであってもよい。記憶媒体は、磁気ディスクや光ディスク等の着脱可能なものに限定されず、ハードディスク装置やメモリなどの固定型の記憶媒体であってもよい。すなわち、ソフトウェアによる情報処理がハードウェア資源を用いて具体的に実装されるものであってもよい。さらに、ソフトウェアによる処理は、FPGA等の回路に実装され、ハードウェアが実行するものであってもよい。ジョブの実行は、例えば、GPU(Graphics Processing Unit)等のアクセラレータを使用して行ってもよい。
In all the above descriptions, at least a part of the
例えば、コンピュータが読み取り可能な記憶媒体に記憶された専用のソフトウェアをコンピュータが読み出すことにより、コンピュータを上記の実施形態の装置とすることができる。記憶媒体の種類は特に限定されるものではない。また、通信ネットワークを介してダウンロードされた専用のソフトウェアをコンピュータがインストールすることにより、コンピュータを上記の実施形態の装置とすることができる。こうして、ソフトウェアによる情報処理が、ハードウェア資源を用いて、具体的に実装される。 For example, the computer can be the device of the above-described embodiment by the computer reading the dedicated software stored in the computer-readable storage medium. The type of storage medium is not particularly limited. Further, the computer can be the device of the above embodiment by installing the dedicated software downloaded via the communication network by the computer. In this way, information processing by software is specifically implemented using hardware resources.
図9は、本発明の一実施形態におけるハードウェア構成の一例を示すブロック図である。訓練装置1は、プロセッサ71と、主記憶装置72と、補助記憶装置73と、ネットワークインタフェース74と、デバイスインタフェース75と、を備え、これらがバス76を介して接続されたコンピュータ装置7として実現できる。
FIG. 9 is a block diagram showing an example of the hardware configuration according to the embodiment of the present invention. The
なお、図9のコンピュータ装置7は、各構成要素を一つ備えているが、同じ構成要素を複数備えていてもよい。また、1台のコンピュータ装置7が示されているが、ソフトウェアが複数のコンピュータ装置にインストールされて、当該複数のコンピュータ装置それぞれがソフトウェアの異なる一部の処理を実行してもよい。 Note that the computer device 7 of FIG. 9 includes one each of the constituent elements, but may include a plurality of the same constituent elements. Further, although one computer device 7 is shown, software may be installed in a plurality of computer devices, and each of the plurality of computer devices may execute a part of processing of different software.
プロセッサ71は、コンピュータの制御装置および演算装置を含む電子回路(処理回路、Processing circuit、Processing circuitry)である。プロセッサ71は、コンピュータ装置7の内部構成の各装置などから入力されたデータやプログラムに基づいて演算処理を行い、演算結果や制御信号を各装置などに出力する。具体的には、プロセッサ71は、コンピュータ装置7のOS(Operating System)や、アプリケーションなどを実行することにより、コンピュータ装置7を構成する各構成要素を制御する。プロセッサ71は、上記の処理を行うことができれば特に限られるものではない。訓練装置1及びそれらの各構成要素は、プロセッサ71により実現される。ここで、処理回路とは、1チップ上に配置された1又は複数の電気回路を指してもよいし、2つ以上のチップあるいはデバイス上に配置された1又は複数の電気回路を指してもよい。
The
主記憶装置72は、プロセッサ71が実行する命令および各種データなどを記憶する記憶装置であり、主記憶装置72に記憶された情報がプロセッサ71により直接読み出される。補助記憶装置73は、主記憶装置72以外の記憶装置である。なお、これらの記憶装置は、電子情報を格納可能な任意の電子部品を意味するものとし、メモリでもストレージでもよい。また、メモリには、揮発性メモリと、不揮発性メモリがあるが、いずれでもよい。訓練装置1内において各種データを保存するためのメモリ、例えば、記憶部12は、主記憶装置72または補助記憶装置73により実現されてもよい。例えば、前述した各記憶部の少なくとも一部は、この主記憶装置72又は補助記憶装置73に実装されていてもよい。別の例として、アクセラレータが備えられている場合には、前述した各記憶部の少なくとも一部は、当該アクセラレータに備えられているメモリ内に実装されていてもよい。
The
ネットワークインタフェース74は、無線または有線により、通信ネットワーク8に接続するためのインタフェースである。ネットワークインタフェース74は、既存の通信規格に適合したものを用いればよい。ネットワークインタフェース74により、通信ネットワーク8を介して通信接続された外部装置9Aと情報のやり取りが行われてもよい。
The
外部装置9Aは、例えば、カメラ、モーションキャプチャ、出力先デバイス、外部のセンサ、入力元デバイスなどが含まれる。また、外部装置9Aは、訓練装置1の構成要素の一部の機能を有する装置でもよい。そして、コンピュータ装置7は、訓練装置1の処理結果の一部を、クラウドサービスのように通信ネットワーク8を介して送受信してもよい。
The
デバイスインタフェース75は、外部装置9Bと直接接続するUSB(Universal Serial Bus)などのインタフェースである。外部装置9Bは、外部記憶媒体でもよいし、ストレージ装置でもよい。各記憶部は、外部装置9Bにより実現されてもよい。
The
外部装置9Bは出力装置でもよい。出力装置は、例えば、画像を表示するための表示装置でもよいし、音声などを出力する装置などでもよい。例えば、LCD(Liquid Crystal Display)、CRT(Cathode Ray Tube)、PDP(Plasma Display Panel)、スピーカなどがあるが、これらに限られるものではない。
The
なお、外部装置9Bは入力装置でもよい。入力装置は、キーボード、マウス、タッチパネルなどのデバイスを備え、これらのデバイスにより入力された情報をコンピュータ装置7に与える。入力装置からの信号はプロセッサ71に出力される。
The
本発明の態様は、上記した個々の実施形態に限定されるものではない。特許請求の範囲に規定された内容及びその均等物から導き出される本発明の概念的な思想と趣旨を逸脱しない範囲において種々の追加、変更及び部分的削除が可能である。例えば、前述した全ての実施形態において、説明に用いた数値は、一例として示したものであり、これらに限られるものではない。 Aspects of the invention are not limited to the individual embodiments described above. Various additions, changes and partial deletions are possible without departing from the conceptual idea and gist of the present invention derived from the contents defined in the claims and the equivalents thereof. For example, in all the embodiments described above, the numerical values used for the description are shown as an example, and the numerical values are not limited to these.
1:訓練装置、10:入力部、12:記憶部、14:グラフ生成部、16:順伝播部、18:ID付与部、20:逆伝播部、22:出力部 1: Training device, 10: Input unit, 12: Storage unit, 14: Graph generation unit, 16: Forward propagation unit, 18: ID assignment unit, 20: Back propagation unit, 22: Output unit
Claims (10)
1又は複数のプロセッサと、
を備え、
前記1又は複数のプロセッサは、
誤差逆伝播の経路に基づいてグラフを生成し、
前記グラフにおいて、前記誤差逆伝播の経路に基づいて識別子を各ノードに付与し、
前記グラフ及び前記識別子に基づいて誤差逆伝播を実行する、
訓練装置。 One or more memories,
One or more processors,
Equipped with
The one or more processors are
Generate a graph based on the path of error backpropagation,
In the graph, an identifier is given to each node based on the path of the error back propagation,
Performing backpropagation based on the graph and the identifier,
Training equipment.
入力された変数、順伝播における演算及び出力された変数に対応する誤差逆伝播の経路となるノードをそれぞれ生成する、
請求項1に記載の訓練装置。 The one or more processors are
Generates a node that is a path of error back propagation corresponding to the input variable, the operation in forward propagation, and the output variable,
The training device according to claim 1.
複数の異なる前記誤差逆伝播の経路が存在する場合に、それぞれの経路を示す複数の前記グラフを生成する、
請求項1又は請求項2に記載の訓練装置。 The one or more processors are
When there are a plurality of different backpropagation paths, the plurality of graphs showing the respective paths are generated.
The training device according to claim 1 or 2.
前記誤差逆伝播の経路が同一の前記グラフごとに、一意的に前記識別子を各ノードへと付与する、
請求項1乃至請求項3のいずれかに記載の訓練装置。 The one or more processors are
For each of the graphs having the same error backpropagation path, the identifier is uniquely assigned to each node,
The training device according to any one of claims 1 to 3.
前記誤差逆伝播の経路が異なる前記グラフに属するノードに対して、異なる前記識別子を付与する、
請求項4に記載の訓練装置。 The one or more processors are
The different identifiers are given to nodes belonging to the graphs having different paths for the back propagation of errors,
The training device according to claim 4.
同一の前記識別子が付与されたノードについて誤差逆伝播を実行し、当該識別子について誤差逆伝播が完了した場合に、当該識別子が付与されている前記グラフのデータを破棄する、
請求項1乃至請求項5のいずれかに記載の訓練装置。 The one or more processors are
The error backpropagation is executed for the nodes to which the same identifier is added, and when the error backpropagation is completed for the identifier, the data of the graph to which the identifier is added is discarded.
The training device according to any one of claims 1 to 5.
異なる前記識別子を有するノード間において参照関係がある場合には、前記参照関係を有するノードを生成し、
前記参照関係に基づいて、誤差逆伝播を行う前記グラフの順番を決定する、
請求項1乃至請求項6のいずれかに記載の訓練装置。 The one or more processors are
When there is a reference relationship between the nodes having different identifiers, a node having the reference relationship is generated,
Determining the order of the graphs for backpropagation based on the reference relationship,
The training device according to any one of claims 1 to 6.
前記1又は複数のプロセッサが、前記グラフにおいて、前記誤差逆伝播の経路に基づいて識別子を各ノードに付与し、
前記1又は複数のプロセッサが、前記グラフ及び前記識別子に基づいて誤差逆伝播を実行する、
モデルの生成方法。 One or more processors generate a graph based on the path of error backpropagation,
The one or more processors assign an identifier to each node in the graph based on the error backpropagation path;
The one or more processors perform error backpropagation based on the graph and the identifier,
How to generate the model.
請求項8に記載のモデルの生成方法。 The one or more processors store the generated model in one or more memories,
The method for generating a model according to claim 8.
誤差逆伝播の経路に基づいてグラフを生成し、
前記グラフにおいて、誤差逆伝播の経路に基づいて識別子を各ノードに付与し、
前記グラフ及び前記識別子に基づいて誤差逆伝播を実行する、
プログラム。 When executed by one or more processors,
Generate a graph based on the path of error backpropagation,
In the graph, an identifier is assigned to each node based on the path of error back propagation,
Performing backpropagation based on the graph and the identifier,
program.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
US16/693,754 US20200167657A1 (en) | 2018-11-26 | 2019-11-25 | Training apparatus, training method, non-transitory computer readable medium, and model generating method |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2018220606 | 2018-11-26 | ||
JP2018220606 | 2018-11-26 |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2020091855A true JP2020091855A (en) | 2020-06-11 |
Family
ID=71013839
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2019209063A Pending JP2020091855A (en) | 2018-11-26 | 2019-11-19 | Training model, method of generating model, and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2020091855A (en) |
-
2019
- 2019-11-19 JP JP2019209063A patent/JP2020091855A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109858019B (en) | Dialogue state tracking method and device, storage medium and semantic recognition system | |
US9495206B2 (en) | Scheduling and execution of tasks based on resource availability | |
US11281491B2 (en) | Execution of services concurrently | |
CN110866687A (en) | Task allocation method and device | |
CN114424214A (en) | Hybrid data-model parallelism for efficient deep learning | |
CN111106960B (en) | Mapping method and mapping device of virtual network and readable storage medium | |
CN115185496A (en) | Service arrangement method based on Flowable workflow engine | |
JP2020091855A (en) | Training model, method of generating model, and program | |
US20200183737A1 (en) | Coordinating processes with interfering external actions | |
CN113222099A (en) | Convolution operation method and chip | |
US20090031119A1 (en) | Method for the operation of a multiprocessor system in conjunction with a medical imaging system | |
CN109829004A (en) | Data processing method, device, equipment and storage medium based on unmanned vehicle | |
CN110609744A (en) | Method, apparatus and computer program product for processing computing tasks | |
US20200167657A1 (en) | Training apparatus, training method, non-transitory computer readable medium, and model generating method | |
WO2018235124A1 (en) | Distributed allocation device, distributed allocation system, and distributed allocation method | |
CN116670660A (en) | Simulation model generation method and device for network on chip, electronic equipment and computer readable storage medium | |
CN112579258A (en) | Virtual machine management method, device, equipment and storage medium | |
CN110825461A (en) | Data processing method and device | |
CN117056068B (en) | JobEngine task splitting method in ETL | |
CN110113181A (en) | Node configuration method, device, computer installation and readable storage medium storing program for executing | |
CN108288302B (en) | Node division method applied to home decoration data management | |
CN110017844A (en) | Method, apparatus and calculating equipment for public transport path planning | |
WO2023148813A1 (en) | Production planning device, production planning method, and production planning program | |
CN109582295A (en) | A kind of data processing method, device, storage medium and processor | |
CN115730681B (en) | Model training method, device, equipment and storage medium |