KR20230137788A - A multi-class pipeline defect detection, tracking and counting method based on self-attention mechanism - Google Patents

A multi-class pipeline defect detection, tracking and counting method based on self-attention mechanism Download PDF

Info

Publication number
KR20230137788A
KR20230137788A KR1020220066732A KR20220066732A KR20230137788A KR 20230137788 A KR20230137788 A KR 20230137788A KR 1020220066732 A KR1020220066732 A KR 1020220066732A KR 20220066732 A KR20220066732 A KR 20220066732A KR 20230137788 A KR20230137788 A KR 20230137788A
Authority
KR
South Korea
Prior art keywords
defect
tracking
inspection
self
procedure
Prior art date
Application number
KR1020220066732A
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 KR20230137788A publication Critical patent/KR20230137788A/en

Links

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/8851Scan or image signal processing specially adapted therefor, e.g. for scan signal adjustment, for detecting different kinds of defects, for compensating for structures, markings, edges
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/95Investigating the presence of flaws or contamination characterised by the material or shape of the object to be examined
    • G01N21/954Inspecting the inner surface of hollow bodies, e.g. bores
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • G06F18/2415Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches based on parametric or probabilistic models, e.g. based on likelihood ratio or false acceptance rate versus a false rejection rate
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/047Probabilistic or stochastic networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • G06T7/0004Industrial image inspection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/20Analysis of motion
    • G06T7/246Analysis of motion using feature-based methods, e.g. the tracking of corners or segments
    • G06T7/248Analysis of motion using feature-based methods, e.g. the tracking of corners or segments involving reference images or patches
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/70Determining position or orientation of objects or cameras
    • G06T7/73Determining position or orientation of objects or cameras using feature-based methods
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/8851Scan or image signal processing specially adapted therefor, e.g. for scan signal adjustment, for detecting different kinds of defects, for compensating for structures, markings, edges
    • G01N2021/8854Grading and classifying of flaws
    • G01N2021/8858Flaw counting
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/8851Scan or image signal processing specially adapted therefor, e.g. for scan signal adjustment, for detecting different kinds of defects, for compensating for structures, markings, edges
    • G01N2021/8854Grading and classifying of flaws
    • G01N2021/8861Determining coordinates of flaws
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/8851Scan or image signal processing specially adapted therefor, e.g. for scan signal adjustment, for detecting different kinds of defects, for compensating for structures, markings, edges
    • G01N2021/8883Scan or image signal processing specially adapted therefor, e.g. for scan signal adjustment, for detecting different kinds of defects, for compensating for structures, markings, edges involving the calculation of gauges, generating models
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/8851Scan or image signal processing specially adapted therefor, e.g. for scan signal adjustment, for detecting different kinds of defects, for compensating for structures, markings, edges
    • G01N2021/8887Scan or image signal processing specially adapted therefor, e.g. for scan signal adjustment, for detecting different kinds of defects, for compensating for structures, markings, edges based on image processing techniques
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N2201/00Features of devices classified in G01N21/00
    • G01N2201/12Circuits of general importance; Signal processing
    • G01N2201/129Using chemometrical methods
    • G01N2201/1296Using chemometrical methods using neural networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10016Video; Image sequence
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20076Probabilistic image processing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20084Artificial neural networks [ANN]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30108Industrial image inspection
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02ATECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE
    • Y02A10/00TECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE at coastal zones; at river basins
    • Y02A10/40Controlling or monitoring, e.g. of flood or hurricane; Forecasting, e.g. risk assessment or mapping

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Data Mining & Analysis (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Health & Medical Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • General Engineering & Computer Science (AREA)
  • Evolutionary Computation (AREA)
  • Computational Linguistics (AREA)
  • Molecular Biology (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Software Systems (AREA)
  • Mathematical Physics (AREA)
  • Computing Systems (AREA)
  • Analytical Chemistry (AREA)
  • Chemical & Material Sciences (AREA)
  • Biochemistry (AREA)
  • Immunology (AREA)
  • Pathology (AREA)
  • Quality & Reliability (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Probability & Statistics with Applications (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Evolutionary Biology (AREA)
  • Signal Processing (AREA)
  • Multimedia (AREA)
  • Image Analysis (AREA)
  • Image Processing (AREA)

Abstract

본 발명은 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법으로서, 하기 절차를 포함한다. S1. 다양한 유형의 배관 결함 이미지 수집. S2. 배관 결함 이미지 데이터 세트 구축. S3. 배관 결함 검사 모델 구축 및 훈련. S4. 배관 결함 추적 및 계수 모델 구축. S5. 테스트 및 결과 출력. 본 발명은 셀프 어텐션 메커니즘 기반 딥러닝 학습 방법을 바탕으로 배관 결함 특징을 대상으로 한 객체 검사, 추적 또는 계수 알고리즘이다. 배관 결함 빅데이터를 바탕으로 한 모델 훈련으로 견고성과 일반화 능력을 향상시킨다. 본 발명은 기존의 합성곱 신경망 대신 트랜스포머(Transformer) 신경망을 이용함으로써 모델 검사의 정확도를 높이고 배관 결함 자동 인식과 계수 기능을 실현한다.The present invention is an inspection, tracking, and counting method for various types of piping defects based on a self-attention mechanism, and includes the following procedures. S1. Collect images of various types of plumbing defects. S2. Building a pipe defect image dataset. S3. Building and training piping defect inspection models. S4. Building pipe defect tracking and counting models. S5. Testing and output of results. The present invention is an object inspection, tracking, or counting algorithm targeting pipe defect characteristics based on a deep learning learning method based on a self-attention mechanism. Model training based on plumbing defect big data improves robustness and generalization ability. The present invention improves the accuracy of model inspection and realizes automatic recognition and counting of piping defects by using a transformer neural network instead of the existing convolutional neural network.

Description

셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법{A multi-class pipeline defect detection, tracking and counting method based on self-attention mechanism}Inspection, tracking and counting method for various types of pipeline defects based on self-attention mechanism {A multi-class pipeline defect detection, tracking and counting method based on self-attention mechanism}

본 발명은 배관 결함 검사 기술에 관한 것으로, 셀프 어텐션 메커니즘 기반 다양한 배관 결함에 대한 검사, 추적 및 계수 방법에 관한 것이다.The present invention relates to piping defect inspection technology, and to a method for inspecting, tracking, and counting various piping defects based on a self-attention mechanism.

배수관은 도시의 생명선으로서 집수, 물빼기 또는 배수의 기능을 가진다. 최근 몇 년간에 지반 불균형으로 인한 침강, 미생물 부식, 오염물 침적 등의 현상이 발생하기 때문에 여러 가지의 배관 결함 문제가 생겼다. 배수관 내부 표면에서 누수와 접합 오류로 인해 오염이 발생해서 주변의 물과 토양에 영향을 마치게 된다. 이는 국민의 건강에 해롭다. 물이 새기 때문에 주변의 토양이 유실되고 도로가 붕괴되는 문제가 발생한다. 이런 문제는 사람들의 여행 안전에 나쁜 영향을 미치게 된다. 배수관 내부 공간에 장애물이나 나무뿌리가 있어서 배관을 막혀서 배수능력이 약해진다. 이 때문에 도시 침수의 문제가 발생된다. 따라서 배관 결함 검사와 수량 통계를 정기적으로 진행하고 예방 조치를 취해야 한다. 이를 통해 배관 손상 정도를 판단하고 결함에 대한 정확한 수리 방법을 취해야 한다.Drain pipes are the lifeline of a city and have the function of water collection, drainage, or drainage. In recent years, various piping defect problems have arisen due to phenomena such as subsidence, microbial corrosion, and contaminant deposition due to ground imbalance. Leaks and joint failures on the internal surfaces of drain pipes can cause contamination, affecting the surrounding water and soil. This is harmful to people's health. Water leaks cause surrounding soil to be lost and roads to collapse. These problems have a negative impact on people's travel safety. If there are obstacles or tree roots in the space inside the drain pipe, the pipe will be blocked and the drainage ability will be weakened. This causes the problem of urban flooding. Therefore, pipe defect inspection and quantity statistics should be conducted regularly and preventive measures should be taken. Through this, the extent of pipe damage must be determined and an accurate repair method for the defect must be taken.

기존 배수관 검사는 폐회로 텔레비전 카메라 또는 잠망경 등의 시각 검사 기술을 위주로 하며 수동 식별을 진행한다. 다만 수동 식별에 시간이 많이 필요하고 평가가 주관적이고 검사를 누락하거나 잘못하는 문제가 생길 수 있어서 검사의 정확성가 떨어진다.Existing drain pipe inspections focus on visual inspection techniques such as closed-circuit television cameras or periscopes and involve manual identification. However, manual identification requires a lot of time, the evaluation is subjective, and problems of missing or incorrect testing may occur, which reduces the accuracy of the test.

기존의 배수관 결함 검사 방법은 경험 기반 인공 작업자 또는 데이터 기반 자율 학습 알고리즘에 의존하다. 전통적인 알고리즘은 세 가지로 나눌 수 있다. 첫 번째, 배관 결함의 그레이 레벨은 배경보다 낮다. 예를 들면 기울기 방향 히스토그램과 역치법 등이 있다. 두 번째, 균열 가장자리 그레이 레벨 수치 변화가 크다. 예를 들면, 인공 에지 검사 연산자와 이산 웨이블릿 변환 알고리증 등이 있다. 세 번째, 배관 결함이 통계와 회귀를 통해 얻을 수 있는 동일 특징을 갖는다. 예를 들면, 서포트 벡터머신, 인공신경망, 랜덤포레스트 등이 있다. 전통적인 알고리즘은 특징추출기 또는 분류기로서 종속적으로 이용할 수 있으며 우수한 결과를 얻을 수 있다. 하지만 배수관 내부 환경이 복잡하며 결함 유형이 다양하다. 기존 알고리즘이 소량의 특징만 추출하기 때문에 배수관 검사의 정확성과 견고성 요구에 만족시킬 수 없다.Existing drain pipe defect inspection methods rely on experience-based artificial workers or data-based unsupervised learning algorithms. Traditional algorithms can be divided into three types. First, the gray level of the plumbing defects is lower than the background. For example, there are gradient histograms and threshold methods. Second, there is a large change in the gray level value at the edge of the crack. Examples include artificial edge checking operators and discrete wavelet transform algorithms. Third, plumbing defects have the same characteristics that can be obtained through statistics and regression. For example, there are support vector machines, artificial neural networks, random forests, etc. Traditional algorithms can be used independently as feature extractors or classifiers and can achieve excellent results. However, the internal environment of the drain pipe is complex and the types of defects are diverse. Because existing algorithms extract only a small amount of features, they cannot satisfy the requirements for accuracy and robustness in drain pipe inspection.

CN202110737415.7 특허번호인 특허 문헌은 딥러닝을 기반으로 한 배수관 결함 검사 방법과 시스템이 개시되어 있다. 이 방법은 sinGAN을 통해 원본 결함 이미지에 대한 데이터 세트 확정 처리를 진행하고 GA-RPN 알고리즘을 사용하여 앵커프레임이 생성된다. 마지막으로 신경망을 활용함으로써 배관 결함 이미지에 대한 검사와 분할 처리를 진행한다. 이 방법은 배관 결함의 구체적인 위치 좌표를 얻게 되지만 영상의 연속 프레임에서 동일한 결함에 대하여 중복 계산하는 문제가 발생할 가능성이 있다. 따라서 기존의 데이터 보강으로 생성된 이미지의 높은 연관성 문제를 고려할 때, 결함 검사 정확성을 높이는 방법이 필요하다.The patent document, patent number CN202110737415.7, discloses a method and system for inspecting drain pipe defects based on deep learning. This method processes the data set for the original defect image through sinGAN and creates an anchor frame using the GA-RPN algorithm. Lastly, inspection and segmentation processing of pipe defect images are performed using a neural network. This method obtains the specific location coordinates of the pipe defect, but there is a possibility that the problem of double calculation of the same defect in consecutive frames of the image may occur. Therefore, considering the problem of high correlation of images generated by existing data augmentation, a method to increase defect inspection accuracy is needed.

CN202110737415.7CN202110737415.7

기존 기술에 존재한 문제를 해결하기 위하여 본 발명은 셀프 어텐션 메커니즘 기반 여러 가지 배관 결함에 대한 검사, 추적 및 계수방법으로서 생성적 대립 신경망을 기반으로 구축한 배관 결함 데이터베이스, 셀프 어텐션 메커니즘 기반으로 구축한 배관 결함 검사 모델 또는 셀프 어텐션 메커니즘 기반으로 구축한 배관 결함 계수 모델 총 세 가지의 주요 부분으로 구성되어 있다. 이 방법은 기존 검사 알고리즘이 동일한 결함을 대해 중복하게 계산하는 문제를 해결해 주고 셀프 어텐션 메커니즘을 통해 검사 모델을 최적화함으로써 정확도가 높고 일반화 능력을 늘리고 견고성이 좋다는 장점을 가진다. 따라서 상기 배경기술 부분에서 언급한 문제를 해결해 준다.In order to solve the problems existing in existing technology, the present invention is a self-attention mechanism-based inspection, tracking and counting method for various piping defects, a piping defect database built based on a generative adversarial neural network, and a self-attention mechanism. It consists of three main parts: a piping defect inspection model or a piping defect coefficient model built based on a self-attention mechanism. This method solves the problem of existing inspection algorithms repeatedly calculating the same defect and has the advantage of high accuracy, increased generalization ability, and good robustness by optimizing the inspection model through a self-attention mechanism. Therefore, it solves the problem mentioned in the background technology section above.

상기 목적을 달성하기 위하여 본 발명은 셀프 어텐션 메커니즘 기반 여러 유형의 배관 결함에 대한 검사, 추적 및 계수방법과 같은 기술 솔루션을 제공한다. 구체적으로 아래와 같은 절차를 포함하고 있다.To achieve the above object, the present invention provides technical solutions such as inspection, tracking, and counting methods for various types of piping defects based on a self-attention mechanism. Specifically, it includes the following procedures.

S1. 다양한 유형의 배관 결함 이미지 수집;S1. Collect images of various types of plumbing defects;

S2. 배관 결함 이미지 데이터 세트 구축;S2. Building a pipeline defect image dataset;

S3. 배관 결함 검사 모델 구축 및 훈련;S3. Building and training piping defect inspection models;

S4. 배관 결함 추적 및 계수모델 구축;S4. Piping defect tracking and counting model construction;

S5. 테스트 및 결과 출력.S5. Testing and output of results.

바람직하게는, 상기 절차 S1인 다양한 유형의 배관 결함 이미지 수집은 아래와 같은 세부 절차를 포함하고 있다:Preferably, the image collection of various types of pipe defects, which is procedure S1, includes the following detailed procedures:

S11. 배관 크롤링 로봇을 통해 배관 내 표면 결함 이미지 또는 영상수집;S11. Collecting images or videos of surface defects in pipes through pipe crawling robots;

S12. 원본 이미지에 대한 전처리를 진행하며, 영상을 프레임 이미지로 분할하고, 모든 이미지의 해상도가 256×256으로 통일하고, jpg 포맷으로 저장된다;S12. Preprocessing of the original image is performed, the video is divided into frame images, the resolution of all images is unified to 256 × 256, and saved in jpg format;

S13. 한 가지 또는 여러 가지의 결함을 포함한 이미지를 선정한다.S13. Select an image that contains one or more defects.

바람직하게는, 상기 절차 S2인 배관 결함 이미지 데이터 세트 구축은 아래와 같은 세부 절차를 포함한다:Preferably, the construction of the pipe defect image data set, which is procedure S2, includes the following detailed procedures:

S21. 절차 S1을 통해 배관 결함 이미지를 접합 오류, 파열, 장애물 총 3가지의 결함 유형별로 분류한다;S21. Through procedure S1, pipe defect images are classified into three defect types: joint failure, rupture, and obstruction;

S22. 생성적대립신경망 GAN을 구축한다. GAN 신경망은 생성기와 감별기로 구성된다. 생성기는 랜덤적으로 잡음을 접수하고 새로운 이미지를 생성한다. 감별기는 진실한 이미지인지 판단하는 것이다. 배관 결함 유형에 따라 훈련을 실시한다. 총 3가지의 이미지의 생성 모델을 구축하고 이미지가 생성되고 jpg 포맷으로 저장된다.S22. Construct a generative adversarial network (GAN). A GAN neural network consists of a generator and a discriminator. The generator randomly receives noise and creates a new image. The discriminator is to determine whether the image is true. Conduct training according to the type of piping defect. A total of three image generation models are built, and the images are created and saved in jpg format.

S23. 원시 이미지와 생성 이미지는 같은 파일에 통합하고 이미지 순서대로 리네임을 진행한다.S23. Raw images and generated images are integrated into the same file and renamed in image order.

S24. 표시 이미지 배경 구역의 픽셀은 0으로 하며, 접합 오류 구역의 픽셀은 1로 되며, 파열 구역의 픽셀은 2로 되며, 장애물 구역의 픽셀은 3으로 되며 xml 포맷으로 저장된다.S24. The pixels in the display image background area are set to 0, the pixels in the splicing error area are set to 1, the pixels in the rupture area are set to 2, and the pixels in the obstacle area are set to 3, and are saved in xml format.

S25. 보정된 jpg 포맷의 이미지와 생성된 xml 포맷의 표시 정보를 결합함으로써 배관 결함 이미지 데이터베이스를 구축한다.S25. A pipe defect image database is constructed by combining the corrected jpg format images and the generated xml format display information.

S26. 절차 S25에 따른 이미지 데이터베이스는 랜덤적으로 6:2:2의 비율로 훈련 세트, 검증 세트와 시험 세트로 나누게 된다.S26. The image database according to procedure S25 is randomly divided into a training set, validation set, and test set at a ratio of 6:2:2.

바람직하게는, 상기 절차 S3에 언급한 배관 결함 검사 모델 구축 및 훈련은 하기 세부 절차를 포함한다. 셀프 어텐션 메커니즘 기반 배관 결함 검사 모델을 구축하고 전이 학습 방법을 사용하여 모델 초기화를 진행하고 훈련 세트 데이터를 훈련 모델에 입력하고 모델 훈련 과정에서 기록한 손실치와 정확률을 비교하고 최적 하이퍼파라미터를 찾아야 한다. 검증 세트의 데이터를 모델에 입력하고 검증을 진행하여, 검증된 예상치에 도달한 후에 모델을 저장한다.Preferably, building and training the pipe defect inspection model mentioned in Procedure S3 above includes the following detailed procedures. You must build a plumbing defect inspection model based on a self-attention mechanism, initialize the model using a transfer learning method, input training set data into the training model, compare the loss values and accuracy rates recorded during the model training process, and find the optimal hyperparameters. Data from the verification set are input into the model, verification is performed, and the model is saved after reaching the verified prediction.

바람직하게는, 원하는 최적 하이퍼파라미터가 하기 조건에 만족시켜야 한다. 다른 하이퍼파라미터를 설정할 때 훈련 과정에서 정확율 상승곡선의 최대치와 손실치 하강곡선의 안정성과 수렴성을 비교해야 한다. 상기 검증 예상치는 모델의 정확성이 88.860%에 도달하며 손실 곡선에 완화할 추세를 보인다. 상기 최적 하이퍼파리미터는 초기 학습율이 0.00001이며, 매번 반복된 이미지 배치 수량이 2로 되며, 가중 감쇠치가 0.0005로 되며 총 61번의 순환이 반복된다.Preferably, the desired optimal hyperparameters should satisfy the following conditions. When setting other hyperparameters, the stability and convergence of the maximum accuracy rate increase curve and the loss value decrease curve must be compared during the training process. The above verification estimate shows that the model's accuracy reaches 88.860% and the loss curve shows a easing trend. The optimal hyperparameter has an initial learning rate of 0.00001, the number of image batches repeated each time is 2, the weighted attenuation value is 0.0005, and the cycle is repeated a total of 61 times.

바람직하게는, 상기 셀프 어텐션 메커니즘이 서열 간의 상호작용을 계산함으로써 현 예상치에 관한 어텐션 가중치를 얻게 된다. 구체적인 과정이 아래와 같다. 우선 원본 이미지는 9개의 2차원 블록으로 분할하고 2차원 블록을 벡터화 처리로 셀프 어텐션 모델을 얻게 된다. 이는 1차원 유효계열(x1,x2,x3,...,x9) 접수가 가능하다. 완전 연결 계층을 통해 1차원 계열을 고정 길이의 내용 벡터로 전환한다. 블록마다 위치 코딩 정보를 추가하고 내용 벡터를 삽입하고 시맨틱계열(z1,z2,z3, ,,, ,z9)을 얻어서 마지막으로 어텐션 가중치를 얻게 된다.Preferably, the self-attention mechanism computes interactions between sequences to obtain attention weights relative to current expectations. The specific process is as follows. First, the original image is divided into nine 2-dimensional blocks, and the 2-dimensional blocks are vectorized to obtain a self-attention model. This can be accepted as a one-dimensional valid series (x 1 , x 2 , x 3 ,..., x 9 ). Converts one-dimensional series into fixed-length content vectors through a fully connected layer. Position coding information is added to each block, content vectors are inserted, semantic series (z 1 , z 2 , z 3 , ,,, , z 9 ) are obtained, and finally attention weights are obtained.

상기 셀프 어텐션 메커니즘은 조회벡터, 키벡터와 값벡터를 포함하고 있다. 상기 조회벡터가 전항 출력 yi -1이며, 상기 키벡터가 입력값 xi가 출력값 yi의 중요한 정도에 영향을 미치며, 상기 값벡터가 각 입력값 xi의 크기를 표현한다. 키벡터와 조회벡터가 곱한 값을 바탕으로 소프트맥스(Softmax) 함수로 가중벡터 ai를 얻게 된다. 이는 출력치 yi를 예측하는 과정에서 입력 벡터의 어텐션 정도를 뜻한다.The self-attention mechanism includes a lookup vector, a key vector, and a value vector. The lookup vector is the preceding output y i -1 , the key vector influences the importance of the input value x i to the output value y i , and the value vector expresses the size of each input value x i . Based on the value multiplied by the key vector and the lookup vector, the weight vector a i is obtained using the Softmax function. This means the degree of attention of the input vector in the process of predicting the output value y i .

바람직하게는, 상기 절차 S4에 따른 배관 결함 추적 및 계수 모델 구축은 추적 네트워크에 셀프 어텐션 메커니즘을 추가하고 배관 결함 이미지 데이터베이스로 이 신경망을 훈련시킨다. 셀프 어텐션 메커니즘 기반 배관 추적 및 계수 모델을 구축한다. 특정 유형의 배관 결함을 탐지하게 되면 추적 알고리즘을 활용함으로써 결함이 사라질 때까지 추적될 예정이다. 해당 결함 계수 수량에 1을 더하는 것이다. 구체적인 과정이 아래와 같다:Preferably, building a pipe defect tracking and counting model according to procedure S4 above adds a self-attention mechanism to the tracking network and trains this neural network with a pipe defect image database. We build a piping tracking and counting model based on a self-attention mechanism. Once a specific type of pipe defect is detected, it will be tracked using a tracking algorithm until the defect disappears. Add 1 to the corresponding defect coefficient quantity. The specific process is as follows:

S41. 배관 영상 계열을 모델에 입력하고 배관 결함 검사 모델로 첫 프레임의 결함을 탐지하고 초기 경계 박스를 정하고 결함 수량에 1을 중가시킨다;S41. The pipe image series is input into the model, and the pipe defect inspection model detects defects in the first frame, sets the initial bounding box, and adds 1 to the defect quantity;

S42. 배관 결함 추적 네트워크에서 추적 알고리즘이 탐지된 결함이 사라질 때까지 계속 추적한다;S42. In a pipe defect tracking network, the tracking algorithm continues tracking the detected defect until it disappears;

S43. 추적된 결함이 프레임 계열에서 사라진 후에 다음 결함을 검사하고 계산한다;S43. After the tracked defect disappears from the frame series, the next defect is inspected and calculated;

S44. 마지막으로 유형별 결함의 수량을 합계한다.S44. Finally, the quantity of defects by type is totaled.

바람직하게는, 상기 절차 S42에 따른 추적 알고리즘이 아래와 같이 적용된다. 우선 합성곱 신경망으로 이전 프레임과 현재 프레임의 특징도를 얻게 되고, 그 다음에 셀프 어텐션 매커니즘을 활용하여 디코딩을 통해 검사 프레임워크와 추적 프레임워크를 얻고 마지막으로 같은 프레임에 IoU 함수를 활용하여 검사 프레임워크와 추적 프레임워크 추적을 완성한다.Preferably, the tracking algorithm according to procedure S42 above is applied as follows. First, the features of the previous frame and the current frame are obtained using a convolutional neural network, then the inspection framework and tracking framework are obtained through decoding using a self-attention mechanism, and finally, the inspection frame is obtained by using the IoU function on the same frame. Complete the work and tracking framework tracking.

바람직하게는, 상기 절차 S5에 의한 검사와 출력한 결과는 구체적으로 아래와 같다. 시험 세트를 상기 검사. 추적 또는 계수 모델에 입력하고 배관 결함에 대한 검사, 추적 또는 계수를 진행함으로써 수치 지표가 예상된 정확율에 도달할 수 있는지 판단한다. 예상치에 도달한 후에 배관 결함 결과가 출력될 예정이다. Preferably, the inspection and output results by the above procedure S5 are specifically as follows. Check the test set above. Determine whether numerical indicators can reach expected accuracy rates by inputting them into a tracking or counting model and inspecting, tracking, or counting pipe defects. After reaching the estimate, the pipe defect results will be output.

바람직하게는, 상기 검사 수치 지표는 정확율, F1 스코어와 PR 곡선을 포함한다. 상기 PR 곡선은 재현율을 가로 좌표로 하며, 정확율을 세로 좌표로 한다.Preferably, the test numerical indicators include accuracy rate, F1 score and PR curve. The PR curve uses recall as the abscissa and accuracy as the ordinate.

바람직하게는, 상기 예상 정확율은 각 유형의 배관 결함의 정확율이 85% 이상이다.Preferably, the predicted accuracy rate is greater than or equal to 85% for each type of piping defect.

본 발명의 유익한 효과는 다음과 같다. 본 발명은 딥러닝 기반 배수관 결함 이미지 생성망을 구축하여 새로운 결함 이미지 수량을 추가한다. 연속적인 영상 프레임으로 인한 중복 계수 문제를 해결하기 위하여 셀프 어텐션 메커니즘 기반 추적 또는 계수 모델을 제시한다. 이는 배수관 결함 수량과 유형 계산에 적용된다. 합성곱 연산자 수용 영역에 제한성이 있다는 문제를 해결하기 위하여 셀프 어텐션 메커니즘을 활용함으로써 결함 검사의 정확성을 높여 준다. 배관 결함의 유형이 다양하고 상황이 복잡하기 때문에 기존 알고리즘이 결함 특징 정보 추출에 한계가 있어서 다양한 배관 환경에 적용하기 어렵다. 본 발명은 딥러닝을 활용하여 다수의 배관 결함 특징 학습을 통해 일반화 능력이 증가하고 식별 정확도가 향상된다.The beneficial effects of the present invention are as follows. The present invention builds a deep learning-based drain pipe defect image generation network and adds new defect image quantities. To solve the redundant counting problem caused by consecutive video frames, we propose a tracking or counting model based on a self-attention mechanism. This applies to calculating the quantity and type of drain defects. To solve the problem of limitations in the convolution operator acceptance area, the accuracy of defect inspection is improved by utilizing a self-attention mechanism. Because the types of piping defects are diverse and the situations are complex, existing algorithms have limitations in extracting defect characteristic information, making it difficult to apply them to various piping environments. The present invention utilizes deep learning to increase generalization ability and improve identification accuracy by learning multiple pipe defect characteristics.

도 1은 본 발명인 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수 방법의 절차 흐름도이다.
도 2는 본 발명의 셀프 어텐션 메커니즘 구조도이다.
도 3은 본 발명인 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수 방법의 인식 결과를 도시하는 도면이다.
Figure 1 is a flow chart of the inspection, tracking and counting method for various types of piping defects based on the self-attention mechanism of the present invention.
Figure 2 is a structural diagram of the self-attention mechanism of the present invention.
Figure 3 is a diagram showing the recognition results of the inspection, tracking, and counting method for various types of piping defects based on the self-attention mechanism of the present invention.

이하, 첨부된 도면을 참조하여 본 발명의 실시예에 있어서의 기술적 해결방안을 명확하고 완전하게 설명한다. 명백하게, 설명된 실시예는 본 발명의 전부가 아니라 일부 실시예이다. 본 발명의 실시예에 기초하여, 당업자가 창의적인 노력 없이 획득한 다른 모든 실시예는 본 발명의 보호 범위에 속할 것이다.Hereinafter, technical solutions in embodiments of the present invention will be clearly and completely described with reference to the attached drawings. Obviously, the described embodiments are some, but not all, embodiments of the invention. Based on the embodiments of the present invention, all other embodiments obtained by a person skilled in the art without creative efforts will fall within the protection scope of the present invention.

본 발명의 전문용어에 대한 정의가 아래와 같다:Definitions of terminology of the present invention are as follows:

F1 스코어(F1 Score, 통계학에서 이진 분류 모델의 정확도를 평가하는 지표이며 분류 모델의 정확율과 재현율을 동시 고려한다. F1 스코어는 모델의 정확율과 재현율의 가중치이며 최대치가 1이며며 최소치가 0이다;F1 Score (F1 Score) is an indicator that evaluates the accuracy of a binary classification model in statistics and simultaneously considers the accuracy and recall of the classification model. The F1 score is a weight of the model's accuracy and recall, and the maximum value is 1 and the minimum value is 0;

PR 곡선 (P는 정확율(precision)을 뜻하며, R은 재현율(recall)을 뜻하며 정확율과 재현율의 관계를 표현한 것이다);PR curve (P stands for precision, R stands for recall, and expresses the relationship between precision and recall);

견고성 (시스템 표현이 불안정한 파라미터 섭동하에서 특정한 성능을 유지하는 특성을 나타냄);Robustness (the property of a system representation to maintain a certain performance under unstable parameter perturbations);

어텐션 모델(AM,Attention model, 인간 대뇌의 주의력 기능을 참조하여 신경망이 입력한 데이터 부위에 따른 관심점이 다르고 가중치가 다르게 만들어 준다);Attention model (AM, Attention model, refers to the attention function of the human brain and creates different points of interest and different weights depending on the data area input by the neural network);

생성적 대립 신경망(GAN, Generative adversarial network)Generative adversarial network (GAN)

도 1 내지 도 3을 참조하면, 본 발명은 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 또는 계수 방법으로서 도 1과 같이 아래와 같은 절차를 포함한다:Referring to Figures 1 to 3, the present invention is a self-attention mechanism-based inspection, tracking or counting method for various types of piping defects and includes the following procedures as shown in Figure 1:

절차 1: 다양한 유형의 배관 결함 이미지 수집Procedure 1: Collect images of different types of pipe defects

배관 크롤링 로봇을 활용함으로써 정저우시와 톈진시의 지하 배수관 내부 표면 결함의 이미지와 영상을 수집했다. 하지만 배수관 내부 환경이 복잡하기 때문에 원본 이미지에 모호하고 각 유형의 결함 수량이 불균등 등의 문제가 있다. 따라서 원본 이미지에 대해 사전 처리를 진행하고 한 가지 또는 여러 가지 결함이 있는 이미지를 선정한다. 구체적인 과정은 아래와 같다:By utilizing a pipe crawling robot, images and videos of internal surface defects of underground drain pipes in Zhengzhou and Tianjin cities were collected. However, because the internal environment of the drain pipe is complex, there are problems such as ambiguity in the original image and uneven quantity of each type of defect. Therefore, preprocessing is performed on the original image and images with one or several defects are selected. The specific process is as follows:

1.1 도로 표면 결함 이미지의 수집 방법은 아래와 같다. 배관 크롤링 로봇을 통해 배관 내 표면 결함 이미지 또는 영상 수집한다;1.1 The method of collecting road surface defect images is as follows. Collect images or videos of surface defects within pipes through a pipe crawling robot;

1.2 관계자가 원본 이미지에 대한 사전처리를 진행하고 영상을 프레임 이미지로 분할하고 모든 이미지의 해상도가 256×256로 통일하고 jpg 포맷으로 저장된다;1.2 The person involved performs pre-processing on the original image, divides the video into frame images, unifies the resolution of all images to 256×256, and saves them in jpg format;

1.3 관계자가 한 가지 또는 여러 가지의 결함을 포함한 이미지를 선정한다.1.3 The person concerned selects an image containing one or more defects.

구체적으로 설명하면, 영상에서 같은 결함에 대한 이미지 한 장만 저장되어 단일 결함에 대한 모델의 어텐션을 중복적으로 증가하는 문제를 해결해 준다.Specifically, this solves the problem of redundantly increasing the model's attention to a single defect by storing only one image of the same defect in the video.

구체적으로 설명하면, 관계자가 결함이 사진에서 뚜렷하게 나타날 수 있도록 해상도, 노출도, 모호도, 밝기, 수량 균형을 의한 필터를 진행한다.To be specific, the person involved performs filters based on resolution, exposure, ambiguity, brightness, and quantity balance so that defects appear clearly in the photo.

절차 2: 배관 결함 이미지 데이터 세트 구축Procedure 2: Building a Pipe Defect Image Dataset

생성적 대립 신경망을 바탕으로 생성한 배관 결함 이미지를 활용함으로써 원본 이미지와 생성된 이미지를 결합함으로써 결함 데이터 세트를 구축한다. 관계자는 배관 결함 데이터 세트를 분류하고 표시함으로써 해상도가 높고 수량에 균형 잡힌 배관 결함 데이터베이스를 구축한다. 또한 비율에 의하여 훈련 세트, 검증 세트와 시험 세트로 나누게 된다. 구체적인 과정은 아래와 같다:By using pipe defect images generated based on a generative adversarial neural network, a defect data set is constructed by combining the original image and the generated image. By classifying and displaying pipeline defect data sets, stakeholders build a high-resolution, quantitatively balanced pipeline defect database. Also, it is divided into training set, validation set and test set according to the ratio. The specific process is as follows:

2.1 진실한 배관 결함 이미지를 접합 오류, 파열, 장애물 총 3가지의 결함 유형별로 분류한다.2.1 Classify true piping defect images into three defect types: joint failure, rupture, and obstruction.

2.2 생성적 대립 신경망을 구축함으로써 배관 결함을 유형별로 훈련하고 모델을 생성한다. 또한 결함 이미지를 생성하고 jpg 포맷으로 저장된다.2.2 By building a generative adversarial network, we train pipe defects by type and create a model. It also creates defect images and saves them in jpg format.

2.3 생성된 이미지를 선정한다. 원본 이미지와 생성된 이미지를 같은 파일로 저장되고 이미지 순서를 의하여 이미지에 대한 리네임을 진행한다;2.3 Select the created image. The original image and the created image are saved as the same file, and the image is renamed according to the image order;

2.4 표시 이미지 배경 영역의 픽셀을 0으로, 접합 오류 구역의 픽셀을 1로 , 파열 구역의 픽셀을 2로, 장애물 구역의 픽셀을 3으로 표시하고 xml 포맷으로 저장된다;2.4 Display image The pixels in the background area are marked as 0, the pixels in the splicing error zone are marked as 1, the pixels in the rupture zone are marked as 2, and the pixels in the obstacle zone are marked as 3 and saved in xml format;

2.5 보정된 jpg 포맷의 이미지와 생성된 xml 포맷의 표시 정보를 결합함으로써 배관 결함 이미지 데이터베이스를 만들어 낸다;2.5 Create a pipe defect image database by combining the corrected jpg format images and the generated xml format display information;

2.6 배관 결함 이미지 데이터베이스는 랜덤적으로 6:2:2의 비율로 훈련 세트, 검증 세트와 시험 세트로 나누게 된다.2.6 The pipe defect image database is randomly divided into a training set, validation set, and test set at a ratio of 6:2:2.

구체적으로 딥러닝 기반으로 한 목표 검사는 대량의 이미지가 필요하다. 배수관의 복잡한 환경(예를 들면 어두운 환경, 수질 환경)으로 인해 결함 이미지 자료를 얻기 어렵다. 기존 아핀 변환(예를 들면 이동, 회전과 크기 조절)을 기반으로 한 데이터 보강 방법은 수 많은 이미지 생성에 적용된다. 하지만 이런 방법은 원본 이미지와 관계성이 높은 새로운 이미지만 생성할 수 있다. 생성적 대립 신경망은 생성기와 감별기로 구성되어 있다. 생성기는 랜덤적으로 잡음을 접수하고 새로운 이미지를 생성한다. 감별기는 진실한 이미지인지 판단하는 것이다.Specifically, targeted inspection based on deep learning requires large amounts of images. It is difficult to obtain defect image data due to the complex environment of drain pipes (e.g. dark environment, water quality environment). Data enrichment methods based on traditional affine transformations (e.g. translation, rotation and scaling) are applied to numerous image creations. However, this method can only create new images that are highly related to the original image. A generative adversarial network consists of a generator and a discriminator. The generator randomly receives noise and creates a new image. The discriminator is to determine whether the image is true.

구체적으로, 훈련 기간에 생성기는 가짜 사진을 생성하여 감별기를 속이는 역할을 하며, 감별기는 생성기로 생성된 가짜 이미지와 진실한 이미지를 구분하는 역할을 하고 있다. 이러므로 생성기와 감별기로 구성된 동태적 게임이다. 상황이 좋을 경우에 생성기는 진실한 이미지와 같이 보이는 사진을 생성할 수 있다. 이런 경우에 감별기는 생성기가 생성한 이미지가 진실한 것인지 판단하기 어렵다.Specifically, during the training period, the generator generates fake photos to deceive the discriminator, and the discriminator serves to distinguish between fake images generated by the generator and true images. Therefore, it is a dynamic game consisting of a generator and a discriminator. Under good circumstances, the generator can produce photos that look like true images. In this case, it is difficult for the discriminator to determine whether the image generated by the generator is authentic.

구체적으로, 훈련 과정에서 499장의 접합 오류 이미지와 472장의 장애물을 GAN에 입력된다. 파열 유형에서 국부 이미지 수량이 117장이며 전체 이미지 수량이 315장이다. 만약 국부와 전체 이미지를 동시 훈련하면 GAN 모델이 국부 특징과 전체 특징을 구분할 수 없다. 어떤 이미지에서 국부 특징과 전체 특징을 갖추고 성능이 혼란된 상태이다. 이 때문에 315장의 국부 파열 이미지만 대상으로 훈련을 진행한다. 마지막으로 3가지의 결함 이미지의 생성 모델을 구축한다.Specifically, during the training process, 499 splicing error images and 472 obstacles are input to the GAN. In the rupture type, the number of local images is 117 and the total number of images is 315. If local and global images are trained simultaneously, the GAN model cannot distinguish between local and global features. In some images, local features and global features are present, and the performance is confused. For this reason, training is conducted using only 315 local rupture images. Finally, we build a generation model for three defect images.

구체적으로, 훈련 세트, 검증 세트와 시험 세트의 이미지는 서로 겹치지 않으면 검증 모델의 견고성과 일반화 능력이 향상된다.Specifically, if the images in the training set, validation set, and test set do not overlap each other, the robustness and generalization ability of the validation model are improved.

구체적으로, 1403장의 진실한 이미지와 1500장의 가짜 이미지로 배수관 결함 이미지 라이브러리를 구축한다. 검증 세트와 시험 세트 중의 이미지 진실성을 확보하기 위하여 훈련 세트에 1500장의 가짜 이미지를 추가한다. 이 때문에 검증 세트와 시험 세트 중의 이미지 수량을 변함없이 유지한다. 훈련 세트에서 842개의 접합 오류, 116개의 장애물과 74개의 파열이 있다. 시험 세트에서 114개의 접합 오류, 88개의 장애물과 101개의 파열이 있다.Specifically, a drain pipe defect image library is constructed with 1403 real images and 1500 fake images. To ensure the veracity of the images in the validation and test sets, 1500 fake images are added to the training set. For this reason, the number of images in the validation set and test set is kept constant. There are 842 splicing errors, 116 obstacles and 74 ruptures in the training set. There are 114 joint errors, 88 obstructions and 101 ruptures in the test set.

절차 3: 배관 결함 검사 모델 구축 및 훈련Procedure 3: Building and training a pipe defect inspection model

셀프 어텐션 메커니즘 기반으로 한 배관 결함 시험 모델이 적용되며 도 2와 같이 전이 학습 방법을 사용하여 모델 초기화를 진행하고 모델을 훈련시킨다. 모델 훈련 과정에서 기록한 손실치와 정확률을 비교하고 최적 하이퍼파라미터를 찾아야 한다. 구체적인 과정이 아래와 같다:A piping defect test model based on a self-attention mechanism is applied, and the transfer learning method is used to initialize the model and train the model, as shown in Figure 2. We need to compare the loss values and accuracy rates recorded during the model training process and find the optimal hyperparameters. The specific process is as follows:

3.1 셀프 어텐션 메커니즘 기반으로 한 배관 결함 시험 모델이 적용된다. 셀프 어텐션 메커니즘은 조회벡터, 키벡터와 값벡터를 포함하고 있다;3.1 A piping defect test model based on a self-attention mechanism is applied. The self-attention mechanism includes lookup vector, key vector and value vector;

3.2 전이 학습 방법을 사용하여 신경망 초기화를 진행함으로써 훈련 효율을 향상시키고 검사 정확도를 높여 준다;3.2 Transfer learning method is used to initialize the neural network, which improves training efficiency and improves inspection accuracy;

3.3 모델 훈련 과정에서 기록한 손실치와 정확률을 비교하고 최적 하이퍼파라미터를 찾아야 한다.3.3 The loss and accuracy rates recorded during the model training process must be compared and the optimal hyperparameters must be found.

구체적으로 설명하면, 어텐션 모델이 최초로 기계 번역에 적용되며 장기적 의뢰 문제를 해결해 준다. 이는 신경망 분야의 중요한 콘셉트가 되었다. 상기 셀프 어텐션 메커니즘이 서열 간의 상호 작용을 계산함으로써 현 예상치에 관한 어텐션 가중치를 얻게 된다. 이 과정은 셀프 어텐션 메커니즘이 신경망 모델의 복잡도를 완화해 주는 것이다. 가중치의 값에 따라 어텐션 메커니즘이 인간 정보 처리의 어텐션의 집중을 시뮬레이션하고 모델의 성능을 향상시키고 계산량을 낮추게 된다.Specifically, the attention model is applied to machine translation for the first time and solves the long-term request problem. This has become an important concept in the field of neural networks. The self-attention mechanism calculates interactions between sequences to obtain an attention weight related to the current prediction. In this process, the self-attention mechanism reduces the complexity of the neural network model. Depending on the value of the weight, the attention mechanism simulates the concentration of attention in human information processing, improves model performance and reduces the amount of computation.

구체적으로, 2차원 이미지를 처리하기 위하여 원본 이미지를 9개의 2차원 블록으로 분할하고 2차원 블록을 벡터화 처리로 셀프 어텐션 모델을 얻게 된다. 이는 1차원 유효계열(x1,x2,x3,...,x9) 접수가 가능하다. 완전 연결 계층을 통해 1차원 계열을 고정 길이의 내용 벡터로 전환한다. 블록마다 위치 코딩 정보를 추가하고 내용 벡터를 삽입하고 시맨틱계열(z1,z2,z3,...,z9)을 얻게 된다.Specifically, to process a 2D image, the original image is divided into 9 2D blocks and the 2D blocks are vectorized to obtain a self-attention model. This can be accepted as a one-dimensional valid series (x 1 , x 2 , x 3 ,..., x 9 ). Converts one-dimensional series into fixed-length content vectors through a fully connected layer. Position coding information is added to each block, a content vector is inserted, and a semantic series (z 1 ,z 2 ,z 3 ,...,z 9 ) is obtained.

구체적으로 설명하면, 상기 조회벡터는 이전 출력 yi -1이며, 상기 키벡터는 입력값 xi가 출력값 yi의 중요한 정도에 영향을 미치며, 상기 값벡터가 각 입력값 xi의 크기를 나타낸다. 키벡터와 조회벡터가 곱한 값을 바탕으로 소프트맥스(Softmax) 함수로 가중벡터 ai를 얻게 된다. 이는 출력치 yi를 예측하는 과정에서 입력 벡터의 어텐션 정도를 뜻한다. 마지막으로 소프트맥스(Softmax) 함수를 통해 출력 확률 분포를 얻으며 라벨코딩을 통해 출력 결과를 얻게 된다. 어텐션 메커니즘이 가중벡터로 인간 정보 처리시 주의력 집중을 시뮬레이션함으로써 모델의 성능을 향상시킨다.Specifically, the lookup vector is the previous output y i -1 , the key vector influences the importance of the input value x i to the output value y i , and the value vector represents the size of each input value x i . . Based on the value multiplied by the key vector and the lookup vector, the weight vector a i is obtained using the Softmax function. This means the degree of attention of the input vector in the process of predicting the output value y i . Finally, the output probability distribution is obtained through the Softmax function, and the output result is obtained through label coding. The attention mechanism improves the model's performance by simulating the concentration of attention when processing human information using a weight vector.

구체적으로 설명하면, 원하는 최적 하이퍼파라미터가 하기 조건에 만족시켜야 한다. 다른 하이퍼파라미터를 설정할 때 검증세트 데이터를 모델에 입력하고 검증해야 한다. 모델이 검증세트에서 정확율 상승 곡선의 최대치와 손실치 하강 곡선의 안정성과 수렴성 같은 지표로 평가해야 한다.Specifically, the desired optimal hyperparameter must satisfy the following conditions. When setting other hyperparameters, validation set data must be entered into the model and verified. The model should be evaluated by indicators such as the maximum accuracy increase curve and the stability and convergence of the loss decrease curve in the validation set.

구체적으로, 훈련이 지속적으로 진행하면서 모델의 손실은 점차 감소하고 정확도가 점점 증가한다. 61개의 시간대 훈련을 통해 모델(예상치 검증)의 정확율이 88.860%에 도달하며 손실 곡선은 완화하는 추세를 보인다. 해당 모델을 다음 단계에서 이용할 수 있도록 저장된다.Specifically, as training continues, the model's loss gradually decreases and accuracy gradually increases. Through training in 61 time periods, the accuracy rate of the model (expected value verification) reaches 88.860%, and the loss curve shows a easing trend. The model is saved so that it can be used in the next step.

우선적으로 선택해야 할 본 발명 실시예는 여러 번의 튜닝을 통해 최종적 모델의 하이퍼파라미터는 아래와 같다. 초기 학습율이 0.00001이며 매번 반복된 이미지 배치 수량은 2이고, 가중 감쇠치가 0.0005이며, 총 61번의 순환이 반복된다.In the embodiment of the present invention that should be selected first, the hyperparameters of the final model through several tunings are as follows. The initial learning rate is 0.00001, the number of image batches repeated each time is 2, the weighted attenuation value is 0.0005, and the cycle is repeated a total of 61 times.

절차 4: 배관 결함 추적 및 계수 모델 구축.Procedure 4: Building a pipe defect tracking and counting model.

추적 네트워크에 셀프 어텐션 메커니즘을 추가하고 배관 결함 이미지 데이터베이스로 이 신경망을 훈련시켜서 셀프 어텐션 메커니즘 기반 배관 추적 및 계수 모델을 구축한다. 어떤 유형의 배관 결함을 탐지하게 되면 추적 알고리즘을 활용함으로써 결함이 사라질 때까지 추적될 예정이다. 해당 결함 계수 수량에 1을 더하는 것이다. 구체적인 과정이 아래와 같다;By adding a self-attention mechanism to the tracking network and training this neural network with a database of pipe defect images, a pipe tracking and counting model based on the self-attention mechanism is built. Once a pipe defect of any type is detected, it will be tracked using tracking algorithms until the defect disappears. Add 1 to the corresponding defect coefficient quantity. The specific process is as follows;

4.1 배관 영상 계열을 모델에 입력하고 배관 결함 검사 모델로 첫 프레임의 결함을 탐지하고 초기 경계박스를 정하고 결함 수량에 1을 더하는 것이다;4.1 Input the piping image series into the model, detect the defects in the first frame with the piping defect inspection model, determine the initial bounding box, and add 1 to the defect quantity;

4.2 배관 결함 추적 네트워크에서 추적 알고리즘이 탐지된 결함이 사라질 때까지 계속 추적한다;4.2 In the pipe defect tracking network, the tracking algorithm continues tracking the detected defect until it disappears;

4.3 추적된 결함이 프레임 계열에서 사라진 후에 다음 결함을 검사하고 계산한다;4.3 After the tracked defect disappears from the frame series, the next defect is inspected and calculated;

4.4 마지막으로 유형별 결함의 수량을 합계한다.4.4 Finally, sum up the quantity of defects by type.

구체적으로 설명하면, 기존 딥러닝 기반 배관 결함 검사 신경망을 통해 결함의 유형과 위치를 얻을 수 있다. 하지만 영상의 연속 프레임에서 동일한 결함이 있을 수 있다. 기존 검사 방법으로 동일한 결함 인식이 안되며 계산하기 어려운 문제가 발생할 가능성이 있다. 검사는 정태적인 작업으로 비슷한 이미지에서 배웠던 특징을 통해 단일한 이미지에서 목표물을 찾는 것이다. 반면에 추적은 동태적인 작업으로 이전 프레임의 특징을 활용함으로써 연속적인 프레임에서 같은 목표물을 찾게 된다. 추적 작업은 이전 프레임과 현재 프레임의 유사도를 비교함으로써 목표물의 운동 궤적을 찾아낸다.Specifically, the type and location of the defect can be obtained through an existing deep learning-based piping defect inspection neural network. However, the same defect may exist in successive frames of video. Existing inspection methods do not recognize the same defects, and problems that are difficult to calculate may arise. Testing is a static task: finding a target in a single image using features learned from similar images. On the other hand, tracking is a dynamic task that finds the same target in successive frames by utilizing the characteristics of previous frames. The tracking task finds the target's movement trajectory by comparing the similarity between the previous frame and the current frame.

더 나아가, 추적 알고리즘은 아래와 같은 절차를 포함하고 있다. 우선 합성곱 신경망으로 이전 프레임 및 현재 프레임의 특징도를 얻게 되고, 그 다음에 셀프 어텐션 메커니즘을 활용하여 디코딩을 통해 검사 프레임워크와 추적 프레임워크를 얻고, 마지막으로 동일한 프레임에서 IoU 함수를 활용하여 검사 프레임워크와 추적 프레임워크 추적을 완성한 것이다.Furthermore, the tracking algorithm includes the following procedures. First, the features of the previous frame and the current frame are obtained using a convolutional neural network, then the inspection framework and tracking framework are obtained through decoding using a self-attention mechanism, and finally, the IoU function is used to inspect the same frame. Framework and Tracking Framework tracking has been completed.

절차 5: 테스트 및 결과 출력.Procedure 5: Test and print results.

배관 크롤링 로봇을 통해 배관 내 표면 결함 영상을 촬영하고 고성능 서버에 전송된다. 시험세트는 상기 모델에 입력하고 배관 결함을 검사하고 추적함으로써 검사 수치 지표가 예상된 정확율에 도달할 수 있는지 판단할 수 있다. 예상치에 도달하면 배관 결함 결과가 출력된다.Images of surface defects within the pipe are captured using a pipe crawling robot and transmitted to a high-performance server. A test set can be input into the model and inspect and track pipe defects to determine if inspection metrics can reach expected accuracy rates. When the expected value is reached, the pipe defect result is output.

구체적으로, 배관 결함 결과는 결함 유형, 해당 수량과 관련 위치를 포함하고 있다.Specifically, piping defect results include the defect type, its quantity, and its relative location.

구체적으로 설명하면, 도 3은 해상도가 720×408로 되며 재생 속도가 초당 25 프레임이며 12초의 배관 결함 영상을 도시하는 것이다. 본 모델을 활용하여 결함을 추적하고 추적 프레임워크로 결함이 이미지 속의 위치를 정한 것이다. 그 중에 왼쪽 상단에 있는 글자는 결함 유형을 표시하며, 숫자는 계수 번호를 뜻한 것이다. 이 영상에서 나타난 결함이 장애물이며 총 2개가 있다. 검사와 계수 결과는 모두 정확하게 집계된다.Specifically, FIG. 3 shows a 12-second pipe defect image with a resolution of 720×408 and a playback speed of 25 frames per second. This model is used to track defects and the location of the defect in the image is determined using the tracking framework. Among them, the letters in the upper left indicate the defect type, and the numbers indicate the coefficient number. The defects shown in this video are obstacles, and there are a total of two. All inspection and counting results are accurately counted.

구체적으로, 검사 수치 지표는 정확율, F1 스코어와 PR 곡선을 포함한다.Specifically, test numerical indicators include accuracy rate, F1 score, and PR curve.

구체적으로, 신뢰도 한계치를 조절함으로써 검증세트 이미지는 재현율과 이에 맞춰 준 정확율을 출력할 수 있다. 상기 PR 곡선은 재현율을 가로 좌표로 하며 정확율을 세로 좌표로 한다. 곡선 아래 부분의 면적 크기를 비교함으로써 모델의 장점과 단점을 분석할 수 있다. 시험세트 샘플이 불균형할 경우에 정확도와 F1 스코어보다 PR 곡선이 모델에 대하여 평가하는데 더 객관적이다.Specifically, by adjusting the reliability threshold, the validation set image can output a recall rate and a corresponding accuracy rate. The PR curve uses recall as the abscissa and accuracy as the ordinate. By comparing the size of the area under the curve, the strengths and weaknesses of the model can be analyzed. When the test set samples are unbalanced, the PR curve is a more objective way to evaluate a model than accuracy and F1 score.

구체적으로 설명하면, 정확하거나 잘못하게 통계한 정보를 수집함으로써 각 유형의 결함에 85% 이상의 정확율이 도달할 수 있는지 확인해야 한다. 이를 통해 본 발명이 진실한 환경에서 응용하는 능력을 확보한다. 정확율이 예상한 요구에 도달하지 못하면 검사 오류정보를 통계하고 귀납해야 한다. 오류 결함을 찾는 이미지는 본 발명의 방법에 의하여 처리한 후에 배관 결함 이미지 데이터베이스에 추가하고 다시 훈련시키고 각 지표가 예상치에 도달할 때까지 튜닝을 한다. 본 발명은 기존의 합성곱 신경망 대신 트랜스포머(Transformer) 신경망을 이용함으로써 모델 검사의 정확도를 높이고 배관 결함 자동 인식과 계수 기능을 구현해 준다.Specifically, we need to ensure that an accuracy rate of 85% or higher for each type of defect can be achieved by collecting accurate or incorrect statistical information. This ensures the ability of the present invention to be applied in a realistic environment. If the accuracy rate does not reach the expected requirement, the test error information must be statisticized and deducted. Images that find error defects are processed by the method of the present invention, then added to the pipe defect image database, retrained, and tuned until each indicator reaches the expected value. The present invention improves the accuracy of model inspection and implements automatic recognition and counting of piping defects by using a transformer neural network instead of the existing convolutional neural network.

본 발명은 전술한 실시예를 참조하여 상세하게 설명되었지만, 당업자라면 전술한 실시예에서 설명된 기술적 솔루션을 수정하거나 일부 기술적 특징에 대해 동등한 대체를 수행하는 것이 여전히 가능하다. 본 발명의 사상과 원리 내에서 이루어진 수정, 균등 대체, 개량 등은 본 발명의 보호 범위에 포함된다.Although the present invention has been described in detail with reference to the above-described embodiments, it is still possible for those skilled in the art to modify the technical solutions described in the above-described embodiments or make equivalent replacements for some technical features. Modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention are included in the protection scope of the present invention.

Claims (10)

S1. 다양한 유형의 배관 결함 이미지 수집 절차 ;
S2. 배관 결함 이미지 데이터 세트 구축 절차;
S3. 배관 결함 검사 모델 구축 및 훈련 절차;
S4. 배관 결함 추적 및 계수 모델 구축 절차; 및
S5. 테스트 및 결과 출력 절차를 포함하는 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법.
S1. Procedure for collecting images of various types of pipe defects;
S2. Pipe defect image dataset construction procedure;
S3. Piping defect inspection model construction and training procedures;
S4. Piping defect tracking and counting model building procedures; and
S5. Inspection, tracking and counting method for various types of piping defects based on self-attention mechanism including test and result output procedures.
청구항 1에 있어서,
상기 절차 S1인 다양한 유형의 배관 결함 이미지 수집은,
S11. 배관 크롤링 로봇을 통해 배관 내 표면 결함 이미지 또는 영상 수집 절차;
S12. 원본 이미지에 대한 사전 처리를 진행하고 영상을 프레임 이미지로 분할하고 모든 이미지의 해상도를 256×256로 통일하고 jpg 포맷으로 저장하는 절차; 및
S13. 한 가지 또는 여러 가지의 결함을 포함한 이미지를 선정하는 절차를 포함하는 것을 특징으로 하는 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법.
In claim 1,
The above procedure S1, collecting images of various types of pipe defects,
S11. Procedure for collecting images or videos of surface defects in pipes through pipe crawling robots;
S12. The procedure of pre-processing the original image, dividing the video into frame images, unifying the resolution of all images to 256×256, and saving them in jpg format; and
S13. An inspection, tracking, and counting method for various types of piping defects based on a self-attention mechanism that includes a procedure for selecting an image containing one or several defects.
청구항 1에 있어서,
상기 절차 S2인 배관 결함 이미지 데이터 세트 구축은,
S21. 절차 S1을 통해 배관 결함 이미지를 접합 오류, 파열, 장애물 총 3가지의 결함 유형별로 분류하는 절차;
S22. 생성적 대립 신경망 GAN을 구축하는데, GAN 신경망은 생성기와 감별기로 구성되어 있으며, 생성기는 랜덤적으로 잡음을 접수하고 새로운 이미지를 생성하며, 감별기는 진실한 이미지인지 판단하며, 배관 결함 유형에 따라 훈련을 실시하며, 총 3가지의 이미지의 생성 모델을 구축하고 이미지가 생성되고 jpg 포맷으로 저장되는 절차;
S23. 원본 이미지와 생성 이미지는 같은 파일에 통합되고, 이미지 순서대로 리네임을 진행하는 절차;
S24. 표시 이미지 배경 구역의 픽셀은 0으로, 접합 오류 구역의 픽셀은 1로, 파열 구역의 픽셀은 2로, 장애물 구역의 픽셀은 3으로 표시되며 xml 포맷으로 저장되는 절차;
S25. 보정된 jpg 포맷의 이미지와 생성된 xml 포맷의 표시 정보를 결합함으로써 배관 결함 이미지 데이터베이스를 구축하는 절차; 및
S26. 절차 S25에 따른 이미지 데이터베이스는 랜덤적으로 6:2:2의 비율로 훈련 세트, 검증 세트와 시험 세트로 나누는 절차를 포함하는 것을 특징으로 하는 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법.
In claim 1,
The construction of the pipe defect image data set, which is procedure S2, is as follows:
S21. The procedure of classifying pipe defect images into three defect types: joint failure, rupture, and obstruction through procedure S1;
S22. A generative adversarial neural network (GAN) is constructed. The GAN neural network consists of a generator and a discriminator. The generator randomly receives noise and creates a new image, and the discriminator determines whether the image is true, and trains according to the type of pipe defect. A procedure in which a total of three image generation models are built and the images are created and saved in jpg format;
S23. The original image and the generated image are integrated into the same file, and renaming is performed in the order of the images;
S24. The pixels in the display image background area are marked as 0, the pixels in the junction error zone are marked as 1, the pixels in the rupture zone are marked as 2, and the pixels in the obstacle zone are marked as 3, and the procedure is saved in xml format;
S25. A procedure for building a pipe defect image database by combining the corrected jpg format images and the generated xml format display information; and
S26. Inspection and tracking of various types of piping defects based on a self-attention mechanism, which includes the procedure of randomly dividing the image database according to procedure S25 into a training set, validation set, and test set at a ratio of 6:2:2. and counting method.
청구항 1에 있어서,
상기 절차 S3에 언급한 배관 결함 검사 모델 구축 및 훈련은,
셀프 어텐션 메커니즘 기반 배관 결함 검사 모델을 구축하고 전이 학습 방법을 사용하여 모델 초기화를 진행하고 훈련 세트 데이터를 훈련 모델에 입력하고 모델 훈련과정에서 기록한 손실치와 정확률을 비교하고 최적 하이퍼파라미터를 찾아야 내고, 검증 세트의 데이터를 모델에 입력하고 검증을 진행하여 검증된 예상치에 도달한 후에 모델을 저장하는 것을 특징으로 하는 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법.
In claim 1,
Building and training the piping defect inspection model mentioned in procedure S3 above,
Build a plumbing defect inspection model based on a self-attention mechanism, initialize the model using a transfer learning method, input training set data into the training model, compare the loss values and accuracy rates recorded during the model training process, and find the optimal hyperparameters. An inspection, tracking, and counting method for various types of piping defects based on a self-attention mechanism that inputs data from the verification set into the model, performs verification, and saves the model after reaching the verified estimate.
청구항 4에 있어서,
원하는 최적 하이퍼파라미터는,
다른 하이퍼파라미터를 설정할 때 훈련 과정에서 정확율 상승곡선의 최대치와 손실치 하강곡선의 안정성과 수렴성을 비교하며, 상기 검증 예상치는 모델의 정확성이 88.860%에 도달하며 손실곡선에 완화할 추세를 보이며, 상기 최적 하이퍼파리미터는 초기 학습율이 0.00001이며 매번 반복된 이미지 배치수량이 2로 되며 가중 감쇠치가 0.0005로 되며, 총 61번의 순환이 반복되는 것을 특징으로 하는 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법.
In claim 4,
The desired optimal hyperparameters are:
When setting other hyperparameters, the stability and convergence of the maximum accuracy rising curve and the loss value falling curve are compared during the training process, and the verification estimate shows that the accuracy of the model reaches 88.860% and the loss curve shows a tendency to relax. The optimal hyperparameter has an initial learning rate of 0.00001, the number of image batches repeated each time is 2, the weighted attenuation value is 0.0005, and inspection of various types of piping defects based on the self-attention mechanism, which is characterized by repeating a total of 61 cycles. Tracking and counting methods.
청구항 4에 있어서,
상기 셀프 어텐션 메커니즘이 서열 간의 상호작용을 계산함으로써 현 예상치에 관한 어텐션 가중치를 얻게 되는데, 구체적인 과정은,
우선 원시 이미지는 9개의 2차원 블록으로 분할하고 2차원 블록을 벡터화 처리로 셀프 어텐션 모델을 얻게 되며, 이는 1차원 유효계열(x1,x2,x3,... ,x9) 접수가 가능하며, 완전 연결 계층을 통해 1차원 계열을 고정 길이의 내용 벡터로 전환하며, 블록마다 위치 코딩 정보를 추가하고 내용 벡터를 삽입하고 시맨틱계열(z1,z2,z3, ... ,z9)을 얻어서 마지막으로 어텐션 가중치를 얻게 되는 절차; 및
상기 셀프 어텐션 메커니즘은 조회벡터, 키벡터와 값벡터를 포함하며, 상기 조회벡터는 이전 항목 출력 yi -1이며, 상기 키벡터는 입력값 xi가 출력값 yi의 중요한 정도에 영향을 미치며, 상기 값벡터는 각 입력값 xi의 크기를 표현하며, 키벡터와 조회벡터가 곱한 값을 바탕으로 소프트맥스(Softmax) 함수로 가중벡터 ai를 얻게 되며, 이는 출력치 yi를 예측하는 과정에서 입력 벡터의 어텐션 정도를 뜻하는 것을 특징으로 하는 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법.
In claim 4,
The self-attention mechanism calculates interactions between sequences to obtain an attention weight related to the current prediction. The specific process is:
First, the raw image is divided into 9 2-dimensional blocks, and the 2-dimensional blocks are vectorized to obtain a self-attention model, which receives a 1-dimensional valid series (x 1 , x 2 , x 3 ,..., x 9 ). It is possible, converting the one-dimensional series into a fixed-length content vector through a fully connected layer, adding position coding information to each block, inserting the content vector, and converting the semantic series (z 1 , z 2 , z 3 , ..., z 9 ) is obtained and finally the attention weight is obtained; and
The self-attention mechanism includes a lookup vector, a key vector and a value vector, where the lookup vector is the previous item output y i -1 , and the key vector influences the degree to which the input value x i is important to the output value y i , The value vector expresses the size of each input value x i , and based on the value multiplied by the key vector and the lookup vector, a weight vector a i is obtained using the Softmax function, which is the process of predicting the output value y i . An inspection, tracking, and counting method for various types of piping defects based on a self-attention mechanism, which refers to the degree of attention of the input vector.
청구항 1에 있어서,
상기 절차 S4에 따른 배관 결함 추적 및 계수모델 구축은 추적 네트워크에 셀프 어텐션 메커니즘을 추가하고 배관 결함 이미지 데이터베이스로 이 신경망을 훈련 시키며, 셀프 어텐션 메커니즘 기반 배관 추적 및 계수모델을 구축하며, 어떤 유형의 배관 결함을 탐지하게 되면 추적 알고리즘을 활용함으로써 결함이 사라질 때까지 추적될 예정이며, 해당 결함 계수 수량에 1을 더하는 것으로서,
구체적인 과정은,
S41. 배관 영상 계열을 모델에 입력하고 배관 결함 검사 모델로 첫 프레임의 결함을 탐지하고 초기 경계박스를 정하고 결함 수량에 1을 더하는 절차;
S42. 배관 결함 추적 네트워크에서 추적 알고리즘이 탐지된 결함이 사라질 때까지 계속 추적하는 절차;
S43. 추적된 결함이 프레임 계열에서 사라진 후에 다음 결함을 검사하고 계산하는 절차; 및
S44. 마지막으로 유형별 결함의 수량을 합계하는 절차를 포함하는 것을 특징으로 하는 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법.
In claim 1,
Building a pipe defect tracking and counting model according to the above procedure S4 adds a self-attention mechanism to the tracking network, trains this neural network with a pipe defect image database, builds a pipe tracking and counting model based on the self-attention mechanism, and determines which type of pipe. When a defect is detected, it will be tracked until the defect disappears by using a tracking algorithm, and 1 will be added to the defect count quantity.
The specific process is,
S41. A procedure to input a pipe image series into the model, detect defects in the first frame with the pipe defect inspection model, determine the initial bounding box, and add 1 to the defect quantity;
S42. A procedure in which a tracking algorithm in a piping defect tracking network continues to track a detected defect until it disappears;
S43. A procedure for inspecting and calculating the next defect after a tracked defect has disappeared from the frame series; and
S44. Lastly, an inspection, tracking, and counting method for various types of piping defects based on a self-attention mechanism that includes a procedure for summing the quantity of defects by type.
청구항 7에 있어서,
상기 절차 S42에 따른 추적 알고리즘은,
우선 합성곱 신경망으로 이전 프레임과 현재 프레임의 특징도를 얻고, 그 다음에 셀프 어텐션 매커니즘을 활용하여 디코딩을 통해 검사 프레임워크와 추적 프레임워크를 얻고, 마지막으로 같은 프레임에 IoU 함수를 활용하여 검사 프레임 워크와 추적 프레임워크 추적을 완성하는 것을 특징으로 하는 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법.
In claim 7,
The tracking algorithm according to procedure S42 is,
First, obtain the features of the previous frame and the current frame using a convolutional neural network, then use the self-attention mechanism to obtain the inspection framework and tracking framework through decoding, and finally, use the IoU function for the same frame to obtain the inspection frame. An inspection, tracking, and counting method for various types of piping defects based on a self-attention mechanism that completes the work and tracking framework tracking.
청구항 1에 있어서,
상기 절차 S5에 의한 검사와 출력한 결과는,
시험 세트를 상기 검사, 추적 또는 계수모델에 입력하고 배관 결함에 대한 검사, 추적 또는 계수를 진행함으로써 수치 지표가 예상된 정확율에 도달할 수 있는지 판단하며, 예상치에 도달한 후에 배관 결함 결과가 출력되는 것을 특징으로 하는 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법.
In claim 1,
The results of the inspection and output according to procedure S5 above are:
By inputting a test set into the inspection, tracking, or counting model and inspecting, tracking, or counting pipe defects, it is determined whether the numerical indicator can reach the expected accuracy rate, and after reaching the expectation, the pipe defect result is output. An inspection, tracking and counting method for various types of piping defects based on a self-attention mechanism.
청구항 8에 있어서,
상기 검사 수치 지표는 정확율, F1 스코어와 PR 곡선을 포함하며, 상기 PR 곡선은 재현율을 가로 좌표로 하며 정확율을 세로 좌표로 하며, 상기 예상 정확율은 각 유형의 배관 결함의 정확율이 85% 이상인 것을 특징으로 하는 셀프 어텐션 메커니즘 기반 다양한 유형의 배관 결함에 대한 검사, 추적 및 계수방법.
In claim 8,
The inspection numerical index includes accuracy rate, F1 score, and PR curve. The PR curve has the recall rate as the abscissa and the accuracy rate as the ordinate, and the expected accuracy rate is characterized in that the accuracy rate for each type of piping defect is 85% or more. An inspection, tracking and counting method for various types of piping defects based on a self-attention mechanism.
KR1020220066732A 2022-03-22 2022-05-31 A multi-class pipeline defect detection, tracking and counting method based on self-attention mechanism KR20230137788A (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210287241.3A CN114723957A (en) 2022-03-22 2022-03-22 Multi-class pipeline defect detection, tracking and counting method based on self-attention mechanism
CN202210287241.3 2022-03-22

Publications (1)

Publication Number Publication Date
KR20230137788A true KR20230137788A (en) 2023-10-05

Family

ID=82239224

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020220066732A KR20230137788A (en) 2022-03-22 2022-05-31 A multi-class pipeline defect detection, tracking and counting method based on self-attention mechanism

Country Status (2)

Country Link
KR (1) KR20230137788A (en)
CN (1) CN114723957A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117237683A (en) * 2023-11-10 2023-12-15 闽都创新实验室 Chip defect intelligent detection system based on improved neural network
CN117406759A (en) * 2023-12-14 2024-01-16 深圳天溯计量检测股份有限公司 Pipeline robot crawling calibration method and system
CN117576095A (en) * 2024-01-16 2024-02-20 南京航空航天大学 Metal surface defect detection and classification method for multi-scale learning task
CN117689999A (en) * 2024-02-04 2024-03-12 宝鸡核力材料科技有限公司 Method and system for realizing TC4 tape coiling process optimization
CN117830750A (en) * 2024-03-04 2024-04-05 青岛大学 Mechanical fault prediction method based on graph converter
CN117830750B (en) * 2024-03-04 2024-06-04 青岛大学 Mechanical fault prediction method based on graph converter

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117172085B (en) * 2023-04-17 2024-04-26 北京市水科学技术研究院 PCCP broken wire prediction method, device, computer equipment and medium

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117237683A (en) * 2023-11-10 2023-12-15 闽都创新实验室 Chip defect intelligent detection system based on improved neural network
CN117237683B (en) * 2023-11-10 2024-03-26 闽都创新实验室 Chip defect intelligent detection system based on improved neural network
CN117406759A (en) * 2023-12-14 2024-01-16 深圳天溯计量检测股份有限公司 Pipeline robot crawling calibration method and system
CN117406759B (en) * 2023-12-14 2024-04-05 深圳天溯计量检测股份有限公司 Pipeline robot crawling calibration method and system
CN117576095A (en) * 2024-01-16 2024-02-20 南京航空航天大学 Metal surface defect detection and classification method for multi-scale learning task
CN117576095B (en) * 2024-01-16 2024-04-05 南京航空航天大学 Metal surface defect detection and classification method for multi-scale learning task
CN117689999A (en) * 2024-02-04 2024-03-12 宝鸡核力材料科技有限公司 Method and system for realizing TC4 tape coiling process optimization
CN117689999B (en) * 2024-02-04 2024-05-07 宝鸡核力材料科技有限公司 Method and system for realizing TC4 tape coiling process optimization
CN117830750A (en) * 2024-03-04 2024-04-05 青岛大学 Mechanical fault prediction method based on graph converter
CN117830750B (en) * 2024-03-04 2024-06-04 青岛大学 Mechanical fault prediction method based on graph converter

Also Published As

Publication number Publication date
CN114723957A (en) 2022-07-08

Similar Documents

Publication Publication Date Title
KR20230137788A (en) A multi-class pipeline defect detection, tracking and counting method based on self-attention mechanism
KR102008973B1 (en) Apparatus and Method for Detection defect of sewer pipe based on Deep Learning
Kumar et al. Deep learning–based automated detection of sewer defects in CCTV videos
US20210319265A1 (en) Method for segmentation of underground drainage pipeline defects based on full convolutional neural network
Li et al. Sewer damage detection from imbalanced CCTV inspection data using deep convolutional neural networks with hierarchical classification
CN110992349A (en) Underground pipeline abnormity automatic positioning and identification method based on deep learning
CN110826588A (en) Drainage pipeline defect detection method based on attention mechanism
CN108074244A (en) A kind of safe city wagon flow statistical method for merging deep learning and Background difference
CN111832484A (en) Loop detection method based on convolution perception hash algorithm
CN110675374B (en) Two-dimensional image sewage flow detection method based on generation countermeasure network
CN112967252B (en) Rail vehicle machine sense hanger assembly bolt loss detection method
CN110660049A (en) Tire defect detection method based on deep learning
Gul et al. Image-based monitoring of open gears of movable bridges for condition assessment and maintenance decision making
Shehab et al. Automated detection and classification of infiltration in sewer pipes
CN115546223A (en) Method and system for detecting loss of fastening bolt of equipment under train
CN116206104A (en) Artificial intelligence segmentation classification algorithm for industrial appearance defect detection
CN116862885A (en) Segmentation guide denoising knowledge distillation method and device for ultrasonic image lesion detection
Wang et al. Instance segmentation of soft‐story buildings from street‐view images with semiautomatic annotation
Roberts et al. Optimization and sensitivity analysis of existing deep learning models for pavement surface monitoring using low-quality images
CN116596851A (en) Industrial flaw detection method based on knowledge distillation and anomaly simulation
CN116051496A (en) Real-time sewer defect detection method
CN113970073B (en) ResNet-based water supply network leakage accurate positioning method
Wang et al. Automatic Damage Segmentation Framework for Buried Sewer Pipes Based on Machine Vision: Case Study of Sewer Pipes in Zhengzhou, China
Jia et al. Defect Severity Assessment Model for Sewer Pipeline Based on Automated Pipe Calibration
Yasuno et al. One-class steel detector using patch GAN discriminator for visualising anomalous feature map