Image pixel discriminative screening method based on l2.0 norm sparse operator and irrelevance constraint
Patent Information
- Application Number
- CN202410337090.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-22
- Publication Date
- 2026-10-20
- Estimated Expiration
- 2044-03-22
AI Technical Summary
尽管提出模型有效提升了特征子集质量,但仍存在以下三个问题:1)图学习优化过程使得模型时间复杂度与样本数量的平方成正比,在处理大规模数据时时间开销将爆炸式增长;2)由于各种正则项的引入,模型中超参数过多,使得调参难度大幅增加,泛化性能降低;3)模型仍使用2,1范数执行稀疏优化,无法与特征选择数量显式对应,可解释性较差
[0042]本发明提出的一种基于2,0范数稀疏算子与不相关约束的图像像素判别性筛选方法,提出了一种无超参数的特征选择模型,并将其应用于图像数据处理任务,名为基于2,0范数稀疏算子与不相关约束的图像像素判别性筛选方法,在结合稀疏算子2,0范数和不相关线性判别分析模型的基础上,构建高泛化性能的无超参数模型,其中2,0范数能够将投影矩阵非零行数量与特征选择数量显式对应,且不相关约束能够保证所选子集之间统计学不相关,进而自适应获取非冗余且包含图像数据判别信息的关键特征子集,以期实现对图像数据像素的高效判别性筛选。
Smart Images

Figure CN118608821B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of image recognition and classification and pattern recognition, and relates to a method based on 2,0 A discriminative selection method for image pixels using norm sparse operators and uncorrelated constraints. Background Technology
[0002] Due to the rapid development of communication technology, massive amounts of data in the real world often exhibit high dimensionality. However, a large number of these data contain useless, redundant, or even interfering information that affects downstream processing tasks such as clustering and classification. These features not only drastically increase the time cost of data processing but also significantly reduce the accuracy of downstream classification tasks. Therefore, dimensionality reduction techniques, by mining the potential information in features, are indispensable for improving both efficiency and accuracy in data processing tasks. Dimensionality reduction can generally be divided into two types: feature extraction and feature selection. The former projects the original features into a low-dimensional space, combines them using specific coefficients, and generates a new subspace basis. Feature selection methods directly select the most representative and information-rich subset of features to achieve dimensionality reduction. Compared to feature extraction, feature selection methods preserve the original structure and semantic information of image data features, offering stronger interpretability and facilitating subsequent data visualization and analysis. Therefore, feature selection methods are crucial in the preprocessing of image classification and text recognition tasks.
[0003] Jiang Bingbing et al. ("Semi-supervised feature selection based on adaptive graph learning". Journal of Electronics, 2022, 50(07):1643-1652.) proposed a feature selection method based on adaptive information nearest neighbor graph construction. This method organically combines sparse projection learning of the feature subspace with reliable information nearest neighbor graph construction, achieving more discriminative feature subset selection while considering local structure. Although the proposed model effectively improves the quality of feature subsets, it still has the following three problems: 1) The graph learning optimization process makes the model's time complexity proportional to the square of the number of samples, leading to an explosive increase in time overhead when processing large-scale data; 2) Due to the introduction of various regularization terms, the model has too many hyperparameters, significantly increasing the difficulty of parameter tuning and reducing generalization performance; 3) The model still uses... 2,1 Norms, when used for sparse optimization, cannot be explicitly correlated with the number of feature selections, resulting in poor interpretability. Therefore, for text recognition and image classification systems, there is an urgent need to research interpretable and efficient feature selection methods without hyperparameters.
[0004] Existing feature selection methods often rely on easily optimized convex sparsity constraints. 2,1The sparse norm yields a row-sparse subspace projection matrix. On one hand, the row sparsity of this sparse norm is too low, typically selecting suboptimal subsets. On the other hand, its sparsity needs to be tuned via hyperparameters, which cannot explicitly correspond to the varying number of features selected as user needs, thus worsening model interpretability. Furthermore, existing feature selection methods often improve the quality of selected feature subsets by adding regularization terms such as relaxation graph clustering, ridge regression, and mutual information optimization. However, excessive regularization terms also mean a large number of hyperparameters without concrete physical meaning, increasing model complexity and further complicating parameter tuning, hindering the model's widespread application. Summary of the Invention
[0005] Technical problems to be solved
[0006] To avoid the shortcomings of existing technologies, this invention proposes a method based on 2,0 A discriminative selection method for image pixels using norm sparse operators and uncorrelated constraints.
[0007] Technical solution
[0008] A type based on 2,0 A discriminative image pixel selection method using norm sparse operators and uncorrelated constraints is characterized by the pixel selection model containing only two integer parameters with explicit physical meaning: the subspace dimension m and the number of image pixels to be selected k. The method steps are as follows:
[0009] Step 1: Stretch and merge the dataset consisting of n a×b pixel images into a single image data matrix. Where n is the total number of images, and d = a × b is the number of pixels in a single image;
[0010] Step 2: Perform feature normalization on the data matrix X′ so that the mean of the processed data matrix is 0 and the standard deviation is 1. Let the normalized image data matrix be denoted as .
[0011] Step 3: Define the sample label matrix according to the following rules. Where c is the number of image categories: when the data vector x of the i-th image... i When it belongs to class j, y ij =1, otherwise 0;
[0012] Calculate the intra-class scatter matrix S w With the overall divergence matrix S t :
[0013]
[0014] in, The sample label matrix is constructed from the sample labels;
[0015] Step 4: Map the data matrix X to the projection matrix of the low-dimensional subspace. Where m is the dimension of the subspace;
[0016] Apply l to W 2,0 Norm sparse operators and form equality constraints ||W|| 2,0 =k, so that the number of non-zero rows in the projection matrix W is consistent with the number of pixels selected;
[0017] Based on l 2,0 The equation constraints of norm sparse operators and the uncorrelated linear discriminant analysis model are integrated to obtain the following main model:
[0018]
[0019] Among them, I m This represents an m-dimensional identity matrix, where k is the number of image pixels filtered; benefiting from l 2,0 Norm equality constraints explicitly correspond the number of pixels filtered, k, to the number of non-zero rows in W.
[0020] Perform matrix decomposition on W, i.e., W = VR, where V ∈ {0,1} d×k The feature selection indicator matrix satisfies V T 1 d =1 k , It is a non-zero projection matrix;
[0021] Define a set and feature filtering index set There are no duplicate elements and the following conditions are met: and
[0022] The set The correspondence between the matrix and matrix V:
[0023] Based on this correspondence, the constraint V∈{0,1} d×k and V T 1 d =1 k Let Ω be the unified symbol, and the proposed master model be transformed into the following problem to be solved:
[0024]
[0025] Step 5: Randomly initialize the set and the corresponding matrix V;
[0026] Step 6: Calculation and Simultaneously optimize column j of V, v. jGiven (j = 1, 2, ..., k) and R, we obtain the optimal feature selection indicator matrix V and the feature selection index.
[0027] Step 7: Use the optimal feature selection indicator matrix V and feature selection index Select k out of all d pixels in the image data to achieve discriminative filtering of the image data pixels.
[0028] Step 6 optimizes the j-th column v of V. j The steps for (j = 1, 2, ..., k) and R are:
[0029] 1) Candidate index calculation: For v j Given d-k+1 candidate indicator indices for feature selection, solve the following problem:
[0030]
[0031] Where, the solution to R is... The eigenvectors are composed of the m smallest eigenvalues;
[0032] 2) Optimal objective function selection: Calculate the objective function of problem (3) optimized for each candidate index, select the minimum value of R and V, and realize v. j Simultaneous optimization with matrix R;
[0033] 3) Element update: For v j Assuming the feature index before optimization is α, and the feature index corresponding to the minimum value of the objective function is α′, when α′=α, no elements need to be updated; while when α′≠α, vectors are defined respectively. and And update according to the following rules and
[0034]
[0035] Repeat steps 1 through 3) to update the other columns of V one by one, while R is updated synchronously during this process; until V, The algorithm converges when R no longer changes, yielding the optimal feature selection indicator matrix V and feature selection index.
[0036] The sample label matrix is constructed as follows: when the data vector x of the i-th image... i When it belongs to class j, y ij =1, otherwise 0.
[0037] The number of image pixels selected, k, is set by the user and does not include regularization parameters or hyperparameters.
[0038] An electronic device is characterized by comprising a processor and a memory, wherein the processor is configured to implement the steps of the data migration method as described above when executing a computer program stored in the memory.
[0039] A readable storage medium, characterized in that a computer program is stored on the readable storage medium, and when the computer program is executed by a processor, it implements the steps of the data migration method described above.
[0040] A computer program product characterized by comprising computer-executable instructions, which, when executed, are used to implement the method described.
[0041] Beneficial effects
[0042] The present invention proposes a method based on 2,0 A discriminative image pixel selection method based on norm sparse operators and irrelevant constraints is proposed, which introduces a hyperparameter-free feature selection model and applies it to image data processing tasks. This model is named [Model Name - 1]. 2,0 A discriminative image pixel selection method combining norm-based sparse operators and uncorrelated constraints, further demonstrating the effectiveness of sparse operators. 2,0 Based on norm and uncorrelated linear discriminant analysis models, a high-generalization-performance hyperparameter-free model is constructed, in which... 2,0 The norm can explicitly correspond the number of non-zero rows in the projection matrix to the number of feature selections, and the uncorrelation constraint can ensure that the selected subsets are statistically uncorrelated. This allows for the adaptive acquisition of non-redundant key feature subsets that contain discriminative information of image data, in order to achieve efficient discriminative screening of image data pixels.
[0043] Its beneficial effects are as follows:
[0044] (1) This invention adopts 2,0 Norm equality constraints, on the one hand, avoid the introduction of additional regularization parameters, and on the other hand, enable the number of non-zero rows in the projection matrix to correspond explicitly to the number of feature selections, thereby improving the interpretability of the model.
[0045] (2) This invention only contains two explicit integer parameters, the number of subspaces m and the number of feature selections k, and k can usually be given directly by the user. Therefore, this invention has no hyperparameters, which greatly reduces the model tuning pressure and significantly improves the generalization performance of the model.
[0046] (3) As can be seen from step 7 in the technical solution, it is easy to ensure that under the selected feature subspace. The non-singularity of the problem ensures that there is no information loss in the solution process of problem (3), which can effectively improve the quality of the selected feature subset and improve the accuracy of downstream data processing tasks. Attached Figure Description
[0047] Figure 1 Image pixel filtering method flowchart
[0048] Figure 2 Flowchart of the specific implementation on the JAFFE face image dataset Detailed Implementation
[0049] The present invention will now be further described in conjunction with the embodiments and accompanying drawings:
[0050] The basic flowchart of image pixel selection in this invention is shown at the end of this document. Figure 1 As shown, the specific steps are as follows:
[0051] Step 1: Stretch and merge the dataset consisting of n a×b pixel images into a single image data matrix. Where n is the total number of images, and d = a × b is the number of pixels in a single image.
[0052] Step 2: Perform feature normalization on the elongated data matrix X′ so that the mean of the processed data matrix is 0 and the standard deviation is 1. Let the normalized image data matrix be denoted as .
[0053] Step 3: Define the sample label matrix according to the following rules. Where c is the number of image categories: when the data vector x of the i-th image... i When it belongs to class j, y ij =1, otherwise 0. Next, the within-class scatter matrix S is calculated using the following formula. w With the overall divergence matrix S t :
[0054]
[0055] Step 4: Design the projection matrix that maps the data matrix X to the low-dimensional subspace. Where m is the dimension of the subspace. To satisfy the row sparsity of the projection matrix, l is applied to W. 2,0 Norm sparse operators and form equality constraints ||W|| 2,0 =k, so that the number of non-zero rows in the projection matrix W is consistent with the number of selected pixels. This is then integrated with the uncorrelated linear discriminant analysis model to obtain the following problem to be solved:
[0056]
[0057] Among them, I m Let represent an m-dimensional identity matrix, and k be the number of image pixels to be filtered. Benefiting from l 2,0Norm equality constraints are applied, and the number of pixels selected, k, explicitly corresponds to the number of non-zero rows in W. To solve the above problem (2), we first perform matrix decomposition on W, i.e., W = VR, where V ∈ {0, 1}. d×k The feature selection indicator matrix satisfies V T 1 d =1 k , This is a non-zero projection matrix. Next, we define the set... and feature filtering index set There are no duplicate elements and the following conditions are met: and gather The correspondence between the matrix and V is as follows:
[0058]
[0059] Step 5: Randomly initialize the set And the corresponding matrix V.
[0060] Step 6: Calculation and
[0061] Step 7: Simultaneously optimize the j-th column v of V. j (j = 1, 2, ..., k) and R:
[0062] 1) Candidate index calculation: For v j Given d-k+1 candidate indicator indices for feature selection, solve the following problem:
[0063]
[0064] Where, the solution to R is... The eigenvectors are composed of the m smallest eigenvalues.
[0065] 2) Optimal objective function selection: Calculate the objective function of problem (3) optimized for each candidate index, select the minimum value of R and V, and realize v. j Simultaneous optimization with matrix R.
[0066] 3) Element update: For v j Assuming the feature index before optimization is α, and the feature index corresponding to the minimum value of the objective function is α′, when α′=α, no elements need to be updated; while when α′≠α, vectors are defined respectively. and And update according to the following rules and
[0067]
[0068] Step 8: Update the other columns of V one by one by repeating step 7, while R is updated synchronously during the process.
[0069] Step 9: When Step 8 ends, one round of updates for V and R is complete. Then, repeat Steps 7 and 8 until V, The algorithm converges when R no longer changes, yielding the optimal feature selection indicator matrix V and feature selection index for problem (2). To select k out of all d pixels in the image data, discriminative filtering of image data pixels is achieved. Specific implementation examples:
[0071] This invention proposes an image pixel discriminative selection method based on a complete set sparse operator and irrelevant constraints. The specific implementation steps for selecting key pixels using the JAFFE face image dataset are illustrated, but the technical content of this invention is not limited to the scope described herein. The JAFFE face image dataset contains 213 images of 32×32 pixels from 10 different faces, i.e., n = 213, d = 32×32 = 1024, and c = 10.
[0072] Implementation Step 1: Stretch and merge 213 images of size 32×32 pixels into a single image data matrix. This method aims to select k key pixels that contain important classification information while simultaneously removing useless pixels, where k is the number of pixels to be selected.
[0073] Implementation Step 2: For the image data matrix obtained in the previous step Perform feature orientation normalization, i.e., the matrix has zero columns and a standard deviation of 1. Let the normalized image data matrix be denoted as... This normalization method helps simplify the subsequent calculation of the scatter matrix.
[0074] Implementation Step 3: Calculate the intra-class scatter matrix S using the following formula. w With the overall divergence matrix S t :
[0075]
[0076] in, The sample label matrix is constructed from the sample labels, specifically as follows: when the data vector x of the i-th image... i When it belongs to class j, y ij =1, otherwise 0. It is worth noting that, due to the normalization process in step 2, each divergence matrix can be obtained directly using equation (1), simplifying matrix calculation.
[0077] Implementation Step 4: To solve l 2,1 The unclear explicit correspondence between the norm and the number of selected pixels (features) and the problem of the regularization term introducing additional regularization hyperparameters are addressed by using l. 2,0 Norm equality constraint ||W|| 2,0 =k, so that the number of non-zero rows in the projection matrix W is equal to the number of selected pixels. Based on this, the irrelevance constraints are integrated to achieve statistical irrelevance of subspace features, and a hyperparameter-free feature selection model based on linear discriminant analysis is constructed as follows:
[0078]
[0079] in, For the low-dimensional projection matrix, I m Let m represent an m-dimensional identity matrix, where m is the subspace dimension and k is the number of image pixels to be selected. Clearly, the pixel selection model proposed in this invention only includes two integer parameters: the subspace dimension m and the number of image pixels to be selected k. Furthermore, k can usually be given by the user and does not include hyperparameters such as regularization parameters, thus greatly simplifying the model complexity and reducing the difficulty of experimental parameter tuning.
[0080] Implementation step 5: To facilitate optimization, problem (6) is transformed into an equivalent form. Based on l 2,0 The row sparsity property of the norm is addressed by matrix factorization of W, i.e., W = VR, where V ∈ {0, 1}. 1024×k The feature selection indicator matrix satisfies V T 1 1024 =1 k , It is a non-zero projection matrix. Further define the set... and satisfy and Obviously, Used to indicate which features have been selected and which have not. Therefore, V and The relationship is as follows:
[0081]
[0082] Based on the above transformation, the constraint V∈{0,1} 1024×k and V T 1 1024 =1 k V is denoted as Ω, and problem (6) is transformed into:
[0083]
[0084] Implementation Step 6: Randomly Initialize the Set And the corresponding matrix V.
[0085] Implementation Step 7: Calculation and
[0086] Implementation Step 8: Simultaneously optimize the j-th column v of V. j (j = 1, 2, ..., k) and R:
[0087] 1) Problem decomposition: Based on the characteristic that V is discrete and the column sum is 1, the problem (8) is decomposed into k sub-problems and solved column by column. For v j There are d-k+1 variable feature selection indexes, including the self-label. Each change in the feature selection index is equivalent to fixing the matrix V, which is equivalent to solving the following problem:
[0088]
[0089] Clearly, problem (8) can be solved by eigenvalue decomposition, i.e., R is obtained from... The eigenvectors corresponding to the m smallest eigenvalues are composed of this. Based on this, the objective function of problem (8) is calculated for each candidate index, and R and V corresponding to the minimum value among the d-k+1 objective functions are selected to realize v. j Simultaneous optimization with matrix R.
[0090] 2) Element update: For v j Assuming the feature index before optimization is α, and the feature index corresponding to the minimum value of the objective function is α′, when α′=α, it means that the index of the j-th column of V has not changed, and R does not need to be changed either, so no element needs to be updated; however, when α′≠α, since both V and R have changed, therefore… and S t v also needs to be changed accordingly, whereby a new value is calculated by implementing step 6. and Since the other columns of V are all fixed, this would lead to unnecessary calculations. Therefore, we define vectors separately. and And update according to the following rules and
[0091]
[0092] Vector substitution eliminates unnecessary computational steps, thereby improving model efficiency.
[0093] Step 9: Update the other columns of V one by one by repeating step 8, while R is updated synchronously during the process.
[0094] Implementation step 10: When implementation step 9 ends, it is equivalent to completing one round of simultaneous updates for V and R. According to implementation steps 6-9, this invention equivalently transforms one update of W in problem (6) into v. j And k updates to R. Finally, repeat steps 8-9 until V, The algorithm converges when R no longer changes, yielding the optimal feature selection indicator matrix V and feature selection index for problem (7). To select k out of all d pixels in the image data, thus achieving discriminative filtering of image data pixels.
[0095] The effectiveness and superiority of this invention for image pixel selection on the JAFFE face dataset when k=12 are verified using a 1-Nearest Neighbor (1NN) classifier. 50% of the images are randomly selected as training samples, and the remainder as test samples. The training samples are first input into the feature selection model to obtain the sequence of selected pixels. Subsequently, training and test samples are obtained from the selected pixel subspace, and finally, the classification accuracy of the low-dimensional test samples is obtained through a 1-NN classifier. Two state-of-the-art (SOTA) algorithms, namely Discriminative Feature Selection (DFS) and Sparse Subspace Discriminative Feature Selection (SFS), are used. 2 Using the DFS method and the classification accuracy of training without pixel filtering as three benchmarks, we can obtain the classification accuracy of DFS and S. 2 The classification accuracies of DFS (k=12) and the unfiltered test set were 87.17%, 92.17%, and 97.45%, respectively. The classification accuracy of this invention was 98.68%. Therefore, it can be seen that DFS and S... 2 Distributed Filtering (DFS) suffers a certain degree of decrease in classification accuracy after filtering and removing a large number of pixels. In contrast, the method proposed in this invention, while removing a large number of pixel features from the original image data, not only significantly compresses the image data size but also improves the image data classification accuracy, verifying the effectiveness and superiority of this invention.
[0096] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the scope of the technology disclosed in the present invention, and such modifications or substitutions should all be covered within the scope of protection of the present invention.
Claims
1. A discriminative image pixel selection method based on L2.0 norm sparse operators and irrelevance constraints, characterized in that: Pixel filtering models only include subspace dimension Image pixel filtering number Two integer parameters with clear physical meaning; the method steps are as follows: Step 1: The one from indivual The dataset of pixel images is stretched and merged into an image data matrix. ,in The total number of images, The number of pixels in a single image; Step 2: Process the data matrix Feature normalization is performed so that the mean of the processed data matrix is 0 and the standard deviation is 1. Let the normalized image data matrix be denoted as . ; Step 3: Define the sample label matrix according to the following rules. ,in For the number of image categories: when the... Image data vector Belongs to the When class, Otherwise, it is 0; Calculate the within-class scatter matrix With the overall divergence matrix : in, The sample label matrix is constructed from the sample labels; Step 4: Transform the data matrix Projection matrix mapped to a low-dimensional subspace ,in Let be the dimension of the subspace; right Apply L2.0 norm sparse operators and construct equality constraints. , so that the projection matrix The number of non-zero rows is consistent with the number of pixels being filtered; The following main model is obtained by integrating the equality constraints based on the L2.0 norm sparse operator with the uncorrelated linear discriminant analysis model: in, express 1D identity matrix The number of pixels to filter in the image; benefiting from the L2.0 norm equality constraint, the number of pixels to filter. and The number of non-zero rows corresponds explicitly; right Perform matrix decomposition, i.e. ,in The feature selection indicator matrix satisfies , It is a non-zero projection matrix; Define a set and feature filtering index set , There are no duplicate elements and the following conditions are met: and ; The set sum matrix Correspondence: ; Based on this correspondence, the constraints will be... and Unified as The proposed master model is then transformed into the following problem to be solved: Step 5: Randomly initialize the set and corresponding matrix ; Step 6: Calculation and At the same time, optimize The List and , The optimal feature selection indicator matrix is obtained. and feature filtering index ; Step 7: Select the indicator matrix using the optimal features and feature filtering index Select all image data In pixels This allows for the discriminative filtering of image data pixels.
2. The image pixel discriminative selection method based on L2.0 norm sparse operators and irrelevance constraints according to claim 1, characterized in that: Step 6 optimization The List , and The steps are as follows: 1) Candidate index solution: For of To select candidate indicator indices based on a given feature, solve the following problem: in, The solution of of The eigenvectors are composed of the eigenvalues corresponding to the smallest eigenvalues; 2) Optimal objective function selection: Calculate the objective function corresponding to problem (3) after optimization for each candidate index, and select the minimum value among them. and ,accomplish With matrix Simultaneous optimization; 3) Element Update: For Assuming the feature indicator index before optimization is The feature index corresponding to the minimum value of the objective function is ,when When, no elements need to be updated; and when When, define vectors respectively and Update according to the following rules and : ; Repeat steps 1 through 3) to update one by one. Other columns, in this process Synchronous updates; until , and The algorithm converges when it stops changing, yielding the optimal feature selection indicator matrix. and feature filtering index .
3. The image pixel discriminative selection method based on L2.0 norm sparse operators and irrelevance constraints according to claim 1, characterized in that: The sample label matrix is constructed as follows: when the first... Image data vector Belongs to the When class, Otherwise, it is 0.
4. The image pixel discriminative selection method based on L2.0 norm sparse operators and irrelevance constraints according to claim 1, characterized in that: The number of image pixels to be filtered User-defined, does not include regularization parameters or hyperparameters.
5. An electronic device, characterized in that, The device includes a processor and a memory, wherein the processor is configured to execute a computer program stored in the memory to implement the steps of the image pixel discriminative screening method based on L2.0 norm sparse operators and uncorrelated constraints as described in any one of claims 1 to 4.
6. A readable storage medium, characterized in that, The readable storage medium stores a computer program that, when executed by a processor, implements the steps of the image pixel discriminative filtering method based on L2.0 norm sparse operators and uncorrelated constraints as described in any one of claims 1 to 4.
7. A computer program product, characterized in that... It includes computer-executable instructions, which, when executed, are used to implement the method of any one of claims 1 to 4.