Abstract
In high-speed manufacturing, transitioning from manual to automated surface inspection requires balancing model accuracy with strict latency constraints. This paper presents a practical implementation of a CNN-based defect detection system for weld nuts at Frontec. By utilizing Circular Hough Transform for region-of-interest extraction and a persistent VGG-16 model architecture, the system achieves a 0.14-second response time and over 99% accuracy. The deployment resulted in significant labor cost savings and improved aesthetic quality control.
Introduction: The Challenge of Aesthetic Quality
In the automotive parts industry, functional quality—ensuring a part fits and works—is no longer the sole metric of success. Customers increasingly demand "aesthetic" quality, where minor surface scratches, "bursts," or struck marks are considered unacceptable defects.
Frontec, a South Korean manufacturer, faced the challenge of automating the inspection of these subtle surface damages. While existing vision systems could verify dimensions and thread presence, they struggled with surface irregularities. This necessitated manual inspection by human workers, a process prone to inconsistency due to eye fatigue and subjective judgment. To replace this with AI, the solution had to meet three critical industrial constraints:
- Latency: Classification must occur in under 0.2 seconds to match production line speeds.
- Integration: The system must interface with existing LabVIEW-based hardware.
- Efficiency: Processing high-resolution (2MP) images in real-time requires significant optimization.
Data and Defect Classification
The researchers compiled a custom dataset of weld nut images captured directly from the factory line. The dataset included 1,198 images of the upper side and 2,031 images of the underside, covering various defect categories.
Defects were categorized into types such as "Burst" (cracks on the edge), "Struck" (surface indentations), and "Internal Chip" (debris within the threading). To enhance model robustness, the training data was augmented using random rotations and flips to improve generalization.
Technical Implementation
The core of the solution lies in a multi-stage pipeline designed to bridge the gap between computationally intensive deep learning and high-speed industrial requirements.
Preprocessing and ROI Extraction
Processing a full 1920x1600 image through a CNN is too slow for a 0.2-second window. The team implemented a preprocessing stage using the Circular Hough Transform (CHT) to locate the nut within the frame.
As shown in the figure above, the system applies a binary threshold and Gaussian blur before using CHT to find the circular boundary of the nut. This allows the system to crop a 750x750 region of interest (ROI) and downsample it to 224x224, drastically reducing the input size for the neural network.
Model Architecture and Persistence
The team compared several architectures, ultimately selecting an adjusted VGG-16 model. While heavier than simpler CNNs, it provided superior accuracy and generalization when combined with a 50% Dropout rate.
To overcome the "initialization lag" of loading a large model (which can take several seconds), the authors implemented a TCP/IP client-server architecture. The CNN runs as a local server, keeping the model "warm" in RAM. When the LabVIEW-based vision inspector captures an image, it sends the ROI to the Python-based AI server, receiving a classification almost instantaneously.
Performance and Economic Impact
The deployed system exceeded all performance targets:
- Accuracy: Achieved >99%, surpassing the initial 95% requirement.
- Speed: Total inference and communication time was clocked at 0.14 seconds.
- Economic Benefit: The system saves the company approximately $20,000 per month by reducing labor costs by $16,000 and failure costs by $4,000.
Conclusion
This project demonstrates that successful industrial AI deployment depends as much on classical computer vision and software engineering as it does on neural network design. By using CHT to prune the search space and maintaining a persistent model server, Frontec successfully automated a complex manual task. Future work will explore using this real-time defect data for predictive maintenance, identifying machine wear before it leads to production failures.
Summary updated