Intelligent detection system and method for fabric density based on machine vision
Patent Information
- Application Number
- CN202611028811.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-10
- Publication Date
- 2026-10-30
AI Technical Summary
[0004]然而,实际生产环境中获取的织物图像受到光照不均、表面毛羽、污渍噪声以及织物微小形变因素的干扰,算法对该干扰敏感,泛化能力较差;将基于数据驱动的智能检测模型利用到织物纹理分析中,提升了特征提取的水平;但织物纹理具有多尺度和强方向性特征,现有的常规特征提取网络在处理纱线交织结构时,不能同时兼顾高频细节与全局方向特征,导致复杂纹理的表示不够精确;面对高分辨率的织物图像数据,在进行数据划分和并行处理时,割裂了织物本身连续的空间结构,无法适应特征分布的稀疏性与重叠性,易造成局部边缘信息的丢失;现有的特征分析多停留在像素层面,无法建立图拓扑结构来检测纱线节点间的隐式交互关系,限制了特征提取的深度
[0022]上述技术方案通过对织物图像执行多尺度Curvelet变换并构建纱线方向能量谱,结合谱熵度量纹理复杂度,并利用高斯混合模型对变换系数进行概率性聚类,以生成带有重叠区域的数据子集;随后,将各子集内的局部极值系数映射为图节点,基于特征相似度与空间邻近度计算连接权重,并利用由谱熵标定的阈值建立节点间的拓扑连接,最后配合图注意力网络对节点信息进行聚合更新,并由混合注意力模块对各子集的初步预测值与图级特征进行置信度评估与融合处理。
Smart Images

Figure CN123015385A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of machine vision technology. More specifically, this invention relates to a machine vision-based intelligent fabric density detection system and method. Background Technology
[0002] Fabric density testing relies on manual visual inspection or counting with the aid of a density microscope, which is easily affected by the visual fatigue and subjective experience of quality inspectors, resulting in inconsistent and inaccurate test results.
[0003] Currently, fabric density detection uses image processing-based detection methods. Early machine vision methods relied on traditional algorithms such as Fourier transform, grayscale projection, or wavelet transform to extract texture periodic features and calculate density.
[0004] However, fabric images acquired in actual production environments are affected by uneven lighting, surface fuzz, stains, noise, and minute fabric deformations. Algorithms are sensitive to this interference and exhibit poor generalization ability. While data-driven intelligent detection models have been applied to fabric texture analysis to improve feature extraction, fabric textures possess multi-scale and strong directional characteristics. Existing conventional feature extraction networks, when processing yarn interweaving structures, cannot simultaneously consider high-frequency details and global directional features, resulting in inaccurate representations of complex textures. When dealing with high-resolution fabric image data, data partitioning and parallel processing fragment the continuous spatial structure of the fabric itself, failing to adapt to the sparsity and overlap of feature distributions, easily leading to the loss of local edge information. Existing feature analysis often remains at the pixel level, unable to establish graph topology to detect implicit interactions between yarn nodes, limiting the depth of feature extraction. In the integration stage of local prediction results, traditional models lack a confidence evaluation mechanism, failing to achieve the fusion of multi-scale information. Summary of the Invention
[0005] To address the aforementioned technical problems, the present invention provides solutions in the following aspects.
[0006] In a first aspect, the present invention provides a machine vision-based intelligent fabric density detection system, comprising the following modules:
[0007] The generation module is used to acquire fabric images and perform multi-scale Curvelet transformation to obtain transformation coefficients. Based on the transformation coefficients, the yarn direction energy spectrum is constructed and the spectral entropy is calculated to represent the texture complexity. Based on the energy value and spatial distribution of the transformation coefficients, a Gaussian mixture model is used to probabilistically cluster the transformation coefficients to generate multiple overlapping data subsets. The membership degree of the transformation coefficient to each data subset is determined by the joint probability density of the energy value and spatial location. The preliminary prediction module uses local extremum coefficients within each data subset as graph nodes. It sets node features based on scale, orientation, coordinates, and transformation coefficients. Node connection weights are calculated based on feature similarity and spatial proximity. When a node connection weight exceeds a threshold calibrated by spectral entropy, connections are established between graph nodes, generating a relationship graph for each data subset. A graph attention network is deployed for each relationship graph, iteratively aggregating node information through an attention mechanism. Global pooling is used to extract graph-level features, and a fully connected regression layer outputs preliminary predictions of latitude and longitude density for each data subset based on these graph-level feature maps. The detection module is used to input the preliminary predicted values of latitude and longitude density and map-level features of each data subset into the hybrid attention module to calculate the confidence distribution. Based on the confidence distribution, the module performs confidence evaluation and weighted fusion on the results of different data subsets and outputs the fabric density detection results.
[0008] This invention utilizes multi-scale Curvelet transformation on fabric images to construct yarn direction energy spectra, combines spectral entropy to represent texture complexity, and employs a Gaussian mixture model for probabilistic clustering to generate overlapping data subsets. Local extremum coefficients are transformed into graph-structured data, and weights are calculated using feature similarity and spatial proximity. Node connections are established using thresholds calibrated by spectral entropy, and a graph attention network is used to delve into the spatial topological relationships between yarns, enhancing the model's ability to analyze and perceive fabric interweaving structures. A hybrid attention module performs confidence assessment on the preliminary prediction results of each data subset and graph-level features, and implements intelligent weighted fusion, integrating multi-dimensional information and suppressing detection biases caused by local noise and interference, thereby improving the accuracy of fabric warp and weft density detection results.
[0009] Preferably, the texture complexity is represented by constructing the yarn direction energy spectrum based on the transformation coefficients and calculating the spectral entropy. The energy of the transformation coefficients of the multi-scale Curvelet transform at the same direction and different scales is superimposed to generate a yarn direction energy spectrum representing the distribution of the yarn's dominant direction. The energy spectrum along the yarn direction is normalized to obtain the probability distribution sequence of energy in each direction relative to the total energy. The spectral entropy is obtained by calculating the entropy value of the probability distribution sequence using the Shannon information entropy formula.
[0010] The above technical solution quantifies texture complexity by introducing spectral entropy, providing an adaptive parameter adjustment basis for subsequent graph construction. When the texture is cluttered or noisy, spectral entropy can guide the model to automatically adjust the threshold, enhancing the system's adaptability to different types of fabrics.
[0011] Preferably, a Gaussian mixture model is used to probabilistically cluster the transform coefficients based on their energy values and spatial distribution, generating multiple overlapping data subsets. This includes: constructing a three-dimensional feature vector using the normalized energy values and two-dimensional spatial coordinates of the transform coefficients; initializing the distribution parameters of the Gaussian mixture model and iteratively updating the mean, covariance matrix, and mixture weights of each Gaussian component using the expectation-maximization algorithm; calculating the posterior probability of the three-dimensional feature vector of each transform coefficient under each convergent Gaussian component, and using the posterior probability as the membership degree of the transform coefficient to each data subset; and dividing the transform coefficient into one or more corresponding data subsets based on the condition that the membership degree is greater than a preset probability threshold.
[0012] The above technical solution adopts a soft clustering strategy instead of the traditional hard partitioning, and determines the membership degree through joint probability density. This allows for reasonable overlap between data subsets, effectively preventing the loss of edge yarn information caused by the disruption of spatial continuity when performing parallel processing or block division of high-resolution images. It ensures that each detection window can obtain sufficient structural context information.
[0013] Preferably, the node connection weights are calculated based on feature similarity and spatial proximity, including: normalizing the difference in scale and the difference in direction between two graph nodes, and calculating feature similarity using a negative exponential function; calculating spatial proximity using an exponential decay function of the Euclidean distance between the spatial coordinates of two graph nodes; multiplying feature similarity and spatial proximity to obtain the initial connection weights between graph nodes; mapping spectral entropy to a weight adjustment coefficient, setting a threshold using the weight adjustment coefficient, and using the initial connection weight as the node connection weight when the initial connection weight is higher than the threshold.
[0014] The above technical solution constructs edge weights by comprehensively considering scale, directional similarity, and spatial proximity, which can restore the topological relationship of the physical interweaving structure of the fabric. In addition, by using spectral entropy to dynamically map the weight threshold, a dynamic balance between noise filtering and structure preservation is achieved. Under complex textures, the connection threshold is increased to filter out background interference, and under simple textures, the threshold is decreased to maintain connectivity, ensuring that the generated relationship graph can truly reflect the warp and weft interweaving logic of the fabric.
[0015] Preferably, the node information is iteratively aggregated through an attention mechanism, graph-level features are extracted using global pooling, and preliminary predictions of the latitude and longitude density of each data subset are output. This includes: in the graph attention network, the attention coefficient is calculated based on the feature representations of adjacent graph nodes, and the features of neighboring graph nodes are weighted and summed using the attention coefficients to update the feature representation of the central graph node; after iterative updates through a multi-layer graph attention network, an average pooling mechanism is used as global pooling to aggregate the features of all graph nodes in each relation graph into a fixed-dimensional graph-level feature; the graph-level feature is input into a fully connected regression layer, and preliminary predictions of the latitude and longitude density of the corresponding data subset are output.
[0016] The above technical solution improves prediction accuracy by enabling the model to automatically learn the importance of adjacent nodes during information aggregation and assigning lower weights to abnormal nodes affected by feathers or stains in the self-attention layer. In addition, it compresses complex topological features into fixed-length graph-level vectors, solving the problem of inconsistent input graph sizes and enabling the model to directly output numerical estimates of longitudinal and latitudinal densities.
[0017] Preferably, the results from different data subsets are subjected to confidence assessment and weighted fusion to output fabric density detection results, including: The graph-level features of each data subset are concatenated and input into a multilayer perceptron to generate channel attention weight vectors. The channel attention weight vector is processed by a normalization function to obtain the confidence evaluation score for each data subset. The preliminary predicted warp and weft density values of each data subset are weighted and summed with the corresponding confidence assessment scores to output the fabric density detection results.
[0018] Secondly, the present invention provides a machine vision-based intelligent fabric density detection method, comprising the following steps: S1. Acquire fabric images and perform multi-scale Curvelet transformation to obtain transformation coefficients. Construct yarn direction energy spectrum based on transformation coefficients and calculate spectral entropy to represent texture complexity. Based on the energy value and spatial distribution of transformation coefficients, use Gaussian mixture model to probabilistically cluster transformation coefficients to generate multiple overlapping data subsets. The membership degree of transformation coefficients to each data subset is determined by the joint probability density of the energy value and spatial location. S2. The local extreme value coefficients within each data subset are used as graph nodes. Node features are set according to scale, direction, coordinates, and transformation coefficient values. Node connection weights are calculated based on feature similarity and spatial proximity. When the node connection weight is higher than the threshold calibrated by spectral entropy, connection relationships are constructed between graph nodes to generate a relationship graph for each data subset. A graph attention network is deployed for each relationship graph. Node information is iteratively aggregated through the attention mechanism. Global pooling is used to extract graph-level features, and preliminary predictions of latitude and longitude density for each data subset are output. S3. Input the preliminary predicted values of latitude and longitude density and map-level features of each data subset into the hybrid attention module to calculate the confidence distribution. Based on the confidence distribution, perform confidence evaluation and weighted fusion on the results of different data subsets, and output the fabric density detection results.
[0019] Preferably, the texture complexity is represented by constructing the yarn direction energy spectrum based on the transformation coefficients and calculating the spectral entropy. The energy of the transformation coefficients of the multi-scale Curvelet transform at the same direction and different scales is superimposed to generate a yarn direction energy spectrum representing the distribution of the yarn's dominant direction. The energy spectrum along the yarn direction is normalized to obtain the probability distribution sequence of energy in each direction relative to the total energy. The spectral entropy is obtained by calculating the entropy value of the probability distribution sequence using the Shannon information entropy formula.
[0020] Preferably, a Gaussian mixture model is used to probabilistically cluster the transform coefficients based on their energy values and spatial distribution, generating multiple overlapping data subsets. This includes: constructing a three-dimensional feature vector using the normalized energy values and two-dimensional spatial coordinates of the transform coefficients; initializing the distribution parameters of the Gaussian mixture model and iteratively updating the mean, covariance matrix, and mixture weights of each Gaussian component using the expectation-maximization algorithm; calculating the posterior probability of the three-dimensional feature vector of each transform coefficient under each convergent Gaussian component, and using the posterior probability as the membership degree of the transform coefficient to each data subset; and dividing the transform coefficient into one or more corresponding data subsets based on the condition that the membership degree is greater than a preset probability threshold.
[0021] Preferably, the node connection weights are calculated based on feature similarity and spatial proximity, including: normalizing the difference in scale and the difference in direction between two graph nodes, and calculating feature similarity using a negative exponential function; calculating spatial proximity using an exponential decay function of the Euclidean distance between the spatial coordinates of two graph nodes; multiplying feature similarity and spatial proximity to obtain the initial connection weights between graph nodes; mapping spectral entropy to a weight adjustment coefficient, setting a threshold using the weight adjustment coefficient, and using the initial connection weight as the node connection weight when the initial connection weight is higher than the threshold.
[0022] The above technical solution performs multi-scale Curvelet transformation on fabric images and constructs yarn direction energy spectra. It combines spectral entropy to measure texture complexity and uses a Gaussian mixture model to probabilistically cluster the transformation coefficients to generate data subsets with overlapping regions. Subsequently, the local extremum coefficients within each subset are mapped to graph nodes. Connection weights are calculated based on feature similarity and spatial proximity. Topological connections between nodes are established using thresholds calibrated by spectral entropy. Finally, a graph attention network is used to aggregate and update node information. A hybrid attention module performs confidence evaluation and fusion processing on the preliminary predicted values of each subset and graph-level features.
[0023] This invention utilizes graph structure data and a self-attention mechanism to mine the spatial topological relationships between yarns, effectively enhancing the model's ability to analyze and perceive the interweaving structure of fabrics, and achieving deep extraction of yarn features against complex texture backgrounds.
[0024] Furthermore, by implementing confidence-based intelligent weighted fusion of the multi-subset prediction results, multi-dimensional graph-level feature information is integrated, which can effectively suppress detection bias caused by local noise or environmental interference, and effectively improve the accuracy and stability of the fabric warp and weft density detection results. Attached Figure Description
[0025] The above and other objects, features, and advantages of exemplary embodiments of the present invention will become readily apparent upon reading the following detailed description with reference to the accompanying drawings. In the drawings, several embodiments of the invention are illustrated by way of example and not limitation, and like or corresponding reference numerals denote like or corresponding parts, wherein: Figure 1 This is a schematic diagram of the energy spectrum along the yarn direction; Figure 2 This is a diagram illustrating the confidence assessment of each data subset; Figure 3 This is a diagram showing the comparison of the average relative errors of each model. Detailed Implementation
[0026] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0027] In this invention, a machine vision-based intelligent fabric density detection system is provided, comprising: The generation module is used to acquire fabric images and perform multi-scale Curvelet transformation to obtain transformation coefficients. Based on the transformation coefficients, the yarn direction energy spectrum is constructed and the spectral entropy is calculated to represent the texture complexity. Based on the energy value and spatial distribution of the transformation coefficients, a Gaussian mixture model is used to probabilistically cluster the transformation coefficients to generate multiple overlapping data subsets. The membership degree of the transformation coefficient to each data subset is determined by the joint probability density of the energy value and spatial location.
[0028] Specifically, the fabric image captured by the digital industrial camera is read, the RGB color image is converted into a grayscale image matrix, and the grayscale image matrix is decomposed into multiple scales and directions to obtain the Curvelet transform coefficient matrix at different scales and angles.
[0029] The transformation coefficient matrix is traversed at various scales and angles. The sum of the squares of the absolute values of the transformation coefficients at each angle is calculated as the energy value, thereby constructing a one-dimensional array of yarn direction energy spectrum. The one-dimensional array of yarn direction energy spectrum is normalized to obtain a probability distribution sequence. The spectral entropy value of the probability distribution sequence is calculated according to the Shannon entropy formula. The larger the spectral entropy value, the higher the complexity of the fabric texture.
[0030] Furthermore, the energy value of each transformation coefficient and its horizontal and vertical coordinates in the original image matrix are extracted as three-dimensional feature vectors, and the Gaussian Mixture model algorithm of the Scikit-learn machine learning library is called to fit all three-dimensional feature vectors.
[0031] During the clustering phase, the posterior probability of each transform coefficient belonging to each cluster is calculated. This posterior probability is the membership degree determined by the joint probability density of the energy value and spatial location. A lower membership degree threshold is set, and transform coefficients with a posterior probability greater than this threshold are assigned to their corresponding clusters. Since the posterior probability of the same transform coefficient for different clusters may be greater than this lower threshold simultaneously, multiple subsets of transform coefficient data with data overlap are generated. If the posterior probability of a transform coefficient for all clusters is less than this lower threshold, it is forcibly assigned to the unique cluster with the highest posterior probability according to the principle of maximum posterior probability.
[0032] In an optional embodiment, constructing the yarn direction energy spectrum based on the transformation coefficients and calculating the spectral entropy to represent the texture complexity includes: The energy of the transformation coefficients of the multi-scale Curvelet transform at the same direction and different scales is superimposed to generate a yarn direction energy spectrum representing the distribution of the yarn's dominant direction. The energy spectrum along the yarn direction is normalized to obtain the probability distribution sequence of energy in each direction relative to the total energy. The spectral entropy is obtained by calculating the entropy value of the probability distribution sequence using the Shannon information entropy formula.
[0033] It should be noted that in the multi-scale Curvelet transformation stage, the number of scales is set to 4 to 6, for example, the scale parameter J is set to 5. The number of directions at different scales increases layer by layer from the inside to the outside. For example, the angle is divided into 16, 32 or 64 discrete directions.
[0034] Furthermore, the calibration method for the number of scales and directions of the multi-scale Curvelet transform specifically includes: obtaining the spatial resolution at the current camera working distance, measuring the maximum physical interlacing period and minimum yarn diameter of the target fabric, and calculating the highest and lowest cutoff frequencies in the image space corresponding to the two; calculating the octave band based on the cutoff frequency span, rounding it up to determine that the scale parameter J equals 5; simultaneously obtaining the maximum natural torsion angle deviation of the target yarn during the physical twisting process, using it as the lower limit constraint for angle discretization, and uniformly dividing the semi-circular space from 0° to 180° into 32 discrete directions based on the lower limit constraint. This setting ensures that the transform basis function is highly isomorphic to the physical dimensions of the underlying fabric.
[0035] For each transformation coefficient obtained in complex form, the square of its modulus is calculated as the energy value.
[0036] The energy values at all different scales belonging to the same angle are summed to construct a yarn direction energy spectrum containing multiple discrete directions; the yarn direction energy spectrum distribution is as follows. Figure 1 As shown, the probability distribution characteristics of yarn energy at different directional angles from 0° to 180° are presented.
[0037] Divide the energy value in each direction by the total energy. For example, when the number of directions is set to 32, obtain the probability distribution sequence of energy in each direction relative to the total energy. Calculate the spectral entropy using the Shannon information entropy formula. For example, for a plain weave fabric image, the yarn energy is concentrated in the two orthogonal warp and weft directions, and the calculated spectral entropy is usually in the range of 1.5 to 2. For a jacquard fabric image, the energy is relatively dispersed in each direction, and the calculated spectral entropy is in the range of 3.5 to 4.2. This achieves numerical quantification of the fabric texture complexity.
[0038] In an optional embodiment, a Gaussian mixture model is used to probabilistically cluster the transform coefficients based on their energy values and spatial distribution, generating multiple overlapping data subsets, including: A three-dimensional feature vector is constructed using the energy values of the normalized transformation coefficients and the two-dimensional spatial coordinates; Initialize the distribution parameters of the Gaussian mixture model, and iteratively update the mean, covariance matrix and mixture weights of each Gaussian component using the expectation-maximization algorithm; Calculate the posterior probability of the three-dimensional feature vector of each transform coefficient under each convergent Gaussian component, and use the posterior probability as the membership degree of the transform coefficient to each data subset. Based on the condition that the membership degree is greater than a preset probability threshold, the transformation coefficients are divided into one or more corresponding data subsets.
[0039] The energy values of all Curvelet transform coefficients are mapped to the range of 0 to 1, and the image spatial coordinates corresponding to the coefficients are also normalized to the range of 0 to 1, thereby constructing a three-dimensional feature vector of length 3.
[0040] For this set of three-dimensional feature vectors, the distribution parameters of the Gaussian mixture model are initialized using the K-Means++ algorithm. The number of Gaussian components is set to be between 4 and 8. In this embodiment, K is set to 5, representing 5 potential data subsets. The mean vector of each component, the diagonal-initialized covariance matrix, and the equally distributed mixture weights are initialized.
[0041] Furthermore, the method for calibrating the number of Gaussian components in the Gaussian mixture model specifically includes: constructing a low-level physical state map of the fabric image and performing topological decomposition on the physical affiliation of pixels within the field of view; strictly mapping all pixels into five independent physical topological states: warp yarn body, weft yarn body, warp and weft interlacing overlap area, yarn gap background, and free hair noise; directly mapping the total number of categories of this independent physical state to the number of potential feature clusters in the Gaussian mixture model, thereby calibrating the number of Gaussian components K to be equal to 5, so that each Gaussian component of the clustering algorithm has clear physical tissue semantic support.
[0042] During the iterative update phase, the E-step and M-step are executed alternately using the expectation-maximization algorithm to calculate the response of each eigenvector to each Gaussian component and update the parameters. The maximum number of iterations is set to 100 or the rate of change of the log-likelihood function between two iterations is less than one ten-thousandth as the convergence condition.
[0043] Furthermore, the method for calibrating the convergence condition of the expectation-maximization algorithm specifically includes: obtaining the rated operating linear speed of the conveyor belt in the industrial site and the trigger frequency of the time-series image frames of the camera; calculating the limit time window that the system can call between two adjacent frames of time-series data; running a single expectation-maximization iteration on the underlying computing platform to obtain the single-step time-series calculation delay; dividing the limit time window by the single-step time-series calculation delay, and rounding down after reserving 20% system redundancy to obtain the maximum number of iterations under hardware constraints as 100; and simultaneously, combining the extreme value of system noise fluctuation, setting the rate of change of the log-likelihood function between two iterations to be less than one ten-thousandth as an auxiliary convergence threshold, thereby ensuring the accuracy of feature clustering while meeting the stringent time-series requirements of online monitoring.
[0044] After the model converges, the posterior probability value calculated for each three-dimensional feature vector under each Gaussian component is set as the membership degree of the coefficient to the corresponding data subset.
[0045] The preset probability threshold is set to a range of 0.15 to 0.25. In this embodiment, it is set to 0.2. When the membership degree of a certain transformation coefficient to a certain subset is greater than or equal to 0.2, the coefficient is assigned to that subset. The sum of the membership degrees of the same coefficient to different subsets is 1. The probability threshold-based determination method enables the coefficient to be assigned to two or three different subsets at the same time, realizing overlapping clustering of spatial and energy feature dimensions.
[0046] Furthermore, the calibration method for the preset probability threshold specifically includes: during the system initialization phase, acquiring an image of the edge transition zone of a standard yarn using a calibration camera, and extracting the optical point diffusion distribution curve of the corresponding physical yarn edge; calculating the process of the main energy peak at the center of the yarn decaying to both sides, and locating the physical boundary where the energy decays to 20% of the center peak; using the energy percentage corresponding to this physical boundary as the physical lower limit of the spatial overlap probability of the Gaussian mixture model, thereby fixing the preset probability threshold to 0.2. This calibration method ensures that the overlapping area of soft clustering strictly matches the physical blur boundary of the actual yarn in optical imaging, avoiding blindly setting values based on experience without physical meaning.
[0047] The preliminary prediction module uses local extremum coefficients within each data subset as graph nodes. It sets node features based on scale, direction, coordinates, and transformation coefficients. It calculates node connection weights based on feature similarity and spatial proximity. When a node connection weight is higher than a threshold calibrated by spectral entropy, it constructs connections between graph nodes, generating a relationship graph for each data subset. It deploys a graph attention network for each relationship graph, iteratively aggregates node information through an attention mechanism, extracts graph-level features using global pooling, and outputs preliminary predictions of latitude and longitude density for each data subset based on the graph-level feature mapping through a fully connected regression layer.
[0048] Specifically, for each subset of data, local maxima are found in the absolute value matrix of coefficients and used as graph nodes in the graph structure algorithm. The scale index, orientation index, x-coordinate, y-coordinate, and absolute value of the transformation coefficients corresponding to each graph node are concatenated into a five-dimensional vector as the node feature of that graph node. The spatial Euclidean distance between any two graph nodes is calculated. The differences in scale and orientation between any two graph nodes are calculated and substituted into a negative exponential function to obtain feature similarity. The spatial Euclidean distance is mapped to spatial proximity using the negative exponential function, and the spatial proximity is multiplied by the feature cosine similarity to obtain the node connection weight.
[0049] It should be noted that graph-level features are specifically represented as a graph-level feature vector with a fixed dimension.
[0050] Construct a threshold function, subtract the attenuation coefficient from the preset benchmark value and use the product of the calculated spectral entropy value as the calibrated threshold; traverse all node pairs, and when the node connection weight between two nodes is higher than the calibrated threshold, add an undirected edge between the two graph nodes to complete the construction of the topology of the graph corresponding to each data subset.
[0051] Based on the PyTorch framework, graph attention network models are constructed for each relation graph. During the forward propagation of the graph attention network model, the weight coefficients of neighboring nodes are determined by the graph attention layer using a self-attention mechanism, and the features of neighboring nodes are weighted and aggregated accordingly to achieve iterative updates of node information. Global average pooling is used to map the aggregated node features into graph-level feature vectors of fixed dimensions. The graph-level feature vectors are input into a multilayer perceptron consisting of multiple fully connected layers for regression calculation, and a two-dimensional floating-point vector is output as the preliminary predicted values of the longitudinal and latitudinal densities of the data subset.
[0052] In an optional embodiment, node connection weights are calculated based on feature similarity and spatial proximity, including: The differences in scale and angle between two graph nodes are normalized, and the feature similarity is calculated using a negative exponential function. Spatial proximity is calculated using the exponential decay function of the Euclidean distance between the spatial coordinates of two graph nodes; Multiplying feature similarity by spatial proximity yields the initial connection weights between graph nodes; The spectral entropy is mapped to a weight adjustment coefficient. A threshold is set using the weight adjustment coefficient. When the initial connection weight is higher than the threshold, the initial connection weight is used as the node connection weight.
[0053] It should be noted that, in order to avoid feature drift and recognition failure based on local isolated pixels caused by uncontrollable stains, noise and abnormal hairs on the surface of fabrics in industrial sites, the local extreme value coefficients are converted into graph nodes and combined with spatial proximity to construct a global topological connection relationship, so as to accurately lock the real physical interlacing skeleton of the yarn under complex interference.
[0054] For any two graph nodes with scale, orientation angle, and spatial coordinates respectively, calculate their absolute difference in scale and divide it by the maximum scale number to obtain the normalized scale difference; calculate the difference in orientation angle and divide it by 180 degrees to obtain the normalized angle difference; substitute the weighted sum of the two into a negative exponential function to calculate the feature similarity, where the scaling factors for scale and orientation are, for example, 1.5 and 2 respectively.
[0055] Furthermore, the calibration methods for the scale scaling factor and direction scaling factor in feature similarity calculation specifically include: extracting the longitudinal physical continuous length and transverse physical diameter of the yarn in the standard fabric sample, and calculating the anisotropy ratio of the yarn's physical morphology; since the stiffness of the physical yarn in the extension direction is much greater than the difficulty of deformation of its diameter, that is, the physical resistance to abrupt changes in direction is greater than the resistance to abrupt changes in scale, the feature distance is penalized and weighted according to this anisotropy ratio; the scale scaling factor reflecting the change in transverse width is set to 1.5, and the direction scaling factor reflecting the change in longitudinal stiffness is set to 2, so that the calculation model of the connection weight between graph nodes strictly fits the anisotropic interweaving characteristics of the yarn in the real physical three-dimensional space.
[0056] Simultaneously calculate the Euclidean distance between the normalized spatial coordinates of two nodes, and calculate spatial proximity using an exponential decay function with a decay coefficient of, for example, 1. Calculate the initial connection weights, ranging from 0 to 1, by multiplying the feature similarity and spatial proximity. Construct a linear mapping function that varies with spectral entropy to set the weight threshold for graph connections. The mapping relationship is defined as a baseline value minus the product of the decay coefficient and the spectral entropy; for example, the baseline value is 0.8 and the decay coefficient is 0.1. For instance, when dealing with a fabric with a spectral entropy of 2, the calculated threshold is 0.6; when dealing with a fabric with a spectral entropy of 4, the calculated threshold is 0.4. Edges with initial connection weights higher than the threshold are retained and used as node connection weights between graph nodes.
[0057] In an optional embodiment, node information is iteratively aggregated through an attention mechanism, graph-level features are extracted using global pooling, and preliminary predictions of latitude and longitude density for each data subset are output, including: In a graph attention network, attention coefficients are calculated based on the feature representations of neighboring graph nodes. The feature representations of the central graph node are then updated by weighted summation of the attention coefficients on the features of the neighboring graph nodes. After iterative updates through a multi-layer graph attention network, average pooling is used as the global pooling mechanism to aggregate the features of all graph nodes in each relation graph into a fixed-dimensional graph-level feature. Input the graph-level features into the fully connected regression layer, and output the preliminary predicted values of latitude and longitude density of the corresponding data subset.
[0058] In each layer of the graph attention network, the features of each node are linearly transformed using a shared learnable weight matrix. The features of the center node are concatenated with the features of its neighboring nodes, and a weight vector 'a' is applied to the concatenated features. After processing with a LeakyReLU activation function with a preset negative slope and Softmax normalization, the attention coefficients between the center node and each neighboring node are determined. ; Utilizing attention coefficient The transformed features of neighboring nodes are weighted and summed, and the feature representation of the center node is updated using the ELU activation function; the update formula is as follows: ; in, This is the updated feature representation of the central node. This represents the activation function. This represents the set of neighboring nodes of the central node. Here, represents the attention coefficient, and W is the shared learnable weight matrix. Features of the central node These are the characteristics of neighboring nodes.
[0059] In terms of network structure, for example, a graph convolutional layer with three stacked layers and a four-head attention mechanism is used to map and expand the node features layer by layer to 128-dimensional features. After the iterative update, an average pooling mechanism is used as global pooling to perform an arithmetic average operation on the node dimension of the 128-dimensional feature vectors of all nodes in the relation graph, and aggregate them into a fixed-dimensional 128-dimensional graph-level feature vector. This graph-level feature is input into a fully connected regression layer composed of two multilayer perceptrons with the number of hidden layer neurons configured from 128 to 64 to 2. The output is an array of preliminary predicted values containing longitudinal and latitudinal densities, with the variable unit being every 10 cm.
[0060] It should be added that the acquisition of the above-mentioned attenuation coefficient includes: in the offline test before the equipment leaves the factory, the spatial Euclidean distance distribution law is extracted based on the fabric sample of standard density, the node connectivity attenuation rate is recorded by high-frequency sampling at different distances, and the absolute value of the slope of the fitted curve is directly extracted as the attenuation coefficient by performing linear regression fitting on the connectivity data of multiple physical samples.
[0061] The acquisition of the above benchmark values includes: for an ideal fabric calibration board that is absolutely clean and flawless, running multi-scale feature extraction and recording its background spectral entropy response, reading the minimum weight boundary required by the underlying feature processing module to maintain topological full connectivity under this ideal state, and directly solidifying this physical boundary constant as the benchmark value.
[0062] The acquisition of the aforementioned preset negative slope includes: capturing the activation function dead zone log of the underlying chip when processing the edge of high-frequency fuzz noise, locating the critical response slope that prevents the weak signal of the effective yarn from being forced to zero by the hardware, and compensating and setting the result of the calculation of this small value as the preset negative slope.
[0063] In this way, the local discrete extrema are transformed into a graph structure with topological relationships. This not only avoids the weakness of feature dimensions under a single scale, but also accurately filters out random noise at the physical level through adaptive adjustment of attention weights, effectively stabilizing the underlying foundation of density numerical regression.
[0064] The detection module is used to input the preliminary predicted values of latitude and longitude density and map-level features of each data subset into the hybrid attention module to calculate the confidence distribution. Based on the confidence distribution, the module performs confidence evaluation and weighted fusion on the results of different data subsets and outputs the fabric density detection results.
[0065] In the PyTorch framework, a hybrid attention module is constructed, which concatenates the graph-level feature vectors of each data subset with the corresponding preliminary latitude and longitude density predictions to form a comprehensive feature vector sequence. This comprehensive feature vector sequence is then input into the channel attention branch and spatial attention branch of the hybrid attention module to calculate the attention weight score of each comprehensive feature vector. The attention weight scores of all data subsets are normalized, and the normalized scores are used as the confidence evaluation scores of the prediction results for each data subset.
[0066] The preliminary predicted warp and weft density values of each data subset are multiplied by their corresponding confidence scores and then weighted and summed. The optimal two-dimensional regression value obtained after weighted fusion is rounded down and used as the measurement index for warp and weft yarn counts, respectively. The warp and weft density detection results of the fabric are output through the standard output stream.
[0067] In an optional embodiment, the results from different subsets of data are subjected to confidence evaluation and weighted fusion to output fabric density detection results, including: The graph-level features of each data subset are concatenated and input into a multilayer perceptron to generate channel attention weight vectors. The channel attention weight vector is processed by a normalization function to obtain the confidence evaluation score for each data subset. The preliminary predicted warp and weft density values of each data subset are weighted and summed with the corresponding confidence assessment scores to output the fabric density detection results.
[0068] Further explanation is needed. For example, if five overlapping data subsets are generated, graph-level features of 128 dimensions are extracted sequentially from the outputs of these five subsets. The initial 2D latitude and longitude density predictions of each subset are then concatenated along the feature channel dimensions to form a (128+2)×5, or 650-dimensional, joint feature vector. This joint feature vector is then input into a multilayer perceptron with the number of neurons in one channel attention branch configured sequentially as 650, 256, 64, and 5. The multilayer perceptron structure includes an input layer, multiple hidden layers, and an output layer. Its input is the concatenated joint feature vector, and its output is the channel attention weight vector. The forward propagation calculation formula is... ,in For the input vector, and This is the weight matrix from layer 1 to layer n. and The bias vectors from layer 1 to layer n. Let y be the activation function and y be the output vector. By performing cross-correlation analysis on the global structural features, a one-dimensional channel attention weight vector of length 5 is output. This joint feature vector is then input into the spatial attention branch, where the weight coefficients of each subset in the spatial dimension are calculated using one-dimensional convolution and the Sigmoid activation function, resulting in a spatial attention weight vector of length 5. Finally, the channel attention weight vector and the spatial attention weight vector are multiplied element-wise to obtain the comprehensive attention weight vector.
[0069] The generated channel attention weight vector is input into the Softmax normalization function, which transforms it into a probability distribution where each element's value is between 0 and 1 and the sum is 1. This yields the confidence evaluation score for each data subset, for example, evaluation score vectors of 0.4, 0.3, 0.15, 0.1, and 0.05. The confidence evaluation score distribution for each data subset is as follows: Figure 2 As shown, the scores decrease sequentially with the subset number, reflecting the difference in the contribution of different data subsets to the fabric density prediction results.
[0070] This ablation experiment was conducted using a multi-class fabric density detection dataset. This dataset contains 6000 images of plain weave, twill weave, and jacquard fabrics of different specifications, divided into training, validation, and test sets in an 8:1:1 ratio. The experiment was run on a deep learning workstation equipped with a high-performance graphics card. The initial learning rate of the network model was set to 0.1%, and a moment estimation optimizer was used to update the model parameters. The training batch size was set to 16, and the maximum number of training epochs was 200. The experiment used the mean absolute error and mean relative error of warp and weft density predictions as quantitative evaluation metrics for model accuracy.
[0071] Four different network structures were set up. The baseline model only used multi-scale transformation combined with the basic graph attention network for density prediction. Model 2 added a connection weight threshold mechanism based on spectral entropy calculation on the basis of the baseline. Model 3 utilized the probabilistic feature overlap clustering mechanism of Gaussian mixture model on the basis of Model 2. The complete scheme model added a multi-subset confidence evaluation and weighted fusion module on the basis of Model 3.
[0072] Specific experimental data show that: the baseline model has a mean absolute error of 3.52 roots per 10cm and a mean relative error of 1.85%; the mean absolute error of model two decreases to 2.86 roots per 10cm and the mean relative error is 1.42%; the mean absolute error of model three decreases to 2.15 roots per 10cm and the mean relative error is 1.1%; the complete scheme model achieves the best performance, with a mean absolute error of only 1.28 roots per 10cm and a mean relative error as low as 0.65%. The comparison results of the mean relative error of models under different network structure configurations are as follows: Figure 3 As shown, the stepwise improvement trend of model prediction accuracy is presented after gradually utilizing the spectral entropy threshold mechanism, probabilistic overlapping clustering strategy, and confidence weighted fusion module.
[0073] Thresholding based on spectral entropy reduced the mean absolute error by 0.66 roots, demonstrating that the mechanism can preserve the core topological structure and filter out invalid connections based on fabric texture complexity. The use of Gaussian mixture models reduced the relative error, validating that the probabilistic overlapping clustering strategy can fully explore potential subset associations of features in both spatial and energy dimensions. The confidence-weighted fusion mechanism reduced the mean absolute error by 0.87 roots compared to the previous version, proving that global attention evaluation can identify and integrate the optimal prediction results of various subsets, thereby achieving fabric density detection.
[0074] This invention also discloses a machine vision-based intelligent fabric density detection method, the method comprising: The fabric image is acquired and multi-scale Curvelet transformation is performed to obtain the transformation coefficients. Based on the transformation coefficients, the yarn direction energy spectrum is constructed and the spectral entropy is calculated to represent the texture complexity. Based on the energy value and spatial distribution of the transformation coefficients, a Gaussian mixture model is used to probabilistically cluster the transformation coefficients to generate multiple overlapping data subsets. The membership degree of the transformation coefficient to each data subset is determined by the joint probability density of the energy value and spatial location. The local extremum coefficients within each data subset are used as graph nodes. Node features are set according to scale, direction, coordinates, and transformation coefficient values. Node connection weights are calculated based on feature similarity and spatial proximity. When the node connection weight is higher than the threshold calibrated by spectral entropy, a connection relationship is constructed between graph nodes to generate a relationship graph for each data subset. A graph attention network is deployed for each relationship graph. Node information is iteratively aggregated through the attention mechanism. Graph-level features are extracted using global pooling. Based on graph-level feature mapping, a fully connected regression layer is used to output the preliminary predicted values of latitude and longitude density for each data subset. The preliminary predicted values of latitude and longitude density and map-level features of each data subset are input into the hybrid attention module to calculate the confidence distribution. Based on the confidence distribution, the results of different data subsets are evaluated and weighted and fused to output the fabric density detection results.
[0075] In an optional embodiment, constructing the yarn direction energy spectrum based on the transformation coefficients and calculating the spectral entropy to represent the texture complexity includes: The energy of the transformation coefficients of the multi-scale Curvelet transform at the same direction and different scales is superimposed to generate a yarn direction energy spectrum representing the distribution of the yarn's dominant direction. The energy spectrum along the yarn direction is normalized to obtain the probability distribution sequence of energy in each direction relative to the total energy. The spectral entropy is obtained by calculating the entropy value of the probability distribution sequence using the Shannon information entropy formula.
[0076] In an optional embodiment, a Gaussian mixture model is used to probabilistically cluster the transform coefficients based on their energy values and spatial distribution, generating multiple overlapping data subsets, including: A three-dimensional feature vector is constructed using the energy values of the normalized transformation coefficients and the two-dimensional spatial coordinates; Initialize the distribution parameters of the Gaussian mixture model, and iteratively update the mean, covariance matrix and mixture weights of each Gaussian component using the expectation-maximization algorithm; Calculate the posterior probability of the three-dimensional feature vector of each transform coefficient under each convergent Gaussian component, and use the posterior probability as the membership degree of the transform coefficient to each data subset. Based on the condition that the membership degree is greater than a preset probability threshold, the transformation coefficients are divided into one or more corresponding data subsets.
[0077] In an optional embodiment, node connection weights are calculated based on feature similarity and spatial proximity, including: The differences in scale and angle between two graph nodes are normalized, and the feature similarity is calculated using a negative exponential function. Spatial proximity is calculated using the exponential decay function of the Euclidean distance between the spatial coordinates of two graph nodes; Multiplying feature similarity by spatial proximity yields the initial connection weights between graph nodes; The spectral entropy is mapped to a weight adjustment coefficient. A threshold is set using the weight adjustment coefficient. When the initial connection weight is higher than the threshold, the initial connection weight is used as the node connection weight.
[0078] In an optional embodiment, node information is iteratively aggregated through an attention mechanism, graph-level features are extracted using global pooling, and preliminary predictions of latitude and longitude density for each data subset are output, including: In a graph attention network, attention coefficients are calculated based on the feature representations of neighboring graph nodes. The feature representations of the central graph node are then updated by weighted summation of the attention coefficients on the features of the neighboring graph nodes. After iterative updates through a multi-layer graph attention network, average pooling is used as the global pooling mechanism to aggregate the features of all graph nodes in each relation graph into a fixed-dimensional graph-level feature. Input the graph-level features into the fully connected regression layer, and output the preliminary predicted values of latitude and longitude density of the corresponding data subset.
[0079] In an optional embodiment, the results from different subsets of data are subjected to confidence evaluation and weighted fusion to output fabric density detection results, including: The graph-level features of each data subset are concatenated and input into a multilayer perceptron to generate channel attention weight vectors. The channel attention weight vector is processed by a normalization function to obtain the confidence evaluation score for each data subset. The preliminary predicted warp and weft density values of each data subset are weighted and summed with the corresponding confidence assessment scores to output the fabric density detection results.
[0080] The system also includes other components well known to those skilled in the art, such as communication buses and communication interfaces, the settings and functions of which are known in the art and will not be described in detail here.
[0081] In the description of this specification, "multiple" or "several" means at least two, such as two, three or more, unless otherwise expressly and specifically defined.
[0082] While this specification has shown and described numerous embodiments of the invention, it will be apparent to those skilled in the art that such embodiments are provided by way of example only. Many modifications, alterations, and alternatives will occur to those skilled in the art without departing from the spirit and essence of the invention. It should be understood that various alternatives to the embodiments of the invention described herein may be employed in the practice of this invention.
Claims
1. A machine vision-based intelligent fabric density detection system, characterized in that, Includes the following modules: The generation module is used to acquire fabric images and perform multi-scale Curvelet transformation to obtain transformation coefficients. Based on the transformation coefficients, the yarn direction energy spectrum is constructed and the spectral entropy is calculated to represent the texture complexity. Based on the energy value and spatial distribution of the transformation coefficients, a Gaussian mixture model is used to probabilistically cluster the transformation coefficients to generate multiple overlapping data subsets. The membership degree of the transformation coefficient to each data subset is determined by the joint probability density of the energy value and spatial location. The preliminary prediction module uses local extreme value coefficients within each data subset as graph nodes, sets node features based on scale, direction, coordinates, and transformation coefficients, calculates node connection weights based on feature similarity and spatial proximity, and constructs connections between graph nodes when the node connection weights are higher than the threshold calibrated by spectral entropy, generating a relationship graph for each data subset. A graph attention network is deployed for each relationship graph, iteratively aggregates node information through an attention mechanism, extracts graph-level features using global pooling, and outputs preliminary prediction values of latitude and longitude density for each data subset based on the graph-level feature mapping through a fully connected regression layer. The detection module is used to input the preliminary predicted values of latitude and longitude density and map-level features of each data subset into the hybrid attention module to calculate the confidence distribution. Based on the confidence distribution, the module performs confidence evaluation and weighted fusion on the results of different data subsets and outputs the fabric density detection results.
2. The system according to claim 1, characterized in that, Based on the transformation coefficients, the yarn direction energy spectrum is constructed and the spectral entropy is calculated to represent the texture complexity, including: The energy of the transformation coefficients of the multi-scale Curvelet transform at the same direction and different scales is superimposed to generate a yarn direction energy spectrum representing the distribution of the yarn's dominant direction. The energy spectrum along the yarn direction is normalized to obtain the probability distribution sequence of energy in each direction relative to the total energy. The spectral entropy is obtained by calculating the entropy value of the probability distribution sequence using the Shannon information entropy formula.
3. The system according to claim 1, characterized in that, Based on the energy values and spatial distribution of the transform coefficients, a Gaussian mixture model is used to probabilistically cluster the transform coefficients, generating multiple overlapping data subsets. This includes: constructing a three-dimensional feature vector using the normalized energy values and two-dimensional spatial coordinates of the transform coefficients; initializing the distribution parameters of the Gaussian mixture model and iteratively updating the mean, covariance matrix, and mixture weights of each Gaussian component using the expectation-maximization algorithm; calculating the posterior probability of the three-dimensional feature vector of each transform coefficient under each convergent Gaussian component, and using the posterior probability as the membership degree of the transform coefficient to each data subset; and dividing the transform coefficient into one or more corresponding data subsets based on the condition that the membership degree is greater than a preset probability threshold.
4. The system according to claim 1, characterized in that, The node connection weights are calculated based on feature similarity and spatial proximity, including: normalizing the difference in scale and the difference in direction between two graph nodes, and calculating feature similarity using a negative exponential function; calculating spatial proximity using an exponential decay function of the Euclidean distance between the spatial coordinates of two graph nodes; multiplying feature similarity and spatial proximity to obtain the initial connection weights between graph nodes; mapping spectral entropy to a weight adjustment coefficient, setting a threshold using the weight adjustment coefficient, and using the initial connection weight as the node connection weight when the initial connection weight is higher than the threshold.
5. The system according to claim 1, characterized in that, The system iteratively aggregates node information through an attention mechanism, extracts graph-level features using global pooling, and outputs preliminary predictions of latitude and longitude density for each data subset. This includes: in the graph attention network, calculating attention coefficients based on the feature representations of adjacent graph nodes, using the attention coefficients to perform a weighted summation of the features of neighboring graph nodes, and updating the feature representation of the central graph node; after iterative updates through a multi-layer graph attention network, using average pooling as global pooling to aggregate the features of all graph nodes within each relation graph into a fixed-dimensional graph-level feature; inputting the graph-level feature into a fully connected regression layer, and outputting preliminary predictions of latitude and longitude density for the corresponding data subset.
6. The system according to claim 1, characterized in that, The results from different data subsets are evaluated for confidence and weighted and fused to output the fabric density detection results, including: The graph-level features of each data subset are concatenated and input into a multilayer perceptron to generate channel attention weight vectors. The channel attention weight vector is processed by a normalization function to obtain the confidence evaluation score for each data subset. The preliminary predicted warp and weft density values of each data subset are weighted and summed with the corresponding confidence assessment scores to output the fabric density detection results.
7. A machine vision-based intelligent fabric density detection method, characterized in that, Includes the following steps: S1. Acquire fabric images and perform multi-scale Curvelet transform to obtain transform coefficients. Construct yarn direction energy spectra based on transform coefficients and calculate spectral entropy to represent texture complexity. Use a Gaussian mixture model to probabilistically cluster the transform coefficients based on their energy values and spatial distribution, generating multiple overlapping data subsets. The membership degree of each transform coefficient to each data subset is determined by the joint probability density of the energy value and spatial location. S2. Use local extremum coefficients within each data subset as graph nodes. Set node features based on scale, direction, coordinates, and transform coefficient values. Then, based on feature similarity and... Spatial proximity calculation is used to determine the node connection weights. When the node connection weights are higher than the threshold calibrated by spectral entropy, connections are established between graph nodes to generate relationship graphs for each data subset. A graph attention network is deployed for each relationship graph, and node information is iteratively aggregated through the attention mechanism. Global pooling is used to extract graph-level features, and the preliminary predicted values of latitude and longitude density for each data subset are output. S3: The preliminary predicted values of latitude and longitude density and graph-level features of each data subset are input into the hybrid attention module to calculate the confidence distribution. Based on the confidence distribution, the results of different data subsets are evaluated for confidence and weighted and fused to output the fabric density detection results.
8. The method according to claim 7, characterized in that, Based on the transformation coefficients, the yarn direction energy spectrum is constructed and the spectral entropy is calculated to represent the texture complexity, including: The energy of the transformation coefficients of the multi-scale Curvelet transform at the same direction and different scales is superimposed to generate a yarn direction energy spectrum representing the distribution of the yarn's dominant direction. The energy spectrum along the yarn direction is normalized to obtain the probability distribution sequence of energy in each direction relative to the total energy. The spectral entropy is obtained by calculating the entropy value of the probability distribution sequence using the Shannon information entropy formula.
9. The method according to claim 7, characterized in that, Based on the energy values and spatial distribution of the transform coefficients, a Gaussian mixture model is used to probabilistically cluster the transform coefficients, generating multiple overlapping data subsets. This includes: constructing a three-dimensional feature vector using the normalized energy values and two-dimensional spatial coordinates of the transform coefficients; initializing the distribution parameters of the Gaussian mixture model and iteratively updating the mean, covariance matrix, and mixture weights of each Gaussian component using the expectation-maximization algorithm; calculating the posterior probability of the three-dimensional feature vector of each transform coefficient under each convergent Gaussian component, and using the posterior probability as the membership degree of the transform coefficient to each data subset; and dividing the transform coefficient into one or more corresponding data subsets based on the condition that the membership degree is greater than a preset probability threshold.
10. The method according to claim 7, characterized in that, The node connection weights are calculated based on feature similarity and spatial proximity, including: normalizing the difference in scale and the difference in direction between two graph nodes, and calculating feature similarity using a negative exponential function; calculating spatial proximity using an exponential decay function of the Euclidean distance between the spatial coordinates of two graph nodes; multiplying feature similarity and spatial proximity to obtain the initial connection weights between graph nodes; mapping spectral entropy to a weight adjustment coefficient, setting a threshold using the weight adjustment coefficient, and using the initial connection weight as the node connection weight when the initial connection weight is higher than the threshold.