Outlier detection device, outlier detection method, and program
The k-dimensional subspace learning method with a Concrete Select Layer and Gumbel Softmax addresses the challenges of high-dimensional outlier detection by reducing costs and improving interpretability through feature selection.
Patent Information
- Application Number
- JP2023562023
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2021-11-18
- Publication Date
- 2024-10-23
- Estimated Expiration
- 2041-11-18
AI Technical Summary
Outlier detection in high-dimensional data is costly and difficult to interpret due to the large number of features, making it challenging to identify which feature values cause outliers.
A method using a k-dimensional subspace learning approach with a Concrete Select Layer and Gumbel Softmax to select k features that minimize the distance between normal points while maximizing the distance between normal and outlier points, reducing data collection costs and improving interpretability.
Reduces data collection costs and enhances the interpretability of outlier detection by selecting key features for data collection and detection, allowing for efficient and understandable outlier identification.
Smart Images

Figure 0007571898000008 
Figure 0007571898000009 
Figure 0007571898000010
Abstract
Description
[Technical field]
[0001] The present invention relates to an outlier detection device, an outlier detection method, and a program. [Background technology]
[0002] Outlier detection technology is known as a technology for detecting anomalous points that are located away from other data points in a set of data points, and is used in various fields, such as diagnosing illnesses in the medical field, diagnosing security in ICT systems, and detecting malfunctions in factory equipment. There are various outlier detection technologies, but the most basic one is a metric-based outlier detection technology based on the distance between data points in a feature space in which the data points exist (for example, Non-Patent Documents 1 to 3, etc.). [Prior art documents] [Non-patent literature]
[0003] [Non-Patent Document 1] Leif E Peterson, "K-nearest neighbor", Scholarpedia 4 (2), 2009. [Non-Patent Document 2] LIU, FT, TING, KM, AND ZHOU, Z.-H. 2008a. Isolation forest. In Proceedings of the 8th IEEE International Conference on Data Mining (ICDM'08). IEEE Computer Society Press, 413-422. [Non-Patent Document 3] Guansong Pang, Kai Ming Ting, and David Albrecht. 2015. LeSiNN: Detecting anomalies by identifying least similar nearest neighbors. In ICDM Workshop. IEEE, 623-630. Summary of the Invention [Problem to be solved by the invention]
[0004] However, in recent years, the number of items in data collected in fields where outlier detection technology is used tends to be large, and the dimensions of the feature space in which data points exist can exceed several thousand or even several million. This increases the cost of collecting data, and even if an outlier is detected, it is difficult to know which feature caused the outlier to be detected.
[0005] An embodiment of the present invention has been made in consideration of the above points, and has an object to select a feature amount used for outlier detection. [Means for solving the problem]
[0006] To achieve the above object, an outlier detection device according to one embodiment has: a learning unit configured to learn a model that uses a set of d-dimensional data represented by points in a d-dimensional feature space as input, and selects a k-dimensional subspace of the d-dimensional feature space in which the distance between normal points when outlier detection is performed is smaller than the distance between normal points and outlier points; a feature selection unit configured to select k features corresponding to the k-dimensional subspace using the trained model; and a data collection unit configured to collect k-dimensional data composed of the k features as data for outlier detection. Effect of the Invention
[0007] The features used for outlier detection can be selected. [Brief description of the drawings]
[0008] [Figure 1] FIG. 2 is a diagram illustrating an example of a hardware configuration of the outlier detection device according to the present embodiment. [Diagram 2] FIG. 2 is a diagram illustrating an example of a functional configuration of an outlier detection device according to the present embodiment. [Diagram 3] 10 is a flowchart showing an example of the flow of a learning process according to the present embodiment. [Figure 4] 10 is a flowchart showing an example of the flow of a feature amount selection process according to the present embodiment. [Diagram 5] 10 is a flowchart showing an example of the flow of data collection and outlier detection processing according to the present embodiment. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0009] An embodiment of the present invention will be described below. In this embodiment, an outlier detection device 10 will be described which selects features that contribute to outlier detection from high-dimensional data, and performs data collection and outlier detection for the selected features. By using the outlier detection device 10 according to this embodiment, the number of features to be collected and subjected to outlier detection is reduced, so that data collection costs can be reduced and the interpretability of outlier detection results can be improved. Note that outlier detection may also be called, for example, "outlier point detection," "abnormal detection," "abnormal value detection," "abnormal point detection," etc.
[0010] <Theoretical structure> The theoretical configuration of this embodiment will now be described.
[0011] Let the set of data points be D={x1, ,x r}, where for each i=1,...,r, x i is a data point in the feature space, and is a d-dimensional vector x i =[x i1 ,···,x id ]. Note that d is the number of data xi The number of items (feature quantities) of each data x is a predetermined natural number, but it is assumed to be a large value such as several thousand to several million. i is collected from the target systems, devices, etc.
[0012] The method proposed in this embodiment (hereinafter, also referred to as the proposed method) is a combination of a dimensionality reduction method using false labels based on the existing outlier detection technology proposed in RAPEN (Reference 1), a feature extraction method proposed in Concrete Autoencoder (Reference 2), and Self-Paced Learning (Reference 3). I or λ n The method of creating these data is different from that of conventional technology and has been devised specifically for the proposed method.
[0013] ≪Polynomial distribution≫ First, a polynomial distribution that represents a quantity that defines the degree of normality of each data point and a polynomial distribution that represents a quantity that defines the degree of abnormality are defined.
[0014] For each data x in the data set D, we use a known metric-based outlier detection technique. i The abnormality (or outlier) of a i ' is calculated. Examples of metric-based outlier detection techniques include kNN (Non-Patent Document 1), Isolation Forest (Non-Patent Document 2), and LeSiNN (Non-Patent Document 3).
[0015] The set of abnormalities {a i '|i=1,...,r} is calculated as the mean μ and the standard deviation σ. In this case, we introduce a certain threshold c and set O={i|a i '>μ+cσ}, we define the following polynomial distributions as quantities that specify the degree of normality and abnormality of each data point.
[0016]
number
[0017] ≪Model to be learned≫ Next, the model used in the proposed method will be described. In this proposed method, a neural network composed of a single-layer Concrete Select Layer is used as the model to be learned. The Concrete Select Layer is configured as follows.
[0018] First, Gumbel Softmax is introduced.
[0019]
Equation
[0020] At this time, the d-dimensional vector m = [m1, ···, m d τ becomes a vector satisfying a magnitude of 1. Note that τ represents transposition.
[0021] Let k (where k < r) be a parameter that can be arbitrarily set by the user. k d-dimensional vectors m (1) , ···, m (k) are generated by Gumbel Softmax, and a matrix composed of these k d-dimensional vectors m (1) , ···, m (k) is denoted as M = (m (1) , ···, m (k) ). At this time, x i ' = x i M is the Concrete Select Layer. x i ' is a k-dimensional vector, and in the low-temperature limit, each of its elements is xi are independently selected from among the elements of
[0022] Therefore, the parameter α j (i) By properly learning the original data x i The necessary k features can be extracted from the parameter α1 (i) ,...,α d (i) is a d-dimensional vector m (i) These are the parameters to be learned by Gumbel Softmax when generating the (i) =(α1 (i) ,...,α d (i) )
[0023] <Learning method and loss function> Next, the learning method and the loss function will be explained.
[0024] The number of epochs is N, the number of batches per epoch is S, and the batch size is B. B pieces of data are sampled from the data point set D using a uniform distribution, and normal points are selected using a multinomial distribution Pr I (x i ) based on B data, the multinomial distribution Pr O (x i ) and sample each of the B pieces of data. Then, each of these three types of data points is treated as a set, and the set of B three points as shown below is treated as one batch.
[0025] T s =( <x (1) ,x I (1) ,x O (1) > s , , <x (B) ,x I (B) ,x O (B) > s ) where s is the batch number, x (b)is the data sampled uniformly from the data set D, and x I (b) is a candidate normal point, x O (b) is a candidate outlier.
[0026] x in batch (b) , x I (b) , x O (b) Input each of these independently to the Concrete Select Layer, and the k-dimensional vector x' (b) , x I ' (b) , x O ' (b) In order to be able to distinguish between normal and outliers in k-dimensional space, we consider the following loss function:
[0027]
number
[0028]
number
[0029] Furthermore, λ n is a quantity defined for epoch n, and l at epoch n-1 b The average of μ n-1 , standard deviation is σ n-1 As,
[0030]
number
[0031] Then, the model is trained as follows:
[0032]
number
[0033] In addition, the temperature parameter T is gradually lowered for each epoch. Specifically, the initial temperature is T s , and the final temperature T e In the nth epoch of training,
[0034]
number
[0035] In this way, in the proposed method, outlier detection is performed on each data included in the data point set D, pseudo-labels (quantities that specify the degree of normality and abnormality) of normal points and outlier points are set, and then a model is trained that selects a subspace (k-dimensional subspace) of feature space in which the distance between two randomly selected normal points is smaller than the distance between a normal point and an outlier.
[0036] <Feature selection and outlier detection> Trained parameter α = (α (1) ,...,α (k) ) for each d-dimensional vector α (i) The feature corresponding to the maximum value among the elements of is selected as the feature for data collection and outlier detection. That is, for each i=1,...,k, max{α1 (i) ,...,α d (i)Then, the feature vectors corresponding to j∈{1, ,d}, where} is the feature vector for data collection and outlier detection, are selected. As a result, k feature vectors are selected as the feature vectors for data collection and outlier detection.
[0037] In outlier detection, a metric-based outlier detection technique (e.g., kNN, Isolation Forest, LeSiNN, etc.) is applied to data x' (i.e., k-dimensional vector x') consisting of the k features selected above. Furthermore, when collecting data, it is sufficient to collect only the k features selected above.
[0038] <Hardware Configuration of Outlier Detection Device 10> An example of the hardware configuration of an outlier detection device 10 according to this embodiment is shown in Fig. 1. As shown in Fig. 1, the outlier detection device 10 according to this embodiment has an input device 101, a display device 102, an external I / F 103, a communication I / F 104, a processor 105, and a memory device 106. Each of these pieces of hardware are connected to each other via a bus 107 so as to be able to communicate with each other.
[0039] The input device 101 is, for example, a keyboard, a mouse, a touch panel, various physical buttons, etc. The display device 102 is, for example, a display, a display panel, etc. Note that the outlier detection device 10 does not necessarily have to include at least one of the input device 101 and the display device 102, for example.
[0040] The external I / F 103 is an interface with an external device such as a recording medium 103a. Examples of the recording medium 103a include a CD (Compact Disc), a DVD (Digital Versatile Disk), an SD memory card (Secure Digital memory card), and a USB (Universal Serial Bus) memory card.
[0041] The communication I / F 104 is an interface for connecting the outlier detection device 10 to a communication network. The processor 105 is, for example, various types of arithmetic devices such as a central processing unit (CPU) or a graphics processing unit (GPU). The memory device 106 is, for example, various types of storage devices such as a hard disk drive (HDD), a solid state drive (SSD), a random access memory (RAM), a read only memory (ROM), and a flash memory.
[0042] 1 is an example, and the outlier detection device 10 may have other hardware configurations. For example, the outlier detection device 10 may have multiple processors 105 and multiple memory devices 106, or may have various types of hardware other than the hardware shown in the figure.
[0043] <Functional configuration of outlier detection device 10> FIG. 2 shows an example of the functional configuration of the outlier detection device 10 according to this embodiment. As shown in FIG. 2, the outlier detection device 10 according to this embodiment includes a data collection unit 201, a learning unit 202, a feature selection unit 203, and an inference unit 204. These functional units are realized, for example, by a process in which one or more programs installed in the outlier detection device 10 are executed by the processor 105. The outlier detection device 10 according to this embodiment also includes an input data DB 205 and a trained model DB 206. Each of these DBs (databases) is realized, for example, by the memory device 106. However, at least one of the input data DB 205 and the trained model DB 206 may be realized by a storage device (such as a database server) connected to the outlier detection device 10 via a communication network.
[0044] Before model learning, the data collection unit 201 collects d-dimensional vector data x and stores it in the input data DB 205. After model learning, the data collection unit 201 collects k-dimensional vector data x′ composed of k features set by the feature selection unit 203 and stores it in the input data DB 205.
[0045] The learning unit 202 uses a data point set D stored in the input data DB 205 to generate a polynomial distribution Pr I (x i ) and Pr O (x i ) and train the training model (a neural network consisting of one concrete select layer).
[0046] The feature selection unit 203 selects k feature quantities to be used as data collection targets and outlier detection targets, using the trained model trained by the training unit 202. In addition, the feature selection unit 203 sets the selected k feature quantities in the data collection unit 201 as feature quantities to be used as data collection targets.
[0047] The inference unit 204 performs outlier detection by a known metric-based outlier detection technique using data x' (k-dimensional vector data) stored in the input data DB 205. The outlier detection result is output to a predetermined output destination (for example, a display device such as a display, another program, another terminal, a control device that executes some control based on the outlier detection result, etc.).
[0048] Before model learning, the input data DB 205 stores a data point set D. After model learning, the input data DB 205 stores data x' (k-dimensional vector data) collected by the data collection unit 201.
[0049] The trained model DB 206 stores trained models trained by the training unit 202 (specifically, trained parameters α=(α (1) ,...,α (k))) is stored.
[0050] In addition, although FIG. 2 shows an example in which all the functional units and the DB are arranged in one device, the present invention is not limited to this. For example, each functional unit and each DB may be distributed and arranged in a plurality of devices connected to each other via a communication network.
[0051] <Flow of learning process> The flow of the learning process according to the present embodiment will be described with reference to FIG. 3. Hereinafter, it is assumed that the input data DB 205 stores a data point set D = {x1,..., x r}(each data x i is a d-dimensional vector). Also, it is assumed that a parameter k (<d) is specified by the user.
[0052] First, the learning unit 202 uses the data point set D = {x1,..., x r} stored in the input data DB 205 to calculate polynomial distributions Pr I (x i ) and Pr O (x i )(step S101). That is, the learning unit 202 calculates the abnormality degree a i ' of each data x i included in the data point set D using a known metric-based outlier detection technique, and then uses these abnormality degrees a i ' to define the normality degree of each data x i as a polynomial distribution Pr I (x i ) and the abnormality degree as a polynomial distribution Pr O (x i ) are calculated.
[0053] Next, the learning unit 202 uses the polynomial distributions Pr I (x i ) and Pr O (x i ) calculated in step S101 above to create a learning data set {T s |s = 1,..., S} (step S102). Note that Ts =( <x (1) ,x I (1) ,x O (1) > s , , <x (B) ,x I (B) ,x O (B) > s ).
[0054] Next, the learning unit 202 uses the learning data set {T s Using |s=1, ,S}, the learning object model is trained by the formula shown in the above formula 6 (step S103). At this time, the temperature parameter T of the learning object model is set to the temperature parameter T shown in the above formula 7, and is gradually lowered for each epoch.
[0055] Then, the learning unit 202 calculates the trained model trained in step S103 (specifically, the trained parameter α=(α (1) ,...,α (k) ) is stored in the trained model DB 206 (step S104).
[0056] <Feature selection process flow> The flow of the feature selection process according to this embodiment will be described with reference to FIG. 4. In the following, the trained model DB 206 stores trained parameters α=(α (1) ,...,α (k) )) is assumed to be stored.
[0057] The feature selection unit 203 selects the trained parameter α=(α (1) ,...,α (k) ) to select k features (step S201). That is, the feature selection unit 203 selects k features for each i=1, . . . , k by using max{α (i) ,...,α d (i),d}, where j∈{1, ,d} is the set of features that are
[0058] Then, the feature selection unit 203 sets the k feature quantities selected in step S201 as feature quantities to be collected in the data collection unit 201 (step S202). As a result, the data collection unit 201 collects k-dimensional vector data x' consisting of these k feature quantities. Therefore, outlier detection is also performed using this k-dimensional vector data x'.
[0059] <Data collection and outlier detection process flow> The flow of data collection and outlier detection processing according to this embodiment will be described with reference to Fig. 5. In the following, it is assumed that k feature quantities are set in the data collection unit 201 as feature quantities of data to be collected, and that a certain amount of k-dimensional vector data x' (at least an amount of data x' that allows outlier detection by a metric-based outlier detection technique) is stored in the input data DB 205. Note that the following steps S301 to S303 are repeatedly executed, for example, every data collection period.
[0060] The data collection unit 201 collects k-dimensional vector data x' consisting of k feature quantities set as feature quantities of the data collection target (step S301). Note that this data x' is collected from the target system, device, etc.
[0061] Next, the data collection unit 201 stores the data x' collected in the above step S301 in the input data DB 205 (step S302).
[0062] Then, the inference unit 204 performs outlier detection by a known metric-based outlier detection technique using the data x' (k-dimensional vector data) stored in the input data DB 205 (step S303). This makes it possible to realize outlier detection with high interpretability.
[0063] <Summary> As described above, the outlier detection device 10 according to this embodiment selects k features necessary for outlier detection from high-dimensional data (d-dimensional vector data) and collects only the selected k features, thereby reducing data collection costs and improving the interpretability of outlier detection. In addition, since the parameter k can be set by the user, it is possible to set an appropriate parameter k according to, for example, the allowable cost requirements for data collection and requirements for the interpretation of outlier detection.
[0064] The outlier detection device 10 according to the present embodiment can be applied to various fields, such as, for example, disease diagnosis in the medical field, security diagnosis of ICT systems, and fault detection of factory equipment. The outlier detection device 10 according to the present embodiment may not only simply detect outliers, but may also perform various controls according to the application field based on the outlier detection results. For example, when applied to fault detection of factory equipment, the outlier detection device 10 according to the present embodiment may perform control such as switching to a non-faulty device when an outlier (i.e., a fault) is detected.
[0065] The present invention is not limited to the above-described embodiments specifically disclosed, and various modifications, changes, combinations with known technologies, etc. are possible without departing from the scope of the claims.
[0066] [References] Reference 1: Guansong Pang, Longbing Cao, Ling Chen, and Huan Liu. 2018. Learning representations of ultrahigh-dimensional data for random distance-based outlier detection. In KDD. 2041-2050. Reference 2: Balin MF, Abid A, Zou J (2019) Concrete autoencoders: Differentiable features selection and reconstruction. In Proc Int Conf Mach Learn,pp444 -453 Reference 3: Kumar, MP, Packer, B., and Koller, D. Self-paced learning for latent variable models. In NIPS, 2010. [Explanation of symbols]
[0067] 10. Outlier detection device 101 Input Device 102 Display device 103 External I / F 103a Recording media 104 Communication I / F 105 processors 106 Memory Device 107 Bus 201 Data Collection Department 202 Learning Department 203 Feature Selection Unit 204 Reasoning part 205 Input Data DB 206 Trained Model DB
Claims
1. a learning unit configured to learn a model that uses a set of d-dimensional data represented by points in a d-dimensional feature space as an input, and selects a k-dimensional subspace of the d-dimensional feature space, in which a distance between normal points when outlier detection is performed can be made smaller than a distance between a normal point and an outlier point; A feature selection unit configured to select k features corresponding to the k-dimensional subspace using the trained model; a data collection unit configured to collect k-dimensional data composed of the k feature amounts as outlier detection target data; An outlier detection device having the following configuration.
2. The outlier detection device according to claim 1 , further comprising an outlier detection unit configured to detect outliers by metric-based outlier detection using the outlier detection target data.
3. The learning unit is Calculating a first polynomial distribution representing a degree of normality of the d-dimensional data and a second polynomial distribution representing a degree of anomaly of the d-dimensional data by metric-based outlier detection; 3. The outlier detection device according to claim 1, wherein the model is trained using, as training data, first d-dimensional data uniformly sampled from the set, second d-dimensional data sampled from the set based on the first polynomial distribution, and third d-dimensional data sampled from the set based on the second polynomial distribution.
4. The learning unit is The set is denoted by {x i |i=1, . . . , r}, each d-dimensional data x included in the set is detected by the metric-based outlier detection. i Abnormality level a i ' is calculated, P I (x i ) = (1 / a i ') / (1 / a 1 '+...+1 / a r ') to obtain the first polynomial distribution Pr I (x i ) is calculated, For a predetermined threshold c, O = {i | a i '>μ+cσ} (where μ and σ are {a i '|i = 1, ..., r}) (mean and standard deviation), if i is not an element of O, then Pr O (x i ) = 0, if i is an element of O, Pr O (x i ) = a i ' / (a 1 '+...+a r ') to obtain the second polynomial distribution Pr O (x i The outlier detection device according to claim 3 , wherein the outlier detection device is configured to calculate a difference between the first and second inequalities.
5. The learning unit is Let n be the epoch number, B be the batch size, and v for each b ∈ {1, ..., B}. b ∈{0, 1}, l b =1 / (1+exp(d O -d I ) ) d I is the distance between the first d-dimensional data and the second d-dimensional data, d O is the distance between the first d-dimensional data and the third d-dimensional data, and when n=1, λ n = 0, and λ for n > 1 n = μ n-1 +σ n-1 (However, μ n-1 and σ n-1 are the l at epoch number n-1, respectively. b (mean and standard deviation of v 1 (l 1 -λ n ) + ... + v B (l B -λ n 5. The outlier detection device according to claim 3, wherein the model is trained using a loss function of .times. ...
6. The outlier detection device according to claim 1 , wherein the model is a neural network configured with one layer of Concrete Select Layer.
7. a learning procedure for learning a model that uses a set of d-dimensional data represented by points in a d-dimensional feature space as an input and selects a k-dimensional subspace of the d-dimensional feature space, in which a distance between normal points when outlier detection is performed is smaller than a distance between a normal point and an outlier point; a feature selection step of selecting k features corresponding to the k-dimensional subspace using the trained model; a data collection step of collecting k-dimensional data composed of the k feature amounts as outlier detection target data; This is an outlier detection method implemented by a computer.
8. A program causing a computer to function as the outlier detection device according to claim 1 .
