# Detection of Defects in Warp Knitted Fabrics Based on Local Feature Scale Adaptive Comparison
## 3 Experiment and Result Analysis
### Verification of Images Collected by the Factory  
In order to further verify the rationality of the methods in this chapter, factory experiments were carried out. On the cloth inspection machine, a linear CCD camera was used to collect warp knitted fabrics under different tissues (considering the actual production cost of the textile mill). The experimental device is shown in Figure 12. The CCD camera was a Hikvision MV-CS060-10 GM/GC second-generation industrial area scan camera; the light source system selects the LED lamp with the model MV-LLDS-1002-38 as the system light source, the number of lamp beads is 6 rows, the wavelength B: 465 nm, R: 625 nm, the light-emitting surface size is 990 \(\times\) 32 mm, and the color temperature W: 6500 k; the frame grabber is NIPCIe-1433.  
A total of 200 gray-scale images with a resolution of 2568 \(\times\) 40 pixels were collected, including 115 flawless images and 85 defective images. The collected pictures are used for the offline test. The experimental results are shown in Figures 13-15. This experiment uses an experimental window with a central area size of 11 \(\times\) 39 pixels. The experiments are carried out under the environment of matlab2023a. The pad number of plain weave in Figure 14 is Gb3: 1-0 \(|\) 0-1 \(|\) gb4: 1-2 \(|\) 1-0 \(|\), the pad number of twill weave in Figure 13 is Gb3: 1-0 \(|\) 1-2 \(|\) gb4: 1-2 \(|\) 1-0 \(|\), and the pad number of variable warp weave in Figure 12 is Gb3: 1-0 \(|\) 1243-4 \(|\). Let off volume: 1200 mm/rack, pulling density: 20 rows/cm.  
Figures 13-15 are defect images and detection results of different yarn breaking parts under different tissues. The left broken yarn defect image has a tendency to tilt to the right, the middle broken yarn defect image is a vertical bar, and the right broken yarn is inclined to the left. It can be seen from the yarn breaking diagram on the left that when the yarn breaking starts, the defect image is not very obvious and the image is relatively small, but the detection results show that the algorithm can clearly identify the existence of defects and effectively avoid long defects. As the defect range after yarn breaking is different for  
\begin{table}
\begin{tabular}{c c c c c c c} \hline \hline \multirow{2}{*}{**Mode**} & \multirow{2}{*}{**Acc (\%)**} & \multirow{2}{*}{**Params (M)**} & \multirow{2}{*}{**Flops (M)**} & \multirow{2}{*}{**Mem (MB)**} & \multicolumn{2}{c}{**Time/ms**} \\ \cline{5-6}  & & & & & **CPU** & **GPU** \\ \hline LBPs & 97.06 & 21.18 & 3.56 G & 37.61 & 63.99 & 7.46 \\ LCD & 96.00 & 0.25 & 34.44 & 10.12 & 8.11 & 1.73 \\ Proposed method & 99.89 & 0.18 & 34.44 & 10.12 & 8.12 & 1.77 \\ \hline \hline \end{tabular}
\end{table}
Table 1: Comparison of network model inference performance.  
Figure 12: Fabric defect detection platform. (**a**) Defect detection system, (**b**) defect detection view.  
Figure 13: Detection results of plain weave defects.  
different fabrics, it can be seen from the above figure that this method has a good detection effect for different fabrics, which shows that the algorithm used in this paper can adapt to the defect detection of different fabrics and has high robustness.  
The image in Figure 15 is affected by light during acquisition, which shows that this algorithm can adapt to defect detection under the influence of external factors and has certain anti-interference performance.