Target recognition method and device based on low-rank neural network
By designing a low-rank neural network and using CP decomposition and matrix decomposition to replace convolution and fully connected modules, the problem of difficult deployment of convolutional neural networks on spaceborne computing platforms was solved, and efficient radar target recognition was achieved.
Patent Information
- Application Number
- CN202510766411.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-10
- Publication Date
- 2025-09-26
- Estimated Expiration
- 2045-06-10
AI Technical Summary
Existing convolutional neural network models are difficult to deploy on spaceborne computing platforms due to limited storage and computing resources. In addition, traditional low-rank decomposition algorithms have high training costs and severe performance loss, making them unable to meet the rapid response requirements of spaceborne radar target recognition.
Design a low-rank neural network, replace the corresponding modules in the convolutional neural network through CP decomposition convolution module and matrix decomposition fully connected module, combine Kruskal uniqueness theory and actual compression requirements, reasonably select the decomposition rank for training, and avoid dependence on pre-trained models.
While greatly compressing the number of model parameters, the performance loss is kept small, which improves the accuracy and computational efficiency of spaceborne radar target recognition, reduces redundant information, and enhances feature expression capability and training stability.
Smart Images

Figure CN120294719B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of radar target recognition, and in particular to a target recognition method and device based on a low-rank neural network. Background Art
[0002] Radar target recognition is a technology that uses electromagnetic waves emitted by radar to illuminate a target and analyze the received electromagnetic waves to determine the target's type. Radar data commonly used for target recognition include synthetic aperture radar (SAR) imagery, inverse synthetic aperture radar (ISAR) imagery, one-dimensional RCS (Radar Cross Section) data and its time-frequency transform, and one-dimensional range profile data, all of which have good classification characteristics. In scenarios requiring rapid decision-making, rapid radar target recognition is essential. Spaceborne radar target recognition algorithms offer fast response and identification, while only requiring a small amount of algorithmic output data to be transmitted back to ground radar stations, rather than massive amounts of raw data. This facilitates rapid decision-making on the ground.
[0003] The currently widely used Convolutional Neural Network (CNN) models are typically storage-intensive and compute-intensive, requiring huge storage resources and computing costs. However, the resources of onboard computing platforms are limited, making it impossible to deploy large target recognition models, making it difficult to effectively deploy them on onboard computing platforms. To address this problem, researchers have proposed many model compression methods, and low-rank decomposition is a commonly used compression technology.
[0004] Due to the unique nature of spaceborne target recognition, strict requirements must be placed on the size of the radar target recognition model while also ensuring target recognition accuracy. Traditional neural network model compression algorithms based on low-rank decomposition mostly perform parameter decomposition on the pre-trained model, decomposing high-dimensional tensors into combinations of multiple low-rank factor matrices and leveraging this low-rank property to approximate the original weights. Traditional low-rank decomposition algorithms require multiple iterations of fine-tuning, suffer from significant convergence issues, and incur high training costs. Furthermore, the selection of the decomposition rank is often based on manual experience and lacks certain constraints. Consequently, the performance loss at high model compression factors cannot meet the requirements of spaceborne radar target recognition. Summary of the Invention
[0005] In view of this, the present invention provides a target recognition method and device based on a low-rank neural network, which can maintain a small performance loss while greatly compressing the number of model parameters.
[0006] In order to solve the above technical problems, the present invention is implemented as follows.
[0007] A target recognition method based on a low-rank neural network, comprising:
[0008] Step 1: Design a low-rank neural network:
[0009] Design a low-rank convolution module: Perform CP decomposition on the convolution kernel weight tensor of the two-dimensional convolution kernel in the convolution module; determine the decomposition rank of the convolution kernel weight tensor in the CP decomposition based on Kruskal's uniqueness theory and the computing power of the low-rank neural network running device; obtain the low-rank convolution module through CP decomposition;
[0010] Design a low-rank fully connected module: Perform matrix decomposition on the fully connected layer weight matrix of the fully connected module; determine the decomposition rank of the fully connected layer weight matrix based on the input feature dimension and output feature dimension of the fully connected module; obtain a low-rank fully connected module through matrix decomposition;
[0011] The low-rank convolution module and the low-rank fully connected module are used to replace the convolution module and the fully connected module in the convolutional neural network to obtain a low-rank neural network;
[0012] Step 2: Train the low-rank neural network: Without pre-training the network weights, use the training samples to train the low-rank neural network;
[0013] Step 3: Collect target feature parameters and input them into the trained low-rank neural network, which then outputs the target recognition results.
[0014] Preferably, the convolution kernel weight tensor of the two-dimensional convolution kernel in the convolution module is decomposed into:
[0015] Decompose the convolution kernel weight tensor CP into a factor matrix , , , ,in 、 、 、 They are the component factor matrices 、 、 、 A rank 1 vector, , is the decomposition rank of the convolution kernel weight tensor;
[0016] The four dimensions of the two-dimensional convolution kernel are the output channel dimension, the input channel dimension, the convolution kernel height, and the convolution kernel width. The convolution kernel height and the convolution kernel width are the same.
[0017] The convolution kernel weight tensor is recorded as ,right The CP decomposition is:
[0018]
[0019] in," " represents the vector outer product operation; is the convolution kernel weight tensor The elements in are vectors The element in; the subscript o represents the oth number of the two-dimensional convolution kernel output channel, the subscript i Indicates the number of input channels of the two-dimensional convolution kernel. i , subscript k The first dimension of the convolution kernel height or width k indivual;
[0020] The matrix decomposition of the fully connected layer weight matrix of the fully connected module is:
[0021] The weight matrices of the fully connected layer are factor matrix U and factor matrix V respectively;
[0022] set up is the weight matrix of the fully connected layer, Matrix decomposition is:
[0023]
[0024] in, is the weight matrix of the fully connected layer The elements in The factor matrices are Elements in ; subscript out Represents the first dimension of the fully connected module output feature out , subscript in Represents the first dimension of the fully connected module input feature in ; subscript r Representation factor matrix The r rank-1 vectors, is the decomposition rank of the fully connected layer weight matrix.
[0025] Preferably, according to the Kruskal uniqueness theory and the computing power of the low-rank neural network running device, the decomposition rank of the convolution kernel weight tensor in the CP decomposition is determined as:
[0026] Determine the first decomposition rank based on Kruskal's uniqueness theory ;
[0027] Determine the maximum rank based on the computing power of the device running the low-rank neural network The lower the computing power of the low-rank neural network running device, the higher the compression factor is required. The smaller the selection, the higher the computing power of the low-rank neural network running device, the The bigger the choice;
[0028] First decomposition rank and maximum rank The minimum value of is used as the decomposition rank of the convolution kernel weight tensor.
[0029] Preferably, the first decomposition rank is determined according to Kruskal uniqueness theory. for:
[0030] The convolution kernel weight tensor is a 4th-order tensor, and the first decomposition rank is derived according to Kruskal's uniqueness theory. The following conditions are met:
[0031]
[0032] in, is the number of output channels of the two-dimensional convolution kernel; The number of input channels for the two-dimensional convolution kernel; is the height and width of the convolution kernel in the two-dimensional convolution kernel, and the height is the same as the width.
[0033] Preferably, the decomposition rank of the fully connected layer weight matrix is determined based on the input feature dimension and output feature dimension of the fully connected module: the decomposition rank of the fully connected layer weight matrix is the output feature dimension of the fully connected module.
[0034] Preferably, in step 2, during the training process, Kaiming is used to initialize the network parameters of the low-rank neural network; the low-rank neural network is trained with the initialized network parameters as the training starting point without pre-training the network weights.
[0035] Preferably, the low-rank neural network includes a preliminary feature extraction module, a multi-feature fusion module, and a feature reintegration and classification module;
[0036] The preliminary feature extraction module is used to perform preliminary feature extraction on the input target feature parameters. Input multi-feature fusion module;
[0037] The multi-feature fusion module is composed of N fusion extraction networks with the same structure connected in series; each fusion extraction network includes a shallow feature extraction channel, a deep feature extraction channel, an attention feature extraction channel and a splicing fusion unit; the shallow feature extraction channel has Feature extraction layer, the preliminary features are output through the shallow feature extraction channel ; Deep feature extraction channel has feature extraction layers, , preliminary features Output deep features through deep feature extraction channel ;
[0038] In the attention feature extraction channel: the first branch performs the initial feature extraction. Perform convolution feature extraction and expansion to obtain the first branch feature ; The second branch is for preliminary features Perform convolution feature extraction and expansion, and then process it through the Sigmoid function layer to obtain parameter amplitude features ; Layer-reduction mask module D-Mask for the deep features Perform partial zeroing operation and output feature mask ; As the level of the fusion extraction network gradually deepens from 1 to N , the feature representativeness is continuously enhanced, and the layer-by-layer mask module is used to improve the deep features. The zero ratio of the first branch feature is gradually attenuated. , parameter amplitude characteristics and feature masks Multiply to generate attention features ;The layer-reduction mask module D-Mask is only used during network training;
[0039] The shallow features , deep features and attention features Perform feature fusion and output fusion features , input the feature reintegration and classification module;
[0040] The feature reintegration and classification module processes the fusion features , output the target recognition result.
[0041] Preferably, the layer-reduction mask module D-Mask is used to mask the deep features. Perform partial zeroing operation and output feature mask The way is:
[0042] against N Layer fusion extracts the first Layer, calculate the zero ratio :
[0043]
[0044] in, and are the zero-setting ratios of the first layer of fusion extraction network and the last layer of fusion extraction network respectively;
[0045] According to the zeroing ratio , for Layer fusion extracts the deep features of the network and extracts the deep features of the channel output Each element in is partially set to zero: judge the deep features Is the absolute value of the element in greater than or equal to the The absolute value threshold set by the layer; and generate a uniform random variable, and judge whether the uniform random variable is less than ; If the absolute value of the element and the uniform random variable are both judged to be yes, then the current element is placed in the feature mask The position in is set to 0, otherwise, it is set to 1; by deep features All elements of perform partial zeroing judgment operations to generate feature masks .
[0046] Preferably, when training the low-rank neural network, a homogeneous convolutional neural network is constructed without replacing the low-rank convolutional module and the low-rank fully connected module. The homogeneous convolutional neural network is first trained as a teacher model, and then a distillation learning network is composed of the trained teacher model and the low-rank neural network to perform distillation learning on the low-rank neural network.
[0047] The present invention also provides a target recognition device based on a low-rank neural network, which includes a low-rank neural network and a training module;
[0048] The low-rank neural network is obtained by replacing the convolution module in the convolutional neural network with a low-rank convolution module and the fully connected module with a low-rank fully connected module; the collected target feature parameters are input into the low-rank neural network, and the low-rank neural network outputs a target recognition result;
[0049] The low-rank convolution module is determined by: performing CP decomposition on the convolution kernel weight tensor of the two-dimensional convolution kernel in the convolution module; determining the decomposition rank of the convolution kernel weight tensor in the CP decomposition based on the Kruskal uniqueness theory and the computing power of the low-rank neural network operation device; and obtaining the low-rank convolution module through the CP decomposition;
[0050] The low-rank fully connected module is determined by: performing matrix decomposition on the fully connected layer weight matrix of the fully connected module; determining the decomposition rank of the fully connected layer weight matrix according to the input feature dimension and the output feature dimension of the fully connected module; and obtaining the low-rank fully connected module through matrix decomposition;
[0051] The training module is used to train the low-rank neural network using training samples without pre-training the network weights.
[0052] Beneficial effects:
[0053] (1) The present invention proposes a lightweight neural network design scheme CLRND based on CP decomposition and matrix decomposition. Unlike most methods that only perform low-rank decomposition on a certain block of parameters, the present invention utilizes the differences in form and dimension between parameters of different layers to design low-rank convolution modules and low-rank fully connected modules according to different decomposition methods. It can maintain a small performance loss while greatly compressing the number of model parameters.
[0054] Secondly, other traditional algorithms often choose the decomposition rank, especially the low-rank decomposition of high-order tensors, based on manual experience. The present invention starts from the uniqueness theory and actual compression requirements in the rank decomposition of high-order tensors to rationalize the rank selection. At the same time, the selection of matrix decomposition rank is also mathematically derived, combined with the actual data characteristics, to select a reasonable rank.
[0055] In addition, unlike the existing technology that requires high-rank information of the pre-trained model, the present invention only needs to initialize the network parameters and let the neural network learn the effective information of the low-rank subspace from scratch, making the low-rank approximation more flexible, and converging quickly with low computational overhead.
[0056] (2) The low-rank convolution module LRCPC proposed in this invention performs low-rank decomposition of the convolution kernel in the form of a high-order tensor, which can better utilize the structural information of the high-order tensor and does not require the dimension reshaping operation of the weight tensor, thereby reducing the intermediate calculation steps; at the same time, based on the uniqueness theory of high-order tensor rank decomposition and combined with the actual compression capability requirements, the decomposition rank is constrained within a reasonable range, which better avoids the problems of blind selection of decomposition rank and poor interpretability.
[0057] (3) The low-rank fully connected module LRCPFc proposed in this paper takes into account the characteristics of the fully connected layer weight matrix, gets rid of the complex decomposition process of the pre-trained model weight matrix, simplifies the decomposition, mathematically derives the rank selected for the decomposition, and reasonably limits the size of the decomposition rank based on actual application needs and general data characteristics. Under this condition, the network can learn effective information while reducing the accumulation of redundant information.
[0058] (4) In a preferred embodiment, an attention feature extraction channel implemented by a filter-balanced attention module (FBAM) is proposed to enhance the perception of key features and enable the network to focus on key features. The larger weight parameters of the layer-by-layer mask module (D-mask) are randomly set to zero, and the random zeroing ratios of different layers of the network are different. As the network layers deepen, the feature representativeness continues to increase, and the zeroing ratio decays layer by layer, thereby retaining more high-semantic features. This allows the model to more flexibly mine feature information, avoid fitting problems caused by parameter homogeneity, and ultimately enable the network to learn more potential and robust features.
[0059] (5) As the number of model layers increases, traditional CNN models often experience feature representation deviations, and the model effect may even degenerate. To solve this problem, the inventors adopted a multi-feature fusion solution in the low-rank neural network to fuse the shallow features of the model with the deep features and attention features, thereby enhancing the feature expression capability and effectively avoiding the problem of biased feature extraction of a single branch, avoiding gradient vanishing and gradient explosion, thereby improving the training stability and robustness of the network.
[0060] (6) In a preferred embodiment, to address the problem of slow learning to represent effective information from scratch, a low-rank filter balanced attention distillation network (LFBADN) is designed. The fusion of multiple features enhances the feature expression capability, and the teacher model with a large number of parameters is isomorphic to guide the low-rank neural network to quickly learn effective parameters, thereby improving the recognition rate. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] Figure 1 Schematic diagram of the principle of the target recognition method based on low-rank neural network of the present invention.
[0062] Figure 2 Schematic diagram of a low-rank convolution module according to an embodiment of the present invention.
[0063] Figure 3 Schematic diagram of the forward process of the low-rank convolution module.
[0064] Figure 4 Schematic diagram of a low-rank fully connected module according to an embodiment of the present invention.
[0065] Figure 5 Schematic diagram of the forward process of the low-rank fully connected module.
[0066] Figure 6 This is a block diagram of the composition of the low-rank neural network according to the second embodiment of the present invention.
[0067] Figure 7 for Figure 6 An example of a low-rank neural network is shown.
[0068] Figure 8This is a structural diagram of the filter-balanced attention distillation network in Example 3 of the present invention.
[0069] Figure 9 This is a block diagram of the composition of a target recognition device based on a low-rank neural network according to the fourth embodiment of the present invention. DETAILED DESCRIPTION
[0070] The present invention is described in detail below with reference to the accompanying drawings and embodiments.
[0071] The present invention provides a target recognition method based on a low-rank neural network. The method adopts a lightweight neural network design method (Concise Low-Rank Network Design, CLRND) based on CP (CANDECOMP / PARAFAC) decomposition and matrix decomposition, abandons the relevant information in the full-rank high-precision parameters of the pre-trained model, and directly designs a low-rank neural network, including a low-rank convolution module (Low-rank CP Convolution, LRCPC) and a low-rank fully connected module (Low-rank CP Fully Connected Layer, LRCPFc). The network is allowed to adaptively learn the factor matrix under the conditions of optimal rank constraints and computational complexity constraints, and the low-rank model is trained from scratch to achieve better compression performance and model performance.
[0072] Example 1
[0073] This embodiment provides a target recognition method based on a low-rank neural network. Figure 1 As shown, the following steps are included:
[0074] Step 1: Design a low-rank neural network.
[0075] Existing technologies, based on CP decomposition of high-dimensional weight tensors from pre-trained models, suffer from convergence issues, high training costs, and severe performance degradation at high compression factors. Furthermore, existing technologies lack a well-defined algorithm for determining the rank of tensors. The classic Alternating Least Squares (ALS) algorithm cannot guarantee convergence to the global minimum, and the presence of degenerate tensors makes it difficult to find an optimal rank approximation. Methods based on layered iteration and fine-tuning also struggle to achieve balanced information utilization across layers. Furthermore, low-rank decompositions based on pre-trained models often employ singular value decomposition (SVD) operations or Bayesian estimates, which are computationally expensive. Furthermore, most low-rank decompositions are performed only on a certain type of network layer.
[0076] The present invention designs a low-rank neural network, and performs different low-rank decompositions for different types of modules. Among them, CP decomposition is used for the convolution module, and the convolution kernel is decomposed into a low-rank form in the form of a high-order tensor, which can better utilize the structural information of the high-order tensor and does not require the weight tensor to be reshaped, thereby reducing the intermediate operation steps. At the same time, starting from the uniqueness theory of high-order tensor rank decomposition and combining the actual compression capacity requirements, the decomposition rank is constrained within a reasonable range, which better avoids the problems of blind selection of decomposition rank and poor interpretability. Matrix decomposition is used for the fully connected module. This design is based on the characteristics of the weight matrix of the fully connected layer, gets rid of the complex decomposition process of the weight matrix of the pre-trained model, simplifies the decomposition, and mathematically derives the rank selected for the decomposition. At the same time, according to the actual application needs and general data characteristics, the size of the decomposition rank is reasonably limited, so that the network can learn effective information under this condition while reducing the stacking of redundant information.
[0077] The low-rank decomposition scheme and decomposition rank selection of the low-rank convolutional module and the low-rank fully connected module are described in detail below.
[0078] (1) Design of low-rank convolutional module (LRCPC):
[0079] The four dimensions of the two-dimensional convolution kernel in the convolution module are: output channel dimension , input channel dimension , convolution kernel height , convolution kernel width By convention, the height and width of the convolution kernel are set to the same value, that is, = = K .
[0080] In the past, the decomposition of convolution kernel parameters mostly involved matrixing them and then performing matrix decomposition operations. The present invention proposes a low-rank convolution module that performs low-rank decomposition of convolution kernel parameters in the form of high-order tensors to generate a low-rank convolution structure. This module can better utilize high-dimensional tensor structure information and does not require dimensionality reconstruction (reshaping) operations on the weight parameter tensor, thereby reducing intermediate calculation steps.
[0081] like Figure 2 As shown in the figure, the convolution kernel weight tensor of the two-dimensional convolution kernel in the convolution module is decomposed into CP:
[0082] Decompose the convolution kernel weight tensor CP into a factor matrix , , , ,in 、 、 、 They are the component factor matrices 、 、 、 A rank 1 vector, , , , ; , is the decomposition rank of the convolution kernel weight tensor; , .
[0083] is the convolution kernel weight tensor, ,right The CP decomposition is:
[0084] (1)
[0085] in," " represents the vector outer product operation; is the element in the convolution kernel weight tensor, are vectors Elements in ; subscript Indicates the number of output channels of the two-dimensional convolution kernel. , subscript Indicates the number of input channels of the two-dimensional convolution kernel. , subscript The first dimension of the convolution kernel height or width indivual.
[0086] When decomposing high-order tensors, choosing the right rank has always been a challenge. While other existing approaches often select rank based solely on the decomposition effect, this paper, based on the uniqueness of the rank decomposition of high-order tensors, constrains the choice of rank within a balance between theoretical framework and practical performance requirements. Specifically, this paper determines the decomposition rank of the convolution kernel weight tensor in CP decomposition based on Kruskal's uniqueness theory and the computing power of low-rank neural network operating equipment.
[0087] According to Kruskal's uniqueness theory, for a factor matrix A, k-rank is recorded as , is any The column vectors are linearly independent under the condition The maximum value of , then for an N-order tensor, the sufficient condition for its decomposition uniqueness is:
[0088] (2)
[0089] The convolution kernel weight tensor is a 4th-order tensor, and its decomposition rank is recorded as If the order is not correct Without any restrictions, assuming that the neural network learns the full-rank factor matrix parameters in an ideal situation, the convolution kernel decomposition rank determined by Kruskal's uniqueness theory is The following conditions are met:
[0090] (3)
[0091] Considering the powerful learning ability of neural networks, the necessary conditions for decomposing general uniqueness have shape restrictions for fourth-order tensors. In the process of neural network gradient calculation or parameter update, the requirements for consistency are high, and there are fewer restrictions on shape. Secondly, considering only sufficient conditions has two advantages: first, the choice of rank is constrained within the theoretical framework to avoid the blindness and redundancy of rank selection; second, a part of the space for rank selection is reserved to give full play to the flexibility of neural network learning parameter exploration in low-rank tensor space. At the same time, considering that high-rank selection leads to poor compression effect, more information redundancy and greater computational overhead, the maximum value of the rank is chosen. Maximum rank is a hyperparameter, and the maximum rank is determined based on the computing power of the low-rank neural network running device. The lower the computing power of the low-rank neural network running device, the higher the compression factor is required. The smaller the selection, the higher the computing power of the low-rank neural network running device, the The bigger the choice;
[0092] Finally, the decomposition rank and maximum rank The minimum value of is used as the decomposition rank of the convolution kernel weight tensor, that is:
[0093] (4)
[0094] The forward propagation process of the low-rank convolution module is as follows Figure 3 For ease of demonstration, assume that the input is a single 4×4 color image, the convolution sum size is 2×2, and the output is a single channel.
[0095] at this time is 1, the first dimension of the default weight parameter is 0, which is omitted in the following derivation. The input of the low-rank convolution module is X, the output is L, and the forward calculation formula for each output channel is:
[0096] (5)
[0097] in, Output matrix for the current output channel L No. i Rank j Elements of the column; is the convolution kernel weight, subscript The independent variable whose value is in the corresponding range.
[0098] To find the gradient of weight W, we have:
[0099] (6)
[0100] Assume that the loss function is E and the output feature map matrix is F, then the gradient of the loss function with respect to W is:
[0101] (7)
[0102] The gradient of the loss function with respect to the elements of the factor matrix is:
[0103] (8)
[0104] (9)
[0105] (10)
[0106] (11)
[0107] Assume that the learning rate is , the gradient update formula of the factor matrix is as follows:
[0108] (12)
[0109] (13)
[0110] (14)
[0111] (15)
[0112] (2) Low-rank fully connected module (LRCPFc)
[0113] In classification or recognition tasks, due to the high input and output dimensions, the fully connected layer usually contains a large number of parameters and the model computation is large. The weight dimension of the fully connected layer is ( , ), which is a matrix structure. This paper disregards the mathematical requirements for the matrix form of pre-trained model parameters and directly utilizes a matrix rank decomposition algorithm to perform matrix decomposition on the fully connected layer weight matrix of the fully connected module, constructing a low-rank fully connected module. This allows the network to automatically learn low-rank information representation without relying on the weight matrix information of the pre-trained model.
[0114] Low-rank fully connected modules such as Figure 4 As shown. The fully connected weight matrix is decomposed into two factor matrices U and V, where , is the weight matrix of the fully connected layer, , , ,right The low-rank decomposition is:
[0115] (16)
[0116] in, is the weight matrix of the fully connected layer The elements in The factor matrices are Elements in ; subscript Represents the first dimension of the fully connected module output feature , subscript Represents the first dimension of the fully connected module input feature ; subscript Representation factor matrix The rank-1 vectors, is the decomposition rank of the fully connected layer weight matrix.
[0117] Similarly, after getting rid of the weight constraints of the pre-trained model, we no longer need to consider the limitation of using the SVD algorithm for non-square matrix decomposition, simplifying the decomposition. At the same time, according to the decomposition formula, we have:
[0118] (17)
[0119] The decomposition rank is recorded as If the order is not correct Without making any restrictions, assuming that the neural network learns the column-full rank matrix parameters in an ideal situation, considering that the input feature dimension is high in actual situations, the following relationship holds:
[0120] (18)
[0121] In actual classification tasks, the output feature dimension To ensure that the model maintains good performance after decomposition and allows the network to learn more useful information, ,have , according to formula (17) (18), the decomposed weight matrix satisfy , in summary, choose As the matrix decomposition rank of the fully connected layer, it learns and stores as many useful parameters as possible while compressing a large number of parameters.
[0122] The forward process of the low-rank fully connected network is as follows Figure 5 As shown. The input of the low-rank fully connected module is , the output is ; The forward calculation formula (excluding the bias term) is:
[0123] (19)
[0124] Assume the loss function for training low-rank fully connected modules Output The gradient of ;
[0125] Then the weight matrix The gradient of is calculated as:
[0126] (20)
[0127] The gradient of the factor matrices U, V is:
[0128] (twenty one)
[0129] (twenty two)
[0130] Assume that the learning rate is , the gradient update formula of the factor matrix is as follows:
[0131] (twenty three)
[0132] (twenty four)
[0133] in," ” represents the gradient update operation.
[0134] Low-rank convolutional modules and low-rank fully connected modules are used to replace the convolutional modules and fully connected modules in the convolutional neural network to obtain a low-rank neural network.
[0135] Step 2: Train the low-rank neural network: Without pre-training the network weights, use the training samples to train the low-rank neural network.
[0136] Unlike most methods that require pre-training high-rank information from the model, this method initializes the parameters, allowing the neural network to learn the effective information in the low-rank subspace from scratch. Learning from scratch only requires initializing the network parameters of the low-rank neural network; using the initialized network parameters as the training starting point, the low-rank neural network can be trained without pre-training the network weights.
[0137] In a preferred solution, Kaiming initialization (He Kaiming initialization) is used to initialize network parameters.
[0138] Step 3: Collect target feature parameters and input them into the trained low-rank neural network, which then outputs the target recognition results.
[0139] This concludes the process.
[0140] Example 2
[0141] This embodiment provides a low-rank neural network structure based on the first embodiment. Figure 6 As shown in Figure 3, the network includes a preliminary feature extraction module, a multi-feature fusion module, and a feature reintegration and classification module.
[0142] The preliminary feature extraction module is used to extract the preliminary features of the input target feature parameters. Enter the multi-feature fusion module.
[0143] The multi-feature fusion module is composed of N fusion extraction networks with the same structure connected in series. Each fusion extraction network includes a shallow feature extraction channel, a deep feature extraction channel, an attention feature extraction channel, and a splicing fusion unit. Among them:
[0144] Shallow feature extraction channels have Feature extraction layer, the preliminary features are output through the shallow feature extraction channel .
[0145] The deep feature extraction channel has feature extraction layers, , the preliminary features are output through the deep feature extraction channel to generate deep features .
[0146] The attention feature extraction channel adopts the filter balancing attention module FBAM (FilterBalancing Attention Module) designed by the present invention, which includes a first branch, a second branch, and a layer decreasing mask module D-Mask (Layer Decreasing Mask). Perform convolution feature extraction and expansion to obtain the first branch feature The second branch is for preliminary features Perform convolution feature extraction and expansion, and then process it through the Sigmoid function layer to obtain parameter amplitude features Layer-by-layer mask module D-Mask for deep features Perform partial zeroing operation and output feature mask As the level of the fusion extraction network gradually deepens from 1 to N , the feature representativeness is continuously enhanced, and the layer-by-layer mask module is used to improve the deep features. The zero ratio of is gradually attenuated. The first branch feature , parameter amplitude characteristics and feature masks Multiply to generate attention features .
[0147] In this embodiment, the layer-reduction mask module D-Mask is used to mask the deep features. Perform partial zeroing of parameters and output feature mask The way is:
[0148] For the Layer fusion extraction network, calculate zero ratio :
[0149] (25)
[0150] in, and are the zero-setting ratios of the first layer of fusion extraction network and the last layer of fusion extraction network, N is the total number of layers of the fusion extraction network in the multi-feature fusion module.
[0151] According to the calculated zero ratio , for Layer fusion extracts the deep features of the network and extracts the deep features of the channel output Each element in is partially set to zero: judge the deep features Is the absolute value of the element in greater than or equal to the The absolute value threshold of the layer, and whether the generated uniform random variable is less than If so, the element corresponds to the feature mask The position element value in is set to 0, otherwise, it is set to 1; by deep features Perform partial zeroing on all elements of to generate a feature mask The D-mask formula is expressed as:
[0152] For the Layer parameters , which is in the feature mask The mask value at the corresponding position in is:
[0153] (26)
[0154] in: Indicates the Layer fusion extracts deep features from the network Located in the middle The element at position, is the position number of the element in the four-dimensional matrix; For the The absolute value threshold of the layer parameter, is a uniform random variable, controlling the decision of random zeroing; Indicates the Layer fusion to extract the network’s feature mask Located in the middle The element at position.
[0155] The layer-subtraction mask module D-Mask is only used during network training. During actual recognition, the layer-subtraction mask module D-Mask is removed.
[0156] In the multi-feature fusion module, shallow features are obtained , deep features and attention features Finally, the three are feature fused and the fused features are output , Input feature reintegration and classification module.
[0157] Feature reintegration and classification module for fusion features Further processing is performed to output the target recognition results.
[0158] From the above network structure, it can be seen that the neural network design features of the present invention are as follows:
[0159] First, in addition to the deep and shallow feature extraction channels, the multi-feature fusion module of the present invention also adds an attention feature extraction channel, which is designed using a filter-balanced attention module (FBAM). Traditional CNNs have limitations in allocating local information and uniform weights. The attention module enhances the model's perception of key features through feature selection and global modeling, while ensuring efficiency and flexibility. Unlike conventional attention modules, the filter-balanced attention module (FBAM) designed in the present invention extracts and expands features through multiple convolutional layers, and obtains parameter amplitude features through the sigmoid function layer of the second branch. Unlike the general idea of relying solely on amplitude as a factor in determining parameter importance, the present invention believes that parameters with smaller amplitudes are not necessarily unimportant, and parameters with larger amplitudes do not necessarily contain valid information. Therefore, based on this idea, a layer-decrementing mask module (D-mask) is designed. A certain proportion of parameters with larger amplitudes in the shallow network are randomly set to zero, preventing overfitting by increasing parameter sparsity. As the network layers deepen, feature representativeness continues to increase, and the zeroing ratio decays layer by layer, retaining more high-semantic features. This allows the model to more flexibly mine feature information and avoid fitting problems caused by parameter homogeneity.
[0160] In addition, traditional CNN models often have feature representation deviations as the number of model layers increases, and the model effect may even degrade. To solve this problem, this model proposes a method of multi-feature fusion of the model, which fuses the shallow features of the model with the deep features and attention features to enhance the feature expression ability and effectively avoid the problem of biased feature extraction of a single branch.
[0161] Figure 7 Shown Figure 6 An example of a specific structure of a low-rank neural network. As shown in the figure:
[0162] The preliminary feature extraction module consists of a low-rank convolution module and a ReLU activation layer;
[0163] In the multi-feature fusion module, the shallow feature extraction channel consists of a low-rank convolution module and a batch normalization module to generate shallow features. The deep feature extraction channel consists of a low-rank convolution module and a batch normalization module to form a set of processing units. The two sets of processing units are connected in series through the ReLU activation layer. The batch normalization module of the second set of processing units generates deep features. The first branch of the attention feature extraction channel includes two low-rank convolution modules, and the second branch includes two low-rank convolution modules and a Sigmoid function layer; the outputs of the first branch, the second branch, and the D-mask module are connected to the multiplication module, and the output of the multiplication module is passed through a batch normalization module to generate attention features. Shallow features , deep features and attention features Enter the splicing and fusion unit to perform feature fusion and output fusion features .
[0164] The feature reintegration and classification module is composed of a low-rank convolution module, a batch normalization module and a low-rank fully connected module in series.
[0165] Example 3
[0166] In this embodiment, based on the low-rank neural network of embodiment 2, a filter-balanced attention distillation network LFBADN is designed for training the low-rank neural network.
[0167] like Figure 8 As shown in the figure, the left side of the filter-balanced attention distillation network LFBADN is the low-rank neural network of Example 2, and the right side is an isomorphic convolutional neural network with the low-rank convolutional module and low-rank fully connected module replaced with ordinary convolutional modules and fully connected modules. The modules corresponding to the soft loss calculation, hard loss calculation, and weighted operation on the bottom side of the filter-balanced attention distillation network LFBADN are shown.
[0168] Considering the low-rank neural network in Example 2, training from scratch will face uncertain training parameter directions, slow convergence, and easy local convergence. Therefore, to reduce the computing pressure of model training and ensure the high quality and stability of the teacher model, this example adopts the concept of offline distillation. Specifically, a homogeneous convolutional neural network is first trained as the teacher model. Then, a distillation learning network is formed by combining the trained teacher model and the low-rank neural network to quickly guide the student model to learn effective representation parameters.
[0169] Calculate hard loss between low-rank neural network output and true label , the low-rank neural network output and the teacher model output calculate the soft loss , the total loss of the model It is composed of the weighted combination of the two, namely:
[0170] (27)
[0171] in, Weighting coefficient for weighting hard loss and soft loss.
[0172] Parameter optimization of low-rank neural networks based on total loss.
[0173] The low-rank filter balanced attention distillation network (LFBADN) of this embodiment enhances the perception of key features through the filter balanced attention module (FBAD), enhances feature expression through the fusion of multiple features, and guides the low-rank neural network to quickly learn effective parameters through the isomorphism of the large-parameter teacher model, achieving accurate target recognition. The main advantages of this model are:
[0174] ① Anti-training degradation ability: Multi-feature fusion can effectively avoid gradient vanishing and gradient explosion problems, thereby improving the training stability and robustness of the network.
[0175] ② Simple training: Unlike general low-rank decomposition that requires a large number of iterative fine-tuning, this model designs a low-rank module and trains it from scratch, which is simple and efficient.
[0176] ③ Efficient feature extraction: Design a filter-balanced attention module to integrate the overall filter features, focus on key features, and perform layered masking to improve the model's anti-interference ability and prevent model overfitting.
[0177] ④ Distillation design: By designing the distillation structure of low-rank networks and isomorphic non-low-rank networks, a teacher model with more parameters is used to guide the low-rank network to learn effective parameters from scratch, making training easier to converge and more accurate.
[0178] ⑤ Scalability: The low-rank module is not only applicable to this model, but can also be extended to other deep learning tasks with similar model structures.
[0179] The model of this embodiment is trained using actual data. The training process and results are as follows:
[0180] (1) Dataset construction
[0181] The SAR image dataset used in this paper contains four categories: Cargo, Tanker, Other Type, and Tug. These four target categories are divided into training and test data with a ratio of 7:3. The training set contains 1,610 SAR images per category for model learning and training; the test set contains 690 SAR images per category for evaluating the model's performance on unseen data. Table 1 shows the dataset classification.
[0182] Table 1 Dataset classification
[0183]
[0184] (2) Model training and validation
[0185] The following describes the model and training parameter settings.
[0186] ① The idea of the lightweight network designed in the present invention is to train a low-rank network from scratch, rather than to decompose the weight parameters of the pre-trained model. Low-rank decomposition algorithms based on pre-trained models often require iterative fine-tuning, which consumes a lot of time and computing power, and the accuracy drops seriously when the compression factor is high. For the decomposition method proposed in the present invention, for CP decomposition, due to the problem of CP rank selection, if the pre-trained model is decomposed equally, it will lead to insufficient representation of parameter information under the same decomposition effect, and the performance degradation will be more serious; for matrix decomposition, the decomposition method proposed in the present invention does not meet the mathematical derivation of general matrix decomposition (such as SVD decomposition). Using a pre-trained model to perform such matrix decomposition cannot effectively obtain high-precision related information in the pre-trained parameters, and the decomposition effect is poor. In summary, the present invention adopts the idea of training from scratch, so that the network can obtain effective parameters under a given rank during learning, so it is necessary to adopt a parameter initialization strategy. The network training of the present invention adopts Kaiming initialization to better adapt to the gradient problem caused by parameter decomposition.
[0187] ②Batch_size is set to 16, training epochs is set to 50, and single GPU training and inference are used.
[0188] ③The running device parameters are: CPU: AMD Ryzen 7 4800H with Radeon Graphics 2.90 GHz; GPU: GeForce RTX 2060 6G, using the PyTorch deep learning framework.
[0189] In this SAR target recognition model, there are four target categories. Based on the principle of derivation, the decomposition rank of the low-rank fully connected layer is set to 4, and the low-rank convolution module is set to different maximum decomposition ranks. The model parameters and recognition rates under different compression conditions are shown in Table 2.
[0190] Table 2 Verification results
[0191]
[0192] Example 4
[0193] This embodiment provides a target recognition device based on a low-rank neural network. Figure 9 As shown, it includes a low-rank neural network and a training module.
[0194] Among them, the low-rank neural network is obtained by replacing the convolution module in the convolutional neural network with a low-rank convolution module and the fully connected module with a low-rank fully connected module; the collected target feature parameters are input into the low-rank neural network, and the low-rank neural network outputs the target recognition result.
[0195] The low-rank convolution module is determined as follows: perform CP decomposition on the convolution kernel weight tensor of the two-dimensional convolution kernel in the convolution module; determine the decomposition rank of the convolution kernel weight tensor in the CP decomposition based on the Kruskal uniqueness theory and the computing power of the low-rank neural network running device; and obtain the low-rank convolution module through CP decomposition.
[0196] The low-rank fully connected module is determined by: performing matrix decomposition on the fully connected layer weight matrix of the fully connected module; determining the decomposition rank of the fully connected layer weight matrix according to the input feature dimension and output feature dimension of the fully connected module; and obtaining the low-rank fully connected module through matrix decomposition.
[0197] The training module is used to train the low-rank neural network using training samples without pre-training the network weights.
[0198] The low-rank neural network in this embodiment can adopt the specific network structure of Example 2. The training method can refer to the distillation training scheme of Example 3.
[0199] Compared with the prior art, the solution of the present invention has the following advantages:
[0200] 1. Analysis from the perspective of compression effect and model performance after compression. Traditional low-rank decomposition of high-dimensional weight tensors based on pre-trained models has convergence problems, high training costs, and severe performance degradation when the compression factor is high. Traditional low-rank decomposition of fully connected layers mostly uses the singular value decomposition (SVD) algorithm, which brings greater computational complexity. While achieving good results in model compression, it often brings about large performance losses. The present invention maintains a great compression effect while causing little loss in model performance and is simple to train.
[0201] 2. Analysis from the perspective of decomposition rank selection. Traditional algorithms often rely on manual experience to select decomposition rank, especially low-rank decomposition of high-order tensors. This paper rationalizes the rank selection in high-order tensor rank decomposition based on uniqueness theory and actual compression requirements. At the same time, the selection of matrix decomposition rank is also mathematically derived, combined with the characteristics of actual data, to select a reasonable rank.
[0202] 3. Analysis from the perspective of computational overhead. Traditionally, the low-rank decomposition process of pre-trained models requires multiple iterations of fine-tuning, which has high computational overhead and is prone to convergence to local minimum points. This invention trains the low-rank module from scratch, which converges quickly and has low computational overhead.
[0203] 4. Analysis from the perspective of decomposition completeness. Most traditional algorithms only decompose a certain module of the neural network. The present invention designs decomposition algorithms according to the characteristics of different modules, constructs different low-rank modules, and has strong decomposition completeness.
[0204] 5. Analysis from the perspective of scalability. Most traditional low-rank decomposition algorithms are designed for a specific neural network, while the present invention designs a basic network module with good scalability.
[0205] The above specific embodiments merely illustrate the design principles of the present invention. The shapes and names of the components described herein may vary and are not limiting. Therefore, those skilled in the art may modify or substitute equivalents for the technical solutions described in the above embodiments. Such modifications and substitutions, without departing from the inventive spirit and technical solutions of the present invention, shall fall within the scope of protection of the present invention.
Claims
1. A target recognition method based on a low-rank neural network, characterized in that: include: Step 1: Design a low-rank neural network: Design a low-rank convolution module: Perform CP decomposition on the convolution kernel weight tensor of the two-dimensional convolution kernel in the convolution module to obtain a low-rank convolution module. According to Kruskal's uniqueness theory and the computing power of the low-rank neural network running device, the decomposition rank of the convolution kernel weight tensor in the CP decomposition is determined, including: Determine the first decomposition rank based on Kruskal's uniqueness theory :The convolution kernel weight tensor is a 4-order tensor, and the first decomposition rank is derived according to Kruskal uniqueness theory The following conditions are met: in, is the number of output channels of the two-dimensional convolution kernel; The number of input channels for the two-dimensional convolution kernel; is the height and width of the convolution kernel in the two-dimensional convolution kernel, and the height is the same as the width; Determine the maximum rank based on the computing power of the device running the low-rank neural network :The lower the computing power of the low-rank neural network running device, the higher the compression factor is required. The smaller the selection, the higher the computing power of the low-rank neural network running device, the The bigger the choice; First decomposition rank and maximum rank The minimum value of is used as the decomposition rank of the convolution kernel weight tensor; Design a low-rank fully connected module: Perform matrix decomposition on the fully connected layer weight matrix of the fully connected module; determine the decomposition rank of the fully connected layer weight matrix based on the input feature dimension and output feature dimension of the fully connected module; obtain a low-rank fully connected module through matrix decomposition; The low-rank convolution module and the low-rank fully connected module are used to replace the convolution module and the fully connected module in the convolutional neural network to obtain a low-rank neural network; Step 2: Train the low-rank neural network: Without pre-training the network weights, use the training samples to train the low-rank neural network; Step 3: Collect target feature parameters and input them into the trained low-rank neural network, which then outputs the target recognition results.
2. The target recognition method based on low-rank neural network according to claim 1, characterized in that The convolution kernel weight tensor of the two-dimensional convolution kernel in the convolution module is decomposed into CP: Decompose the convolution kernel weight tensor CP into a factor matrix , , , ,in 、 、 、 They are the component factor matrices 、 、 、 A rank 1 vector, , is the decomposition rank of the convolution kernel weight tensor; The four dimensions of the two-dimensional convolution kernel are the output channel dimension, the input channel dimension, the convolution kernel height, and the convolution kernel width. The convolution kernel height and the convolution kernel width are the same. The convolution kernel weight tensor is recorded as ,right The CP decomposition is: in," " represents the vector outer product operation; is the convolution kernel weight tensor The elements in are vectors Elements in ; subscript Indicates the number of output channels of the two-dimensional convolution kernel. , subscript Indicates the number of input channels of the two-dimensional convolution kernel. , subscript The first dimension of the convolution kernel height or width indivual; The matrix decomposition of the fully connected layer weight matrix of the fully connected module is: Decompose the fully connected layer weight matrix into factor matrix U and factor matrix V; set up is the weight matrix of the fully connected layer, Matrix decomposition is: in, is the weight matrix of the fully connected layer The elements in The factor matrices are Elements in ; subscript Represents the first dimension of the fully connected module output feature , subscript Represents the first dimension of the fully connected module input feature ; subscript r Representation factor matrix The rank-1 vectors, is the decomposition rank of the fully connected layer weight matrix.
3. The target recognition method based on low-rank neural network according to claim 1, characterized in that The decomposition rank of the fully connected layer weight matrix is determined according to the input feature dimension and output feature dimension of the fully connected module: the decomposition rank of the fully connected layer weight matrix is the output feature dimension of the fully connected module.
4. The target recognition method based on low-rank neural network according to claim 1, characterized in that In step 2, during the training process, Kaiming is used to initialize the network parameters of the low-rank neural network; the initialized network parameters are used as the training starting point, and the low-rank neural network is trained without pre-training the network weights.
5. The target recognition method based on low-rank neural network according to claim 1, characterized in that The low-rank neural network includes a preliminary feature extraction module, a multi-feature fusion module, and a feature reintegration and classification module; The preliminary feature extraction module is used to perform preliminary feature extraction on the input target feature parameters. Input multi-feature fusion module; The multi-feature fusion module is composed of N fusion extraction networks with the same structure connected in series; each fusion extraction network includes a shallow feature extraction channel, a deep feature extraction channel, an attention feature extraction channel and a splicing fusion unit; the shallow feature extraction channel has Feature extraction layer, the preliminary features are output through the shallow feature extraction channel ; The deep feature extraction channel has feature extraction layers, , preliminary features Output deep features through deep feature extraction channel ; In the attention feature extraction channel: the first branch performs the initial feature extraction. Perform convolution feature extraction and expansion to obtain the first branch feature ; The second branch is for preliminary features Perform convolution feature extraction and expansion, and then process it through the Sigmoid function layer to obtain parameter amplitude features ; Layer-reduction mask module D-Mask for the deep features Perform partial zeroing operation and output feature mask ; As the level of the fusion extraction network gradually deepens from 1 to N , the feature representativeness is continuously enhanced, and the layer-by-layer mask module is used to improve the deep features. The zero ratio of the first branch feature is gradually attenuated. , parameter amplitude characteristics and feature masks Multiply to generate attention features ;The layer-reduction mask module D-Mask is only used during network training; The shallow features , deep features and attention features Perform feature fusion and output fusion features , input the feature reintegration and classification module; The feature reintegration and classification module processes the fusion features , output the target recognition result.
6. The target recognition method based on low-rank neural network according to claim 5, characterized in that: The layer-reduction mask module D-Mask is used to reduce the depth of the features. Perform partial zeroing operation and output feature mask The way is: against N Layer fusion extracts the first Layer, calculate the zero ratio : in, and are the zero-setting ratios of the first layer of fusion extraction network and the last layer of fusion extraction network respectively; According to the zeroing ratio , for Layer fusion extracts the deep features of the network and extracts the deep features of the channel output Each element in is partially set to zero: judge the deep features Is the absolute value of the element in greater than or equal to the The absolute value threshold set by the layer; and generate a uniform random variable, and judge whether the uniform random variable is less than ; If the absolute value of the element and the uniform random variable are both judged to be yes, then the current element is placed in the feature mask The position in is set to 0, otherwise, it is set to 1; by deep features All elements of perform partial zeroing judgment operations to generate feature masks .
7. The target recognition method based on low-rank neural network according to claim 5, characterized in that When training the low-rank neural network, a homogeneous convolutional neural network is constructed without replacing the low-rank convolutional module and the low-rank fully connected module. The homogeneous convolutional neural network is first trained as a teacher model, and then a distillation learning network is composed of the trained teacher model and the low-rank neural network to perform distillation learning on the low-rank neural network.
8. A target recognition device based on a low-rank neural network, characterized in that: The device includes a low-rank neural network and a training module; The low-rank neural network is obtained by replacing the convolution module in the convolutional neural network with a low-rank convolution module and the fully connected module with a low-rank fully connected module; the collected target feature parameters are input into the low-rank neural network, and the low-rank neural network outputs a target recognition result; The low-rank convolution module is determined by performing CP decomposition on the convolution kernel weight tensor of the two-dimensional convolution kernel in the convolution module to obtain the low-rank convolution module; wherein, according to the Kruskal uniqueness theory and the computing power of the low-rank neural network running device, the decomposition rank of the convolution kernel weight tensor in the CP decomposition is determined, including: Determine the first decomposition rank based on Kruskal's uniqueness theory :The convolution kernel weight tensor is a 4-order tensor, and the first decomposition rank is derived according to Kruskal uniqueness theory The following conditions are met: in, is the number of output channels of the two-dimensional convolution kernel; The number of input channels for the two-dimensional convolution kernel; is the height and width of the convolution kernel in the two-dimensional convolution kernel, and the height is the same as the width; Determine the maximum rank based on the computing power of the device running the low-rank neural network :The lower the computing power of the low-rank neural network running device, the higher the compression factor is required. The smaller the selection, the higher the computing power of the low-rank neural network running device, the The bigger the choice; First decomposition rank and maximum rank The minimum value of is used as the decomposition rank of the convolution kernel weight tensor; The low-rank fully connected module is determined by: performing matrix decomposition on the fully connected layer weight matrix of the fully connected module; determining the decomposition rank of the fully connected layer weight matrix according to the input feature dimension and the output feature dimension of the fully connected module; and obtaining the low-rank fully connected module through matrix decomposition; The training module is used to train the low-rank neural network using training samples without pre-training the network weights.
Citation Information
Patent Citations
Tensor decomposition-based acceleration and compression method for deep convolutional neural network
CN106127297A
Low-rank generative adversarial network construction method for medical image generation
CN112465118A