Local binary pattern defect recognition approach for the friction stir welded AA 1200 and AA 6061-T6 aluminum alloy

The research reported in this paper focuses on the application of local binary patterns (LBPs) for surface defects detection. The surface defection detection algorithm for friction stir welded aluminum plates is the key part of the entire surface defect recognition system. Two different grades i.e AA 1200 and AA 6061 plates were similarly joined with the help of Friction Stir Welding process. Python codes for the proposed algorithm were executed on Google Colaboratory platform. The results obtained prove that the local binary patterns method can be used for real-time surface defects detection in friction stir welded joints.


INTRODUCTION
Aluminum alloys are the core materials which find various applications in aerospace industries. While operating under adverse conditions, the aerospace materials must carry the structural and aerodynamic loads and also should not crack, corrode, oxidize or suffer other forms of damage which involves high loads, freezing and high temperatures [1]. In critical weight applications, high strength to weight ratio favors the selection of aluminum alloys. The main issue arises during the joining process of these alloys by conventional welding process. Friction Stir Welding process overcomes this difficulty and produces a sound joint without melting the parent metal alloys [2]. Friction Stir Welding is a solid state joining process which was invented by The Welding Institute (TWI) in 1991. This technology is ecofriendly and energy efficient [3]. The experimental demonstration of Friction Stir Welding process is shown in the Figure 1. Friction Stir Welding tool at a certain rotational speed is plunged at the welding line and given a traverse speed along the weld line. Tool material is harder than the parent material to be joined.  [4] However, the welded joints obtained by Friction Stir Welding process are not defects free. Friction-stir welding is still susceptible to flaw formation because it lacks the potential for imbalances between the distinct processing zones. Defects such as nonbonding or void formation can occur at very cold welding conditions, due to insufficient material flow, and flaws such as flash formation, collapse of the nugget within the stir zone and deterioration in the strength properties of the joint can occur at very hot conditions, due to excessive material flow [5].
In this study, a machine learning based approach is used for the identification of surface defects in friction stir welded joints. In order to automate the surface defect inspection process where the main goal is to detect and identify defects, Computer vision techniques have been widely used.
Local Binary Pattern (LBP) is an image descriptor which finds applications in computer vision like facial expression recognition, face recognition, modeling motion and actions as well as in medical image analysis. The texture descriptor is used to describe the coarseness, regularity, and directionality of patterns in texture images [6][7][8][9]. Local Binary Pattern (LBP) is one of the descriptors used for understanding the images. For obtaining the Local Binary Pattern (LBP) of a given image, the given image should be converted to a Grayscale image. Once the grayscale image is obtained, we get the texture distributor consisting of various descriptive vectors as shown in the Figure 2.
The yellow highlighted region shown in the texture distributor matrix is the centroid of the pixel, while 10, 5, 4, 6, 7, 4, 1, and 3 are the descriptive vectors (Tab. 1). The main idea of the Local Binary Pattern (LBP) is that if the neighbour value is greater than the center value then replace it by 1 and if it is less than the center value put 0. Noise is an uncertainity in image which is sensed by any image analysis instrument. Song et al.
[10] proposed a robust feature Local Binary Pattern (LBP) Descriptor to prevent a noise called the AECLBP while the defect recognition from the hot rolled steel strip. Ko et al.
[11] also used Local Binary Pattern (LBP) for defect detection in polycrystalline solar wafers. It was observed that compared to other related methods, the LBP method has an advantage for identifying various low gray level defects.

MATERIALS AND METHODS
In the present work, Aluminium alloy 6061 T5 plates and AA 1200 plates were joined. The application of both alloys are depicted in Table 2. The base alloy plate of the dimensions 150×100×6 mm was mounted tightly on the CNC bed with the help of fixture. The main purpose of the fixture is to help the both workpiece in a proper grip so that they do not dislocate from their original position while carrying out the Friction Stir Welding Process. Tool material for joining the plates is H13. The cylindrical tool design profile was used for joining the plates. Input parameters used to join the plates are tool rotational speed, traverse speed and axial force. Tool rotational speed, traverse speed and axial force used are 1500 rpm, 400 mm/min and 2.5 KN. Digital image of the friction stir welded samples were captured using the digital camera. The captured images shown in the Figure 3 and 4 were then stored in the computer system for the image processing. In our case study, we have used PYTHON programming language for the coding purpose on the Google Colaboratory platform. The python libraries used for image processing in the code are numpy, matplotlib and cv2. The digital image were cropped to the resolution of 1511×2237 pixels for obtaining the low level gray image which were further converted to local binary patterns and histogram for each obtained local binary patterns were plotted.

RESULTS AND DISCUSSION
In the Python code, a function is created to obtain the Local Binary Pattern (LBP) of the given images. The size of the kernel taken is 3×3. The subplot of the grayscale, Local Binary Pattern (LBP) and histogram for the given samples are shown in the Figure 5 and Figure 6.
From Figure 4 it is observed that there is a discontinuity in the pixel of the LBP image which is marked by yellow rectangle. It can be due to improper selection of the input parameters which results surface defect at the welding line due to poor mixing and flowability of the material alloy. On the other hand from Fig. 5 the subplots reveal the good texture of the welded joints which means there is absence of any type of surface defects in the respective samples.

CONCLUSIONS
Local Binary Pattern (LBP) images can successfully detect the non-homogeneity in the respective images of the friction stir welded joints. The main objective of the research is to observe the location of any type of surface defects present in the friction stir welded joints. With the help of obtained Local Binary Pattern images, the input parameters can be modified further to obtain sound quality of welded joints. It can be concluded that the Local Binary Pattern (LBP) images can be used as a powerful texture descriptor. However, some further improvement is needed in enhancing the algorithm because Local Binary Pattern is unable to extract texture feature in a large size and structure.