JP5255484B2 - Clustering distance learning device and program thereof, and clustering device - Google Patents
Clustering distance learning device and program thereof, and clustering device Download PDFInfo
- Publication number
- JP5255484B2 JP5255484B2 JP2009045015A JP2009045015A JP5255484B2 JP 5255484 B2 JP5255484 B2 JP 5255484B2 JP 2009045015 A JP2009045015 A JP 2009045015A JP 2009045015 A JP2009045015 A JP 2009045015A JP 5255484 B2 JP5255484 B2 JP 5255484B2
- Authority
- JP
- Japan
- Prior art keywords
- cluster
- data
- learning
- clustering
- distance
- 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.)
- Expired - Fee Related
Links
Images
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Description
本発明は、クラスタリングを行う際に類似度として用いるデータ間の距離のパラメータを学習するクラスタリング距離学習装置およびそのプログラム、ならびに、それを用いたクラスタリング装置に関する。 The present invention relates to a clustering distance learning device that learns a parameter of a distance between data used as a similarity when performing clustering, a program thereof, and a clustering device using the same.
従来、画像処理、言語処理等において、分類範疇が未知の複数のデータを、類似した同一のクラスタに分類するクラスタリングの手法が知られている(例えば、特許文献1参照)。このようなクラスタリングの手法においては、データが類似しているか否かの判定に、類似度としてデータ間の距離を用いている。この距離としては、ユークリッド距離やコサイン距離を用い、距離尺度を固定にするのが一般的である。 2. Description of the Related Art Conventionally, a clustering technique for classifying a plurality of pieces of data with unknown classification categories into similar identical clusters in image processing, language processing, and the like (see, for example, Patent Document 1). In such a clustering technique, the distance between data is used as the similarity in determining whether or not the data are similar. As this distance, Euclidean distance or cosine distance is generally used, and the distance scale is generally fixed.
また、従来のクラスタリングは、教師データを用いずに分類を行う教師なし手法が確立されていたが、近年、教師あり手法が用いられ、半教師ありクラスタリングとして研究がなされている(非特許文献1参照)。この半教師ありクラスタリングとは、クラスタリング対象のデータのいくつかに、予めクラスタに関する情報を与えることで、事前にクラスタリングに関する学習を行い、その学習結果に応じて他のクラスタリング対象のデータをクラスタリングするものである。この学習においては、よりよいクラスタリング性能を得るために、距離尺度を学習データに応じて設定することが望ましい。
そのため、従来、この学習において、距離としてマハラノビス距離を用い、距離尺度、すなわち、マハラノビス距離のパラメータを反復解法により推定する手法が提案されている(非特許文献2参照)。
In addition, in the conventional clustering, an unsupervised method for performing classification without using teacher data has been established, but recently, a supervised method is used, and research is being conducted as semi-supervised clustering (Non-patent Document 1). reference). This semi-supervised clustering is a method in which information related to the cluster is given to some of the data to be clustered in advance to perform learning related to clustering in advance, and other data to be clustered is clustered according to the learning result. It is. In this learning, in order to obtain better clustering performance, it is desirable to set the distance measure according to the learning data.
Therefore, conventionally, in this learning, a method has been proposed in which the Mahalanobis distance is used as a distance and a distance scale, that is, a parameter of the Mahalanobis distance is estimated by an iterative solution (see Non-Patent Document 2).
従来のユークリッド距離やコサイン距離を用い、距離尺度を固定にしてクラスタリングを行う手法では、学習データに応じて調整するパラメータが存在しない。そのため、従来の手法では、クラスタリング対象のデータに応じた(例えば、データ分散の特性等に応じた)最適なクラスタリングを行うことができないという問題がある。
また、従来のマハラノビス距離を用い、学習データにより、予めマハラノビス距離のパラメータを推定する手法では、その推定を行う際に反復演算を行っている。そのため、従来の手法では、マハラノビス距離のパラメータ推定に時間がかかってしまうという問題がある。
In the conventional method of performing clustering with the distance scale fixed using the Euclidean distance or the cosine distance, there is no parameter to be adjusted according to the learning data. Therefore, the conventional method has a problem that optimal clustering according to data to be clustered (for example, according to data distribution characteristics) cannot be performed.
Moreover, in the method of estimating the parameter of Mahalanobis distance beforehand from learning data using the conventional Mahalanobis distance, iterative calculation is performed when performing the estimation. Therefore, the conventional method has a problem that it takes time to estimate the parameter of the Mahalanobis distance.
本発明は、以上のような問題点に鑑みてなされたものであり、半教師ありクラスタリングに用いるマハラノビス距離のパラメータを、学習データから反復演算を行わずに推定することが可能なクラスタリング距離学習装置およびそのプログラム、ならびに、クラスタリング装置を提供することを目的とする。 The present invention has been made in view of the above problems, and is a clustering distance learning device capable of estimating Mahalanobis distance parameters used for semi-supervised clustering from learning data without performing iterative operations. It is an object to provide a program and a clustering apparatus thereof.
本発明は、前記目的を達成するために創案されたものであり、まず、請求項1に記載のクラスタリング距離学習装置は、データの特徴量の類似度である距離により複数のデータをクラスタリングする際に用いるマハラノビス距離のパラメータを学習するクラスタリング距離学習装置であって、クラスタ中心記憶手段と、学習データ入力手段と、パラメータ演算手段と、を備える構成とした。 The present invention was devised to achieve the above object. First, the clustering distance learning device according to claim 1 performs clustering of a plurality of data based on a distance that is a similarity of data feature amounts. A clustering distance learning device that learns the Mahalanobis distance parameters used in the above configuration, and includes a cluster center storage unit, a learning data input unit, and a parameter calculation unit.
かかる構成において、クラスタリング距離学習装置は、クラスタ中心記憶手段に、クラスタごとに、データの特徴量空間におけるクラスタ中心の値を記憶する。このクラスタ中心は、データをクラスタリングする際のクラスタごとの特徴量空間における座標値である。また、特徴量空間とは、データの1つ以上の特徴量をベクトルとした座標空間である。ここで、データの特徴量とは、各データを分類するための指標となるものであって、例えば、言語処理の場合、音声データを分析することで抽出したケプストラム係数、文書データを形態素解析することで抽出した形態素の出現頻度等である。 In this configuration, the clustering distance learning device stores the cluster center value in the data feature amount space for each cluster in the cluster center storage unit. The cluster center is a coordinate value in the feature amount space for each cluster when data is clustered. The feature amount space is a coordinate space using one or more feature amounts of data as vectors. Here, the feature amount of data is an index for classifying each data. For example, in the case of language processing, cepstrum coefficients extracted by analyzing speech data and morphological analysis of document data are performed. The appearance frequency of the extracted morpheme.
そして、クラスタリング距離学習装置は、学習データ入力手段によって、どのクラスタに属するかが既知のデータである学習データを入力する。ここで学習データは、クラスタリング対象のデータと同種のデータであって、マハラノビス距離のパラメータを推定するために使用される。なお、学習データのクラスタを既知とするためには、学習データ入力手段が、クラスタを指定された後に、学習データをクラスタごとにまとめて入力することとしてもよいし、学習データそのものにクラスタの情報を付加して入力することとしてもよい。 Then, the clustering distance learning device inputs learning data that is known data as to which cluster belongs to the learning data input means. Here, the learning data is the same kind of data as the data to be clustered, and is used to estimate the Mahalanobis distance parameter. In order to make the learning data cluster known, the learning data input means may input the learning data collectively for each cluster after the cluster is designated. Alternatively, the learning data itself may include the cluster information. It is good also as inputting by adding.
そして、クラスタリング距離学習装置は、パラメータ演算手段によって、マハラノビス距離を計算するための行列と当該行列の転置行列との積の対角成分の和に予め定めた拘束条件を設け、学習データ入力手段で入力された学習データと、当該学習データのクラスタに対応するクラスタ中心記憶手段に記憶されているクラスタ中心とに基づいて、行列をマハラノビス距離のパラメータとして演算する。すなわち、クラスタリング距離学習装置は、パラメータ演算手段において、予め定めた拘束条件を設けることで、マハラノビス距離を計算するためのパラメータである行列を、反復演算することなく特定する。 Then, the clustering distance learning device provides a predetermined constraint condition on the sum of diagonal components of the product of the matrix for calculating the Mahalanobis distance and the transposed matrix of the matrix by the parameter calculation means, and the learning data input means A matrix is calculated as a Mahalanobis distance parameter based on the input learning data and the cluster center stored in the cluster center storage unit corresponding to the cluster of the learning data. That is, the clustering distance learning apparatus specifies a matrix that is a parameter for calculating the Mahalanobis distance without iterative calculation by providing a predetermined constraint condition in the parameter calculation means.
また、請求項2に記載のクラスタリング距離学習装置は、請求項1に記載のクラスタリング距離学習装置において、前記行列をAとしたとき、当該行列Aに対する前記拘束条件をtr(ATA)=1とし、パラメータ演算手段が、前記学習データをx、当該学習データを識別するxの添字をn,n′、前記クラスタ中心をμ、当該クラスタ中心のクラスタを識別するμの添字をk,k′、添字n,n′の学習データxが添字k,k′のクラスタに属する場合に値“1”、それ以外の場合に値“0”をとる属性値をrnk,rn′k′で表したとき、前記行例Aを、 Further, the clustering distance learning device according to claim 2 is the clustering distance learning device according to claim 1, wherein the constraint condition for the matrix A is tr (A T A) = 1, where A is the matrix. And the parameter calculation means sets the learning data to x, the subscript of x identifying the learning data to n, n ′, the cluster center to μ, and the subscript of μ to identify the cluster at the cluster center to k, k ′. , R nk and r n′k ′ are attribute values having a value “1” when the learning data x of the subscripts n and n ′ belong to the cluster of the subscripts k and k ′, and a value “0” otherwise . When the above example A is expressed,
により演算する構成とした。 It was set as the structure which calculates by.
かかる構成において、拘束条件を設けることで、マハラノビス距離のパラメータの推定を、学習データにおけるマハラノビス距離が最小となる拘束条件付最小化問題として解くことができる。そこで、クラスタリング距離学習装置は、パラメータ演算手段によって、この拘束条件付最小化問題の解である行例Aを演算することで、マハラノビス距離のパラメータ(行列)を推定する。
このように、クラスタリング距離学習装置は、固有の式によりマハラノビス距離のパラメータ(行列)を推定するため、反復演算を行う必要がない。
In such a configuration, by providing the constraint condition, the estimation of the parameter of the Mahalanobis distance can be solved as a minimization problem with a constraint condition that minimizes the Mahalanobis distance in the learning data. Therefore, the clustering distance learning device estimates the parameter (matrix) of the Mahalanobis distance by calculating the example A which is a solution to the constraint condition minimization problem by the parameter calculation means.
In this way, the clustering distance learning device estimates the Mahalanobis distance parameter (matrix) using a unique expression, and thus does not need to perform iterative calculations.
さらに、請求項3に記載のクラスタリング距離学習プログラムは、データの特徴量の類似度である距離により複数のデータをクラスタリングする際に用いるマハラノビス距離のパラメータを学習するために、コンピュータを、学習データ入力手段、パラメータ演算手段、として機能させる構成とした。
Further, the clustering distance learning program according to
かかる構成において、クラスタリング距離学習プログラムは、学習データ入力手段によって、どのクラスタに属するかが既知のデータである学習データを入力する。そして、クラスタリング距離学習プログラムは、パラメータ演算手段によって、マハラノビス距離を計算するための行列をAとしたとき、当該行列Aに対する拘束条件をtr(ATA)=1とし、学習データをx、当該学習データを識別するxの添字をn,n′、クラスタ中心記憶手段に記憶されているデータの特徴量空間におけるクラスタごとのクラスタ中心をμ、当該クラスタ中心のクラスタを識別するμの添字をk,k′、添字n,n′の学習データxが添字k,k′のクラスタに属する場合に値“1”、それ以外の場合に値“0”をとる属性値をrnk,rn′k′で表したとき、行例Aを、 In such a configuration, the clustering distance learning program inputs learning data that is known data to which cluster it belongs by the learning data input means. Then, the clustering distance learning program sets the constraint condition for the matrix A to tr (A T A) = 1, the learning data x, and A, where A is a matrix for calculating the Mahalanobis distance by the parameter calculation means. The subscripts of x for identifying the learning data are n, n ', the cluster center for each cluster in the feature amount space of the data stored in the cluster center storage means is μ, and the subscript of μ for identifying the cluster at the cluster center is k. , k ', the subscript n, n' learning data x is the subscript k of, k 'value "1" if it belongs to a cluster of, and the other takes the value "0" when the attribute value r nk, r n' When represented by k ′ , example A is
により演算する。 Calculate by
また、請求項4に記載のクラスタリング装置は、データの特徴量の類似度にマハラノビス距離を用いて、複数のデータをクラスタリングするクラスタリング装置において、前記マハラノビス距離のパラメータを学習する距離学習手段を備え、前記距離学習手段が、クラスタ中心記憶手段と、学習データ入力手段と、パラメータ演算手段と、を備える構成とした。 Further, the clustering device according to claim 4 includes a distance learning unit that learns a parameter of the Mahalanobis distance in a clustering device that clusters a plurality of data using the Mahalanobis distance for the similarity of the feature amount of the data, The distance learning unit includes a cluster center storage unit, a learning data input unit, and a parameter calculation unit.
かかる構成において、クラスタリング装置は、クラスタ中心記憶手段に、クラスタごとに、データの特徴量空間におけるクラスタ中心の値を記憶する。また、クラスタリング装置は、学習データ入力手段によって、どのクラスタに属するかが既知のデータである学習データを入力する。そして、クラスタリング装置は、パラメータ演算手段によって、マハラノビス距離を計算するための行列と当該行列の転置行列との積の対角成分の和に予め定めた拘束条件を設け、学習データ入力手段で入力された学習データと、当該学習データのクラスタに対応するクラスタ中心記憶手段に記憶されているクラスタ中心とに基づいて、行列をマハラノビス距離のパラメータとして演算する。 In such a configuration, the clustering apparatus stores the cluster center value in the data feature space for each cluster in the cluster center storage means. Further, the clustering apparatus inputs learning data, which is known data to which cluster belongs, by the learning data input means. The clustering device provides a predetermined constraint condition for the sum of diagonal components of the product of the matrix for calculating the Mahalanobis distance and the transposed matrix of the matrix by the parameter calculation means, and is input by the learning data input means. The matrix is calculated as a Mahalanobis distance parameter based on the learned data and the cluster center stored in the cluster center storage unit corresponding to the cluster of the learned data.
さらに、請求項5に記載のクラスタリング装置は、請求項4に記載のクラスタリング装置において、前記行列をAとしたとき、当該行列Aに対する前記拘束条件をtr(ATA)=1とし、パラメータ演算手段が、前記学習データをx、当該学習データを識別するxの添字をn,n′、前記クラスタ中心をμ、当該クラスタ中心のクラスタを識別するμの添字をk,k′、添字n,n′の学習データxが添字k,k′のクラスタに属する場合に値“1”、それ以外の場合に値“0”をとる属性値をrnk,rn′k′で表したとき、前記行例Aを、 Furthermore, the clustering device according to claim 5 is the clustering device according to claim 4, wherein when the matrix is A, the constraint condition for the matrix A is tr (A T A) = 1, and parameter calculation is performed. The means is x for the learning data, n and n ′ for the x for identifying the learning data, μ for the cluster center, k and k ′ for the cluster for identifying the cluster at the cluster center, and n, When the learning data x of n ′ is represented by r nk , r n′k ′ , the attribute value taking the value “1” when it belongs to the cluster of subscripts k and k ′, and the value “0” otherwise . Example line A
により演算する構成とした。 It was set as the structure which calculates by.
かかる構成において、拘束条件を設けることで、マハラノビス距離のパラメータの推定を、学習データにおけるマハラノビス距離が最小となる拘束条件付最小化問題として解くことができる。そこで、クラスタリング装置は、パラメータ演算手段によって、この拘束条件付最小化問題の解である行例Aを演算することで、マハラノビス距離のパラメータ(行列)を推定する。 In such a configuration, by providing the constraint condition, the estimation of the parameter of the Mahalanobis distance can be solved as a minimization problem with a constraint condition that minimizes the Mahalanobis distance in the learning data. Therefore, the clustering apparatus estimates the Mahalanobis distance parameter (matrix) by calculating the example A which is the solution of the constraint-conditional minimization problem by the parameter calculation means.
本発明は、以下に示す優れた効果を奏するものである。
請求項1〜3に記載の発明によれば、クラスタリングに用いるマハラノビス距離のパラメータ(行列)を、学習データに応じて調整することができる。これによって、クラスタリング装置において、クラスタリング対象のデータを精度よくクラスタリングすることが可能なパラメータを推定することができる。また、請求項1〜3に記載の発明によれば、マハラノビス距離のパラメータ(行列)の推定を、反復演算することなく求めることができる。これによって、CPU負荷を軽減することができるとともに、パラメータの推定時間を短縮することができる。
The present invention has the following excellent effects.
According to the first to third aspects of the present invention, the Mahalanobis distance parameter (matrix) used for clustering can be adjusted according to the learning data. Thereby, in the clustering apparatus, it is possible to estimate a parameter capable of accurately clustering data to be clustered. According to the first to third aspects of the present invention, the estimation of the Mahalanobis distance parameter (matrix) can be obtained without iterative calculation. As a result, the CPU load can be reduced and the parameter estimation time can be shortened.
請求項4,5に記載の発明によれば、クラスタリングに用いるマハラノビス距離のパラメータ(行列)を、学習データに応じて調整することができ、クラスタリング対象のデータを精度よくクラスタリングすることができる。また、請求項4,5に記載の発明によれば、マハラノビス距離のパラメータ(行列)の推定を、反復演算することなく求めることができる。これによって、CPU負荷を軽減することができるとともに、パラメータの推定時間を短縮することができる。 According to the fourth and fifth aspects of the present invention, the Mahalanobis distance parameter (matrix) used for clustering can be adjusted according to the learning data, and the clustering target data can be clustered with high accuracy. Further, according to the fourth and fifth aspects of the present invention, the estimation of the Mahalanobis distance parameter (matrix) can be obtained without iterative calculation. As a result, the CPU load can be reduced and the parameter estimation time can be shortened.
以下、本発明の実施の形態について図面を参照して説明する。
[クラスタリング装置の概要]
最初に、図1を参照して、本発明の実施形態に係る距離学習手段(クラスタリング距離学習装置)を含んだクラスタリング装置の概要について説明する。
図1に示したクラスタリング装置1は、距離学習手段2によって、学習データから、データの特徴量の類似度である距離に用いるマハラノビス距離のパラメータ(対称正定値行列)を推定する。
なお、ベクトルa,b間のマハラノビス距離M(a,b)は、行列(対称正定値行列)Aを用いて、以下の(1)式により定義される距離である。また、Tは転置行列を示す。
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
[Overview of clustering equipment]
First, an overview of a clustering apparatus including distance learning means (clustering distance learning apparatus) according to an embodiment of the present invention will be described with reference to FIG.
The clustering apparatus 1 shown in FIG. 1 uses a distance learning unit 2 to estimate a Mahalanobis distance parameter (a symmetric positive definite matrix) to be used for the distance that is the similarity of the data feature amount from the learning data.
The Mahalanobis distance M (a, b) between the vectors a and b is a distance defined by the following equation (1) using a matrix (symmetric positive definite matrix) A. T represents a transposed matrix.
すなわち、マハラノビス距離は、行列Aにより特定される距離である。そこで、クラスタリング装置1は、距離学習手段2によって、学習データからマハラノビス距離を算出するために用いる行列Aをパラメータとして推定する。
このとき、距離学習手段2は、パラメータ(対称正定値行列)に対して予め拘束条件を設けることで、反復演算を行わずにパラメータを推定する。
That is, the Mahalanobis distance is a distance specified by the matrix A. Therefore, the clustering apparatus 1 uses the distance learning unit 2 to estimate the matrix A used for calculating the Mahalanobis distance from the learning data as a parameter.
At this time, the distance learning means 2 estimates the parameter without performing the iterative calculation by providing a constraint condition in advance for the parameter (symmetric positive definite matrix).
そして、クラスタリング装置1は、クラスタリング実行手段3によって、特徴量空間におけるクラスタ中心とデータとの距離に、距離学習手段2で推定したパラメータ(行列A)を有するマハラノビス距離を用い、k−平均(k−means)法により、データをクラスタごとにクラスタリングする。
Then, the clustering device 1 uses the Mahalanobis distance having the parameter (matrix A) estimated by the distance learning unit 2 as the distance between the cluster center and the data in the feature amount space by the
このように、クラスタリング装置1は、予め与えられた学習データから、マハラノビス距離のパラメータ(対称正定値行列)を推定し、当該マハラノビス距離を用いてクラスタリングを行う半教師ありクラスタリング手法を実現するものである。
以下、本発明の実施形態に係るクラスタリング装置の構成および動作について順次説明する。
As described above, the clustering device 1 realizes a semi-supervised clustering method that estimates the Mahalanobis distance parameter (symmetric positive definite matrix) from the given learning data and performs clustering using the Mahalanobis distance. is there.
Hereinafter, the configuration and operation of the clustering apparatus according to the embodiment of the present invention will be sequentially described.
[クラスタリング装置の構成]
まず、図2を参照して、本発明の実施形態に係るクラスタリング装置の構成について説明する。このクラスタリング装置1は、データの特徴量の類似度にマハラノビス距離を用いて、複数のデータをクラスタリングするものである。ここでは、クラスタリング装置1は、距離学習手段2と、クラスタリング実行手段3と、を備えている。
[Configuration of clustering device]
First, the configuration of the clustering apparatus according to the embodiment of the present invention will be described with reference to FIG. The clustering device 1 is a device that clusters a plurality of data by using the Mahalanobis distance as the similarity of the feature amount of the data. Here, the clustering apparatus 1 includes distance learning means 2 and clustering execution means 3.
距離学習手段(クラスタリング距離学習装置)2は、後記するクラスタリング実行手段3において使用するマハラノビス距離のパラメータを学習(推定)するものである。ここでは、距離学習手段2は、記憶手段21と、学習データ入力手段22と、特徴量抽出手段23と、パラメータ演算手段24と、を備えている。
The distance learning means (clustering distance learning apparatus) 2 learns (estimates) the Mahalanobis distance parameter used in the clustering execution means 3 described later. Here, the distance learning unit 2 includes a
記憶手段(クラスタ中心記憶手段)21は、予め定めたデータの分類数(クラスタ数)ごとに、クラスタ中心の値を記憶するものであって、ハードディスク等の一般的な記憶装置である。
この記憶手段21に記憶するクラスタ中心の値は、予め定めたクラスタの数(K個とする)だけ準備すれば、その値は特に限定するものではない。例えば、すべてのクラスタ中心μk(k=1,2,…,K)を以下の(2)式に示すように、特徴量空間上の原点とする。
The storage means (cluster center storage means) 21 stores a cluster center value for each predetermined number of data classifications (number of clusters), and is a general storage device such as a hard disk.
The cluster center value stored in the storage means 21 is not particularly limited as long as a predetermined number (K) of clusters is prepared. For example, all cluster centers μ k (k = 1, 2,..., K) are set as origins in the feature amount space as shown in the following equation (2).
なお、この記憶手段21には、後記するパラメータ演算手段24により演算されたマハラノビス距離の行例(パラメータ)Aも記憶されるものとする。 The storage means 21 also stores a line example (parameter) A of Mahalanobis distance calculated by the parameter calculation means 24 described later.
学習データ入力手段22は、外部からマハラノビス距離のパラメータを学習するための学習データを入力するものである。この学習データは、どのクラスタに属するデータであるかが既知のデータである。例えば、学習データ入力手段22は、クラスタを指定された後に、学習データをクラスタごとにまとめて入力することとしてもよいし、学習データそのものにクラスタの情報を付加して入力することとしてもよい。
The learning data input means 22 inputs learning data for learning a parameter of Mahalanobis distance from the outside. This learning data is data in which the cluster belongs is known. For example, the learning
また、この学習データは、クラスタリング実行手段3においてクラスタリングするデータと同種のデータである。なお、この学習データは、画像データ、音声データ、文書データ等、その特徴量において分類可能なデータであれば、どのようなデータであっても構わない。この学習データ入力手段22は、入力した学習データを特徴量抽出手段23に出力する。
The learning data is the same type of data that is clustered by the clustering execution means 3. Note that the learning data may be any data as long as the data can be classified by the feature amount, such as image data, audio data, document data, and the like. The learning
特徴量抽出手段23は、学習データ入力手段22で入力された学習データの特徴量を抽出するものである。なお、この特徴量抽出手段23は、学習データから抽出する特徴量の種類を、予め学習データの種類に応じて定めておく。あるいは、学習データの種類が固定の場合は、予め定めた固有の特徴量を抽出するものであってもよい。
例えば、特徴量抽出手段23は、学習データが、画像データである場合、色分布、動きベクトル等を特徴量として抽出することができる。また、学習データが、音声データの場合、ケプストラム係数等、文書データの場合、形態素の出現頻度等を特徴量とすることができる。
The feature
For example, when the learning data is image data, the feature
この特徴量抽出手段23で抽出された1以上の特徴量は、特徴量空間上のベクトルで表される。すなわち、1つの学習データは、特徴量空間上の1点で表される。そして、特徴量抽出手段23は、学習データごとに抽出した特徴量をパラメータ演算手段24に出力する。なお、以降の説明においては、学習データごとに抽出した特徴量をベクトルとし、特徴量のベクトルで表される学習データをxn(n=1,2,…,N)と表記する。
The one or more feature amounts extracted by the feature
パラメータ演算手段24は、学習データ入力手段22で入力され、特徴量抽出手段23で特徴量が抽出された学習データxn(n=1,2,…,N)と、当該学習データのクラスタに対応して記憶手段21に記憶されているクラスタ中心μk(k=1,2,…,K)とに基づいて、マハラノビス距離の行列をパラメータとして演算するものである。 The parameter calculation means 24 is input to the learning data x n (n = 1, 2,..., N), which is input by the learning data input means 22 and extracted by the feature quantity extraction means 23, and the learning data cluster. Correspondingly, based on the cluster centers μ k (k = 1, 2,..., K) stored in the storage means 21, a Mahalanobis distance matrix is calculated as a parameter.
このパラメータ演算手段24は、演算により求めた行列を記憶手段21に書き込み、記憶する。なお、この記憶手段21に記憶された行列Aは、クラスタリング実行手段3において、データをクラスタリングする際に、クラスタ中心μkからのマハラノビス距離を算出するために使用される。
具体的には、パラメータ演算手段24は、以下の(3)式によりマハラノビス距離の行列Aを演算する。
The parameter calculation means 24 writes and stores the matrix obtained by the calculation in the storage means 21. The matrix A stored in the storage means 21 is used to calculate the Mahalanobis distance from the cluster center μ k when the clustering execution means 3 clusters data.
Specifically, the parameter calculation means 24 calculates the Mahalanobis distance matrix A by the following equation (3).
この(3)式では、学習データをベクトル表記であるxnで表す。なお、添字nは、当該学習データを識別する情報であって、{1,2,…,N}とする。また、クラスタ中心をベクトル表記であるμkで表す。なお、添字kは、クラスタを識別する情報であって、{1,2,…,K}とする。さらに、ここでは、属性値をrnkで表す。この属性値は、添字nのデータが添字kのクラスタに属する場合に値“1”、それ以外の場合に値“0”をとる1−of−k表記法で表記することとする。なお、この(3)式において、添字n′およびk′は、それぞれ添字nおよびkと同じ意味を示し、二重の総和記号Σの変数を区別するために用いている。また、Tは転置行列を示し、tr(・)は括弧内の行列における対角成分の和(トレース)を表している。 In this equation (3), the learning data is represented by xn which is a vector notation. The subscript n is information for identifying the learning data and is {1, 2,..., N}. The cluster center is represented by μ k which is a vector notation. The subscript k is information for identifying a cluster and is {1, 2,..., K}. Further, here, the attribute value is represented by r nk . This attribute value is expressed in a 1-of-k notation that takes the value “1” when the data of the subscript n belongs to the cluster of the subscript k, and the value “0” otherwise. In the equation (3), the subscripts n ′ and k ′ have the same meaning as the subscripts n and k, respectively, and are used to distinguish the variable of the double summation symbol Σ. T represents a transposed matrix, and tr (•) represents the sum (trace) of diagonal components in the matrix in parentheses.
このように、パラメータ演算手段24は、学習データxnと、クラスタ中心μkとを用いて、反復演算を行わずに演算を行い行列Aを算出する。なお、この演算により、マハラノビス距離の行列を推定することができる理由については、後で説明を行うこととする。
As described above, the
クラスタリング実行手段(クラスタリング実行装置)3は、距離学習手段2で推定されたマハラノビス距離のパラメータ(行列)を用いて、クラスタリング対象のデータを、k−平均(k−means)法によりクラスタリングするものである。ここでは、クラスタリング実行手段3は、データ入力手段31と、特徴量抽出手段32と、クラスタ生成手段33と、クラスタ中心更新手段34と、クラスタ判定手段35と、を備えている。
The clustering execution means (clustering execution apparatus) 3 uses the Mahalanobis distance parameter (matrix) estimated by the distance learning means 2 to cluster the data to be clustered by the k-means method. is there. Here, the
データ入力手段31は、外部からクラスタリング対象のデータを入力するものである。このデータは、距離学習手段2においてマハラノビス距離のパラメータを学習するために用いた学習データと同種のデータである。すなわち、このデータは、画像データ、音声データ、文書データ等、その特徴量において分類可能なデータであれば、どのようなデータであっても構わない。このデータ入力手段31は、入力したデータを特徴量抽出手段32に出力する。
The data input means 31 is for inputting data to be clustered from the outside. This data is the same type of learning data used for learning the Mahalanobis distance parameter in the distance learning means 2. In other words, this data may be any data as long as it can be classified by the feature amount, such as image data, audio data, document data, and the like. The
特徴量抽出手段32は、データ入力手段31で入力されたデータの特徴量を抽出するものである。この特徴量抽出手段32は、データから抽出する特徴量の種類を、予めデータの種類に応じて定めておく。あるいは、データの種類が固定の場合は、予め定めた固有の特徴量を抽出するものであってもよい。なお、特徴量抽出手段32が抽出する特徴量は、距離学習手段2の特徴量抽出手段32が抽出する特徴量と同種のものとする。
The feature
この特徴量抽出手段32で抽出された1以上の特徴量は、特徴量空間上のベクトルで表される。すなわち、1つのデータは、特徴量空間上の1点で表される。そして、特徴量抽出手段32は、データごとに抽出した特徴量をクラスタ生成手段33に出力する。なお、以降の説明においては、データごとに抽出した特徴量をベクトルとし、特徴量のベクトルで表されるデータをzm(m=1,2,…,M)と表記する。
The one or more feature quantities extracted by the feature
クラスタ生成手段33は、データ入力手段31で入力され、特徴量抽出手段32で特徴量が抽出されたデータzm(m=1,2,…,M)について、距離学習手段2で推定されたマハラノビス距離のパラメータ(行列A)を用いて、クラスタを生成するものである。 The cluster generation means 33 is estimated by the distance learning means 2 for the data z m (m = 1, 2,..., M) input by the data input means 31 and extracted by the feature quantity extraction means 32. A cluster is generated using the Mahalanobis distance parameter (matrix A).
ここでは、クラスタ生成手段33は、クラスタ中心μkとデータzmとの距離を、距離学習手段2で推定された行列Aを用いて前記(1)式により計算し、データzmを、最も近いクラスタ中心μkに割り当てる(分類する)ことで、K個のクラスタを生成する。このクラスタ生成手段33は、生成したK個のクラスタを、クラスタ中心μkとデータzmとを対応付けて図示を省略したメモリに展開することとする。なお、クラスタ生成手段33におけるクラスタ中心の初期値は、データzmをクラスタ数Kで分割して割り当てたクラスタの中心とする。例えば、それぞれのクラスタに属するデータの特徴量空間上の平均とする。
Here, the cluster generation means 33 calculates the distance between the cluster center μ k and the data z m by the above equation (1) using the matrix A estimated by the distance learning means 2, and the data z m By assigning (classifying) to the near cluster center μ k , K clusters are generated. The
また、クラスタ生成手段33は、後記するクラスタ判定手段35において、クラスタ生成の終了が指示された場合に、メモリ(不図示)に展開されているクラスタをクラスタ結果として出力する。なお、クラスタ生成手段33は、後記するクラスタ判定手段35から、クラスタ生成の継続が指示された場合、後記するクラスタ中心更新手段34において、更新されたクラスタ中心を用いてデータzmのクラスタリングを行う。
Further, the
クラスタ中心更新手段34は、クラスタ生成手段33で生成されたクラスタに基づいて、クラスタ中心を更新するものである。すなわち、クラスタ中心更新手段34は、クラスタ生成手段33で生成されたクラスタごとに、クラスタに属するデータzmの特徴量空間における重心を求めることで、当該クラスタの新たなクラスタ中心とする。なお、クラスタ中心更新手段34は、新たなクラスタ中心を、旧クラスタ中心と対応付けてメモリ(不図示)に書き込む。
The cluster
クラスタ判定手段35は、クラスタ中心更新手段34で更新されたクラスタ中心と、旧クラスタ中心との距離(ユークリッド距離)に基づいて、クラスタリングの終了を判定するものである。このクラスタ判定手段35は、例えば、更新されたクラスタ中心と、旧クラスタ中心との距離(更新量)が予め定めた距離(閾値)以下となった場合に、クラスタリングが終了したものと判定する。また、このクラスタ判定手段35は、クラスタリングが終了したと判定した場合、クラスタ生成手段33にクラスタ生成の終了を指示する。
なお、クラスタ判定手段35は、クラスタ生成手段33において、更新されたクラスタ中心でデータをクラスタリングし、割り当てるクラスタに変化がなくなった場合に、クラスタリングが終了したものと判定することとしてもよい。
The
Note that the
以上説明したように、クラスタリング装置1は、半教師ありクラスタリングとして、学習データに基づいて、マハラノビス距離のパラメータを推定し、そのパラメータを用いて、クラスタリング対象のデータをクラスタリングすることができる。このとき、クラスタリング装置1は、距離学習手段2において、マハラノビス距離のパラメータを、反復演算することなく推定することができ、学習データから高速にパラメータの推定を行うことができる。 As described above, the clustering device 1 can estimate the Mahalanobis distance parameter based on the learning data as semi-supervised clustering, and cluster the clustering target data using the parameter. At this time, the clustering apparatus 1 can estimate the Mahalanobis distance parameter without iterative calculation in the distance learning means 2, and can estimate the parameter at high speed from the learning data.
また、クラスタリング装置1は、図示を省略したCPUやメモリを搭載した一般的なコンピュータで実現することができる。このとき、クラスタリング装置1は、コンピュータを、前記した各手段として機能させるクラスタリングプログラムにより動作させることができる。 Further, the clustering apparatus 1 can be realized by a general computer having a CPU and a memory (not shown). At this time, the clustering apparatus 1 can be operated by a clustering program that causes the computer to function as each of the means described above.
以上、本発明の実施形態について説明したが、本発明は、この実施形態に限定されるものではない。例えば、ここでは、クラスタリング装置1が、距離学習手段2と、クラスタリング実行手段3とでそれぞれ特徴量抽出手段23,32を備える構成としたが、1つの手段として構成し、入力データ(学習データ、クラスタ対象のデータ)に応じて、出力先(パラメータ演算手段24またはクラスタ生成手段33)を切り替える構成としてもよい。
また、この特徴量抽出手段23,32は、予め特徴量が抽出された学習データやクラスタ対象のデータが外部から入力される場合は、構成から省略してもよい。
Although the embodiment of the present invention has been described above, the present invention is not limited to this embodiment. For example, here, the clustering device 1 is configured to include the feature
Further, the feature amount extraction means 23 and 32 may be omitted from the configuration when learning data from which feature amounts have been extracted in advance or cluster target data is input from the outside.
また、ここでは、記憶手段21に記憶するクラスタ中心μkの値を前記(2)式に示したように、特徴量空間上の原点としたが、以下の(4)式に示すように、学習データxn全体の特徴量空間上の平均(大域的平均)としてもよい。 Here, the value of the cluster center μ k stored in the storage means 21 is the origin on the feature amount space as shown in the equation (2), but as shown in the following equation (4), It is good also as the average (global average) on the feature-value space of the learning data xn whole.
あるいは、クラスタ中心μkの値を、以下の(5)式に示すように、クラスタkごとの学習データxnの特徴量空間上の平均(クラスタ平均)としてもよい。 Alternatively, the value of the cluster center μ k may be an average (cluster average) in the feature amount space of the learning data x n for each cluster k as shown in the following equation (5).
また、ここでは、クラスタリング装置1を、距離学習手段2とクラスタリング実行手段3とで構成したが、これらの各手段を、別個独立した装置(クラスタリング距離学習装置、クラスタリング実行装置)として構成してもよい。 Here, the clustering device 1 is composed of the distance learning means 2 and the clustering execution means 3, but each of these means may be configured as an independent device (clustering distance learning device, clustering execution device). Good.
この場合、クラスタリング距離学習装置(距離学習手段2)、クラスタリング実行装置(クラスタリング実行手段3)は、それぞれ図示を省略したCPUやメモリを搭載した一般的なコンピュータで実現することができる。また、クラスタリング距離学習装置(距離学習手段2)は、コンピュータを、距離学習手段2で説明した各手段として機能させるクラスタリング距離学習プログラムにより動作させることができる。また、クラスタリング実行装置(クラスタリング実行手段3)は、コンピュータを、クラスタリング実行手段3で説明した各手段として機能させるクラスタリング実行プログラムにより動作させることができる。 In this case, the clustering distance learning device (distance learning means 2) and the clustering execution device (clustering execution means 3) can each be realized by a general computer equipped with a CPU and memory not shown. Further, the clustering distance learning device (distance learning means 2) can be operated by a clustering distance learning program that causes the computer to function as each means described in the distance learning means 2. Further, the clustering execution device (clustering execution means 3) can be operated by a clustering execution program that causes the computer to function as each means described in the clustering execution means 3.
[クラスタリング装置の動作]
次に、図3,4を参照して、本発明の実施形態に係るクラスタリング装置の動作について説明する。なお、ここでは、クラスタリング装置1の動作として、距離学習手段2において行われる学習動作(パラメータ推定動作)と、クラスタリング実行手段3において行われるクラスタリング実行動作とに分けて説明する。
[Operation of clustering device]
Next, with reference to FIGS. 3 and 4, the operation of the clustering apparatus according to the embodiment of the present invention will be described. Here, the operation of the clustering apparatus 1 will be described by dividing it into a learning operation (parameter estimation operation) performed in the distance learning means 2 and a clustering execution operation performed in the clustering execution means 3.
(学習動作)
最初に、図3を参照(構成については適宜図2参照)して、クラスタリング装置1(距離学習手段2)の学習動作(パラメータ推定動作)について説明する。なお、ここでは、記憶手段21に、K個のクラスタ中心μkとして、予め特徴量空間上の原点が記憶されているものとする。
(Learning action)
First, a learning operation (parameter estimation operation) of the clustering apparatus 1 (distance learning means 2) will be described with reference to FIG. Here, it is assumed that the origin on the feature amount space is stored in advance in the
まず、クラスタリング装置1は、距離学習手段2の学習データ入力手段22によって、外部からマハラノビス距離のパラメータを学習するためのクラスタが既知の学習データを入力する(ステップS10)。
そして、クラスタリング装置1は、距離学習手段2の特徴量抽出手段23によって、ステップS10で入力した学習データの特徴量を抽出する(ステップS11)。
First, the clustering device 1 inputs learning data with a known cluster for learning the Mahalanobis distance parameter from the outside by the learning
Then, the clustering apparatus 1 extracts the feature amount of the learning data input in step S10 by the feature
その後、クラスタリング装置1は、距離学習手段2のパラメータ演算手段24によって、ステップS11で特徴量が抽出された学習データxn(n=1,2,…,N)と、当該学習データのクラスタに対応して記憶手段21に記憶されているクラスタ中心μk(k=1,2,…,K)とに基づいて、前記(3)式により、マハラノビス距離の行列Aを演算する(ステップS12)。
そして、クラスタリング装置1は、距離学習手段2のパラメータ演算手段24によって、ステップS12で演算により求めたマハラノビス距離の行列Aを、記憶手段21に書き込み、記憶する(ステップS13)。
Thereafter, the clustering device 1 applies the learning data x n (n = 1, 2,..., N) from which the feature amount is extracted in step S11 by the
Then, the clustering apparatus 1 writes and stores the Mahalanobis distance matrix A obtained by the calculation in step S12 in the
以上の動作によって、クラスタリング装置1は、マハラノビス距離を算出するために使用される行列Aを、学習によって推定することができる。
なお、ここでは、記憶手段21に、K個のクラスタ中心μkが予め記憶されているものとして説明したが、前記した(4)式や(5)式に示すように、学習データに応じてクラスタ中心の値を算出し記憶手段21に記憶することとしてもよい。この場合、クラスタリング装置1は、ステップS11以降に、距離学習手段2のパラメータ演算手段24によって、ステップS11で特徴量が抽出された学習データxnに基づいて、前記した(4)式や(5)式に示す演算を行うことでクラスタ中心μkを算出し、記憶手段21に書き込み、記憶する。
With the above operation, the clustering apparatus 1 can estimate the matrix A used for calculating the Mahalanobis distance by learning.
Here, the description has been made assuming that K cluster centers μ k are stored in the storage means 21 in advance. However, as shown in the above equations (4) and (5), according to the learning data, The cluster center value may be calculated and stored in the
(クラスタリング実行動作)
次に、図4を参照(構成については適宜図2参照)して、クラスタリング装置1(クラスタリング実行手段3)のクラスタリング実行動作について説明する。
まず、クラスタリング装置1は、クラスタリング実行手段3のデータ入力手段31によって、外部からクラスタリング対象のデータを入力する(ステップS20)。
そして、クラスタリング装置1は、クラスタリング実行手段3の特徴量抽出手段32によって、ステップS20で入力したデータの特徴量を抽出する(ステップS21)。
(Clustering execution operation)
Next, the clustering execution operation of the clustering apparatus 1 (clustering execution means 3) will be described with reference to FIG. 4 (refer to FIG. 2 as appropriate for the configuration).
First, the clustering device 1 inputs data to be clustered from the outside by the data input means 31 of the clustering execution means 3 (step S20).
Then, the clustering device 1 extracts the feature amount of the data input in step S20 by the feature
その後、クラスタリング装置1は、クラスタリング実行手段3のクラスタ生成手段33によって、ステップS21で特徴量が抽出されたデータzm(m=1,2,…,M)をクラスタ数Kで分割し、それぞれのクラスタに属するデータの特徴量空間上の平均を求めることで、クラスタ中心の初期値を算出する(ステップS22)。
Thereafter, the clustering device 1 divides the data z m (m = 1, 2,..., M) from which the feature amount is extracted in step S21 by the
そして、クラスタリング装置1は、クラスタリング実行手段3のクラスタ生成手段33によって、クラスタ中心μkと、ステップS21で特徴量が抽出されたデータzm(m=1,2,…,M)との距離を、距離学習手段2で推定され、記憶手段21に記憶されている行列Aを用いて前記(1)式により計算し、データzmを、最も近いクラスタ中心μkに割り当てる(分類する)ことで、K個のクラスタを生成する(ステップS23)。
The clustering apparatus 1 then determines the distance between the cluster center μ k and the data z m (m = 1, 2,..., M) from which the feature amount is extracted in step S21 by the
そして、クラスタリング装置1は、クラスタリング実行手段3のクラスタ中心更新手段34によって、ステップS23で生成されたクラスタごとに、クラスタに属するデータzmの特徴量空間上の重心を求めることで、クラスタ中心を新たなクラスタ中心に更新する(ステップS24)。
ここで、クラスタリング装置1は、クラスタリング実行手段3のクラスタ判定手段35によって、ステップS24で更新されたクラスタ中心と、旧クラスタ中心との距離差(更新量)が予め定めた距離(閾値)以下となったか否かを判定する(ステップS25)。
Then, the clustering apparatus 1, the cluster centers updating means 34
Here, the clustering apparatus 1 determines that the distance difference (update amount) between the cluster center updated in step S24 and the old cluster center by the
そして、距離差(更新量)が閾値以下となった場合(ステップS25でYes)、クラスタリング装置1は、クラスタリング実行手段3のクラスタ生成手段33によって、クラスタ結果を出力する(ステップS26)。一方、距離差(更新量)が閾値より大きい場合(ステップS25でNo)、クラスタリング装置1は、ステップS23に戻って、クラスタ生成手段33によって、更新されたクラスタ中心によりクラスタを生成する動作を実行する。
以上の動作によって、クラスタリング装置1は、マハラノビス距離を用いて、k−平均(k−means)法により、データをクラスタごとにクラスタリングすることができる。
When the distance difference (update amount) is equal to or smaller than the threshold (Yes in Step S25), the clustering apparatus 1 outputs the cluster result by the
With the above operation, the clustering apparatus 1 can cluster data for each cluster using the Mahalanobis distance by the k-means method.
なお、ここでは、更新されたクラスタ中心と、旧クラスタ中心との距離差(更新量)が予め定めた距離(閾値)以下となったか否かにより、ステップS25においてクラスタ生成の終了判定を行ったが、この手法に限定されるものではない。例えば、ステップS23において、更新されたクラスタ中心でクラスタを生成する際に、割り当てるクラスタに変化がなくなった場合に終了と判定することとしてもよい。 Here, the end of cluster generation is determined in step S25 depending on whether the distance difference (update amount) between the updated cluster center and the old cluster center is equal to or smaller than a predetermined distance (threshold). However, it is not limited to this method. For example, when a cluster is generated at the updated cluster center in step S23, it may be determined to end when there is no change in the allocated cluster.
[マハラノビス距離のパラメータ推定手法の説明]
次に、クラスタリング装置1が、距離学習手段2のパラメータ演算手段24において、マハラノビス距離の算出に用いるパラメータ(行列)を、反復演算を行うことなく、前記(3)式の演算により求めることができる理由について説明する。
[Explanation of Mahalanobis distance parameter estimation method]
Next, the clustering device 1 can obtain the parameter (matrix) used for the calculation of the Mahalanobis distance by the calculation of the equation (3) without performing the iterative calculation in the
学習データxnを最も精度よくクラスタリングするマハラノビス距離M(前記(1)式参照)の学習は、以下の(6)式に示す行列Aとクラスタ中心μkの関数Jを最小にする問題と捉えることができる。 Learning the Mahalanobis distance M (see the above equation (1)) that clusters the learning data x n with the highest accuracy is regarded as a problem of minimizing the function J of the matrix A and the cluster center μ k shown in the following equation (6). be able to.
この関数Jは、クラスタkのクラスタ中心μkと、当該クラスタkに属する学習データxnとのマハラノビス距離Mの和を、すべてのクラスタk(k=1,2,…,K)について総和する関数である。なお、rnkは、添字nの学習データが添字kのクラスタに属する場合に値“1”、それ以外の場合に値“0”をとる。
ここで、関数J(A,μk)を、行列Aで偏微分すると、以下の(7)式を得る。
This function J sums the sum of the Mahalanobis distance M between the cluster center μ k of the cluster k and the learning data x n belonging to the cluster k for all clusters k (k = 1, 2,..., K). It is a function. Note that r nk takes a value “1” when the learning data of the subscript n belongs to the cluster of the subscript k, and takes a value “0” otherwise.
Here, when the function J (A, μ k ) is partially differentiated by the matrix A, the following expression (7) is obtained.
この(7)式の右辺は、共分散行列である。つまり、その共分散行列の対角成分は、xn=μkでない限り正であり、前記(7)式の値は増大し続けるため、最小解が存在しないことになる。そこで、行列Aの大きさを制限する拘束条件として、以下の(8)式を導入する。 The right side of the equation (7) is a covariance matrix. That is, the diagonal component of the covariance matrix is positive unless x n = μ k , and the value of equation (7) continues to increase, so there is no minimum solution. Therefore, the following equation (8) is introduced as a constraint condition for limiting the size of the matrix A.
なお、Tは転置行列を示し、tr(・)は括弧内の行列の対角成分の和(トレース)を表している。
この(8)式の拘束条件の下で、前記(6)式を最小にする行列Aを決定する問題は、拘束条件付最小化問題であるため、ラグランジュの未定乗数αを導入して、以下の(9)式を最小化すればよいことになる。
T represents a transposed matrix, and tr (•) represents the sum (trace) of diagonal components of the matrix in parentheses.
Since the problem of determining the matrix A that minimizes the expression (6) under the constraint condition of the equation (8) is a constraint condition minimization problem, the Lagrange undetermined multiplier α is introduced and (9) Equation (9) should be minimized.
ここで、この(9)式を行列Aで偏微分すると、以下の(10)式を得る。 Here, when this equation (9) is partially differentiated by the matrix A, the following equation (10) is obtained.
この(10)式が値“0”となる行列Aは、以下の(11)式で求められる。 The matrix A in which the expression (10) has a value “0” is obtained by the following expression (11).
ここで、前記(8)式の拘束条件に、この(11)式で求められた行列Aを代入すると、以下の(12)式を得る。 Here, when the matrix A obtained by the equation (11) is substituted into the constraint condition of the equation (8), the following equation (12) is obtained.
この(12)式を変形することで、以下の(13)式を得る。 The following equation (13) is obtained by modifying the equation (12).
この(13)式の結果を、前記(11)式に代入することで、前記(3)式の行列Aを得ることができる。
以上説明したように、行列Aに拘束条件を設けることで、前記(3)式に示した行列Aは、学習データxnを最も精度よくクラスタリングするマハラノビス距離Mを算出するための行列となる。これによって、図2で説明した距離学習手段2のパラメータ演算手段24は、行列Aを反復演算することなく、前記(3)式の演算により、学習データを精度よくクラスタリングする行列を学習することができる。
By substituting the result of the equation (13) into the equation (11), the matrix A of the equation (3) can be obtained.
As described above, by providing a constraint condition on the matrix A, the matrix A shown in the equation (3) becomes a matrix for calculating the Mahalanobis distance M for clustering the learning data xn with the highest accuracy. Accordingly, the
なお、ここでは、拘束条件として、tr(ATA)の値を“1”としたが、この値は“1”である必要はなく、任意の定数であればよい。
すなわち、定数をcとしたとき、拘束条件は、以下の(14)式となる。
Here, as a constraint condition, the value of tr (A T A) is set to “1”, but this value does not have to be “1” and may be an arbitrary constant.
That is, when the constant is c, the constraint condition is the following equation (14).
この場合、前記(12)式、(13)式と同様の式の変形を行うことで、(15)式に示す行列Aを得ることができる。 In this case, the matrix A shown in the equation (15) can be obtained by modifying the equations similar to the equations (12) and (13).
よって、図2で説明した距離学習手段2のパラメータ演算手段24は、前記(3)式の代わりに、この(15)式を用いて、行列Aを演算することとしてもよい。ただし、(15)式において、1/cにより小数点演算が行われることから、CPUの負荷を軽減するため、定数cは“1”であることが望ましいといえる。
Therefore, the
1 クラスタリング装置
2 距離学習手段(クラスタリング距離学習装置)
21 記憶手段(クラスタ中心記憶手段)
22 学習データ入力手段
23 特徴量抽出手段
24 パラメータ演算手段
3 クラスタリング実行手段(クラスタリング実行装置)
31 データ入力手段
32 特徴量抽出手段
33 クラスタ生成手段
34 クラスタ中心更新手段
35 クラスタ判定手段
DESCRIPTION OF SYMBOLS 1 Clustering apparatus 2 Distance learning means (clustering distance learning apparatus)
21 Storage means (cluster center storage means)
22 learning data input means 23 feature quantity extraction means 24 parameter calculation means 3 clustering execution means (clustering execution apparatus)
31
Claims (5)
クラスタごとに、前記データの特徴量空間におけるクラスタ中心の値を記憶するクラスタ中心記憶手段と、
どのクラスタに属するかが既知のデータである学習データを入力する学習データ入力手段と、
前記マハラノビス距離を計算するための行列と当該行列の転置行列との積の対角成分の和に予め定めた拘束条件を設け、前記学習データ入力手段で入力された学習データと、当該学習データのクラスタに対応する前記クラスタ中心記憶手段に記憶されているクラスタ中心とに基づいて、前記行列を前記パラメータとして演算するパラメータ演算手段と、
を備えることを特徴とするクラスタリング距離学習装置。 A clustering distance learning device for learning a Mahalanobis distance parameter used when clustering a plurality of data according to a distance that is a similarity of a feature amount of data,
Cluster center storage means for storing a cluster center value in the feature amount space of the data for each cluster;
Learning data input means for inputting learning data which is known data to which cluster belongs,
A predetermined constraint condition is provided for the sum of diagonal components of the product of the matrix for calculating the Mahalanobis distance and the transposed matrix of the matrix, the learning data input by the learning data input means, and the learning data Parameter computing means for computing the matrix as the parameter based on the cluster center stored in the cluster center storage means corresponding to the cluster;
A clustering distance learning device comprising:
前記パラメータ演算手段が、
前記学習データをx、当該学習データを識別するxの添字をn,n′、前記クラスタ中心をμ、当該クラスタ中心のクラスタを識別するμの添字をk,k′、添字n,n′の学習データxが添字k,k′のクラスタに属する場合に値“1”、それ以外の場合に値“0”をとる属性値をrnk,rn′k′で表したとき、前記行列Aを、
The parameter calculation means is
The learning data is x, the subscript of x identifying the learning data is n, n ′, the cluster center is μ, the subscript of μ identifying the cluster at the cluster center is k, k ′, and the subscripts n, n ′. When the learning data x is represented by r nk and r n′k ′ as attribute values having a value “1” when the learning data x belongs to a cluster of subscripts k and k ′, and the value “0” otherwise. The
どのクラスタに属するかが既知のデータである学習データを入力する学習データ入力手段、
前記マハラノビス距離を計算するための行列をAとしたとき、当該行列Aに対する拘束条件をtr(ATA)=1とし、
前記学習データをx、当該学習データを識別するxの添字をn,n′、クラスタ中心記憶手段に記憶されている前記データの特徴量空間におけるクラスタごとのクラスタ中心をμ、当該クラスタ中心のクラスタを識別するμの添字をk,k′、添字n,n′の学習データxが添字k,k′のクラスタに属する場合に値“1”、それ以外の場合に値“0”をとる属性値をrnk,rn′k′で表したとき、前記行例Aを、
として機能させることを特徴とするクラスタリング距離学習プログラム。 In order to learn the Mahalanobis distance parameter used when clustering a plurality of data according to the distance that is the similarity of the feature amount of the data,
Learning data input means for inputting learning data which is known data to which cluster belongs,
When the matrix for calculating the Mahalanobis distance is A, the constraint condition for the matrix A is tr (A T A) = 1,
The learning data is x, the subscripts of x identifying the learning data are n, n ′, the cluster center for each cluster in the feature amount space of the data stored in the cluster center storage means is μ, and the cluster at the cluster center Is an attribute that takes the value “1” when the learning data x of the subscripts k and k ′, the subscripts n and n ′ belong to the cluster of the subscripts k and k ′, and the value “0” otherwise. When the value is represented by r nk , r n′k ′ , the line example A is
Clustering distance learning program characterized by functioning as
前記マハラノビス距離のパラメータを学習する距離学習手段を備え、
前記距離学習手段は、
クラスタごとに、前記データの特徴量空間におけるクラスタ中心の値を記憶するクラスタ中心記憶手段と、
どのクラスタに属するかが既知のデータである学習データを入力する学習データ入力手段と、
前記マハラノビス距離を計算するための行列と当該行列の転置行列との積の対角成分の和に予め定めた拘束条件を設け、前記学習データ入力手段で入力された学習データと、当該学習データのクラスタに対応する前記クラスタ中心記憶手段に記憶されているクラスタ中心とに基づいて、前記行列を前記パラメータとして演算するパラメータ演算手段と、
を備えることを特徴とするクラスタリング装置。 In a clustering apparatus that clusters a plurality of data using the Mahalanobis distance for the similarity of the data feature amount,
A distance learning means for learning the Mahalanobis distance parameter;
The distance learning means includes
Cluster center storage means for storing a cluster center value in the feature amount space of the data for each cluster;
Learning data input means for inputting learning data which is known data to which cluster belongs,
A predetermined constraint condition is provided for the sum of diagonal components of the product of the matrix for calculating the Mahalanobis distance and the transposed matrix of the matrix, the learning data input by the learning data input means, and the learning data Parameter computing means for computing the matrix as the parameter based on the cluster center stored in the cluster center storage means corresponding to the cluster;
A clustering apparatus comprising:
前記パラメータ演算手段が、
前記学習データをx、当該学習データを識別するxの添字をn,n′、前記クラスタ中心をμ、当該クラスタ中心のクラスタを識別するμの添字をk,k′、添字n,n′の学習データxが添字k,k′のクラスタに属する場合に値“1”、それ以外の場合に値“0”をとる属性値をrnk,rn′k′で表したとき、前記行列Aを、
The parameter calculation means is
The learning data is x, the subscript of x identifying the learning data is n, n ′, the cluster center is μ, the subscript of μ identifying the cluster at the cluster center is k, k ′, and the subscripts n, n ′. When the learning data x is represented by r nk and r n′k ′ as attribute values having a value “1” when the learning data x belongs to a cluster of subscripts k and k ′, and the value “0” otherwise. The
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2009045015A JP5255484B2 (en) | 2009-02-27 | 2009-02-27 | Clustering distance learning device and program thereof, and clustering device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2009045015A JP5255484B2 (en) | 2009-02-27 | 2009-02-27 | Clustering distance learning device and program thereof, and clustering device |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JP2010198518A JP2010198518A (en) | 2010-09-09 |
| JP5255484B2 true JP5255484B2 (en) | 2013-08-07 |
Family
ID=42823154
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2009045015A Expired - Fee Related JP5255484B2 (en) | 2009-02-27 | 2009-02-27 | Clustering distance learning device and program thereof, and clustering device |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP5255484B2 (en) |
Families Citing this family (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP5591772B2 (en) * | 2011-08-25 | 2014-09-17 | 日本電信電話株式会社 | Context-dependent estimation device, utterance clustering device, method, and program |
| JP6691646B2 (en) * | 2018-07-10 | 2020-05-13 | データ・ケーキベーカ株式会社 | Data analysis method, system, and program for generating a matching mind map |
| CN111353516B (en) * | 2018-12-21 | 2024-10-15 | 华为技术有限公司 | A sample classification method and model updating method for online learning |
Family Cites Families (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2008071207A (en) * | 2006-09-14 | 2008-03-27 | Murata Mach Ltd | Method and apparatus for estimating optimal value and program for optimal value estimation apparatus |
-
2009
- 2009-02-27 JP JP2009045015A patent/JP5255484B2/en not_active Expired - Fee Related
Also Published As
| Publication number | Publication date |
|---|---|
| JP2010198518A (en) | 2010-09-09 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US12106223B2 (en) | Data valuation using reinforcement learning | |
| JP6482481B2 (en) | Binary classification learning apparatus, binary classification apparatus, method, and program | |
| JP6212216B2 (en) | Weight generation in machine learning | |
| JP6212217B2 (en) | Weight generation in machine learning | |
| US20210182602A1 (en) | Flexible imputation of missing data | |
| JP2012058972A (en) | Evaluation prediction device, evaluation prediction method, and program | |
| KR102748213B1 (en) | Reinforcement learning based on locally interpretable models | |
| CN103365829A (en) | Information processing apparatus, information processing method, and program | |
| JP2019096313A (en) | Information processing method and information processing apparatus | |
| JP2012038244A (en) | Learning model creation program, image identification information giving program, learning model creation device, image identification information giving device | |
| CN110033094A (en) | A kind of model training method and device based on disturbance sample | |
| Wang et al. | A new LSTM-based gene expression prediction model: L-GEPM | |
| Cholewa et al. | Estimation of the number of states for gesture recognition with Hidden Markov Models based on the number of critical points in time sequence | |
| JP5704692B2 (en) | Pattern classification device learning device and computer program therefor | |
| JP5255484B2 (en) | Clustering distance learning device and program thereof, and clustering device | |
| US20220327394A1 (en) | Learning support apparatus, learning support methods, and computer-readable recording medium | |
| Chen et al. | Unbiased boosting estimation for censored survival data | |
| WO2022190301A1 (en) | Learning device, learning method, and computer-readable medium | |
| JP2020021343A (en) | Analysis apparatus, analysis method and program | |
| JP2019159918A (en) | Clustering program, clustering method, and clustering apparatus | |
| CN120523955B (en) | Pseudo-label-based intent recognition model training method, intent recognition method, and apparatus | |
| CN107636678A (en) | Method and apparatus for the attribute of prognostic chart picture sample | |
| JP5175585B2 (en) | Document processing apparatus, electronic medical chart apparatus, and document processing program | |
| CN114595683A (en) | Evaluation object extraction method, apparatus, device, storage medium image, and program product | |
| JP7700542B2 (en) | Information processing device, information processing method, and program |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20110322 |
|
| 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: 20130326 |
|
| A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20130419 |
|
| R150 | Certificate of patent or registration of utility model |
Ref document number: 5255484 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20160426 Year of fee payment: 3 |
|
| R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
| R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
| R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
| R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
| R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
| R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
| LAPS | Cancellation because of no payment of annual fees |