# Research on Seamless Fabric Defect Detection Based on Improved YOLOv8n
## 1 Introduction  
Surface defect detection of fabrics is a crucial step in the textile industry, with the aim of promptly detecting defects in the fabric to ensure product quality [1]. At present, most textile manufacturing industries still use manual visual inspection methods to control fabric quality [2]. This method has many problems, such as low efficiency, time-consuming, error-prone, missed or misjudged detection, and a significant threat to human health, especially visual health. This traditional manual defect detection method cannot meet the requirements of real-time and efficiency [3]. Some current automated detection methods still require manually designed feature expression methods, which have certain limitations. In recent years, the superior performance of computer vision technology in image processing and other fields has been widely used for fabric defect detection [4, 5]. [PERSON] et al. proposed an unsupervised fabric defect detection method that generates multi-level saliency values by convolving color histograms with pixel values. This method can greatlysuppress background information by fusing multi-level saliency [6]. To solve the problems of poor model generalization ability and blurry edge detection, [PERSON] et al. proposed a novel network called \"U-SMR Net\", which includes a lightweight multi-scale feature extraction module [7]. [PERSON] et al. studied a hybrid mutation moth flame optimization with deep learning-based smart fabric defect detection (HMFODL-FDD) technology, which utilizes computer vision (CV) and deep learning (DL) techniques to detect defects in fabrics [8]. [PERSON] et al. used the LSTM method to identify defects in fabrics and classified the patterns and percentages of defects present in the fabrics [9]. In order to apply the automatic fabric defect detection system to the production site, [PERSON] et al. proposed a cloud-edge collaborative fabric defect detection system [10]. [PERSON] et al. proposed a lightweight fabric defect detection architecture based on CNN, which has a faster training speed while reducing graphics processing unit and memory consumption [11]. A new method using an integral image scheme to solve the problem of fabric defect detection has been proposed, replacing a large amount of computation in NCC to speed up the calculation process, and the defect detection process can be completed in real-time [4]. [PERSON] et al. proposed a dual sparse low-rank decomposition method for defect detection of complex and irregular printed fabrics, which better preserves the shape details of defects [12]. To solve the problem of texture interference, [PERSON] et al. utilized the advantages of Gabor filters in frequency analysis and improved the Faster R-CNN model by embedding Gabor kernels into Faster R-CNN [13]. [PERSON] et al. proposed an effective weakly supervised shallow network called DLSE-Net, which includes a Link-SE module and Dilation Up-Weight CAM for fabric defect detection [14]. [PERSON] et al. proposed a fabric defect detection method based on Mobile-UNet, which uses a median frequency balance loss function to handle sample imbalance and adopts deep separable convolution to significantly reduce network complexity and model size [15]. [PERSON] et al. proposed an adaptive fabric defect detection method based on the DenseNet-SSD algorithm, aiming to improve detection performance. This method replaces the VGG16 backbone network in the SSD algorithm with a DenseNet network, which enhances the transfer of feature maps, effectively alleviates the gradient vanishing problem, and reduces the number of network parameters [16]. [PERSON] et al. proposed a compact convolutional neural network architecture that utilizes several microarchitectures with multi-layer perceptron to optimize the network for detecting several common fabric defects [17]. [PERSON] et al. proposed an algorithm for detecting texture defects in uniform and structured fabrics, which consists of two stages: feature extraction and defect recognition.