Intelligent cloth inspection detection method and system for textile fabric production
By adjusting the characteristics of the light intensity and the division pattern area, the method of extraction of the characteristics of the division pattern solves the problem of insufficient detection of complex pattern fabric defects in existing technologies, and achieves higher detection accuracy and lower labor costs.
Patent Information
- Application Number
- CN202411932873.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-26
- Publication Date
- 2025-01-24
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The prior art is difficult to accurately detect defects in fabrics with complex patterns, especially in small differences in color and structure, which are susceptible to the impact of the detection environment and lead to false detection, which reduces the accuracy of the detection.
By obtaining the cloth characteristics and ambient light intensity of the cloth to be inspected, the light intensity of the lighting on the cloth inspection machine is adjusted, and the cloth surface defect detection model is used to segment the pattern area and non-pattern area, and the image features of each area are extracted for defect detection.
It improves the accuracy of defect detection on fabrics with complex patterns, ensures that defects are clearly visible under the most appropriate lighting conditions, and avoids the complexity of pattern areas from affecting defect detection in non-pattern areas.
Smart Images

Figure CN119359728A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of cloth defect detection, and in particular to an intelligent cloth inspection method and system for textile production. Background Art
[0002] In the modern textile industry, with the continuous expansion of production scale and the increase of production speed, the quality control of textiles has become a crucial link. Especially in the fabric production process, the quality of the fabric directly affects the quality of the final product. Therefore, it is necessary to detect defects such as oil stains and weaving dislocation on the fabric to ensure the quality of the fabric.
[0003] With the development of image processing technology and artificial intelligence algorithms, automated inspection systems have gradually become a new trend in the textile industry. These systems usually use high-speed cameras, optical sensors and advanced algorithms to inspect fabrics in real time. Intelligent fabric inspection methods can not only identify surface defects in fabrics, but also deeper structural defects by using computer vision and machine learning. They can provide higher detection accuracy, faster processing speed and lower labor costs in the production process of fabrics.
[0004] Currently, most methods for fabric defect detection are to detect fabrics with solid colors or simple patterns. Although this method can detect textile defects, the texture of fabrics with complex patterns has certain variability and irregularity. The defects of such fabrics also include slight differences in color and structure. These slight defects will be affected by the detection environment and lead to false detection, thereby reducing the accuracy of fabric detection.
[0005] To this end, an intelligent cloth inspection method and system for textile production are proposed. Summary of the invention
[0006] The purpose of the present invention is to provide an intelligent cloth inspection method and system for textile production. First, cloth inspection parameters are obtained according to the cloth characteristics and ambient light intensity of the cloth to be inspected; secondly, the cloth to be inspected is intelligently inspected according to the cloth inspection parameters, and a high-resolution image of the cloth surface is obtained at fixed intervals, and the timestamp corresponding to the high-resolution image of the cloth surface is recorded; thirdly, defect detection is performed on the cloth to be inspected according to the high-resolution image, and the degree of local defects of the cloth corresponding to each high-resolution image of the cloth surface is obtained; then, when the degree of local defects of the cloth surface is greater than the set local defect threshold, the defect position in the high-resolution image of the cloth surface is obtained according to the timestamp corresponding to the high-resolution image of the cloth surface; finally, the quality inspection result of the cloth to be inspected is obtained according to the degree of local defects of the cloth corresponding to each high-resolution image of the cloth surface. The present invention can improve the accuracy of cloth defect detection with complex patterns through this method.
[0007] To achieve the above object, the present invention provides the following technical solutions: An intelligent cloth inspection method for textile production, comprising: Obtaining fabric inspection parameters according to fabric characteristics of the fabric to be inspected and ambient light intensity; Intelligently inspect the fabric to be inspected according to the inspection parameters, obtain a high-resolution image of the fabric surface at fixed intervals, and record a timestamp corresponding to the high-resolution image of the fabric surface; Perform defect detection on the fabric to be detected based on the high-resolution image, and obtain fabric defect features corresponding to each of the fabric high-resolution images; the fabric defect features include the number of defects, the area and type of each defect; Obtaining the degree of local defects of the cloth corresponding to each of the cloth surface high-resolution images according to the defect characteristics; The calculation formula for the degree of local defects of the cloth is: ; in, It is represented by the degree of local defects of the fabric corresponding to the i-th high-resolution image of the fabric surface; It is expressed as the number of defects corresponding to the i-th cloth surface high-resolution image; It is expressed as the area of the jth defect on the i-th cloth surface high-resolution image; It is represented by the type identification value corresponding to the jth defect on the i-th cloth surface high-resolution image; and They are expressed as defect quantity parameter and defect shape parameter respectively; It is expressed as an exponential function with a natural constant as base; When the degree of the local defect of the cloth is greater than a set local defect threshold, the defect position in the high-resolution cloth image is obtained according to the timestamp corresponding to the high-resolution cloth image; The quality inspection result of the cloth to be inspected is obtained according to the degree of local defects of the cloth corresponding to each of the high-resolution cloth surface images.
[0008] Furthermore, the method of acquiring the cloth inspection parameters based on the cloth features of the cloth to be inspected includes: the cloth features include cloth reflectivity, cloth length, cloth width and cloth image features; the process of acquiring the cloth image features includes: acquiring a standard cloth image corresponding to the cloth to be inspected; the cloth image features include the texture complexity, grayscale value, brightness and saturation of each pixel of the standard cloth image; the cloth inspection parameters include cloth inspection light source parameters and cloth inspection machine parameters; the cloth inspection light source parameters include the light intensity of the lighting on the cloth inspection machine; the cloth inspection machine parameters include the cloth inspection speed of the cloth inspection machine.
[0009] Furthermore, the process of acquiring the parameters of the cloth inspection light source includes: Obtaining the average grayscale value and comprehensive saturation of all pixels on the standard cloth image according to the cloth features; The comprehensive saturation is obtained by weighted average based on the saturation of each pixel, and the weight is the brightness component of each pixel; the calculation formula of the light intensity of the lighting lamp is: ; Wherein, I represents the light intensity; represents the set basic light intensity; , and They are respectively expressed as fabric reflectance, average gray value and comprehensive saturation; It is expressed as the ambient light intensity; , , , and They are respectively expressed as cloth characteristic coefficient, ambient lighting coefficient, reflectivity coefficient, brightness coefficient and saturation coefficient.
[0010] Furthermore, obtaining the high-resolution image of the fabric surface at fixed intervals based on the fabric inspection parameters includes: obtaining the fabric inspection speed of the fabric inspection machine in the fabric inspection parameters and the fabric shooting length corresponding to the high-resolution fabric surface image obtained each time; and obtaining the fixed time based on the fabric shooting length and the fabric inspection speed of the fabric inspection machine.
[0011] Furthermore, the process of acquiring the fabric surface defect features includes: Inputting the high-resolution cloth image into a cloth defect detection model to obtain cloth defect features corresponding to the high-resolution cloth image; the cloth defect detection model comprises a cloth image input layer, a cloth image segmentation layer, a cloth image local feature extraction layer, a cloth image local feature fusion layer, a cloth image defect classification layer and a cloth defect feature output layer; The cloth image segmentation layer is used to perform image segmentation on the cloth high-resolution image to obtain the cloth pattern area and the cloth non-pattern area; the cloth image local feature extraction layer is used to extract feature maps of the cloth pattern area and the cloth non-pattern area respectively; the cloth image local feature fusion layer is used to fuse the feature maps corresponding to the cloth pattern area and the cloth non-pattern area respectively to obtain the cloth pattern area features and the cloth non-pattern area features.
[0012] Further, obtaining the defect position in the high-resolution fabric image according to the timestamp corresponding to the high-resolution fabric image includes: obtaining the fabric position corresponding to the high-resolution image according to the timestamp and the fabric inspection speed of the fabric inspection machine; According to the cloth position and the position of each defect on the high-resolution image in the high-resolution image, the position of the defect on the cloth to be inspected is obtained and recorded as the defect position.
[0013] Furthermore, the process of obtaining the quality inspection result includes: obtaining the overall defect degree of the fabric according to the local defect degree of the fabric corresponding to each high-resolution image of the fabric; when the overall defect degree of the fabric is greater than the set overall defect threshold, the quality inspection result of the fabric to be inspected is unqualified; otherwise, the quality inspection result of the fabric to be inspected is qualified; the calculation formula of the overall defect degree of the fabric is: ; in, It is expressed as the overall defect degree of the fabric surface of the fabric to be tested; It is expressed as the number of high-resolution images of the cloth surface; It is expressed as the number of high-resolution images of the cloth surface with a local defect level of 0; It is represented by the degree of local defects of the fabric corresponding to the i-th high-resolution image of the fabric surface; and They are expressed as defect proportion coefficient and defect degree coefficient respectively.
[0014] An intelligent cloth inspection system for textile production, comprising: Fabric inspection parameter acquisition unit: used to acquire fabric inspection parameters according to fabric characteristics of the fabric to be inspected and ambient light intensity; A cloth surface high-resolution image acquisition unit is used to perform intelligent detection on the cloth to be detected according to the cloth inspection parameters, and to obtain a cloth surface high-resolution image at fixed intervals, and to record a timestamp corresponding to the cloth surface high-resolution image; A cloth surface defect feature acquisition unit is used to perform defect detection on the cloth to be detected based on the high-resolution image, and acquire a cloth surface defect feature corresponding to each of the cloth surface high-resolution images; A cloth local defect degree acquisition unit: used for acquiring the cloth local defect degree corresponding to each of the cloth surface high-resolution images according to the defect characteristics; A defect position acquisition unit: used for acquiring the defect position in the high-resolution image of the cloth surface according to the timestamp corresponding to the high-resolution image of the cloth surface when the degree of the local defect of the cloth surface is greater than a set local defect threshold; The quality inspection result acquisition unit is used to acquire the quality inspection result of the cloth to be inspected according to the degree of local defects of the cloth corresponding to each high-resolution image of the cloth surface.
[0015] Furthermore, the method of acquiring the cloth inspection parameters based on the cloth features of the cloth to be inspected includes: the cloth features include cloth reflectivity, cloth length, cloth width and cloth image features; the process of acquiring the cloth image features includes: acquiring a standard cloth image corresponding to the cloth to be inspected; the cloth image features include the texture complexity, grayscale value, brightness and saturation of each pixel of the standard cloth image; the cloth inspection parameters include cloth inspection light source parameters and cloth inspection machine parameters; the cloth inspection light source parameters include the light intensity of the lighting on the cloth inspection machine; the cloth inspection machine parameters include the cloth inspection speed of the cloth inspection machine.
[0016] Furthermore, the calculation formula for the degree of local defects of the cloth is: ; in, It is represented by the degree of local defects of the fabric corresponding to the i-th high-resolution image of the fabric surface; It is expressed as the number of defects corresponding to the i-th cloth surface high-resolution image; It is expressed as the area of the jth defect on the i-th cloth surface high-resolution image; It is represented by the type identification value corresponding to the jth defect on the i-th cloth surface high-resolution image; and They are expressed as defect quantity parameter and defect shape parameter respectively; Expressed as an exponential function with a natural constant as base.
[0017] Compared with the prior art, the present invention has the following beneficial effects: 1. Different fabrics have different colors, textures and surface reflectances, and a fixed light intensity may not be able to fully expose the defects on the surface of some fabrics. The present invention adjusts the light intensity of the lighting on the fabric inspection machine according to the fabric characteristics and the ambient light, combining the material characteristics of the fabric and the actual ambient light intensity, and can ensure that the defects of the fabric are clearly visible under the most appropriate lighting conditions, thereby improving the accuracy of fabric defect detection.
[0018] 2. For fabrics with patterns, the color and texture of the pattern area are relatively complex. The present invention uses a fabric defect detection model to segment the fabric pattern area and the fabric non-pattern area, and extracts the image features of the fabric pattern area and the fabric non-pattern area respectively to perform fabric defect detection. This method can specifically analyze the features of each area, avoid the complexity of the pattern area affecting the defect detection of the non-pattern area, and improve the accuracy of fabric defect detection.
[0019] 3. The present invention obtains the degree of local defects of the fabric corresponding to each high-resolution fabric image based on the fabric defect features corresponding to each high-resolution fabric image; when the degree of local defects of the fabric is greater than the set local defect threshold, the defect position in the high-resolution fabric image is obtained in combination with the timestamp. This method can accurately obtain the degree of local defects of the fabric in combination with the various defect features corresponding to the high-resolution fabric image, and then locate the defects in the high-resolution fabric image with a large degree of local defects, thereby improving the accuracy of fabric defect detection.
[0020] 4. The present invention obtains the overall defect degree of the fabric surface of the fabric to be tested based on the degree of local defects of the fabric corresponding to each high-resolution fabric image. This method can accurately evaluate the overall defect degree of the fabric surface of the fabric to be tested by combining the number of high-resolution fabric images with defects and the corresponding degree of local defects of the fabric, thereby accurately obtaining the quality test results of the fabric to be tested. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 A flow chart of an intelligent cloth inspection method for textile production provided by an embodiment of the present invention; Figure 2 A structural diagram of an intelligent cloth inspection system for textile production provided by an embodiment of the present invention; Figure 3 A schematic diagram of a standard cloth image of cloth B to be detected provided in an embodiment of the present invention; Figure 4 A schematic diagram of the structure of a cloth defect detection model provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0022] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0023] The present invention provides an intelligent cloth inspection method for textile production. The method is applied to an intelligent cloth inspection system for textile production. The specific method flow chart and system structure diagram refer to Figure 1 and Figure 2 .
[0024] Embodiment 1 Reference Figure 1 S10 in the figure is applied to a cloth inspection parameter acquisition unit of an intelligent cloth inspection system for textile production.
[0025] Furthermore, the method of acquiring the cloth inspection parameters based on the cloth features of the cloth to be inspected includes: the cloth features include cloth reflectivity, cloth length, cloth width and cloth image features; the process of acquiring the cloth image features includes: acquiring a standard cloth image corresponding to the cloth to be inspected; the cloth image features include the texture complexity, the grayscale value, brightness and saturation of each pixel of the standard cloth image; the cloth inspection parameters include cloth inspection light source parameters and cloth inspection machine parameters; the cloth inspection light source parameters include the light intensity of the lighting on the cloth inspection machine; the cloth inspection machine parameters include the cloth inspection speed of the cloth inspection machine; the texture complexity is acquired through the grayscale co-occurrence matrix corresponding to the standard cloth image.
[0026] This step of implementing the present invention obtains various fabric features of the fabric to be inspected, and adjusts the light intensity of the lighting on the fabric inspection machine and the fabric inspection speed of the fabric inspection machine according to the various fabric features. This method can accurately adjust the fabric inspection parameters according to the various parameters of the fabric, thereby improving the accuracy of fabric defect detection.
[0027] This embodiment obtains the fabric reflectivity, fabric length, width, and ambient light intensity of the fabric inspection machine of the fabric B to be inspected of company A, as shown in Table 1.
[0028] Table 1 Relevant data table of fabric B to be tested
[0029] Furthermore, the standard cloth image of the cloth B to be detected is referenced Figure 3 The process of obtaining the parameters of the inspection light source includes: Obtaining the average grayscale value and comprehensive saturation of all pixels on the standard cloth image according to the cloth features; The comprehensive saturation is obtained by weighted average based on the saturation of each pixel, with the weight being the brightness component of each pixel, and the calculation formula is: ; in, Expressed as comprehensive saturation; It is represented by the number of pixels on the standard fabric image; It is expressed as the brightness value of the y-th similar point; Represented as the saturation value of the y-th pixel; The calculation formula of the light intensity of the lighting lamp is: ; Wherein, I represents the light intensity; represents the set basic light intensity; , and They are respectively expressed as fabric reflectance, average gray value and comprehensive saturation; It is expressed as the ambient light intensity; , , , and They are respectively expressed as fabric characteristic coefficient, ambient light coefficient, reflectivity coefficient, brightness coefficient and saturation coefficient; in this embodiment The default value is 0.5. , and The default is , The default value is 1. , , , and The specific value of can also be changed according to the actual application; Expressed as an exponential function with a natural constant as base.
[0030] Different fabrics have different colors, textures, and surface reflectivity, and a fixed light intensity may not be able to fully expose some fabric surface defects. This step of the present embodiment adjusts the light intensity of the lighting on the fabric inspection machine according to the fabric characteristics and the ambient light, combining the fabric characteristics and the actual ambient light intensity to ensure that fabric defects are clearly visible under the most appropriate lighting conditions, thereby improving the accuracy of fabric defect detection.
[0031] Furthermore, the inspection speed of the fabric inspection machine is obtained according to the texture complexity corresponding to the fabric to be inspected; the higher the texture complexity, the slower the inspection speed of the fabric inspection machine; the lower the texture complexity, the faster the inspection speed of the fabric inspection machine.
[0032] Reference Figure 1 The S20 in the figure is applied to a high-resolution image acquisition unit of a fabric surface in an intelligent fabric inspection system for textile production.
[0033] Further, obtaining the high-resolution fabric image at fixed intervals according to the fabric inspection parameters includes: obtaining the fabric inspection speed of the fabric inspection machine in the fabric inspection parameters and the fabric shooting length corresponding to each high-resolution fabric image obtained; obtaining the fixed time according to the fabric shooting length and the fabric inspection speed of the fabric inspection machine, and the calculation formula of the fixed time is: ; in, Expressed as a fixed time; It is expressed as the cloth inspection speed of the cloth inspection machine; It is expressed as the length of the cloth shot; It is expressed as the fabric shooting length coefficient; is set based on experience, and ; Furthermore, after obtaining the high-resolution cloth surface image, it is also necessary to pre-process the high-resolution cloth surface image.
[0034] In this step of the present embodiment, the interval time for collecting high-resolution images of the fabric surface is set according to the fabric shooting length and the fabric inspection speed of the fabric inspection machine. This method can avoid excessive or insufficient collection while ensuring the image quality, thereby improving the overall working efficiency of the fabric inspection machine and making fabric defect detection more efficient.
[0035] Reference Figure 1 S30 in the embodiment is applied to a fabric surface defect feature acquisition unit of an intelligent fabric inspection system for textile production.
[0036] Furthermore, the fabric surface defect characteristics include the number of defects, the area and type of each defect; and the process of acquiring the fabric surface defect characteristics includes: Input the cloth surface high-resolution image into the cloth surface defect detection model to obtain the cloth surface defect features corresponding to the cloth surface high-resolution image; refer to Figure 4 The cloth defect detection model includes a cloth image input layer, a cloth image segmentation layer, a cloth image local feature extraction layer, a cloth image local feature fusion layer, a cloth image defect classification layer and a cloth defect feature output layer; The cloth image segmentation layer is used to perform image segmentation on the cloth high-resolution image to obtain a cloth pattern area and a cloth non-pattern area; The cloth image local feature extraction layer is used to extract feature maps of the cloth pattern area and the cloth non-pattern area respectively; The cloth image local feature fusion layer is used to fuse the feature maps corresponding to the cloth pattern area and the cloth non-pattern area respectively, to obtain the cloth pattern area feature and the cloth non-pattern area feature; The cloth image defect classification layer is used to obtain the defect features of the cloth image based on the cloth pattern area features and the cloth non-pattern area features; the cloth defect feature output layer is used to output the defect features; when there are no defects in the cloth high-resolution image, the defect features output by the cloth defect feature output layer are empty.
[0037] In order to verify the effectiveness of the cloth defect detection model in this embodiment, this embodiment collected 600 high-resolution cloth images with patterns, and used the cloth defect detection model to detect cloth defect features on the 600 high-resolution cloth images; at the same time, the other two models were used to detect cloth defect features on the high-resolution cloth images; the recognition accuracy of the three models for the number of defects, defect area and defect type was calculated, and the calculation formula for the defect area recognition accuracy was: ; in, It is expressed as the defect area recognition accuracy of the k-th model; represents the number of real defects identified by the k-th model; represents the defect area of the hth defect identified by the kth model; represents the true defect area of the hth defect identified by the kth model; Please refer to Table 2 for specific recognition accuracy data.
[0038] Table 2 Cloth surface defect detection model recognition verification table
[0039] In Table 2, recognition model 1 is the cloth defect detection model provided in this embodiment; recognition model 2 is based on recognition model 1 without segmenting the cloth pattern area and the cloth non-pattern area of the high-resolution cloth image; model 3 is the CNN model; It can be seen from Table 2 that the cloth defect detection model provided in this embodiment can improve the accuracy of cloth defect feature extraction.
[0040] For patterned fabrics, the color and texture of the patterned area are relatively complex. In this step of the present embodiment, the patterned area and the non-patterned area of the fabric are segmented by the fabric defect detection model, and the image features of the patterned area and the non-patterned area of the fabric are extracted respectively to perform fabric defect detection. This method can specifically analyze the features of each area, avoid the complexity of the patterned area affecting the defect detection of the non-patterned area, and improve the accuracy of fabric defect detection.
[0041] Reference Figure 1 The S40 in the embodiment is applied to a unit for obtaining the degree of local defects of fabrics in an intelligent fabric inspection system for textile production.
[0042] Furthermore, the calculation formula for the degree of local defects of the cloth is: ; in, It is represented by the degree of local defects of the fabric corresponding to the i-th high-resolution image of the fabric surface; It is expressed as the number of defects corresponding to the i-th cloth surface high-resolution image; It is expressed as the area of the jth defect on the i-th cloth surface high-resolution image; It is represented by the type identification value corresponding to the jth defect on the i-th cloth surface high-resolution image; the type identification value is obtained according to a pre-stored defect database; the defect database includes each defect and the corresponding type identification value; and They are expressed as defect quantity parameter and defect shape parameter respectively; and The default value is 0.5, which can be changed according to the actual application; is expressed as an exponential function with a natural constant as the base. In particular, when the i-th cloth high-resolution image has no defects, .
[0043] In this step of the present embodiment, the degree of local defects of the fabric corresponding to each high-resolution fabric image is obtained based on the fabric defect features corresponding to each high-resolution fabric image; when the degree of local defects of the fabric is greater than the set local defect threshold, the defect position in the high-resolution fabric image is obtained in combination with the timestamp. This method can accurately obtain the degree of local defects of the fabric in combination with various defect features corresponding to the high-resolution fabric image, and then locate the defects in the high-resolution fabric image with a large degree of local defects, thereby improving the accuracy of fabric defect detection.
[0044] Reference Figure 1 The S50 in the embodiment is applied to a defect position acquisition unit of an intelligent fabric inspection system for textile production.
[0045] Furthermore, when the degree of the local defect of the cloth is greater than a set local defect threshold, the defect position in the high-resolution cloth image is obtained according to the timestamp corresponding to the high-resolution cloth image; the local defect threshold is obtained based on experience; the specific steps of obtaining the defect position include: Acquire the cloth position corresponding to the high-resolution image according to the timestamp and the cloth inspection speed of the cloth inspection machine; According to the cloth position and the position of each defect on the high-resolution image in the high-resolution image, the position of the defect on the cloth to be inspected is obtained and recorded as the defect position.
[0046] This step of the present embodiment locates defects in the high-resolution fabric image with large local defects. The position of the fabric area corresponding to the high-resolution fabric image on the fabric to be inspected can be accurately obtained based on the timestamp corresponding to the high-resolution fabric image and the inspection speed of the fabric inspection machine. Combined with the position of the defect in the high-resolution image, the position of the defect can be accurately obtained.
[0047] Reference Figure 1 The S60 in the embodiment is applied to a quality inspection result acquisition unit of an intelligent fabric inspection system for textile production.
[0048] Furthermore, the process of obtaining the quality inspection result includes: obtaining the overall defect degree of the fabric surface according to the local defect degree of the fabric surface corresponding to each high-resolution image of the fabric surface; when the overall defect degree of the fabric surface is greater than a set overall defect threshold, the quality inspection result of the fabric to be inspected is unqualified; otherwise, the quality inspection result of the fabric to be inspected is qualified; The calculation formula for the overall defect degree of the fabric is: ; in, It is expressed as the overall defect degree of the fabric surface of the fabric to be tested; It is expressed as the number of high-resolution images of the cloth surface; It is expressed as the number of high-resolution images of the cloth surface with a local defect level of 0; It is represented by the degree of local defects of the fabric corresponding to the i-th high-resolution image of the fabric surface; and They are expressed as defect proportion coefficient and defect degree coefficient respectively; and The default value is 0.5, and can be changed according to actual application.
[0049] In this step of the present embodiment, the overall defect degree of the fabric surface of the fabric to be inspected is obtained based on the degree of local defect of the fabric corresponding to each high-resolution fabric surface image. This method can accurately evaluate the overall defect degree of the fabric surface of the fabric to be inspected by combining the number of high-resolution fabric surface images with defects and the corresponding degree of local defect of the fabric, thereby accurately obtaining the quality inspection result of the fabric to be inspected.
[0050] Embodiment 2 In Example 1, the method of the present invention is combined with a system to realize intelligent fabric inspection and detection in textile production; in Example 2 of the present application, the method of the present invention will be described again.
[0051] S10: Acquire cloth inspection parameters according to the cloth characteristics of the cloth to be inspected and the ambient light intensity.
[0052] Furthermore, the method of acquiring the cloth inspection parameters based on the cloth features of the cloth to be inspected includes: the cloth features include cloth reflectivity, cloth length, cloth width and cloth image features; the process of acquiring the cloth image features includes: acquiring a standard cloth image corresponding to the cloth to be inspected; the cloth image features include the texture complexity, grayscale value, brightness and saturation of each pixel of the standard cloth image; the cloth inspection parameters include cloth inspection light source parameters and cloth inspection machine parameters; the cloth inspection light source parameters include the light intensity of the lighting on the cloth inspection machine; the cloth inspection machine parameters include the cloth inspection speed of the cloth inspection machine.
[0053] Furthermore, the process of acquiring the parameters of the cloth inspection light source includes: Obtaining the average grayscale value and comprehensive saturation of all pixels on the standard cloth image according to the cloth features; The comprehensive saturation is obtained by weighted average based on the saturation of each pixel, and the weight is the brightness component of each pixel; the calculation formula of the light intensity of the lighting lamp is: ; Wherein, I represents the light intensity; represents the set basic light intensity; , and They are respectively expressed as fabric reflectance, average gray value and comprehensive saturation; It is expressed as the ambient light intensity; , , , and They are respectively expressed as fabric characteristic coefficient, ambient light coefficient, reflectivity coefficient, brightness coefficient and saturation coefficient; in this embodiment The default value is 0.5. , and The default is , The default value is 1. , , , and The specific value of can also be changed according to the actual application; Expressed as an exponential function with a natural constant as base.
[0054] S20, performing intelligent inspection on the cloth to be inspected according to the cloth inspection parameters, obtaining a high-resolution image of the cloth surface at fixed intervals, and recording a timestamp corresponding to the high-resolution image of the cloth surface.
[0055] Further, obtaining the high-resolution fabric image at fixed intervals according to the fabric inspection parameters includes: obtaining the fabric inspection speed of the fabric inspection machine in the fabric inspection parameters and the fabric shooting length corresponding to each high-resolution fabric image obtained; obtaining the fixed time according to the fabric shooting length and the fabric inspection speed of the fabric inspection machine, and the calculation formula of the fixed time is: ; in, Expressed as a fixed time; It is expressed as the cloth inspection speed of the cloth inspection machine; It is expressed as the length of the cloth shot; It is expressed as the fabric shooting length coefficient; is set based on experience, and .
[0056] S30, performing defect detection on the cloth to be detected based on the high-resolution image, and obtaining cloth surface defect features corresponding to each of the cloth surface high-resolution images.
[0057] Furthermore, the fabric surface defect characteristics include the number of defects, the area and type of each defect; and the process of acquiring the fabric surface defect characteristics includes: Inputting the high-resolution cloth image into a cloth defect detection model to obtain cloth defect features corresponding to the high-resolution cloth image; the cloth defect detection model comprises a cloth image input layer, a cloth image segmentation layer, a cloth image local feature extraction layer, a cloth image local feature fusion layer, a cloth image defect classification layer and a cloth defect feature output layer; The cloth image segmentation layer is used to perform image segmentation on the cloth high-resolution image to obtain the cloth pattern area and the cloth non-pattern area; the cloth image local feature extraction layer is used to extract feature maps of the cloth pattern area and the cloth non-pattern area respectively; the cloth image local feature fusion layer is used to fuse the feature maps corresponding to the cloth pattern area and the cloth non-pattern area respectively to obtain the cloth pattern area features and the cloth non-pattern area features; the cloth image defect classification layer is used to obtain the defect features of the cloth image based on the cloth pattern area features and the cloth non-pattern area features; the cloth defect feature output layer is used to output the defect features; when there is no defect in the cloth high-resolution image, the defect features output by the cloth defect feature output layer are empty.
[0058] S40, obtaining the degree of local defects of the cloth corresponding to each of the high-resolution cloth images according to the cloth defect features.
[0059] Furthermore, the calculation formula for the degree of local defects of the cloth is: ; in, It is represented by the degree of local defects of the fabric corresponding to the i-th high-resolution image of the fabric surface; It is expressed as the number of defects corresponding to the i-th cloth surface high-resolution image; It is expressed as the area of the jth defect on the i-th cloth surface high-resolution image; It is represented by the type identification value corresponding to the jth defect on the i-th cloth surface high-resolution image; and They are expressed as defect quantity parameter and defect shape parameter respectively; and The default value is 0.5, which can be changed according to the actual application; is expressed as an exponential function with a natural constant as the base. In particular, when the i-th cloth high-resolution image has no defects, .
[0060] S50: When the degree of the local defect of the cloth is greater than a set local defect threshold, the defect position in the high-resolution cloth image is obtained according to a timestamp corresponding to the high-resolution cloth image.
[0061] Further, obtaining the defect position in the high-resolution cloth surface image according to the timestamp corresponding to the high-resolution cloth surface image includes: Acquire the cloth position corresponding to the high-resolution image according to the timestamp and the cloth inspection speed of the cloth inspection machine; According to the cloth position and the position of each defect on the high-resolution image in the high-resolution image, the position of the defect on the cloth to be inspected is obtained and recorded as the defect position.
[0062] S60: Obtain a quality inspection result of the to-be-inspected fabric according to the degree of local fabric defects corresponding to each of the high-resolution fabric surface images.
[0063] Furthermore, the process of obtaining the quality inspection result includes: obtaining the overall defect degree of the fabric according to the local defect degree of the fabric corresponding to each high-resolution image of the fabric; when the overall defect degree of the fabric is greater than the set overall defect threshold, the quality inspection result of the fabric to be inspected is unqualified; otherwise, the quality inspection result of the fabric to be inspected is qualified; the calculation formula of the overall defect degree of the fabric is: ; in, It is expressed as the overall defect degree of the fabric surface of the fabric to be tested; It is expressed as the number of high-resolution images of the cloth surface; It is expressed as the number of high-resolution images of the cloth surface with a local defect level of 0; It is represented by the degree of local defects of the fabric corresponding to the i-th high-resolution image of the fabric surface; and They are expressed as defect proportion coefficient and defect degree coefficient respectively; and The default value is 0.5, and can be changed according to actual application.
[0064] Furthermore, in order to verify the effectiveness of the intelligent fabric inspection method provided in this embodiment, this embodiment collected 300 pieces of different patterned fabrics, and adopted four different schemes for intelligent fabric inspection to obtain the quality inspection results of the fabrics. Each scheme was tested five times repeatedly; the quality inspection accuracy of each scheme after each test was obtained. For specific results, refer to Table 3.
[0065] Table 3 Comparison table of intelligent fabric inspection
[0066] Furthermore, the first cloth inspection scheme in Table 3 is the intelligent cloth inspection method provided by this embodiment; the second cloth inspection scheme is based on the first cloth inspection scheme, and the cloth surface image segmentation layer in the cloth surface defect detection model is removed; the third cloth inspection scheme is based on the first cloth inspection scheme, and the cloth surface defect detection model is replaced with a CNN model; the fourth cloth inspection scheme is based on the first cloth inspection scheme, and only the number of defects in the defect feature is used to calculate the degree of local defects of the cloth. It can be seen from the data in Table 3 that the intelligent cloth inspection method provided by this embodiment can effectively improve the accuracy of cloth defect detection, thereby improving the accuracy of cloth quality detection.
[0067] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.
Claims
1. An intelligent cloth inspection method for textile production, characterized in that: include: Obtaining fabric inspection parameters according to fabric characteristics of the fabric to be inspected and ambient light intensity; Intelligently inspect the fabric to be inspected according to the inspection parameters, obtain a high-resolution image of the fabric surface at fixed intervals, and record a timestamp corresponding to the high-resolution image of the fabric surface; Perform defect detection on the fabric to be detected based on the high-resolution image, and obtain fabric defect features corresponding to each of the fabric high-resolution images; the fabric defect features include the number of defects, the area and type of each defect; Obtaining the degree of local defects of the cloth corresponding to each of the high-resolution cloth images according to the cloth defect characteristics; The calculation formula for the degree of local defects of the cloth is: ; in, It is represented by the degree of local defects of the fabric corresponding to the i-th high-resolution image of the fabric surface; It is expressed as the number of defects corresponding to the i-th cloth surface high-resolution image; It is expressed as the area of the jth defect on the i-th cloth surface high-resolution image; It is represented by the type identification value corresponding to the jth defect on the i-th cloth surface high-resolution image; and They are expressed as defect quantity parameter and defect shape parameter respectively; It is expressed as an exponential function with a natural constant as base; When the degree of the local defect of the cloth is greater than a set local defect threshold, the defect position in the high-resolution cloth image is obtained according to the timestamp corresponding to the high-resolution cloth image; The quality inspection result of the cloth to be inspected is obtained according to the degree of local defects of the cloth corresponding to each of the high-resolution cloth surface images.
2. The intelligent cloth inspection method for textile production according to claim 1, characterized in that: The method of acquiring the cloth inspection parameters according to the cloth features of the cloth to be inspected includes: the cloth features include cloth reflectivity, cloth length, cloth width and cloth image features; the process of acquiring the cloth image features includes: acquiring a standard cloth image corresponding to the cloth to be inspected; the cloth image features include the texture complexity, the gray value, brightness and saturation of each pixel of the standard cloth image; the cloth inspection parameters include cloth inspection light source parameters and cloth inspection machine parameters; the cloth inspection light source parameters include the light intensity of the lighting on the cloth inspection machine; the cloth inspection machine parameters include the cloth inspection speed of the cloth inspection machine.
3. The intelligent cloth inspection method for textile production according to claim 2, characterized in that: The process of obtaining the parameters of the cloth inspection light source includes: Obtaining the average grayscale value and comprehensive saturation of all pixels on the standard cloth image according to the cloth features; The comprehensive saturation is obtained by weighted average based on the saturation of each pixel, and the weight is the brightness component of each pixel; the calculation formula of the light intensity of the lighting lamp is: ; Wherein, I represents the light intensity; represents the set basic light intensity; , and They are respectively expressed as fabric reflectance, average gray value and comprehensive saturation; It is expressed as the ambient light intensity; , , , and They are respectively expressed as cloth characteristic coefficient, ambient lighting coefficient, reflectivity coefficient, brightness coefficient and saturation coefficient.
4. The intelligent cloth inspection method for textile production according to claim 1, characterized in that: The method of acquiring a high-resolution image of the fabric surface at fixed intervals according to the fabric inspection parameters comprises: acquiring a fabric inspection speed of a fabric inspection machine in the fabric inspection parameters and a fabric shooting length corresponding to each high-resolution fabric surface image acquired; and acquiring the fixed time according to the fabric shooting length and the fabric inspection speed of the fabric inspection machine.
5. The intelligent cloth inspection method for textile production according to claim 1, characterized in that: The process of acquiring the fabric surface defect features includes: Inputting the high-resolution cloth image into a cloth defect detection model to obtain cloth defect features corresponding to the high-resolution cloth image; the cloth defect detection model comprises a cloth image input layer, a cloth image segmentation layer, a cloth image local feature extraction layer, a cloth image local feature fusion layer, a cloth image defect classification layer and a cloth defect feature output layer; The cloth image segmentation layer is used to perform image segmentation on the cloth high-resolution image to obtain the cloth pattern area and the cloth non-pattern area; the cloth image local feature extraction layer is used to extract feature maps of the cloth pattern area and the cloth non-pattern area respectively; the cloth image local feature fusion layer is used to fuse the feature maps corresponding to the cloth pattern area and the cloth non-pattern area respectively to obtain the cloth pattern area features and the cloth non-pattern area features.
6. The intelligent cloth inspection method for textile production according to claim 1, characterized in that: Acquiring the defect position in the high-resolution cloth surface image according to the timestamp corresponding to the high-resolution cloth surface image includes: Acquire the cloth position corresponding to the high-resolution image according to the timestamp and the cloth inspection speed of the cloth inspection machine; According to the cloth position and the position of each defect on the high-resolution image in the high-resolution image, the position of the defect on the cloth to be inspected is obtained and recorded as the defect position.
7. The intelligent cloth inspection method for textile production according to claim 1, characterized in that: The process of obtaining the quality inspection result includes: obtaining the overall defect degree of the fabric surface according to the local defect degree of the fabric surface corresponding to each high-resolution image of the fabric surface; when the overall defect degree of the fabric surface is greater than a set overall defect threshold, the quality inspection result of the fabric to be inspected is unqualified; otherwise, the quality inspection result of the fabric to be inspected is qualified; The calculation formula for the overall defect degree of the fabric is: ; in, It is expressed as the overall defect degree of the fabric surface of the fabric to be tested; It is expressed as the number of high-resolution images of the cloth surface; It is expressed as the number of high-resolution images of the cloth surface with a local defect level of 0; It is represented by the degree of local defects of the fabric corresponding to the i-th high-resolution image of the fabric surface; and They are expressed as defect proportion coefficient and defect degree coefficient respectively.
8. An intelligent cloth inspection system for textile production, characterized in that: include: Fabric inspection parameter acquisition unit: used to acquire fabric inspection parameters according to fabric characteristics of the fabric to be inspected and ambient light intensity; A cloth surface high-resolution image acquisition unit is used to perform intelligent detection on the cloth to be detected according to the cloth inspection parameters, and to obtain a cloth surface high-resolution image at fixed intervals, and to record a timestamp corresponding to the cloth surface high-resolution image; A cloth surface defect feature acquisition unit is used to perform defect detection on the cloth to be detected based on the high-resolution image, and acquire a cloth surface defect feature corresponding to each of the cloth surface high-resolution images; A cloth local defect degree acquisition unit: used for acquiring the cloth local defect degree corresponding to each of the cloth surface high-resolution images according to the defect characteristics; A defect position acquisition unit: used for acquiring the defect position in the high-resolution image of the cloth surface according to the timestamp corresponding to the high-resolution image of the cloth surface when the degree of the local defect of the cloth surface is greater than a set local defect threshold; The quality inspection result acquisition unit is used to acquire the quality inspection result of the cloth to be inspected according to the degree of local defects of the cloth corresponding to each high-resolution image of the cloth surface.
9. The intelligent cloth inspection system for textile production according to claim 8, characterized in that: The method of acquiring the cloth inspection parameters according to the cloth features of the cloth to be inspected includes: the cloth features include cloth reflectivity, cloth length, cloth width and cloth image features; the process of acquiring the cloth image features includes: acquiring a standard cloth image corresponding to the cloth to be inspected; the cloth image features include the texture complexity, the gray value, brightness and saturation of each pixel of the standard cloth image; the cloth inspection parameters include cloth inspection light source parameters and cloth inspection machine parameters; the cloth inspection light source parameters include the light intensity of the lighting on the cloth inspection machine; the cloth inspection machine parameters include the cloth inspection speed of the cloth inspection machine.
10. The intelligent cloth inspection system for textile production according to claim 8, characterized in that: The calculation formula for the degree of local defects of the cloth is: ; in, It is represented by the degree of local defects of the fabric corresponding to the i-th high-resolution image of the fabric surface; It is expressed as the number of defects corresponding to the i-th cloth surface high-resolution image; It is expressed as the area of the jth defect on the i-th cloth surface high-resolution image; It is represented by the type identification value corresponding to the jth defect on the i-th cloth surface high-resolution image; and They are expressed as defect quantity parameter and defect shape parameter respectively; Expressed as an exponential function with a natural constant as base.
Citation Information
Patent Citations
Coal mine underground image enhancement method and system and computer storage medium
CN111429370A
YOLO-based method for detecting surface defects of a rail in a tunnel
CN111598846A
Low-cost fabric flaw detection system and method
CN114757910A
Road defect detection method and system, electronic equipment and storage medium
CN116777833A
Metal surface defect detection method and system based on multi-angle image exposure fusion
CN117115610A