Textile real-time chromatic aberration calculation method and device based on hyperspectrum
Through the real-time color difference calculation method and device of textiles based on hyperspectral, the existing textile detection methods have been solved, and the existing textile detection methods are involved in a lot of manual participation and inconsistent detection environment are achieved, and efficient and accurate color difference detection of textiles is achieved.
Patent Information
- Application Number
- CN202510376929.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-28
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2045-03-28
AI Technical Summary
The existing textile inspection methods are highly manual, the inspection environment cannot be guaranteed to be unified, and the external environment is more disturbing, resulting in poor textile inspection results.
A real-time color difference calculation method and device for textiles based on hyperspectral is adopted, including the initialization of real-time color difference calculation device for textiles, automatic transportation and spectral acquisition of textiles, and real-time color difference calculation. The device obtains the original spectral data of the textile through the hyperspectral acquisition module and calculates the output of the total textile color difference in real time.
Automatic and intelligent inspection of textiles has been realized, the labor intensity of operators has been reduced, the inspection efficiency and accuracy have been improved, and the impact of external factors on the detection results have been avoided.
Smart Images

Figure CN119880803A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of textile detection, and in particular to a method and device for calculating real-time color difference of textiles based on a hyperspectral spectrum. Background Art
[0002] The uniformity of textile dyeing and the color difference between batches have always been a key problem that has attracted much attention and needs to be solved in the textile production process. At present, the color difference inspection of textiles mostly adopts the traditional manual sampling and evaluation method, but the efficiency of manual sampling and evaluation is low, and due to the differences in individual sensitivity to color and the inconsistency of each person's habits, the judgment results are not standardized. At the same time, due to the inconsistent thread density of textiles, different tensile strengths have a great influence on the test results, and the differences in artificial detection techniques and detection angles are likely to lead to the misjudgment of good products, causing unnecessary losses to manufacturers. In the prior art, there are also devices and apparatuses that apply spectrometers to the field of color detection, but there are still many limitations when applied to flexible materials such as textiles. The existing color difference detection device cannot realize automatic color difference detection, and can only be manually used by operators to sample textile samples. The detection effect is low, and there is a problem of missing areas, which easily leads to the outflow of defective products. At the same time, the existing detection method has great technical difficulties in how to detect textiles such as stockings that are thin, elastic, sparsely knitted, and have large holes. When elastic fabrics are placed on common automated detection devices such as conveyor belts, wrinkles will be encountered, resulting in inaccurate measurements. Thin and translucent textiles have high light transmittance and weak reflected spectral signals, resulting in greater interference between transmitted light and other reflected light on the results. In addition, the thread density of textiles is different. For sparse textile samples, holes will also have a greater impact on the sample detection results, and the color difference detection accuracy is low. Summary of the invention
[0003] The technical problem to be solved by the present invention is that the existing textile testing methods have a large proportion of manual participation, the testing environment cannot be guaranteed to be uniform, and there are many external environmental interferences, resulting in poor textile testing results.
[0004] In order to solve the above technical problems, the first aspect of the present invention adopts the following technical solution: a method for calculating the real-time color difference of textiles based on hyperspectral, comprising the following steps: S1: Initializing the textile real-time color difference calculation device, installing the textile on the supporting part of the textile real-time color difference calculation device; S2: driving the textile to be tested to move through the supporting part of the textile real-time color difference calculation device to keep it flat, and driving the textile to pass through the spectrum collection stations in sequence; S3: The hyperspectral acquisition module preset by the textile real-time color difference calculation device obtains the original spectrum data of the textile through spectrum acquisition, and outputs the real-time total color difference of the textile after calculation.
[0005] When the present invention is working, it can realize a series of tasks such as supporting and automatically leveling textiles, automatically conveying textiles, automatically collecting spectra of textiles and calculating color differences, etc. It has a high degree of automation and intelligence, greatly reduces the labor intensity of operators, can effectively improve the efficiency of textile detection, and at the same time unify the detection environment, can avoid the influence of external factors on the detection results, and improve the detection accuracy. The support part of the real-time color difference calculation device for textiles drives the movement of the textile to be tested to keep it flat. It is suitable for color difference detection of flexible textiles, and can avoid the influence of wrinkles and holes caused by excessive stretching on the detection results.
[0006] Preferably, in step S2, when the textile to be tested is driven to move so as to keep it flat by the supporting part of the real-time color difference calculation device for textiles, the following steps are adopted to obtain the specification parameters of the textile, and drive the textile to be tested to move so as to keep it flat by changing the size of the supporting part of the real-time color difference calculation device for textiles.
[0007] Preferably, in step S2, when the textile to be tested is driven to move so as to keep it flat by the supporting part of the real-time color difference calculation device for textiles, the following steps are adopted: depth information of the textile is continuously collected by a depth acquisition module preset in the real-time color difference calculation device for textiles to obtain real-time depth information of the textile, and whether the textile is flat is determined by calculating the depth information; when the textile is not flat, the size of the supporting part of the real-time color difference calculation device for textiles is changed to drive the textile to be tested to move so as to keep it flat.
[0008] Preferably, in step S2, the depth information of the textile is continuously collected by a depth collection module preset in the real-time color difference calculation device for textiles to obtain real-time depth information of the textile, and whether the textile is flat is determined by calculating the depth information. When the textile is not flat, the size of the support part of the real-time color difference calculation device for textiles is changed to drive the textile to be tested to move so that it remains flat, and the following steps are adopted: A1: Obtain the standard depth value obtained by the depth acquisition module and the thickness of the textile; A2: The depth acquisition module collects depth information of the textiles entering its detection area to obtain the depth information of each point; A3: Subtract the depth information of each point from the standard depth value, take the absolute value of the difference and compare it with the preset depth threshold, and mark the points with depth greater than the threshold as abnormal points; A4: Count the number of abnormal points. When the proportion of abnormal points is greater than or equal to a preset smoothness threshold, the current state of the textile is determined to be uneven. The size of the supporting part of the textile real-time color difference calculation device is changed to drive the textile to be tested to move.
[0009] When the present invention is working, it can dynamically adjust the size of the supporting part according to the specification parameters of the textile, and is suitable for use in the detection of textiles of different specifications. It has a wide range of applications and good versatility. At the same time, through the depth acquisition module preset by the real-time color difference calculation device for textiles, the depth information of the textiles is continuously collected, and the real-time monitoring and real-time adjustment of the flatness of the textiles can be realized. By keeping the flatness of the textiles, the accuracy of textile detection can be further improved.
[0010] Preferably, in step S2, when driving the textile to pass through the spectrum collection station in sequence, the following steps are adopted: the textile is connected to the head end of the textile through a preset drawing belt, and the reeling part of the textile reeling mechanism preset by the textile real-time color difference calculation device is connected to the textile through the drawing belt, and the textile is driven to pass through the spectrum collection station in sequence at a uniform speed. The transfer speed of the textile is set by the following formula: ; Wherein: v is the transfer speed of the textile, x is the slit width, H is the distance from the collection part of the hyperspectral collection module to the spectrum collection station, f is the focal length of the hyperspectral collection module, and fps is the frame rate of the hyperspectral collection module.
[0011] When the present invention is working, by driving the textile to pass through the spectrum collection station at a uniform speed according to a preset transfer speed, the textile transfer speed can be adapted to the frame rate of the hyperspectral collection module, thereby maintaining the collection effect and ensuring the detection efficiency without missing samples.
[0012] Preferably, in step S3, the hyperspectral acquisition module preset by the textile real-time color difference calculation device obtains the original spectrum data of the textile through spectrum acquisition, and when the real-time total color difference of the textile is output through calculation, the following steps are adopted: B1: The interference light in the spectrum collection station is removed by the light absorption module preset by the real-time color difference calculation device for textiles, and the original spectrum data of the textiles is obtained by the high spectrum collection module preset by the real-time color difference calculation device for textiles through spectrum collection; B2: Calculate the reflectance through the original spectrum data of the textile, and obtain several groups of LAB data from the reflectance; B3: A group of LAB data after regional averaging is obtained by performing regional averaging operation on several groups of LAB data in the original spectral data of the textile, and after calculating the LAB value of the group of LAB data, the total color difference of the textile is calculated and output in real time.
[0013] When the present invention is working, a hyperspectral acquisition module is used to obtain original spectral data of textiles through spectral acquisition, and the LAB value and total color difference of textiles can be measured and calculated in batches, and the color difference value that meets international standards can be further calculated, which is convenient for classifying and grading textiles. At the same time, through regional averaging operations, the interference of textile holes on the detection results can be avoided, and the anti-interference ability is strong, which can ensure the accuracy of the detection results.
[0014] In order to solve the above technical problems, the second aspect of the present invention adopts the following technical solution: a real-time color difference calculation device for textiles based on hyperspectrum, using the above-mentioned real-time color difference calculation method for textiles based on hyperspectrum, comprising: A light source module is used to provide a light source with adjustable angle and uniform illumination; Depth acquisition module, used to collect color information and depth information in the spectrum acquisition station; A hyperspectral acquisition module, used to collect spectral data in a spectral acquisition station; A textile support mechanism, used to support textiles of different specifications to keep them flat according to the collected depth information; A textile reeling mechanism, used to transfer the textile through the spectrum collection station and reel up the textile that has been tested; Light absorption module, used to avoid interfering light in the spectrum collection station; The light emitting part of the light source module, the collecting part of the depth collecting module and the collecting part of the hyperspectral collecting module are all connected to the optical path of the spectral collecting station; the textile supporting mechanism and the textile rolling mechanism are respectively arranged on both sides of the spectral collecting station; the light absorbing part of the light absorbing module is arranged at the periphery of the spectral collecting station; the supporting part of the textile supporting mechanism is actuated after the depth collecting module collects the depth information of the textile to drive the textile to remain flat; the speed of the textile rolling mechanism in moving the textile is set to be synchronized with the collecting work of the hyperspectral collecting module.
[0015] When the present invention is working, it can realize a series of tasks such as supporting and automatically leveling textiles, automatically conveying textiles, automatically collecting spectra of textiles and calculating color differences, etc. It has a high degree of automation and intelligence, greatly reduces the labor intensity of operators, and can effectively improve the efficiency of textile detection. At the same time, the light absorption module is used to avoid interfering light in the spectrum collection station, and the influence of external factors on the detection results can be avoided, thereby improving the detection accuracy. The depth collection module and the textile support mechanism are used to drive the movement of the textile to be tested to keep it flat. It is suitable for color difference detection of flexible textiles, and can avoid the influence of wrinkles and holes caused by excessive stretching on the detection results.
[0016] Preferably, the textile support mechanism comprises at least two support rods, a transverse slide rail and a driving device, wherein the transverse slide rail extends in a direction perpendicular to the moving direction of the textile, and the support rods are slidably mounted on the transverse slide rail, and adjacent support rods are kept parallel, and each support rod is connected to the driving device through a corresponding transmission assembly, and the spacing between adjacent support rods is adjusted under the drive of the driving device to flatten the supported textile.
[0017] Preferably, the depth acquisition module collects depth information of the textile when the textile moves into the spectrum acquisition station to obtain depth information of several points on the textile, and the spacing between adjacent support rods is adjusted by comparing the depth information of each point with a preset standard depth value.
[0018] Preferably, the textile winding mechanism comprises a textile driving mechanism for uniformly transferring the textile at a preset transfer speed and a textile storage mechanism for storing the inspected textiles, the textile driving mechanism being provided with two driving wheels and a driven wheel, the two driving wheels and the driven wheel being arranged in parallel, a gap for the textiles to pass through being provided between the driven wheel and the two driving wheels, the driven wheel being moved after the textiles are loaded to press the textiles against the two driving wheels respectively, the rotation directions of the two driving wheels being arranged in opposite directions, the feeding end of the textile driving mechanism being connected to the discharging end of the textile supporting mechanism, and the discharging end of the textile driving mechanism being connected to the storage part of the textile storage mechanism.
[0019] The beneficial technical effects of the present invention include: 1. The present invention can realize a series of tasks such as supporting and automatically leveling textiles, automatically conveying textiles, automatically collecting spectra of textiles and calculating color difference, etc., with a high degree of automation and intelligence, greatly reducing the labor intensity of operators, and effectively improving the efficiency of textile testing. At the same time, the testing environment is unified, and the influence of external factors on the test results can be avoided, thereby improving the detection accuracy. The support part of the real-time color difference calculation device for textiles drives the tested textile to move so as to keep it flat. It is suitable for color difference detection of flexible textiles, and can avoid the influence of wrinkles and holes caused by excessive stretching on the test results.
[0020] 2. The present invention can dynamically adjust the size of the supporting part according to the specification parameters of the textile, and is suitable for use in the detection of textiles of different specifications. It has a wide range of applications and good versatility. At the same time, the depth acquisition module preset by the real-time color difference calculation device for textiles continuously collects depth information of the textiles, which can realize real-time monitoring and real-time adjustment of the flatness of the textiles. By keeping the textiles flat, the accuracy of textile detection can be further improved.
[0021] 3. The present invention drives the textile to pass through the spectral collection station at a constant speed according to a preset transfer speed, so that the textile transfer speed can be adapted to the frame rate of the hyperspectral collection module, thereby maintaining the collection effect and ensuring the detection efficiency without missing samples.
[0022] 4. The present invention adopts a hyperspectral acquisition module to obtain the original spectral data of textiles through spectral acquisition, and can implement measurement and batch calculation of the LAB value and total color difference of textiles, and can further calculate the color difference value that meets international standards, which is convenient for classification and rating of textiles. At the same time, through regional averaging operation, it can avoid the interference of textile holes on the test results, has strong anti-interference ability, and can ensure the accuracy of the test results.
[0023] 5. The present invention can realize a series of tasks such as supporting and automatically leveling textiles, automatically conveying textiles, automatically collecting spectra of textiles and calculating color differences, etc. It has a high degree of automation and intelligence, greatly reduces the labor intensity of operators, and can effectively improve the efficiency of textile detection. At the same time, the light absorption module is used to avoid interfering light in the spectrum collection station, and the influence of external factors on the detection results can be avoided, thereby improving the detection accuracy. The depth acquisition module and the textile support mechanism are used to drive the movement of the textile to be tested to keep it flat. It is suitable for color difference detection of flexible textiles, and can avoid the influence of wrinkles and holes caused by excessive stretching on the detection results.
[0024] Other features and advantages of the present invention will be disclosed in detail in the following specific embodiments and drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] The present invention will be further described below in conjunction with the accompanying drawings: Figure 1 The figure is a workflow diagram of a method for calculating the real-time color difference of textiles based on hyperspectral. Figure 2 is a workflow diagram of step S2 in a method for calculating real-time color difference of textiles based on hyperspectral; Figure 3 is a workflow diagram of step S3 in a method for calculating real-time color difference of textiles based on hyperspectral; Figure 4 It is a structural schematic diagram of a real-time color difference calculation device for textiles based on hyperspectral; Figure 5 Schematic diagram of the structure of the textile support mechanism. DETAILED DESCRIPTION
[0026] The technical solutions of the embodiments of the present invention are explained and described below in conjunction with the drawings of the embodiments of the present invention, but the following embodiments are only preferred embodiments of the present invention, not all. Based on the embodiments in the implementation mode, other embodiments obtained by those skilled in the art without creative work are all within the protection scope of the present invention.
[0027] In the following description, terms such as "inside", "outside", "up", "down", "left", "right", etc. that indicate directions or positional relationships are only used to facilitate the description of the embodiments and simplify the description, and do not indicate or imply that the referred device or element must have a specific direction, be constructed and operate in a specific direction. Therefore, it should not be understood as a limitation of the present invention. Embodiment 1:
[0028] See also Figure 1 This embodiment discloses a method for calculating the real-time color difference of textiles based on hyperspectral, comprising the following steps: S1: Initializing the textile real-time color difference calculation device, installing the textile on the supporting part of the textile real-time color difference calculation device; S2: driving the textile to be tested to move through the supporting part of the textile real-time color difference calculation device to keep it flat, and driving the textile to pass through the spectrum collection stations in sequence; S3: The hyperspectral acquisition module 3 preset by the textile real-time color difference calculation device obtains the original spectrum data of the textile through spectrum acquisition, and outputs the real-time total color difference of the textile after calculation, so as to realize the comprehensive detection of the textile.
[0029] When the present embodiment is working, it can realize a series of tasks such as supporting and automatically leveling textiles, automatically conveying textiles, automatically collecting spectra of textiles and calculating color differences, etc. It has a high degree of automation and intelligence, greatly reduces the labor intensity of operators, can effectively improve the efficiency of textile detection, and unify the detection environment at the same time, can avoid the influence of external factors on the detection results, improve the detection accuracy, and drive the textile to be tested to move through the supporting part of the real-time color difference calculation device of the textile to keep it flat. It is suitable for color difference detection of flexible textiles, and can avoid the influence of wrinkles and holes caused by excessive stretching on the detection results.
[0030] In this embodiment, in step S2, when the textile to be tested is driven to move so as to keep it flat by the supporting part of the real-time color difference calculation device for textiles, the following steps are adopted to obtain the specification parameters of the textile, and drive the textile to be tested to move so as to keep it flat by changing the size of the supporting part of the real-time color difference calculation device for textiles.
[0031] Preferably, in step S2, when the textile to be tested is driven to move so as to keep it flat by the supporting part of the real-time color difference calculation device for textiles, the following steps are adopted: the depth information of the textile is continuously collected by the depth acquisition module 2 preset in the real-time color difference calculation device for textiles to obtain the real-time depth information of the textile, and whether the textile is flat is determined by calculating the depth information. When the textile is not flat, the size of the supporting part of the real-time color difference calculation device for textiles is changed to drive the textile to be tested to move so as to keep it flat.
[0032] See also Figure 2 In the specific implementation, in step S2, the depth information of the textile is continuously collected by the depth collection module 2 preset in the real-time color difference calculation device for textiles to obtain the real-time depth information of the textile. By calculating the depth information, it is judged whether the textile is flat. When the textile is not flat, the size of the supporting part of the real-time color difference calculation device for textiles is changed to drive the textile to be tested to move so that it remains flat. The following steps are adopted: A1: Obtaining a standard depth value obtained by the depth acquisition module 2 and the thickness of the textile; A2: Depth acquisition module 2 acquires depth information of the textile entering its detection area to obtain depth information of each point; A3: Subtract the depth information of each point from the standard depth value, take the absolute value of the difference and compare it with the preset depth threshold, and mark the points with depth greater than the threshold as abnormal points; A4: Count the number of abnormal points. When the proportion of abnormal points is greater than or equal to a preset smoothness threshold, the current state of the textile is determined to be uneven. The size of the supporting part of the textile real-time color difference calculation device is changed to drive the textile to be tested to move.
[0033] When this embodiment is working, it can dynamically adjust the size of the supporting part according to the specification parameters of the textile, and is suitable for use in the detection of textiles of different specifications. It has a wide range of applications and good versatility. At the same time, the depth acquisition module 2 preset by the real-time color difference calculation device for textiles continuously collects depth information of the textile, which can realize real-time monitoring and real-time adjustment of the flatness of the textile, and can further improve the accuracy of textile detection by keeping the textile flat.
[0034] As a further improvement of this embodiment, in step S2, when driving the textile to pass through the spectrum collection station in sequence, the following steps are adopted: the textile is connected to the head end of the textile through a preset drawing belt, and the reeling part of the textile reeling mechanism 5 preset by the textile real-time color difference calculation device is connected to the textile through the drawing belt, and the textile is driven to pass through the spectrum collection station in sequence at a uniform speed. The transfer speed of the textile is set by the following formula: ; Wherein: v is the conveying speed of the textile, x is the slit width, H is the distance from the collection part of the hyperspectral collection module 3 to the spectrum collection station, f is the focal length of the hyperspectral collection module 3, and fps is the frame rate of the hyperspectral collection module 3.
[0035] When this embodiment is working, by driving the textile to pass through the spectral collection station at a constant speed according to the preset transfer speed, the textile transfer speed can be adapted to the frame rate of the hyperspectral collection module 3, thereby maintaining the collection effect and ensuring the detection efficiency without missing samples.
[0036] Preferably, step S2 also includes the following steps: placing a correction circle on the textile, driving the correction circle to move with the textile, obtaining the ratio of the diameter of the correction circle in the displacement direction to the diameter in the perpendicular displacement direction to correct the transfer speed of the textile, which can achieve further adjustment of the transfer speed and facilitate the operator to make adaptive adjustments according to actual conditions, thereby ensuring the accuracy of the detection. Embodiment 2:
[0037] See also Figure 3 This embodiment provides a method for calculating real-time color difference of textiles based on hyperspectral. The similarities with other embodiments will not be repeated here, and the differences will be described in detail below.
[0038] In this embodiment, in step S3, the hyperspectral acquisition module 3 preset by the textile real-time color difference calculation device obtains the original spectrum data of the textile through spectrum acquisition, and when the real-time total color difference of the textile is output through calculation, the following steps are adopted: B1: The interference light in the spectrum collection station is removed by the light absorption module 6 preset in the real-time color difference calculation device for textiles, and the high spectrum collection module 3 preset in the real-time color difference calculation device for textiles obtains the original spectrum data of the textiles through spectrum collection; B2: Calculate the reflectance through the original spectrum data of the textile, and obtain several groups of LAB data from the reflectance; B3: Performing regional averaging operation on several groups of LAB data in the original spectral data of the textile to obtain a group of LAB data after regional averaging, calculating the LAB value of the group of LAB data, and then calculating and outputting the real-time total color difference of the textile.
[0039] When this embodiment is working, the hyperspectral acquisition module 3 is used to obtain the original spectral data of the textile through spectral acquisition, and the LAB value and total color difference of the textile can be measured and calculated in batches, and the color difference value that meets the international standards can be further calculated, which is convenient for classifying and grading the textiles. At the same time, through the regional averaging operation, the interference of textile holes on the detection results can be avoided, and the anti-interference ability is strong, which can ensure the accuracy of the detection results.
[0040] As a further improvement of this embodiment, in step B1, the following steps are also included: collecting dark background data and white board data, and correcting the original spectrum data and white board data of the textile by using the dark background data; In step B1, when correcting the original spectrum data of textiles and white board data by dark background data, the following calculation formula is used: ; ; in: is the dark background data, For the collected whiteboard data, This is the white board data after black field correction. The original spectral data of textiles collected. It is the original spectrum data of textile after black field correction; In step B2, when calculating the reflectance using the original spectral data of the textile, the following calculation formula is used: ; in: is the reflectivity.
[0041] Preferably, in step B2, when several groups of LAB data are obtained by reflectivity calculation, the following steps are adopted to obtain the current tristimulus values by reflectivity calculation, and call the tristimulus values of the completely reflecting diffuser under the standard lighting body to calculate the LAB value, and repeatedly obtain several groups of LAB data in sequence.
[0042] In step B2, when the current tristimulus value is calculated from the reflectivity, the following calculation formula is used: ; ; ; Among them: X, Y, Z are the current three stimulus values, is the relative spectral power distribution of the standard illuminant, , , is the spectral tristimulus value of the CIE standard observer, is the wavelength interval, and k is a normalization constant.
[0043] In step B2, when the LAB value is calculated by calling the tristimulus values of a completely reflecting diffuser under a standard illumination body, the following calculation formula is used: ; ; ; in: , , is the LAB value, , , It is the tristimulus value of a completely reflecting diffuser under standard lighting. is a color space conversion function. In this embodiment, It can be defined as the following formula: ; in: Value .
[0044] Preferably, in step B3, when a group of LAB data after regional average is obtained by regional averaging operation on several groups of LAB data in the original spectral data of the textile, the following steps are adopted: the number of average pixels is set to n, for several groups of LAB data, a pixel is selected as the center, and n pixels are selected above, below, left and right of the pixel, and a total of pixels, for The pixel points are averaged to get the value of the center point. The window size is used as the sliding window, and it slides from left to right in turn, sliding the corresponding number of pixels each time according to the preset step size, and sliding from top to bottom, sliding the corresponding number of pixels each time according to the preset step size, until all the pixels of several groups of LAB data are slid, and a new group of LAB data is obtained. When working, it is necessary to select the n value according to the actual specification parameters of the textile. For example, for stockings with different needle counts, the holes in stockings with 0 to 300 needle counts are relatively large. At this time, the n value can be 7, which can avoid the influence of holes on the detection results to a certain extent. In the needle count range of 301 to 512, the n value can be 5, and in the needle count range of 513 to 720, the n value can be 3. When the needle count is above 721, the stockings have no holes that interfere with color difference detection, and the n value can be 1.
[0045] In step B3, a group of LAB data after regional averaging is obtained by performing regional averaging operation on several groups of LAB data in the original spectral data of the textile. When calculating the LAB value of the group of LAB data, the following steps are adopted: when the number of surrounding pixels plus the number of its own pixels satisfies the central pixel, For pixels, the LAB value after regional averaging is updated using the following formula: ; ; ; in: , , is the LAB value after regional averaging, , , is the LAB value before regional averaging, , , for The mean value of pixels; For pixels that do not meet the requirements, the following formula is used to update the LAB value after regional averaging: ; ; ; In step B3, the following calculation formula is used to calculate and output the total color difference of the textile in real time: ; in: is the total color difference of textiles, , , The current color and the standard color respectively. , , Preferably, the total color difference can also be compared with the threshold value in the GSC grade standard, and the GSC grade of the textile can be determined according to the comparison result. At the same time, the total color difference can also be calculated in real time by any existing standard calculation method of CIE2000 and CMC. Embodiment three:
[0046] This embodiment provides a method for calculating real-time color difference of textiles based on hyperspectral. The similarities with other embodiments are not repeated here, and the differences are described in detail below.
[0047] In this embodiment, in order to further improve the efficiency of textile detection, the color difference defects of textiles can be detected while detecting the defects of textiles, which greatly improves the production efficiency and reduces the outflow of defective products. At the same time, for elastic textiles, they have a certain shrinkage stress. Some relatively hidden defects or defects such as needle path defects and missed needle defects are also more difficult to detect under the action of shrinkage stress. In this embodiment, in the step S2, the following steps are also included: obtaining the specification parameters of the textile, and driving the textile to be tested to stretch it to a suitable specification and keep it flat by changing the size of the end of the supporting part of the real-time color difference calculation device for the textile according to a preset stretch ratio table. In the specific implementation, the stretch ratio of the textile needs to be customized according to the specifications of the textile to be tested, so as to achieve that the textile located near the head end of the textile transfer route in the spectral acquisition station is kept flat and does not stretch, and the textile located near the end of the textile transfer path in the spectral acquisition station is stretched to a suitable specification and kept flat.
[0048] In the step S3, the following steps are also included: after calculating and outputting the total color difference of the textile located in the spectral collection station near the head end of the textile transfer route, the total color difference of the textile in the stretched state and the unstretched state of the part of the textile is synchronously output, and whether the textile has a defect is determined by comparing whether the total color difference of the textile exceeds a preset threshold. During operation, the holes of the textile can be enlarged by stretching the textile. At this time, in the original spectral data of the textile, the textile area is a valid area. When calculating, the total color difference of the textile is calculated for this part. When a defect occurs in the textile, a large deviation will occur in the total color difference of the textile in the stretched state and the unstretched state. The deviation will show an accelerated growth trend according to the change in the stretching ratio. By selecting a suitable stretching ratio, the accuracy of textile defect detection can be further improved to avoid the outflow of defective products. When calculating the total color difference of the textile in the stretched state and the unstretched state, the following formula is used: ; ; ; ; in: is the total color difference between the textile in the stretched state and the unstretched state, k is the correction coefficient. In specific implementation, it needs to be selected according to the actual hairiness value of the textile. Generally, the selection range is 0.4 to 1, which can avoid the misjudgment of holes caused by flying feathers; , and They are the differences in LAB values between the current color and the color of the textile when it is not stretched; , and It is the LAB value of the textile in the stretched state; , and It is the LAB value of the textile in the unstretched state. Embodiment 4:
[0049] See also Figure 4 This embodiment provides a textile real-time color difference calculation device based on hyperspectrum, and applies a textile real-time color difference calculation method based on hyperspectrum as in the above embodiment, including: The light source module 1 is used to provide a light source with adjustable angle and uniform illumination; Depth acquisition module 2 is used to acquire color information and depth information in the spectrum acquisition station. When working, a ToF 3D camera can be used, and of course any other suitable depth acquisition camera can be used; A hyperspectral acquisition module 3, used for acquiring spectral data in a spectral acquisition station; A textile support mechanism 4, used to support textiles of different specifications to keep them flat according to the collected depth information; A textile winding mechanism 5, used for transferring the textile through the spectrum collection station and winding up the textile after the inspection; Light absorption module 6, used to avoid interfering light in the spectrum collection station; The light-emitting part of the light source module 1, the collection part of the depth collection module 2 and the collection part of the hyperspectral collection module 3 are all connected to the optical path of the spectral collection station. The textile support mechanism 4 and the textile winding mechanism 5 are respectively arranged on both sides of the spectral collection station. The light-absorbing part of the light-absorbing module 6 is arranged on the periphery of the spectral collection station. Preferably, the real-time color difference calculation device for textiles can also be deployed in a darkroom environment to avoid interference from stray light in the overlapping bands of external natural light and the hyperspectral collection module 3. The supporting part of the textile support mechanism 4 moves after the depth collection module 2 collects the depth information of the textile to drive the textile to remain flat. The speed of the textile winding mechanism 5 to move the textile is set to keep synchronization with the collection work of the hyperspectral collection module 3.
[0050] When the present embodiment is working, it can realize a series of tasks such as supporting and automatically leveling textiles, automatically conveying textiles, automatically collecting spectra of textiles and calculating color differences, etc. It has a high degree of automation and intelligence, greatly reduces the labor intensity of operators, and can effectively improve the efficiency of textile detection. At the same time, the light absorption module 6 is used to avoid interfering light in the spectrum collection station, and the influence of external factors on the detection results can be avoided, thereby improving the detection accuracy. The depth acquisition module 2 and the textile support mechanism 4 are used to drive the textile to be tested to move so as to keep it flat. It is suitable for color difference detection of flexible textiles, and can avoid the influence of wrinkles and holes caused by excessive stretching on the detection results.
[0051] See also Figure 5 In a specific implementation, the textile support mechanism 4 includes at least two support rods 41, a transverse slide rail 42 and a driving device 43. The transverse slide rail 42 is extended and arranged in a direction perpendicular to the moving direction of the textile. The support rods 41 can be slidably limited and installed on the transverse slide rail 42. Adjacent support rods 41 remain parallel. Each support rod 41 is connected to the driving device 43 through a corresponding transmission assembly. The spacing between adjacent support rods 41 is adjusted under the drive of the driving device 43 to flatten the supported textile. Preferably, the depth acquisition module 2 collects the depth information of the textile when the textile moves to the spectrum acquisition station to obtain the depth information of several points on the textile. The spacing between adjacent support rods 41 is adjusted by comparing the depth information of each point with the preset standard depth value.
[0052] During operation, the connection portion between the material storage portion and the material discharge portion of the support rod 41 can be set to an S shape, which can prevent the textiles installed on the support rod 41 from being pulled out completely, thereby ensuring the uniformity of the material discharge. Preferably, a light-absorbing material can also be sprayed on the support rod 41 to avoid interference with reflected light caused by the reflection of the support rod 41. Preferably, it also includes a horizontal support module 8, which is arranged on the side of the spectrum collection station close to the textile winding mechanism 5, and the supporting portion of the horizontal support module 8 is arranged below the textile transfer path, so that the material discharge portion of the support rod 41 is kept flush with the supporting portion of the horizontal support module 8, which can prevent the textiles from vibrating during transfer and ensure the flatness of the textiles.
[0053] Preferably, the textile winding mechanism 5 includes a textile driving mechanism 51 for uniformly transferring the textile at a preset transfer speed and a textile storage mechanism 52 for storing the inspected textiles. The textile driving mechanism 51 is provided with two driving wheels 511 and a driven wheel 512. The two driving wheels 511 and the driven wheel 512 are arranged in parallel. There is a gap between the driven wheel 512 and the two driving wheels 511 for the textiles to pass through. The driven wheel 512 moves after the textiles are loaded to press the textiles against the two driving wheels 511 respectively. The rotation directions of the two driving wheels 511 are set to be opposite. The feeding end of the textile driving mechanism 51 is connected to the discharging end of the textile supporting mechanism 4, and the discharging end of the textile driving mechanism 51 is connected to the storage part of the textile storage mechanism 52.
[0054] Preferably, it also includes an angle adjustment mechanism 7, and the hyperspectral acquisition module 3 is installed on the rotating part of the angle adjustment mechanism 7. When working, the acquisition angle of the hyperspectral acquisition module 3 can be adjusted by the angle adjustment mechanism 7, such as 10° angle observation and 2° angle observation, etc., which can simulate the observation angle of the human eye and facilitate the unification of the working conditions of color difference detection.
[0055] The beneficial technical effects of this embodiment include: the present invention can realize a series of tasks such as supporting and automatically leveling textiles, automatically conveying textiles, automatically collecting spectra of textiles and calculating color differences, etc., with a high degree of automation and intelligence, greatly reducing the labor intensity of operators, and can effectively improve the efficiency of textile detection. At the same time, the detection environment is unified, and the influence of external factors on the detection results can be avoided, thereby improving the detection accuracy. The support part of the real-time color difference calculation device for textiles drives the movement of the textile to be tested to keep it flat, which is suitable for color difference detection of flexible textiles and can avoid the influence of wrinkles and holes caused by excessive stretching on the detection results.
[0056] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Those skilled in the art should understand that the present invention includes but is not limited to the contents described in the drawings and the above specific embodiments. Any modification that does not deviate from the functional and structural principles of the present invention will be included in the scope of the claims.
Claims
1. A method for calculating real-time color difference of textiles based on hyperspectral, characterized in that: The following steps are involved: S1: Initializing the textile real-time color difference calculation device, installing the textile on the supporting part of the textile real-time color difference calculation device; S2: driving the textile to be tested to move through the supporting part of the textile real-time color difference calculation device to keep it flat, and driving the textile to pass through the spectrum collection stations in sequence; S3: The hyperspectral acquisition module (3) preset in the textile real-time color difference calculation device obtains the original spectrum data of the textile through spectrum acquisition, and outputs the real-time total color difference of the textile through calculation.
2. The method for calculating the real-time color difference of textiles based on hyperspectral according to claim 1, characterized in that: In step S2, when the textile to be tested is driven to move so as to keep it flat by the supporting part of the textile real-time color difference calculation device, the following steps are adopted to obtain the specification parameters of the textile, and drive the textile to be tested to move so as to keep it flat by changing the size of the supporting part of the textile real-time color difference calculation device.
3. The method for calculating the real-time color difference of textiles based on hyperspectral according to claim 1, characterized in that: In step S2, when the textile to be tested is driven to move so as to keep it flat by the support part of the textile real-time color difference calculation device, the following steps are adopted: the depth information of the textile is continuously collected by the depth collection module (2) preset in the textile real-time color difference calculation device to obtain the real-time depth information of the textile, and whether the textile is flat is determined by calculating the depth information. When the textile is not flat, the size of the support part of the textile real-time color difference calculation device is changed to drive the textile to be tested to move so as to keep it flat.
4. The method for calculating the real-time color difference of textiles based on hyperspectral according to claim 3, characterized in that: In step S2, the depth information of the textile is continuously collected by the depth collection module (2) preset in the textile real-time color difference calculation device to obtain the real-time depth information of the textile. By calculating the depth information, it is determined whether the textile is flat. When the textile is not flat, the size of the support part of the textile real-time color difference calculation device is changed to drive the textile to be tested to move so that it remains flat. The following steps are adopted: A1: Obtaining a standard depth value obtained by the depth acquisition module (2) and the thickness of the textile; A2: The depth acquisition module (2) acquires depth information of the textile entering its detection area to obtain depth information of each point; A3: Subtract the depth information of each point from the standard depth value, take the absolute value of the difference and compare it with the preset depth threshold, and mark the points with depth greater than the threshold as abnormal points; A4: Count the number of abnormal points. When the proportion of abnormal points is greater than or equal to a preset smoothness threshold, the current state of the textile is determined to be uneven. The size of the supporting part of the textile real-time color difference calculation device is changed to drive the textile to be tested to move.
5. The method for calculating textile color difference in real time based on hyperspectral according to claim 1, characterized in that: In step S2, when driving the textile to pass through the spectrum collection station in sequence, the following steps are adopted: a preset pulling belt is connected to the head end of the textile, and a reeling part of a textile reeling mechanism (5) preset by the textile real-time color difference calculation device is connected to the textile through the pulling belt, and the textile is driven to pass through the spectrum collection station in sequence at a uniform speed. The transfer speed of the textile is set by the following formula: ; Wherein: v is the conveying speed of the textile, x is the slit width, H is the distance between the collection part of the hyperspectral collection module (3) and the spectrum collection station, f is the focal length of the hyperspectral collection module (3), and fps is the frame rate of the hyperspectral collection module (3).
6. The method for calculating the real-time color difference of textiles based on hyperspectral according to claim 1, characterized in that: In step S3, the hyperspectral acquisition module (3) preset in the textile real-time color difference calculation device obtains the original spectrum data of the textile through spectrum acquisition, and when the real-time total color difference of the textile is output through calculation, the following steps are adopted: B1: The interference light in the spectrum collection station is removed by a light absorption module (6) preset in the real-time color difference calculation device for textiles, and the original spectrum data of the textile is obtained by spectrum collection by a high spectrum collection module (3) preset in the real-time color difference calculation device for textiles; B2: Calculate the reflectance through the original spectrum data of the textile, and obtain several groups of LAB data from the reflectance; B3: Performing regional averaging operation on several groups of LAB data in the original spectral data of the textile to obtain a group of LAB data after regional averaging, calculating the LAB value of the group of LAB data, and then calculating and outputting the real-time total color difference of the textile.
7. A textile real-time color difference calculation device based on hyperspectral, using a textile real-time color difference calculation method based on hyperspectral as claimed in any one of claims 1 to 6, characterized in that: include: A light source module (1) is used to provide a light source with adjustable angle and uniform illumination; A depth acquisition module (2), used for acquiring color information and depth information in the spectrum acquisition station; A hyperspectral acquisition module (3), used for acquiring spectral data in a spectral acquisition station; A textile support mechanism (4), used for supporting textiles of different specifications to keep them flat according to the collected depth information; A textile winding mechanism (5) is used to transfer the textile through the spectrum collection station and to wind up the textile after the inspection is completed; A light absorption module (6) is used to prevent interfering light from appearing in the spectrum collection station; The light emitting part of the light source module (1), the collecting part of the depth collecting module (2) and the collecting part of the hyperspectral collecting module (3) are all connected to the optical path of the spectral collecting station; the textile supporting mechanism (4) and the textile rolling mechanism (5) are respectively arranged on both sides of the spectral collecting station; the light absorbing part of the light absorbing module (6) is arranged on the periphery of the spectral collecting station; the supporting part of the textile supporting mechanism (4) moves after the depth collecting module (2) collects the depth information of the textile to drive the textile to remain flat; the speed of the textile rolling mechanism (5) in transferring the textile is set to be synchronized with the collecting work of the hyperspectral collecting module (3).
8. The real-time color difference calculation device for textiles based on hyperspectral according to claim 7, characterized in that: The textile support mechanism (4) comprises at least two support rods (41), a transverse slide rail (42) and a drive device (43); the transverse slide rail (42) is arranged to extend in a direction perpendicular to the moving direction of the textile; the support rods (41) are slidably mounted on the transverse slide rail (42); adjacent support rods (41) are kept parallel; each support rod (41) is connected to the drive device (43) via a corresponding transmission assembly; and the spacing between adjacent support rods (41) is adjusted under the drive of the drive device (43) to level the supported textile.
9. The real-time color difference calculation device for textiles based on hyperspectral according to claim 8, characterized in that: The depth acquisition module (2) acquires depth information of the textile when the textile moves into the spectrum acquisition station to obtain depth information of a plurality of points on the textile, and the spacing between adjacent support rods (41) is adjusted by comparing the depth information of each point with a preset standard depth value.
10. The real-time color difference calculation device for textiles based on hyperspectral according to claim 7, characterized in that: The textile winding mechanism (5) comprises a textile driving mechanism (51) for uniformly transferring textiles at a preset transfer speed and a textile storage mechanism (52) for storing textiles that have been tested. The textile driving mechanism (51) is provided with two driving wheels (511) and a driven wheel (512). The two driving wheels (511) and the driven wheel (512) are arranged in parallel. A gap is provided between the driven wheel (512) and the two driving wheels (511) for the textiles to pass through. After the textiles are loaded, the driven wheel (512) moves to press the textiles onto the two driving wheels (511) respectively. The rotation directions of the two driving wheels (511) are arranged in opposite directions. The feeding end of the textile driving mechanism (51) is connected to the discharging end of the textile supporting mechanism (4), and the discharging end of the textile driving mechanism (51) is connected to the storage part of the textile storage mechanism (52).
Citation Information
Patent Citations
Fabric flatness evaluation method based on combination of three-dimensional image and two-dimensional image characteristics
CN110070532A
Textile color detection system, color detection method and material detection method
CN115077704A
Spectral imaging device for assisting identification of painting and calligraphy cultural relics
CN219016065U
Silk spindle spectrum detection device
CN219777482U
Method and apparatus for the automated inspection and grading of fabrics and fabric samples
US20040184639A1
Cited By
EVA and POE composite material irradiation quality evaluation method based on near-infrared hyperspectrum
CN121540666A
EVA and POE composite material irradiation quality evaluation method based on near infrared hyperspectrum
CN121540666B
Detection method and system for safety air bag production
CN121612887A