WO2019194285A1 - 計算装置、計算方法および計算プログラム - Google Patents

計算装置、計算方法および計算プログラム Download PDF

Info

Publication number
WO2019194285A1
WO2019194285A1 PCT/JP2019/015007 JP2019015007W WO2019194285A1 WO 2019194285 A1 WO2019194285 A1 WO 2019194285A1 JP 2019015007 W JP2019015007 W JP 2019015007W WO 2019194285 A1 WO2019194285 A1 WO 2019194285A1
Authority
WO
WIPO (PCT)
Prior art keywords
limit value
calculation
parameter
data points
hyperplane
Prior art date
Application number
PCT/JP2019/015007
Other languages
English (en)
French (fr)
Inventor
靖宏 藤原
Original Assignee
日本電信電話株式会社
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by 日本電信電話株式会社 filed Critical 日本電信電話株式会社
Publication of WO2019194285A1 publication Critical patent/WO2019194285A1/ja

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning
    • G06N20/10Machine learning using kernel methods, e.g. support vector machines [SVM]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N99/00Subject matter not provided for in other groups of this subclass

Definitions

  • the present invention relates to a calculation device, a calculation method, and a calculation program.
  • Non-Patent Document 1 there is a known one-class support vector machine that is based on a support vector machine (SVM) and determines a data point that is not classified into the class specified by the hyperplane as an outlier.
  • SVM support vector machine
  • the conventional One-class support vector machine has a problem of high calculation cost. For example, when the number of data points is N, it is necessary to solve a quadratic programming problem having N constraints in order to obtain a hyperplane. At this time, the amount of calculation increases in proportion to the square of the number of data points.
  • the computing device of the present invention provides a predetermined parameter based on a ratio parameter indicating a lower limit value of a support vector ratio or an upper limit value of an outlier ratio used in a one-class support vector machine for each data point included in the matrix.
  • a hyperplane calculation unit that calculates a hyperplane of a One-class support vector machine based on the data points included in the set and the ratio parameter.
  • the calculation cost of the One-class support vector machine can be reduced.
  • FIG. 1 is a diagram illustrating an example of a configuration of a computing device according to the first embodiment.
  • FIG. 2 is a diagram showing Definition 1.
  • FIG. 3 is a diagram showing definition 2.
  • FIG. 4 is a diagram showing Lemma 1.
  • FIG. 5 is a diagram showing Lemma 2.
  • FIG. 6 is a diagram showing definition 3.
  • FIG. 7 is a diagram showing Lemma 3.
  • FIG. 8 is a diagram showing the definition 4.
  • FIG. 9 is a diagram showing Lemma 4.
  • FIG. 10 is a diagram illustrating Theorem 1 and Theorem 2.
  • FIG. 11 is a diagram showing Lemma 5.
  • FIG. 12 is a diagram illustrating an example of a calculation processing algorithm according to the first embodiment.
  • FIG. 13 is a flowchart showing a flow of calculation processing according to the first embodiment.
  • FIG. 14 is a diagram illustrating an example of a computer that executes a calculation program according to the embodiment.
  • the column vector of the matrix X is assumed to be standardized in order to match the value range. If w, ⁇ i , and ⁇ are m-dimensional vectors, slack variables, and offsets, respectively, the data points can be divided by solving the linear programming problem expressed by the following equations (1) and (2).
  • Equation (2) ⁇ is a kernel map that maps data points to X ⁇ F and a high-dimensional feature space.
  • is a kernel map that maps data points to X ⁇ F and a high-dimensional feature space.
  • is a vector whose i-th element ⁇ i corresponds to a Lagrange multiplier for data point x i
  • K (x i , x j ) is a Gaussian kernel e ⁇
  • is the lower limit value of the support vector ratio or the upper limit value of the outlier ratio.
  • FIG. 1 is a diagram illustrating an example of a configuration of a computing device according to the first embodiment.
  • the computing device 10 includes an initialization unit 11, a sparse vector calculation unit 12, a data point selection unit 13, a parameter determination unit 14, a priority calculation unit 15, a parameter calculation unit 16, a set setting unit 17, The hyperplane calculation unit 18, parameter update unit 19, confirmation unit 20, set update unit 21, and overall parameter calculation unit 22 are included.
  • the initialization unit 11 initializes each parameter.
  • the sparse vector calculation unit 12 calculates the sparse vector by shifting the value of the element of the column vector using the mode value for each column vector of the matrix.
  • the data point selection unit 13 selects a data point to be added to the set.
  • the parameter determination unit 14 determines the parameter of the selected data point.
  • the priority calculation unit 15 determines the priority when selecting a data point.
  • the parameter calculation unit 16 is a predetermined parameter based on a ratio parameter indicating the lower limit value of the support vector ratio or the upper limit value of the outlier ratio used in the One-class support vector machine (hereinafter referred to as a parameter).
  • a ratio parameter indicating the lower limit value of the support vector ratio or the upper limit value of the outlier ratio used in the One-class support vector machine (hereinafter referred to as a parameter).
  • the upper and lower limits of the predetermined parameter are calculated.
  • the predetermined parameter may be the parameter z described above.
  • the set setting unit 17 sets a set of data points whose predetermined parameters are not more than the upper limit value and not less than the lower limit value among the data points. Further, the set setting unit 17 can include, among the data points, data points whose lower limit value and upper limit value satisfy a predetermined condition in the set.
  • the hyperplane calculation unit 18 calculates the hyperplane of the One-class support vector machine based on the data points and ratio parameters included in the set. Note that the hyperplane calculation unit 18 can perform calculation by applying a solver.
  • the parameter update unit 19 updates the upper limit value and lower limit value of the parameter z for the data point. Further, the confirmation unit 20 determines whether or not the data points included in the matrix and not included in the set satisfy a predetermined condition set based on the hyperplane calculated by the hyperplane calculation unit 18. To check. Then, the set update unit 21 adds the data points that are confirmed to satisfy the predetermined condition by the check unit 20 to the set.
  • the set set by the set setting unit 17 based on the upper limit value and the lower limit value of the parameter z calculated by the parameter calculation unit 16 is a hyperplane calculation target.
  • the set set by the set setting unit 17 is obtained by pruning a set of all given data points.
  • the confirmation by the confirmation unit 20 confirms whether or not the calculated hyperplane is optimal, the set can be optimized by repeating the processing.
  • the set setting unit 17 sets the set S and the set P using the definition 1 shown in FIG. 2 based on the upper limit value and the lower limit value of the parameter z calculated by the parameter calculation unit 16.
  • FIG. 2 is a diagram showing Definition 1.
  • the set S is a set of hyperplane calculation targets.
  • the condition of definition 1 is an example of the first condition.
  • FIG. 3 is a diagram showing definition 3.
  • the set update unit 21 moves the data point from the set P to the set S when the hyperplane is not optimal. Therefore, the set S monotonously increases and the set P monotonously decreases. Further, from definition 1 and definition 2, when there are an upper limit value and a lower limit value, it can be said that the set update unit 21 can calculate the set S and the set P at a cost of O (n).
  • the set S and the set P have the property shown in Lemma 1 in FIG.
  • FIG. 4 is a diagram showing Lemma 1.
  • the checking unit 20 checks the optimality of the hyperplane by the method shown in Lemma 2 in FIG.
  • FIG. 5 is a diagram showing Lemma 5.
  • the confirmation unit 20 can confirm the optimality at the cost of O (n).
  • the condition of Lemma 2 is an example of the second condition.
  • the parameter calculation unit 16 describes the case where the upper limit value and the lower limit value are calculated for the RBF kernel. However, the parameter calculation unit 16 calculates the upper limit value and the lower limit value for other kernels. May be.
  • the parameter calculation unit 16 can calculate the upper limit value and the lower limit value using the sparse vector calculated by the sparse vector calculation unit 12.
  • the sparse vector calculation unit 12 sets ⁇ j as the mode value in the j-th column vector of the matrix X
  • the sparse vector calculation unit 12 can replace the value of the element whose value is the mode value with 0 by shifting the value of the element. Note that x ⁇ indicates that ⁇ exists immediately above x.
  • the parameter calculation unit 16 calculates the upper limit value and the lower limit value of the parameter z by the method shown in Definition 3 in FIG.
  • ⁇ i 1 / n ⁇ is a set of outliers.
  • the parameter calculation unit 16 by updating the sequentially set O whenever computing the Lagrange multiplier can be efficiently determine the score o i.
  • the parameter calculation unit 16 can also calculate the kernel function at high speed from the sparse vector x ⁇ i . Furthermore, from definition 3, a method of calculating the Lagrange multiplier ⁇ i for the data point x i will be described later. For definition 3, the properties shown in Lemma 3 in FIG. 7 hold.
  • FIG. 7 is a diagram showing Lemma 3.
  • the data point selection unit 13 selects a data point included in the support vector set A.
  • the parameter determination unit 14 randomly determines the Lagrange multiplier ⁇ i in the range of 0 ⁇ i ⁇ 1 / n ⁇ .
  • the priority p i is calculated from the Lagrange multiplier and the kernel function, as is the parameter z. Therefore, the priority p i is expected to have a high value if the data point x i is classified as an outlier by the hyperplane. Therefore, the data point selection unit 13 can effectively obtain the initial value of the Lagrange multiplier ⁇ i by using the priority p i . Further, with respect to the priority p i , the property of Lemma 4 shown in FIG. 9 is established. From Lemma 4, it can be said that the priority pi of each data point can be calculated at a calculation cost of O (m) in the process of adding the data point to the set A.
  • FIG. 10 is a diagram illustrating Theorem 1 and Theorem 2.
  • the parameter calculation unit 16 can calculate an upper limit value and a lower limit value for a linear kernel or a polynomial kernel.
  • the parameter calculation unit 16 calculates the upper limit value and the lower limit value using the properties shown in Lemma 5 of FIG. 11 regarding these kernel functions.
  • FIG. 11 is a diagram showing Lemma 5.
  • FIG. 12 is a diagram illustrating an example of a calculation processing algorithm according to the first embodiment.
  • the calculation apparatus 10 calculates the mode value ⁇ i from the i-th column vector to obtain a vector x ⁇ i (2-6th line).
  • the computing device 10 selects the data point with the highest priority if the set A is not an empty set, otherwise the node having a high norm is the outlier. Since the possibility is high, the node having the highest norm is selected (line 8-11).
  • the computing device 10 randomly determines the Lagrangian multiplier of the selected data point in a range of 0 ⁇ i ⁇ 1 / n ⁇ , and if the total of the Lagrange multipliers exceeds 1, it is reset so that it becomes 1.
  • Set lines 13-15.
  • the calculation device 10 calculates the upper limit value and the lower limit value of the parameter z for the data point, and obtains the set S and the set P (lines 19-21). Furthermore, the calculation apparatus 10 applies a solver to the set S to obtain an optimal hyperplane, and updates the upper limit value and the lower limit value (lines 23-25).
  • the computing device 10 confirms the optimality of the hyperplane using Lemma 2, and updates the set S and the set P from the definition 2 (lines 26-27).
  • the calculation apparatus 10 repeats these processes until an optimal hyperplane is obtained (line 28).
  • various solvers can be used.
  • FIG. 13 is a flowchart showing a flow of calculation processing according to the first embodiment. As shown in FIG. 13, first, the matrix X and the parameter ⁇ are input to the computing device 10 (step S101). Then, the computing device 10 initializes each parameter (step S102).
  • the calculation device 10 calculates the mode value for each column vector of the matrix X (steps S103 to S106). Then, the calculation device 10 calculates the value x ⁇ i of each element of the sparse matrix using the mode value (steps S107 to S109).
  • step S110 When the sum of the Lagrange multipliers is 1 or the set A and the set X are equal (step S110, yes), the computing device 10 advances the process to step S121. On the other hand, if the sum of the Lagrange multipliers is not 1 or the set A and the set X are not equal (step S110, no), the computing device 10 advances the process to step S111.
  • step S111 the computing device 10 selects the data point with the highest priority if the set A is not an empty set (step S111, yes) (step S112), otherwise (step S111, no), The node with the highest norm is selected (step S113). Then, the computing device 10 adds x i to the set A and sets a Lagrange multiplier ⁇ i between 0 and 1 / n ⁇ (step S114).
  • step S115 when the total Lagrange multiplier exceeds 1 (step S115, yes), the calculation apparatus 10 sets ⁇ i to a value obtained by subtracting the total value of the Lagrange multipliers from 1 (step S116). On the other hand, when the total Lagrange multiplier does not exceed 1 (step S115, no), the computing device 10 adds the set Lagrange multiplier to the total value (step S117).
  • the computing device 10 calculates the priority for each x i (steps S118-S120), and advances the process to step S110. Even when the processing proceeds from step S110 to step S121, the computing device 10 calculates the priority for each x i (steps S121 to S123).
  • the calculation device 10 calculates the upper limit value and the lower limit value of the parameter z (step S124), and calculates the set S and the set P (step S125).
  • the calculation apparatus 10 advances the processing to step S133.
  • the calculation apparatus 10 advances the process to step S127. Further, the calculation apparatus 10 calculates ⁇ and ⁇ as parameters of the entire SVM (step S133) and outputs them (step S134).
  • step S127 the computing device 10 applies a solver to the set S (step S127), and updates the upper limit value and the lower limit value of the parameter z (steps S127 to S130). Then, the computing device 10 confirms the hyperplane optimality (step S131), updates the set S and the set P (step S132), and advances the processing to step S126.
  • the parameter calculation unit 16 sets an upper limit of a predetermined parameter based on a ratio parameter indicating the lower limit value of the support vector ratio or the upper limit value of the outlier ratio used in the One-class support vector machine for each data point included in the matrix. Calculate the value and the lower limit.
  • the set setting unit 17 sets a set of data points whose predetermined parameters are not more than the upper limit value and not less than the lower limit value among the data points.
  • the hyperplane calculation unit 18 calculates the hyperplane of the One-class support vector machine based on the data points and ratio parameters included in the set. Thus, since the computing device 10 of this embodiment performs branching of data points before calculating the hyperplane, the calculation cost of the One-class support vector machine can be reduced.
  • the set setting unit 17 includes, among the data points, data points whose lower limit value and upper limit value satisfy the first condition in the set. Therefore, since the calculation apparatus 10 can determine whether or not to perform branch hunting from the upper limit value and the lower limit value of the parameter z without calculating the parameter z, the calculation cost can be further reduced.
  • the confirmation unit 20 determines whether the data points included in the matrix and not included in the set satisfy the second condition set based on the hyperplane calculated by the hyperplane calculation unit 18. Confirm.
  • the set update unit 21 adds data points that are confirmed by the check unit 20 to satisfy the second condition to the set.
  • the sparse vector calculation unit 12 calculates the sparse vector by shifting the element value of the column vector using the mode value for each column vector of the matrix.
  • the parameter calculation unit 16 calculates an upper limit value and a lower limit value for each data point of the sparse matrix.
  • the set setting unit 17 sets a set based on sparse matrix data points.
  • the calculation device 10 can further reduce the calculation cost by converting each column vector of the matrix into a sparse vector in advance.
  • each component of each illustrated device is functionally conceptual and does not necessarily need to be physically configured as illustrated.
  • the specific form of distribution / integration of each device is not limited to that shown in the figure, and all or a part thereof may be functionally or physically distributed or arbitrarily distributed in arbitrary units according to various loads or usage conditions.
  • all or any part of each processing function performed by each device is realized by a CPU (Central Processing Unit) and a program analyzed and executed by the CPU, or hardware by wired logic.
  • CPU Central Processing Unit
  • the calculation apparatus 10 can be implemented by installing a calculation program for executing the above calculation as package software or online software on a desired computer.
  • the information processing apparatus can be caused to function as the calculation apparatus 10 by causing the information processing apparatus to execute the above calculation program.
  • the information processing apparatus referred to here includes a desktop or notebook personal computer.
  • the information processing apparatus includes mobile communication terminals such as smartphones, mobile phones and PHS (Personal Handyphone System), and slate terminals such as PDA (Personal Digital Assistant).
  • the computing device 10 can be implemented as a computing server device that uses a terminal device used by a user as a client and provides the client with services relating to the above calculation.
  • the calculation server device is implemented as a server device that provides a calculation service that receives a multidimensional matrix as an input and outputs a dimension-reduced matrix.
  • the calculation server device may be implemented as a Web server, or may be implemented as a cloud that provides a service related to the above calculation by outsourcing.
  • FIG. 14 is a diagram illustrating an example of a computer that executes a calculation program.
  • the computer 1000 includes a memory 1010 and a CPU 1020, for example.
  • the computer 1000 also includes a hard disk drive interface 1030, a disk drive interface 1040, a serial port interface 1050, a video adapter 1060, and a network interface 1070. These units are connected by a bus 1080.
  • the memory 1010 includes a ROM (Read Only Memory) 1011 and a RAM (Random Access Memory) 1012.
  • the ROM 1011 stores a boot program such as BIOS (Basic Input Output System).
  • BIOS Basic Input Output System
  • the hard disk drive interface 1030 is connected to the hard disk drive 1090.
  • the disk drive interface 1040 is connected to the disk drive 1100.
  • a removable storage medium such as a magnetic disk or an optical disk is inserted into the disk drive 1100.
  • the serial port interface 1050 is connected to a mouse 1110 and a keyboard 1120, for example.
  • the video adapter 1060 is connected to the display 1130, for example.
  • the hard disk drive 1090 stores, for example, an OS (Operating System) 1091, an application program 1092, a program module 1093, and program data 1094. That is, a program that defines each process of the computing device 10 is implemented as a program module 1093 in which a code executable by a computer is described.
  • the program module 1093 is stored in the hard disk drive 1090, for example.
  • a program module 1093 for executing processing similar to the functional configuration in the computing device 10 is stored in the hard disk drive 1090.
  • the hard disk drive 1090 may be replaced by an SSD.
  • the setting data used in the processing of the above-described embodiment is stored as program data 1094 in, for example, the memory 1010 or the hard disk drive 1090. Then, the CPU 1020 reads the program module 1093 and the program data 1094 stored in the memory 1010 and the hard disk drive 1090 to the RAM 1012 and executes them as necessary.
  • the program module 1093 and the program data 1094 are not limited to being stored in the hard disk drive 1090, but may be stored in, for example, a removable storage medium and read by the CPU 1020 via the disk drive 1100 or the like. Alternatively, the program module 1093 and the program data 1094 may be stored in another computer connected via a network (LAN (Local Area Network), WAN (Wide Area Network), etc.). The program module 1093 and the program data 1094 may be read by the CPU 1020 from another computer via the network interface 1070.
  • LAN Local Area Network
  • WAN Wide Area Network

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • General Physics & Mathematics (AREA)
  • Mathematical Physics (AREA)
  • Evolutionary Computation (AREA)
  • Medical Informatics (AREA)
  • Data Mining & Analysis (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Artificial Intelligence (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Complex Calculations (AREA)

Abstract

パラメータ計算部(16)は、行列に含まれるデータポイントごとに、One-class サポートベクターマシンで用いられるサポートベクトルの割合の下限値または外れ値の割合の上限値を示す割合パラメータに基づく所定のパラメータの上限値および下限値を計算する。集合設定部(17)は、データポイントのうち、所定のパラメータが、上限値以下かつ下限値以上であるデータポイントの集合を設定する。超平面計算部(18)は、集合に含まれるデータポイントおよび割合パラメータを基に、One-class サポートベクターマシンの超平面を計算する。

Description

計算装置、計算方法および計算プログラム
 本発明は、計算装置、計算方法および計算プログラムに関する。
 従来、サポートベクターマシン(SVM:Support Vector Machine)に基づく手法であって、超平面によって指定されたクラスに分類されないデータポイントを外れ値と判定する手法であるOne-class サポートベクターマシンが知られている(例えば、非特許文献1を参照)。
Bernhard Scholkopf and John C. Platt and John Shawe-Taylor and Alexander J. Smola and Robert C. Williamson, Estimating the Support of a High-Dimensional Distribution, Neural Computation, 13(7):1443-1471, 2001.
 しかしながら、従来のOne-class サポートベクターマシンには、計算コストが高いという問題がある。例えば、データポイントの数がNである場合、超平面を求めるためにN個の制約を持つ2次計画問題を解く必要がある。このとき、計算量は、データポイントの数の2乗に比例して増加する。
 本発明の計算装置は、行列に含まれるデータポイントごとに、One-class サポートベクターマシンで用いられるサポートベクトルの割合の下限値または外れ値の割合の上限値を示す割合パラメータに基づく所定のパラメータについて、該所定のパラメータの上限値および下限値を計算するパラメータ計算部と、前記データポイントのうち、前記所定のパラメータが、前記上限値以下かつ前記下限値以上であるデータポイントの集合を設定する集合設定部と、前記集合に含まれるデータポイントおよび前記割合パラメータを基に、One-class サポートベクターマシンの超平面を計算する超平面計算部と、を有することを特徴とする。
 本発明によれば、One-class サポートベクターマシンの計算コストを低減させることができる。
図1は、第1の実施形態に係る計算装置の構成の一例を示す図である。 図2は、定義1を示す図である。 図3は、定義2を示す図である。 図4は、補題1を示す図である。 図5は、補題2を示す図である。 図6は、定義3を示す図である。 図7は、補題3を示す図である。 図8は、定義4を示す図である。 図9は、補題4を示す図である。 図10は、定理1および定理2を示す図である。 図11は、補題5を示す図である。 図12は、第1の実施形態に係る計算処理のアルゴリズムの一例を示す図である。 図13は、第1の実施形態に係る計算処理の流れを示すフローチャートである。 図14は、実施形態に係る計算プログラムを実行するコンピュータの一例を示す図である。
 以下に、本願に係る計算装置、計算方法および計算プログラムの実施形態を図面に基づいて詳細に説明する。なお、本発明は、以下に説明する実施形態により限定されるものではない。
[従来のOne-class SVM]
 まず、従来のOne-class SVMについて説明する。ここで、One-class SVMでは、ベクトルxi=(x[1],x[2],・・・,x[m])∈Xがm次元空間のi番目のデータポイントに対応し、行列Xのi番目の行ベクトルに対応している。ここで、行列Xの列ベクトルは、値のレンジを合わせるために標準化されているものとする。w、ξ、ρをそれぞれm次元のベクトル、スラック変数、オフセットとすると、データポイントは以下の式(1)および式(2)で示される線形計画問題を解くことで分けることができる。
Figure JPOXMLDOC01-appb-M000001
 式(2)において、ΦはデータポイントをX→Fと高次元の特徴量空間にマッピングするカーネルマップである。ここで、ラグランジュ乗数を導入することで、以下の式(3)および式(4)に示す双対問題が得られる。
Figure JPOXMLDOC01-appb-M000002
 ここで、αは、そのi番目の要素αがデータポイントxにのラグランジュ乗数に対応するベクトルとし、K(x,x)は、ガウスカーネルe-γ||xi-xj||^2などのカーネル関数とする。また、式(3)において、α>0またはα=1/nνであるようなデータポイントは、それぞれサポートベクトルまたは外れ値と呼ばれる。ここで、νは、サポートベクトルの割合の下限値または外れ値の割合の上限値である。また、z=Σi=1 αK(x,x)-ρをデータポイントxの所定のパラメータとすると、決定関数は式(5)のように与えられる。
Figure JPOXMLDOC01-appb-M000003
 双対問題は凸であるため、決定関数によれば最適な超平面を計算することができる。つまり、ソルバを適用することで、ベクトルαの最適解が得られる。また、オフセットρは、ベクトルαから、ρ=Σi=1 αK(x,x)と計算される。ここで、データポイントxに対しては、0<α<1/nνであるとする。
[第1の実施形態]
 One-class SVMでは、データポイントの数がnである場合、n個の制約を持つ線形計画問題を解く必要があるため、nが増加するに従って、計算コストが非常に高くなる。そこで、本実施形態の計算装置は、One-class SVMの計算コストを低減させるため、データポイントの枝狩りを行う。
 図1を用いて、第1の実施形態の構成について説明する。図1は、第1の実施形態に係る計算装置の構成の一例を示す図である。図1に示すように、計算装置10は、初期化部11、疎ベクトル計算部12、データポイント選択部13、パラメータ決定部14、優先度計算部15、パラメータ計算部16、集合設定部17、超平面計算部18、パラメータ更新部19、確認部20、集合更新部21および全体パラメータ計算部22を有する。
 初期化部11は、各パラメータの初期化を行う。疎ベクトル計算部12は、行列の列ベクトルごとの最頻値を用いて、当該列ベクトルの要素の値のシフトを行うことによって、疎ベクトルを計算する。データポイント選択部13は、集合に加えるデータポイントを選択する。パラメータ決定部14は、選択されたデータポイントのパラメータを決定する。優先度計算部15は、データポイントを選択するときの優先度を決定する。
 パラメータ計算部16は、行列に含まれるデータポイントごとに、One-class サポートベクターマシンで用いられるサポートベクトルの割合の下限値または外れ値の割合の上限値を示す割合パラメータに基づく所定のパラメータ(以降、パラメータz)について、該所定のパラメータの上限値および下限値を計算する。なお、所定のパラメータは、前述のパラメータzであってよい。
 集合設定部17は、データポイントのうち、所定のパラメータが、上限値以下かつ下限値以上であるデータポイントの集合を設定する。また、集合設定部17は、データポイントのうち、下限値および上限値が所定の条件を満たすデータポイントを、集合に含めることができる。
 超平面計算部18は、集合に含まれるデータポイントおよび割合パラメータを基に、One-class サポートベクターマシンの超平面を計算する。なお、超平面計算部18は、ソルバを適用することによって計算を行うことができる。
 パラメータ更新部19は、データポイントに対するパラメータzの上限値と下限値を更新する。また、確認部20は、行列に含まれるデータポイントであって、集合に含まれないデータポイントが、超平面計算部18によって計算された超平面を基に設定された所定の条件を満たすか否かを確認する。そして、集合更新部21は、確認部20によって所定の条件を満たすことが確認されたデータポイントを集合に追加する。
 本実施形態では、パラメータ計算部16によって計算されたパラメータzの上限値および下限値に基づいて、集合設定部17が設定した集合を超平面の計算対象としている。このとき、集合設定部17が設定する集合は、与えられた全てのデータポイントの集合を枝狩りして得られるものであるといえる。さらに、確認部20による確認により、計算された超平面が最適なものであるか否かが確認されるため、処理を繰り返すことで、集合を最適化してくことができる。
 集合設定部17は、パラメータ計算部16によって計算されたパラメータzの上限値および下限値を基に、図2に示す定義1を用いて集合Sおよび集合Pを設定する。図2は、定義1を示す図である。なお、集合Sは、超平面の計算対象の集合である。また、定義1の条件は、第1の条件の一例である。
 さらに、確認部20による確認の結果、所定の条件を満たさないことが確認された場合、すなわち、超平面が最適でない場合、集合更新部21は、図3に示す定義2を用いて集合Sおよび集合Pを更新する。図3は、定義3を示す図である。
 図3に示すように、集合更新部21は、超平面が最適でなかった場合、データポイントを集合Pから集合Sへ移動させる。そのため、集合Sは単調増加し、集合Pは単調減少する。また、定義1および定義2から、上限値と下限値がある場合、集合更新部21は、集合Sおよび集合PをO(n)のコストで計算することができることがいえる。
 ここで、集合Sおよび集合Pには、図4の補題1に示す性質がある。図4は、補題1を示す図である。確認部20は、補題1に示す性質を利用して、図5の補題2に示す方法で、超平面の最適性を確認する。図5は、補題5を示す図である。補題5に示す方法によれば、上限値と下限値がある場合、確認部20は、O(n)のコストで最適性を確認することができる。なお、補題2の条件は、第2の条件の一例である。
 ここで、パラメータ計算部16によるパラメータzの上限値および下限値の計算方法について説明する。本実施形態では、パラメータ計算部16は、RBFカーネルに対して上限値および下限値を計算する場合について説明するが、パラメータ計算部16は、他のカーネルに対して上限値および下限値を計算してもよい。
 また、パラメータ計算部16は、疎ベクトル計算部12によって計算された疎ベクトルを使って上限値および下限値を計算することができる。疎ベクトル計算部12は、σを行列Xのj番目の列ベクトルにおける最頻値としたとき、疎ベクトルの要素x [j]を、x [j]=x[j]-σと計算する。このように、疎ベクトル計算部12は、要素の値をシフトすることで、値が最頻値である要素の値を0に置き換えることができる。なお、x^は、xの直上に^があることを示す。
 パラメータ計算部16は、図6の定義3に示す方法でパラメータzの上限値および下限値を計算する。図6は、定義3を示す図である。なお、集合O={x|α=1/nν}を外れ値の集合とする。
 定義3において、パラメータ計算部16は、ラグランジュ乗数を計算するたびに逐次的に集合Oを更新することで、効率的にスコアoを求めることができる。また式(17)と(18)において、α=0であれば、カーネル関数を計算する必要はない。さらに、パラメータ計算部16は、疎な構造を持つベクトルx^に対してソルバを適用する前に、ノルム||x^||を計算することができる。そのため、パラメータ計算部16は、高速に上限値と下限値を計算することができる。
 なお、パラメータ計算部16は、カーネル関数についても、疎なベクトルx^から高速に計算することができる。さらに定義3から、データポイントxに対するラグランジュ乗数αの計算方法については後述する。また、定義3に対しては、図7の補題3に示す性質が成り立つ。図7は、補題3を示す図である。
 パラメータ計算部16による処理が行われる前に、データポイント選択部13は、サポートベクトルの集合Aに含まれるデータポイントを選択する。その際、優先度計算部15は、図8の定義4に示す方法でデータポイントの優先度を計算する。そして、データポイント選択部13は、優先度の高いデータポイントを、Σi=1 αi=1となるまで集合Aに追加していく。このとき、パラメータ決定部14は、ラグランジュ乗数αを、0<α<1/nνの範囲でランダムに決定する。
 定義4に示すように、パラメータzと同様に、優先度pは、ラグランジュ乗数とカーネル関数とから計算される。そのため、優先度pは、データポイントxが超平面により外れ値と分類されるなら高い値を持つことが期待される。そのため、データポイント選択部13は、優先度pを用いることでラグランジュ乗数αの初期値を効果的に求めることができる。また、優先度pについては、図9に示す補題4の性質が成り立つ。補題4から、各データポイントの優先度piは、データポイントを集合Aに追加する過程において、O(m)の計算コストで計算可能であることがいえる。
 ここで、計算装置10による学習結果については、図10の定理1に示す性質が成り立つ。また、計算装置10による計算処理の計算コストについては、図10の定理2に示す性質が成り立つ。図10は、定理1および定理2を示す図である。
 また、パラメータ計算部16は、RBFカーネル以外にも、線形カーネルや多項式カーネルに対して上限値および下限値を計算することができる。パラメータ計算部16は、これらのカーネル関数に関する図11の補題5に示す性質を用いて上限値および下限値を計算する。図11は、補題5を示す図である。
[第1の実施形態のアルゴリズム]
 図12は、第1の実施形態に係る計算処理のアルゴリズムの一例を示す図である。図12に示すように、計算装置10は、i番目の列ベクトルから最頻値σiを計算し、ベクトルx^を求める(2-6行目)。次に、計算装置10は、ラグランジュ乗数の初期値を求めるため、もし集合Aが空集合でなければ、優先度が最も高いデータポイントを選択し、そうでなければノルムが高いノードが外れ値の可能性が高いため、ノルムの最も高いノードを選択する(8-11行目)。
 そして、計算装置10は、選択されたデータポイントのラグランジュ乗数をランダムに0<α<1/nνの範囲で決定し、もしラグランジュ乗数の合計が1を超えるようなら、1になるように再設定する(13-15行目)。そして、計算装置10は、定義4と補題4を用いて優先度を求める(16-17行目)。ここでもし集合A=集合Xであれば、すべてのデータポイントのラグランジュ乗数は、α=1/nとする。
 そして、計算装置10は、データポイントに対してパラメータzの上限値と下限値を計算し、集合Sと集合Pを求める(19-21行目)。さらに、計算装置10は、最適な超平面を求めるために、集合Sに対してソルバを適用し、上限値と下限値を更新する(23-25行目)。
 その後、計算装置10は、補題2を用いて超平面の最適性を確認し、定義2から集合Sと集合Pを更新する(26-27行目)。計算装置10は、最適な超平面が得られるまでこれらの処理を繰り返す(28行目)。また、ここで説明したアルゴリズムはソルバとは独立であるため、様々なソルバを用いることができる。
[第1の実施形態の処理の流れ]
 図13は、第1の実施形態に係る計算処理の流れを示すフローチャートである。図13に示すように、まず、計算装置10には、行列Xおよびパラメータνが入力される(ステップS101)。そして、計算装置10は、各パラメータを初期化する(ステップS102)。
 ここで、計算装置10は、行列Xの各列ベクトルについて、最頻値を計算する(ステップS103-S106)。そして、計算装置10は、最頻値を用いて、疎行列の各要素の値x^を計算する(ステップS107-S109)。
 ラグランジュ乗数の合計が1であるか、集合Aと集合Xが等しい場合(ステップS110、yes)、計算装置10は、処理をステップS121へ進める。一方、ラグランジュ乗数の合計が1でないか、または集合Aと集合Xが等しくない場合(ステップS110、no)、計算装置10は、処理をステップS111へ進める。
 ステップS111において、計算装置10は、集合Aが空集合でなければ(ステップS111、yes)、優先度が最も高いデータポイントを選択し(ステップS112)、そうでなければ(ステップS111、no)、ノルムの最も高いノードを選択する(ステップS113)。そして、計算装置10は、xを集合Aに追加し、ラグランジュ乗数αを0~1/nνの間で設定する(ステップS114)。
 さらに、ラグランジュ乗数の合計が1を超える場合(ステップS115、yes)、計算装置10は、ラグランジュ乗数の合計値を1から引いた値をαとする(ステップS116)。一方、ラグランジュ乗数の合計が1を超えない場合(ステップS115、no)、計算装置10は、設定したラグランジュ乗数を合計値に足す(ステップS117)。
 そして、計算装置10は、xごとに優先度を計算し(ステップS118-S120)、処理をステップS110へ進める。ステップS110からステップS121へ処理を進めた場合も、計算装置10は、xごとに優先度を計算する(ステップS121-S123)。
 そして、計算装置10は、パラメータzの上限値および下限値を計算し(ステップS124)、集合Sおよび集合Pを計算する(ステップS125)。ここで、計算装置10は、ソルバを適用して計算した超平面が最適である場合(ステップS126、yes)、処理をステップS133へ進める。一方、計算装置10は、ソルバを適用して計算した超平面が最適でない場合(ステップS126、no)、処理をステップS127へ進める。また、計算装置10は、SVM全体のパラメータとしてρとαを計算し(ステップS133)、出力する(ステップS134)。
 ステップS127では、計算装置10は、集合Sに対してソルバを適用し(ステップS127)、パラメータzの上限値および下限値を更新する(ステップS127-S130)。そして、計算装置10は、超平面の最適性を確認し(ステップS131)、集合Sおよび集合Pを更新し(ステップS132)、処理をステップS126へ進める。
[第1の実施形態の効果]
 パラメータ計算部16は、行列に含まれるデータポイントごとに、One-class サポートベクターマシンで用いられるサポートベクトルの割合の下限値または外れ値の割合の上限値を示す割合パラメータに基づく所定のパラメータの上限値および下限値を計算する。集合設定部17は、データポイントのうち、所定のパラメータが、上限値以下かつ下限値以上であるデータポイントの集合を設定する。超平面計算部18は、集合に含まれるデータポイントおよび割合パラメータを基に、One-class サポートベクターマシンの超平面を計算する。このように、本実施形態の計算装置10は、超平面を計算する前にデータポイントの枝狩りを行うため、One-class サポートベクターマシンの計算コストを低減させることができる。
 集合設定部17は、データポイントのうち、下限値および上限値が第1の条件を満たすデータポイントを、集合に含める。これにより、計算装置10は、パラメータzを計算することなく、パラメータzの上限値および下限値から枝狩りをするか否かを判断できるため、さらに計算コストを低減させることができる。
 確認部20は、行列に含まれるデータポイントであって、集合に含まれないデータポイントが、超平面計算部18によって計算された超平面を基に設定された第2の条件を満たすか否かを確認する。集合更新部21は、確認部20によって第2の条件を満たすことが確認されたデータポイントを集合に追加する。これにより、枝狩りを行った後の集合を使って計算した超平面の最適性が保証されるため、本実施形態によれば、計算コストの低減とSVMの分類精度とを両立させることができる。
 疎ベクトル計算部12は、行列の列ベクトルごとの最頻値を用いて、当該列ベクトルの要素の値のシフトを行うことによって、疎ベクトルを計算する。パラメータ計算部16は、疎行列のデータポイントごとに上限値および下限値を計算する。集合設定部17は、疎行列のデータポイントを基に集合を設定する。計算装置10は、行列の各列ベクトルをあらかじめ疎ベクトル化しておくことで、さらに計算コストを低減させることができる。
[システム構成等]
 また、図示した各装置の各構成要素は機能概念的なものであり、必ずしも物理的に図示のように構成されていることを要しない。すなわち、各装置の分散・統合の具体的形態は図示のものに限られず、その全部または一部を、各種の負荷や使用状況等に応じて、任意の単位で機能的または物理的に分散・統合して構成することができる。さらに、各装置にて行われる各処理機能は、その全部または任意の一部が、CPU(Central Processing Unit)および当該CPUにて解析実行されるプログラムにて実現され、あるいは、ワイヤードロジックによるハードウェアとして実現され得る。
 また、本実施形態において説明した各処理のうち、自動的に行われるものとして説明した処理の全部または一部を手動的に行うこともでき、あるいは、手動的に行われるものとして説明した処理の全部または一部を公知の方法で自動的に行うこともできる。この他、上記文書中や図面中で示した処理手順、制御手順、具体的名称、各種のデータやパラメータを含む情報については、特記する場合を除いて任意に変更することができる。
[プログラム]
 一実施形態として、計算装置10は、パッケージソフトウェアやオンラインソフトウェアとして上記の計算を実行する計算プログラムを所望のコンピュータにインストールさせることによって実装できる。例えば、上記の計算プログラムを情報処理装置に実行させることにより、情報処理装置を計算装置10として機能させることができる。ここで言う情報処理装置には、デスクトップ型またはノート型のパーソナルコンピュータが含まれる。また、その他にも、情報処理装置にはスマートフォン、携帯電話機やPHS(Personal Handyphone System)等の移動体通信端末、さらには、PDA(Personal Digital Assistant)等のスレート端末等がその範疇に含まれる。
 また、計算装置10は、ユーザが使用する端末装置をクライアントとし、当該クライアントに上記の計算に関するサービスを提供する計算サーバ装置として実装することもできる。例えば、計算サーバ装置は、多次元行列を入力とし、次元削減した行列を出力とする計算サービスを提供するサーバ装置として実装される。この場合、計算サーバ装置は、Webサーバとして実装することとしてもよいし、アウトソーシングによって上記の計算に関するサービスを提供するクラウドとして実装することとしてもかまわない。
 図14は、計算プログラムを実行するコンピュータの一例を示す図である。コンピュータ1000は、例えば、メモリ1010、CPU1020を有する。また、コンピュータ1000は、ハードディスクドライブインタフェース1030、ディスクドライブインタフェース1040、シリアルポートインタフェース1050、ビデオアダプタ1060、ネットワークインタフェース1070を有する。これらの各部は、バス1080によって接続される。
 メモリ1010は、ROM(Read Only Memory)1011およびRAM(Random Access Memory)1012を含む。ROM1011は、例えば、BIOS(Basic Input Output System)等のブートプログラムを記憶する。ハードディスクドライブインタフェース1030は、ハードディスクドライブ1090に接続される。ディスクドライブインタフェース1040は、ディスクドライブ1100に接続される。例えば磁気ディスクや光ディスク等の着脱可能な記憶媒体が、ディスクドライブ1100に挿入される。シリアルポートインタフェース1050は、例えばマウス1110、キーボード1120に接続される。ビデオアダプタ1060は、例えばディスプレイ1130に接続される。
 ハードディスクドライブ1090は、例えば、OS(Operating System)1091、アプリケーションプログラム1092、プログラムモジュール1093、プログラムデータ1094を記憶する。すなわち、計算装置10の各処理を規定するプログラムは、コンピュータにより実行可能なコードが記述されたプログラムモジュール1093として実装される。プログラムモジュール1093は、例えばハードディスクドライブ1090に記憶される。例えば、計算装置10における機能構成と同様の処理を実行するためのプログラムモジュール1093が、ハードディスクドライブ1090に記憶される。なお、ハードディスクドライブ1090は、SSDにより代替されてもよい。
 また、上述した実施形態の処理で用いられる設定データは、プログラムデータ1094として、例えばメモリ1010やハードディスクドライブ1090に記憶される。そして、CPU1020が、メモリ1010やハードディスクドライブ1090に記憶されたプログラムモジュール1093やプログラムデータ1094を必要に応じてRAM1012に読み出して実行する。
 なお、プログラムモジュール1093やプログラムデータ1094は、ハードディスクドライブ1090に記憶される場合に限らず、例えば着脱可能な記憶媒体に記憶され、ディスクドライブ1100等を介してCPU1020によって読み出されてもよい。あるいは、プログラムモジュール1093およびプログラムデータ1094は、ネットワーク(LAN(Local Area Network)、WAN(Wide Area Network)等)を介して接続された他のコンピュータに記憶されてもよい。そして、プログラムモジュール1093およびプログラムデータ1094は、他のコンピュータから、ネットワークインタフェース1070を介してCPU1020によって読み出されてもよい。
 10 計算装置
 11 初期化部
 12 疎ベクトル計算部
 13 データポイント選択部
 14 パラメータ決定部
 15 優先度計算部
 16 パラメータ計算部
 17 集合設定部
 18 超平面計算部
 19 パラメータ更新部
 20 確認部
 21 集合更新部
 22 全体パラメータ計算部

Claims (6)

  1.  行列に含まれるデータポイントごとに、One-class サポートベクターマシンで用いられるサポートベクトルの割合の下限値または外れ値の割合の上限値を示す割合パラメータに基づく所定のパラメータについて、該所定のパラメータの上限値および下限値を計算するパラメータ計算部と、
     前記データポイントのうち、前記所定のパラメータが、前記上限値以下かつ前記下限値以上であるデータポイントの集合を設定する集合設定部と、
     前記集合に含まれるデータポイントおよび前記割合パラメータを基に、One-class サポートベクターマシンの超平面を計算する超平面計算部と、
     を有することを特徴とする計算装置。
  2.  前記集合設定部は、前記データポイントのうち、前記下限値および前記上限値が第1の条件を満たすデータポイントを、前記集合に含めることを特徴とする請求項1に記載の計算装置。
  3.  前記行列に含まれるデータポイントであって、前記集合に含まれないデータポイントが、前記超平面計算部によって計算された超平面を基に設定された第2の条件を満たすか否かを確認する確認部と、
     前記確認部によって前記第2の条件を満たすことが確認されたデータポイントを前記集合に追加する集合更新部と、
     をさらに有することを特徴とする請求項1または2に記載の計算装置。
  4.  前記行列の列ベクトルごとの最頻値を用いて、当該列ベクトルの要素の値のシフトを行うことによって、疎ベクトルを計算する疎ベクトル計算部をさらに有し、
     前記パラメータ計算部は、前記疎ベクトルのデータポイントごとに前記上限値および前記下限値を計算し、
     前記集合設定部は、前記疎ベクトルのデータポイントを基に前記集合を設定することを特徴とする請求項1から3のいずれか1項に記載の計算装置。
  5.  コンピュータが実行する計算方法であって、
     行列に含まれるデータポイントごとに、One-class サポートベクターマシンで用いられるサポートベクトルの割合の下限値または外れ値の割合の上限値を示す割合パラメータに基づく所定のパラメータについて、該所定のパラメータの上限値および下限値を計算するパラメータ計算工程と、
     前記データポイントのうち、前記所定のパラメータが、前記上限値以下かつ前記下限値以上であるデータポイントの集合を設定する集合設定工程と、
     前記集合に含まれるデータポイントおよび前記割合パラメータを基に、One-class サポートベクターマシンの超平面を計算する超平面計算工程と、
     を含むことを特徴とする計算方法。
  6.  コンピュータを、請求項1から4のいずれか1項に記載の計算装置として機能させるための計算プログラム。
PCT/JP2019/015007 2018-04-04 2019-04-04 計算装置、計算方法および計算プログラム WO2019194285A1 (ja)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2018072125A JP2019185199A (ja) 2018-04-04 2018-04-04 計算装置、計算方法および計算プログラム
JP2018-072125 2018-04-04

Publications (1)

Publication Number Publication Date
WO2019194285A1 true WO2019194285A1 (ja) 2019-10-10

Family

ID=68100355

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2019/015007 WO2019194285A1 (ja) 2018-04-04 2019-04-04 計算装置、計算方法および計算プログラム

Country Status (2)

Country Link
JP (1) JP2019185199A (ja)
WO (1) WO2019194285A1 (ja)

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
FUJIWARA, YASUHIRO ET AL.: "Acceleration of Lasso by selective coordinate descent method", PROCEEDINGS OF THE 30TH ANNUAL CONFERENCE OF JSAI, 2016, pages 1 - 4 *

Also Published As

Publication number Publication date
JP2019185199A (ja) 2019-10-24

Similar Documents

Publication Publication Date Title
US10067746B1 (en) Approximate random number generator by empirical cumulative distribution function
CN113574325B (zh) 通过选择控制设置来控制环境的方法和系统
JP6919770B2 (ja) パラメータ探索方法、パラメータ探索装置、及びパラメータ探索用プログラム
WO2019194299A1 (ja) 学習装置、学習方法および学習プログラム
JP6870508B2 (ja) 学習プログラム、学習方法及び学習装置
CN114416351B (zh) 资源分配方法、装置、设备、介质及计算机程序产品
CN110705718A (zh) 基于合作博弈的模型解释方法、装置、电子设备
CN114816711A (zh) 批量任务处理方法、装置、计算机设备和存储介质
CN110782030A (zh) 深度学习权值更新方法、系统、计算机设备及存储介质
JP6767312B2 (ja) 検知システム、検知方法及び検知プログラム
JP6484449B2 (ja) 予測装置、予測方法および予測プログラム
JP6453785B2 (ja) 回帰分析装置、回帰分析方法および回帰分析プログラム
WO2020116211A1 (ja) 推定装置、最適化装置、推定方法、最適化方法、及びプログラム
WO2019194285A1 (ja) 計算装置、計算方法および計算プログラム
CN113646782A (zh) 信息处理设备、信息处理系统、信息处理方法、存储介质及程序
JP2018073285A (ja) L1グラフ計算装置、l1グラフ計算方法及びl1グラフ計算プログラム
JP6835704B2 (ja) 検知システム、学習方法及び学習プログラム
Lamboni On exact distribution for multivariate weighted distributions and classification
JP7077746B2 (ja) 学習装置、学習方法及び学習プログラム
US11270369B2 (en) Systems for generating recommendations
CN113646783A (zh) 信息处理设备、信息处理系统、信息处理方法、存储介质及程序
CN106547922B (zh) 一种应用程序的排序方法、装置及服务器
CN113420841B (zh) 有毒样本数据生成方法及装置
JP6721533B2 (ja) graphical lasso計算装置、graphical lasso計算方法及びgraphical lasso計算プログラム
CN116644646B (zh) 岩石的细观重构方法、装置、设备及存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19780789

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19780789

Country of ref document: EP

Kind code of ref document: A1