In-depth Analysis and Application of Machine Vision in Product Weld Inspection

2026/03/11 11:12

In modern industrial manufacturing systems, welding is a crucial process for connecting metal components and forming the main structure of products. The quality of welds directly determines the strength, sealing, safety, and service life of products. From automobile bodies and high-speed rail tracks to aerospace vehicles and pressure pipelines, any substandard weld can lead to catastrophic consequences. Therefore, weld inspection is an indispensable quality control in the manufacturing process.


Traditional manual visual inspection relies heavily on the experience and condition of the inspectors, resulting in inherent drawbacks such as low efficiency, inconsistent standards, susceptibility to fatigue, high missed detection rates, and difficulty in quantifying and tracing results. With the advancement of Industry 4.0 and intelligent manufacturing, machine vision, as a non-contact, high-precision, and high-efficiency automated inspection technology, has become a revolutionary tool for improving weld quality control.


I. Core Value and Advantages of Machine Vision Weld Inspection


Compared to traditional methods, machine vision exhibits unparalleled advantages in weld inspection:


1. Objectivity and Consistency: Judgments are based on preset algorithm standards, unaffected by human emotions, experience differences, or subjective biases, ensuring absolute objectivity and consistency in inspection results.


2. High Precision and High Resolution: Modern industrial cameras and lenses can capture surface defects at the micron or even submicron level (such as micropores and cracks), far exceeding the limits of the human eye.


3. High Efficiency and Real-Time Performance: Enables full-speed online inspection on the production line, completing image acquisition, processing, and judgment in milliseconds, meeting the demands of high-speed production cycles and achieving 100% full inspection.


4. Digitalization and Traceability: All inspection processes and results (images, data, NG locations) are automatically recorded, stored, and bound to product identification codes (such as QR codes), forming a complete digital quality archive, facilitating quality traceability, statistical analysis, and process improvement. 5. Non-contact and adaptable to harsh environments: It can operate stably in harsh environments unsuitable for manual work, such as high temperature, high humidity, dust, and toxic substances, protecting personnel safety.


6. Reduced costs: Although there is some initial investment, it can significantly reduce labor and training costs in the long run, and reduce hidden costs such as after-sales maintenance and brand reputation damage caused by missed inspections.


II. Core Components of a Machine Vision Weld Inspection System


A complete machine vision weld inspection system typically consists of the following five main parts:


1. Imaging System:


Industrial Camera: Selected according to inspection requirements. Area scan cameras are suitable for acquiring the overall shape and dimensional measurement of welds; line scan cameras are more suitable for continuous scanning of long, straight welds to obtain ultra-high resolution images. 3D cameras (such as laser profilometers and structured light) are used to acquire three-dimensional geometric information such as the cross-sectional profile, weld reinforcement, concavity, and penetration depth of the weld.


Lens: High-resolution, low-distortion industrial lenses ensure clear and accurate images. Telecentric lenses are often used to eliminate perspective errors and ensure measurement accuracy.


Light Source and Illumination Scheme: This is crucial for success. 1. **Illumination:** Due to the characteristics of welds (typically bright white or dark, undulating surfaces), careful lighting design is required to enhance features and suppress interference. Common solutions include:


▪ Backlighting: Used for contour measurement and detecting penetrating defects.


▪ Coaxial/Dome lighting: Used to detect scratches, dents, and oxidation color differences on flat surfaces.


▪ Low-angle ring/strip lighting: Used to highlight surface texture undulations, undercut, weld beads, etc., in welds.


2. Image Acquisition and Triggering Unit:


Responsible for controlling the camera to take pictures at precise moments (e.g., when the workpiece arrives at the inspection station), ensuring the image position is fixed for subsequent analysis.


3. Image Processing and Analysis System (Core Brain):


Hardware: Typically an industrial PC or embedded vision controller with powerful computing capabilities.


Software: Equipped with machine vision algorithm libraries (such as Halcon, OpenCV, VisionPro) or self-developed algorithms. Core tasks include: image preprocessing (denoising, enhancement, correction), feature extraction, defect identification and classification, dimensional measurement, and result judgment.


4. Mechanical Structure and Motion Control:


This includes the mounting brackets for the camera and light source, adjustment mechanisms, and potentially necessary servo motion platforms (for driving the camera or product scanning). Ensure stable and reliable imaging distance, angle, and field of view.


5. Result Output and Execution Mechanism:


The detection results (OK/NG) are transmitted to the PLC via I/O interfaces or industrial networks (such as Ethernet/IP, PROFINET) to control the sorting mechanisms on the production line (such as cylinders, robots) to remove or mark defective products.


III. Main Detection Content and Core Technology Algorithms


Machine vision applications in weld inspection can be divided into two main categories: two-dimensional appearance inspection and three-dimensional geometric dimension inspection.


1. Two-Dimensional Appearance Defect Detection: Primarily identifies visual anomalies on the weld surface.


• Common defects: porosity, slag inclusions, surface cracks, undercut, weld beads, burn-through, lack of fusion (surface), severe spatter, abnormal surface color (oxidation).


• Core Technologies:


Traditional Image Processing Algorithms: Extract features such as area, perimeter, and location of defect areas through filtering, binarization, edge detection, morphological operations, and blob analysis, and compare them with thresholds for judgment. Suitable for regular defects with obvious contrast.


Defect Detection Based on Deep Learning: This is the current mainstream and cutting-edge direction. Convolutional Neural Network (CNN) models, such as YOLO, Faster R-CNN, and U-Net, are trained using a large number of labeled weld images (positive and negative samples). Deep learning has strong adaptability and ultra-high detection rate for complex backgrounds, irregular defects, and defects with weak contrast, and can automatically classify defect types.


2. 3D Geometric Dimension Detection: Accurately measures the macroscopic geometric parameters of the weld, which directly affect welding strength and mechanical properties.


• Key Dimensions: Weld width, reinforcement height, concavity depth, misalignment, fillet weld leg size, weld width, etc.


• Core Technologies:


Laser Triangulation/Line Laser Scanning: The most commonly used 3D vision technology. A line laser beam is projected onto the weld surface, forming a laser line that deforms along the surface contour. A camera captures this line from another angle, and the height information of each point on the line is calculated using triangulation principles, thus reconstructing the complete 3D contour of the weld. It can accurately output all the aforementioned dimensions and identify problems such as insufficient or excessive weld height, or weld asymmetry.



Structured light 3D imaging: By projecting a series of coded grating patterns onto the weld surface, a camera captures the deformed patterns and calculates high-precision 3D point cloud data, suitable for weld inspection on more complex curved surfaces.


IV. Typical Application Scenarios and Workflows


Example Scenario: Weld inspection on an automotive body welding production line


1. Inspection Task: Online inspection of the surface quality (no cracks, porosity) and continuity of spot welds/laser welds on key parts of the car body, such as A-pillars/B-pillars.


2. System Deployment: Integrating a 3D laser profilometer and a high-resolution area array camera into a single inspection station, carried by a robot or fixed to the production line.


3. Workflow:


Trigger: The vehicle body arrives at the inspection station, and the photoelectric sensor triggers the vision system.


Scanning: The robot, guided by a 3D sensor, scans the weld along a preset trajectory, simultaneously acquiring 3D contour data and 2D texture images.


Processing:


▪ After processing the 3D data, the weld width and excess height are calculated and compared with theoretical values in the CAD model to determine dimensional compliance.


▪ The 2D image is input into a deep learning defect detection model, which identifies and selects any surface defects (such as cracks and porosity) and classifies them.


Decision: The system integrates the 3D dimensional results and 2D defect results to provide a final "pass" or "fail" judgment for the weld.


Execution and Recording: An NG signal is sent to the PLC for marking or alarming at subsequent workstations. All data (images, contour curves, measurements, defect locations) are uploaded to the MES system and linked to the vehicle body's VIN code.


V. Challenges and Future Development Trends


Challenges:


• Complex working conditions: Strong arc light, spatter, fumes, workpiece surface reflection, and oil contamination can severely interfere with imaging quality.


• Diverse weld types: The appearance of welds varies greatly depending on the materials, processes (MIG/MAG, TIG, laser welding), and joint types (butt joint, corner joint, lap joint), posing a challenge to the universality of the algorithm.


• Definition of inspection standards: The acceptance criteria for certain defects (such as micro-splashes and uneven color) are ambiguous, requiring precise quantification of process specifications into algorithm parameters.


• Initial investment and integration complexity: Requires a certain level of technical capability and financial resources from enterprises.


Development Trends:


1. Widespread adoption of AI deep learning: Extending from defect detection to deeper levels such as process parameter optimization and welding quality prediction, achieving a closed loop from "detection" to "control". 2. Multi-sensor information fusion: Integrating information from multiple sources such as 2D vision, 3D vision, infrared thermal imaging (detecting temperature fields), and acoustic emission (detecting internal defects) enables comprehensive evaluation of weld quality, both internally and externally.


3. Integration and miniaturization: Intelligent cameras and embedded vision systems make vision systems easier to deploy, lower in cost, and easier to apply at more workstations.


4. Deep integration with robots: Forming intelligent welding robot units that integrate "vision-guided welding - real-time process monitoring - immediate post-weld inspection," achieving truly adaptive intelligent welding.


5. Cloud platform and big data analytics: Uploading all visual inspection data from the production line to a cloud platform, utilizing big data analytics to uncover potential correlations between welding quality and equipment parameters, material batches, and environmental factors, providing data insights for process optimization and quality prediction.


Conclusion


Machine vision technology is profoundly changing the traditional mode of product weld inspection, upgrading quality control from relying on experience-based judgment based on "human eyes and brains" to precise, digital, and intelligent management based on "photoelectric and algorithmic" methods. It is not merely a simple tool to "replace the human eye," but a core enabling technology for digitizing the welding process, building transparent factories, and driving the transformation to intelligent manufacturing. Although specific technical and engineering challenges remain to be overcome in its implementation, its immense value in improving quality, efficiency, and traceability has already become apparent, making it an irreversible technological trend in high-end manufacturing. With the continuous maturation and cost reduction of technologies such as AI and 3D sensing, machine vision weld inspection will undoubtedly be applied in a wider range of industrial sectors, laying a solid quality foundation for a manufacturing powerhouse.