1.1 Overview of Project:: "Application of Convolutional Neural Network in Defect Detection of 3C Products"
1.1 Overview of Project:: "Application of Convolutional Neural Network in Defect Detection of 3C Products"
CHAPTER 1
INTRODUCTION
1.1 Overview of project:
With the continuous improvement of science and technology, the intelligent, automated, and
unmanned manufacturing industry will be an inevitable trend in the future. As an important
form of metal materials, metal work pieces are widely used in daily life and industrial
production by virtue of their excellent mechanical and physical properties. In the production
process of the product, due to the influence of equipment and technology, different kinds of
defects often appear on the surface of the product, such as scratches, holes, and cracks in the
metal work piece.
The surface quality of metal work pieces not only affects the appearance and image of
the product, but may also affect the functional characteristics of the product and cause
significant losses to the enterprise. Therefore, it is very necessary to detect the surface defects
of the product, and it is particularly important to design a real-time and effective surface
defect detection method for metal work pieces. Conventional non-destructive inspection
methods for surface defects of metal work pieces include magnetic particle inspection,
penetrant inspection, infrared thermal imaging inspection, ultrasonic inspection, visual
inspection, etc. Machine vision inspection technology is constantly being used in inspections
in various fields. Machine vision inspection mainly uses high-resolution industrial cameras to
obtain images of specimens to be inspected, and uses digital image processing inspection
algorithms to complete the inspection of defects.
The visual inspection is a non-contact inspection, and it will not cause any damage to the
work piece to be inspected during inspection. At the same time, the visual inspection has a
high degree of automation, which can be realized for a long time and work continuously and
smoothly. In recent years, research on artificial intelligence technology has continued to
deepen, and machine learning and deep learning methods have been rapidly developed, and
have been gradually applied in various fields, providing a new method for solving the
detection problem of metal work piece surface defects.
Deep learning can directly learn two-dimensional images, reducing image pre-
processing, without manually extracting features, and can automatically learn more
appropriate features layer by layer, greatly reducing the impact of human factors. With the
development of
DEPT OF IS&E, AIT, CHIKKAMAGALUR PAGE 1
“Application of Convolutional Neural Network in Defect Detection of 3C Products”
Machine vision technology, researchers use image processing to detect screen defects of 3C
products. Proposed an algorithm combining the line intercept as the threshold and particle
swarm optimization, which solved the problem of low detection accuracy of mobile phone
screen defects. Improved the median filter algorithm and utilized the image processing
algorithm to pre-process the defective image. In addition, they proposed an image difference
algorithm based on fast image matching for detection. Z hang et al posed an improved
differential image detection method for mobile phone screen defects to improve detection
efficiency and accuracy. However, the performance of pure image processing technology
cannot achieve satisfactory detection results.
The main content of this method is to review the surface defect detection methods with
different levels of CNN in 3C products such as glass display screens, PCBs and TFT-LCD
screens. Then, the detection methods and the problems of various methods are summarized
and discussed. First, we outline the types of defects in 3C products and the comparison of
different detection methods in the context of Industry 4.0. Subsequently, the improved CNN
structures in various scenarios are compared, and the technical limitations and detection
performance of different methods in practical applications are shown. This research
summarized and compared noteworthy research based on CNN in recent years to overcome
the challenges of surface defect detection in 3C products.
CHAPTER 2
PROBLEM DEFINITION
CHAPTER 3
LITERATURE SURVEY
(1) ‘‘Defect detection of mobile phone screen based on improved difference image
method’
Using the CNN to defect detection of product. CNN is a feed forward neural network.
CNN consist of one or more convolutional layers and fully connected layers, as well as
associated weights and pooling layers. Literature is a very popular LeNet convolution
neural network structure. LeNet network structure can be used to detect defects in two
situations: one is to design a complex multi-layer CNN structure, use different network
structure to extra image content features, and complete end-to-end training to detect
defects in images; the other is to combine CNN with CRF model, train CNN with CRF
energy function as constraint or optimize network prediction results with CRF. And to
achieve the detection of product defects
(2) Peng, Y.; Liu, G.; Quan, Y.; Zeng, Q. The depth measurement of internal defect
based on laser speckle shearing interference. Opt. Laser Technol. 2017,92, 69–73
Using the CNN to defect detection of product. CNN is a feedforward neural network.
CNN consist of one or more convolutional layers and fully connected layers, as well as
associated weights and pooling layers. Literature is a very popular LeNet convolution
neural network structure. LeNet network structure can be used to detect defects in two
situations: one is to design a complex multi-layer CNN structure, use different network
structure to extra image content features, and complete end-to-end training to detect
defects in images; the other is to combine CNN with CRF model, train CNN with CRF
energy function as constraint or optimize network prediction results with CRF. And to
achieve the detection of product defects
(3) Xiao, X.; Yu, L.; Dong, Z.; Mbelek, R.; Xu, K.; Lei, C.; Zhong, W.; Lu, F.; Xing,
M. Adipose stem cell-laden injectable thermosensitive hydrogel reconstructing
depressed defects in rats: Filler and scaffold. J. Mater.Chem. B 2015,27, 5635–
5644.
DEPT OF IS&E, AIT, CHIKKAMAGALUR PAGE 5
“Application of Convolutional Neural Network in Defect Detection of 3C Products”
(4) Hui, K.; Jian, Y.; Chen, Z. Accurate and Efficient Inspection of Speckle and
Scratch Defects on Surfaces of Planar Products. IEEE Trans. Ind. Inform. 2017,4,
1855–1865.
The product defect-detection technology of deep residual neural network. The deep
residual network adds a residual module on the basis of the convolutional neural
network. The residual network is characterized by easy optimization and can improve
the accuracy by increasing the network depth. CNN, Generative Adversarial Networks,
etc. with the depth of the network increases, the extraction feature increases, but it is
easy to cause the activation function not to converge.
(5) Chen, J.; Li, C. Prediction and Control of Thermal Scratch Defect on Surface of
Strip in Tandem Cold Rolling. J. Iron Steel Res. Int. 2015,22, 106–114.
Full convolution neural network. The fully connected layer is a connection between any
two nodes between two adjacent layers. A fully connected neural network uses a fully
connected operation, so there will be more weight values, which also means that the
network will take up more memory and calculations. During the calculation of the fully
connected neural network, the feature map generated by the convolution layer is
mapped into a fixed-length feature vector
CHAPTER 4
SYSTEM SPECIFICATION
CHAPTER 5
METHODOLOGY
pieces. The convolutional neural network structure designed in this method. The first layer is
the input layer, and the input data is a 128*128 grayscale image. Next is the alternating
connection of the three convolutional layers and the pooling layer. The feature filters used in
the convolutional layers are all the same in size. The S3 layer outputs the final two-dimensional
feature map, and maps the two-dimensional feature map to a one-dimensional vector as the
input of the fully connected layer.
The SoftMax classifier classifies the output of the fully connected layer. It is equivalent to a
multi-class logistic regression. The result is the position corresponding to the largest component
output by the classifier. The training process of the network mainly involves the calculation of
forward propagation and back propagation of the network. Forward propagation reflects the
transfer of characteristic information, while back propagation reflects the correction of model
parameters by error information.
When the amount of data is insufficient or the network complexity is large, the training error of
the model will decrease and tend to zero, and the test error will first decrease and then increase.
The model can recognize the training samples very well, but the recognition effect on the test
samples is not very satisfactory, that is, over fitting occurs. Therefore, a regularization model
can be selected, and a regularization attenuation term or penalty term is added to the empirical
risk. The attenuation term will penalize too large parameter values to prevent over fitting.
The YOLO algorithm is a one-stage object detection algorithm characterized by the direct
regression of the location and category of an object after feature extraction. It has the
advantages of fast inference speed and high detection accuracy. The author of the YOLO
algorithm then proposed the YOLOv2 and YOLOv3 models successively, and their
performance showed continuous improvements. In 2020, Alexey Bochkovskiy proposed the
YOLOv4 algorithm, which modified the backbone network to CSPDarknet53, replaced the
activation function with Mish and added a PANet structure based on the FPN from YOLOv3.
The YOLOv5 model has been improved on the basis of YOLOv4, with the detection speed
being significantly improved and the model size greatly reduced, and it is more suitable for
engineering applications.
The YOLOv5 algorithm has four models: YOLOv5s, YOLOv5m, YOLOv5l and
YOLOv5x. The depth and width of these models increase in turn, and the feature extraction
ability also gradually improves. Considering that our algorithm was intended to be deployed
and applied in mobile terminals in the future, we selected the lightest YOLOv5s network as the
research object, improved it on the basis of our needs and established a model for detection of
surface defects in aero-engine components.
YOLOv5 is mainly composed of three parts: the backbone, neck and head. The backbone
consists of a series of convolutional neural networks used to extract image features, mainly
focus, C3 and SPP modules. The focus module slices the images and splices them into the
channel dimension to integrate the width and height information into the channel dimension,
which can effectively improve the speed of feature extraction. The C3 module is improved from
the structure of the cross-stage partial (CSP) connections, having one less convolution layer and
changing the activation function, and its main function is to extract features from images and
reduce the repetition of gradient information. The spatial pyramid pooling (SPP) module
respectively uses three pooling kernels of sizes 5, 9 and 13 to perform max-pooling operations
on the images. This module can increase the receptive field of the network and obtain features
of different scales. The neck is the feature fusion network of the model, where feature pyramid
networks (FPNs) and path aggregation network (PANet) are adopted. The structure of the FPNs
transmits semantic information from the top down, while the PANet additionally transmits
location information from the bottom up on the basis of the FPNs. The head is the prediction
network of the model and, through convolution operations, three groups of feature vectors
containing the categories prediction boxes, confidence and coordinate position are output,
which predict at scales of 80 × 80, 40 × 40 and 20 × 20, respectively.
The architecture of YOLOv5s is shown in Figure1.2, where k represents the convolution
kernel size, C3(T) represents the C3 module containing a residual structure, C3(F) does not
contain a residual structure, Upsample is the upsampling operation and CBS is the standard
convolution process consisting of Conv (the convolution layer), BN (batch normalization) and
SiLu (activation function).
CHAPTER 6
CONCLUSION
REFERENCES
[1] J. Zhang, Y. Li, C. Zuo, and M. Xing, ‘‘Defect detection of mobile phone screen based on
improved difference image method,’’ in Proc. Int. Conf. Intel. In format. Biomed. Sci.
(ICIIBMS), Nov. 2019, pp. 86–92.
[2] Peng, Y.; Liu, G.; Quan, Y.; Zeng, Q. The depth measurement of internal defect based on
laser speckle shearing interference. Opt. Laser Technol. 2017,92, 69–73
[3] Xiao, X.; Yu, L.; Dong, Z.; Mbelek, R.; Xu, K.; Lei, C.; Zhong, W.; Lu, F.; Xing, M.
Adipose stem cell-laden injectable thermosensitive hydrogel reconstructing depressed defects
in rats: Filler and scaffold. J. Mater.Chem. B 2015,27, 5635–5644.
[4] Hui, K.; Jian, Y.; Chen, Z. Accurate and Efficient Inspection of Speckle and Scratch
Defects on Surfaces of Planar Products. IEEE Trans. Ind. Inform. 2017,4, 1855–1865.
[5] Chen, J.; Li, C. Prediction and Control of Thermal Scratch Defect on Surface of Strip in
Tandem Cold Rolling. J. Iron Steel Res. Int. 2015,22, 106–114.
[6] B.Z. Chen, Z.H. Fang, Y. Xia, etc. Automatic detection of pore defects in thick steel pipe
welds based on X-ray images. Computer Applications, 2017, 37(03): 849-853.
[7] X.L. Qian, H.Q. Zhang, Y.X. Chen, etc. Research status and prospect of surface defect
detection for solar cells based on machine vision. Journal of Beijing University of
Technology, 2017, 43(01): 76-85.
[8] L.Z. Zhu, M.Y. Chen. A Research on Auto Glue Defect Detection Based on Machine
Learning. Journal of Shenyang Ligong University, 2018, 37(04): 18-22.
[9] L. Guo, L. Shu, G.C. Wu. Detection method of arc-extinguishing grid surface defects
based on machine learning. Mechanical Engineering and Automation, 2019(01): 4-7.
[10] C. Wang, Y.T. Liu, X.Y. Xu, et al. Research on magnetic tile defect detection based on
convolutional neural network. Journal of Dalian Nationalities University, 2019, 21(03): 220-
224.
[11]J .C. Hu, X.Y. Wang, H. Liu. Surface defect detection of continuous casting slab based on
deep learning. Journal of Shanghai University (Natural Science Edition), 2019, 25(04): 445-
452.