JP7700542B2 - Information processing device, information processing method, and program - Google Patents
Information processing device, information processing method, and program Download PDFInfo
- Publication number
- JP7700542B2 JP7700542B2 JP2021111255A JP2021111255A JP7700542B2 JP 7700542 B2 JP7700542 B2 JP 7700542B2 JP 2021111255 A JP2021111255 A JP 2021111255A JP 2021111255 A JP2021111255 A JP 2021111255A JP 7700542 B2 JP7700542 B2 JP 7700542B2
- Authority
- JP
- Japan
- Prior art keywords
- data
- unlabeled data
- result corresponding
- unlabeled
- inference
- 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.)
- Active
Links
Images
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Description
本発明は、情報処理装置、情報処理方法およびプログラムに関する。 The present invention relates to an information processing device, an information processing method, and a program.
ニューラルネットワーク(以下、「NN」とも表記する。)は、画像認識などにおいて高い性能を有する。NNの学習精度を高めるためには、膨大な入力データとそれに対応した教師ラベルが必要となることが知られている。しかし、教師ラベルは人手によって付与される場合が多い。そのため、膨大な入力データに対して教師ラベルを付与する負担がユーザに掛かってしまう。 Neural networks (hereafter referred to as "NNs") have high performance in areas such as image recognition. It is known that in order to improve the learning accuracy of NNs, a huge amount of input data and corresponding teacher labels are required. However, teacher labels are often assigned manually. As a result, the burden of assigning teacher labels to huge amounts of input data falls on the user.
近年、この課題を解決するため、収集した入力データのうち少量のデータに教師ラベルを付与し、残りのデータには教師ラベルを付与せずにNNの学習を行う半教師あり学習の研究が盛んになっている。半教師あり学習によれば、ユーザの負担が大きく削減され得る。一般に、半教師あり学習に用いられる損失関数は、教師ラベル付きデータセット(ラベル付きデータセット)に対応する損失関数と、教師ラベル無しデータセット(ラベル無しデータセット)に対応する損失関数との重み和によって定義される。 In recent years, in order to solve this problem, research has been actively conducted into semi-supervised learning, in which teacher labels are assigned to a small amount of collected input data and the remaining data is trained by a neural network without teacher labels. Semi-supervised learning can significantly reduce the burden on users. In general, the loss function used in semi-supervised learning is defined as the weighted sum of the loss function corresponding to the dataset with teacher labels (labeled dataset) and the loss function corresponding to the dataset without teacher labels (unlabeled dataset).
非特許文献1に記載の手法は、特に画像認識における半教師あり学習の手法の一つであり、教師ラベルが付されていない画像に対して2種類のデータ拡張を施し、2種類のデータ拡張によって得られた2種類の画像同士を比較することに基づいて学習を行う手法である。これによって、学習精度を高めることが可能となる。非特許文献1に記載の手法においては、教師ラベルが付されていない入力データ(ラベル無しデータ)に依存しない定数が個々のラベル無しデータに対応する損失関数に乗じられることによって、ラベル無しデータ全体に対応する損失関数が算出される。 The method described in Non-Patent Document 1 is one of the semi-supervised learning methods in image recognition, in which two types of data augmentation are applied to an image without teacher labels, and learning is performed based on comparing the two types of images obtained by the two types of data augmentation. This makes it possible to improve the learning accuracy. In the method described in Non-Patent Document 1, a constant that does not depend on input data without teacher labels (unlabeled data) is multiplied by the loss function corresponding to each piece of unlabeled data to calculate the loss function corresponding to the entire unlabeled data.
非特許文献2に記載の手法は、半教師あり学習の一つであり、ラベル無しデータごとに影響度を示す係数を算出し、ラベル無しデータごとの係数と損失関数との重み和によってラベル無しデータ全体に対応する損失関数を算出する手法である。ただし、係数の算出は、学習用データとは別に用意された検証用の教師ラベル付きデータセットを用いて行われる。 The method described in Non-Patent Document 2 is a type of semi-supervised learning method that calculates a coefficient indicating the degree of influence for each piece of unlabeled data, and calculates a loss function corresponding to the entire unlabeled data by a weighted sum of the coefficient for each piece of unlabeled data and the loss function. However, the coefficients are calculated using a dataset with teacher labels for validation that is prepared separately from the training data.
しかしながら、非特許文献1に記載の手法によれば、個々のラベル無しデータに対応する損失関数が均等に扱われた上で、損失関数に基づくNNの更新が行われる。そのため、学習を妨害するラベル無しデータに対応する損失関数も均等に扱われるため、学習が不安定となりやすく、構築されるNNの精度も高くなりにくい。 However, according to the technique described in Non-Patent Document 1, the loss functions corresponding to each piece of unlabeled data are treated equally, and then the NN is updated based on the loss functions. As a result, the loss functions corresponding to unlabeled data that interferes with learning are also treated equally, making learning unstable and making it difficult to increase the accuracy of the constructed NN.
また、非特許文献2に記載の手法によれば、ラベル無しデータの影響度がサンプルごとに決定され得る。しかし、学習用データとは別に検証用の教師ラベル付きデータセットを用意する必要があるため、ユーザに掛かる負担が高くなる可能性がある。 In addition, according to the method described in Non-Patent Document 2, the influence of unlabeled data can be determined for each sample. However, since it is necessary to prepare a dataset with teacher labels for validation in addition to the training data, this may impose a heavy burden on users.
そこで、本発明は、これらの問題点を解決すべく提案されたものであり、学習用データとは別に検証用の教師ラベル付きデータセットを用意せずとも、高精度なNNを構築することを可能とする技術が提供されることが望まれる。 The present invention has been proposed to solve these problems, and it is hoped that a technology will be provided that makes it possible to build a highly accurate neural network without having to prepare a data set with teacher labels for validation purposes in addition to the training data.
上記問題を解決するために、本発明のある観点によれば、ラベル無しデータを取得するとともに、教師ラベルが付されたラベル有りデータを取得する入力部と、前記ラベル無しデータと前記ラベル有りデータとニューラルネットワークとに基づいて、前記ラベル無しデータに対応する推論結果と前記ラベル有りデータに対応する推論結果とを出力する推測部と、前記ラベル無しデータに対応する推論結果に基づいて、前記ラベル無しデータの影響度を示す係数を算出する係数生成部と、前記ラベル無しデータに対応する推論結果と前記係数とに基づいて、前記ラベル無しデータに対応する評価結果を出力するラベル無しデータ評価部と、前記ラベル有りデータに対応する推論結果と前記教師ラベルとに基づいて、前記ラベル有りデータに対応する評価結果を出力するラベル有りデータ評価部と、前記ラベル無しデータに対応する評価結果と、前記ラベル有りデータに対応する評価結果とに基づいて、前記ニューラルネットワークの重みパラメータを更新する更新部と、を備える、情報処理装置が提供される。
本発明の実施形態に係る技術においては、ラベル無しデータとラベル付きデータとが学習に用いられる。したがって、本発明の実施形態に係る技術は、半教師あり機械学習に関する技術に該当する。
In order to solve the above problem, according to an aspect of the present invention, there is provided an information processing device comprising: an input unit that acquires unlabeled data and labeled data to which a teacher label has been attached; an estimation unit that outputs an inference result corresponding to the unlabeled data and an inference result corresponding to the labeled data based on the unlabeled data, the labeled data, and a neural network; a coefficient generation unit that calculates a coefficient indicating a degree of influence of the unlabeled data based on the inference result corresponding to the unlabeled data; an unlabeled data evaluation unit that outputs an evaluation result corresponding to the unlabeled data based on the inference result corresponding to the unlabeled data and the coefficient; a labeled data evaluation unit that outputs an evaluation result corresponding to the labeled data based on the inference result corresponding to the labeled data and the teacher label; and an update unit that updates weight parameters of the neural network based on the evaluation result corresponding to the unlabeled data and the evaluation result corresponding to the labeled data.
In the technology according to the embodiment of the present invention, unlabeled data and labeled data are used for learning. Therefore, the technology according to the embodiment of the present invention corresponds to a technology related to semi-supervised machine learning.
前記ラベル無しデータに対応する推論結果は、クラスごとの推論値を含み、前記係数生成部は、ラベル無しデータごとに推論値が最大となる第1のクラスの推論値と前記第1のクラスとは異なる1または複数のクラスの推論値とに基づく差分を算出し、前記ラベル無しデータごとに前記差分に基づいて前記係数を算出してもよい。 The inference result corresponding to the unlabeled data may include an inference value for each class, and the coefficient generation unit may calculate a difference between the inference value of a first class having a maximum inference value for each unlabeled data and the inference values of one or more classes different from the first class, and calculate the coefficient for each unlabeled data based on the difference.
前記係数生成部は、前記ラベル無しデータごとに前記第1のクラスの推論値と推論値が2番目に大きい第2のクラスの推論値との差分を算出してもよい。 The coefficient generation unit may calculate the difference between the inferred value of the first class and the inferred value of the second class having the second largest inferred value for each of the unlabeled data.
前記係数生成部は、前記ラベル無しデータごとに前記第1のクラスの推論値と前記第1のクラスとは異なる複数のクラスの推論値の平均値との差分を算出してもよい。 The coefficient generation unit may calculate the difference between the inferred value of the first class and the average value of inferred values of multiple classes different from the first class for each of the unlabeled data.
前記係数生成部は、前記ラベル無しデータごとに前記差分に対して正の相関を有する数を前記係数として算出してもよい。 The coefficient generation unit may calculate, for each of the unlabeled data, a number that has a positive correlation with the difference as the coefficient.
前記ラベル無しデータに対応する推論結果は、クラスごとの推論値を含み、前記係数生成部は、ラベル無しデータごとに推論値に基づく予測クラスを特定し、前記予測クラスに対応するラベル無しデータの数を前記予測クラスの度数として算出し、前記ラベル無しデータごとに前記予測クラスの度数に基づいて前記係数を算出してもよい。 The inference result corresponding to the unlabeled data may include an inference value for each class, and the coefficient generation unit may identify a predicted class based on the inference value for each unlabeled data, calculate the number of unlabeled data corresponding to the predicted class as a frequency of the predicted class, and calculate the coefficient based on the frequency of the predicted class for each unlabeled data.
前記係数生成部は、前記ラベル無しデータごとに前記推論値が最大となるクラスを予測クラスとして特定してもよい。 The coefficient generation unit may identify, for each of the unlabeled data, the class for which the inference value is maximum as the predicted class.
前記係数生成部は、前記ラベル無しデータごとに前記予測クラスの度数に対して負の相関を有する数を前記係数として算出してもよい。 The coefficient generation unit may calculate, for each of the unlabeled data, a number that has a negative correlation with the frequency of the predicted class as the coefficient.
前記ラベル無しデータ評価部は、前記ラベル無しデータに対応する推論結果に基づく損失と前記係数とを乗算することに基づいて、前記ラベル無しデータに対応する評価結果を出力してもよい。 The unlabeled data evaluation unit may output an evaluation result corresponding to the unlabeled data based on multiplying a loss based on an inference result corresponding to the unlabeled data by the coefficient.
また、本発明の別の観点によれば、ラベル無しデータを取得するとともに、教師ラベルが付されたラベル有りデータを取得することと、前記ラベル無しデータと前記ラベル有りデータとニューラルネットワークとに基づいて、前記ラベル無しデータに対応する推論結果と前記ラベル有りデータに対応する推論結果とを出力することと、前記ラベル無しデータに対応する推論結果に基づいて、前記ラベル無しデータの影響度を示す係数を算出することと、前記ラベル無しデータに対応する推論結果と前記係数とに基づいて、前記ラベル無しデータに対応する評価結果を出力することと、前記ラベル有りデータに対応する推論結果と前記教師ラベルとに基づいて、前記ラベル有りデータに対応する評価結果を出力することと、前記ラベル無しデータに対応する評価結果と、前記ラベル有りデータに対応する評価結果とに基づいて、前記ニューラルネットワークの重みパラメータを更新することと、を備える、コンピュータが実行する情報処理方法が提供される。
According to another aspect of the present invention, there is provided an information processing method executed by a computer, comprising: acquiring unlabeled data and labeled data to which a teacher label has been attached; outputting an inference result corresponding to the unlabeled data and an inference result corresponding to the labeled data based on the unlabeled data, the labeled data, and a neural network; calculating a coefficient indicating a degree of influence of the unlabeled data based on the inference result corresponding to the unlabeled data; outputting an evaluation result corresponding to the unlabeled data based on the inference result corresponding to the unlabeled data and the coefficient; outputting an evaluation result corresponding to the labeled data based on the inference result corresponding to the labeled data and the teacher label; and updating weight parameters of the neural network based on the evaluation result corresponding to the unlabeled data and the evaluation result corresponding to the labeled data.
また、本発明の別の観点によれば、コンピュータを、ラベル無しデータを取得するとともに、教師ラベルが付されたラベル有りデータを取得する入力部と、前記ラベル無しデータと前記ラベル有りデータとニューラルネットワークとに基づいて、前記ラベル無しデータに対応する推論結果と前記ラベル有りデータに対応する推論結果とを出力する推測部と、前記ラベル無しデータに対応する推論結果に基づいて、前記ラベル無しデータの影響度を示す係数を算出する係数生成部と、前記ラベル無しデータに対応する推論結果と前記係数とに基づいて、前記ラベル無しデータに対応する評価結果を出力するラベル無しデータ評価部と、前記ラベル有りデータに対応する推論結果と前記教師ラベルとに基づいて、前記ラベル有りデータに対応する評価結果を出力するラベル有りデータ評価部と、前記ラベル無しデータに対応する評価結果と、前記ラベル有りデータに対応する評価結果とに基づいて、前記ニューラルネットワークの重みパラメータを更新する更新部と、を備える情報処理装置として機能させるプログラムが提供される。 According to another aspect of the present invention, a program is provided that causes a computer to function as an information processing device including an input unit that acquires unlabeled data and labeled data to which a teacher label has been attached, an estimation unit that outputs an inference result corresponding to the unlabeled data and an inference result corresponding to the labeled data based on the unlabeled data, the labeled data, and a neural network, a coefficient generation unit that calculates a coefficient indicating the influence of the unlabeled data based on the inference result corresponding to the unlabeled data, an unlabeled data evaluation unit that outputs an evaluation result corresponding to the unlabeled data based on the inference result corresponding to the unlabeled data and the coefficient, a labeled data evaluation unit that outputs an evaluation result corresponding to the labeled data based on the inference result corresponding to the labeled data and the teacher label, and an update unit that updates weight parameters of the neural network based on the evaluation result corresponding to the unlabeled data and the evaluation result corresponding to the labeled data.
以上説明したように本発明によれば、学習用データとは別に検証用の教師ラベル付きデータセットを用意せずとも、高精度なNNを構築することを可能とする技術が提供される。 As described above, the present invention provides technology that makes it possible to build a highly accurate neural network without having to prepare a dataset with teacher labels for validation in addition to the training data.
以下に添付図面を参照しながら、本発明の好適な実施の形態について詳細に説明する。なお、本明細書及び図面において、実質的に同一の機能構成を有する構成要素については、同一の符号を付することにより重複説明を省略する。 The preferred embodiment of the present invention will be described in detail below with reference to the attached drawings. Note that in this specification and the drawings, components having substantially the same functional configuration are designated by the same reference numerals to avoid redundant description.
また、本明細書および図面において、実質的に同一の機能構成を有する複数の構成要素を、同一の符号の後に異なる数字を付して区別する場合がある。ただし、実質的に同一の機能構成を有する複数の構成要素等の各々を特に区別する必要がない場合、同一符号のみを付する。また、異なる実施形態の類似する構成要素については、同一の符号の後に異なるアルファベットを付して区別する場合がある。ただし、異なる実施形態の類似する構成要素等の各々を特に区別する必要がない場合、同一符号のみを付する。 In addition, in this specification and drawings, multiple components having substantially the same functional configuration may be distinguished by adding different numbers after the same reference symbol. However, if there is no particular need to distinguish between multiple components having substantially the same functional configuration, only the same reference symbol will be used. In addition, similar components in different embodiments may be distinguished by adding different letters after the same reference symbol. However, if there is no particular need to distinguish between similar components in different embodiments, only the same reference symbol will be used.
(0.実施形態の概要)
本発明の実施形態の概要について説明する。本発明の実施形態では、ニューラルネットワークの学習を行う情報処理装置(以下、「学習装置」とも言う。)について説明する。学習装置においては、学習用データに基づいてニューラルネットワークの学習が行われる(学習段階)。その後、識別装置において、学習済みのニューラルネットワークと識別用データ(テストデータ)とに基づいて推定ラベルが出力される。
(0. Overview of the embodiment)
An overview of an embodiment of the present invention will be described. In the embodiment of the present invention, an information processing device that trains a neural network (hereinafter, also referred to as a "learning device") will be described. In the learning device, the neural network is trained based on training data (learning stage). After that, in the classification device, an estimated label is output based on the trained neural network and classification data (test data).
本発明の実施形態では、学習装置と識別装置とが同一のコンピュータによって実現される場合を主に想定する。しかし、学習装置と識別装置とは、別のコンピュータによって実現されてもよい。かかる場合には、学習装置によって生成された学習済みのニューラルネットワークが識別装置に提供される。例えば、学習済みのニューラルネットワークは、学習装置から識別装置に記録媒体を介して提供されてもよいし、通信を介して提供されてもよい。以下では、学習装置において実行される「学習段階」について説明する。 In the embodiment of the present invention, it is mainly assumed that the learning device and the identification device are realized by the same computer. However, the learning device and the identification device may be realized by different computers. In such a case, the trained neural network generated by the learning device is provided to the identification device. For example, the trained neural network may be provided from the learning device to the identification device via a recording medium or via communication. The "learning stage" executed in the learning device is described below.
(1.第1の実施形態)
まず、本発明の第1の実施形態について説明する。本発明の第1の実施形態においては、学習装置によって半教師あり学習が行われる。
1. First embodiment
First, a first embodiment of the present invention will be described. In the first embodiment of the present invention, semi-supervised learning is performed by a learning device.
(学習装置の構成)
図1を参照しながら、本発明の第1の実施形態に係る学習装置の構成例について説明する。図1は、本発明の第1の実施形態に係る学習装置10の機能構成例を示す図である。図1に示されるように、本発明の第1の実施形態に係る学習装置10は、入力部111と、推測部122と、係数生成部131と、ラベル無しデータ評価部132と、ラベル有りデータ評価部133と、更新部134とを備える。
(Configuration of the learning device)
An example of the configuration of a learning device according to a first embodiment of the present invention will be described with reference to Fig. 1. Fig. 1 is a diagram showing an example of the functional configuration of a
本発明の第1の実施形態では、推測部122が、ニューラルネットワーク120に含まれる場合を主に想定する。すなわち、推測部122は、ニューロンによって構築される計算グラフが処理順に接続されて構成されており、全体として1つのニューラルネットワークとみなされ得る。以下では、ニューラルネットワークを「NN」とも表記する。より詳細に、推測部122は、畳み込み層およびプーリング層を主に含んでよい。以下では、畳み込み層として、2次元畳み込み層が用いられる場合を主に想定するが、3次元畳み込み層が用いられてもよい。
In the first embodiment of the present invention, it is mainly assumed that the
推測部122の他、入力部111、係数生成部131、ラベル無しデータ評価部132、ラベル有りデータ評価部133および更新部134などは、CPU(Central Processing Unit)またはGPU(Graphics Processing Unit)などの演算装置を含み、ROM(Read Only Memory)により記憶されているプログラムが演算装置によりRAMに展開されて実行されることにより、その機能が実現され得る。このとき、当該プログラムを記録した、コンピュータに読み取り可能な記録媒体も提供され得る。あるいは、これらのブロックは、専用のハードウェアにより構成されていてもよいし、複数のハードウェアの組み合わせにより構成されてもよい。演算装置による演算に必要なデータは、図示しない記憶部によって適宜記憶される。
In addition to the
ラベル無しデータセット101、ラベル付きデータセット102および重みパラメータ121は、図示しない記憶部によって記憶される。かかる記憶部は、RAM(Random Access Memory)、ハードディスクドライブまたはフラッシュメモリなどのメモリによって構成されてよい。
The
初期状態において、重みパラメータ121には、初期値が設定されている。例えば、重みパラメータ121に設定される初期値は、ランダムな値であってよいが、どのような値であってもよい。例えば、重みパラメータ121に設定される初期値は、あらかじめ学習によって得られた学習済みの値であってもよい。
In the initial state, an initial value is set for the
(ラベル無しデータセット101)
ラベル無しデータセット101は、教師ラベルがそれぞれ対応付けられていない複数の学習用データ(入力データ)を含んで構成される。以下では、教師ラベルが対応付けられていない学習用データを「ラベル無しデータ」とも言う。なお、本発明の実施形態では、ラベル無しデータが画像データである場合(特に、静止画像データである場合)を主に想定する。しかし、ラベル無しデータの種類は特に限定されず、静止画像データ以外もラベル無しデータとして用いられ得る。例えば、ラベル無しデータは、複数のフレームを含んだ動画像データであってもよいし、時系列データまたは音声データであってもよい。
(Unlabeled Dataset 101)
The
(ラベル付きデータセット102)
ラベル付きデータセット102は、複数の学習用データ(入力データ)と当該複数の学習用データそれぞれに対応付けられた教師ラベルとを含んで構成される。以下では、教師ラベルが対応付けられた学習用データを「ラベル有りデータ」とも言う。また、教師ラベルとラベル有りデータとの組み合わせを「ラベル付きデータ」とも言う。教師ラベルは、人手または図示しない機能によって付与される。なお、ラベル無しデータの種類と同様に、ラベル有りデータの種類も特に限定されない。
(Labeled Dataset 102)
The labeled
(入力部111)
入力部111は、ラベル無しデータセット101からラベル無しデータを順次に取得し、取得したラベル無しデータをもとにミニバッチを作成し、作成したミニバッチをニューラルネットワーク120の推測部122に出力する。さらに、入力部111は、ラベル付きデータセット102からラベル付きデータ(教師ラベルとラベル有りデータとの組み合わせ)を順次に取得し、取得したラベル付きデータをもとにミニバッチを作成し、作成したミニバッチをニューラルネットワーク120の推測部122に出力する。ミニバッチのサイズは特に限定されない。
(Input unit 111)
The
(推測部122)
推測部122は、入力部111から出力されたミニバッチに含まれるラベル無しデータとニューラルネットワーク120とに基づいてラベル無しデータに対応する推論結果を得る。より詳細に、推測部122は、重みパラメータ121が設定されたニューラルネットワーク120にラベル無しデータを入力させたことに基づいて、ニューラルネットワーク120から出力されるデータをラベル無しデータに対応する推論結果として得る。推測部122は、ラベル無しデータに対応する推論結果を係数生成部131に出力する。
(Estimation unit 122)
The
このとき、推測部122は、ラベル無しデータに対応する推論結果として、半教師あり学習の枠組みに基づく2種類のラベルを係数生成部131に出力し得る。ここで、2種類のラベルを得るためのアルゴリズムは、特定のアルゴリズムに限定されず、半教師あり学習に用いられるアルゴリズムが用いられてよい。
At this time, the
例えば、入力部111が、ラベル無しデータセット101から取得したラベル無しデータに基づいて2種類のラベル無しデータを得てもよい。一例として、入力部111は、ラベル無しデータに対して2種類のデータ拡張を施すことによって2種類のラベル無しデータを得てもよい。このとき、入力部111は、推測部122に対して2種類のラベル無しデータを出力し、推測部122は、2種類のラベル無しデータそれぞれに対応するラベルを2種類のラベルとして係数生成部131に出力する。
For example, the
あるいは、入力部111から推測部122に出力されるラベル無しデータは1種類であり、推測部122において、2種類の重みパラメータを使用してもよい。一例として、推測部122は、入力部111から出力されるラベル無しデータに対して、重みパラメータ121の全部を適用して得たデータおよび重みパラメータ121の一部を適用して得たデータを2種類のラベルとして得てもよい。このとき、推測部122は、2種類のラベルを係数生成部131に出力する。
Alternatively, one type of unlabeled data may be output from the
例えば、推測部122は、2種類のラベルのうち、一方をラベル無しデータに対応する擬似的な教師ラベルとし、他方をラベル無しデータに対応する推定ラベルとして係数生成部131に出力する。なお、2種類のラベルのどちらを疑似的な教師ラベルとするかは限定されない。例えば、より弱いデータ拡張によって得られたラベルが疑似的な教師ラベルとされてもよい。あるいは、重みパラメータ121の全部の適用によって得られたラベルが疑似的な教師ラベルとされてもよい。
For example, the
さらに、推測部122は、入力部111から出力されたミニバッチに含まれるラベル有りデータとニューラルネットワーク120とに基づいてラベル有りデータに対応する推論結果を得る。より詳細に、推測部122は、重みパラメータ121が設定されたニューラルネットワーク120にラベル有りデータを入力させたことに基づいて、ニューラルネットワーク120から出力されるデータをラベル有りデータに対応する推論結果として得る。推測部122は、ラベル有りデータに対応する推論結果をラベル有りデータ評価部133に出力する。
Furthermore, the
なお、推測部122から出力される推論結果の形式は、特に限定されない。しかし、推測部122から出力される推論結果の形式は、教師ラベルの形式と合わせて設定されているのがよい。例えば、教師ラベルが分類問題のクラスを示し、クラス数分の長さを有するone-hotベクトルである場合、推測部122から出力される推論結果の形式も、クラス数分の長さを有するベクトルであってよい。このとき、推測部122から出力される推論結果は、クラスごとの値(以下、「推論値」とも言う。)を含み得る。
The format of the inference result output from the
一例として、推測部122によって全クラスの推論値の合計が1になるように調整される場合には、それぞれのクラスに対応する推論値は、それぞれのクラスに対応する確率に相当し得る。しかし、全クラスの推論値の合計は、推測部122によって1になるように調整されていなくてもよい。いずれの場合であっても、推測部122から出力される推論値は、そのクラスの確からしさが高いほど、大きい値であり得る。
As an example, when the inference values of all classes are adjusted by the
(係数生成部131)
係数生成部131は、推測部122から出力されたラベル無しデータに対応する推論結果に基づいて、ラベル無しデータの影響度を示す係数を算出する。より詳細に、係数生成部131は、ミニバッチに含まれるラベル無しデータごとに推論値に基づく予測クラスを特定する。バッチサイズBとすると、ラベル無しデータxu={x1
u,…,xB
u}の推論値に基づく予測クラスは、yu={y1
u,…,yB
u}として特定される。なお、yuの各要素は、予測クラスの番号であってよい。
(Coefficient Generation Unit 131)
The
ここで、予測クラスは、どのようにして特定されてもよい。一例として、推論値が最大となるクラスは、確からしさが最も高いクラスであると考えられる。そこで、係数生成部131は、ミニバッチに含まれるラベル無しデータごとに推論値が最大となるクラスを予測クラスとして特定してもよい。例えば、予測クラスの特定に用いられる推論値としては、2種類のラベルのいずれが用いられてもよいが、疑似的な教師ラベルが用いられるのが望ましい。
Here, the predicted class may be identified in any manner. As an example, the class with the largest inference value is considered to be the most likely class. Therefore, the
そして、係数生成部131は、予測クラスに対応するラベル無しデータの数を予測クラスの度数として算出する。例えば、ニューラルネットワーク120がNクラスへの分類問題を解く場合には(すなわち、ラベル無しデータに対応する推論結果がNクラス分の推論値を含む場合には)、予測クラスの度数ciは、以下の式(1)のように表現され得る。
Then, the
係数生成部131は、ミニバッチに含まれるラベル無しデータxuごとに、予測クラスの度数cに基づいて係数tを算出する。一例として、係数生成部131は、ミニバッチに含まれるラベル無しデータxuごとに予測クラスの度数cに対して負の相関を有する数を係数tとして算出するのが望ましい。これによって、度数cが小さい予測クラスに対応するラベル無しデータほど、影響度が高く扱われるようになる。
The
例えば、入力値に対して負の相関を示す出力値を返却する関数をfとすると、入力値に対して負の相関を示す出力値を返却する関数fは、以下の式(2)のように表現され得る。 For example, if f is a function that returns an output value that shows a negative correlation with respect to an input value, then the function f that returns an output value that shows a negative correlation with respect to an input value can be expressed as in the following equation (2).
例えば、入力値に対して負の相関を示す出力値を返却する関数fの例として、以下の式(3)が挙げられる。 For example, the following formula (3) is an example of a function f that returns an output value that shows a negative correlation with an input value.
係数生成部131は、ミニバッチに含まれるラベル無しデータごとの推論結果および係数を、ラベル無しデータ評価部132に出力する。
The
(ラベル無しデータ評価部132)
ラベル無しデータ評価部132は、ミニバッチに含まれるラベル無しデータごとの推論結果および係数に基づいて、ラベル無しデータに対応する評価結果を得る。より詳細に、ラベル無しデータ評価部132は、ミニバッチに含まれるラベル無しデータごとに、推論結果に基づいて損失を算出し、ラベル無しデータごとの損失および係数に基づいて、ラベル無しデータに対応する評価結果を得る。
(Unlabeled Data Evaluation Unit 132)
The unlabeled
まず、ラベル無しデータ評価部132は、ラベル無しデータごとに、疑似的な教師ラベルに基づいて推定ラベルを評価して損失を算出する。
First, the unlabeled
ここで、損失の算出に用いられる損失関数は特定の関数に限定されず、一般的なニューラルネットワークにおいて用いられる損失関数と同様の損失関数が用いられてよい。例えば、損失関数は、ラベル無しデータに対応する疑似的な教師ラベルとラベル無しデータに対応する推定ラベルとの差分に基づく平均二乗誤差であってもよいし、ラベル無しデータに対応する疑似的な教師ラベルとラベル無しデータに対応する推定ラベルとの差分に基づく交差エントロピー誤差であってもよい。 Here, the loss function used to calculate the loss is not limited to a specific function, and a loss function similar to that used in a general neural network may be used. For example, the loss function may be a mean square error based on the difference between the pseudo teacher label corresponding to the unlabeled data and the estimated label corresponding to the unlabeled data, or a cross entropy error based on the difference between the pseudo teacher label corresponding to the unlabeled data and the estimated label corresponding to the unlabeled data.
次に、ラベル無しデータ評価部132は、ラベル無しデータごとの損失および係数に基づいて、ラベル無しデータに対応する評価結果を得る。より詳細に、ラベル無しデータ評価部132は、ラベル無しデータごとに損失と係数とを乗算することに基づいて、ラベル無しデータに対応する評価結果を得る。
Next, the unlabeled
一例として、ラベル無しデータをxuとし、重みパラメータ121をθとし、係数生成部131によって算出された係数をtとすると、ラベル無しデータに対応する評価結果luは、以下の式(4)に示すように、ラベル無しデータごとの損失と係数との乗算結果のミニバッチにおける合計によって算出され得る。
As an example, if the unlabeled data is x u , the
ラベル無しデータ評価部132は、ラベル無しデータに対応する評価結果を更新部134に出力する。
The unlabeled
(ラベル有りデータ評価部133)
ラベル有りデータ評価部133は、ミニバッチに含まれるラベル有りデータごとに、ラベル有りデータに対応する教師ラベルに基づいて、ラベル有りデータを評価してラベル有りデータごとの評価結果を得る。より詳細に、ラベル有りデータ評価部133は、ラベル有りデータに対応する教師ラベルとラベル有りデータとに基づいて損失を算出し、ラベル有りデータごとの損失に基づいて、ラベル有りデータに対応する評価結果を得る。
(Labeled Data Evaluation Unit 133)
The labeled
まず、ラベル有りデータ評価部133は、ラベル有りデータごとに、ラベル有りデータに対応する教師ラベルに基づいてラベル有りデータを評価して損失を算出する。
First, the labeled
ここで、損失関数は特定の関数に限定されず、一般的なニューラルネットワークにおいて用いられる損失関数と同様の損失関数が用いられてよい。例えば、損失関数は、ラベル有りデータに対応する教師ラベルとラベル有りデータとの差分に基づく平均二乗誤差であってもよいし、ラベル有りデータに対応する教師ラベルとラベル有りデータとの差分に基づく交差エントロピー誤差であってもよい。 Here, the loss function is not limited to a specific function, and a loss function similar to that used in a general neural network may be used. For example, the loss function may be a mean square error based on the difference between the labeled data and the teacher label corresponding to the labeled data, or a cross entropy error based on the difference between the labeled data and the teacher label corresponding to the labeled data.
次に、ラベル有りデータ評価部133は、ラベル有りデータごとの損失に基づいて、ラベル有りデータに対応する評価結果を得る。より詳細に、ラベル有りデータ評価部133は、ラベル有りデータごとの損失のミニバッチにおける合計によって、ラベル有りデータに対応する評価結果を得る。
Next, the labeled
一例として、ラベル有りデータをxtとし、ラベル有りデータに対応する教師ラベルをxtとし、重みパラメータ121をθとすると、ラベル有りデータに対応する評価結果lsは、以下の式(5)に示すように表現され得る。
As an example, if labeled data is xt , a teacher label corresponding to the labeled data is xt , and a
ラベル有りデータ評価部133は、ラベル有りデータに対応する評価結果を更新部134に出力する。
The labeled
(更新部134)
更新部134は、ラベル無しデータ評価部132から出力されたラベル無しデータに対応する評価結果とラベル有りデータ評価部133から出力されたラベル有りデータに対応する評価結果とに基づいて、重みパラメータ121の更新を行う。これによって、ラベル無しデータに対応する推定ラベルがラベル無しデータに対応する疑似的な教師ラベルに近づくように、かつ、ラベル有りデータがラベル有りデータに対応する教師ラベルに近づくように、重みパラメータ121が訓練され得る。
(Update unit 134)
The
例えば、更新部134は、ラベル有りデータに対応する評価結果とラベル無しデータに対応する評価結果との重み付き和(以下、単に「重み付き和」とも言う。)に基づいて、重みパラメータ121の更新を行ってよい。より詳細に、更新部134は、ラベル有りデータに対応する評価結果とラベル無しデータに対応する評価結果との重み付き和に基づく誤差逆伝播法(バックプロパゲーション)によって重みパラメータ121を更新してよい。
For example, the
重み付き和は、どのように表現されてもよい。一例として、式(5)に示されたように、ラベル有りデータに対応する評価結果をlsとし、式(4)に示されたように、ラベル無しデータに対応する評価結果をluとし、重み付き和を取るためのハイパーパラメータをλとすると、重み付き和Lは、以下の式(6)に示すように表現され得る。 The weighted sum may be expressed in any way. As an example, if the evaluation result corresponding to the labeled data is l s as shown in formula (5), the evaluation result corresponding to the unlabeled data is l u as shown in formula (4), and the hyperparameter for taking the weighted sum is λ, the weighted sum L can be expressed as shown in formula (6) below.
なお、更新部134は、重みパラメータ121の更新が終わるたびに、学習の終了条件が満たされたか否かを判断する。学習の終了条件が満たされていないと判断された場合には、入力部111によって次の入力データ(ラベル有りデータおよび教師ラベルの組み合わせ、および、ラベル無しデータ)が取得され、推測部122、係数生成部131、ラベル無しデータ評価部132、ラベル有りデータ評価部133および更新部134それぞれによって、当該次の入力データに基づく各自の処理が再度実行される。一方、学習の終了条件が満たされたと判断された場合には、学習が終了される。
Note that the
なお、学習の終了条件は特に限定されず、ニューラルネットワーク120の学習がある程度行われたことを示す条件であればよい。具体的に、学習の終了件は、当該重み付き和の値が閾値よりも小さいという条件を含んでもよい。あるいは、学習の終了条件は、当該重み付き和の値の変化が閾値よりも小さいという条件(当該重み付き和の値が収束状態になったという条件)を含んでもよい。あるいは、学習の終了条件は、重みパラメータ121の更新が所定の回数行われたという条件を含んでもよい。あるいは、ニューラルネットワーク120の精度(例えば、正解率など)が算出される場合、学習の終了条件は、精度が所定の割合(例えば、90%など)を超えるという条件を含んでもよい。
The learning end condition is not particularly limited, and may be any condition that indicates that the
以上、本発明の第1の実施形態に係る学習装置の構成例について説明した。 The above describes an example of the configuration of a learning device according to the first embodiment of the present invention.
(学習段階の動作)
続いて、図2を参照しながら、本発明の第1の実施形態に係る学習装置10によって実行される「学習段階」の動作の流れについて説明する。図2は、本発明の第1の実施形態に係る学習装置10によって実行される学習段階の動作例を示すフローチャートである。
(Learning stage operation)
Next, a flow of operations in a "learning stage" executed by the
まず、入力部111は、ラベル無しデータセット101からバッチサイズのラベル無しデータを取得することによってミニバッチを作成し、作成したミニバッチをニューラルネットワーク120の推測部122に出力する(S101)。
First, the
続いて、推測部122は、入力部111によって作成されたミニバッチに含まれるラベル無しデータとニューラルネットワーク120とに基づいてラベル無しデータに対応する推論結果を得る(S102)。推測部122は、ラベル無しデータに対応する推論結果を係数生成部131に出力する。
Then, the
このとき、推測部122は、ラベル無しデータに対応する推論結果として、2種類のラベルを係数生成部131に出力し得る。例えば、推測部122は、2種類のラベルのうち、一方をラベル無しデータに対応する擬似的な教師ラベルとし、他方をラベル無しデータに対応する推定ラベルとして係数生成部131に出力する。
At this time, the
係数生成部131は、推測部122から出力されたラベル無しデータに対応する推論結果に基づいて、ラベル無しデータの影響度を示す係数を算出する(S103)。より詳細に、係数生成部131は、ミニバッチに含まれるラベル無しデータごとに推論値に基づく予測クラスを特定する。一例として、係数生成部131は、ミニバッチに含まれるラベル無しデータごとに推論値が最大となるクラスを予測クラスとして特定してもよい。例えば、予測クラスの特定に用いられる推論値としては、2種類のラベルのいずれが用いられてもよいが、疑似的な教師ラベルが用いられるのが望ましい。
The
そして、係数生成部131は、予測クラスに対応するラベル無しデータの数を予測クラスの度数として算出する。係数生成部131は、ミニバッチに含まれるラベル無しデータごとに、予測クラスの度数に基づいて係数を算出する。一例として、係数生成部131は、ミニバッチに含まれるラベル無しデータごとに予測クラスの度数に対して負の相関を有する数を係数として算出するのが望ましい。これによって、度数が小さい予測クラスに対応するラベル無しデータほど、影響度が高く扱われるようになる。
Then, the
係数生成部131は、ミニバッチに含まれるラベル無しデータごとの推論結果および係数を、ラベル無しデータ評価部132に出力する。
The
ラベル無しデータ評価部132は、ミニバッチに含まれるラベル無しデータごとの推論結果および係数に基づいて、ラベル無しデータに対応する評価結果を得る(S104)。より詳細に、ラベル無しデータ評価部132は、ミニバッチに含まれるラベル無しデータごとに、推論結果に基づいて損失を算出し、ラベル無しデータごとの損失および係数に基づいて、ラベル無しデータに対応する評価結果を得る。ラベル無しデータ評価部132は、ラベル無しデータに対応する評価結果を更新部134に出力する。
The unlabeled
続いて、入力部111は、ラベル付きデータセット102からバッチサイズのラベル付きデータを教師ラベルとラベル有りデータとの組み合わせとして取得することによってミニバッチを作成し、作成したミニバッチをニューラルネットワーク120の推測部122に出力する(S105)。
Then, the
続いて、推測部122は、入力部111によって作成されたミニバッチに含まれるラベル有りデータとニューラルネットワーク120とに基づいてラベル有りデータに対応する推論結果を得る(S106)。推測部122は、ラベル有りデータに対応する推論結果をラベル有りデータ評価部133に出力する。
Then, the
ラベル有りデータ評価部133は、ミニバッチに含まれるラベル有りデータごとに、ラベル有りデータに対応する教師ラベルに基づいて、ラベル有りデータを評価してラベル有りデータごとの評価結果を得る(S107)。より詳細に、ラベル有りデータ評価部133は、ラベル有りデータに対応する教師ラベルとラベル有りデータとに基づいて損失を算出し、ラベル有りデータごとの損失に基づいて、ラベル有りデータに対応する評価結果を得る。ラベル有りデータ評価部133は、ラベル有りデータに対応する評価結果を更新部134に出力する。
For each piece of labeled data included in the mini-batch, the labeled
更新部134は、ラベル無しデータ評価部132から出力されたラベル無しデータに対応する評価結果とラベル有りデータ評価部133から出力されたラベル有りデータに対応する評価結果とに基づいて、重みパラメータ121の更新を行う(S108)。これによって、ラベル無しデータに対応する推定ラベルがラベル無しデータに対応する疑似的な教師ラベルに近づくように、かつ、ラベル有りデータがラベル有りデータに対応する教師ラベルに近づくように、重みパラメータ121が訓練され得る。
The
例えば、更新部134は、ラベル有りデータに対応する評価結果とラベル無しデータに対応する評価結果との重み付き和に基づいて、重みパラメータ121の更新を行ってよい。より詳細に、更新部134は、ラベル有りデータに対応する評価結果とラベル無しデータに対応する評価結果との重み付き和に基づく誤差逆伝播法(バックプロパゲーション)によって重みパラメータ121を更新してよい。
For example, the
更新部134は、重みパラメータ121の更新が終わるたびに、学習の終了条件が満たされたか否かを判断する(S109)。学習の終了条件が満たされていないと判断された場合には(S109において「NO」)、S101に動作が移行され、入力部111によって次の入力データが取得され、推測部122、係数生成部131、ラベル無しデータ評価部132、ラベル有りデータ評価部133および更新部134それぞれによって、当該次の入力データに基づく各自の処理が再度実行される。一方、学習の終了条件が満たされたと判断された場合には、学習が終了される。
Each time the
以上、本発明の第1の実施形態に係る学習装置10によって実行される「学習段階」の動作の流れについて説明した。
The above describes the flow of operations in the "learning stage" performed by the
(第1の実施形態のまとめ)
以上に説明したように、本発明の第1の実施形態によれば、ラベル無しデータに対応する推論結果に基づいて、ラベル無しデータごとの擬似的な予測クラスが特定される。そして、疑似的な予測クラスに基づいて損失に影響する度合いがラベル無しデータごとに自動的に決定される。
(Summary of the first embodiment)
As described above, according to the first embodiment of the present invention, a pseudo predicted class is identified for each piece of unlabeled data based on the inference result corresponding to the unlabeled data. Then, the degree of influence on the loss is automatically determined for each piece of unlabeled data based on the pseudo predicted class.
これによって、学習段階(特に学習初期段階)において発生し得る現象(すなわち、推論結果が特定のクラスに集中してしまう現象)に対して、推論結果が集中してしまうクラスの損失への影響度を下げることが可能となる。その結果として、安定した学習が可能となるという効果が享受され得る。 This makes it possible to reduce the impact of a phenomenon that can occur during the learning stage (especially the early stages of learning) (i.e., the phenomenon in which inference results are concentrated in a specific class) on the loss of the class in which the inference results are concentrated. As a result, the effect of stable learning can be enjoyed.
また、本発明の第1の実施形態によれば、半教師あり学習のアルゴリズムに依存せず、ラベル無しデータの損失への影響度が決定され得る。さらに、本発明の第1の実施形態によれば、損失への影響度が比較的小さいラベル無しデータが存在する場合であっても、その影響度が係数として学習に用いられるため、閾値などを利用した人手によるデータ選別作業を不要としつつ、安定した学習が可能になる。 In addition, according to the first embodiment of the present invention, the impact of unlabeled data on loss can be determined without relying on a semi-supervised learning algorithm. Furthermore, according to the first embodiment of the present invention, even if there is unlabeled data whose impact on loss is relatively small, the impact is used as a coefficient for learning, making it possible to perform stable learning while eliminating the need for manual data selection using thresholds, etc.
以上、本発明の第1の実施形態について説明した。 The above describes the first embodiment of the present invention.
(2.第2の実施形態)
続いて、本発明の第2の実施形態について説明する。本発明の第2の実施形態においても、学習装置によって半教師あり学習が行われる。
2. Second embodiment
Next, a second embodiment of the present invention will be described. In the second embodiment of the present invention, semi-supervised learning is also performed by a learning device.
図1に示されるように、本発明の第2の実施形態に係る学習装置10は、本発明の第1の実施形態に係る学習装置10と同様に、入力部111と、推測部122と、係数生成部131と、ラベル無しデータ評価部132と、ラベル有りデータ評価部133と、更新部134とを備える。
As shown in FIG. 1, the
本発明の第2の実施形態に係る学習装置10は、本発明の第1の実施形態に係る学習装置10と比較して、係数生成部131の機能が主に異なる。したがって、以下では、係数生成部131の機能について主に説明を行い、他のブロックの機能についての詳細な説明は省略する。
The
(係数生成部131)
係数生成部131は、推測部122から出力されたラベル無しデータに対応する推論結果に基づいて、ラベル無しデータの影響度を示す係数を算出する。より詳細に、係数生成部131は、ミニバッチに含まれるラベル無しデータごとに推論値が最大となる第1のクラスを特定する。そして、係数生成部131は、第1のクラスの推論値と第1のクラスとは異なる1または複数のクラスの推論値とに基づく差分を算出する。例えば、差分の算出に用いられる推論値としては、2種類のラベルのいずれが用いられてもよいが、疑似的な教師ラベルが用いられるのが望ましい。係数生成部131は、ラベル無しデータごとに差分に基づいて係数を算出する。
(Coefficient Generation Unit 131)
The
一例として、係数生成部131は、推論値が2番目に大きい第2のクラスを特定してもよい。このとき、係数生成部131は、ラベル無しデータごとに第1のクラスの推論値と第2のクラスの推論値との差分を算出してもよい。例えば、ニューラルネットワーク120がNクラスへの分類問題を解く場合には(すなわち、ラベル無しデータに対応する推論結果がNクラス分の推論値を含む場合には)、差分diは、以下の式(7)のように表現され得る。
As an example, the
式(7)において、vは、ラベル無しデータに対応する推論結果を示し、各クラスに対応する推論値の集合を示す。argmaxは、引数として渡された推論値に対応するクラス番号を出力値として返却する関数である。 In equation (7), v represents the inference result corresponding to the unlabeled data and represents a set of inference values corresponding to each class. argmax is a function that returns the class number corresponding to the inference value passed as an argument as an output value.
なお、第1のクラスの推論値と第1のクラスとは異なる1または複数のクラスの推論値とに基づく差分を算出する手法は限定されない。例えば、係数生成部131は、ラベル無しデータごとに第1のクラスの推論値と第1のクラスとは異なる複数のクラスの推論値の平均値との差分を算出してもよい。このとき、平均値を取る関数をaveとすると、差分diは、以下の式(8)のように表現され得る。
The method of calculating the difference based on the inferred value of the first class and the inferred values of one or more classes different from the first class is not limited. For example, the
係数生成部131は、ミニバッチに含まれるラベル無しデータごとに、差分dに基づいて係数tを算出する。一例として、係数生成部131は、ミニバッチに含まれるラベル無しデータごとに差分dに対して正の相関を有する数を係数tとして算出するのが望ましい。これによって、大きい差分に対応するラベル無しデータほど、影響度が高く扱われるようになる。
The
例えば、入力値に対して正の相関を示す出力値を返却する関数をgとすると、入力値に対して正の相関を示す出力値を返却する関数gは、以下の式(9)のように表現され得る。 For example, if a function that returns an output value that shows a positive correlation with an input value is g, the function g that returns an output value that shows a positive correlation with an input value can be expressed as the following equation (9).
例えば、入力値に対して正の相関を示す出力値を返却する関数gの例として、以下の式(10)が挙げられる。 For example, the following formula (10) is an example of a function g that returns an output value that shows a positive correlation with an input value.
係数生成部131は、ミニバッチに含まれるラベル無しデータごとの推論結果および係数を、ラベル無しデータ評価部132に出力する。
The
以上、本発明の第2の実施形態に係る学習装置の構成例について説明した。 The above describes an example of the configuration of a learning device according to the second embodiment of the present invention.
(学習段階の動作)
続いて、図2を参照しながら、本発明の第2の実施形態に係る学習装置10によって実行される「学習段階」の動作の流れについて説明する。本発明の第2の実施形態に係る学習装置10によって実行される「学習段階」の動作は、本発明の第1の実施形態に係る学習装置10によって実行される「学習段階」の動作と比較して、係数生成部131の動作が主に異なる。したがって、以下では、係数生成部131の動作について主に説明を行い、他の動作についての詳細な説明は省略する。
(Learning stage operation)
Next, the flow of operations in the "learning stage" performed by the
本発明の第2の実施形態においても、本発明の第1の実施形態と同様に、S101~S102が実行される。続いて、係数生成部131は、推測部122から出力されたラベル無しデータに対応する推論結果に基づいて、ラベル無しデータの影響度を示す係数を算出する(S103)。
In the second embodiment of the present invention, steps S101 to S102 are executed in the same manner as in the first embodiment of the present invention. Next, the
より詳細に、係数生成部131は、ミニバッチに含まれるラベル無しデータごとに推論値が最大となる第1のクラスを特定する。そして、係数生成部131は、第1のクラスの推論値と第1のクラスとは異なる1または複数のクラスの推論値とに基づく差分を算出する。例えば、差分の算出に用いられる推論値としては、2種類のラベルのいずれが用いられてもよいが、疑似的な教師ラベルが用いられるのが望ましい。係数生成部131は、ラベル無しデータごとに差分に基づいて係数を算出する。
More specifically, the
一例として、係数生成部131は、推論値が2番目に大きい第2のクラスを特定してもよい。このとき、係数生成部131は、ラベル無しデータごとに第1のクラスの推論値と第2のクラスの推論値との差分を算出してもよい。あるいは、係数生成部131は、ラベル無しデータごとに第1のクラスの推論値と第1のクラスとは異なる複数のクラスの推論値の平均値との差分を算出してもよい。
As an example, the
係数生成部131は、ミニバッチに含まれるラベル無しデータごとに、差分に基づいて係数を算出する。一例として、係数生成部131は、ミニバッチに含まれるラベル無しデータごとに差分に対して正の相関を有する数を係数として算出するのが望ましい。これによって、大きい差分に対応するラベル無しデータほど、影響度が高く扱われるようになる。
The
係数生成部131は、ミニバッチに含まれるラベル無しデータごとの推論結果および係数を、ラベル無しデータ評価部132に出力する。
The
本発明の第2の実施形態においても、本発明の第1の実施形態と同様に、S104~S109が実行される。 In the second embodiment of the present invention, steps S104 to S109 are executed in the same manner as in the first embodiment of the present invention.
以上、本発明の第2の実施形態に係る学習装置10によって実行される「学習段階」の動作の流れについて説明した。
The above describes the flow of operations in the "learning stage" performed by the
(第2の実施形態のまとめ)
以上に説明したように、本発明の第2の実施形態によれば、ラベル無しデータに対応する推論結果に基づいて、ラベル無しデータごとに推論値が最大となる第1のクラスの推論値と第1のクラスとは異なる1または複数のクラスの推論値とに基づく差分が算出される。そして、差分に基づいて損失に影響する度合いがラベル無しデータごとに自動的に決定される。
(Summary of the second embodiment)
As described above, according to the second embodiment of the present invention, a difference is calculated for each piece of unlabeled data based on an inference result corresponding to the unlabeled data, between an inferred value of a first class having a maximum inferred value and inferred values of one or more classes different from the first class. Then, a degree of influence on loss is automatically determined for each piece of unlabeled data based on the difference.
これによって、本発明の第1の実施形態と同様の効果が享受され得る。さらに、本発明の第2の実施形態によれば、バッチサイズが比較的小さい場合であっても、損失に影響する度合いが高精度に決定され得る。そのため、本発明の第2の実施形態によれば、バッチサイズが比較的小さい場合であっても、安定した学習が可能になる。 This allows the same effects as those of the first embodiment of the present invention to be obtained. Furthermore, according to the second embodiment of the present invention, even if the batch size is relatively small, the degree of influence on the loss can be determined with high accuracy. Therefore, according to the second embodiment of the present invention, stable learning is possible even if the batch size is relatively small.
以上、本発明の第2の実施形態について説明した。 The second embodiment of the present invention has been described above.
(3.ハードウェア構成例)
続いて、本発明の第1の実施形態に係る学習装置10のハードウェア構成例について説明する。なお、本発明の第2の実施形態に係る学習装置10のハードウェア構成も、本発明の第1の実施形態に係る学習装置10のハードウェア構成と同様に実現され得る。
(3. Hardware Configuration Example)
Next, a hardware configuration example of the
以下では、本発明の第1の実施形態に係る学習装置10のハードウェア構成例として、情報処理装置900のハードウェア構成例について説明する。なお、以下に説明する情報処理装置900のハードウェア構成例は、学習装置10のハードウェア構成の一例に過ぎない。したがって、学習装置10のハードウェア構成は、以下に説明する情報処理装置900のハードウェア構成から不要な構成が削除されてもよいし、新たな構成が追加されてもよい。
Below, an example of the hardware configuration of an
図3は、本発明の第1の実施形態に係る学習装置10の例としての情報処理装置900のハードウェア構成を示す図である。情報処理装置900は、CPU(Central Processing Unit)901と、ROM(Read Only Memory)902と、RAM(Random Access Memory)903と、ホストバス904と、ブリッジ905と、外部バス906と、インタフェース907と、入力装置908と、出力装置909と、ストレージ装置910と、通信装置911と、を備える。
Figure 3 is a diagram showing the hardware configuration of an
CPU901は、演算処理装置および制御装置として機能し、各種プログラムに従って情報処理装置900内の動作全般を制御する。また、CPU901は、マイクロプロセッサであってもよい。ROM902は、CPU901が使用するプログラムや演算パラメータ等を記憶する。RAM903は、CPU901の実行において使用するプログラムや、その実行において適宜変化するパラメータ等を一時記憶する。これらはCPUバス等から構成されるホストバス904により相互に接続されている。
The
ホストバス904は、ブリッジ905を介して、PCI(Peripheral Component Interconnect/Interface)バス等の外部バス906に接続されている。なお、必ずしもホストバス904、ブリッジ905および外部バス906を分離構成する必要はなく、1つのバスにこれらの機能を実装してもよい。
The
入力装置908は、マウス、キーボード、タッチパネル、ボタン、マイクロフォン、スイッチおよびレバー等ユーザが情報を入力するための入力手段と、ユーザによる入力に基づいて入力信号を生成し、CPU901に出力する入力制御回路等から構成されている。情報処理装置900を操作するユーザは、この入力装置908を操作することにより、情報処理装置900に対して各種のデータを入力したり処理動作を指示したりすることができる。
The
出力装置909は、例えば、CRT(Cathode Ray Tube)ディスプレイ装置、液晶ディスプレイ(LCD)装置、OLED(Organic Light Emitting Diode)装置、ランプ等の表示装置およびスピーカ等の音声出力装置を含む。
The
ストレージ装置910は、データ格納用の装置である。ストレージ装置910は、記憶媒体、記憶媒体にデータを記録する記録装置、記憶媒体からデータを読み出す読出し装置および記憶媒体に記録されたデータを削除する削除装置等を含んでもよい。ストレージ装置910は、例えば、HDD(Hard Disk Drive)で構成される。このストレージ装置910は、ハードディスクを駆動し、CPU901が実行するプログラムや各種データを格納する。
The
通信装置911は、例えば、ネットワークに接続するための通信デバイス等で構成された通信インタフェースである。また、通信装置911は、無線通信または有線通信のどちらに対応してもよい。
The
以上、本発明の第1の実施形態に係る学習装置10のハードウェア構成例について説明した。
The above describes an example of the hardware configuration of the
(4.まとめ)
以上、添付図面を参照しながら本発明の好適な実施形態について詳細に説明したが、本発明はかかる例に限定されない。本発明の属する技術の分野における通常の知識を有する者であれば、特許請求の範囲に記載された技術的思想の範疇内において、各種の変更例または修正例に想到し得ることは明らかであり、これらについても、当然に本発明の技術的範囲に属するものと了解される。
(4. Summary)
Although the preferred embodiment of the present invention has been described in detail above with reference to the accompanying drawings, the present invention is not limited to such an example. It is clear that a person having ordinary knowledge in the technical field to which the present invention pertains can conceive of various modified or altered examples within the scope of the technical ideas described in the claims, and it is understood that these also naturally belong to the technical scope of the present invention.
本発明の第1の実施形態および本発明の第2の実施形態では、学習用データが画像データである場合(特に、静止画像データである場合)について主に説明した。しかし、学習用データの種類は特に限定されない。例えば、学習用データの種類に合わせた特徴量が抽出されれば、静止画像データ以外も学習用データとして用いられ得る。例えば、学習用データは、複数のフレームを含んだ動画像データであってもよいし、音声データであってもよい。 In the first embodiment and the second embodiment of the present invention, the case where the learning data is image data (particularly, still image data) has been mainly described. However, the type of learning data is not particularly limited. For example, as long as features that match the type of learning data are extracted, data other than still image data may also be used as learning data. For example, the learning data may be video data including multiple frames, or may be audio data.
このとき、学習用データが静止画像データである場合には、推測部122に含まれる畳み込み層として2次元畳み込み層が用いられるのが一般的である。一方、推測部122に含まれる畳み込み層として3次元畳み込み層が用いられれば、学習用データとして動画像データが適用され得る。
In this case, when the learning data is still image data, a two-dimensional convolutional layer is generally used as the convolutional layer included in the
本発明の第1の実施形態では、入力値に対して負の相関を示す出力値を返却する関数fの例として、以下の式(3)を挙げて説明した。しかし、入力値に対して負の相関を示す出力値を返却する関数fは、かかる例に限定されない。例えば、入力値に対して負の相関を示す出力値を返却する関数fの例として、以下の式(3-A)および式(3-B)なども挙げられる。 In the first embodiment of the present invention, the following formula (3) has been given as an example of a function f that returns an output value that shows a negative correlation with an input value. However, the function f that returns an output value that shows a negative correlation with an input value is not limited to this example. For example, the following formulas (3-A) and (3-B) are also examples of a function f that returns an output value that shows a negative correlation with an input value.
本発明の第2の実施形態では、入力値に対して正の相関を示す出力値を返却する関数gの例として、以下の式(9)を挙げて説明した。しかし、入力値に対して正の相関を示す出力値を返却する関数gは、かかる例に限定されない。例えば、入力値に対して正の相関を示す出力値を返却する関数gの例として、以下の式(9-A)および式(9-B)なども挙げられる。 In the second embodiment of the present invention, the following formula (9) has been given as an example of function g that returns an output value that shows a positive correlation with an input value. However, function g that returns an output value that shows a positive correlation with an input value is not limited to this example. For example, the following formulas (9-A) and (9-B) are also examples of function g that returns an output value that shows a positive correlation with an input value.
10 学習装置
101 ラベル無しデータセット
102 ラベル付きデータセット
111 入力部
120 ニューラルネットワーク
121 重みパラメータ
122 推測部
131 係数生成部
132 ラベル無しデータ評価部
133 ラベル有りデータ評価部
134 更新部
REFERENCE SIGNS
Claims (11)
前記ラベル無しデータと前記ラベル有りデータとニューラルネットワークとに基づいて、前記ラベル無しデータに対応する推論結果と前記ラベル有りデータに対応する推論結果とを出力する推測部と、
前記ラベル無しデータに対応する推論結果に基づいて、前記ラベル無しデータの影響度を示す係数を算出する係数生成部と、
前記ラベル無しデータに対応する推論結果と前記係数とに基づいて、前記ラベル無しデータに対応する評価結果を出力するラベル無しデータ評価部と、
前記ラベル有りデータに対応する推論結果と前記教師ラベルとに基づいて、前記ラベル有りデータに対応する評価結果を出力するラベル有りデータ評価部と、
前記ラベル無しデータに対応する評価結果と、前記ラベル有りデータに対応する評価結果とに基づいて、前記ニューラルネットワークの重みパラメータを更新する更新部と、
を備える、情報処理装置。 An input unit that acquires unlabeled data and labeled data to which a teacher label is attached;
an inference unit that outputs an inference result corresponding to the unlabeled data and an inference result corresponding to the labeled data based on the unlabeled data, the labeled data, and a neural network;
a coefficient generation unit that calculates a coefficient indicating an influence of the unlabeled data based on an inference result corresponding to the unlabeled data;
an unlabeled data evaluation unit that outputs an evaluation result corresponding to the unlabeled data based on an inference result corresponding to the unlabeled data and the coefficients;
a labeled data evaluation unit that outputs an evaluation result corresponding to the labeled data based on an inference result corresponding to the labeled data and the teacher label;
an update unit that updates weight parameters of the neural network based on an evaluation result corresponding to the unlabeled data and an evaluation result corresponding to the labeled data;
An information processing device comprising:
前記係数生成部は、ラベル無しデータごとに推論値が最大となる第1のクラスの推論値と前記第1のクラスとは異なる1または複数のクラスの推論値とに基づく差分を算出し、前記ラベル無しデータごとに前記差分に基づいて前記係数を算出する、
請求項1に記載の情報処理装置。 the inference results corresponding to the unlabeled data include an inference value for each class;
the coefficient generation unit calculates a difference between an inferred value of a first class having a maximum inferred value for each unlabeled data and an inferred value of one or more classes different from the first class, and calculates the coefficient for each unlabeled data based on the difference;
The information processing device according to claim 1 .
請求項2に記載の情報処理装置。 the coefficient generation unit calculates, for each of the unlabeled data, a difference between an inferred value of the first class and an inferred value of a second class having a second largest inferred value;
The information processing device according to claim 2 .
請求項2に記載の情報処理装置。 the coefficient generation unit calculates, for each of the unlabeled data, a difference between the inferred value of the first class and an average value of inferred values of a plurality of classes different from the first class;
The information processing device according to claim 2 .
請求項2~4のいずれか一項に記載の情報処理装置。 the coefficient generation unit calculates, for each of the unlabeled data, a number having a positive correlation with the difference as the coefficient;
The information processing device according to any one of claims 2 to 4.
前記係数生成部は、ラベル無しデータごとに推論値に基づく予測クラスを特定し、前記予測クラスに対応するラベル無しデータの数を前記予測クラスの度数として算出し、前記ラベル無しデータごとに前記予測クラスの度数に基づいて前記係数を算出する、
請求項1に記載の情報処理装置。 the inference results corresponding to the unlabeled data include an inference value for each class;
the coefficient generation unit specifies a predicted class based on an inference value for each unlabeled data, calculates a number of unlabeled data corresponding to the predicted class as a frequency of the predicted class, and calculates the coefficient based on the frequency of the predicted class for each of the unlabeled data.
The information processing device according to claim 1 .
請求項6に記載の情報処理装置。 The coefficient generation unit identifies a class for which the inference value is maximum as a predicted class for each of the unlabeled data.
The information processing device according to claim 6 .
請求項6または7に記載の情報処理装置。 the coefficient generation unit calculates, for each of the unlabeled data, a number having a negative correlation with a frequency of the predicted class as the coefficient;
8. The information processing device according to claim 6 or 7.
請求項2~8のいずれか一項に記載の情報処理装置。 the unlabeled data evaluation unit outputs an evaluation result corresponding to the unlabeled data by multiplying a loss based on an inference result corresponding to the unlabeled data by the coefficient.
The information processing device according to any one of claims 2 to 8.
前記ラベル無しデータと前記ラベル有りデータとニューラルネットワークとに基づいて、前記ラベル無しデータに対応する推論結果と前記ラベル有りデータに対応する推論結果とを出力することと、
前記ラベル無しデータに対応する推論結果に基づいて、前記ラベル無しデータの影響度を示す係数を算出することと、
前記ラベル無しデータに対応する推論結果と前記係数とに基づいて、前記ラベル無しデータに対応する評価結果を出力することと、
前記ラベル有りデータに対応する推論結果と前記教師ラベルとに基づいて、前記ラベル有りデータに対応する評価結果を出力することと、
前記ラベル無しデータに対応する評価結果と、前記ラベル有りデータに対応する評価結果とに基づいて、前記ニューラルネットワークの重みパラメータを更新することと、
を備える、コンピュータが実行する情報処理方法。 Obtaining unlabeled data and labeled data to which a teacher label is attached;
outputting an inference result corresponding to the unlabeled data and an inference result corresponding to the labeled data based on the unlabeled data, the labeled data, and a neural network;
calculating a coefficient indicating an influence of the unlabeled data based on an inference result corresponding to the unlabeled data;
outputting an evaluation result corresponding to the unlabeled data based on the inference result corresponding to the unlabeled data and the coefficients;
outputting an evaluation result corresponding to the labeled data based on an inference result corresponding to the labeled data and the teacher label;
updating weight parameters of the neural network based on the evaluation results corresponding to the unlabeled data and the evaluation results corresponding to the labeled data;
13. A computer-implemented information processing method comprising:
ラベル無しデータを取得するとともに、教師ラベルが付されたラベル有りデータを取得する入力部と、
前記ラベル無しデータと前記ラベル有りデータとニューラルネットワークとに基づいて、前記ラベル無しデータに対応する推論結果と前記ラベル有りデータに対応する推論結果とを出力する推測部と、
前記ラベル無しデータに対応する推論結果に基づいて、前記ラベル無しデータの影響度を示す係数を算出する係数生成部と、
前記ラベル無しデータに対応する推論結果と前記係数とに基づいて、前記ラベル無しデータに対応する評価結果を出力するラベル無しデータ評価部と、
前記ラベル有りデータに対応する推論結果と前記教師ラベルとに基づいて、前記ラベル有りデータに対応する評価結果を出力するラベル有りデータ評価部と、
前記ラベル無しデータに対応する評価結果と、前記ラベル有りデータに対応する評価結果とに基づいて、前記ニューラルネットワークの重みパラメータを更新する更新部と、
を備える情報処理装置として機能させるプログラム。
Computer,
An input unit that acquires unlabeled data and labeled data to which a teacher label is attached;
an inference unit that outputs an inference result corresponding to the unlabeled data and an inference result corresponding to the labeled data based on the unlabeled data, the labeled data, and a neural network;
a coefficient generation unit that calculates a coefficient indicating an influence of the unlabeled data based on an inference result corresponding to the unlabeled data;
an unlabeled data evaluation unit that outputs an evaluation result corresponding to the unlabeled data based on an inference result corresponding to the unlabeled data and the coefficients;
a labeled data evaluation unit that outputs an evaluation result corresponding to the labeled data based on an inference result corresponding to the labeled data and the teacher label;
an update unit that updates weight parameters of the neural network based on an evaluation result corresponding to the unlabeled data and an evaluation result corresponding to the labeled data;
A program that causes the information processing device to function as an information processing device having the above-mentioned.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2021111255A JP7700542B2 (en) | 2021-07-05 | 2021-07-05 | Information processing device, information processing method, and program |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2021111255A JP7700542B2 (en) | 2021-07-05 | 2021-07-05 | Information processing device, information processing method, and program |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JP2023008028A JP2023008028A (en) | 2023-01-19 |
| JP7700542B2 true JP7700542B2 (en) | 2025-07-01 |
Family
ID=85112062
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2021111255A Active JP7700542B2 (en) | 2021-07-05 | 2021-07-05 | Information processing device, information processing method, and program |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP7700542B2 (en) |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2024232048A1 (en) * | 2023-05-10 | 2024-11-14 | 日本電気株式会社 | Model evaluation device, model evaluation method, and program |
Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2010231768A (en) | 2009-03-27 | 2010-10-14 | Mitsubishi Electric Research Laboratories Inc | How to train a multi-class classifier |
| JP2017126158A (en) | 2016-01-13 | 2017-07-20 | 日本電信電話株式会社 | Binary classification learning device, binary classification device, method, and program |
| WO2021091661A1 (en) | 2019-11-07 | 2021-05-14 | Google Llc | Deep learning system and method for diagnosis of chest conditions from chest radiographs |
-
2021
- 2021-07-05 JP JP2021111255A patent/JP7700542B2/en active Active
Patent Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2010231768A (en) | 2009-03-27 | 2010-10-14 | Mitsubishi Electric Research Laboratories Inc | How to train a multi-class classifier |
| JP2017126158A (en) | 2016-01-13 | 2017-07-20 | 日本電信電話株式会社 | Binary classification learning device, binary classification device, method, and program |
| WO2021091661A1 (en) | 2019-11-07 | 2021-05-14 | Google Llc | Deep learning system and method for diagnosis of chest conditions from chest radiographs |
Also Published As
| Publication number | Publication date |
|---|---|
| JP2023008028A (en) | 2023-01-19 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JP2012058972A (en) | Evaluation prediction device, evaluation prediction method, and program | |
| JP7732299B2 (en) | Learning device, learning method, and program | |
| JP2016523402A (en) | System and method for performing Bayesian optimization | |
| CN114424204A (en) | Data evaluation using reinforcement learning | |
| JP2020087103A (en) | Learning method, computer program, classifier, and generator | |
| CN113537630A (en) | Training method and device for business prediction model | |
| JP2019191827A (en) | Question answering device, question answering method and program | |
| WO2019215904A1 (en) | Prediction model construction device, prediction model construction method and prediction model construction program recording medium | |
| CN114072809A (en) | Small and fast video processing network via neural architectural search | |
| JP2010009517A (en) | Learning equipment, learning method and program for pattern detection device | |
| JP7544254B2 (en) | Learning device, learning method, and program | |
| CN114186097A (en) | Method and apparatus for training a model | |
| JP7700542B2 (en) | Information processing device, information processing method, and program | |
| JP2019095894A (en) | Estimating device, learning device, learned model, estimation method, learning method, and program | |
| CN112560982A (en) | CNN-LDA-based semi-supervised image label generation method | |
| CN116361657A (en) | Method, system and storage medium for disambiguating gray sample labels | |
| JP7047665B2 (en) | Learning equipment, learning methods and learning programs | |
| CN114445656A (en) | Multi-label model processing method and device, electronic equipment and storage medium | |
| JP2024120643A (en) | Information processing device, information processing method, and program | |
| JP7143906B2 (en) | Information processing device, information processing method and program | |
| TWI781000B (en) | Machine learning device and method | |
| JP5255484B2 (en) | Clustering distance learning device and program thereof, and clustering device | |
| JP2023138928A (en) | Method and device for generating neural network | |
| JP2024030579A (en) | Information processing method, information processing system, and information processing program | |
| JP2022151502A (en) | Program, information processing device and method |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20240508 |
|
| A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20250227 |
|
| A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20250311 |
|
| A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20250507 |
|
| TRDD | Decision of grant or rejection written | ||
| A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20250520 |
|
| A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20250602 |
|
| R150 | Certificate of patent or registration of utility model |
Ref document number: 7700542 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |