Change detection apparatus and change detection method
The change detection device enhances the accuracy of detecting time-series data changes by normalizing difference vectors based on directional distribution, addressing the outlier issue in conventional methods and enabling detection with smaller data sets.
Patent Information
- Application Number
- JP2023046097
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2023-03-23
- Publication Date
- 2024-10-04
AI Technical Summary
Conventional change detection methods in time-series data, such as RuLSIF, are affected by outliers, leading to decreased accuracy in detecting characteristic changes.
A change detection device and method that acquires time-series data for two periods, generates partial vectors, calculates difference vectors, normalizes them to maintain directionality, and detects changes based on the bias in the directional distribution of these vectors, ignoring vector magnitudes.
Improves the accuracy of detecting characteristic changes in time-series data by mitigating the influence of outliers and enabling detection with smaller data sets.
Smart Images

Figure 2024135425000001_ABST
Abstract
Description
[Technical field]
[0001] The present disclosure relates to a change detection apparatus and a change detection method. [Background technology]
[0002] Conventionally, the RuLSIF method has been disclosed as a method for detecting characteristic changes in time series data (see Non-Patent Document 1). The method described in Non-Patent Document 1 is a method for acquiring time series data for a predetermined period and time series data for a period after the predetermined period, and determining whether or not a characteristic change has occurred in the time series data based on the density ratio of the probability distributions of the time series data for each period. [Prior art documents] [Non-patent literature]
[0003] [Non-Patent Document 1] S. Liu, M. Yamada, N. Collier, and M. Sugiyama, Change-point detection in time-series data by relative density-ratio estimation, Neural Networks, 43(2013), pp.72-83. Summary of the Invention [Problem to be solved by the invention]
[0004] In general, time series data may contain outliers that are significantly different from other data values due to various factors. However, the method described in Non-Patent Document 1 has a problem that the calculation of the density ratio is affected by the outliers contained in the time series data, and therefore the accuracy of detecting characteristic changes may decrease depending on the outliers contained in the time series data.
[0005] The present disclosure is intended to solve the above-mentioned problems, and aims to provide a change detection device and a change detection method that can improve the accuracy of detecting characteristic changes in time-series data compared to conventional methods. [Means for solving the problem]
[0006] The change detection device according to the present disclosure is characterized by including a time series data acquisition unit that acquires time series data for a period including a first period and a second period that is a period subsequent to the first period; a vector acquisition unit that acquires a plurality of first vectors that are a plurality of partial time series data for the first period and a plurality of second vectors that are a plurality of partial time series data for the second period based on the time series data acquired by the time series data acquisition unit; a difference vector acquisition unit that acquires difference vectors relating to combinations of a specific first vector among the multiple first vectors and a specific second vector among the multiple second vectors in a plurality of combinations; and a change detection unit that detects a characteristic change in the time series data based on a bias in the directional distribution of the multiple difference vectors acquired by the difference vector acquisition unit. Effect of the Invention
[0007] According to the present disclosure, by detecting a characteristic change in time series data based on the directional bias of multiple difference vectors obtained from a first vector, which is partial time series data for a first period of the time series data, and a second vector, which is partial time series data for a second period of the time series data, it becomes possible to suppress the influence of outliers contained in the time series data, and to improve the accuracy of detecting a characteristic change in time series data compared to conventional methods. [Brief description of the drawings]
[0008] [Figure 1] 1 is a block diagram showing a schematic configuration of a change detection device according to a first embodiment. [Diagram 2] FIG. 1 is a block diagram showing an example of a hardware configuration of a change detection device according to a first embodiment. [Diagram 3]FIG. 1 is a block diagram showing an example of a hardware configuration of a change detection device according to a first embodiment. [Figure 4] 4 is a flowchart showing processing performed by the change detection device according to the first embodiment. [Diagram 5] 4 is a graph showing an example of time-series data acquired by the change detection device according to the first embodiment. [Figure 6] 4 is a conceptual diagram showing an example of a vector acquisition process performed by the change detection device according to the first embodiment. [Figure 7] 4 is a diagram showing a plurality of first vectors and a plurality of second vectors obtained by the vector acquisition process performed by the change detection device according to the first embodiment. [Figure 8] FIG. 8A is a conceptual diagram showing the first differential vector acquisition process performed by the change detection device of embodiment 1. FIG. 8B is a diagram showing an example of multiple first differential vectors obtained by the first differential vector acquisition process performed by the change detection device of embodiment 1. FIG. 8C is a diagram showing an example of multiple first normal vectors obtained by the first normalization process performed by the change detection device of embodiment 1. [Figure 9] FIG. 9A is a conceptual diagram showing the first differential vector acquisition process performed by the change detection device of embodiment 1. FIG. 9B is a diagram showing an example of multiple first differential vectors obtained by the first differential vector acquisition process performed by the change detection device of embodiment 1. FIG. 9C is a diagram showing an example of multiple first normal vectors obtained by the first normalization process performed by the change detection device of embodiment 1. [Figure 10] FIG. 10A is a conceptual diagram showing the first differential vector acquisition process performed by the change detection device of embodiment 1. FIG. 10B is a diagram showing an example of multiple first differential vectors obtained by the first differential vector acquisition process performed by the change detection device of embodiment 1. FIG. 10C is a diagram showing an example of multiple first normal vectors obtained by the first normalization process performed by the change detection device of embodiment 1. [Figure 11]FIG. 11A is a conceptual diagram showing the second differential vector acquisition process performed by the change detection device of embodiment 1. FIG. 11B is a diagram showing an example of multiple second differential vectors obtained by the second differential vector acquisition process performed by the change detection device of embodiment 1. FIG. 11C is a diagram showing an example of multiple second normal vectors obtained by the second normalization process performed by the change detection device of embodiment 1. [Figure 12] 3 is a conceptual diagram showing a vector acquisition process performed by the change detection device according to the first embodiment. [Figure 13] 3 is a schematic diagram showing a timing gear for detecting a change in vibration by the change detection device according to the first embodiment; [Figure 14] FIG. 14A is a graph showing vibration data of a timing gear as time series data acquired by the change detection device of embodiment 1, and FIG. 14B is a graph showing a change score calculated by the change detection device of embodiment 1 based on the vibration data of the timing gear. [Figure 15] 4 is a graph showing gas consumption data as time-series data acquired by the change detection device according to the first embodiment and a change score calculated based on the gas consumption data. [Figure 16] FIG. 16A is a graph showing the trend of daily closing prices of the Tokyo Stock Price Index as time series data acquired by the change detection device of embodiment 1, and FIG. 16B is a graph showing the change score calculated by the change detection device of embodiment 1 based on the data of the Tokyo Stock Price Index. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0009] Hereinafter, embodiments of the present disclosure will be described in detail with reference to the drawings. Embodiment 1 First, a schematic configuration of a change detection device 100 according to the first embodiment will be described with reference to Fig. 1. Fig. 1 is a block diagram showing a schematic configuration of the change detection device 100 according to the first embodiment. As shown in Fig. 1, the change detection device 100 according to the first embodiment includes a time series data acquisition unit 10 that acquires time series data, a calculation unit 20 that performs calculation based on the time series data acquired by the time series data acquisition unit 10, and an output unit 30 that outputs a result of the calculation by the calculation unit 20.
[0010] The time series data acquisition unit 10 acquires time series data that allows the change detection device 100 to determine the presence or absence of a characteristic change. For example, the time series data acquisition unit 10 acquires time series data from an input device (not shown) that accepts input operations by a user, a storage device (not shown) included in the change detection device 100, an external device such as a sensor or computer (not shown) communicably connected to the change detection device 100, an external storage medium read by an information reading device (not shown) included in the change detection device 100, etc. Note that the time series data acquired by the time series data acquisition unit 10 is not limited to sequence data including values indicating time. The time series data acquired by the time series data acquisition unit 10 may be sequence data including values related to time, and may be, for example, sequence data including values indicating elapsed time starting from a specific time, or sequence data including values other than values directly indicating time, such as a count number that increases as time progresses.
[0011] The calculation unit 20 has a vector acquisition unit 21, a difference vector acquisition unit 22, a vector conversion unit 23, a change score calculation unit 24, a change detection unit 25, and a parameter setting unit 26, and detects characteristic changes in the time series data based on the time series data acquired by the time series data acquisition unit 10.
[0012] The vector acquiring unit 21 acquires a plurality of first vectors, which are a plurality of partial time series data in a first period, based on the time series data acquired by the time series data acquiring unit 10. In other words, the vector acquiring unit 21 extracts a plurality of partial time series data as a plurality of first vectors from the time series data in the first period among the time series data acquired by the time series data acquiring unit 10. Note that the partial time series data is series data in which a plurality of consecutive data values among the data values included in the time series data are grouped together into one.
[0013] Moreover, the vector acquiring unit 21 acquires a plurality of second vectors, which are a plurality of partial time series data in a second period that is a period after the first period, based on the time series data acquired by the time series data acquiring unit 10. In other words, the vector acquiring unit 21 extracts a plurality of partial time series data as a plurality of second vectors from the time series data in the second period that is a period after the first period, among the time series data acquired by the time series data acquiring unit 10. Note that the start point of the second period may be separated in time from the end point of the first period, but is preferably not earlier than the end point of the first period.
[0014] The difference vector acquisition unit 22 acquires a difference vector between a specific first vector among the multiple first vectors and a specific second vector among the multiple second vectors. Moreover, the difference vector acquisition unit 22 acquires a plurality of difference vectors by acquiring the difference vector for a plurality of combinations of the first vector and the second vector.
[0015] The vector conversion unit 23 normalizes each of the multiple difference vectors acquired by the difference vector acquisition unit 22. In other words, the vector conversion unit 23 converts each of the multiple difference vectors acquired by the difference vector acquisition unit 22 into a normalized vector with a magnitude of 1. Note that the vector conversion unit 23 may be configured to acquire a vector obtained by converting the multiple difference vectors acquired by the difference vector acquisition unit 22 so as to unify their magnitudes without changing their orientations, and for example, the vector conversion unit may be configured to convert each of the multiple difference vectors acquired by the difference vector acquisition unit 22 into a vector with a magnitude other than 1.
[0016] The change score calculation unit 24 calculates a change score based on the multiple normal vectors obtained by the conversion of the vector conversion unit 23. The change score is a value indicating the bias of the directional distribution of the multiple normal vectors obtained by the conversion of the vector conversion unit 23. For example, when the trend of the time series data changes, the multiple difference vectors acquired by the difference vector acquisition unit 22 tend to have biased directions. For this reason, it is possible to detect a characteristic change in the time series data based on the bias of the directional distribution of the multiple difference vectors acquired by the difference vector acquisition unit 22.
[0017] However, such a plurality of difference vectors may include an outlier difference vector calculated based on an outlier of the time series data, and since the outlier difference vector is calculated as a vector larger than other difference vectors, the detection accuracy may be affected depending on the detection method used to detect a characteristic change in the time series data. Therefore, the change detection device 100 according to the first embodiment is configured to focus only on the directions of the plurality of difference vectors acquired by the difference vector acquisition unit 22, convert these plurality of difference vectors into normal vectors whose magnitude is 1, and detect a characteristic change in the time series data based on the bias in the distribution of these plurality of normal vectors.
[0018] The change detection unit 25 detects a characteristic change in the time series data by determining whether or not a characteristic change has occurred between the time series data of the first period and the time series data of the second period based on the calculation result by the change score calculation unit 24. For example, the change detection unit 25 determines whether or not a characteristic change has occurred in the time series data by comparing the change score calculated by the change score calculation unit 24 with a preset threshold. In this way, the change detection unit 25 detects a characteristic change in the time series data based on the bias in the directional distribution of the multiple difference vectors acquired by the difference vector acquisition unit 22.
[0019] The parameter setting unit 26 sets various parameters to be executed by the calculation unit 20. For example, the parameter setting unit 26 sets various parameters based on information from an input device (not shown) that accepts input operations by a user, a storage device (not shown) included in the change detection device 100, an external device (not shown) communicably connected to the change detection device 100, an external storage medium read by an information reading device (not shown) included in the change detection device 100, etc. Also, the parameter setting unit 26 sets various parameters based on the time series data acquired by the time series data acquisition unit 10. For example, the parameter setting unit 26 sets parameters such as the size (number of dimensions of vector) of the partial time series data acquired by the vector acquisition unit 21, the time difference between the partial time series data acquired by the vector acquisition unit 21, and a threshold value used for judgment by the change detection unit 25.
[0020] The output unit 30 outputs the detection result by the change detection unit 25. In other words, the output unit 30 outputs information indicating whether or not a characteristic change has occurred in the time-series data detected by the change detection unit 25. For example, the output unit 30 outputs the detection result by the change detection unit 25 to a display device (not shown) that displays information, a storage device (not shown) included in the change detection device 100, an external device (not shown) communicatively connected to the change detection device 100, an external storage medium to which information is written by an information reading device (not shown) included in the change detection device 100, or the like.
[0021] Next, a hardware configuration of the change detection device 100 will be described with reference to Fig. 2 and Fig. 3. Fig. 2 is a diagram showing an example of a hardware configuration of the change detection device 100 in the first embodiment, and Fig. 3 is a diagram showing another example of a hardware configuration of the change detection device 100 in the first embodiment. For example, as shown in Fig. 2, the change detection device 100 has a processor 100a, a memory 100b, and an I / O port 100c, and is configured so that the processor 100a reads and executes a program stored in the memory 100b.
[0022] 3, the change detection device 100 has a processing circuit 100d and an I / O port 100c, which are dedicated hardware. The processing circuit 100d is configured, for example, by a single circuit, a composite circuit, a programmed processor, a parallel programmed processor, a system LSI (Large-Scale Integration), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array), or a combination of these. Each function of the change detection device 100 is realized by the processor 100a or the processing circuit 100d, which is dedicated hardware, executing a program, which is software. The change detection device 100 may also include hardware other than the above, not shown.
[0023] Next, the processing performed by the change detection device 100 according to the first embodiment will be described with reference to Figs. 4 to 12. Fig. 4 is a flowchart showing the processing performed by the change detection device 100 according to the first embodiment. First, when the change detection device 100 starts processing, it performs a parameter setting process for setting various parameters (step ST1). In this process, the change detection device 100 sets various parameters by the parameter setting unit 26 for the calculation unit 20 to perform calculations. After performing the process of step ST1, the change detection device 100 performs a time-series data acquisition process for acquiring time-series data (step ST2). In this process, the change detection device 100 acquires time-series data by the time-series data acquisition unit 10.
[0024] FIG. 5 is a graph showing an example of time series data acquired by the change detection device 100 according to the first embodiment. The time series data shown in FIG. 5 has two variables, namely, time t and data value ξ. For example, when determining whether or not a characteristic change has occurred around time t=100 in the time series data shown in FIG. 5, the change detection device 100 acquires, from the time series data, first time series data for a first period that is a period before time t=100 and second time series data for a second period that is a period after time t=100. In other words, from the acquired time series data, the change detection device 100 acquires, as the first time series data, time series data before point P, which is data at time t=100, and as the second time series data, data after point P.
[0025] After performing the process of step ST2, the change detection device 100 performs a vector acquisition process of acquiring a plurality of first vectors based on the first time series data and acquiring a plurality of second vectors based on the second time series data (step ST3). In this process, the change detection device 100, by the vector acquisition unit 21, acquires a plurality of first vectors which are partial time series data of the first time series data and a plurality of second vectors which are partial time series data of the second time series data.
[0026] FIG. 6 is a conceptual diagram showing an example of a vector acquisition process performed by the change detection device according to the first embodiment. For example, the change detection device 100 extracts partial time series data consisting of a specific data value ξ(1) in the first time series data and a data value ξ(2) that is adjacent to the time later than ξ(1) as a first vector [ξ(1), ξ(2)]. The value on the shoulder of ξ indicates the time. Similarly, the change detection device 100 extracts partial time series data consisting of a specific data value ξ(2) in the first time series data and a data value ξ(3) that is adjacent to the time later than ξ(2) as a first vector [ξ(2), ξ(3)]. After that, adjacent data values are sequentially extracted as first vectors that are partial time series data, and a plurality of first vectors are acquired.
[0027] In other words, in the process of step ST3, the change detection device 100 extracts M adjacent data values from the first time series data as an M-dimensional first vector, and converts the first time series data into a set of multiple first vectors by sequentially sliding the time of the extracted data values by the number of slides of the sliding window. In the example of Fig. 6, the change detection device 100 performs processing with the number of dimensions M of the first vector, which is the size of the window, being 2, and the number of slides of the data values being 1.
[0028] Next, the change detection device 100 extracts adjacent M data values from the second time series data as an M-dimensional second vector, and converts the second time series data into a set of multiple second vectors by sequentially sliding the time of the extracted data values by the number of slides of the sliding window. Note that the value of the number of dimensions M of the first and second vectors set as parameters can be set to any integer of 2 or more, and the value of the number of slides of the data values can be set freely, but it is preferable that the value of M and the value of the number of slides of the data values are the same in the process of converting the first time series data into multiple first vectors and the process of converting the second time series data into multiple second vectors.
[0029] Fig. 7 is a diagram showing a plurality of first vectors and a plurality of second vectors obtained by the vector acquisition process performed by change detection device 100 according to embodiment 1. In Fig. 7, a circle indicates a first vector, and an X indicates a second vector. In the vector acquisition process of step ST3, the number of dimensions M of the first vector and the second vector is 2, so the first vector and the second vector are shown on a two-dimensional plane shown in Fig. 7.
[0030] After performing the process of step ST3, the change detection device 100 performs a first difference vector acquisition process to calculate a difference vector between the first vector and the second vector acquired in the vector acquisition process of step ST3 (step ST4). In the first difference vector acquisition process as the difference vector acquisition process, the change detection device 100 calculates a specific first vector v i , a specific second vector v' from among the plurality of second vectors i Subtract the first difference vector r i Calculate.
[0031] 8A is a conceptual diagram showing the first difference vector acquisition process performed by change detection device 100 according to embodiment 1. In FIG. 8A, a circle indicates a first vector, and an X indicates a second vector. For example, in the first difference vector acquisition process, change detection device 100 uses a k-nearest neighbor algorithm (knn), which is a known algorithm, to obtain a specific second vector v' i The first vector v closest to i The extracted first vector v is extracted as shown in formula (1). i to the corresponding second vector v' i The process of subtracting is performed for each second vector to obtain the first difference vector r i By calculating the difference vectors, multiple first difference vectors are obtained. Note that when k in the k-nearest neighbor method is 2 or more, the difference vector r i v' is the average vector of the vectors in the k neighborhood i (knn) It is calculated using: r i =v i -v' i (knn) (i=1, 2,..., n)...(1) TIFF2024135425000002.tif16166
[0032] 8B is a diagram showing an example of a plurality of first difference vectors obtained by the first difference vector acquisition process performed by change detection device 100 according to Embodiment 1. The plurality of first difference vectors obtained by the first difference vector acquisition process in step ST4 naturally have different orientations and magnitudes.
[0033] When the process of step ST4 is performed, the change detection device 100 calculates each of the first difference vectors r i In the first normalization process, the change detection device 100 performs a first normalization process to normalize each first difference vector r i Let z be the first normal vector. i In other words, the change detection device 100 converts each first difference vector through the first normalization process so that the magnitude of each first difference vector becomes 1. In other words, the change detection device 100 unifies the magnitude of each first difference vector through the first normalization process. z i =r i / ||r i || (i=1, 2,..., n)...(2)
[0034] 8C is a diagram showing an example of a plurality of first normal vectors obtained by the first normalization process performed by the change detection device 100 according to the first embodiment. The change detection device 100 converts a plurality of first difference vectors having a dimension number M of 2 into a plurality of first normal vectors having a dimension number M of 2 by the first normalization process. These first normal vectors are distributed on a circumference of a circle with a radius of 1. Note that when the dimension number M is 3, the plurality of first normal vectors are distributed on a sphere, and when the dimension number M is 4 or more, the plurality of first normal vectors are distributed on a hypersphere.
[0035] After performing the process of step ST5, the change detection device 100 performs a first change score calculation process to calculate a first change score based on the multiple first normal vectors (step ST6). In the first change score calculation process as the change score calculation process, the change detection device 100 calculates and acquires a first change score, which is a value indicating the bias in distribution of the multiple first normal vectors, by the change score calculation unit 24.
[0036] For example, the change detection device 100 calculates a Rayleigh score R as the first change score using a known algorithm, as shown in Equation (3). TIFF2024135425000003.tif24166
[0037] The Rayleigh score R is a function of multiple first normal vectors z i When the distribution is uniform (uniform) on a circumference, a sphere, or a hypersphere, the value is close to zero, and when the distribution is biased, the value is large. Therefore, by evaluating the magnitude of the Rayleigh score, it is possible to determine whether or not there has been a characteristic change in the time series data. The change score calculated by the change score calculation unit 24 may be a value according to the bias (uniformity) of the distribution of the multiple first normal vectors, and may be, for example, a Gine score or an Ajne score obtained by a known algorithm.
[0038] Let i and j be indices of the first normal vector, z i and z j Let be two first normal vectors. Then, the Gine score F n and Ajne score A n is expressed by the following equations (4) and (5). TIFF2024135425000004.tif46166
[0039] Regarding the Gine score and the Ajne score, the terms defined by the Σ symbol can be interpreted as follows: if two first normal vectors are pointing in the same direction, the angle between the two first normal vectors is ψ ij is close to 0, so the values of the terms determined by the Σ symbol in the Gine score and Ajne score are close to 0. On the other hand, when the two first normal vectors are pointing in different directions, the angle ψ between the two first normal vectors is ij is greater than 0, the values of the terms determined by the Σ symbol in the Gine score and the Ajne score are greater than 0. Considering the above that a minus sign is placed before the term determined by the Σ symbol, the Gine score and the Ajne score will be large when the distribution of the first normal vector on a circle, a sphere, or a hypersphere is uniform (uniform), and will be small when the distribution is biased.
[0040] Fig. 9A is a conceptual diagram showing the first difference vector acquisition process performed by the change detection device 100 according to embodiment 1, Fig. 9B is a diagram showing an example of a plurality of first difference vectors obtained by the first difference vector acquisition process performed by the change detection device 100 according to embodiment 1, and Fig. 9C is a diagram showing an example of a plurality of first normalized vectors obtained by the first normalization process performed by the change detection device 100 according to embodiment 1. Figs. 9A, 9B, and 9C differ from Figs. 8A, 8B, and 8C in that the time series data acquired by the change detection device 100 in the process of step ST2 is data in a case where there is no characteristic change between the first time series data and the second time series data.
[0041] As shown in Figures 9A, 9B, and 9C, when the change detection device 100 performs processing using such time series data, the directions of the multiple first difference vectors obtained have little bias, and the multiple first normal vectors obtained are distributed approximately uniformly around the circumference.
[0042] FIG. 10A is a conceptual diagram showing the first difference vector acquisition process performed by the change detection device 100 according to the first embodiment, FIG. 10B is a diagram showing an example of a plurality of first difference vectors obtained by the first difference vector acquisition process performed by the change detection device 100 according to the first embodiment, and FIG. 10C is a diagram showing an example of a plurality of first normal vectors obtained by the first normalization process performed by the change detection device 100 according to the first embodiment. FIGS. 10A, 10B, and 10C are different from FIGS. 8A, 8B, and 8C in that the time-series data acquired by the change detection device 100 in the process of step ST2 includes a data value that is an outlier (singular value). In the present disclosure, an outlier simply means a data value whose difference when compared with other data values is greater than the difference between the other data values, and includes abnormal values due to human error when acquiring the data values and malfunction of a measuring device acquiring the data values.
[0043] As shown in FIGS. 10A and 10B , for example, when the second time-series data acquired by the change detection device 100 includes a data value that is an outlier, the first vectors include an outlier vector v x The first difference vectors include an outlier vector v x The outlier difference vector r obtained based on x However, as shown in FIG. 10C, in the change detection device 100 according to the first embodiment, each first difference vector r i By performing the first normalization process to normalize the outlier difference vector r x is converted to a normal vector with a magnitude of 1, so the outlier difference vector r x Therefore, the influence on the calculation result can be suppressed.
[0044] 4, after performing the process of step ST6, the change detection device 100 performs a second difference vector acquisition process (step ST8) to calculate a difference vector between the first vector and the second vector acquired in the vector acquisition process of step ST3. In the second difference vector acquisition process as the difference vector acquisition process, the change detection device 100 uses the difference vector acquisition unit 22 to calculate a specific second vector v' i From the first vector, a specific first vector v i Subtract the second difference vector r' i Calculate.
[0045] 11A is a conceptual diagram showing the second difference vector acquisition process performed by the change detection device 100 according to the first embodiment. In FIG. 11A, a circle indicates a first vector, and an X indicates a second vector. For example, in the second difference vector acquisition process, the change detection device 100 uses the k-nearest neighbor method to find a specific first vector v i The second vector v' closest to i Then, the extracted second vector v' is extracted as shown in Equation (6). i to the corresponding first vector v i The process of subtracting the first vector from the second vector r' is performed. i By calculating the above, multiple second difference vectors are obtained. Note that when k in the k-nearest neighbor method is 2 or more, the difference vector r' i is the first vector v, which is the average vector of the vectors in the k neighborhood i (knn) It is calculated using: r' i =v' i -v i (knn) (i=1, 2,..., n)...(6) TIFF2024135425000005.tif16166
[0046] FIG. 11B shows a plurality of second difference vectors r′ obtained by the second difference vector acquisition process performed by the change detection device 100 according to the first embodiment. i 1 is a diagram illustrating an example of a plurality of first difference vectors r obtained by the first difference vector acquisition process in step ST4. i Similarly, the plurality of second difference vectors r′ obtained by the second difference vector acquisition process in step ST8 i have different orientations and sizes.
[0047] After performing the process of step ST8, the change detection device 100 calculates each of the second difference vectors r′ calculated in the second difference vector acquisition process of step ST8. i In the second normalization process, the change detection device 100 performs a second normalization process to normalize each second difference vector r′ by the vector conversion unit 23 as shown in Equation (7). i to the second normal vector z' i In other words, the change detection device 100 uses the vector conversion unit 23 to unify the magnitudes of the second difference vectors. z' i =r' i / ||r' i || (i=1, 2,..., n)...(7)
[0048] FIG. 11C illustrates a plurality of second normal vectors z′ obtained by the second normalization process performed by the change detection device 100 according to the first embodiment. i 1 is a diagram illustrating an example of a plurality of second difference vectors r′, each of which has a dimension M of 2, by the second normalization process. i Let z' be a set of multiple second normal vectors with dimension M of 2. i These second normal vectors are distributed on a circle with a radius of 1. As with the first normal vectors, when the number of dimensions M is 3, the second normal vectors are distributed on a sphere, and when the number of dimensions M is 4 or more, the second normal vectors are distributed on a hypersphere.
[0049] After performing the process of step ST9, the change detection device 100 performs a second change score calculation process to calculate a second change score based on the multiple second normal vectors (step ST10). In the second change score calculation process as the change score calculation process, the change detection device 100 acquires the second change score by calculating the second change score as a change score that is a value indicating the bias in the distribution of the multiple second normal vectors using the change score calculation unit 24. For example, the change detection device 100 calculates the Rayleigh score R' as the second change score using a known algorithm shown in Equation (8) in the same way as the first change score calculation process. TIFF2024135425000006.tif20166
[0050] After performing the process of step ST10, change detection device 100 performs a maximum change score calculation process (step ST10) to calculate the maximum value of the first change score calculated in step ST6 and the second change score calculated in step ST10. In this process, change detection device 100 compares the calculated first change score and second change score, and selects the change score with the larger value. In other words, change detection device 100 selects the change score that indicates the largest change in the time-series data from among the multiple calculated change scores.
[0051] After the process of step ST11, the change detection device 100 performs a change detection process for detecting a change in the time series data by comparing the value of the change score calculated in step ST11 with a preset threshold (step ST12). In this process, the change detection device 100 compares the value of the change score calculated in step ST11 with a threshold preset by the parameter setting unit 26 by the change detection unit 25, and if the value of the change score exceeds the threshold, determines that there is a characteristic change in the time series data between the first time series data and the second time series data. Also, in this process, the change detection device 100 compares the value of the change score calculated in step ST11 with a threshold preset by the parameter setting unit 26 by the change detection unit 25, and if the value of the change score is within the threshold, determines that there is no characteristic change in the time series data between the first time series data and the second time series data.
[0052] For example, the change detection device 100 may acquire time series data during normal times without any distinctive changes in advance, and set the threshold value based on the normal time change score calculated based on the normal time series data. Specifically, the change detection device 100 may be configured to acquire time series data during normal times without any distinctive changes in advance, and set the threshold value to a value obtained by adding a predetermined value to the normal time change score calculated based on the normal time series data. In other words, the change detection device 100 is configured such that the time series data acquisition unit 10 acquires time series data for a period including a third period, which is a period prior to the first period, and a fourth period, which is a period between the third period and the first period; the vector acquisition unit 21 acquires, based on the time series data acquired by the time series data acquisition unit 10, a plurality of third vectors (first vectors) which are a plurality of partial time series data for the third period, and a plurality of fourth vectors (second vectors) which are a plurality of partial time series data for the fourth period; the difference vector acquisition unit 22 acquires difference vectors relating to combinations of a specific third vector among the multiple third vectors and a specific fourth vector among the multiple fourth vectors, for multiple combinations; and the parameter setting unit 26, acting as a threshold setting unit, sets a threshold based on the bias in the directional distribution of the multiple difference vectors acquired by the difference vector acquisition unit 22. Note that the third vector in the third period corresponds to the first vector in the first period, and the fourth vector in the fourth period corresponds to the second vector in the second period, and the difference between the first vector and the third vector, and the difference between the second vector and the fourth vector differ only in the periods during which they were acquired.
[0053] Note that change detection device 100 may be configured to calculate a plurality of change scores in advance for a plurality of time periods that are periods prior to the first time period, and set a threshold based on the calculated plurality of change scores. For example, change detection device 100 may be configured to set a value obtained by adding a predetermined value to a representative value, such as an average, median, or maximum value, of the plurality of change scores calculated in advance as the threshold.
[0054] After performing the process of step ST12, the change detection device 100 outputs a determination result of whether or not there is a characteristic change in the time-series data as a comparison result by the change detection unit 25 (step ST13). For example, in this process, the change detection device 100 causes the output unit 30 to display information corresponding to the determination result on a display device (not shown). Also, for example, in this process, the change detection device 100 causes the output unit 30 to transmit information corresponding to the determination result to an external device (not shown). After performing the process of step ST13, the change detection device 100 ends the process.
[0055] As described above, the change detection device 100 in the first embodiment includes a time series data acquisition unit 10 that acquires time series data for a period including a first period and a second period that is a period subsequent to the first period; a vector acquisition unit 21 that acquires a plurality of first vectors which are a plurality of partial time series data for the first period and a plurality of second vectors which are a plurality of partial time series data for the second period based on the time series data acquired by the time series data acquisition unit 10; a difference vector acquisition unit 22 that acquires difference vectors relating to combinations of a specific first vector among the multiple first vectors and a specific second vector among the multiple second vectors for a plurality of combinations; and a change detection unit 25 that detects a characteristic change in the time series data based on a bias in the directional distribution of the multiple difference vectors acquired by the difference vector acquisition unit 22.
[0056] In this way, the change detection device 100 of embodiment 1 detects characteristic changes in time series data based on the directional bias of multiple difference vectors without taking into account the magnitudes of multiple difference vectors obtained based on time series data, thereby making it possible to suppress the influence of outliers contained in the time series data and to improve the accuracy of detecting characteristic changes in time series data, i.e., changes in trends in the time series data, compared to conventional methods.
[0057] In addition, the change detection device 100 according to embodiment 1 has fewer constraints on the length and number of pieces of time-series data required to detect characteristic changes in time-series data, and is therefore capable of detecting characteristic changes in time-series data with a small amount of data, compared to other change detection algorithms, such as the KL-CPD method, which may be unable to find a kernel function required for change detection if the number of pieces of data after a change is small.
[0058] Moreover, the change detection device 100 according to embodiment 1 includes a vector conversion unit 23 that acquires vectors by converting each of the multiple difference vectors acquired by the difference vector acquisition unit 22 so as to unify the magnitude without changing the direction, and the change detection unit 25 detects a characteristic change in the time series data based on the bias in the distribution of the directions of the vectors acquired by the vector conversion unit 23.
[0059] The vector acquisition unit 21 according to the first embodiment acquires a plurality of first vectors by sliding a sliding window in time series data for a first period, and acquires a plurality of second vectors by sliding the sliding window in time series data for a second period.
[0060] The difference vector acquisition unit 22 according to the first embodiment extracts, for each of a plurality of first vectors, a closest second vector from among a plurality of second vectors, and acquires a plurality of difference vectors based on the differences between each of the plurality of first vectors and the extracted second vector.
[0061] In the change detection device 100 according to the first embodiment, the multiple difference vectors are multiple first difference vectors, and the difference vector acquisition unit 22 extracts the closest first vector from among the multiple first vectors for each of the multiple second vectors, and acquires multiple second difference vectors based on the differences between each of the multiple second vectors and the extracted first vector, and the change detection unit 25 detects a characteristic change in the time series data based on the bias in the distribution of the directional vector that is larger among the multiple first difference vectors acquired by the difference vector acquisition unit 22 and the multiple first difference vectors.
[0062] Change detection device 100 according to embodiment 1 includes a change score calculation unit 24 that calculates a change score according to the bias in the distribution of directions of a plurality of difference vectors, and change detection unit 25 detects a characteristic change in the time series data based on whether or not the change score calculated by change score calculation unit 24 exceeds a preset threshold value.
[0063] The change detection device 100 according to the first embodiment includes a parameter setting unit 26 that sets a threshold value, and the time series data includes a third period, which is a period prior to the first period, and a fourth period, which is a period between the third period and the first period. The vector acquisition unit acquires a plurality of third vectors, which are a plurality of partial time series data in the third period, and a plurality of fourth vectors, which are a plurality of partial time series data in the fourth period, based on the time series data acquired by the time series data acquisition unit. The differential vector acquisition unit 22 acquires differential vectors relating to a combination of a specific third vector among the multiple third vectors and a specific fourth vector among the multiple fourth vectors, in a plurality of combinations. The parameter setting unit 26 sets a threshold value based on the bias in the directional distribution of the multiple differential vectors acquired by the differential vector acquisition unit 22.
[0064] In the first embodiment, change detection device 100 is configured to detect a characteristic change in the time-series data by comparing the change score calculated by change score calculation unit 24 with a preset threshold value, but is not limited to this. The change detection device only needs to be configured to detect a characteristic change in the time-series data based on the change score, and may be configured to detect a characteristic change in the time-series data based on, for example, the amount of change in the change score or the rate of change in the change score.
[0065] In the first embodiment, the change detection device 100 acquires a plurality of first vectors and a plurality of second vectors with the number of dimensions M of the vector acquired in the vector acquisition process being 2 and the number of slides being 1, but is not limited to this. The change detection device 100 may be configured to appropriately set the number of dimensions M of the vector and the number of slides by the parameter setting unit 26.
[0066] FIG. 12 is a conceptual diagram showing a vector acquisition process performed by the change detection device 100 according to the first embodiment. As shown in FIG. 12, the change detection device 100 acquires N sets of vectors with a dimension number of M from time series data of a predetermined length. Note that FIG. 12 shows an example in which the number of slides when the change detection device 100 acquires N sets of vectors with a dimension number of M is 1, but as described above, the number of slides may be other than 1. For example, the parameter setting unit 26 may be configured to set the number of slides based on the time series data acquired by the time series data acquisition unit 10. Specifically, the parameter setting unit 26 may be configured to set the number of slides to be relatively small when the time series data acquired by the time series data acquisition unit 10 is time series data with a relatively large fluctuation in a short time. In addition, the parameter setting unit 26 may be configured to set the number of slides to be relatively large when the time series data acquired by the time series data acquisition unit 10 is time series data with a relatively small fluctuation in a short time. In addition, the parameter setting unit 26 may be configured to dynamically change the number of slides by observing a change in the time series data.
[0067] The parameter setting unit 26 may be configured to appropriately set the sliding window length, which is the number of dimensions M of the first and second vectors acquired by the vector acquiring unit 21, but when the difference vector acquiring unit 22 calculates the difference vector, the number of dimensions of the first and second vectors is required to match. In addition, when the length of the time-series data acquired by the time-series data acquiring unit 10 is longer than the sum of the first and second periods, the change detection device 100 may set various parameters to new values after performing the processes from step ST2 to step ST13 shown in FIG. 4, and perform the processes from step ST2 to step ST13 again.
[0068] Next, with reference to Figs. 13 to 16, a specific example of detecting a characteristic change in time-series data using the change detection device 100 according to the first embodiment will be described. First, with reference to Figs. 13 and 14, an example of detecting a characteristic change in vibration data of a timing gear using the change detection device 100 according to the first embodiment will be described. Fig. 13 is a schematic diagram showing timing gears G1 and G2 whose vibration change is detected by the change detection device 100 according to the first embodiment, Fig. 14A is a graph showing the vibration data of the timing gears G1 and G2 as time-series data acquired by the change detection device 100 according to the first embodiment, and Fig. 14B is a graph showing a change score calculated by the change detection device 100 according to the first embodiment based on the vibration data of the timing gears G1 and G2.
[0069] Generally, the vibration of a timing gear changes due to changes such as wear, scratches, chipping, adhesion of foreign matter, etc. Therefore, by detecting characteristic changes in the vibration data of the timing gear, it is possible to detect these changes related to the timing gear.
[0070] The graph shown in Fig. 14A is vibration data showing vibration levels acquired by a vibration sensor from timing gears G1 and G2 at a cycle of, for example, 1 second. The graph shown in Fig. 14B is a transition of the change score calculated using the vibration data of timing gears G1 and G2 with the number of dimensions M of the first vector and the second vector set to 10. It can be seen from Fig. 14B that the value of the change score also changes to become larger at the time when the vibration data changes.
[0071] Next, with reference to Fig. 15, an example of detecting a characteristic change in gas consumption of a specific consumer using change detection device 100 according to embodiment 1 will be described. Fig. 15 is a graph showing gas consumption data as time-series data acquired by change detection device 100 according to embodiment 1 and a change score calculated based on the gas consumption data. The change score graph shown in Fig. 15 shows the progress of the change score calculated with the number of dimensions M of the first vector and the second vector set to 10. In Fig. 15, the vertical axis represents the value of gas consumption in cubic meters, and the change score is a dimensionless number expressed from 0 to 1, with a common scale.
[0072] In general, gas consumption varies with changes in the number of people (family composition) of consumers, changes in gas consumption facilities such as the introduction of new gas appliances, changes in lifestyle, changes in temperature, etc. As shown in Fig. 15, when change detection device 100 acquires data on gas consumption of consumers for a specified period as time-series data, it can be seen that gas consumption changes during Golden Week and the Obon holiday period, and that the change score value increases during the same periods.
[0073] Next, with reference to Fig. 16, an example of detecting a characteristic change in a stock index using change detection device 100 according to embodiment 1 will be described. Fig. 16A is a graph showing the transition of daily closing prices of the Tokyo Stock Price Index (TOPIX) as time-series data acquired by change detection device 100 according to embodiment 1, and Fig. 16B is a graph showing change scores calculated by change detection device 100 according to embodiment 1 based on the data of the TOPIX. The graph of change scores shown in Fig. 16 shows the transition of change scores calculated with the number of dimensions M of the first vector and the second vector set to 10.
[0074] Generally, the period known as the bubble economy is said to be the period from December 1986 to February 1991. In conventional research on stock prices, attention is often paid to fluctuations (volatility, magnitude of difference), but as shown in Figs. 16A and 16B, it can be seen that the magnitude of fluctuations and the change score do not necessarily match. According to the change detection device 100 of the first embodiment, as shown in Fig. 16B, the change score changes to become larger on November 5, 1986 and December 20, 1990, and the change in the stock index can be detected earlier than the timing generally known as the beginning of the bubble economy and earlier than the timing generally known as the end of the bubble economy.
[0075] In addition, in the present disclosure, any of the components of the embodiments may be modified or any of the components may be omitted. [Explanation of symbols]
[0076] 10: Time series data acquisition section 20: Arithmetic section 21: Vector acquisition section 22: Differential vector acquisition section 23: Vector conversion section 24: Change score calculation section 25: Change detection section 26: Parameter setting section (threshold setting section) 30: Output section 100: Change detection device
Claims
1. a time series data acquisition unit that acquires time series data for a period including a first period and a second period that is a period subsequent to the first period; a vector acquisition unit that acquires, based on the time series data acquired by the time series data acquisition unit, a plurality of first vectors that are a plurality of partial time series data in the first period and a plurality of second vectors that are a plurality of partial time series data in the second period; a difference vector acquisition unit that acquires a difference vector relating to a combination of a specific first vector of the plurality of first vectors and a specific second vector of the plurality of second vectors for a plurality of combinations; a change detection unit that detects a characteristic change in the time series data based on a bias in the directional distribution of the plurality of difference vectors acquired by the difference vector acquisition unit. A change detection device comprising:
2. a vector conversion unit that converts each of the plurality of difference vectors acquired by the difference vector acquisition unit so as to unify the magnitude of the vector without changing the direction, The change detection unit detects a characteristic change in the time series data based on a bias in the distribution of the vector directions acquired by the vector conversion unit.
2. The change detection device according to claim 1.
3. The vector acquisition unit acquires the first vectors by sliding a sliding window in the time series data for the first period, and acquires the second vectors by sliding a sliding window in the time series data for the second period.
2. The change detection device according to claim 1.
4. The difference vector acquisition unit extracts a closest second vector from among the plurality of second vectors for each of the plurality of first vectors, and acquires the plurality of difference vectors based on a difference between each of the plurality of first vectors and the extracted second vector.
2. The change detection device according to claim 1.
5. the plurality of difference vectors are a plurality of first difference vectors, the difference vector acquisition unit extracts a closest first vector from among the plurality of first vectors for each of the plurality of second vectors, and acquires a plurality of second difference vectors based on differences between each of the plurality of second vectors and the extracted first vector; The change detection unit detects a characteristic change in the time series data based on a bias in a distribution direction of one of the plurality of first difference vectors acquired by the difference vector acquisition unit and the plurality of first difference vectors, the bias in the distribution direction of which is larger.
5. The change detection device according to claim 4.
6. a change score calculation unit that calculates a change score according to a bias in distribution of the directions of the plurality of difference vectors; The change detection unit detects a characteristic change in the time-series data based on whether or not the change score calculated by the change score calculation unit exceeds a preset threshold value.
2. The change detection device according to claim 1.
7. A threshold setting unit that sets the threshold, the time series data includes a third period that is a period before the first period, and a fourth period that is a period between the third period and the first period, the vector acquisition unit acquires, based on the time series data acquired by the time series data acquisition unit, a plurality of third vectors which are a plurality of partial time series data in the third period and a plurality of fourth vectors which are a plurality of partial time series data in the fourth period; the difference vector acquisition unit acquires difference vectors relating to a combination of a specific third vector among the plurality of third vectors and a specific fourth vector among the plurality of fourth vectors, for a plurality of combinations; The threshold setting unit sets the threshold based on a bias in a distribution of directions of the plurality of difference vectors acquired by the difference vector acquisition unit.
7. The change detection device according to claim 6.
8. the time series data acquisition unit acquires data on gas consumption during a predetermined period as the time series data, The change detection unit detects a characteristic time change in the gas consumption amount based on a bias in a direction of the difference vector acquired by the difference vector acquisition unit.
8. A change detection device according to claim 1, wherein the change detection device is a change detection device.
9. A change detection method performed by an apparatus including a time series data acquisition unit, a vector acquisition unit, a difference vector acquisition unit, and a change detection unit, comprising: The time series data acquisition unit acquires time series data for a period including a first period and a second period that is a period after the first period; a step in which the vector acquisition unit acquires, based on the time series data acquired by the time series data acquisition unit, a plurality of first vectors which are a plurality of partial time series data in the first period and a plurality of second vectors which are a plurality of partial time series data in the second period; a step in which the difference vector acquisition unit acquires difference vectors relating to a combination of a specific first vector among the plurality of first vectors and a specific second vector among the plurality of second vectors, for a plurality of combinations; The change detection unit detects a characteristic change in the time series data based on a bias in a directional distribution of the plurality of difference vectors acquired by the difference vector acquisition unit.
13. A change detection method comprising:
Citation Information
Patent Citations
Device, method and program for detecting anomaly, and recording medium
JP2006048253A
Change Detection Using Directional Statistics
US20170322114A1
