KR20230030542A - AI-based facility data anomaly detection system and method using random cut forest algorithm - Google Patents

AI-based facility data anomaly detection system and method using random cut forest algorithm Download PDF

Info

Publication number
KR20230030542A
KR20230030542A KR1020220105115A KR20220105115A KR20230030542A KR 20230030542 A KR20230030542 A KR 20230030542A KR 1020220105115 A KR1020220105115 A KR 1020220105115A KR 20220105115 A KR20220105115 A KR 20220105115A KR 20230030542 A KR20230030542 A KR 20230030542A
Authority
KR
South Korea
Prior art keywords
data
facility
anomaly detection
tree
forest algorithm
Prior art date
Application number
KR1020220105115A
Other languages
Korean (ko)
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 KR20230030542A publication Critical patent/KR20230030542A/en

Links

Images

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B23/00Testing or monitoring of control systems or parts thereof
    • G05B23/02Electric testing or monitoring
    • G05B23/0205Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults
    • G05B23/0218Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults characterised by the fault detection method dealing with either existing or incipient faults
    • G05B23/0243Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults characterised by the fault detection method dealing with either existing or incipient faults model based detection method, e.g. first-principles knowledge model
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B23/00Testing or monitoring of control systems or parts thereof
    • G05B23/02Electric testing or monitoring
    • G05B23/0205Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults
    • G05B23/0218Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults characterised by the fault detection method dealing with either existing or incipient faults
    • G05B23/0221Preprocessing measurements, e.g. data collection rate adjustment; Standardization of measurements; Time series or signal analysis, e.g. frequency analysis or wavelets; Trustworthiness of measurements; Indexes therefor; Measurements using easily measured parameters to estimate parameters difficult to measure; Virtual sensor creation; De-noising; Sensor fusion; Unconventional preprocessing inherently present in specific fault detection methods like PCA-based methods
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B23/00Testing or monitoring of control systems or parts thereof
    • G05B23/02Electric testing or monitoring
    • G05B23/0205Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults
    • G05B23/0259Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults characterized by the response to fault detection
    • G05B23/0267Fault communication, e.g. human machine interface [HMI]
    • G05B23/027Alarm generation, e.g. communication protocol; Forms of alarm
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B23/00Testing or monitoring of control systems or parts thereof
    • G05B23/02Electric testing or monitoring
    • G05B23/0205Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults
    • G05B23/0259Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults characterized by the response to fault detection
    • G05B23/0283Predictive maintenance, e.g. involving the monitoring of a system and, based on the monitoring results, taking decisions on the maintenance schedule of the monitored system; Estimating remaining useful life [RUL]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning

Abstract

Disclosed are an AI-based facility data anomaly detection system using the Random Cut Forest (RCF) algorithm and a method thereof. The present invention is to solve problems including a non-labeled data problem, a data imbalance problem, a detection performance problem, and a computing performance problem, which are features of facility data. Accordingly, the present invention can improve a problem that production is delayed since a facility operation is impossible and time is consumed for collecting broken components when a facility breaks down in a factory operating the facility, detect a facility breakdown in advance when a facility anomaly is detected by collecting facility data, inspect the anomaly in advance to order a component of the breakdown so as to minimize facility stop time, repair the facility, improve productivity, and prevent reduction in quality due to the breakdown, and improve a safety problem of workers and a problem of high costs caused by a severely broken facility when a severe breakdown occurs by not detecting the facility breakdown in advance.

Description

랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템과 그 방법 {AI-based facility data anomaly detection system and method using random cut forest algorithm} AI-based facility data anomaly detection system and method using random cut forest algorithm {AI-based facility data anomaly detection system and method using random cut forest algorithm}

본 발명은 절삭가공 설비에서 수집되는 스핀들 로드 데이터와 로봇 진동 데이터 기반으로 향상된 랜덤 컷 포레스트 알고리즘을 활용하여 설비 이상을 감지하는 설비 데이터 이상 감지를 위한 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템과 그 방법에 관한 것이다.The present invention detects an AI-based facility data anomaly using a random cut forest algorithm for facility data anomaly detection by utilizing an improved random cut forest algorithm based on spindle load data and robot vibration data collected from cutting facilities. It is about the system and its methods.

일반적으로, 설비 데이터를 활용한 인공지능(AI) 기반의 이상 감지 알고리즘들이 개시되고 있다.In general, artificial intelligence (AI)-based anomaly detection algorithms using facility data have been disclosed.

구체적으로, 학습모델을 동적으로 구성하는 알고리즘은 랜덤 컷 포레스트 알고리즘(RCF)이고 이는 스트리밍 데이터 이상감지에 활용되는 것으로서 미국의 아마존의 이상감지 주요 알고리즘으로 탑재되어 있다.Specifically, the algorithm that dynamically configures the learning model is the Random Cut Forest Algorithm (RCF), which is used for detecting anomalies in streaming data and is installed as a major algorithm for anomaly detection by Amazon in the United States.

그러나, 상기 랜덤 컷 포레스트 알고리즘(RCF)은 스트리밍 데이터 처리에 특화되어 있고 학습 모델을 재구성하기 위해서 삽입과 삭제 과정을 거치는데 이부분에서 컴퓨팅 연산량이 많아 이상점수 계산에 속도가 오래걸리는 단점이 있고, 재구성을 위한 특성별 바운딩박스(예; 최저값, 최대값)을 각 노드별로 데이터를 저장하고 있어 학습모델의 용량이 무거운 단점이 있었다.However, the random cut forest algorithm (RCF) is specialized in processing streaming data and goes through insertion and deletion processes to reconstruct the learning model. In this part, the amount of computational computation is large, so it takes a long time to calculate the ideal score, There was a disadvantage in that the capacity of the learning model was heavy because data was stored for each node in the bounding box for each characteristic for reconstruction (e.g. minimum value, maximum value).

한편, 설비 데이터에 대한 이상 감지(Anomaly Detection)는 "이상징후감지"라고도 하며, 이는 적은 이상 데이터와 많은 정상 데이터 이상감지의 실제 업무에 적용하려고 하면 찾아야 하는 이상한 패턴은 매우 적고 정상인 데이터가 대부분인 경우가 많다. 따라서 대량의 데이터를 뒤져서 얼마되지 않는 이상한 패턴의 데이터를 찾아내거나 빠르게 감지해야 하기 때문에 소모되는 비용 대비 결과물의 가치가 매우 떨어진다.On the other hand, anomaly detection for equipment data is also called "anomaly detection", and this means that if you try to apply the anomaly detection of a small amount of abnormal data and a lot of normal data to actual work, there are very few abnormal patterns to be found and most of the normal data is There are many. Therefore, since it is necessary to search through a large amount of data to find a small number of strange pattern data or quickly detect it, the value of the result is very low compared to the cost consumed.

○ [시계열 데이터 분석과 이상감지]○ [Time series data analysis and anomaly detection]

이상감지는 시계열 또는 시퀀스 분석의 일종이라고 생각하는 것이 기술적인 측면에서 처음 개념을 잡을 때 편할 것이다. 하지만 통계학에서 말하는 시계열, 시퀀스 분석과 완전히 동일한 것이 아니라는 것에 주의할 필요가 있다.It would be convenient to think of anomaly detection as a kind of time series or sequence analysis when first grasping the concept from a technical point of view. However, it is important to note that it is not exactly the same as time series and sequence analysis in statistics.

이상감지는 이상한 패턴을 찾아내는 것이고 패턴이라는 말은 반복되는 모양, 위치와 같은 것도 있지만 시간 흐름에서 과거 흐름과 다르게 나타나거나 다수의 데이터 흐름과는 다르게 나타나는 것을 찾는 것이다.Anomaly detection is to find a strange pattern, and the word pattern means to find something that appears different from the past flow in the time stream or different from multiple data flows, although there are things such as repeated shapes and locations.

이상감지는 데이터 마이닝의 한 분야로 데이터 마이닝에서는 통계적 기법이 되었든 수학적 방법이든 기계 학습이든 가리지 않고 사용하는 것이다.Anomaly detection is a field of data mining, and in data mining, it is used regardless of whether it is a statistical technique, a mathematical method, or machine learning.

○ [시계열 데이터의 이상감지]○ [Anomaly detection of time series data]

시계열 데이터에서 과거 또는 비슷한 시점의 다른 데이터의 보편적인 패턴에서 벗어나거나 벗어나려는 징후가 있는 드문 패턴이나 사실, 대상 개체를 찾아내는 것이다. 흔히 말하는 이상감지는 모두 여기에 해당한다.In time-series data, it is to find rare patterns, facts, or target entities that deviate from or show signs of departing from the general patterns of other data in the past or at a similar point in time. All common anomaly detections fall under this category.

이상감지는 실시간으로 현재의 이상한 것 또는 가까운 미래에 큰 위험을 만들 여지가 있는 패턴을 발견했는지가 중요하기 때문이다.This is because anomaly detection is important in real-time whether it detects something unusual in the present or a pattern that could create a big risk in the near future.

○ [횡단면 데이터의 이상감지]○ [Anomaly detection of cross section data]

시계열이 아닌 것 중에 이상한 것을 찾는 것은 대부분 아웃라이어 감지에서 다루고 있다. 아웃라이어 감지와 이상감지를 동일하게 취급하거나 구분하지 않는 경우도 있는데 이상감지도 넓은 의미에서는 아웃라이어 감지라고 볼 수 있기 때문이다. 그러나, 아웃라이어를 찾는 것은 원론적으로 말하면 이상감지에 포함되지 않는다.Finding outliers in non-time series is mostly covered by outlier detection. There are cases where outlier detection and anomaly detection are treated the same or not distinguished, because anomaly detection can also be regarded as outlier detection in a broad sense. However, finding outliers is not included in anomaly detection, theoretically speaking.

상기 아웃라이어가 이상하다는 의미가 아니기 때문이다. 아웃라이어를 찾는 방법은 흔히 통계학에서 기술통계(descriptive statistics)에서 다루고 있다.This is because it does not mean that the outliers are abnormal. Methods for finding outliers are often covered in descriptive statistics in statistics.

○ [이상감지와 기계학습]○ [Anomaly Detection and Machine Learning]

이상감지를 처음 접하는 사람들 중에 기계학습에 대한 사전지식이 있거나 학습이 되어 있는 사람들은 오히려 전혀 모르는 사람에 비해서 이상감지가 기계학습으로 해야 하는 것인지 아니면 통계적인 방법인지 또는 그 외에 방법으로 접근해야 하는지 구별하지 못하는 경우가 많다.Among those who are new to anomaly detection, those who have prior knowledge or have been trained in machine learning distinguish whether anomaly detection should be done with machine learning, statistical methods, or other approaches, compared to those who have no knowledge at all. often can't

결론을 말하면 이상감지는 기계학습 알고리즘을 사용할 수도 있고 통계학의 방법을 사용할 수도 있다. 이상감지에서 사실 수단은 별로 중요하지 않으며 결과를 더 우선한다. 하지만 보편적으로 지금까지 지도식 기계 학습 방법으로는 잘 되지 않는다. 현재까지 가장 많이 사용되는 이상감지 기술은 통계학에서 사용하는 통계적 기술이 더 많이 사용되고 일부 딥러닝(Deep learning)이나 비지도 학습(Unsupervised learning)이 사용된다.In conclusion, anomaly detection can use either a machine learning algorithm or a statistical method. In anomaly detection, in fact, the means are not so important and the result is given priority. But in general, so far, supervised machine learning methods have not worked well. As for the anomaly detection technique that is most commonly used to date, statistical techniques used in statistics are used more often, and some deep learning or unsupervised learning are used.

○ [기계학습을 통한 이상감지 모델의 실패 이유]○ [Reason for failure of anomaly detection model through machine learning]

이상감지에 대한 문제를 처음 접하는 사람들 중에 기계학습에 대한 지식이 있는 사람들은 이상감지를 위해서 지도학습모형(supervised learning model)을 사용하려고 하는 경향이 많은데 이것 자체는 잘못된 접근방법은 아니다. 하지만 현실에서 부딪히는 문제는 이렇게 접근할 때 몇 가지 장벽을 만난다. 쉽게 말하면 이제 이 방법으로 이상감지를 해결하는 시도는 잘 하지 않는다.Among those new to the problem of anomaly detection, those with knowledge of machine learning tend to use a supervised learning model for anomaly detection, but this in itself is not a wrong approach. However, in real life, there are several barriers to this approach. To put it simply, we don't try to solve the anomaly detection with this method anymore.

지도학습 기반의 기계학습으로 이상감지를 해야 한다면 흔히 다음과 같은 생각이 먼저 떠오를 것이다.If you need to detect anomalies with supervised machine learning, the following thoughts will often come to your mind first.

[1]. 이상한 것으로 태깅한 데이터(training set)를 만들고 모형을 생성한 뒤에 생성된 모형으로 새로운 데이터에서 이상여부를 감지하는 것을 시도한다.[One]. After making the data (training set) tagged as strange and creating a model, try to detect anomalies in the new data with the created model.

[2]. 기존에 발견된 이상 사례와 정상 데이터를 적절히 섞어서 긍정과 부정의 양이 균형된 학습데이터셋을 만들어서 모형을 생성한 후에 이상여부를 감지하는 것을 시도한다.[2]. We attempt to detect anomalies after creating a model by creating a learning dataset with a balanced amount of positive and negative by properly mixing previously found abnormal cases and normal data.

[3]. 알고리즘으로 회귀 또는 SVM, 결정트리(Decision Tree), 딥러닝 등의 알고리즘을 사용해서 판별하는 모델을 만든다.[3]. As an algorithm, a discriminant model is created using an algorithm such as regression or SVM, decision tree, or deep learning.

상기 [1],[2],[3]에서 생각하는 것은 흔히 기계학습기법으로 분류, 예측 모델(prediction model)을 만드는 것과 완전히 같다.Thinking in [1], [2], and [3] is exactly the same as making classification and prediction models with machine learning techniques.

그러나, 문제가 되는 것은 실제 이상사례라는 케이스가 너무 적어서 제대로 된 학습데이터(training set)를 확보하기가 어렵다는 것이다.However, the problem is that there are too few cases of actual abnormal cases, so it is difficult to secure proper training data.

즉, 다음과 같은 문제가 생긴다.That is, the following problem arises.

[1]. 이상하다고 규정할 사례가 매우 적다. 정답데이터셋(training set)의 참값을 가진 데이터(true set)가 매우 적거나 아예 존재하지 않는다.[One]. There are very few cases that can be defined as strange. There are very few or no true data in the training set.

[2]. 이상한 것이라고 사람이 지목한 것이 매우 애매하게 다른 정상인것과 뚜렷하게 구분되지 않는다. 구분할 수 있는 명확한 변수(variable), 자질(feature)을 찾기 힘들다.[2]. What people refer to as strange is very vague and is not clearly distinguished from other normal things. It is difficult to find a clear variable or feature that can be distinguished.

[3]. 정황상(경험상) 이상한 것이 맞다고 어떤 상황 또는 데이터에 대해 판단했으나 정량적으로 이를 판별할 관측데이터가 없거나 만들기 어렵다. 감지할 때 사용할 수 있는 변수(variable)나 자질(feature)로 사용할 데이터를 얻을 수 없으며 사후에 결과적으로 알아낼 수 밖에 없다.[3]. Circumstantial (experience), it is judged about a certain situation or data that something strange is correct, but there is no observation data to quantitatively determine it, or it is difficult to make it. It is not possible to obtain data to be used as a variable or feature that can be used when detecting, and it is inevitable to find out as a result after the fact.

딥러닝을 선호하는 사람들을 위한 관점에서 말한다면 실제 사례(ground-truth)가 별로 없으며, 이는 학습데이터가 턱없이 부족하기 때문이다.From the point of view of people who prefer deep learning, there are few ground-truths, and this is because training data is sorely lacking.

따라서 학습데이터의 증폭 또는 정답 데이터를 자동으로 수집해주는 모델이 아닌 경우는 현실성이 없다. 이런 문제로 흔히 기계학습의 지도학습 중에서 분류(prediction, classification) 문제를 해결하기 위해 사용하는 Decision Tree, SVM, Regression, DNN 같은 알고리즘들은 이상징후 감지에 사용하기 어렵다고 알려져 있다.Therefore, it is not realistic if it is not a model that amplifies learning data or automatically collects correct answer data. Due to this problem, algorithms such as Decision Tree, SVM, Regression, and DNN, which are commonly used to solve classification (prediction, classification) problems among supervised machine learning, are known to be difficult to use for anomaly detection.

○ [비지도학습(Unsupervised Learning)을 통한 이상감지]○ [Anomaly detection through unsupervised learning]

지도학습으로 이상감지를 하기 어렵다면 비지도학습을 통해서 문제를 해결하려 할 수도 있다. 상기 비지도학습도 사실 어려운데 이상감지는 판별의 문제이기 때문에 비지도학습과 같이 멋대로 분리해 해내는 방식으로도 어렵다. 어떻게 하든 이상한 것이라고 정의된 어떤 것들을 찾아내야 한다는 것이다.If it is difficult to detect anomalies with supervised learning, you can try to solve the problem with unsupervised learning. The above unsupervised learning is also difficult in fact, but since anomaly detection is a problem of discrimination, it is difficult to separate and accomplish it arbitrarily like unsupervised learning. One way or another, you have to find some things that are defined as strange.

비지도 학습은 정답을 주고 비슷한 것을 찾는 문제를 해결하는 것은 일반적으로 부적합하다. 이상한 것이 아니라 따로 묶인 군집들을 구분해서 제시해 줄텐데 분리된 군집들 중에 이상한 것만 모여있는 모델을 만드는 것은 매우 어렵다.Unsupervised learning is generally unsuitable for solving problems of giving correct answers and finding similar ones. It is not strange, but we will present separately grouped clusters, but it is very difficult to create a model in which only strange groups are gathered among separated clusters.

그래도 비지도학습에서는 최근에 랜덤 컷 포레스트(Random Cut Forest)라는 알고리즘이 알려졌고 이상감지에 가장 유력하게 쓸 수 있는 모델 알고리즘으로 알려졌다. 실제 성능도 다른 알고리즘에 비해 보편적으로 좋은 편이다.Still, in unsupervised learning, an algorithm called Random Cut Forest has recently been known, and it is known as the model algorithm that can be used most powerfully for anomaly detection. The actual performance is generally good compared to other algorithms.

○ [반지도학습(Semi-Supervised Learning)을 통한 이상감지]○ [Anomaly Detection through Semi-Supervised Learning]

기계학습을 이용한 방법 중에 가장 유력한 방법일 것이다. 소량의 정답데이터를 이용해서 비슷한 것을 찾아내거나 학습데이터를 확장시키는 방법이다. 문제는 이 기법 자체가 매우 어려운 기법이고 좋은 모델을 만드는데 시간이 너무 오래 소요되는 것이다. 또 확장한 정답데이터가 어느 수준까지 정답으로 인정해야 할 것인지를 결정해야 하는 문제가 남게 된다.It is probably the most powerful method among the methods using machine learning. It is a method of finding something similar using a small amount of correct answer data or expanding the learning data. The problem is that this technique itself is a very difficult technique and it takes too long to create a good model. In addition, there remains a problem of determining to what level the expanded answer data should be recognized as a correct answer.

○ [이상감지와 통계적 방법]○ [Anomaly Detection and Statistical Methods]

이상감지에 통계적인 방법이 주로 사용되는 이유는 통계학이 다루는 가장 기본적인 것이 보편성에 어긋나는지 아닌지를 확인하는 것이기 때문이다. "이상한 것"이라는 것은 좁은 의미로는 보편성에서 벗어난 것을 말하기 때문이다. 여기서 보편성을 어긋난 것을 "아웃라이어"라고 한다. 상기 아웃라이어를 다루는 것은 통계학이 전부이다.The reason why statistical methods are mainly used for anomaly detection is that the most basic thing that statistics deals with is to check whether or not it goes against universality. This is because “strange things” in a narrow sense refer to things that deviate from universality. Here, the deviation from universality is called an "outlier." Dealing with the outliers is all about statistics.

상기 통계학을 통한 이상감지를 하기 위해서는 다음과 같은 갈래에서 출발하는 것이 일반적이다.In order to detect anomalies through the above statistics, it is common to start from the following branches.

- 아웃라이어 판별- Outlier detection

- 시계열 분석 기법 활용- Utilization of time series analysis techniques

- 확률 모델 할용(베이지안)- Use a probabilistic model (Bayesian)

위와 관련된 것은 너무 많아서 여기에 일일히 나열하기 어렵다. 즉 위와 관련된 모델이나 알고리즘 중에서 대부분의 문제를 해결할 수 있는 가장 유력하고 좋은 알고리즘이나 방법은 아직 없다.The above are too numerous to list here. That is, among the models and algorithms related to the above, there is still no most powerful and good algorithm or method that can solve most of the problems.

위의 것 중에 가장 좋은 성능을 보이는 것은 베이지안 모델이라고 알려졌지만 두각을 나타내는 특별한 알고리즘은 없다.Among the above, the best performance is known as the Bayesian model, but there is no special algorithm that stands out.

○ [대상의 문제 발생 시점에 의한 구분]○ [Classification according to the time of occurrence of the problem of the subject]

이상감지는 찾아내고자 하는 문제가 발생하는 시점을 기준으로 두 분류로 나눌 수 있다.Anomaly detection can be divided into two categories based on the time when the problem to be found occurs.

[1]. 어떤 대상의 현재까지의 상태가 이상한지를 감지하는 것[One]. Detecting if an object's current state is abnormal

[2]. 어떤 대상이 미래에 문제가 발생할 여지가 있는지 감지하는 것[2]. Detecting which objects are likely to cause problems in the future

상기 [1],[2]는 거의 같은 말처럼 보이지만 난이도가 매우 다르며 접근 방법도 매우 달라진다. 아직까지 현실에서의 이상감지는 [1]의 경우를 처리하는 것이 대부분인데 [2]에서 말한 미래에 발생한 문제가 있는지는 예측(forecasting) 분야와도 겹치는 것이 많으며 미래를 예측하는 것은 매우 어려운 일이기 때문이다.The above [1] and [2] seem to be almost the same, but the difficulty is very different and the approach is very different. Until now, most of the anomaly detection in reality has dealt with the case of [1], but there are many overlaps with the field of forecasting whether there is a problem in the future mentioned in [2], and it is very difficult to predict the future. am.

상기 [1]은 일종의 광범위한 모니터링이라고 할 수 있지만 일반적으로 말하는 임계치(Threshold) 기반을 말하는 것이 아닌 가변 임계치나 상황이 이전의 흔한 패턴과 다른 것을 빨리 찾는 것이다.The above [1] can be said to be a kind of wide-ranging monitoring, but it does not refer to a generally speaking based on a threshold, but to quickly find a variable threshold or situation different from the previous common pattern.

상기 [2]는 시계열 예측(time-series forecasting)의 일부라고 볼 수 있다. 시계열 예측(time-series forecasting)은 미래에 발생할 일을 정확히 예측하지만 이상감지는 미래에 이상해질 위험이 있는지 이상한 것이 발생할 확률이 높아질지를 예측하는 것으로 기술난이도가 훨씬 높다. 현실에서 이런 요구를 데이터 과학자에게 빈번하게 하는데 이런 모델을 만드는 것이 가능성이 없는 것은 아니지만 사실상 판타지에 가깝다.[2] above can be seen as part of time-series forecasting. Time-series forecasting accurately predicts what will happen in the future, but anomaly detection is much more technically challenging as it predicts whether there is a risk of anomaly in the future or an increased probability of anomaly occurring. In reality, data scientists are often asked for this, and creating such a model is not impossible, but it is actually close to fantasy.

이상한 행동을 만들어내는 대상체의 특징은 다음과 같다.The characteristics of objects that produce strange behavior are as follows.

- 이상한 패턴을 보이지만 뚜렷하지 않음- Weird pattern, but not clear

- 보편적인 것에 섞여 있으나 상대적으로 수가 매우 적음- Mixed in common, but relatively few in number

- 지금은 문제가 없지만 앞으로 문제가 발생할 확률이 있는 미묘한 차이가 있는 패턴- Patterns with subtle differences that are not a problem now, but are likely to cause problems in the future

이상감지에서 찾으려고 하는 패턴은 뚜렷하지 않은 경우가 많다. 패턴이 뚜렷하고 쉽게 인지할 수 있는 것이라면 규칙 기반의 방법을 조합해서도 감지를 해낼 수 있다. 하지만 애매하거나 잘 보이지 않는 것은 그것부터 찾아서 밝혀내야 하고 그 자체가 쉽지 않다.The pattern to be found in anomaly detection is often not clear. If the pattern is distinct and easily recognizable, detection can also be achieved using a combination of rule-based methods. However, the obscure or difficult to see must be found first and revealed, which itself is not easy.

○ [이상 패턴]○ [Abnormal Pattern]

이상징후에서 말하는 패턴은 매우 광의적인 것으로 정의하기가 모호하고 조금 더 구체적으로 보면 다음과 같다. 사실상 모두 아웃라이어를 뜻하는 것이다.The pattern mentioned in the anomaly is very broad, and it is ambiguous to define it. In more detail, it is as follows. Virtually all of them mean outliers.

- 과거에 확률적으로 매우 드물게 발생한 것들이 갑자기 빈발하게 발생- Things that happened very rarely in the past suddenly happen frequently

- 논리적으로 함께 발생할 수 없거나 논리적 정합성 조합에 의해 나타나지 않아야 하는 것- things that cannot logically occur together or must not be represented by a logically coherent combination

- 다른 군집이나 집단, 그룹 등에서는 나타나지 않는 것들이 보이는 것. - To see things that do not appear in other clusters, groups, groups, etc.

이것들은 사실 앞서 말한 것과 크게 다르지 않다.These are in fact not very different from those mentioned above.

이상감지는 아웃라이어를 찾는 것이라고 보면 되는데 아웃라이어를 찾을 때의 비교대상이 과거의 시간, 다른 비슷한 군집 등이 되고 이런 것들의 조합이 경우도 많다.Anomaly detection can be seen as finding outliers, but when looking for outliers, the comparison target is the past time or other similar clusters, and in many cases, a combination of these things.

○ [이상감지와 아웃라이어 감지의 차이]○ [Difference between anomaly detection and outlier detection]

이상감지와 함께 자주 볼 수 있는 용어로는 아웃라이어 감지(또는 이상치 감지)가 있다. 간단히 설명하면 아웃라이어는 시간과 관련이 없이 대상을 표현하는 숫자들의 위치를 보고 보편적인 대상과 벗어난 것을 찾아내는 것이고 이상감지는 시간 또는 순서가 있는 흐름에 따른 패턴이 보편적인 상황 또는 보편적인 패턴들과 다른 것들을 찾아내는 것이다.A term often seen alongside anomaly detection is outlier detection (or outlier detection). Simply put, outliers look at the positions of numbers representing objects regardless of time and find things that deviate from common objects. to find other things.

이상감지는 시계열과 관련이 깊고 아웃라이어는 시간과는 대부분 관련없다.Anomaly detection is related to time series, and outliers are mostly not related to time.

좁은 의미로는 다음과 같다.In a narrow sense, it is

- 이상감지는 시계열 데이터에서 아웃라이어를 찾는 것- Anomaly detection is to find outliers in time series data

- 아웃라이어 감지는 횡단면 데이터에서 아웃라이어를 찾는 것- Outlier detection is to find outliers in cross-sectional data

○ [접근 방법]○ [Approach]

이상감지의 목표는 감지이다. 이상한 것을 가능한 빨리 찾아야 하는 것이 주된 목표이다.The goal of anomaly detection is detection. The main goal is to find the odd one as quickly as possible.

다음과 같은 정의하는 단계를 명확히 하고 시작해야 한다.You need to clarify and start with the following defining steps:

[1]. 이상한 것을 알아차리려면 "이상하지 않은 것" 즉 평범한 것(normal) 부터 정의를 해야한다. 당연한 것이지만 이것부터 정의가 제대로 되지 않으면 하기 어렵다.[One]. If you want to notice the strange, you have to define "what isn't strange," i.e. what is normal. It's obvious, but it's hard to do without a proper definition of this.

[2]. "이상하지 않은 것"을 보편적(normal)한 것으로 규정하고 그 뒤에 보편적인것과 비교해서 "이상한 것"을 정의한 뒤 그것을 찾는 모형(model)을 만들거나 분석을 통해 이상한 것에 부합되는 것을 찾으면 된다.[2]. Define "unusual" as normal, then define "weird" by comparing it with the universal, and create a model to find it, or find something that matches the abnormal through analysis.

다음 단계로는 탐지 방법을 선택해야 하는데 이 부분이 가장 어려우며, 이는 정해진 방법이 없기 때문이다.The next step is to select a detection method, which is the most difficult part because there is no set method.

다음에 대한 체크리스트를 확인해하는 것부터 시작한다.Start by checking the checklist for:

[1]. 기계학습을 할 수 있는 정답데이터가 있는가? 없는가?[One]. Is there correct answer data for machine learning? isn't it?

[2]. 시계열 데이터인가? 아닌가?[2]. Is it time series data? is not it?

[3]. 단변량인가? 다변량인가?[3]. Is it univariate? Is it multivariate?

[4]. 스코어링 모형(scoring model)이어야 하는가? 판별 모형(prediction model)이어야 하는가?[4]. Should it be a scoring model? Should it be a prediction model?

상기 [1]의 경우에 정답데이터가 있다면 지도학습, 반지도학습을 통해서 문제를 해결하는 것을 시도해볼 수 있다. 다음과 같은 알고리즘을 후보에 두고 진행하는 것이 일반적이다.In the case of [1] above, if there is correct answer data, you can try to solve the problem through supervised learning or semi-supervised learning. It is common to proceed with the following algorithm as a candidate.

- Regression 계열- Regression series

- Time-series 계열- Time-series series

- Decision Tree 계열(주로 Random Forest나 몬테카를로가 적용된 계열)- Decision tree series (mainly Random Forest or Monte Carlo applied series)

- Bayesian Network 계열- Bayesian Network Series

정답데이터가 없거나 매우 적다면 분류기반의 기계학습 알고리즘으로 이상감지를 찾아내는 것은 매우 어렵다.If there is no or very little correct answer data, it is very difficult to find anomalies with classification-based machine learning algorithms.

상기 [2]의 문제는 outlier detection과 anomaly detection을 구분하는 것이며 anomaly detection이 연산량이 많이 들고 더 어렵다. 이상감지는 일반적으로 시계열 데이터인 경우가 많다. 만약 시계열 데이터가 아니라면 outlier를 찾는 각종 알고리즘이나 잘 알려진 모형들을 찾아서 사용하면 된다.The problem in [2] above is to distinguish between outlier detection and anomaly detection, and anomaly detection requires a lot of computation and is more difficult. Anomaly detection is generally time-series data. If it is not time series data, you can find and use various algorithms or well-known models to find outliers.

상기 [3]의 문제 단변량과 다변량의 문제는 보통 시계열에서 문제가 되는데 다변량은 여러 변수를 모두 보고 이상한 상태를 종합적으로 판단하는 것으로 매우 어렵다. 현재 잘 알려진 유력한 알고리즘은 없다.The problem of [3] above is that univariate and multivariate problems are usually problems in time series, but multivariate is very difficult because it comprehensively judges abnormal conditions by looking at all variables. Currently, there is no well-known dominant algorithm.

상기 [4]의 문제는 "이상하다"라고 표기만 해주면 되는지 "이상한 정도"가 얼마나 되는 점수화해서 후에 임계값으로 감지의 정확도와 민감도를 조절할 것인지이다. 역시 후자가 더 어렵다.The problem in [4] above is whether it is enough to mark “odd” or whether to set the score for “strangeness” and adjust the accuracy and sensitivity of detection with a threshold value later. The latter is also more difficult.

○ [이상한 것에 대한 정의]○ [Definition of weirdness]

결국 대부분의 경우 학습데이터를 사용할 수 없으므로 이상한 것(anomalous object)을 찾기전에 이상하지 않은것(normal)이 무엇인지 개념 정리를 해야하고 이상하지 않은 것과 이상한 것을 구별하는 것으로 접근해야 하며, 보편적인 것에서 벗어나는 것을 찾는다. 수치상으로는 보통 평균에 가깝거나 다수에 가까운 것을 이상하지 않은 것으로 본다.After all, in most cases, training data cannot be used, so before finding an anomalous object, it is necessary to organize the concept of what is normal and to approach it by distinguishing the normal from the normal. looking for something to get out of Numerically, anything close to the average or close to the majority is usually considered not unusual.

○ [이상감지와 데이터 프로세싱]○ [Anomaly detection and data processing]

이상징후의 문제는 알고리즘도 중요하지만 연산량이 매우 많이 소모되는 경향이 있다.Algorithms are also important for the problem of anomalies, but they tend to consume a lot of calculations.

기계학습으로 이상감지를 접근하기 어려운 이유가 현실에서는 이상한 패턴이라고 발견하고 규정할 수 있는 학습데이터(training set)가 없거나 매우 부족해서 분류 모델을 만들 수 없는 경우가 대부분이므로 비지도학습(unsupervised learning)이나 통계 및 수리 모형을 만들게 되는데 이때 이상한 것을 찾기 위해 대량의 데이터를 여러 방법으로 결합하고 검색해 봐야 하는 경우가 많으며 특히 시계열 데이터는 이상감지와 같은 것을 하려면 처리 연산량이 매우 많다.The reason why it is difficult to approach anomaly detection with machine learning is that in most cases it is not possible to create a classification model because there is no training set that can detect and define a strange pattern in reality, or it is very insufficient, so unsupervised learning However, statistical and mathematical models are created. At this time, in order to find anomalies, it is often necessary to combine and search large amounts of data in various ways.

○ [오탐지(False Alarm)에 대한 문제]○ [Problems with False Alarms]

이상을 감지했는데 오감지로 인해 발생하는 것 손실이 크다면 이상감지는 더욱 어려운 문제가 된다. 모든 분류 및 예측에 관련된 기계학습 기술이 동일한 문제와 부딪히지만 오탐지(false alarm)으로 인한 손해비용이 크다면 매우 높은 정확도를 탐지모델에 요구하게 되고 문제를 또다시 더 어렵게 만든다.If an anomaly is detected and the loss caused by the false detection is large, anomaly detection becomes a more difficult problem. All classification and prediction-related machine learning techniques face the same problem, but if the cost of false alarms is high, they require very high accuracy from the detection model, which again makes the problem more difficult.

어느 정도의 정확도를 원하는지 얼마만큼의 오탐지(false alarm)를 수용할 수 있는지 요구사항을 주는 사람이 정확히 정의해 주어야하며 그렇지 않은 경우에는 업무를 담당하게 된 데이터사이언티스트가 제안을 해 주어야 한다.The person giving the requirements must precisely define how much accuracy is desired and how many false alarms can be accommodated, and if not, the data scientist in charge of the task must make suggestions.

○ [이상감지와 사기감지 및 어뷰즈감지]○ [Anomaly detection, fraud detection, and abuse detection]

이상감지(Anomaly Detection)와 사기감지(Fraud Detection)는 관련이 깊다.Anomaly Detection and Fraud Detection are closely related.

하지만 사기감지가 이상감지 보다는 범위가 넓고 까다롭다. 사기꾼은 언제나 들키지 않기 위해서 매우 노력하는데 이를 찾아내기 위해서는 아직 나타나지 않은 이상한 것과 매우 간헐적인 이상한 패턴, 또는 매우 드물지만 이상한 패턴을 찾아내야 하기 때문이다.However, fraud detection is broader in scope and more demanding than anomaly detection. Scammers always try very hard to stay undetected, because to find them, they have to look for oddities that haven't surfaced yet, very intermittent odd patterns, or very rare but odd patterns.

○ [활용분야]○ [Use field]

이상감지는 시스템 운영, 보안 관련 시스템, 제조업과 같은 공정 데이터 관리 등에 많이 활용되고 있으며, 사용자 행동(behavior)에 대해서도 활용이 가능하다. 그 외에 대부분의 비즈니스에 모두 활용이 가능하다. 매우 광범위하다고 할 수 있다. 이상징후와 아웃라이어는 데이터마이닝에서 찾고자 하는 가치와 부합되는 것이 많기 때문이다.Anomaly detection is widely used in system operation, security-related systems, and process data management such as manufacturing, and can also be used for user behavior. Other than that, it can be used for most businesses. It can be said to be very broad. This is because there are many anomalies and outliers that match the values that are sought in data mining.

○ [비즈니스 분석]○ [Business Analysis]

비즈니스 분석에 있어서 이상 감지는 대부분 데이터 마이닝의 문제와 비슷하다. 관련된 현실에서의 이상감지와 관련된 문제를 찾으려고 하면 무궁무진하게 많다.Anomaly detection in business analytics is mostly similar to data mining problems. If you try to find problems related to anomaly detection in related realities, there are infinitely many.

○ [매출이 이전에 비해 떨어진 판매 채널]○ [Sales channels with lower sales than before]

어떤 리테일(retail) 제품을 판매하는 회사의 특정 판매채널이 전에 비해서 또는 다른 판매채널에 비해서 매출이 증가했거나 감소했는지를 찾는다. 찾고난 후에는 문제가 무엇인지 확인하고 조치하는데 사용할 수 있다. 하지만 소비자에게 판매되는 것은 계절요인(seasonal components), 외생요인(external components)의 문제가 있기 때문에 쉬운 것은 아니다.Find out whether a particular sales channel of a company that sells a certain retail product has increased or decreased in sales compared to the past or other sales channels. Once found, it can be used to determine what the problem is and take action. However, selling to consumers is not easy because there are problems with seasonal components and external components.

○ [주문량이 이전에 비해서 증가한 거래처]○ [Customers whose order volume has increased compared to before]

이것은 이상감지가 아니고 단지 BI(Business Intelligence)를 이용한 경영 분석이 아닌가라고 물을 수 있다. 하지만 기준치를 넘지 않았지만 예전에 비해서 주문량이 증가하는 거래처를 찾는 것은 쉽지 않다. 주문량이 매우 크게 늘어난 것은 아니지만 거래처의 비즈니스가 실제 호황인지 이유가 무엇인지를 알아내야 할 것이다. 그리고 더 늘어날 조짐이 있는 거래처가 다수 늘어났다면 판매를 위해서 미리 제품의 생산을 늘려야 할 것이다. It can be asked if this is not an anomaly detection, but a management analysis using BI (Business Intelligence). However, it is not easy to find a customer who has not exceeded the standard but whose order volume is increasing compared to the past. Although the order volume has not increased very significantly, you will have to find out why the business of the customer is really booming. And if the number of customers with signs of further growth has increased, you will have to increase product production in advance for sales.

○ [구매량이 이전에 비해서 증가 또는 감소한 품목]○ [Items whose purchase volume has increased or decreased compared to the previous time]

위와 유사한 사례로 구매량이 이전에 비해 소폭 감소했지만 크게 떨어진 것은 아니며 잠깐 동안의 스파이크성으로 구매량이 감소한 것이 아닌 중, 장기로 볼 때 구매량이 떨어질 것 같은 것을 감지하는 것이다. In a case similar to the above, although the purchase volume decreased slightly compared to the previous one, it did not fall significantly.

이외에도 적용분야로서, [다른 경쟁사로 이탈할 징후가 보이는 쇼핑몰 또는 서비스의 고객], [자체로는 문제가 없지만 다른 상품의 판매에 의해 영향을 받는 제품], [평소와 다른 공간 이동 패턴을 보이는 차량 또는 모바일 디바이스 사용자] 등이 있을 수 있는 것이다.In addition, as application areas, [customers of shopping malls or services that show signs of leaving to other competitors], [products that are not problematic by themselves but are affected by the sale of other products], [vehicles with unusual spatial movement patterns or a mobile device user] and the like.

○ [컴퓨터 시스템 관리] ○ [Computer System Management]

컴퓨터 시스템 관리는 이상감지가 가장 잘 적용되어 왔고 이상감지를 많이 발전시킨 분야 중의 하나이다. 특히 서버, 스토리지, 네트워크 장비의 이상 발생은 장애와 직결되고 장애는 매출 및 운영비와 직결되는 경우가 많기 때문이다. Computer system management is one of the fields in which anomaly detection has been best applied and has developed a lot. In particular, failures of servers, storage, and network equipment are directly related to failures, and failures are often directly related to sales and operating expenses.

○ [자원 사용량(메모리/디스크IO/네트워크IO)이 이전에 비해 증가한 시스템]○ [System with increased resource usage (memory/disk IO/network IO) compared to before]

접속이 없었던 IP주소들로부터의 시스템 접근량의 증가 (DDOS의 징후) Increase in system access from IP addresses that have never been accessed (symptom of DDOS)

지금은 문제가 없지만 이대로 간다면 틀림없이 다운될 것 같은 시스템 또는 시스템 클러스터Systems or clusters of systems that are fine now, but will undoubtedly go down at this rate.

○ [온라인 서비스 관리]○ [Online Service Management]

이전에 비해서 증가한 로그인 실패 기록Sign-in failure record increased compared to before

이전에 발생하지 않은 에러코드의 기록 또는 더 빈발해진 기록Records of previously non-occurring error codes or records that have become more frequent

다른 사용자와 다른 이동패턴이나 접근 패턴을 보이는 사용자Users who show movement or access patterns different from other users

○ [공정 관리]○ [Process Management]

불량품이 늘어날 것 같은 조짐이 보이는 공정Processes that show signs of increasing defective products

현재 불량률은 차이가 없지만 후에 불량품이 대량 발생되어 리콜될 것 같은 제품 라인There is no difference in the current defect rate, but a product line that is likely to be recalled due to the large number of defective products

큰 고장이 발생할 것 같은 설비equipment likely to fail

○ [보안]○ [Security]

기밀문서 불출 횟수가 상대적으로 증가한 직원Employees who relatively increased the number of handouts of confidential documents

임계치를 넘지는 않는 범위내에서 이전보다 증가한 보안 접근 실패Increased security access failures within a range that does not exceed the threshold

사람의 접근이 거의 없는 지역에 이전보다 다소 증가한 통행량Slightly higher traffic than before in areas with little human access

○ [관련 알고리즘 및 방법]○ [Related Algorithms and Methods]

이상감지 알고리즘을 찾는 사람들이 많을텐데 생각보다 이상감지라고 정의되어 있는 알고리즘 수는 적다. 아래에 소개하는 것들은 비교적 잘 알려진 알고리즘들이며 이 것외에도 활용에 쓰이는 것은 매우 많다는 것을 알려둔다. 아웃라이어에 해당하는 알고리즘이나 방법은 제외하였다.Many people are looking for an anomaly detection algorithm, but the number of algorithms defined as anomaly detection is smaller than expected. The ones introduced below are relatively well-known algorithms, and there are many others that are used for utilization. Algorithms or methods corresponding to outliers were excluded.

○ [트위터 이상감지 알고리즘 Twitter Anomaly Detection]○ [Twitter Anomaly Detection]

Twitter Anomaly Detection 이라고 부르는데 Twitter에서 발표한 이상감지 알고리즘이 있다. 알고리즘의 정식 명칭은 S-H-ESD이라는 매우 복잡해 보이는 이름이다. 하지만 정식 명칭 보다는 "트위터 이상감지 알고리즘"이라고 더 많이 부른다.It is called Twitter Anomaly Detection, and there is an anomaly detection algorithm announced by Twitter. The official name of the algorithm is S-H-ESD, a very complicated-looking name. However, it is more commonly referred to as "Twitter Anomaly Detection Algorithm" than its official name.

○ [통계적 이상 감지]○ [Statistical anomaly detection]

이것은 알고리즘 이름이라고는 할 수 없는데 이베이에서 사용하는 통계적인 방법을 사용한 이상감지에 대한 내용이다.This cannot be called an algorithm name, but it is about anomaly detection using statistical methods used by eBay.

트위터 알고리즘의 원형으로 알려져 있다. 트위터 이상감지 알고리즘이 이 알고리즘을 개량한 것이다.It is known as the prototype of the Twitter algorithm. The Twitter Anomaly Detection Algorithm is an improvement on this algorithm.

○ [홀트윈터스 필터]○ [Holly Twins Filter]

이상감지에도 많이 사용되는 홀트윈터스 필터이다. Elastic에서 X-pack의 이상감지 알고리즘을 홍보하면서 X-pack의 이상감지가 이 알고리즘과 비교(벤치마크)했을때 더 성능이 좋다고 주장하고 있다.It is a Hol Twin Winters filter that is widely used for anomaly detection. Elastic promotes X-pack's anomaly detection algorithm, claiming that X-pack's anomaly detection performs better when compared to this algorithm (benchmark).

○ [엘라스틱 X팩 이상감지]○ [Elastic X pack abnormality detection]

알고리즘이라기 보다는 엔진이라고 불러야 하는 것이 더 맞을 것이다. 여러가지 방법을 섞은 것으로 알려져 있고 소스코드는 오픈되어 있다고 하지만 실제로 찾을 수는 없다.It would be more appropriate to call it an engine rather than an algorithm. It is known that various methods are mixed, and the source code is said to be open, but I can't actually find it.

○ [로버스트 랜덤컷포레스트]○ [Robust Random Cut Forest]

비지도학습으로 가장 성능이 좋은 것으로 알려진 것은 Robust Random Cut Forest(로버스트 랜덤 컷 포레스트)인데 이 알고리즘은 아마존(Amazon)에서 만들었다. 유명한 앙상블 결정트리(Ensemble Decision Tree) 알고리즘인 랜덤포레스트의 컨셉을 사용하고 있다.The one known to perform best in unsupervised learning is the Robust Random Cut Forest, an algorithm created by Amazon. It uses the concept of the famous Ensemble Decision Tree algorithm, Random Forest.

여러가지 좋은 기능을 가지고 있으며 성능도 좋지만 모델을 생성하는 속도가 느린 단점이 있다. 즉, 학습이 매우 느리고 컴퓨팅 자원을 매우 많이 사용한다.It has many good features and has good performance, but it has the disadvantage of slow model generation. That is, learning is very slow and uses a lot of computing resources.

다시말해, 상기와 같은 AI 기반의 이상 감지 알고리즘들은 공장 및 시설의 이상을 감지하기 위해 여러가지 AI알고리즘을 적용하고 활용하고 있지만, 아래와 같이 설비 데이터의 특성상 AI를 적용하기 어려운 문제점이 있다. In other words, although the above AI-based anomaly detection algorithms apply and utilize various AI algorithms to detect anomalies in factories and facilities, there are problems in applying AI due to the characteristics of facility data as follows.

첫째, 라벨링 되지 않는 데이터로서, 설비 및 시설에 전류, 진동, 온도 등의 센서를 설치하면 많은 데이터를 얻을 수 있지만, 데이터들이 라벨링 되어 있지 않아 AI를 적용하기 매우 어려웠다.First, as data that is not labeled, a lot of data can be obtained by installing sensors such as current, vibration, and temperature in facilities and facilities, but it is very difficult to apply AI because the data is not labeled.

둘째, 데이터 불균형 현상으로서, 설비 및 시설은 대부분 정상 상태이기 때문에 비정상의 데이터를 얻기가 어려워 이상 감지 학습모델을 생성하는데 어렵고 생성하더라도 검출 성능이 좋지 않으면서 데이터 불균형 현상을 초래하였다.Second, as a data imbalance phenomenon, since most facilities and facilities are in a normal state, it is difficult to obtain abnormal data and it is difficult to create an anomaly detection learning model, resulting in data imbalance with poor detection performance.

셋째, 설비 데이터의 문제로서, 설비 및 시설에는 전류, 진동, 온도 등의 센서를 설치하여 데이터를 수집하면 많은 데이터를 확보할 수 있지만 이 데이터는 센서에서 자동으로 수집되는 데이터이기 때문에 정상, 비정상을 라벨링하여 수집하기가 어렵고 설비 및 시설은 대부분 정상인 상태이기 때문에 데이터의 불균형 현상(정상만 많은 상태)이 발생된다. 데이터 불균형인 상태로 학습하여 모델을 생성하면 비정상을 검출하기 어렵고 검출 성능이 좋지 못하였던 것이다.Third, as a problem of facility data, a lot of data can be obtained by collecting data by installing sensors such as current, vibration, and temperature in facilities and facilities. However, since this data is automatically collected from sensors, normal and abnormal It is difficult to collect by labeling, and since most of the equipment and facilities are in a normal state, an imbalance of data (many normal states) occurs. When a model was created by learning with imbalanced data, it was difficult to detect abnormalities and the detection performance was poor.

넷째, 검출 성능의 문제로서, 대부분의 회사 및 시설운영업체는 AI 이상감지를 통하여 자동으로 설비 및 시설을 제어하는 것을 목표로하고 있지만, 오판으로 설비 및 시설을 정지시키면 생산성 저하가 발생되고 실제 활용되기 어렵게 된다. 때문에 오판이 발생하지 않아야 한다.Fourth, as a problem of detection performance, most companies and facility operators aim to automatically control facilities and facilities through AI abnormality detection, but when facilities and facilities are stopped due to misjudgment, productivity decreases and actual utilization occurs. it becomes difficult Therefore, errors should not occur.

다섯째, 컴퓨팅 성능의 문제로서, 공장 및 시설운영기관에서는 수많은 설비 및 시설을 운영 중에 있다. 현재는 1가지 설비의 이상을 감지하기 위해서 모델을 생성하고 모델을 기반으로 이상을 감지하는 실정이다.Fifth, as a problem of computing performance, factories and facilities operating organizations are operating numerous facilities and facilities. Currently, a model is created to detect an anomaly of one type of equipment, and an anomaly is detected based on the model.

등록특허공보 제10-0579083호(공고일 2006.05.12.)Registered Patent Publication No. 10-0579083 (Announcement Date 2006.05.12.) 공개특허공보 제10-2008-0070543호(공개일 2008.07.30.)Publication No. 10-2008-0070543 (published on July 30, 2008) 등록특허공보 제10-1611299호(공고일 2016.04.11.)Registered Patent Publication No. 10-1611299 (Announcement Date 2016.04.11.) 등록특허공보 제10-1776956호(공고일 2017.09.19.)Registered Patent Publication No. 10-1776956 (Public date 2017.09.19.)

본 발명은 상기와 같은 문제점들을 해결하고자 제안된 것으로, 설비 데이터의 특성인 라벨링되지 않는 데이터 문제, 데이터 불균형 문제, 검출 성능의 문제, 컴퓨팅 성능 문제를 해결하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템과 그 방법을 제공하려는 것이다.The present invention is proposed to solve the above problems, AI-based equipment using a random cut forest algorithm to solve the problem of unlabeled data, data imbalance problem, detection performance problem, and computing performance problem, which are characteristics of facility data. It is intended to provide a data anomaly detection system and its method.

본 발명의 실시예에서 적용되는 랜덤 컷 포레스트 알고리즘(IRCF)은 학습모델에 신규데이터를 삽입하고 삭제하는 방법 대신 삽입되었을 때 이상점수가 몇 점이 나올지를 예상하는 확률기반의 계산방식(Optimize calculation of CoDISP)을 적용함으로써 동적 모델을 활용하여 이상감지하는 장점을 그대로 계승할 수 있으며, 연상량이 많이 소모되는 노드추가, 노드 삭제 작업 대신 확률기반으로 이상점수만 계산하는 방식을 사용하여 계산량을 대폭 감소시키는 이점이 있는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템과 그 방법을 제공하려는 것이다.The random cut forest algorithm (IRCF) applied in the embodiment of the present invention is a probability-based calculation method (optimization calculation of CoDISP) that predicts how many abnormal scores will come out when new data is inserted into the learning model instead of a method of inserting and deleting new data. ), it is possible to inherit the advantage of anomaly detection by using a dynamic model, and the advantage of significantly reducing the amount of computation by using a method of calculating only anomaly scores based on probability instead of adding and deleting nodes that consume a lot of association. It is intended to provide an AI-based equipment data anomaly detection system and method using a random cut forest algorithm with

본 발명의 실시예에 따른 램던 컷 포레스트 알고리즘(IRCF)은 동적 트리를 가지고 있지 않기 때문에 학습된 모델이 상대적으로 가벼운 장점을 가지면서, 퓨처 샘플링 방법을 통한 검출 정확도 향상(Feature sampling method), 그리고 같은 데이터 가지고 이상점수를 측정하였을 때 점수가 다른 문제를 개선(Deterministic anomaly score)하는 효과를 기대할 수 있는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템과 그 방법을 제공하려는 것이다.The Ramdon Cut Forest Algorithm (IRCF) according to an embodiment of the present invention has the advantage that the learned model is relatively light because it does not have a dynamic tree, while improving detection accuracy through the future sampling method (Feature sampling method), and the same It is intended to provide an AI-based equipment data anomaly detection system and method using a random cut forest algorithm that can expect the effect of improving other problems (Deterministic anomaly score) when anomaly scores are measured with data.

본 발명의 과제 해결 수단인 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템은, 설비에 대한 고장을 진단하는 것으로 AI 기반의 고장진단 스마트 센서; 상기 AI 기반의 고장진단 스마트 센서에 의해 진단된 결과를 모니터링하는 설비 고장진단 모니터링부; 및, 상기 설비 고장진단 모니터링부에 의해 모니터링된 결과를 분석하도록 확률기반의 계산 방식을 적용한 랜덤 컷 포레스트 알고리즘(IRCF; Improve Random Cut Forest)을 가지는 관리자 분석 처리부; 를 포함하는 것이다.An AI-based equipment data abnormality detection system using a random cut forest algorithm, which is a means for solving the problems of the present invention, diagnoses equipment failure, and includes an AI-based failure diagnosis smart sensor; a facility fault diagnosis monitoring unit that monitors a result diagnosed by the AI-based fault diagnosis smart sensor; And, a manager analysis processing unit having an improved random cut forest (IRCF) algorithm to which a probability-based calculation method is applied to analyze the result monitored by the equipment failure diagnosis monitoring unit; is to include

또한, 상기 AI 기반의 고장진단 스마트 센서와 상기 설비 고장진단 모니터링부는 클라우드 서버를 통해 통신 연결되는 것이다.In addition, the AI-based fault diagnosis smart sensor and the facility fault diagnosis monitoring unit are communicatively connected through a cloud server.

또한, 상기 클라우드 서버에는 분할된 데이터 베이스와 빅데이터 베이스가 연결되는 것이다.In addition, a divided database and a big database are connected to the cloud server.

다른 일면에 따라, 본 발명의 과제 해결 수단인 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법은, 이상감지를 위한 학습 모델을 생성하는 단계; 및, 상기 생성하는 단계로부터 생성되는 학습모델로부터 이상점수를 예측하는 이상점수 예측 및 운영단계; 를 포함하는 것이다.According to another aspect, an AI-based facility data anomaly detection method using a random cut forest algorithm, which is a problem solving means of the present invention, includes generating a learning model for anomaly detection; and an ideal score prediction and operation step of predicting an ideal score from the learning model generated in the generating step. is to include

또한, 상기 학습 모델을 생성하는 단계는, 설비에 설치되는 AI 기반의 고장진단 스마트 센서로부터 수집된 데이터를 전처리하는 단계; 상기 전처리하는 단계로부터 전처리된 데이터를 저장하는 단계; 상기 저장하는 단계로부터 저장된 전처리 데이터에서 랜덤 트리를 구성하여 정상 데이터 기반의 학습 모델을 생성하는 단계; 및, 상기 생성하는 단계로부터 생성된 학습 모델을 저장하는 단계; 를 포함하는 것이다.In addition, the generating of the learning model may include pre-processing data collected from an AI-based fault diagnosis smart sensor installed in a facility; Storing preprocessed data from the preprocessing step; generating a learning model based on normal data by constructing a random tree from the preprocessed data stored from the storing step; and storing the learning model generated from the generating step. is to include

또한, 상기 이상점수 예측 및 운영단계는, 설비에 설치되는 AI 기반의 고장진단 스마트 센서로부터 데이터를 수집하여 전처리하는 단계; 상기 저장하는 단계로부터 저장된 학습모델을 기반으로 랜덤 컷 포레스트 알고리즘(IRCF)을 이용하여 측정하고자 하는 데이터로서 이상점수(Optimize calculation of CoDISP)를 계산하는 계산하는 단계; 및, 상기 계산하는 단계로부터 계산된 이상점수가 높으면 설비 알람을 발생시키는 단계; 를 포함하는 것이다.In addition, the abnormal score prediction and operation step may include pre-processing by collecting data from an AI-based fault diagnosis smart sensor installed in the facility; Calculating an ideal score (Optimize calculation of CoDISP) as data to be measured using a random cut forest algorithm (IRCF) based on the learning model stored from the storing step; and generating a facility alarm when the ideal score calculated from the calculating step is high. is to include

또한, 상기 랜덤 컷 포레스트 알고리즘(IRCF)는 동적 트리를 가지고 있지 않으면서 동적인 학습모델을 이용하여 이상점수를 예측하는 확률기반의 계산 방식이 적용되는 것이다.In addition, the random cut forest algorithm (IRCF) applies a probability-based calculation method that predicts an abnormal score using a dynamic learning model without having a dynamic tree.

또 다른 일면에 따라, 본 발명의 과제 해결 수단인 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법은, 정상적인 학습 데이터(X)

Figure pat00001
- (1) 이고, 상기 학습 데이터(X) 집합에서 n(≤N)을 무작위 선택하면,
Figure pat00002
- (2) 이며, 상기 X1을 기반으로 RRC Tree를 생성하는 트리 생성 단계; According to another aspect, an AI-based facility data abnormality detection method using a random cut forest algorithm, which is a problem solving means of the present invention, normal learning data (X)
Figure pat00001
- (1), if n (≤ N) is randomly selected from the set of learning data (X),
Figure pat00002
- (2), a tree creation step of generating an RRC Tree based on the X1;

트리 생성 단계; 데이터 추가 및 변형 트리 생성 단계; 이상점수(CoDISP)를 계산한 후, 데이터를 제거하는 단계; 및 상기 과정을 반복 수행하여, 상기 이상점수(CoDISP)의 평균으로 이상 점수를 새롭게 얻게 되는 이상점수 수득 단계; 를 포함하는 것이다.tree creation step; adding data and creating a transformation tree; removing data after calculating an outlier score (CoDISP); and obtaining an ideal score by repeating the above process to obtain a new ideal score based on the average of the ideal scores (CoDISP). is to include

상기 트리 생성 단계는, 트리 생성시 데이터의 샘플링과 함께 특징 샘플링(feature sampling)을 도입하면서, 트리의 사이즈 감소 및 속도를 개선하고, 스케일이 작은 데이터의 이상 감지 효과를 증가시킬 수 있도록 하는 것이다.The step of creating the tree is to reduce the size and speed of the tree and increase the anomaly detection effect of small-scale data, while introducing feature sampling along with data sampling when the tree is created.

또한, 상기 변형 트리 생성 단계는, 변형된 트리를 생성하지 않고 추가함으로써, 데이터의 이상점수(CoDISP) 만을 연산하여 빠른 속도를 기대할 수 있도록 하는 것이다. Also, in the transformation tree generation step, by adding the transformed tree without generating it, only the abnormal score (CoDISP) of the data is calculated so that a high speed can be expected.

또한, 상기 이상점수 수득 단계는, 상기 이상점수(CoDISP)는 확률적으로 얻는 값이기 때문에 매번 달라지는 상기 이상점수(CoDISP) 값을 고정시키기 위해 상기 이상점수(CoDISP)의 확률적 기대값을 결과값으로 사용하는 것이다.In addition, in the step of obtaining the ideal score, since the ideal score CoDISP is a value obtained probabilistically, in order to fix the value of the ideal score CoDISP, which changes each time, a probabilistic expected value of the ideal score CoDISP is used as a result value. will be used as

이와 같이, 본 발명은 설비 데이터의 특성인 라벨링되지 않는 데이터 문제, 데이터 불균형 문제, 검출 성능의 문제, 컴퓨팅 성능 문제를 해결하는 AI 기반의 설비 데이터 이상 감지를 위한 랜덤 컷 포레스트 알고리즘 방법 및 시스템을 제공하면서, 설비를 운영하는 공장에서 설비가 고장나면 설비 운영이 불가하고 고장 부품을 수급하는데 있어 시간이 걸림으로 생산이 지연되는 문제를 개선하고, 설비 데이터를 수집하여 설비 이상을 감지하면 설비 고장을 미리 감지할 수 있고 이상을 사전에 점검하여 고장 부품을 미리 주문하여 설비 정지 시간을 최소화하여 설비를 수리할 수 있어 생산성을 향상시키며, 고장으로 인한 품질 저하를 막고, 설비 고장을 사전에 감지하여 못하여 큰고장이 발생되면 작업자 안정 문제도 발생하고 설비가 크게 고장남으로 수리 비용이 매우 높게 발생하는 문제를 개선하는 효과를 기대할 수 있는 것이다.As such, the present invention provides a random cut forest algorithm method and system for detecting anomalies in AI-based facility data that solves the problem of unlabeled data, data imbalance, detection performance, and computing performance, which are characteristics of facility data. while improving the problem of production delays due to the time-consuming sourcing of faulty parts and failing to operate the facility if the facility breaks down in the factory that operates the facility, and collects facility data to detect facility failure in advance. It can detect abnormalities in advance, order faulty parts in advance, minimize equipment downtime, improve productivity by repairing equipment, prevent quality deterioration due to failures, and prevent equipment failures from being detected in advance. When a breakdown occurs, worker stability problems also occur, and the effect of improving the problem that the repair cost is very high due to a large failure of the facility can be expected.

본 발명은 학습모델에 신규데이터를 삽입하고 삭제하는 방법 대신 삽입되었을 때 이상점수가 몇 점이 나올지를 예상하는 확률기반의 계산방식(Optimize calculation of CoDISP)을 적용함으로써 동적 모델을 활용하여 이상감지하는 장점을 그대로 계승할 수 있으며, 연상량이 많이 소모되는 노드추가, 노드 삭제 작업 대신 확률기반으로 이상점수만 계산하는 방식을 사용하여 계산량을 대폭 감소시키는 효과를 제공하게 된다.The present invention has the advantage of detecting anomalies using a dynamic model by applying a probability-based calculation method (Optimize calculation of CoDISP) that predicts how many anomalies will be obtained when new data is inserted and deleted instead of inserting and deleting new data in the learning model. can be inherited as it is, and instead of adding nodes and deleting nodes that consume a lot of association, it provides an effect of significantly reducing the amount of calculation by using a method of calculating only anomaly scores based on probability.

본 발명은 또한, 동적 트리를 가지고 있지 않기 때문에 학습된 모델이 상대적으로 가벼운 장점을 가지면서, 퓨처 샘플링 방법을 통한 검출 정확도 향상(Feature sampling method), 그리고 같은 데이터 가지고 이상점수를 측정하였을 때 점수가 다른 문제를 개선(Deterministic anomaly score)하는 효과를 제공하는 것이다.The present invention also has the advantage that the learned model is relatively light because it does not have a dynamic tree, the detection accuracy is improved through the future sampling method (Feature sampling method), and when the abnormal score is measured with the same data, the score is It is to provide the effect of improving other problems (Deterministic anomaly score).

본 발명의 효과들은 이상에서 언급한 효과들로 제한되지 않으며, 언급되지 않은 또 다른 효과들은 청구범위의 기재로부터 당업자에게 명확하게 이해될 수 있을 것이다.The effects of the present invention are not limited to the effects mentioned above, and other effects not mentioned will be clearly understood by those skilled in the art from the description of the claims.

도 1은 본 발명의 실시예로 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템을 보인 개략적인 구성도.
도 2는 본 발명의 실시예로 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템에 클라우드 서버가 연결된 상태를 보인 개략적인 구성도.
도 3은 본 발명의 실시예로 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법에서 학습모델의 생성 흐름도.
도 4는 본 발명의 실시예로 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법에서 이상점수의 예측 및 운영 흐름도.
1 is a schematic configuration diagram showing an AI-based equipment data anomaly detection system using a random cut forest algorithm as an embodiment of the present invention.
2 is a schematic configuration diagram showing a state in which a cloud server is connected to an AI-based equipment data anomaly detection system using a random cut forest algorithm according to an embodiment of the present invention.
3 is a flow chart of generating a learning model in an AI-based facility data anomaly detection method using a random cut forest algorithm according to an embodiment of the present invention.
4 is a flow chart of prediction and operation of anomaly scores in an AI-based facility data anomaly detection method using a random cut forest algorithm according to an embodiment of the present invention.

이하, 첨부된 도면을 참조하여 본 발명의 실시예를 설명하기로 한다.Hereinafter, embodiments of the present invention will be described with reference to the accompanying drawings.

도 1은 본 발명의 실시예로 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템을 보인 개략적인 구성도이고, 도 2는 본 발명의 실시예로 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템에 클라우드 서버가 연결된 상태를 보인 개략적인 구성도를 도시한 것이다.1 is a schematic configuration diagram showing an AI-based facility data anomaly detection system using a random cut forest algorithm as an embodiment of the present invention, and FIG. 2 is an AI-based facility using a random cut forest algorithm as an embodiment of the present invention. It shows a schematic configuration diagram showing a state in which the cloud server is connected to the data anomaly detection system.

첨부된 도 1 및 도 2를 참조하면, 본 발명의 실시예에 따른 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템은, AI기반의 고장진단 스마트 센서(10), 설비 고장진단 모니터링부(20), 관리자 분석 처리부(30)를 포함하는 것이다.Referring to FIGS. 1 and 2, the AI-based facility data anomaly detection system using the random cut forest algorithm according to an embodiment of the present invention includes an AI-based fault diagnosis smart sensor 10, a facility fault diagnosis monitoring unit (20), the manager analysis processing unit 30 is included.

상기 AI 기반의 고장진단 스마트 센서(10)는 설비에 대한 고장을 진단하는 것이다. The AI-based fault diagnosis smart sensor 10 diagnoses faults in facilities.

상기 설비 고장진단 모니터링부(20)는 상기 AI 기반의 고장진단 스마트 센서(10)에 의해 진단된 결과를 모니터링하는 것이다.The facility fault diagnosis monitoring unit 20 monitors a result diagnosed by the AI-based fault diagnosis smart sensor 10 .

상기 관리자 분석 처리부(30)는 상기 설비 고장진단 모니터링부(20)에 의해 모니터링된 결과를 분석하는 것이다. The manager analysis processing unit 30 analyzes the result monitored by the equipment failure diagnosis monitoring unit 20 .

여기서, 상기 AI 기반의 고장진단 스마트 센서(10)와 상기 설비 고장진단 모니터링부(20)는 클라우드 서버(40)를 통해 통신 연결될 수 있으며, 상기 클라우드 서버(40)에는 분할된 데이터 베이스(41)와 빅데이터 베이스(42)가 연결될 수 있는 것이다. Here, the AI-based fault diagnosis smart sensor 10 and the facility fault diagnosis monitoring unit 20 may be connected through communication through a cloud server 40, and the cloud server 40 includes a divided database 41 And the big data base 42 can be connected.

한편, 상기와 같은 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템에 의해 구현되는 이상 감지 방법은 첨부된 도 3 및 도 4에서와 같이, 학습 모델 생성단계, 그리고 이상점수 예측 및 운영단계를 포함할 수 있는 것이다. On the other hand, the anomaly detection method implemented by the AI-based facility data anomaly detection system using the random cut forest algorithm as described above is a learning model generation step, and anomaly score prediction and operation steps, as shown in the attached FIGS. 3 and 4 that can include

상기 학습 모델 생성단계는 첨부된 도 3에서와 같이, 설비에 설치되는 AI 기반의 고장진단 스마트 센서(10)로부터 수집된 데이터를 전처리하는 단계, 상기 전처리하는 단계로부터 전처리된 데이터를 클라우드 서버(40)의 데이터 베이스(41) 및/또는 빅데이터 베이스(42)에 저장하는 단계, 상기 저장하는 단계로부터 저장된 전처리 데이터에서 랜덤 트리를 구성하여 정상 데이터 기반의 학습 모델을 생성하는 단계, 그리고 상기 생성하는 단계로부터 생성된 학습 모델을 상기 데이터 베이스(41) 및/또는 빅데이터 베이스(42)에 저장하는 단계를 포함할 수 있는 것이다.As shown in the attached FIG. 3, the learning model creation step is the step of pre-processing the data collected from the AI-based fault diagnosis smart sensor 10 installed in the facility, and the pre-processed data from the pre-processing step is transferred to the cloud server 40. Storing in the database 41 and / or big data base 42 of ), constructing a random tree from the preprocessed data stored from the storing step to generate a learning model based on normal data, and generating the A step of storing the learning model generated from the step in the database 41 and/or the big data base 42 may be included.

또한, 상기 이상점수 예측 및 운영단계는 첨부된 도 4에서와 같이, 설비에 설치되는 AI 기반의 고장진단 스마트 센서(10)로부터 데이터가 수집시 이를 클라우드 서버(40)를 통해 제공받아 전처리하는 단계, 상기 학습모델 생성단계에 포함되는 저장하는 단계로부터 저장된 학습모델을 기반으로 상기 클라우드 서버(40)를 통해 모니터링되는 측정하고자 하는 데이터로서 아래의 수학식 1, 2에서와 같이 랜덤 컷 포레스트 알고리즘(IRCF; Improve Random Cut Forest)을 이용하여 이상점수(Optimize calculation of CoDISP)를 계산하는 단계, 그리고 상기 계산하는 단계로부터 계산된 이상점수가 높으면 설비 알람을 발생시키는 단계를 포함할 수 있는 것이다. In addition, the abnormal score prediction and operation step is, as shown in the attached FIG. 4, when data is collected from the AI-based fault diagnosis smart sensor 10 installed in the facility, it is provided through the cloud server 40 and pre-processed. , Random cut forest algorithm (IRCF ;

생산 제조 공정의 생산품 불량 감지와 기계 이상 감지는 실시간으로 진행된다. 또한 실제 공장에서 수집되는 센서 데이터의 특성상 많은 불량 데이터를 확보하기 어렵기 때문에 현실적으로 정상 데이터만으로 학습해서 불량을 감지해낼 수 있어야 한다. 그래서 본 발명은 실시간 처리가 가능하며 정상 데이터만으로 학습하는 One class classification(이하 OCC, 또는 Novelty detection) 이상감지 알고리즘의 개발 및 수학적인 개선을 목표로 문제 해결을 진행하고자 하였다.Product defect detection and machine abnormality detection in the production manufacturing process are performed in real time. In addition, since it is difficult to secure a lot of defective data due to the nature of sensor data collected in actual factories, it is necessary to be able to detect defects by learning only with normal data in reality. Therefore, the present invention is capable of real-time processing and aims to develop a One class classification (hereinafter OCC, or Novelty detection) anomaly detection algorithm that learns only with normal data and solves the problem with the goal of mathematical improvement.

본 발명의 시작은 Scikit-learn에 탑재되어 있으며 기존의 고전적인 이상감지 모델에 비해 월등한 성능을 가지고 있는 Isolation Forest라는 트리 기반의 이상감지 모델이다. The start of the present invention is a tree-based anomaly detection model called Isolation Forest, which is loaded in Scikit-learn and has superior performance compared to existing classical anomaly detection models.

이 모델은 랜덤트리를 활용하여 속도가 빠르며 Outlier detection에 강점을 가지고 있다. 하지만 정상 데이터만으로 학습하였을 때 불량을 감지하는 효율이 떨어지기 때문에 본 발명이 목적하는 바에 적용이 어려웠다(Isolation forest는 Outlier detection 문제에 높은 성능을 보인다). This model utilizes a random tree and is fast and has strengths in outlier detection. However, it is difficult to apply the present invention to the intended purpose because the efficiency of detecting defects is low when learning with only normal data (Isolation forest shows high performance for outlier detection problems).

또한 이는 주어진 불량 샘플을 마치 정상처럼 보이게 만드는 조력자(colluder)로 인해 정상으로 오판하여 미검출하는 문제인 마스킹 문제(masking problem)를 극복하기 위해 최근에 연구되어 2016년 ICML에 소개된 Robust Random Cut Forest(이하 'RRCF' 라함)라는 알고리즘을 적용하였다.In addition, this is a Robust Random Cut Forest (Robust Random Cut Forest, introduced in ICML in 2016) that has been recently researched to overcome the masking problem, which is a problem in which a given bad sample is mistakenly judged as normal due to a colluder that makes it look normal. Hereinafter referred to as 'RRCF') was applied.

상기 RRCF의 가장 큰 특징은 Isolation Forest와 달리 다이내믹한 트리구조를 갖는다는 것이다. 즉 학습이 끝난 트리구조에서도 새로운 인풋에 대해 트리구조를 순차적으로 변화시켜 나갈 수 있다. 이러한 특징으로 인해 실시간 스트리밍 데이터에 대한 이상 감지 문제에 활용할 수 있다. The biggest feature of the RRCF is that it has a dynamic tree structure, unlike the isolation forest. That is, the tree structure can be sequentially changed for new input even in the tree structure after learning has been completed. Due to these characteristics, it can be used for an anomaly detection problem for real-time streaming data.

또한 Isolation Forest의 깊이(depth)에 기반한 이상 감지 스코어링 방식과 달리 Collusive Displacement(CoDISP)라는 스코어링 방식을 사용하는데 이는 마스킹 문제(masking problem)를 해소하는데 중요한 역할을 하고 있다. In addition, unlike the anomaly detection scoring method based on the depth of the isolation forest, a scoring method called Collusive Displacement (CoDISP) is used, which plays an important role in solving the masking problem.

본 발명자들은 사전 연구를 통하여 RRCF 알고리즘이 센서 데이터 OCC 문제에 매우 효과적이라는 것을 확인하였다. 즉, CNC 전류 및 생산 로봇 진동 데이터를 포함한 다양한 벤치마크 데이터에서 높은 정확도와 높은 AUROC 값을 얻었다.The present inventors confirmed that the RRCF algorithm is very effective for the sensor data OCC problem through prior research. That is, high accuracy and high AUROC values were obtained from various benchmark data including CNC current and production robot vibration data.

하지만 RRCF를 실시간 이상 감지에 적용하기 어려울 정도로 속도가 느리고 모델의 사이즈가 크다는 문제점이 있었다. 다이내믹한 트리 구조를 갖기 위해 많은 계산 비용(Computational Cost)을 필요로 한다. 즉 이미 학습이 끝난 상황에서도 예측 과정에서 상대적으로 많은 시간을 소모하게 된다. However, there were problems in that the speed was so slow that it was difficult to apply RRCF to real-time anomaly detection and the size of the model was large. A lot of computational cost is required to have a dynamic tree structure. That is, a relatively large amount of time is consumed in the prediction process even when learning has already been completed.

두 번째는 모델의 크기가 크다는 것이다. 이는 역시 다이내믹한 트리 구조를 가지기 위해 트리의 각 노드 마다 경계 상자(Bounding box)정보를 가지고 있어야 하며 이는 모델의 사이즈를 커지게 하는 원인으로 작용한다. 사실 모델사이즈를 줄여주기 위해 경계 상자 정보를 모델에서 제외하고 inference 과정에서 학습 데이터를 넣어 주는 방법 또한 고려해 볼 수 있다. Second, the size of the model is large. In order to have a dynamic tree structure, each node of the tree must have bounding box information, which causes the size of the model to increase. In fact, to reduce the size of the model, it is also possible to consider a method of excluding bounding box information from the model and inserting training data in the inference process.

그러나 이 방법은 매 inference 과정에서 경계 상자를 다시 계산해야 하므로 계산 비용을 늘어나게 만든다. 즉 모델의 크기는 속도와 상충관계(trade off relationship)가 있다.However, this method increases the computational cost because the bounding box must be recalculated at every inference step. In other words, model size has a trade off relationship with speed.

본 발명은 RRCF 알고리즘을 실제 산업현장에서 활용 가능한 수준으로 최적화하고 개선된 RRCF의 적정 하이퍼 파라미터에 대한 연구와 기존의 이상 감지 알고리즘과의 비교 분석하고, 마지막으로 RRCF에서 사용하는 스코어링 방식(Collusive Displacement)의 수학적 의미에 대해 정리하였다.The present invention optimizes the RRCF algorithm to a level that can be used in the actual industry, studies the appropriate hyperparameters of the improved RRCF, compares and analyzes it with the existing anomaly detection algorithm, and finally the scoring method used in RRCF (Collusive Displacement) The mathematical meaning of is summarized.

RRCF는 스트림에서 강력한 랜덤 컷 포레스트 기반 이상 탐지하는 것으로, Proceedings of the 33rd ICML, New York (2016)에서 소개되었으며 2008년에 소개된 Isolation forest 알고리즘을 스트리밍 데이터의 이상 감지에 맞게 고안한 방법이다. Isolation forest와 RRCF의 공통적인 특징은 랜덤 트리 기반의 배깅(bagging) 앙상블 모델로 여러 개(default = 100)의 랜덤트리를 학습하여 이상감지에 활용한다.RRCF is a powerful random cut forest-based anomaly detection in streams. It was introduced in Proceedings of the 33rd ICML, New York (2016), and it is a method designed to fit the isolation forest algorithm introduced in 2008 to detection of anomalies in streaming data. A common feature of isolation forest and RRCF is a random tree-based bagging ensemble model, which uses multiple (default = 100) random trees to learn and detect anomalies.

Isolation forest는 기존의 전통적인 이상 감지 모델과 비교하여 outlier detection 문제에 높은 AUROC 지표를 보여준다. 또한 기존의 거리 기반, 밀도 기반의 이상 감지 알고리즘과 비교하여 빠른 속도를 보인다. Isolation forest shows a high AUROC index for the outlier detection problem compared to conventional anomaly detection models. It also shows faster speed compared to the existing distance-based and density-based anomaly detection algorithms.

Random sampling 방법을 사용하므로 매우 큰 사이즈의 데이터에 대해서도 효과적으로 적용할 수 있으며 실제 이상 감지에 불필요한 차원이 있어도 비교적 큰 영향을 받지 않는다는 장점이 있다. RRCF는 IF(Isolation forest)와 다음과 같은 차이가 존재한다.Since it uses a random sampling method, it can be effectively applied even to very large data, and has the advantage of being relatively unaffected even if there are unnecessary dimensions for actual anomaly detection. RRCF has the following differences from IF (Isolation forest).

IF(Isolation forest)는 첨부된 도 13에서와 같이 이진 트리 분기마다 feature를 선택할 때 uniform distribution 위에서 선택하는 것이다.IF (Isolation forest) is selected on a uniform distribution when selecting a feature for each binary tree branch, as shown in the attached FIG.

즉, 랜덤값으로 column(q) 선택 이후에 column(q) 범위(min-max) 중 random uniform 하게 split point를 지정하고, scoring은

Figure pat00003
로서(단, E(h(x))는 모든 i당 관측치에 대한 평균 길이, c(n)은 iTree의 평균 경로 길이).That is, after selecting column (q) with a random value, the split point is designated randomly uniformly among the column (q) range (min-max), and scoring is
Figure pat00003
as (where E(h(x)) is the average length over all observations per i, and c(n) is the average path length of the iTree).

when E(h(x))→c(n), s→0.5when E(h(x))→c(n), s→0.5

when E(h(x))→0, s→1when E(h(x))→0, s→1

when E(h(x))→n-1, s→0 when E(h(x))→n-1, s→0

즉, 도 5 및 도 6을 참조하면, IF(Isolation forest)는 샘플의 깊이(depth, 루트노드와의 거리)에 기반하여 이상 스코어를 측정하지만, RRCF에서는 (masking problem을 완화 목적) CoDISP으로 이상점수(anomaly score)를 측정한다. That is, referring to FIGS. 5 and 6, IF (Isolation forest) measures the anomaly score based on the depth (distance from the root node) of the sample, but in the RRCF (for the purpose of mitigating the masking problem), CoDISP Anomaly score is measured.

Isolation Forest는 기존 생성한 트리를 고정시키고 새로운 샘플(test set)이 들어왔을 때 기존 트리에 태워 보내는 방식으로 불량을 감지하지만 RRCF는 Insertion과 Deletion 방법으로 트리를 변형하여 스트리밍 데이터의 불량 감지하는 것이다. Isolation Forest detects defects by fixing the previously created tree and burning it to the existing tree when a new sample (test set) comes in, but RRCF detects defects in streaming data by transforming the tree with Insertion and Deletion methods.

일예로, 256개의 데이터

Figure pat00004
에 있어, 상기 St로 만들어진 T(St)에서 Xt-255)를 삭제하고, Xt+1를 추가하여 새로운 판단 트리를 생성할 수 있는 것이다.For example, 256 data
Figure pat00004
, it is possible to create a new decision tree by deleting Xt-255) from T(St) made of St and adding Xt+1.

여기서, T(St+1)은 처음부터 새로운 트리를 생성하는 것이고, T'(St+1)은 St 트리에 추가 삭제 연산이 이루어지는 것으로, 상기 T(St+1)와 상기 T'(St+1)의 확률은 다르며, 상기 T(St+1)는 매 순간 트리를 다시 만들어야 하는 것으로, 본 발명 실시예의 RRCT는 상기 T(St+1)와 상기 T'(St+1)의 분포가 같아지도록 하는 상기 랜덤 컷 포레스트 알고리즘(IRCF)을 사용하는 것이다.Here, T(St+1) is to create a new tree from scratch, and T'(St+1) is an addition/deletion operation performed on the St tree, and the T(St+1) and T'(St+1) The probability of 1) is different, and the T (St + 1) needs to recreate the tree every moment. The Random Cut Forest Algorithm (IRCF) is used.

또한, 상기 Displacement(Real Time)의 계산 방식에 있어, Disp(x, S)=T(S)-{x)일 때 자매 노드의 샘플 깊이(depth) 변화의 총량 평균으로 첨부된 도 16 및 도 17에 예시되어 있다.16 and FIG. 16 and FIG. 17 is illustrated.

여기서, 상기 계산하는 단계에서의 이상점수 계산은 동적 트리를 가지고 있지 않으면서 동적인 학습모델을 이용한 이상점수를 예상하는 확률기반의 계산 방식을 적용한 상기 랜덤 컷 포레스트 알고리즘(IRCF)을 이용하는 것이다.Here, the calculation of the ideal score in the calculating step uses the random cut forest algorithm (IRCF) to which a probability-based calculation method for predicting the ideal score using a dynamic learning model without having a dynamic tree is applied.

즉, 본 발명의 실시예에서, 설비 데이터는 클라우드 서버(40)를 통해 데이터 베이스(41)와 빅데이터 베이스(42)에 정상데이터만 확보되어 저장되는 경우가 많고 비정상 데이터는 없거나 극히 일부만 수집된다. 때문에 비정상 데이터가 들어와도 관리자 분석 처리부(30)에서는 설비 고장진단 모니터링부(20)에 의해 모니터링되는 데이터로부터 이상으로 판단이 안될 가능성이 높고 또한 정상데이터를 비정상으로 판단하는 경우가 많을 수 있다.That is, in the embodiment of the present invention, in many cases, only normal data is secured and stored in the database 41 and the big database 42 through the cloud server 40, and there is no abnormal data or only a small part of the facility data is collected. . Therefore, even if abnormal data is received, there is a high possibility that the manager analysis processing unit 30 will not judge it as abnormal from the data monitored by the facility failure diagnosis and monitoring unit 20, and there may be many cases in which normal data is judged to be abnormal.

이에, 상기 관리자 분석 처리부(30)의 랜덤 컷 포레스트 알고리즘은 정상 데이터만 가지고 학습되었을 때도 비정상을 검출하기 위해서 비정상 데이터를 삽입하여 동적으로 학습된 모델을 변경하도록 하였고, 검증하고자 하는 비정상 데이터를 이상 감지하고자 할 때, 비정상 데이터를 학습모델에 삽입하여 모델을 재구성하고 비정상 데이터를 검증하여 이상 점수가 매우 높게 나오는 것을 예측할 수 있도록 하는 것이다. Therefore, the random cut forest algorithm of the manager analysis processing unit 30 dynamically changes the learned model by inserting abnormal data in order to detect abnormalities even when it is learned with only normal data, and detects anomalies in abnormal data to be verified When you want to do this, you insert abnormal data into the learning model to reconstruct the model and verify the abnormal data so that you can predict very high abnormal scores.

즉, 정상적인 학습 데이터(X)는,That is, the normal learning data (X) is,

Figure pat00005
; X의 내부데이터x로부터 xn번째까지 - (1)로서,
Figure pat00005
; From the internal data x of X to the xnth - (1),

상기 학습 데이터(X) 집합에서 n(≤N)을 무작위 선택하면,If n (≤N) is randomly selected from the set of learning data (X),

Figure pat00006
- (2)이고,
Figure pat00006
- (2),

상기 X1을 기반으로 RRC Tree를 생성하면, 상기 (1),(2)의 작업을 충분하게 많이 수행할 수 있는 것이다.If the RRC Tree is created based on the X1, the tasks (1) and (2) above can be performed sufficiently.

여기서, 상기 (1),(2)의 수행 결과인 RRC Tree의 개수는 number of trees라고 하며, 상기 RRC Tree의 모임을 RRC Forest 라고 하는 것이다. Here, the number of RRC Trees, which is the result of performing (1) and (2), is called number of trees, and the collection of RRC Trees is called RRC Forest.

따라서, 상기 RRCF는,Therefore, the RRCF is,

Figure pat00007
로서,
Figure pat00007
as,

상기 RRC Tree를 생성하는데 사용된 점은 total depth의 변화량과 관련있는 방식으로 이상점수(CoDISP)를 측정할 수 있는 것이다.The point used to generate the RRC Tree is that the abnormal score (CoDISP) can be measured in a manner related to the amount of change in total depth.

한편, 정상 불량 여부를 판단하고자 하는 데이터 P, 그리고 새로운 데이터 P를 상기에서 설명하는 트리에 삽입 알고리즘(insertion algorithm)으로 추가하여 변형된 트리를 생성할 수 있다.Meanwhile, a modified tree may be created by adding the data P to be determined whether it is normal or not and the new data P to the tree described above by an insertion algorithm.

{T1', T2',…,T'}{T1', T2', ... ,T'}

여기서, 상기 T1'는 {x1(1),…,x1(n), P}의 데이터로 생성된 트리이며, 모든 변형된 트리에는 상기 P가 사용되는 것이다. Here, the T1' is {x 1(1) ,... ,x 1(n) , P}, and P is used in all transformed trees.

그러므로, 모든 변형된 트리에서 P의 이상점수(CoDISP)를 계산하고 이 계산된 값들의 평균값으로 상기 P의 이상점수를 정의할 수 있는 것이다. Therefore, it is possible to calculate the outlier score (CoDISP) of P in all transformed trees and define the outlier score of P as the average value of these calculated values.

또한, 모든 변형된 트리에서 P 포인트를 제거하여 원래 트리들의 모임으로 되돌려 놓는다. Also, P points are removed from all transformed trees, returning them to the collection of original trees.

이때, 트리 생성 → 데이터 추가 및 변형 트리 생성 → 이상점수(CoDISP)를 계산한 후 데이터를 제거하는 과정을 반복하면, 상기 이상점수(CoDISP)의 평균으로 이상 점수를 새롭게 얻을 수 있는 것이다. At this time, if the process of tree creation → data addition and transformation tree creation → data removal after calculating the outlier score (CoDISP) is repeated, a new anomaly score can be obtained as the average of the outlier scores (CoDISP).

즉, 트리 생성시 데이터의 샘플링과 함께 특징 샘플링(feature sampling)을 도입하면서, 트리의 사이즈 감소 및 속도를 개선하고, 스케일이 작은 데이터의 이상 감지 효과를 증가시킬 수 있는 것이다. That is, while introducing feature sampling along with data sampling when creating a tree, it is possible to reduce the tree size and improve speed, and to increase the anomaly detection effect of small-scale data.

또한, 변형된 트리를 생성하지 않고 추가함으로써, 데이터의 이상점수(CoDISP) 만을 연산하여 빠른 속도를 기대할 수 있는 것이다. In addition, by adding the deformed tree without generating it, high speed can be expected by calculating only the outlier score (CoDISP) of the data.

또한, 상기 이상점수(CoDISP)는 확률적으로 얻는 값이기 때문에 매번 달라지는 상기 이상점수(CoDISP) 값을 고정시키기 위해 상기 이상점수(CoDISP)의 확률적 기대값을 결과값으로 사용하는 것이다. In addition, since the ideal score CoDISP is a value obtained probabilistically, a probabilistic expected value of the ideal score CoDISP is used as a result value in order to fix the value of the ideal score CoDISP, which changes each time.

(1) Isolation forest. (1) Isolation forest.

RRCF가 느린 속도와 큰 모델 용량을 갖는 이유는 다음과 같다. The reasons for the slow speed and large model capacity of RRCF are as follows.

먼저, Isolation forest와 달리 학습할 때 트리가 분기할 때마다 모든 feature의 range를 계산해야 하기 때문에(Isolation forest는 랜덤하게 feature를 선택) 계산 시간이 소요된다. 또한, 기존 트리에 새로운 샘플을 추가해서 트리를 변형하는 Insertion 알고리즘 할 때 모든 internal node에 feature의 range 정보(bounding box)를 저장하고 있어야 한다. First, unlike the isolation forest, it takes time to calculate because the range of all features must be calculated every time the tree branches during training (Isolation forest randomly selects features). Also, when performing the insertion algorithm that transforms the tree by adding new samples to the existing tree, the range information (bounding box) of the feature must be stored in all internal nodes.

즉, RRCF는 차원이 높으면 데이터의 모델 학습시간이 오래 걸리고 모델의 크기가 무거워지는 문제가 발생하는 알고리즘이다. In other words, RRCF is an algorithm that takes a long time to train a model of data and increases the size of the model when the dimension is high.

[수학식 1][Equation 1]

Figure pat00008
Figure pat00008

즉, 첨부된 도 14를 참조하면, 컬럼 선택 확률

Figure pat00009
일 때, That is, referring to the attached FIG. 14, the column selection probability
Figure pat00009
when,

Figure pat00010
이고,
Figure pat00010
ego,

선택 이후 column(q) 범위(min-max) 중 random uniform 하게 split point를 지정하는 것이다.After selection, the split point is designated randomly and uniformly among the column (q) range (min-max).

더불어, 첨부된 도 15에서와 같이 Displacement(DISP)라는 스코어링 방식은, Displacement(Real Time)에서 이상 데이터는 트리에 주게 되는 영향이 크고, T(s)-{x}일때 자매 노드의 샘플 깊이(depth) 변화의 총량을 나타낼 수 있다.In addition, as shown in the attached FIG. 15, in the scoring method called Displacement (DISP), the abnormal data in Displacement (Real Time) has a large effect on the tree, and when T(s)-{x}, the sample depth of the sister node ( depth) can represent the total amount of change.

여기서, 상기 Real Time Streaming는 실시간 변화하는 데이터에 맞게 Tree를 수정하여 판단하는 것이다.(많은 학습 데이터의 개수는 sampling 방식으로 회피 가능). 이 문제 해결을 위해 본 발명에서는 다음과 같은 방법을 제시하는 것이다. Here, the Real Time Streaming is determined by modifying the tree according to the data changing in real time. (A large number of training data can be avoided by sampling method). To solve this problem, the present invention proposes the following method.

(2) Optimize calculation of CoDISP(2) Optimize calculation of CoDISP

먼저 Insertion과 Deletion 방법은 도 7에서 보이는 바와같이 새로운 샘플을 추가하거나 기존의 샘플을 빼서 트리를 생성(reform)하는 방법이다. 이러한 방식으로 트리를 생성하는 목적은 스트리밍 데이터 처리를 위해서이다. 새로 측정된 최신 데이터를 Insertion하고 가장 과거의 데이터를 Deletion하는 방법은 동적으로 트리를 변형하여 시계열 스트리밍 데이터의 이상감지를 하는 핵심 방법이다.First, the Insertion and Deletion methods are methods of reforming a tree by adding a new sample or subtracting an existing sample, as shown in FIG. 7 . The purpose of creating a tree in this way is to process streaming data. The method of inserting the latest newly measured data and deleting the most recent data is a key method for detecting anomalies in time-series streaming data by dynamically transforming the tree.

스트리밍 시계열 데이터를 처리하기 위해서는 변형된 트리가 다음 시계열 데이터 처리를 위해서 필요하다. 이러한 트리 생성 과정의 중요한 부분은 Insertion 과정에서 random process로서 할 때마다 다른 트리가 생성될 수 있다는 점이다. 그런데 만약 고정된 샘플을 Insert하고 delete하는 경우에는 자연스럽게 처음의 트리로 돌아가게 된다. 이러한 관찰을 바탕으로 트리 생성 과정없이 스코어링만을 하는 방법을 통한 모델 최적화 방안을 제시하는 것이다.In order to process streaming time series data, a transformed tree is needed for processing the next time series data. An important part of this tree creation process is that a different tree can be created each time as a random process in the insertion process. However, if a fixed sample is inserted and deleted, it naturally returns to the initial tree. Based on these observations, we propose a model optimization method through a method of scoring only without tree generation.

문제는 정상 데이터를 확보한 상황에서 새로 들어오는 샘플에 대해 정상 또는 불량을 판단하는 것이다. RRCF의 방법은 새로운 샘플에 대해 트리를 변형시키는 과정과 스코어링을 하는 과정이 하나로 묶여있다. 그러나 트리 변형 과정이 필수적이지 않다면 새로운 샘플을 Insert하고 스코어링을 한 다음 Deletion하는 과정을 단순화 할 수 있다. 즉, OCC 문제에서는 트리를 다이내믹한 구조로 변화시켜 저장해 놓을 필요가 없다. 그래서 본 발명자들은 트리 생성 과정없이 CoDISP 이상 스코어만 계산하는 방법을 제시하는 것이다. The problem is to determine whether a new incoming sample is normal or bad in a situation where normal data is obtained. The RRCF method combines the process of transforming the tree for new samples and the process of scoring. However, if the tree transformation process is not essential, the process of inserting a new sample, scoring, and then deleting can be simplified. That is, in the OCC problem, it is not necessary to change the tree into a dynamic structure and store it. Therefore, the present inventors propose a method of calculating only the CoDISP abnormality score without a tree generation process.

Insertion 방법은 새로운 샘플이 주어진 트리의 internal node를 타고 내려가면서 새롭게 분기가 되는지를 확률적으로 결정해서 기존 트리를 변형한다. 본 발명자들은 여기서 트리를 변형하지 않고 분기가 됐을 경우를 고려하여 그 샘플의 스코어만 계산하는 알고리즘으로 최적화하였다.The insertion method transforms the existing tree by probabilistically determining whether a new sample will branch as it descends the internal node of the given tree. The present inventors optimized with an algorithm that calculates only the score of the sample in consideration of the case where the tree is branched without transforming.

(3) Feature sampling method (3) Feature sampling method

Feature sampling 이란 학습 데이터로 RRCTree를 생성할 때 모든 feature를 사용하는 것이 아니라 고정된 수(parameter)의 feature를 임의로(uniformly random) 선택하여 그 feature만 이용해서 트리를 생성하는 방식이다. 예를 들어서 해당 파라미터를 1인 경우에는 feature들 중 하나를 임의로 선택하고 그 하나의 피쳐만으로 RRCTree를 생성하게 된다. RRCTree를 생성할 때 internal node에서 feature들의 range를 고려해서 랜덤하게 feature를 선택한다. 스케일이 작은 feature의 영향을 줄일 수 있다는 장점이 있지만 반대로 그러한 feature에서 이상감지가 이루어져야 할 경우에는 선택이 되지 않을 확률이 크다. 그래서 스케일이 작은 feature의 특이값은 이상으로 감지하기 어려운 문제점이 있다. 이와 달리 Feature sampling 방법을 사용하게 되면 트리 생성 전에 range와 무관하게 임의로(uniformly random) feature 를 선택하기 때문에 스케일이 작은 feature의 선택될 확률을 더 높일 수 있다. Feature sampling is a method of generating a tree using only those features by uniformly randomly selecting a fixed number of features (parameters) instead of using all features when creating an RRCTree as training data. For example, if the parameter is 1, one of the features is randomly selected and an RRCTree is created with only that one feature. When creating a RRCTree, features are selected randomly considering the range of features in the internal node. It has the advantage of being able to reduce the influence of small-scale features, but on the contrary, it is highly unlikely to be selected when anomaly detection must be performed on such features. Therefore, it is difficult to detect the singular value of a feature with a small scale as an anomaly. On the other hand, if the feature sampling method is used, the probability of selecting a feature with a small scale can be increased because the feature is selected uniformly random regardless of the range before tree generation.

스케일이 작은 feature에서 발생한 이상값을 Feature sampling 있는 모델과 없는 모델의 결과를 도 8에서 비교한다. 또한 위에서 설명한 것처럼 RRCTree 모든 internal node에는 각 차원의 range 정보를 저장하고 있는데 Feature sampling으로 트리를 구성하는 데이터의 feature의 수가 적어서 모델 사이즈를 줄일 수 있다. 크기는 샘 플링하는 feature 수에 선형적으로 감소한다. 물론 데이터 행렬의 크기가 작아지기 때문에 속도 개선도 기대할 수 있다. 추가로 몇 개의 feature를 선택할 것이지도 다양한 데이터로 테스트를 진행하여 디폴트 값을 제시하였다.Figure 8 compares the results of models with and without feature sampling for outliers that occur in small-scale features. Also, as described above, all internal nodes of the RRCTree store range information of each dimension, but the model size can be reduced because the number of features of the data constituting the tree is small through feature sampling. The size decreases linearly with the number of features sampled. Of course, since the size of the data matrix is reduced, speed improvement can also be expected. In addition, a few features to be selected were tested with various data and the default value was presented.

이러한 Feature sampling 방법은 다른 의미로도 해석할 수 있다. IF방식의 트리생성은 각 피쳐를 모두 독립적인 것으로 보고 uniform random으로 각 노드에서 feature와 cut value를 정하게 된다. 반면 RRCF 의 경우 최대-최소 범위를 고려하여 feature를 선택하게 되는데 이는 각 스케일에 따라 feature마다 다른 가중치를 준다고 볼 수 있다. This feature sampling method can also be interpreted in other ways. In the tree generation of the IF method, each feature is regarded as independent, and the feature and cut value are determined at each node with uniform randomness. On the other hand, in the case of RRCF, features are selected considering the maximum-minimum range, which can be seen as giving different weights to each feature according to each scale.

Feature sampling 방법을 통해 IF 방식과 RRCF 방식을 parametrize하고 적절한 중간 지점을 찾아 이용할 수 있다. 예를 들어서, Feature sampling parameter 를 1로 두면 RRCF의 트리 생성 방식은 IF와 동일하다. Parameter를 늘려감에 따라 RRCF는 더 많은 수의 feature들에 대해 스케일을 고려한 트리 생성방식을 따르게 된다.Through the feature sampling method, the IF method and the RRCF method can be parametrized and an appropriate middle point can be found and used. For example, if the feature sampling parameter is set to 1, the tree construction method of RRCF is the same as that of IF. As the parameter is increased, RRCF follows the tree generation method considering the scale for a larger number of features.

(4) Deterministic anomaly score (4) Deterministic anomaly score

RRCF는 IF와 달르게 고정된 테스트 샘플에 대해 매번 다른 스코어링 결과를 준다. 학습이 끝난 상황에서 스코어링을 하는 과정에서 존재하는 random process 때문에 발생된다. 고정된 테스트 샘플에 대해서 고정된 스코어를 주기 위해서 random process를 deterministic process로 바꾸는 것을 제안하는 것이다.Unlike IF, RRCF gives different scoring results each time for a fixed test sample. It occurs because of the random process that exists in the process of scoring after learning is complete. It is proposed to replace the random process with a deterministic process in order to give a fixed score for a fixed test sample.

새로운 샘플의 이상 스코어를 계산할 때 트리를 생성하지 않고 Insertion 알고리즘을 사용한다. 앞에서 제시한 방법은 각 internal node에서 새로운 샘플이 분기를 하는지 Insertion 알고리즘으로 랜덤하게 결정하고 분기됐을 때 CoDISP를 계산하기 때문에 동일한 데이터의 이상 스코어값이 실행할 때마다 매번 다른 값이 도출된다. When calculating an anomaly score for a new sample, an insertion algorithm is used without creating a tree. The method presented above randomly determines whether a new sample diverges at each internal node with an insertion algorithm, and calculates CoDISP when it diverges, so a different value is derived each time the anomaly score of the same data is executed.

그러나, 상기 Disp는 첨부된 도 18에서와 같이 이상 데이터가 집합을 이루어 정상이도록 보이게 하는 마스킹(Masking)에 문제가 있다.However, the Disp has a problem in masking in which abnormal data are grouped to appear normal, as shown in FIG. 18.

반면, 본 발명의 실시예에 따른 Collusive Displacement(CoDISP)라는 스코어링 방식은 첨부된 도 19에서와 같이 그 계산에 있어,On the other hand, the scoring method called Collusive Displacement (CoDISP) according to an embodiment of the present invention is calculated as shown in FIG. 19,

Figure pat00011
로서, 이상 데이터의 집합 c를 모두 제거하였을 때의 총 변화량 최대값이고, 이는 상기 x의 조상들을 마스킹을 야기하는 colluder로 간주하여 계산하기 때문이다.(x의 자매 노드에 있는 데이터 개수/1, x의 부모 노드의 자매 노드에 있는 데이터 개수/부모 노드의 크기)
Figure pat00011
, which is the maximum value of the total change when all sets of abnormal data c are removed, because it is calculated by considering the ancestors of x as colluders that cause masking. (The number of data in sister nodes of x / 1, The number of data in the sister nodes of the parent node of x/size of the parent node)

[수학식 2][Equation 2]

Figure pat00012
Figure pat00012

샘플 S의 트리 T(S)와 포인트(p)가 주어지면 T(S∪{p})의 랜덤 트리를 효율적으로 계산할 수 있으므로, 직관적으로 포인트를 포함하는 동시 분포가 이를 제외하는 분포와 크게 다른 경우, 포인트(p)를 비정상으로 라벨링하게 되며, 이는 포인트(p)를 포함하는 동시 분포를 효율적으로 스케치할 수 있을 것이기 때문이다.Given a tree T(S) of samples S and a point (p), it is possible to efficiently compute a random tree of T(S∪{p}), so intuitively the simultaneous distribution containing the points differs significantly from the distribution excluding them. In this case, we will label point p as abnormal, since we will be able to sketch the simultaneous distribution containing point p efficiently.

상기 라벨을 결정하기 위해 포인트(p)에 대한 샘플링된 데이터 포인트의 영향을 측정하는 대신(예상 깊이와 같은 개념에 의해 측정된 것처럼) 샘플링된 포인트에 대한 p의 영향을 측정하도록 하였다.Instead of measuring the influence of the sampled data point on point p to determine the label (as measured by concepts such as expected depth), we measure the influence of p on the sampled point.

또한, 이동 정량화를 위해 랜덤 컷 포레스트의 트리에서 왼쪽 가지에 비트 0을 할당하고 오른쪽 가지에 비트 1을 할당한다고 가정시, 포인트(p)를 지정하는 비트를 고려해야 한다(포인트 자체의 속성 값을 저장하는 데 필요한 비트는 제외).In addition, assuming that bit 0 is assigned to the left branch and bit 1 to the right branch in the tree of the random cut forest for movement quantification, one has to consider the bit specifying the point p (stores the attribute value of the point itself). except for the bits required to do so).

따라서, 한 점을 표현하는 데 필요한 비트 수는 트리의 깊이에 해당하므로, 점 Z의 집합과 점 y ∈ Z가 주어지면 f(y, Z, T)를 트리 T에서 y의 깊이라고 정의하며, x를 T(Z-{x})로 삭제하여 생성된 트리를 고려할 때 주어진 T 및 x 트리 T(Z-{x})는 고유하게 1로 결정된다.Thus, the number of bits required to represent a point corresponds to the depth of the tree, so given a set of points Z and a point y ∈ Z, we define f(y, Z, T) to be the depth of y in the tree T, and x Considering the tree generated by deleting T(Z-{x}), given T and x tree T(Z-{x}) is uniquely determined to be 1.

T(Z-{x})에서 y의 깊이를 f(y, Z-{x},T)라고 하면, 첨부된 도 20에서와 같이, 하위 트리 c에 있는 점 y를 고려하여, T에서의 비트 표현은 q0,...,qr, 0, 0,....|M(T)|로 표시되는 모델 복잡도를 나타낸다. 따라서 모든 점 y intree T의 설명을 기록하는데 필요한 비트 수는 |M(T)|=y∈Z f (y, Z, T )이고, x를 제거하면 새 모델 복잡성은 아래의 수식과 같다.If the depth of y in T(Z-{x}) is f(y, Z-{x},T), as in the attached FIG. 20, considering the point y in subtree c, at T The bit representation represents the model complexity denoted by q0,...,qr, 0, 0,...|M(T)|. Therefore, the number of bits required to write the description of every point y intree T is |M(T)|=y∈Z f (y, Z, T ), and removing x, the new model complexity is:

Figure pat00013
Figure pat00013

여기서 T’= T(Z-{x})는 Z-{x}에 대한 트리이며, 임의 모델에서 예상되는 모델 복잡성의 변화를 고려한다. 그러나 T(Z)에서 T(Z-{x})로의 다대일 매핑이 있으므로 T = T(Z) 대신 T(Z)에 대한 두 번째 합을 표현할 수 있다(T’=T(Z-{x}).where T'= T(Z-{x}) is a tree over Z-{x}, taking into account the expected change in model complexity for any model. However, since there is a many-to-one mapping from T(Z) to T(Z-{x}), we can express the second sum over T(Z) instead of T = T(Z) (T'=T(Z-{x}). }).

Figure pat00014
Figure pat00014

점 x의 비트 변위 또는 변위를 다른 모든 점의 모델 복잡성의 증가로 정의한다. 즉, 집합 Z에 대해 x에 의해 도입된 외부성을 포착하기 위해 정의하며, 이는 T = T(Z - {x})로서,We define the bit displacement or displacement of point x as the increase in the model complexity of all other points. That is, we define to capture the externality introduced by x on the set Z, as T = T(Z - {x}),

Figure pat00015
Figure pat00015

모델 복잡도의 총 변화는 DISP(x, Z )+g(x, Z )이며, 여기서 g(x, Z )=T Pr [T] f (x, Z, T )는 예상 깊이이다. 임의의 모델에서 점 x. 이상 현상이 큰 g()에 해당한다고 가정하는 대신 DISP()의 더 큰 값에 중점을 두면 다음 보조 정리를 기반으로 이름 변위가 더 명확해질 수 있다.The total change in model complexity is DISP(x, Z )+g(x, Z ), where g(x, Z )=T Pr [T] f (x, Z, T ) is the expected depth. Point x in any model. If we focus on larger values of DISP() instead of assuming that the anomaly corresponds to large g(), the name displacement may become clearer based on the following lemma:

그러나, 이상 현상에 대한 가능한 정의를 가리키지만 명시된 정의는 중복 또는 거의 중복에 대해 강력하지 않다. 하나의 조밀한 클러스터와 클러스터에서 멀리 떨어진 점 p를 고려할 때 p의 변위는 클 것이다. 하지만, p에 매우 가까운 점 q가 있으면 p가 있을 때 q의 변위는 작아진다. 이 현상을 이상치 마스킹이라고 하며, 이는 중복 및 거의 중복은 자연스럽기 때문에 모든 이상 탐지 알고리즘의 의미 체계는 이를 수용해야 하는 것이다.However, while pointing to possible definitions of anomalies, the stated definitions are not robust against overlap or near-overlap. Considering one dense cluster and a point p far from the cluster, the displacement of p will be large. However, if there is a point q that is very close to p, the displacement of q is small when p is present. This phenomenon is called outlier masking, and since duplication and near duplication are natural, the semantics of all anomaly detection algorithms must accommodate it.

일예로, 중복 탄력성에 있어, Waldo가 숨기도록 도와주는 몇 명의 친구가 있다는 개념을 고려할 때 이 친구들은 공모자일 수 있고, 이 경우 모든 공모자를 제거하면 설명이 크게 변경될 수 있다. 구체적으로, 점 x를 제거하는 대신 x ∈ C를 사용하여 집합 C를 제거하는 것이다.For example, in redundancy elasticity, given the notion that Waldo has a few friends who help him hide, these friends could be conspirators, in which case removing all the conspirators would change the description significantly. Specifically, instead of eliminating the point x, we eliminate the set C using x ∈ C.

Figure pat00016
Figure pat00016

여기서 DISP(C, Z)는 로 표시된 부분 집합으로 확장된 변위의 개념으로서, T" = T(Z-C)이며, where DISP(C, Z) is the concept of displacement extended to the subset denoted by T" = T(Z-C),

Figure pat00017
Figure pat00017

도메인 지식이 없으면 변위가 C의 모든 점에 동일하게 귀속되어야 하는 것으로 보이게 된다. 따라서 C를 결정하는 자연스러운 선택은 max DISP(C, Z)/|C | x ∈ C ⊆ Z 의 적용을 받게 되지만, 이는 두 가지 문제가 발생하는 것이다.Without domain knowledge, it appears that the displacement should be equally attributed to all points in C. So the natural choice to determine C is max DISP(C, Z)/|C | It is subject to x ∈ C ⊆ Z, but this causes two problems.

첫째 C의 부분 집합이 너무 많고, 둘째 스트리밍 설정에서 샘플 S ⊂ Z 를 사용할 가능성이 높다. 따라서 자연 선택이라고 가정하는 것은 샘플로 확장되지 않으며, 상기 두 가지 문제를 모두 피하기 위해 다른 샘플 S에 대해 다른 C 선택을 허용해야 하며, 사실상 Waldo가 다른 테스트에서 다른 구성원과 공모하는 것을 허용하고 있으며, 이것은 다음과 같은 동기를 부여할 수 있는 것이다.First, there are too many subsets of C, and second, there is a high probability of using samples S ⊂ Z in the streaming setup. Therefore, assuming natural selection does not extend to samples, and to avoid both of the above problems, we must allow different C selections for different samples S, in effect allowing Waldo to collude with other members in different tests, This can motivate you to:

점 x의 CoDISP(x, Z, |S|)로 표시된 x의 담합 변위는 아래의 수식으로 정의된다.The collusive displacement of x denoted by CoDISP(x, Z, |S|) of point x is defined by the formula below.

Figure pat00018
Figure pat00018

CoDISP(x, Z, |S|)는 효율적으로 추정할 수 있다.CoDISP(x, Z, |S|) can be estimated efficiently.

CoDISP(x, Z, |S|)는 |S|에 종속되지만 종속성은 심하지 않다. 리소스 제약 조건에서 허용되는 가장 큰 샘플 크기를 사용할 수 있으며, 이상치는 큰 CoDISP()에 해당될 수 있다.CoDISP(x, Z, |S|) depends on |S|, but the dependency is minor. The largest sample size permitted by resource constraints can be used, and outliers can correspond to large CoDISP().

따라서, Robust Random Cut Tree(RRCT)를 동적으로 유지 관리하는 방법에 있어, RRCF(S)를 S에서 정의 1을 실행하여 트리에 대한 분포라고 하면, 분포 RRC F(S) 및 p ∈ S에서 추출한 T가 주어지면 RRC F(S ∪{p})에서 추출된 T가 생성되고, 분포 RRC F(S) 및 p ∈ S에서 추출된 T가 주어지면 RRC F(S-{p})에서 추출된 T가 생성되는 것을 고려할 수 있는 것이다.Therefore, in the method of dynamically maintaining Robust Random Cut Tree (RRCT), if RRCF(S) is the distribution for the tree by executing Definition 1 in S, the distribution RRC F(S) and p ∈ extracted from S Given T, yields T extracted from RRC F(S ∪{p}), and given T extracted from the distribution RRC F(S) and p ∈ S, yields T extracted from RRC F(S-{p}). It can be considered that T is generated.

일예로, 축 평행 절단을 사용하여 점 집합 S와 p를 분리하는 것은 축 평행 절단을 사용하여 최소 축 정렬 경계 상자 B(S)와 p를 분리할 수 있는 경우에만 가능하다.As an example, the separation of point sets S and p using an axis-parallel cut is possible only if the minimum axis-aligned bounding box B(S) and p can be separated using an axis-parallel cut.

또한, RRCF 트리에 대한 구조적 속성을 제공하게 되며, 이는 특정 트리가 주어졌을 때 (i) 삭제될(각각 삽입되는) 새로운 포인트가 첫번째 컷으로 분리되지 않고, (ii) 새로운 포인트가 삭제되는(각각 삽입된) 두 가지 철저한 경우가 있음을 주목하면서 첫번째 컷으로 분리시킨다.It also provides structural properties for the RRCF tree, which, given a particular tree, (i) new points to be deleted (respective insertions) do not separate into the first cut, and (ii) new points are deleted (respectively inserted). Inset) is separated by the first cut, noting that there are two exhaustive cases.

그러면, 상기 (i)와 (ii)를 각각 만족하는 트리(단 하나의 트리가 아님) 컬렉션에 대한 문제를 해결할 수 있으며, 주어진 점 p와 축이 평행한 최소 경계 상자 B(S)가 있는 점 집합 S가 다음과 같이 주어질 수 있다.Then, the problem can be solved for a collection of trees (not just one tree) satisfying the above (i) and (ii), respectively, where there is a minimum bounding box B(S) whose axis is parallel to the given point p. A set S can be given as:

(i) 임의의 차원 i에 대해 weighted isolation forest 알고리즘을 사용하여 S를 분할하는 차원 i에서 축 평행 절단을 선택할 확률은 S를 분할하는 축 평행 절단을 선택할 조건부 확률과 정확히 동일하고, ∪{p} 차원 i에서 S의 모든 점에서 p를 분리하지 않는 것을 조건으로 하는 것이다.(i) Using the weighted isolation forest algorithm for any dimension i, the probability of choosing an axis-parallel cut in dimension i that divides S is exactly equal to the conditional probability of choosing an axis-parallel cut that divides S, ∪{p} It is conditional on not separating p at every point of S in dimension i.

(ii) RRCF(S ∪{p})의 랜덤 트리가 주어지고 첫번째 컷이 S의 모든 점에서 p를 분리한다는 사실에 따라 트리의 나머지 부분은 RRCF(S)의 랜덤 트리이다.(ii) Given a random tree of RRCF(S ∪{p}) and the fact that the first cut separates p at every point in S, the rest of the tree is a random tree of RRCF(S).

1. p가 T로 분리된 트리에서 노드 v를 찾고, u를 v의 형제로 한다.1. Find a node v in a tree where p is separated by T, and let u be a sibling of v.

2. v(및 u)의 부모를 제거하고 부모를 u로 바꾼다(즉, u에서 루트 경로를 단락시킨다).2. Remove the parent of v (and u) and replace the parent with u (i.e. short-circuit the root path from u).

3. (새로운) 부모에서 위쪽으로 모든 경계 상자를 업데이트하며 이 상태는 삭제에는 필요하지 않지만 삽입에 유용할 수 있다.3. Updates all bounding boxes from the (new) parent upwards, this state is not necessary for deletes, but can be useful for inserts.

4. 변경된 트리 T'를 반환한다. 4. Return the modified tree T'.

따라서, 상기 T가 분포 RRCF(S)에서 추출된 경우 알고리즘은 확률 분포 RRC F(S -{p})에서 무작위로 추출된 트리 T를 생성할 수 있고, 삭제 작업은 O(d) 시간에 점 p의 깊이에 수행할 수 있게 되면서, 트리에서 임의의 점을 삭제하면 삭제 작업의 실행 시간은 점의 예상 깊이의 O(d)배인 것이다. 마찬가지로 트리의 대부분의 포인트보다 깊이가 얕은 포인트를 삭제하면 실행 시간을 개선할 수 있는 것이다.Therefore, if the T is extracted from the distribution RRCF(S), the algorithm can generate a tree T randomly extracted from the probability distribution RRC F(S -{p}), and the deletion operation takes O(d) time If you delete an arbitrary point from the tree, the running time of the deletion operation is O(d) times the expected depth of the point. Likewise, deleting points that are shallower than most points in the tree can improve execution time.

본 발명자들은 사용자 입장에서 신뢰있는 이상점수를 얻기 위해서 실행할 때마다 같은 스코어가 나오는 방법을 찾아서 제시하였다. Insertion 알고리즘에서 샘플이 분기할 확률과 분기했을 때 계산되는 CoDISP를 이용해서 기댓값을 구하고 이 결정적인 값을 expected CoDISP 라고 정의하였다.The present inventors have found and suggested a method in which the same score is obtained each time it is executed in order to obtain a reliable ideal score from the user's point of view. In the insertion algorithm, the expected value is obtained using the probability that the sample diverges and CoDISP calculated when it diverges, and this decisive value is defined as expected CoDISP.

(5) Test results(5) Test results

RRCF 속도와 모델 사이즈가 개선된 정도를 확인하기 위해서 도 9에서 보여주는 환경에서 테스트를 진행하였다.In order to confirm the degree of improvement in the RRCF speed and model size, a test was conducted in the environment shown in FIG. 9 .

속도 개선: 데이터는 생산 과정에서 수집된 10k 진동 데이터로 학습 데이터의 개수는 128개이다. 랜덤 트리의 개수도 128, 256, 512 개 등 다양하게 테스트를 진행했다. 결과적으로 개선된 모델은 기존 대비 7.5배 정도 빨라졌다. 추가로 Feature sampling 을 적용하게 되면 작아진 데이터 크기로 인해서 더 (선형적으로) 감소할 것으로 기대된다.Speed improvement: The data is 10k vibration data collected during the production process, and the number of training data is 128. The number of random trees was also tested in various ways, such as 128, 256, and 512. As a result, the improved model is about 7.5 times faster than the previous one. If additional feature sampling is applied, it is expected to decrease more (linearly) due to the smaller data size.

모델 크기 개선: 데이터는 CNC 512차원 전류 데이터로 학습 데이터의 개수는 128개이다. Feature sampling 을 적용해서 트리를 생성하게 되면 위에서 설명한 것처럼 internal node에 저장해야 하는 데이터의 개수가 줄어든 feature 만큼 감소하게 된다. 512개 feature를 모두 사용한 모델과 64개 feature만 사용한 모델은 8배 정도 선형적으로 감소하는 것을 도 10에서 확인할 수 있다.Model size improvement: The data is CNC 512-dimensional current data, and the number of training data is 128. When a tree is created by applying feature sampling, as described above, the number of data to be stored in the internal node is reduced by the reduced feature. It can be seen in FIG. 10 that the model using all 512 features and the model using only 64 features decrease linearly by about 8 times.

(6) Effect on Feature sampling (6) Effect on Feature sampling

RRCF 속도와 모델 크기 개선의 결과는 앞에서 소개하였으며, 이하에서는 본 발명에서 제시한 Feature sampling 으로 정확도 개선되는 결과를 소개하고자 한다. The results of improving the RRCF speed and model size were introduced above, and below, we will introduce the results of improving the accuracy with the feature sampling presented in the present invention.

RRCF에서 트리를 생성할 때 min- max range에 비례해서 feature를 선택하기 때문에 스케일이 작은 곳에 존재하는 이상은 감지하기가 어려운데 가상의 데이터로 Feature sampling 방법을 쓰면 이 문제를 해결하는 것을 확인 할 수 있다. 정상 라벨 데이터는 100차원으로 다음과 같은 분포를 따른다.When creating a tree in RRCF, features are selected in proportion to the min-max range, so it is difficult to detect anomalies that exist in small scale areas. Using the feature sampling method with virtual data can confirm that this problem is solved. . Normal label data follows the following distribution with 100 dimensions.

(식).... (Unif (0, 10) Х 95, Unif (0, 1) Х 5)(Expression).... (Unif (0, 10) Х 95, Unif (0, 1) Х 5)

그리고 불량 라벨 데이터는 다음과 같은 분포를 따른다.And the bad label data follow the following distribution.

(식).... (Unif (0, 10) Х 95, Unif (1, 2) Х 5)(Formula).... (Unif (0, 10) Х 95, Unif (1, 2) Х 5)

데이터의 특징은 앞에 95차원은 min-max range가 10으로 뒤에 5차원보다는 크다. 그리고 정상과 불량의 차이는 뒤에 스케일이 작은 차원에서 발생한다. 모든 차원을 사용한 RRCF 모델은 min-max range가 큰 앞에 95차원만 선택하기 때문에 뒤에 5차원에서 발생하는 불량은 감지하지 못하게 된다. 이 가상 데이터를 Feature sampling 안한 것(왼쪽)과 4개 feature로 적용한 결과는 다음과 같다.The characteristic of the data is that the min-max range of the first 95 dimensions is 10, which is larger than that of the next 5 dimensions. And the difference between normal and defective occurs later in a dimension with a small scale. Since the RRCF model using all dimensions selects only the 95th dimension before the min-max range is large, defects occurring in the 5th dimension at the end cannot be detected. The result of applying this virtual data without feature sampling (left) and four features is as follows.

(7) RRCF performance(7) RRCF performance

기존의 RRCF와 개선한 RRCF 알고리즘과의 스코어 비교 및 개선한 RRCF와 IF의 OCC 문제 성능 비교는 별첨 코드로 첨부하였다.The score comparison between the existing RRCF and the improved RRCF algorithm and the OCC problem performance comparison between the improved RRCF and IF are attached as attached codes.

compare robust random cut forest (Original RRCF 와 이상 스코어 비교)compare robust random cut forest (original RRCF and abnormal score comparison)

plot robust random_cut forest (Isolation forest 와 OCC 문제 성능 비교)plot robust random_cut forest (Isolation forest and OCC problem performance comparison)

(8) Reference (8) Reference

[1] S. Guha, N. Mishra, G. Roy, & O. Schrijvers, Robust random cut forest based anomaly detection on streams, in Proceedings of the 33rd International conference on machine learning, New York, NY, 2016 (pp. 2712-2721). [1] S. Guha, N. Mishra, G. Roy, & O. Schrijvers, Robust random cut forest based anomaly detection on streams, in Proceedings of the 33rd International conference on machine learning, New York, NY, 2016 (pp. 2712-2721).

[2] Liu, Fei Tony, Ting, Kai Ming, and Zhou, Zhi-Hua. Isolation-based anomaly detection, ACM Trans. Knowl. Discov. Data, 6(1):3:1-3:39, March 2012.[2] Liu, Fei Tony, Ting, Kai Ming, and Zhou, Zhi-Hua. Isolation-based anomaly detection, ACM Trans. Knowl. Discov. Data, 6(1):3:1-3:39, March 2012.

[3] Liu, F. T., Ting, K. M., and Zhou, Z.-H. 2008a. Isolation Forest. In ICDM '08: Proceedings of the 2008 Eighth IEEE International Conference on Data Mining. IEEE Computer Society, 413-422. [3] Liu, F. T., Ting, K. M., and Zhou, Z.-H. 2008a. Isolation Forest. In ICDM '08: Proceedings of the 2008 Eighth IEEE International Conference on Data Mining. IEEE Computer Society, 413-422.

이상에서 본 발명의 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템과 그 방법에 대한 기술사상을 첨부도면과 함께 서술하였지만, 이는 본 발명의 가장 바람직한 실시예를 예시적으로 설명한 것이지 본 발명을 한정하는 것은 아니다. In the above, the AI-based equipment data anomaly detection system using the random cut forest algorithm of the present invention and the technical idea of the method have been described together with the accompanying drawings, but this is an illustrative example of the most preferred embodiment of the present invention. does not limit

본 발명은 상술한 특정의 실시예에 한정되지 아니하며, 청구범위에서 청구하는 본 발명의 요지를 벗어남이 없이 당해 발명이 속하는 기술분야에서 통상의 지식을 가진 자라면 누구든지 다양한 변형 실시가 가능한 것은 물론이고, 그와같은 변경은 청구범위 기재의 범위내에 있게 된다.The present invention is not limited to the specific embodiments described above, and various modifications can be implemented by anyone having ordinary knowledge in the art to which the present invention belongs without departing from the gist of the present invention claimed in the claims. and such changes are within the scope of the claims.

10; AI 기반의 고장진단 스마트 센서
20; 설비 고장진단 모니터링부
30; 관리자 분석 처리부
40; 클라우드 서버
41; 데이터 베이스
42; 빅데이터 베이스
10; AI-based fault diagnosis smart sensor
20; Facility fault diagnosis monitoring department
30; manager analysis processing unit
40; cloud server
41; database
42; big data base

Claims (11)

설비에 대한 고장을 진단하는 것으로 AI 기반의 고장진단 스마트 센서;
상기 AI 기반의 고장진단 스마트 센서에 의해 진단된 결과를 모니터링하는 설비 고장진단 모니터링부; 및,
상기 설비 고장진단 모니터링부에 의해 모니터링된 결과를 분석하도록 확률기반의 계산 방식을 적용한 랜덤 컷 포레스트 알고리즘(IRCF; Improve Random Cut Forest)을 가지는 관리자 분석 처리부; 를 포함하는 것을 특징으로 하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템.
AI-based fault diagnosis smart sensor for diagnosing faults in facilities;
a facility fault diagnosis monitoring unit that monitors a result diagnosed by the AI-based fault diagnosis smart sensor; and,
a manager analysis processing unit having a random cut forest algorithm (IRCF; Improve Random Cut Forest) to which a probability-based calculation method is applied to analyze the result monitored by the equipment failure diagnosis monitoring unit; An AI-based facility data anomaly detection system using a random cut forest algorithm, characterized in that it comprises a.
제 1 항에 있어서,
상기 AI 기반의 고장진단 스마트 센서와 상기 설비 고장진단 모니터링부는 클라우드 서버를 통해 통신 연결되는 것을 특징으로 하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템.
According to claim 1,
AI-based facility data anomaly detection system using a random cut forest algorithm, characterized in that the AI-based fault diagnosis smart sensor and the facility fault diagnosis monitoring unit are communicatively connected through a cloud server.
제 2 항에 있어서,
상기 클라우드 서버에는 분할된 데이터 베이스와 빅데이터 베이스가 연결되는 것을 특징으로 하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 시스템.
According to claim 2,
An AI-based facility data anomaly detection system using a random cut forest algorithm, characterized in that the divided database and the big data base are connected to the cloud server.
이상감지를 위한 학습 모델을 생성하는 단계; 및,
상기 생성하는 단계로부터 생성되는 학습모델로부터 이상점수를 예측하는 이상점수 예측 및 운영단계; 를 포함하는 것을 특징으로 하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법.
generating a learning model for anomaly detection; and,
an anomaly score prediction and operation step of predicting an ideal score from the learning model generated in the generating step; AI-based facility data anomaly detection method using a random cut forest algorithm, characterized in that it comprises a.
제 4 항에 있어서,
상기 학습 모델을 생성하는 단계는,
설비에 설치되는 AI 기반의 고장진단 스마트 센서로부터 수집된 데이터를 전처리하는 단계;
상기 전처리하는 단계로부터 전처리된 데이터를 저장하는 단계;
상기 저장하는 단계로부터 저장된 전처리 데이터에서 램덤 트리를 구성하여 정상 데이터 기반의 학습 모델을 생성하는 단계; 및,
상기 생성하는 단계로부터 생성된 학습 모델을 저장하는 단계; 를 포함하는 것을 특징으로 하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법.
According to claim 4,
The step of generating the learning model is,
Pre-processing the data collected from the AI-based fault diagnosis smart sensor installed in the facility;
Storing preprocessed data from the preprocessing step;
generating a learning model based on normal data by constructing a random tree from the preprocessed data stored in the storing step; and,
storing the learning model generated from the generating step; AI-based facility data anomaly detection method using a random cut forest algorithm, characterized in that it comprises a.
제 5 항에 있어서,
상기 이상점수 예측 및 운영단계는,
설비에 설치되는 AI 기반의 고장진단 스마트 센서로부터 데이터를 수집하여 전처리하는 단계;
상기 저장하는 단계로부터 저장된 학습모델을 기반으로 랜덤 컷 포레스트 알고리즘(IRCF)를 이용하여 측정하고자 하는 데이터로서 이상점수(Optimize calculation of CoDISP)를 계산하는 계산하는 단계; 및,
상기 계산하는 단계로부터 계산된 이상점수가 높으면 설비 알람을 발생시키는 단계; 를 포함하는 것을 특징으로 하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법.
According to claim 5,
The ideal score prediction and operation step,
Collecting and pre-processing data from AI-based fault diagnosis smart sensors installed in facilities;
Calculating an ideal score (Optimize calculation of CoDISP) as data to be measured using a random cut forest algorithm (IRCF) based on the learning model stored from the storing step; and,
generating a facility alarm when the ideal score calculated from the calculating step is high; AI-based facility data anomaly detection method using a random cut forest algorithm, characterized in that it comprises a.
제 6 항에 있어서,
상기 랜덤 컷 포레스트 알고리즘(IRCF)은 동적 트리를 가지고 있지 않으면서 동적인 학습모델을 이용하여 이상점수를 예측하는 확률기반의 계산 방식이 적용되는 것을 특징으로 하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법.
According to claim 6,
The random cut forest algorithm (IRCF) is an AI-based facility using a random cut forest algorithm, characterized in that a probability-based calculation method for predicting anomaly scores using a dynamic learning model without having a dynamic tree is applied. How to detect data anomalies.
정상적인 학습 데이터(X)
Figure pat00019
- (1) 이고,
상기 학습 데이터(X) 집합에서 n(≤N)을 무작위 선택하면,
Figure pat00020
- (2) 이며,
상기 X1을 기반으로 RRC Tree를 생성하는 트리 생성 단계;
데이터 추가 및 변형 트리 생성 단계;
이상점수(CoDISP)를 계산한 후, 데이터를 제거하는 단계; 및
상기 과정을 반복 수행하여, 상기 이상점수(CoDISP)의 평균으로 이상 점수를 새롭게 얻게 되는 이상점수 수득 단계; 를 포함하는 것을 특징으로 하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법.
Normal training data (X)
Figure pat00019
- (1) is,
If n (≤N) is randomly selected from the set of learning data (X),
Figure pat00020
- is (2),
A tree creation step of generating an RRC Tree based on the X1;
adding data and creating a transformation tree;
removing data after calculating an outlier score (CoDISP); and
Obtaining an ideal score by repeating the above process to obtain a new ideal score based on the average of the ideal scores (CoDISP); AI-based facility data anomaly detection method using a random cut forest algorithm, characterized in that it comprises a.
제 8 항에 있어서,
상기 트리 생성 단계는, 트리 생성시 데이터의 샘플링과 함께 특징 샘플링(feature sampling)을 도입하면서, 트리의 사이즈 감소 및 속도를 개선하고, 스케일이 작은 데이터의 이상 감지 효과를 증가시킬 수 있도록 하는 것을 특징으로 하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법.
According to claim 8,
The tree generation step introduces feature sampling along with data sampling during tree generation, reducing the size and speed of the tree, and increasing the anomaly detection effect of small-scale data. An AI-based equipment data anomaly detection method using a random cut forest algorithm.
제 8 항에 있어서,
상기 변형 트리 생성 단계는, 변형된 트리를 생성하지 않고 추가함으로써, 데이터의 이상점수(CoDISP) 만을 연산하여 빠른 속도를 기대할 수 있도록 하는 것을 특징으로 하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법.
According to claim 8,
In the transformation tree generation step, AI-based equipment data anomalies using a random cut forest algorithm, characterized in that by adding a deformed tree without generating it, only the outlier score (CoDISP) of the data is calculated so that a high speed can be expected. detection method.
제 8 항에 있어서,
상기 이상점수 수득 단계는, 상기 이상점수(CoDISP)는 확률적으로 얻는 값이기 때문에 매번 달라지는 상기 이상점수(CoDISP) 값을 고정시키기 위해 상기 이상점수(CoDISP)의 확률적 기대값을 결과값으로 사용하는 것을 특징으로 하는 랜덤 컷 포레스트 알고리즘을 이용한 AI 기반의 설비 데이터 이상 감지 방법.
According to claim 8,
In the step of obtaining the ideal score, since the ideal score CoDISP is a value obtained probabilistically, a stochastic expected value of the ideal score CoDISP is used as a result value to fix the value of the ideal score CoDISP, which changes each time. An AI-based facility data anomaly detection method using a random cut forest algorithm, characterized in that.
KR1020220105115A 2021-08-25 2022-08-22 AI-based facility data anomaly detection system and method using random cut forest algorithm KR20230030542A (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
KR20210112175 2021-08-25
KR1020210112175 2021-08-25

Publications (1)

Publication Number Publication Date
KR20230030542A true KR20230030542A (en) 2023-03-06

Family

ID=85509801

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020220105115A KR20230030542A (en) 2021-08-25 2022-08-22 AI-based facility data anomaly detection system and method using random cut forest algorithm

Country Status (1)

Country Link
KR (1) KR20230030542A (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116414097A (en) * 2023-05-15 2023-07-11 广东思创智联科技股份有限公司 Alarm management method and system based on industrial equipment data
CN116882790A (en) * 2023-09-06 2023-10-13 北京建工环境修复股份有限公司 Carbon emission equipment management method and system for mine ecological restoration area
CN117148117A (en) * 2023-10-27 2023-12-01 中诚华隆计算机技术有限公司 Chiplet fault automatic detection and repair method and system
CN117194920A (en) * 2023-09-06 2023-12-08 万仁企业管理技术(深圳)有限公司 Data system processing platform and processing method based on big data analysis
CN117238058A (en) * 2023-11-10 2023-12-15 无锡明诚汽车部件有限公司 Starter monitoring method for automobile based on data analysis
CN117574307A (en) * 2024-01-17 2024-02-20 广东云百科技有限公司 Security management system and method for data of Internet of things
CN117574307B (en) * 2024-01-17 2024-05-17 广东云百科技有限公司 Security management system and method for data of Internet of things

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100579083B1 (en) 2002-12-30 2006-05-12 두산인프라코어 주식회사 A Tool Error Detecting Unit of CNC and Method Thereof
KR20080070543A (en) 2007-01-26 2008-07-30 주식회사 신영 Early warning method for estimating inferiority in automatic production line
KR101611299B1 (en) 2015-11-17 2016-04-11 (주)동현테크노 Trouble detecting method for automatic machine
KR101776956B1 (en) 2010-12-09 2017-09-19 두산공작기계 주식회사 Tool Damage Detection Apparatus For Machine Tool and Detection Method Thereby

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100579083B1 (en) 2002-12-30 2006-05-12 두산인프라코어 주식회사 A Tool Error Detecting Unit of CNC and Method Thereof
KR20080070543A (en) 2007-01-26 2008-07-30 주식회사 신영 Early warning method for estimating inferiority in automatic production line
KR101776956B1 (en) 2010-12-09 2017-09-19 두산공작기계 주식회사 Tool Damage Detection Apparatus For Machine Tool and Detection Method Thereby
KR101611299B1 (en) 2015-11-17 2016-04-11 (주)동현테크노 Trouble detecting method for automatic machine

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116414097A (en) * 2023-05-15 2023-07-11 广东思创智联科技股份有限公司 Alarm management method and system based on industrial equipment data
CN116882790A (en) * 2023-09-06 2023-10-13 北京建工环境修复股份有限公司 Carbon emission equipment management method and system for mine ecological restoration area
CN116882790B (en) * 2023-09-06 2023-11-21 北京建工环境修复股份有限公司 Carbon emission equipment management method and system for mine ecological restoration area
CN117194920A (en) * 2023-09-06 2023-12-08 万仁企业管理技术(深圳)有限公司 Data system processing platform and processing method based on big data analysis
CN117148117A (en) * 2023-10-27 2023-12-01 中诚华隆计算机技术有限公司 Chiplet fault automatic detection and repair method and system
CN117148117B (en) * 2023-10-27 2023-12-29 中诚华隆计算机技术有限公司 Chiplet fault automatic detection and repair method and system
CN117238058A (en) * 2023-11-10 2023-12-15 无锡明诚汽车部件有限公司 Starter monitoring method for automobile based on data analysis
CN117238058B (en) * 2023-11-10 2024-01-26 无锡明诚汽车部件有限公司 Starter monitoring method for automobile based on data analysis
CN117574307A (en) * 2024-01-17 2024-02-20 广东云百科技有限公司 Security management system and method for data of Internet of things
CN117574307B (en) * 2024-01-17 2024-05-17 广东云百科技有限公司 Security management system and method for data of Internet of things

Similar Documents

Publication Publication Date Title
KR102118670B1 (en) System and method for management of ict infra
KR20230030542A (en) AI-based facility data anomaly detection system and method using random cut forest algorithm
Hayes et al. Contextual anomaly detection in big sensor data
Pavlovski et al. Hierarchical convolutional neural networks for event classification on PMU measurements
Homayouni et al. An autocorrelation-based LSTM-autoencoder for anomaly detection on time-series data
Dou et al. Pc 2 a: predicting collective contextual anomalies via lstm with deep generative model
US11675643B2 (en) Method and device for determining a technical incident risk value in a computing infrastructure from performance indicator values
CN111539493A (en) Alarm prediction method and device, electronic equipment and storage medium
Cózar et al. An application of dynamic Bayesian networks to condition monitoring and fault prediction in a sensored system: A case study
Gonzalez et al. Automated characterization of software vulnerabilities
Hai et al. Transfer learning for event detection from PMU measurements with scarce labels
Atzmueller et al. Anomaly detection and structural analysis in industrial production environments
Pal et al. DLME: distributed log mining using ensemble learning for fault prediction
Tripathy et al. Explaining Anomalies in Industrial Multivariate Time-series Data with the help of eXplainable AI
Dakheel et al. Intrusion detection system in gas-pipeline industry using machine learning
Zhang et al. Putracead: Trace anomaly detection with partial labels based on gnn and pu learning
Singh et al. User behaviour based insider threat detection in critical infrastructures
CN115495274B (en) Exception handling method based on time sequence data, network equipment and readable storage medium
GB2465860A (en) A directed graph behaviour model for monitoring a computer system in which each node of the graph represents an event generated by an application
Gannarapu et al. Bot detection using machine learning algorithms on social media platforms
Merkt Predictive models for maintenance optimization: an analytical literature survey of industrial maintenance strategies
Chakraborty et al. ESRO: Experience Assisted Service Reliability against Outages
Mansouri et al. Explainable fault prediction using learning fuzzy cognitive maps
Patil et al. Framework for performance comparison of classifiers
Gao et al. Aggregating data sampling with feature subset selection to address skewed software defect data