JP7619481B2 - Model learning device, model learning method, and model learning program - Google Patents
Model learning device, model learning method, and model learning program Download PDFInfo
- Publication number
- JP7619481B2 JP7619481B2 JP2023563387A JP2023563387A JP7619481B2 JP 7619481 B2 JP7619481 B2 JP 7619481B2 JP 2023563387 A JP2023563387 A JP 2023563387A JP 2023563387 A JP2023563387 A JP 2023563387A JP 7619481 B2 JP7619481 B2 JP 7619481B2
- Authority
- JP
- Japan
- Prior art keywords
- model
- learning
- parameters
- input data
- parameter
- 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
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N20/00—Machine learning
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Software Systems (AREA)
- Data Mining & Analysis (AREA)
- Evolutionary Computation (AREA)
- Medical Informatics (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Physics & Mathematics (AREA)
- Computing Systems (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Mathematical Physics (AREA)
- Artificial Intelligence (AREA)
- Feedback Control In General (AREA)
- Management, Administration, Business Operations System, And Electronic Commerce (AREA)
Description
本発明は、モデル学習装置、モデル学習方法、及びモデル学習プログラムに関する。 The present invention relates to a model learning device, a model learning method, and a model learning program.
多変量データから入出力関係を表すモデルを学習することは、機械学習・人工知能分野における問題の1つである。この問題において、通常の設定では、入力値とその入力から得られる出力値の組の集合が数値のデータとして与えられる。しかし、アンケート等において心理的抵抗から回答が得られない場合や、出力値が観測困難なものを対象にする場合は、数値ではなく順序関係が出力値として与えられる場合がある。Learning a model that represents input-output relationships from multivariate data is one of the problems in the fields of machine learning and artificial intelligence. In this problem, in a typical setup, a set of pairs of input values and the output values obtained from those inputs is given as numerical data. However, in cases where responses cannot be obtained from questionnaires due to psychological resistance, or when output values are difficult to observe, ordinal relationships rather than numerical values may be given as output values.
心理的抵抗から数値が得られない場合として、身体情報や私生活に関する情報の収集・分析が挙げられる。例えば、食生活と健康の関係を調べるためアンケート調査を実施する際、心理的抵抗から体重を回答してもらえない場合がある。他にも、室内の状況(温度・湿度など)から電力の消費量を予測するため、データを収集する場合がある。ここでも、在宅時間や家族構成を推測されたくないなどの心理的抵抗から実測値が提供されない場合がある。 Examples of cases where values cannot be obtained due to psychological resistance include the collection and analysis of physical information or information about personal life. For example, when conducting a questionnaire survey to investigate the relationship between diet and health, people may not provide their weight due to psychological resistance. In other cases, data may be collected to predict electricity consumption from indoor conditions (temperature, humidity, etc.). Here too, actual values may not be provided due to psychological resistance, such as not wanting people to guess how much time they spend at home or their family composition.
また、出力値が観測困難な例としては、満足度や興奮といった感情・情動が挙げられる。一般に人間の感情・情動は、真値が観測できず、評価者の主観を含むため絶対評価困難であるという課題がある。そのため、人間の感情・情動のデータは、Likert scales(非特許文献1)やSAM(self-assessment manikins)(非特許文献2)などの多段階評価によって得られることが多い。これらの評価尺度は、非線形かつ評価者のバイアスを含むため間隔尺度や比例尺度とみなすのは妥当でない。実際、ある評価者Aの情動評価値2点と評価者Bの情動評価値4点を比較して、2倍の差があると論じることや、同じ2点差であるからといって評価結果が1点と3点であった場合と同等だと解釈することは妥当でない。 Examples of output values that are difficult to observe include emotions such as satisfaction and excitement. In general, the true values of human emotions cannot be observed, and they involve the subjectivity of the evaluator, making absolute evaluation difficult. For this reason, data on human emotions is often obtained using multi-level evaluations such as Likert scales (Non-Patent Document 1) and SAM (self-assessment manikins) (Non-Patent Document 2). These evaluation scales are non-linear and include the bias of the evaluator, so it is not appropriate to consider them as interval scales or proportional scales. In fact, it is not appropriate to compare an emotion evaluation value of 2 points by a certain evaluator A with an emotion evaluation value of 4 points by evaluator B and argue that there is a two-fold difference, or to interpret the same difference of 2 points as being equivalent to an evaluation result of 1 point and 3 points.
これらの課題は、アンケートにおける設問を順序尺度にするあるいは回答を順序尺度として解釈することで軽減される。設問を順序尺度にするとは、「体重を入力してください」ではなく「体重は~kg以上ですか?」のような設問とすることを意味する。具体的数値に言及しないことで、心理的抵抗を軽減することが可能であり回答を得やすくなる。また、感情や情動などの場合においても、評価者Aの情動評価値2点と評価者Bの情動評価値4点から、「A<B」と解釈することができる。この「A<B」は回答を順序関係として扱っており、数値として扱う場合に比べ、誤った解釈が含まれる可能性を低減できる。このような設定から、具体的な数値は得られないが順序関係がラベルデータとして与えられた場合に、その順序関係から具体的な数値を予測する問題を検討する必要がある。These issues can be alleviated by making the questions in the questionnaire or interpreting the answers as an ordinal scale. Making the questions an ordinal scale means making the questions "Is your weight over __kg?" instead of "Please enter your weight." By not mentioning specific numerical values, it is possible to reduce psychological resistance and make it easier to obtain answers. Even in the case of emotions and feelings, the emotional evaluation value of evaluator A is 2 points and the emotional evaluation value of evaluator B is 4 points, so it can be interpreted as "A < B." This "A < B" treats the answers as an ordinal relationship, which reduces the possibility of misinterpretation compared to when it is treated as a numerical value. With this setting, it is necessary to consider the problem of predicting a specific numerical value from an ordinal relationship when a specific numerical value cannot be obtained but an ordinal relationship is given as label data.
順序関係からモデルパラメタを学習する手法としてランク学習がある。よく用いられるペアワイズランク学習をもとに、以下に一般的なランク学習の流れを述べる。要素数nx個の観測可能な多変量データXに対して、順序関係を示すnk個のペアの集合Dをラベルデータとして定義する。多変量データXとペアの集合Dは、以下のとおりである。 Rank learning is a method for learning model parameters from order relationships. Based on the commonly used pairwise rank learning, the general flow of rank learning is described below. For observable multivariate data X with n x elements, a set D of n k pairs indicating order relationships is defined as label data. The multivariate data X and the set D of pairs are as follows:
これは、vk>ukを示しているのではなく、入力値がvk,ukであるときの目的変数yvk,yukがyvk>yukであることを示している。そして、学習させたいモデルをfとすると、このvk,ukを入力して得られる出力値f(vk),f(uk)がf(vk)>f(uk)となるようL=exp(f(vk)-f(uk))などを最小化することで学習は実現される。つまり、ランク学習の目的は、意図したランキングを構成するためのスコア出力モデルfのパラメタ調整である。 This does not indicate that vk >u k , but indicates that when the input values are vk ,u k, the objective variables yvk , yuk are yvk > yuk . If the model to be trained is f, the learning is realized by minimizing L=exp(f(vk)-f(u k)) so that the output values f( vk ),f(u k ) obtained by inputting vk ,u k are f( vk ) >f( u k ) . In other words, the purpose of rank learning is to adjust the parameters of the score output model f to configure the intended ranking.
有名なランク学習手法としてRankNet(非特許文献3)がある。これはロジスティック関数とエントロピー損失関数を用いて、損失関数Lを以下で定義している。A well-known rank learning method is RankNet (Non-Patent Document 3). It uses a logistic function and an entropy loss function, and defines the loss function L as follows:
この損失関数は、ペアデータの順序関係を保持するとき出力が小さくなるためラベルデータの順序関係を満たすスコアの生成が可能となる。 This loss function produces smaller output when the order relationship of paired data is preserved, making it possible to generate a score that satisfies the order relationship of the label data.
また、ガウス分布を用いたランク学習手法(非特許文献4)も存在する。この手法では、損失関数Lを以下で定義している。There is also a rank learning method using Gaussian distribution (Non-Patent Document 4). In this method, the loss function L is defined as follows:
これらの手法は、順序関係からモデルパラメタを調整し、ランキングを構築可能なスコアを生成するモデルである。つまり、ラベルデータに沿ったランキングを構築することができれば、スコアの値は問わない。例えば、映画鑑賞時の情動を1から5点で評価した結果、入力vk,ukに対して、ukよりもvkの方が好ましいことが得られたとする。このラベルから学習することで、f(vk)>f(uk)を満たすとは可能であり、ラベルデータに沿ったランキングは構築可能である。しかし、f(vk),f(uk)が閉区間[1,5]に収まる保証はなく、このスコアを情動評価値としてみなすことはできない。 These methods are models that adjust model parameters from order relationships and generate scores that can be used to construct rankings. In other words, as long as a ranking can be constructed based on label data, the value of the score does not matter. For example, as a result of evaluating emotions during movie watching on a scale of 1 to 5, it is found that v k is more preferable than u k for inputs v k and u k . By learning from this label, it is possible to satisfy f(v k )>f(u k ), and a ranking based on the label data can be constructed. However, there is no guarantee that f(v k ) and f(u k ) fall within the closed interval [1, 5], and this score cannot be regarded as an emotion evaluation value.
しかし、既存のランク学習はラベルデータから順序関係を学習し、その順序関係に沿ったスコアを出力するモデルであり、その出力は目的変数を示すものではない。すなわち、既存のランク学習を用いるだけでは、順序関係のみがラベルデータとして与えられた場合に、その順序関係から具体的な目的変数を予測することは難しい。However, existing rank learning is a model that learns order relationships from label data and outputs a score according to the order relationships, and the output does not indicate the objective variable. In other words, when only the order relationships are given as label data, it is difficult to predict a specific objective variable from the order relationships using existing rank learning alone.
本発明は、上記事情に着目してなされたもので、その目的は、ラベルデータとして順序関係のみしか得られない場合でも、その順序関係から目的変数を予測するモデル学習装置、モデル学習方法、及びモデル学習プログラムを提供することにある。The present invention has been made in light of the above-mentioned circumstances, and its purpose is to provide a model learning device, a model learning method, and a model learning program that predict a dependent variable from an order relationship, even when only an order relationship is available as label data.
本発明の一態様は、モデル学習装置である。モデル学習装置は、入力データを取得する入力データ処理部と、設定パラメタを取得する設定パラメタ処理部と、前記入力データと前記設定パラメタを入力として、順序関係を保持する損失関数とモデルの出力を制限する正則化項から構成される目的関数を用いて、モデルパラメタをランク学習するモデルパラメタ学習部と、学習したモデルパラメタを出力するモデルパラメタ処理部を有する。前記入力データは、観測可能な多変量データと順序関係を示すラベルデータである。前記設定パラメタは、前記正則化項のハイパーパラメタを含む。前記モデルパラメタ学習部は、目的変数を予測するスコアを出力するモデルパラメタを得る。 One aspect of the present invention is a model learning device. The model learning device includes an input data processing unit that acquires input data, a setting parameter processing unit that acquires setting parameters, a model parameter learning unit that uses the input data and the setting parameters as inputs and rank-learns model parameters using an objective function composed of a loss function that maintains an order relationship and a regularization term that limits the output of a model, and a model parameter processing unit that outputs the learned model parameters. The input data is observable multivariate data and label data that indicates an order relationship. The setting parameters include a hyperparameter of the regularization term. The model parameter learning unit acquires model parameters that output a score that predicts a response variable.
本発明の一態様は、コンピュータが実行するモデル学習方法である。モデル学習方法は、入力データを取得することと、設定パラメタを取得することと、前記入力データと前記設定パラメタを入力として、順序関係を保持する損失関数とモデルの出力を制限する正則化項から構成される目的関数を用いて、モデルパラメタをランク学習することと、学習したモデルパラメタを出力することを有する。前記入力データは、観測可能な多変量データと順序関係を示すラベルデータである。前記設定パラメタは、前記正則化項のハイパーパラメタを含む。前記ランク学習することは、目的変数を予測するスコアを出力するモデルパラメタを得る。 One aspect of the present invention is a model learning method executed by a computer . The model learning method includes acquiring input data, acquiring setting parameters, and using the input data and the setting parameters as inputs, rank learning of model parameters using an objective function composed of a loss function that maintains an order relationship and a regularization term that limits the output of a model, and outputting the learned model parameters. The input data is observable multivariate data and label data that indicates an order relationship. The setting parameters include a hyperparameter of the regularization term. The rank learning obtains model parameters that output a score that predicts a response variable.
本発明の一態様に係るモデル学習プログラムは、上記のモデル学習装置の各構成要素の機能をコンピュータに実行させる。 A model learning program according to one aspect of the present invention causes a computer to execute the functions of each component of the above-mentioned model learning device.
本発明によれば、ラベルデータとして順序関係のみしか得られない場合でも、その順序関係から目的変数を予測するモデル学習装置、モデル学習方法、及びモデル学習プログラムが提供される。 According to the present invention, a model learning device, a model learning method, and a model learning program are provided that predict a target variable from an order relationship even when only an order relationship is obtained as label data.
以下、図面を参照して本発明に係る実施形態について説明する。 Below, an embodiment of the present invention is described with reference to the drawings.
[構成例]
まず、図1を参照して、モデル学習装置1の動作について説明する。図1は、実施形態に係るモデル学習装置1の機能構成の一例を示すブロック図である。
[Configuration example]
First, the operation of the
図1に示されるように、モデル学習装置1は、入力データ処理部10と、設定パラメタ処理部20と、モデルパラメタ学習部30と、モデルパラメタ処理部40と、記録部50と、入出力部60を有する。記録部50は、入力データ記録部51と、設定パラメタ記録部52と、モデルパラメタ記録部53を有する。1, the
入出力部60は、外部装置2との間でデータの入出力を行う。入出力部60は、外部装置2から入力データと設定パラメタを受け取る。また、入出力部60は、外部装置2にモデルパラメタを出力する。The input/
入力データ処理部10は、入出力部60を介して、外部装置2から入力データを取得する。入力データ処理部10は、取得した入力データを入力データ記録部51に出力する。The input
入力データ記録部51は、入力データを入力データ処理部10から受け取り、これを記録する。
The input
設定パラメタ処理部20は、入出力部60を介して、外部装置2から設定パラメタを取得する。設定パラメタ処理部20は、取得した設定パラメタを設定パラメタ記録部52に出力する。The setting
設定パラメタ記録部52は、設定パラメタを設定パラメタ処理部20から受け取り、これを記録する。
The setting
モデルパラメタ学習部30は、入力データ記録部51に記録されている入力データと、設定パラメタ記録部52に記録されている設定パラメタを入力として、順序関係を保持する損失関数とモデルの出力を制限する正則化項から構成される目的関数を用いて、モデルパラメタをランク学習する。モデルパラメタ学習部30は、学習したモデルパラメタをモデルパラメタ記録部53に出力する。The model
モデルパラメタ記録部53は、モデルパラメタをモデルパラメタ学習部30から受け取り、これを記録する。
The model
モデルパラメタ処理部40は、モデルパラメタ記録部53からモデルパラメタを読み込み、入出力部60を介して、これを外部装置2に出力する。
The model
入力データ処理部10が取得する入力データは、観測可能な多変量データと、順序関係を示すラベルデータである。例えば、ラベルデータは、順序関係を示すペアの集合である。The input data acquired by the input
設定パラメタ処理部20が取得する設定パラメタは、モデルパラメタ学習部30がランク学習に用いる目的関数の正則化項のハイパーパラメタを含む。ハイパーパラメタは、目的変数の分位数を含む。ここで、分位数とは、ソート済みの数の集合を正の整数で等分する位置に存在する数である。ハイパーパラメタはまた、正則化項の重みを決定するパラメタを含む。設定パラメタはまた、目的関数の最適化に用いる学習率パラメタを含む。
The setting parameters acquired by the setting
次に、モデル学習装置1のハードウェア構成について説明する。モデル学習装置1は、コンピュータで構成される。例えば、モデル学習装置1は、パーソナルコンピュータやサーバコンピュータ等で構成される。Next, we will explain the hardware configuration of the
図2は、実施形態に係るモデル学習装置1のハードウェア構成の一例を示すブロック図である。図2に示されるように、モデル学習装置1は、入出力インタフェース110と、CPU120と、記憶装置130を有する。
Figure 2 is a block diagram showing an example of a hardware configuration of the
入出力インタフェース110とCPU120と記憶装置130は、バス140を介して互いに電気的に接続されており、バス140を介してデータや命令のやりとりを行う。The input/
入出力インタフェース110は、信号ケーブルまたはネットワークを介して、外部装置2と接続される。入出力インタフェース110は、外部装置2からデータを受け取ったり、モデルパラメタを外部装置2に出力したりするために使用される。The input/
記憶装置130は、CPU120が実行する処理に必要なプログラムとデータを記憶している。CPU120は、記憶装置130から必要なプログラムとデータを読み出して実行することにより、各種の処理を行う。The
記憶装置130は、主記憶装置131と、補助記憶装置132を有する。主記憶装置131と補助記憶装置132は、相互間でプログラムとデータのやりとりを行う。The
主記憶装置131は、CPU120の処理に一時的に必要なプログラムとデータを記憶する。例えば、主記憶装置131は、RAM(Random Access Memory)等の揮発性メモリで構成される。The
補助記憶装置132は、外部機器やネットワークを介して供給されるプログラムやデータを記憶しており、CPU120の処理に一時的に必要なプログラムとデータを主記憶装置131に提供する。例えば、補助記憶装置132は、HDD(Hard Disk Drive)やSSD(Solid State Drive)等の不揮発性メモリで構成される。The
CPU120は、プロセッサであり、データや命令を処理するハードウェアである。CPU120は、制御装置121と、演算装置122を有する。The
制御装置121は、入出力インタフェース110と演算装置122と記憶装置130を制御する。
The
演算装置122は、主記憶装置131からプログラムとデータを読み込み、プログラムを実行してデータを処理し、処理したデータを主記憶装置131に提供する。The
このようなハードウェア構成において、入出力インタフェース110は、入出力部60を構成する。CPU120と主記憶装置131は、入力データ処理部10と設定パラメタ処理部20とモデルパラメタ学習部30とモデルパラメタ処理部40を構成する。記憶装置130(例えば補助記憶装置132)は、記録部50を構成する。In such a hardware configuration, the input/
[動作例]
次に、モデル学習装置1の動作について説明する。モデル学習装置1が実行するランク学習は、ランク学習における出力値の分布を分位数にもとづく正則化項により制限する手法である。モデルの出力を目的変数に近づけるためには、モデルの出力分布を目的変数の分布へ近似させる必要がある。しかし、ラベルデータとして順序関係のみしか得られない場合では、具体的な数値が得られないため目的変数の分布も得られない。
[Example of operation]
Next, the operation of the
そこで、分布全体を近似させるのではなく、目的変数の分位数をハイパーパラメタとして与え、分位数で定める複数点のみを近似させる。分位数とは、あるソート済みの数の集合X={x1,x2,…,xn|x1≦x2≦…≦xn}に対し、分布を任意の正の整数mでm等分する位置に存在するm-1個の数{xi1,xi2,…,xim-1}のことであり、xilを第lm分位数と呼ぶ。
Therefore, instead of approximating the entire distribution, the quantiles of the objective variable are given as hyperparameters, and only a number of points determined by the quantiles are approximated. A quantile is m-1 numbers {
目的変数のm分位数αをハイパーパラメタとして与えたとき、モデルの出力値のm分位数βとの誤差を最小化することでモデルの出力に制限を加える。または、目的変数のm分位数αとモデルの出力値のm分位数βを用いて計算される項を含む目的関数を最小化することでモデルの出力に制限を加える。 When the m-quantile α of the objective variable is given as a hyperparameter, the model output is restricted by minimizing the error between the m-quantile β of the model output value. Alternatively, the model output is restricted by minimizing an objective function that includes a term calculated using the m-quantile α of the objective variable and the m-quantile β of the model output value.
(入力データ)
入力データ処理部10が取得する入力データは、観測可能な多変量データと順序関係を示すラベルデータである。例えば、多変量データは、要素数nx個の観測可能な多変量データXであり、ラベルデータは、順序関係を示すnk個のペアの集合Dである。以下では、ペアの集合DをペアラベルデータDとも称する。多変量データXとペアラベルデータDは、以下のように表される。
(Input data)
The input data acquired by the input
(モデル)
モデルパラメタ学習部30が実行するランク学習に用いられるモデルfは、ランク学習においてランキングの構築指標となるスコアを出力する任意のモデルが利用可能である。入力モデルfは、線形モデルやロジスティック関数・シグモイド関数を用いた一般化線形モデルであってもよいし、ガウス過程モデルや深層学習モデルなどの非線形なモデルであってもよい。また、Xが多変量時系列データである場合には、ある時刻tに対し潜在変数zt-1とxtからztを得る関数と、ztから目的変数ytを推定する基本的な時系列モデルや、LSTMのようなRNNアーキテクチャとしてもよい。多変量データXが画像の集合である場合に対し次式で表現されるCNN構造を持つモデルを用いることも想定している。
(Model)
The model f used in the rank learning performed by the model
(出力)
モデル学習装置1の出力は、モデルパラメタθの推定結果である。モデルパラメタθの推定結果は、目的変数に近いスコアである。
(output)
The output of the
(目的関数)
次に、ランク学習における目的関数について説明する。目的関数は、順序関係を保持する損失関数Eとモデルの出力を制限する正則化項Ωから構成される。これを踏まえ、目的関数Lを以下で表現する。
(Objective function)
Next, the objective function in rank learning will be explained. The objective function is composed of a loss function E that maintains the order relationship and a regularization term Ω that limits the model output. Based on this, the objective function L is expressed as follows.
ここで、λは正則化項の重みを決定するハイパーパラメタであり、αは目的変数のm分位数を示すハイパーパラメタである。 Here, λ is a hyperparameter that determines the weight of the regularization term, and α is a hyperparameter that indicates the m-quantile of the objective variable.
(正則化)
目的関数の主題は正則化であるため、まず正則化項Ωについて述べる。2つの分布の分位数を近似するようなΩについては様々な定義が可能であり、ここでは下記Ω1,Ω2を定義する。
(Regularization)
Since the subject of the objective function is regularization, we will first discuss the regularization term Ω. There are various possible definitions for Ω that approximates the quantiles of two distributions, and here we define Ω 1 and Ω 2 as follows.
まず、Ω1について述べる。目的変数の累積分布関数をΦ(x)、モデル出力の累積分布関数をΨ(x)とすると、両分布が類似するほど小さな値を取る正則化項として2つの累積分布関数のL1距離が定義できる。 First, let us consider Ω1 . If the cumulative distribution function of the objective variable is Φ(x) and the cumulative distribution function of the model output is Ψ(x), the L1 distance between the two cumulative distribution functions can be defined as a regularization term that takes a smaller value as the two distributions become more similar.
この式においてΦ(a)は、目的変数の具体的数値が得られないため、同様に具体的数値が得られない。そこで、目的変数のm分位数α={α1,…,αm-1}が与えられると仮定し、前式の左辺をaに関して離散化した次式を最小化する。 In this equation, since the specific value of the objective variable cannot be obtained, a specific value cannot be obtained for Φ(a). Therefore, assuming that the m-quantile α={α 1 , ..., α m-1 } of the objective variable is given, the following equation, which is obtained by discretizing the left side of the previous equation with respect to a, is minimized.
ここで、昇順ソート済みのモデル出力をyとし、yのうちαlより小さい要素の部分集合をyαlとすると、Ψ(αl)は以下で算出できる。 Here, if the model output sorted in ascending order is y, and a subset of elements of y that are smaller than α l is y α l , then Ψ(α l ) can be calculated as follows.
ただし、式(7)にて用いられるnは要素数の数え上げ処理であり、これは手続き的であるため一般に誤差逆伝播ができない。そこで、モデル出力yのうち第l+1分位に属する(1/m)個の要素が、αlからαl+1の範囲に含まれるよう正則化項Ω2を定めることでΨ(αl)→l/mを実現し、近似的にΩ1を最小化する。Ω2を式(8)に示す。 However, n used in formula (7) is a counting process of the number of elements, which is procedural and generally cannot be used for backpropagation of errors. Therefore, by determining the regularization term Ω2 so that the (1/m) elements belonging to the l+1th quantile of the model output y are included in the range from αl to αl+1 , Ψ( αl )→l/m is realized and Ω1 is approximately minimized. Ω2 is shown in formula (8).
ここで、bはバッチサイズ(=n(y))であり、α0,αmは目的変数の上限と下限を示す任意の値である。この正則化項Ω2は、yの第lm分位数をβlとしたとき、2つの分位数(βl,βl+1)に挟まれる要素yiに対し、yiが区間[αl,αl+1]に属する場合には値が0になり、yiがαlより小さい場合はαlとの差、yiがαl+1より大きい場合はαl+1との差を出力する。これは、yの分位数で定める区間[βl,βl+1]に属するyの要素が、目的変数の分位数で定める区間[αl,αl+1]に収まるほど損失が小さくなることを意味する。よって、yの要素が分位数αで定める各区間に等分されるときΩ2=0となる。つまり、bが十分に大きくΩ2→0のときn(yαl)→(l/m)bであるため、式(5)と式(7)に代入することで同様にΩ→0となる。よって、Ω2を最小化することでΩ1の最小化が実現される。 Here, b is the batch size (=n(y)), and α 0 , α m are arbitrary values indicating the upper and lower limits of the objective variable. When the lmth quantile of y is β l , this regularization term Ω 2 has a value of 0 for an element y i sandwiched between two quantiles (β l , β l+1 ) if y i belongs to the interval [α l , α l+1 ], and outputs the difference between α l when y i is smaller than α l , and the difference between α l+1 when y i is larger than α l+1 . This means that the loss becomes smaller as the elements of y that belong to the interval [β l , β l+1 ] defined by the quantile of y fall within the interval [α l , α l+1 ] defined by the quantile of the objective variable. Therefore, Ω 2 =0 when the elements of y are equally divided into each interval defined by the quantile α. In other words, when b is sufficiently large and Ω2 →0, n( yαl )→(l/m)b, so by substituting into equations (5) and (7), Ω→0 in the same way. Therefore, minimizing Ω2 realizes the minimization of Ω1 .
次に、式(8)の最小化アルゴリズムについて述べる。まず、モデル出力yの第l+1分位に属する要素に対して、目的変数の第(l+1)m分位数を格納したベクトルcと目的変数の第lm分位数を格納したベクトルdを以下で定義する。Next, we will describe the minimization algorithm of equation (8). First, for elements belonging to the l+1th quantile of the model output y, we define vector c storing the (l+1)mth quantile of the objective variable and vector d storing the lmth quantile of the objective variable as follows:
このu,lを用いて計算処理上の正則化項は次式となる。 Using these u and l, the regularization term for the computational process is given by the following equation.
この正則化項において、ハイパーパラメタαは任意の値を設定可能であり、学習時に入力されるバッチの性質に合わせて可変である。これは、ある学習データセットをX1,X2,…,Xnと異なる性質を持つミニバッチに分割して学習する際、ミニバッチX1にはハイパーパラメタα、ミニバッチX2にはハイパーパラメタβというように、ミニバッチレベルで可変であることを示している。例えば、食生活から個人の体重を予測するというタスクにおいては、入力バッチが男性である場合と女性である場合に分けてハイパーパラメタを設定することが可能である。また、スポーツ観戦中に人間の情動を予測するタスクにおいては、盛り上がる時間帯とそうでない時間帯に分けてハイパーパラメタを設定することが可能である。 In this regularization term, the hyperparameter α can be set to any value and is variable according to the properties of the batch input during learning. This indicates that when a certain learning data set is divided into mini-batches with different properties such as X 1 , X 2 , ..., X n for learning, the hyperparameter α is set for the mini-batch X 1 and the hyperparameter β is set for the mini-batch X 2 , and the hyperparameter is variable at the mini-batch level. For example, in a task of predicting an individual's weight from their diet, it is possible to set the hyperparameter separately for the case where the input batch is male and the case where the input batch is female. In addition, in a task of predicting human emotions while watching sports, it is possible to set the hyperparameter separately for the time period when the excitement is high and the time period when it is not.
損失関数Eについては、ペアデータの順序関係を保持するとき出力が小さくなる任意の関数が利用できる。例えば、RankNet(非特許文献3)と同様に式(1)としてもよい。また、ガウス分布を用いたランク学習手法(非特許文献4)と同様に式(2)としてもよい。 The loss function E can be any function that reduces the output when maintaining the order of paired data. For example, it can be equation (1) as in RankNet (Non-Patent Document 3). It can also be equation (2) as in the rank learning method using Gaussian distribution (Non-Patent Document 4).
(最適化法)
目的関数の最適化には、勾配法や確率的勾配法、Adamなど任意の最適化手法が適用できる。勾配法を利用する場合は、k回目の最適化ステップで下記の式にしたがいパラメタを更新することを繰り返せばよい。
(Optimization Method)
Any optimization method such as the gradient method, the stochastic gradient method, Adam, etc. can be applied to optimize the objective function. When using the gradient method, it is sufficient to repeatedly update the parameters according to the following formula in the k-th optimization step.
ここで、γkは学習率パラメタである。目的関数の勾配∇θL(θ)は、計算して導出した関数を用いてもよいし、数値的に計算してもよい。 Here, γ k is a learning rate parameter. The gradient of the objective function ∇ θ L (θ) may be a calculated and derived function or may be calculated numerically.
(モデルパラメタの推定)
次に、図3を参照して、モデル学習装置1が実行するモデルパラメタの推定の処理手順と処理内容について説明する。図3は、モデル学習装置1が実行するモデルパラメタの推定の処理手順と処理内容を示すフローチャート図である。
(Model parameter estimation)
Next, the procedure and contents of the model parameter estimation process executed by the
ステップS1において、入力データ処理部10は、入力データを取得する。入力データは、前述した多変量データXとペアラベルデータDである。入力データ処理部10はまた、取得した入力データを入力データ記録部51に格納する。In step S1, the input
ステップS2において、設定パラメタ処理部20は、設定パラメタを取得する。設定パラメタは、目的関数の正則化項のハイパーパラメタを含む。ハイパーパラメタは、目的変数のm分位数αと、正則化項の重みを決定するパラメタλを含む。設定パラメタはまた、目的関数の最適化に用いる学習率パラメタγkを含む。設定パラメタ処理部20はまた、取得した設定パラメタを設定パラメタ記録部52に格納する。
In step S2, the setting
ステップS3において、モデルパラメタ学習部30は、入力データ記録部51に記録されている入力データと、設定パラメタ記録部52に記録されている設定パラメタを入力として、損失関数と正則化項を有する目的関数を用いて、モデルパラメタをランク学習する。モデルパラメタ学習部30はまた、学習したモデルパラメタをモデルパラメタ記録部53に格納する。In step S3, the model
ステップS4において、モデルパラメタ処理部40は、モデルパラメタ記録部53からモデルパラメタを読み込み、これを外部装置2に出力する。
In step S4, the model
(ランク学習)
次に、図4を参照して、モデルパラメタ学習部30が実行するモデルパラメタのランク学習の処理手順と処理内容について説明する。図4は、モデルパラメタ学習部30が実行するモデルパラメタのランク学習の処理手順と処理内容の一例を示すフローチャート図である。
(Rank learning)
Next, the process procedure and process contents of the model parameter rank learning executed by the model
ステップS11において、モデルパラメタθを初期化する。 In step S11, the model parameter θ is initialized.
ステップS12において、ランク学習の最大繰り返し回数を設定する。また、ランク学習の計算繰り返し回数を初期化する。すなわち、計算繰り返し回数を0にする。In step S12, the maximum number of iterations of rank learning is set. Also, the number of calculation iterations of rank learning is initialized. That is, the number of calculation iterations is set to 0.
ステップS13において、モデルパラメタθを式(3)と式(10)に従い更新する。 In step S13, the model parameter θ is updated according to equations (3) and (10).
ステップS14において、計算繰り返し回数を更新する。すなわち、計算繰り返し回数を1増やす。In step S14, the number of calculation iterations is updated. That is, the number of calculation iterations is incremented by 1.
ステップS15において、計算繰り返し回数が最大繰り返し回数を超えたか否かを判断する。計算繰り返し回数が最大繰り返し回数を超えていない場合には、ステップS13の処理に戻る。計算繰り返し回数が最大繰り返し回数を超えた場合には、モデルパラメタの学習を終了し、図3のステップS4の処理に戻る。In step S15, it is determined whether the number of calculation iterations has exceeded the maximum number of iterations. If the number of calculation iterations has not exceeded the maximum number of iterations, the process returns to step S13. If the number of calculation iterations has exceeded the maximum number of iterations, the learning of the model parameters is terminated, and the process returns to step S4 in FIG. 3.
[効果]
実施形態によれば、ラベルデータとして順序関係のみしか得られない場合でも、その順序関係から目的変数を予測することが可能となる。これにより、任意のランク学習モデルをランキング生成モデルとしてだけではなく、目的変数の分布に近似した数値を出力する回帰モデルとして学習することが可能となる。これにより、心理的抵抗から具体的な数値でアンケート回答が得られない場合や情動など絶対評価が難しい目的変数に対し、順序関係だけでなく数値として推定値を得ることが可能になる。
[effect]
According to the embodiment, even if only an order relationship is obtained as label data, it is possible to predict the objective variable from the order relationship. This makes it possible to learn an arbitrary rank learning model not only as a ranking generation model but also as a regression model that outputs a numerical value that approximates the distribution of the objective variable. This makes it possible to obtain not only an order relationship but also an estimated value as a numerical value for objective variables that are difficult to evaluate absolutely, such as emotions, when a survey response cannot be given in a specific numerical value due to psychological resistance.
上記実施形態では、最適化の際に勾配法を用いる例を示しているが、確率的勾配法やAdamなど任意の手法が利用できる。同様に目的関数(式3)におけるEにも任意の損失関数が利用できる。上記の実施の形態の図1に示すモデル学習装置1は、各構成要素の動作をプログラムとして構築し、モデル学習装置として利用されるコンピュータにインストールして実行させる、またはネットワークを介して流通させることが可能である。本発明は上記実施形態に限定されることなく、種々変更・応用が可能である。
In the above embodiment, an example is shown in which a gradient method is used during optimization, but any method such as a stochastic gradient method or Adam can be used. Similarly, any loss function can be used for E in the objective function (Equation 3). In the
例えば、上記実施形態は、本発明をペアワイズランク学習法に適用した例であるが、本発明は、これに限らず、他のランク学習法、例えば、ポイントワイズランク学習法やリストワイズランク学習法に適用されてもよい。For example, the above embodiment is an example of applying the present invention to a pairwise rank learning method, but the present invention is not limited to this and may be applied to other rank learning methods, such as a pointwise rank learning method or a listwise rank learning method.
なお、本発明は、上記実施形態に限定されるものではなく、実施段階ではその要旨を逸脱しない範囲で種々に変形することが可能である。また、各実施形態は適宜組み合わせて実施してもよく、その場合組み合わせた効果が得られる。更に、上記実施形態には種々の発明が含まれており、開示される複数の構成要件から選択された組み合わせにより種々の発明が抽出され得る。例えば、実施形態に示される全構成要件からいくつかの構成要件が削除されても、課題が解決でき、効果が得られる場合には、この構成要件が削除された構成が発明として抽出され得る。 Note that the present invention is not limited to the above-described embodiments, and can be modified in various ways in the implementation stage without departing from the gist of the invention. The embodiments may also be implemented in appropriate combination, in which case the combined effects can be obtained. Furthermore, the above-described embodiments include various inventions, and various inventions can be extracted by combinations selected from the multiple constituent elements disclosed. For example, if the problem can be solved and an effect can be obtained even if some constituent elements are deleted from all the constituent elements shown in the embodiments, the configuration from which these constituent elements are deleted can be extracted as an invention.
1…モデル学習装置
2…外部装置
10…入力データ処理部
20…設定パラメタ処理部
30…モデルパラメタ学習部
40…モデルパラメタ処理部
50…記録部
51…データ記録部
52…設定パラメタ記録部
53…モデルパラメタ記録部
60…入出力部
110…入出力インタフェース
120…CPU
121…制御装置
122…演算装置
130…記憶装置
131…主記憶装置
132…補助記憶装置
140…バス
REFERENCE SIGNS
121: control device 122: arithmetic unit 130: storage device 131: main storage device 132: auxiliary storage device 140: bus
Claims (8)
設定パラメタを取得する設定パラメタ処理部と、
前記入力データと前記設定パラメタを入力として、順序関係を保持する損失関数とモデルの出力を制限する正則化項から構成される目的関数を用いて、モデルパラメタをランク学習するモデルパラメタ学習部と、
学習したモデルパラメタを出力するモデルパラメタ処理部を有し、
前記入力データは、観測可能な多変量データと順序関係を示すラベルデータであり、
前記設定パラメタは、前記正則化項のハイパーパラメタを含み、
前記モデルパラメタ学習部は、目的変数を予測するスコアを出力するモデルパラメタを得る、
モデル学習装置。 An input data processing unit for acquiring input data;
a configuration parameter processing unit that acquires configuration parameters;
a model parameter learning unit that uses the input data and the setting parameters as inputs, and rank-learns model parameters using an objective function that is composed of a loss function that maintains an order relationship and a regularization term that limits an output of a model;
A model parameter processing unit that outputs learned model parameters;
The input data is observable multivariate data and label data indicating an order relationship;
The setting parameters include hyperparameters of the regularization terms,
The model parameter learning unit obtains model parameters that output a score for predicting a dependent variable.
Model learning device.
前記モデルパラメタ学習部は、モデルの出力値の分位数を前記目的変数の前記分位数と近似させる、
請求項1に記載のモデル学習装置。 The hyperparameter includes a quantile of the objective variable, where the quantile is a number that exists at a position where a set of sorted numbers is equally divided by positive integers;
the model parameter learning unit approximates a quantile of an output value of a model to the quantile of the response variable;
The model learning device according to claim 1 .
請求項2に記載のモデル学習装置。 The model parameter learning unit minimizes an objective function including a term calculated using the quantiles of the objective variable and the quantiles of the output value of the model.
The model learning device according to claim 2 .
請求項2または3に記載のモデル学習装置。 The hyperparameters further include a parameter that determines a weight of the regularization term.
The model learning device according to claim 2 or 3.
請求項1から4までのいずれかひとつに記載のモデル学習装置。 The model parameter learning unit optimizes the objective function using a gradient method, a stochastic gradient method, or Adam.
5. The model learning device according to claim 1.
請求項5に記載のモデル学習装置。 The setting parameters further include a learning rate parameter used in optimizing the objective function.
The model learning device according to claim 5 .
設定パラメタを取得することと、
前記入力データと前記設定パラメタを入力として、順序関係を保持する損失関数とモデルの出力を制限する正則化項から構成される目的関数を用いて、モデルパラメタをランク学習することと、
学習したモデルパラメタを出力することを有し、
前記入力データは、観測可能な多変量データと順序関係を示すラベルデータであり、
前記設定パラメタは、前記正則化項のハイパーパラメタを含み、
前記ランク学習することは、目的変数を予測するスコアを出力するモデルパラメタを得る、
コンピュータが実行するモデル学習方法。 Obtaining input data;
Obtaining configuration parameters;
rank-learning model parameters using an objective function including a loss function for maintaining an order relationship and a regularization term for limiting an output of a model, with the input data and the setting parameters as inputs;
Outputting the learned model parameters;
The input data is observable multivariate data and label data indicating an order relationship;
The setting parameters include hyperparameters of the regularization terms,
The rank learning obtains model parameters that output scores predicting the dependent variable.
A computer implemented method for learning models.
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| PCT/JP2021/043009 WO2023095211A1 (en) | 2021-11-24 | 2021-11-24 | Model learning device, model learning method, and model learning program |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JPWO2023095211A1 JPWO2023095211A1 (en) | 2023-06-01 |
| JP7619481B2 true JP7619481B2 (en) | 2025-01-22 |
Family
ID=86539074
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2023563387A Active JP7619481B2 (en) | 2021-11-24 | 2021-11-24 | Model learning device, model learning method, and model learning program |
Country Status (2)
| Country | Link |
|---|---|
| JP (1) | JP7619481B2 (en) |
| WO (1) | WO2023095211A1 (en) |
Citations (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2019125319A (en) | 2018-01-19 | 2019-07-25 | 富士通株式会社 | Learning program, learning method and learning device |
-
2021
- 2021-11-24 JP JP2023563387A patent/JP7619481B2/en active Active
- 2021-11-24 WO PCT/JP2021/043009 patent/WO2023095211A1/en not_active Ceased
Patent Citations (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2019125319A (en) | 2018-01-19 | 2019-07-25 | 富士通株式会社 | Learning program, learning method and learning device |
Non-Patent Citations (3)
| Title |
|---|
| GENG, Bo ほか,Ranking model adaptation for domain-specific search,IEEE Transactions on Knowledge and Data Engineering [online],IEEE,2012年04月,Vol.24, No.4,pp.745-758,[検索日 2022.01.28], インターネット:<URL:https://ieeexplore.ieee.org/document/5677513?arnumber=5677513>,<DOI: 10.1109/TKDE.2010.252>, Print ISSN: 1041-4347, Electronic ISSN: 1558-2191 |
| 永原聡士,機械学習を用いた生産現場における着工順序ルールのモデリング,日本機械学会論文集 [online],一般社団法人日本機械学会,2021年05月12日,[検索日 2022.01.28], インターネット:<URL:https://www.jstage.jst.go.jp/article/transjsme/advpub/0/advpub_20-00396/_article/-char/ja/>,<DOI: 10.1299/transjsme.20-00396>, Online ISSN: 2187-9761, ISSN-L: 2187-9761 |
| 門田健明 ほか,簡易な相対アノテーションに基づく潰瘍性大腸炎の重症度分類,電子情報通信学会技術研究報告[online],日本,一般社団法人電子情報通信学会,2020年10月02日,Vol.120, No.187,pp.1-5(PRMU2020-18),ISSN: 2432-6380 |
Also Published As
| Publication number | Publication date |
|---|---|
| WO2023095211A1 (en) | 2023-06-01 |
| JPWO2023095211A1 (en) | 2023-06-01 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| Dimakopoulou et al. | Balanced linear contextual bandits | |
| Radev et al. | Amortized bayesian model comparison with evidential deep learning | |
| Dangeti | Statistics for machine learning | |
| Ajiboye et al. | Evaluating the effect of dataset size on predictive model using supervised learning technique | |
| Egrioglu et al. | Recurrent multiplicative neuron model artificial neural network for non-linear time series forecasting | |
| Rashid et al. | A multi hidden recurrent neural network with a modified grey wolf optimizer | |
| Radev et al. | Towards end‐to‐end likelihood‐free inference with convolutional neural networks | |
| Pape et al. | Evaluating case-based decision theory: Predicting empirical patterns of human classification learning | |
| Gao et al. | Modeling the effort and learning ability of students in MOOCs | |
| Contardo et al. | Sequential cost-sensitive feature acquisition | |
| Chen et al. | Beyond the Cox hazard ratio: a targeted learning approach to survival analysis in a cardiovascular outcome trial application | |
| Garcia | Modeling systems with machine learning based differential equations | |
| Chen et al. | Model transferability with responsive decision subjects | |
| JP2020190959A (en) | Model generation device, system, parameter computation device, model generation method, parameter computation method, and program | |
| Lin et al. | Scalable Gaussian processes with latent Kronecker structure | |
| JP7279810B2 (en) | LEARNING DEVICE, CLASSIFIER, LEARNING METHOD, CLASSIFICATION METHOD, AND PROGRAM | |
| Pan et al. | Latent variable sequence identification for cognitive models with neural network estimators | |
| JP7619481B2 (en) | Model learning device, model learning method, and model learning program | |
| Bhatnagar et al. | ANALYSIS OF FACULTY PERFORMANCE EVALUATION USING CLASSIFICATION. | |
| Mustapha et al. | Introduction to machine learning and artificial intelligence | |
| Xu et al. | Continuous-action reinforcement learning with fast policy search and adaptive basis function selection | |
| Akgül et al. | Deterministic uncertainty propagation for improved model-based offline reinforcement learning | |
| Dantas et al. | The impact of state representation on approximate Q-learning for a selection hyper-heuristic | |
| Alhendawi | Predicting the effectiveness of web information systems using neural networks modeling: framework & empirical testing | |
| Karlsson et al. | Qini curve estimation under clustered network interference |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20240311 |
|
| A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20241022 |
|
| A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20241114 |
|
| 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: 20241210 |
|
| A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20241223 |
|
| R150 | Certificate of patent or registration of utility model |
Ref document number: 7619481 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
| S533 | Written request for registration of change of name |
Free format text: JAPANESE INTERMEDIATE CODE: R313533 |
|
| R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |