Abstract
Introduction
Welding spatter is generated by unbalanced metal transfer force in metal inert gas (MIG) welding. Metal transfer is the process by which melted wire is continuously supplied to the weld pool in gas metal arc (GMA) welding. Melted metal is positioned at the end of an electrode by surface tension; an external force greater than the surface tension is applied to the melted metal to break it away from end of the electrode. Normally, force applied to melted metal is classified as gravitational, electromagnetic, plasma drag force. Inadequate welding environments related to the welding current and voltage, shielding gas and the soundness of the welding filler and parent metal affect the balance of the four forces. Welding spatter is then generated because of unbalanced forces.1–10
Several methods have been developed to decrease welding spatter. One such method is simply to monitor the welding process. Schwab et al. obtained raw MIG welding spatter images using a high-speed camera. This imaging process is conducted using inverse light intensity. Welding spatter behavior was established mathematically to predict welding spatter distribution. The relation established in this study was verified using the effects of contaminants in the welding process. 11 Nicolosi et al. conducted spatter monitoring in laser welding. A novel algorithm for real-time spatter detection was implemented using a high-speed camera based on cellular neural networks. The developed algorithm could detect spatter and provide feedback to control welding parameters and decrease spatter ejection. 12 Gao et al. evaluated welding stability based on plume classification and spatter characteristics in disk laser welding. A high-speed camera was used to capture instantaneous images of plumes and spatters. 13 You et al. proposed an effective method for monitoring high-power laser welding; by combining a high-speed camera with ultraviolet and visible band-pass filters, sharp contrast images of a laser-induced plume and spatters were obtained in three welding conditions. Using static and dynamic spatter feature, a time-delay tracking algorithm for spatter detection was designed.14,15 Lahdenoja et al. presented methods for automated visual tracking of spatters in laser and manual arc welding. Their spatter segmentation method is based either on test object elongations or a Hough transform, which are applied on pre-processed image sequences captured by a high-speed smart camera. 16 Schweier et al. took a machine vision approach to spatter tracking in high-speed image series. After a description of the multi-hypothesis tracking method, in which a Kalman filter is used for optimal object status estimation, tracking is applied to high-speed images from an experimental series on laser welding with beam oscillation. 17
Thus far, several methods for spatter behavior and detection in laser welding have used a high-speed camera; however, few works have monitored spatter from arc welding.
In this study, to obtain spatter images, a mobile phone camera was employed instead of a high-speed camera to secure spatter images, which reduce costs. Color correction was applied to clarify the resulting images because of the bright light produced during welding. Welding spatter shape and brightness threshold value based on the processed images were extracted to track and count welding spatter.18–23
Acquisition of spatter images
Experimental setup
Figure 1 shows the measurement setup for acquiring welding spatter images. To capture the spatter images, a mobile phone camera was mounted and positioned above and to the side of the welding area and was set to acquire sequential image from a distance of 0.7 m. Both vertical and horizontal spatter images were captured to obtain two-dimensional spatter images. The spatter images captured vertically are used to determine spatter distribution and the horizontally captured images are used for spatter counting. Spatter images were taken at 240 fps.

Measurement setup for quantification and observation.
The spatter images acquired around the welding arc were mostly distorted due to its brightness. Therefore, an optical filter was selectively used for tracking welding spatter. A neutral-density (ND) optical filter was installed on the digital lens; an ND filter evenly filters incident light across the wave length spectrum, producing clearer images.
Monitoring procedures
Designing tracking algorithms
For simple method, algorithms that include tracking and counting modules were designed. During welding, spatter images were recorded at 240 fps in the welding area for tracking and distribution. The tracking algorithms were initially designed based on the vertically recorded video for two-dimensional spatter traces. Spatter shape was extracted from the captured images. A matching algorithm was then applied, and the spatter traces were fitted on x-y coordinates.
The tracking algorithm was developed in LabVIEW (National Instruments Corp.). The IMAQ Create module was used to temporarily store images and determine the width of the border to create around an image in pixels for 8 bit/pixel grayscale images. Image sequence acquisition was easily conducted using Vision Acquisition Express without any specialization. IMAQ Extract Single Color Plane was applied to the color plane intensity to clarify the spatter images; subsequently, Vision Assistant Express was used to register the spatter shapes based on the pre-processed spatter images. Figure 2 describes the steps involved in processing the images and extracting the shape of welding spatter. Clear spatter images were derived from grayscale images; unnecessary areas were eliminated from regions of interest in Vision Assistant Express.

Spatter shape extraction for tracking.
One-dimensional spatter image data were converted to an element cluster of the same type as the array elements; next, the element was appended to an n-dimensional array for plotting. The processed image data were used as the boundary. Simultaneously, the spatter pattern was plotted on x-y coordinates using the math script module to produce a welding spatter trace. Figure 3 shows the steps of spatter tracking algorithms based on developed LabVIEW code.

Screenshots acquired during image processing for determining spatter distribution: (a) image acquisition with pattern matching, (b) spatter pattern overlay, and (c) plotting commands.
Designing counting algorithms
Figure 4(a) and (b) presents the simple principle of color correction and an example corrected image, respectively. Color correction was applied to clarify the spatter images using the LabVIEW vision module. The welding arc and spatter have similar RGB values to white light, although spatter has lower green and blue values than the welding arc; thus, the red, green, and blue planes are properly applied according to the images so that the spatter images have higher values.

Simple principle of color correction: (a) method of color correction and (b) example corrected image.
To establish the counting algorithms, grayscale color correction was initially applied to produce binary spatter images. Next, red, green, and blue filters were applied to brighten and clarify the spatter images based on their RGB values. The required brightness threshold was set when counting the number of spatters via object detection. The arc was excluded from the image based on its substantially larger area.
To develop the counting algorithm, a Vision Builder AI was used to enable automatic algorithm generation without advanced knowledge of LabVIEW program. First, sequential images were used for counting, with a method similar to the tracking process. A red filter was applied to brighten and clear the spatter images before setting a brightness threshold value. However, the arc, which had a similar brightness to the spatter, was captured during welding. Therefore, the area outside the threshold value range was deleted. Finally, the amount of spatter in each image was obtained. Figure 5 shows the steps of the counting algorithms, and Figure 6 shows a flow chart of the simple spatter monitoring method.

Process of counting welding spatter.

Monitoring algorithm for spatter amount and distribution.
Developed tracking and counting panel
Reviewing the images obtained from the welding experiments, it was observed that all spatters were too fast to be recorded, so they did not have a clear shape. Therefore, constant shapes from the image sequences were obtained and several spatters could be matched. The developed tracking algorithm implemented to observe welding spatter was based on registered spatter shapes and obtains the scattered spatter traces. It displays green dots that represent the spatter trace via its behavior in x-y coordinates. Figure 7 shows the monitoring panel and resulting spatter distribution in x-y coordinates. The counting algorithm then counted the number of spatters within the red boundaries in the images. Figure 8 shows the spatter counting monitoring panel. After counting the welding spatter, the number of welding spatters produced is shown under the panel.

Monitoring panel for tracking and corresponding trace measurements.

Monitoring panel for counting.
Verification of spatter monitoring results
Analysis of counting results
Welding experiment was conducted to verify the method and algorithms. The two MIG welding machines used in this study were TPSi 360c and VR7000-CMT (Fronius). Welding conditions from previous welding experiments were utilized. 24 The cold metal transfer (CMT) and pulse processes were used for bead on-plate welding. The welding conditions were a current of 70 A, a speed of 80 cm/min, and a torch angle of 70°. The materials employed were SGARC340 (galvanized steel), commonly used in the automobile industry, and SM45C (mild structural steel). The specimen sizes were 100 mm × 100 mm × 1.2 mm. The welding wire used was ER70s-3. The LabVIEW vision module and builder were used to establish the algorithm code.
Confirming the spatter distribution via tracking, it was found that the spatter distribution was elliptical, with arc plasma at its center. Also, the maximum distance was 0.4 m in the x-direction and 0.3 m in the y-direction.
As a result of counting by the simple monitoring method, the number of spatters per frame was 25 and 45 in CMT and pulse mode, respectively. To verify the simple monitoring method, a spatter collection experiment was conducted. A spatter curtain was installed to contain the spatter, and it was collected manually. The weight of the spatters from each welding process was measured, as shown in Figure 9; Figure 10 displays the spatter count monitoring results. Comparing the two methods, Figure 11 shows that the ratios of spatter amounts for the two modes observed with the simple monitoring method were similar to those obtained via manual collection. The weight of the welding spatters from the simple monitoring method was calculated based on density and the measured spatter radius.

Manual collection of welding spatters.

Spatter amounts during welding: (a) CMT process and (b) pulse process.

Comparison between the simple and manual method.
Conclusion
In this study, a simple method was implemented to monitor welding spatter for quantification and observation, and verifying experiments were performed using a mobile phone camera. The amount of spatter per frame was evaluated by applying the vision module to welding images. In CMT and pulse modes, spatter amounts were measured by developed method, and it was confirmed that spatter counting trends are consistent with the manual method. In addition, several spatters with constant shapes were detected in video and plotted on x-y coordinates. As a result, welding spatters were scattered approximately 0.4 m in the x-direction and 0.3 m in the y-direction from the center of the welding arc. One thing to note is that fast shutter speeds make it easy to find the shape of welding spatters; therefore, choosing a proper shutter speed is important for obtaining whole spatter traces and good monitoring results. Finally, the proposed monitoring method has practical potential for quantifying and tracking spatter. Thus, it is expected that technique developed in this article can be applied to future studies related to the behavior of welding spatter.
