automatic classification of weld cracks using artificial intelligence and statistical methods...
TRANSCRIPT
Automatic classification of weld cracks Automatic classification of weld cracks using artificial intelligence and using artificial intelligence and
statistical methodsstatistical methods
Ryszard SIKORA, Piotr BANIUKIEWICZ, Ryszard SIKORA, Piotr BANIUKIEWICZ, Marcin CARYKMarcin CARYK
Szczecin University of TechnologySzczecin University of Technology Department of Electrical and Department of Electrical and
Computer EngineeringComputer Engineering
uul. Sikorskiego 37l. Sikorskiego 37, 7, 70-313 Szczecin0-313 Szczecin
POLANDPOLAND
Szczecin, June 2008 2
OUTLINEOUTLINE Digital radiography systemDigital radiography system Automatic Defect Recognition algorithmAutomatic Defect Recognition algorithm Introduction,Introduction, ADDIPADDIP,, Data base preparation,Data base preparation, Statistical analysisStatistical analysis Artificial neural network classifierArtificial neural network classifier ConclusionsConclusions
Szczecin, June 2008 3
DIGITAL RADIOGRAPHY SYSTEMDIGITAL RADIOGRAPHY SYSTEM
1. Portable X-Ray source (120KV, 1mA)2. Phosphor-plate scanner (spatial resolution 50μm,
digital resolution 16bit)3. Personal computer ( Pentium D 3,2 GHz, 2GB RAM)
1
2
3
DR
60
00
+ C
P12
0
Szczecin, June 2008 4
AUTOMATIC DEFECT RECOGNITION ALGORITHMAUTOMATIC DEFECT RECOGNITION ALGORITHM
Radiograph acquisition
ROI Selection, IQI detection and evaluation
Contrast enhancement, normalization, noise reduction
Image segmentation
Defect detection & indexing
Feature extraction
Defect recognition
Acceptance algorithm
Szczecin, June 2008 5
INTRODUCTIONINTRODUCTION The defects data base was prepared using ADDIP (developed by PS), The classification is done in accordance with respective welding norm EN ISO 6520-1 The statistical method PCA is applied in order to find redundant features, The artificial neural network was used as a defect group classifier, The real digital radiographs of welded parts of a ship were analyzed
Szczecin, June 2008 6
ADDIPADDIP AAutomatic utomatic DDefect efect DDetection and etection and IIdentification dentification PProcessor (rocessor (ADDIPADDIP) ) is a collection of selected image processing algorithms dedicated for is a collection of selected image processing algorithms dedicated for automatic radiograph analysis. automatic radiograph analysis. The The ADDIPADDIP was created as a programming environment for quick was created as a programming environment for quick and easy testing of newly developed algorithms for defect and easy testing of newly developed algorithms for defect identification and recognition. identification and recognition.
Szczecin, June 2008 7
DATA BASE PREPARATIONDATA BASE PREPARATION
Index defects Calculate features
Generate background Subtract background from
weld image
Detect angle and rotation Crop image Normalize image Detect ROI
PREPROCESING
DEFECT DETECTION
FEATURE CALCULATION
Algorithm of data base preparation using function implemented in ADDIP
Szczecin, June 2008 8
DATA BASE PREPARATIONDATA BASE PREPARATION
Acquired radiograph image with defects
Image after rotation, crop and normalization operations
Szczecin, June 2008 9
DATA BASE PREPARATIONDATA BASE PREPARATION
ROI region detected
Image cropped to ROI region and segmented Flaw 1 Flaw 3Flaw 2 Flaw 4
Szczecin, June 2008 10
DATA BASE PREPARATIONDATA BASE PREPARATIONFlaw 1
Weld image Weld image - background
Thresholded imageIndex image
Szczecin, June 2008 11
DATA BASE PREPARATIONDATA BASE PREPARATIONFlaw 2
Weld image Weld image - background
Thresholded imageIndex image
Szczecin, June 2008 12
DATA BASE PREPARATIONDATA BASE PREPARATIONFlaw 3
Weld image - background
Thresholded imageIndex image
Weld image
Szczecin, June 2008 13
DATA BASE PREPARATIONDATA BASE PREPARATIONFlaw 4
Weld image Weld image - background
Thresholded imageIndex image
Szczecin, June 2008 14
DATA BASE PREPARATIONDATA BASE PREPARATIONType of defects analyzed (according to EN-ISO-6520_1)
101 (6,3%), 102 (2,0%) - Cracks
Example image:
2011 (6,3%) - Porosity and gas pores, 2013 (15,0%) - Clustered porosity, 2015 (8,7%) - Elongated cavities, 2016 (12,8%) – wormholes
Example image:
3011 (17,4%), 3012 (12,8%) - Slag inclusions
Example image:
Szczecin, June 2008 15
DATA BASE PREPARATIONDATA BASE PREPARATIONType of defects analyzed (according to EN-ISO-6520_1)
4011 (12,8%) - Lack of side wall fusion
Example image:
5011 (6,3 %) - Continuous undercut
Example image:
Szczecin, June 2008 16
STATISTICAL ANALYSIS STATISTICAL ANALYSIS Database: over 400 cracks in 20 pictures from Technic-Control
Five groups according to EN-ISO 6520 norm
- Group 1 – cracks
- Group 2 – porosity and gas pores
- Group 3 – slag and inclusions
- Group 4 – lack of fusion, lack of penetration
- Group 5 – continuous undercut
Principal Components Analysis - a quantitatively rigorous method for achieving simplification of dimensionality of database.
Dimensionality of features space: 21
First eight principal components (PC) explain almost 100% of the total variability in the standardized ratings.
Cumulative sum
Szczecin, June 2008 17
STATISTICAL ANALYSIS STATISTICAL ANALYSIS Data separation for eight PC
Szczecin, June 2008 18
STATISTICAL ANALYSIS STATISTICAL ANALYSIS Factor analysis – finding redundant features
1 – Area2 – Perimeter3 – Center of gravity (x)4 – Center of gravity (y)5 – Center of gravity according to brightness (x)6 – Center of gravity according to brightness (y)7 – Longer diagonal of ellipse8 – Second diagonal of ellipse9 – Perpendicular diagonal to longer diagonal10 – Angle11 – Compactness12 – Anisometry13 – Elongation14 – Lengthening15 – Rectangularity16 – Mean Brightness17 – Max Dev of Brightness18 – Ratio19 – Heywood20 – Surroundings21 – Surroundings (mean brightness)
13
10
46
8
919
35
15
1
72121411
18
1620
2117
Visualization of the principal component coefficients for each feature
•Features 4 and 6 are linearly depended
•Features 3 and 5 are linearly depended
•Features 2 and 7 are linearly depended
•Features 16, 20 and 21 are linearly depended
Szczecin, June 2008 19
ARTIFICAL NEURAL NETWORK CLASYFIERARTIFICAL NEURAL NETWORK CLASYFIER
Feature Vector
2015
0
1
0
0
0
Neuron of hidden layer
one hidden layer = 12 neurons
two hidden layers = [15 10] neurons
Neuron of output layer
Output layer = 5 neurons
• Two structures of neural networks were trained, with one hidden layer and with two hidden layer,
• Number of input corresponds to number of features,
• Number of inputs corresponds to number of defect group,
• The Levenberg-Marquardt optimization method was used as a network training function,
• The features database was randomly divided into three sets: 1) a training data set, 2) a validation data set and 3) testing data set.
Artificial neural network structure
Szczecin, June 2008 20
ARTIFICAL NEURAL NETWORK CLASYFIERARTIFICAL NEURAL NETWORK CLASYFIER
In order to evaluate effectiveness of neural network classifier the mean square errorIn order to evaluate effectiveness of neural network classifier the mean square error between output vector and target vector was calculatedbetween output vector and target vector was calculated
21i i
i
MSE Y DN
where Yi – Output vectorDi – Target vectorN – number of samples in each defect
groupi – number of output neurons = 5
Defect group 1 Defect group 2 Defect group 3 Defect group 4 Defect group 5
Training data 0.0179 0.0008 0.0133 0.0068 0.4231
Validation data 1.0593 0.0178 0.2447 0.5181 0.3603
Testing data 1.3452 0.1161 0.7820 1.3122 0.4778
MSE obtained for neural network with two hidden layers
Szczecin, June 2008 21
CONCLUSIONSCONCLUSIONS
• Cracks (group 1) are most separated defects group so easiest to detect,
• The most difficult to distinguish is defect group 4, which can be confused with first, second and third defect group,
• Small error obtained for training data and validation data confirms that the structure of applied NN has been chosen correctly,
• The best results of NN have been achieved for second, third and fifth group of defects, which are porosity and gas pores, slag and inclusions, undercuts respectively,
• Having suitable big training set, it is possible to build semi-automatic system distinguishing among main groups of imperfections