Method and device for reinforcement training of a gaussian classification neural network
By introducing a 4-layer substructure of reinforcement training neural network into the Gaussian classification neural network to replace the Gaussian mixture discriminant layer, the problem of not fully utilizing the clustering characteristics of Gaussian distribution in the existing technology is solved, thereby improving classification performance and the accuracy of signal classification prediction.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- THE SECOND RES INST OF CIVIL AVIATION ADMINISTRATION OF CHINA
- Filing Date
- 2019-12-31
- Publication Date
- 2026-05-15
AI Technical Summary
Existing technologies use conventional training methods to train parameters for the unique structure of Gaussian mixture discriminant layers, but the results are not ideal. They fail to fully utilize the clustering characteristics of Gaussian distributions, resulting in insufficient classification performance of Gaussian classification neural networks.
The Gaussian mixture discriminant layer is replaced by a reinforcement training neural network. The Gaussian classification neural network is trained through a four-layer substructure reinforcement network loss layer, including a normalization layer, a feature similarity loss calculation layer, a category similarity loss calculation layer, and a classification loss output layer, thereby improving feature distribution and classification accuracy.
This improved the classification performance and feature encoding capability of the Gaussian classification neural network, thereby enhancing the accuracy of signal classification and prediction.
Smart Images

Figure CN111062452B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of neural network design technology in deep learning, specifically to a method and apparatus for reinforcement training of Gaussian classification neural networks. Background Technology
[0002] Signal classification is one of the most common problems in signal processing. Currently, neural networks have achieved good results in signal classification. Gaussian classification neural networks, based on the common convolutional-fully connected layer structure, add a Gaussian mixture discriminant layer, further improving classification performance. However, using conventional training methods to train the parameters of the Gaussian mixture discriminant layer, which has a unique structure, yields less than ideal results, mainly because conventional training methods do not fully utilize the clustering properties of the Gaussian distribution. Summary of the Invention
[0003] The purpose of this invention is to provide a method and apparatus for enhancing the training of Gaussian classification neural networks, so as to improve the classification performance of Gaussian classification neural networks and meet special application requirements such as feature encoding, thereby improving the accuracy of signal classification and prediction.
[0004] To achieve the above objectives, in a first aspect, embodiments of the present invention provide a method for reinforcement training of a Gaussian classification neural network, comprising:
[0005] The original Gaussian classification neural network is reinforced and trained to obtain the target Gaussian classification neural network;
[0006] Acquire the image signal to be classified;
[0007] The image signal to be classified is input into a target Gaussian classification neural network for processing to obtain the classification result;
[0008] The target Gaussian classification neural network is obtained by reinforcing the original Gaussian classification neural network through reinforcement training. The reinforcement training neural network includes a reinforcement loss layer connected to a convolutional-fully connected layer, which replaces the Gaussian mixture discriminant layer in the original Gaussian classification neural network. The reinforcement loss layer sequentially comprises four sub-structures:
[0009] The first layer is the normalization layer, which is used to adjust the feature distribution range of each feature channel to between -1 and +1 as much as possible.
[0010] The second layer is the feature similarity loss calculation layer, which is used to calculate the expected similarity loss between the features output by the previous network structure and the learned features.
[0011] The third layer is the category similarity loss calculation layer, which is used to multiply each feature channel by the loss weight and jointly calculate the category similarity loss based on the similarity loss of all feature channels.
[0012] The fourth layer is the classification loss output layer, which retains only the classification prediction loss corresponding to the category of the input image signal and transforms the classification loss into an output between 0 and 1.
[0013] Further, the original Gaussian classification neural network includes convolutional layers, fully connected layers, and Gaussian mixture discriminant layers; the original Gaussian classification neural network is subjected to reinforcement training to obtain the target Gaussian classification neural network, specifically including:
[0014] (1) Initialize the original Gaussian classification neural network: Keep the parameters of the convolutional layer and the fully connected layer unchanged, and calculate the initialization parameters of the Gaussian mixture discriminant layer according to the Gaussian mixture discriminant layer parameter initialization method;
[0015] (2) Perform routine training on the original Gaussian classification neural network: Use the target dataset to perform routine training on the original Gaussian classification neural network until the accuracy can no longer be improved;
[0016] (3) Substitute the parameters of the convolutional and fully connected layers of the original Gaussian classification neural network into the reinforcement training neural network, and initialize the parameters of the reinforcement network loss layer. The parameters of the reinforcement network loss layer are calculated according to the reinforcement network loss layer parameter initialization method; wherein, the reinforcement neural network is obtained by replacing the Gaussian mixture discriminant layer with the reinforcement network loss layer.
[0017] (4) Use reinforcement training neural network to train convolutional and fully connected layers: Set the parameters of the reinforcement network loss layer to be untrainable, and use the target dataset to train the convolutional and fully connected layers of the reinforcement training neural network until the output loss value has no obvious decreasing trend.
[0018] (5) Substitute the parameters of the reinforced convolutional layer and fully connected layer into the original Gaussian classification neural network, and initialize the parameters of the Gaussian mixture discriminant layer, wherein the parameters of the Gaussian mixture discriminant layer are calculated according to the Gaussian mixture discriminant layer parameter initialization method;
[0019] (6) Repeat steps (2)-(5) in a loop until the classification accuracy of the original Gaussian classification neural network reaches the preset value.
[0020] Secondly, embodiments of the present invention provide an apparatus for reinforcement training of a Gaussian classification neural network, comprising:
[0021] The training unit is used to reinforce the original Gaussian classification neural network to obtain the target Gaussian classification neural network.
[0022] The acquisition unit is used to acquire the image signal to be classified;
[0023] The processing unit is used to input the image signal to be classified into the target Gaussian classification neural network for processing to obtain the classification result;
[0024] The target Gaussian classification neural network is obtained by reinforcing the original Gaussian classification neural network through reinforcement training. The reinforcement training neural network includes a reinforcement loss layer connected to a convolutional-fully connected layer, which replaces the Gaussian mixture discriminant layer in the original Gaussian classification neural network. The reinforcement loss layer sequentially comprises four sub-structures:
[0025] The first layer is the normalization layer, which is used to adjust the feature distribution range of each feature channel to between -1 and +1 as much as possible.
[0026] The second layer is the feature similarity loss calculation layer, which is used to calculate the expected similarity loss between the features output by the previous network structure and the learned features.
[0027] The third layer is the category similarity loss calculation layer, which is used to multiply each feature channel by the loss weight and jointly calculate the category similarity loss based on the similarity loss of all feature channels.
[0028] The fourth layer is the classification loss output layer, which retains only the classification prediction loss corresponding to the category of the input image signal and transforms the classification loss into an output between 0 and 1.
[0029] Thirdly, embodiments of the present invention provide another device for reinforcement training of a Gaussian classification neural network, including a processor, an input device, an output device, and a memory, wherein the processor, input device, output device, and memory are interconnected, wherein the memory is used to store a computer program, the computer program includes program instructions, and the processor is configured to call the program instructions to execute the method of the first aspect described above.
[0030] In implementing this embodiment of the invention, the original Gaussian classification neural network is enhanced and trained to obtain a target Gaussian classification neural network. An image signal to be classified is acquired, and the image signal is input into the target Gaussian classification neural network for processing to obtain a classification result. The enhanced training neural network includes an enhanced network loss layer connected to a convolutional-fully connected layer, which replaces the Gaussian mixture discriminant layer in the original Gaussian classification neural network during training. This improves the classification performance of the Gaussian classification neural network and fulfills special application requirements such as feature encoding. Furthermore, when the image signal to be classified is input into the target Gaussian classification neural network, the accuracy of signal classification prediction can be improved. Attached Figure Description
[0031] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the accompanying drawings used in the description of the specific embodiments or the prior art will be briefly introduced below.
[0032] Figure 1 This is a diagram showing the overall structure of a Gaussian classification neural network;
[0033] Figure 2 This is a diagram showing the overall structure of the reinforcement training neural network;
[0034] Figure 3 This is a schematic flowchart of a method for reinforcement training of a Gaussian classification neural network provided in an embodiment of the present invention;
[0035] Figure 4 This is a schematic diagram of a device for reinforcement training of a Gaussian classification neural network provided in an embodiment of the present invention;
[0036] Figure 5 This is another schematic diagram of the device for reinforcement training of Gaussian classification neural networks provided in this embodiment of the invention. Detailed Implementation
[0037] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0038] To better understand the embodiments of the present invention, the relevant parts are first described as follows:
[0039] A network consisting of a Gaussian mixture discriminant layer constructed using a Gaussian mixture mathematical model, along with pre-convolutional layers and fully connected layers, is called a Gaussian classification neural network. The overall structure is as follows: Figure 1 As shown.
[0040] The Gaussian mixture discriminant layer has a 5-layer substructure.
[0041] The first layer is a normalization layer, which adjusts the feature distribution range of each feature channel to be as close as possible to -1 to +1. The input to this layer is a feature vector Fa of length N, where N is the number of output feature channels of the fully connected layer, also called the feature dimension. The output of this layer is a feature vector Fb of length N. The operation performed by this layer is as follows:
[0042] Fb=FaoS+T (1)
[0043] Where S = [s1, s2, ..., s N ] and T = [t1, t2, ..., t N ] represents the scaling and translation parameters, respectively. The operator o is element-wise multiplication, meaning that the elements of the vectors on both sides of the operator are multiplied one by one to obtain a vector of the same dimension. The parameters of this layer are S and T.
[0044] The second layer is the feature similarity calculation layer, which calculates the expected similarity between the features output by the previous network structure and the learned features. The input to this layer is Fb. The output is an N x M matrix Fc, where M is the number of categories of the target object. This layer performs two operations, and regardless of the method, the parameters of this layer are μ and σ. The first method is standard Gaussian operation, which performs the following operation on each feature channel.
[0045]
[0046] Where the subscript i is the feature channel number and the subscript j is the category number.
[0047] The second approach is to simplify the Gaussian operation, which involves performing the following operation on each feature channel.
[0048]
[0049] The ReLU function is defined as follows:
[0050]
[0051] The third layer is the feature weight layer, which multiplies each feature channel by a classification decision weight. The input to this layer is Fc. The output of this layer is a matrix Fd of dimension N by M. The operation performed by this layer is Fd = log(Fc)oW (3).
[0052] Here, the function W is an N-by-M matrix, and the operator o is element-wise multiplication, which means that the elements of the matrices on both sides of the operator are multiplied one by one to obtain matrices of the same dimension. The parameter of this layer is W.
[0053] The fourth layer performs category similarity calculation, which jointly calculates the classification similarity based on the similarity of all feature channels. The input to this layer is Fd. The output of this layer is a feature vector Fe of length M. This layer has no parameters and performs the following operations:
[0054]
[0055] The fifth layer is the classification score output layer, which converts classification similarity into a classification score between 0 and 1. The input to this layer is Fe. The output of this layer is a feature vector of length M, representing the score for each class. This layer has no parameters and performs the following operation:
[0056]
[0057] This invention relates to a reinforcement training module for Gaussian classification neural networks, called a reinforcement network loss layer. During reinforcement training, the reinforcement network loss layer is connected after the fully connected layer of the original Gaussian classification neural network, replacing the Gaussian mixture discriminant layer, thus forming a structure as follows: Figure 2 The reinforcement training neural network shown.
[0058] The enhanced network loss layer has a four-layer substructure.
[0059] The first layer is a normalization layer, which adjusts the feature distribution range of each feature channel to between -1 and +1 as much as possible. The input of this layer is a feature vector Fa of length N, where N is the number of output feature channels of the fully connected layer, also called the feature dimension. The output of this layer is a feature vector Fb of length N. The operation performed by this layer is Fb=(Fa-T)oS (1)
[0060] Where T = [t1, t2, ..., t N ] and S = [s1,s2,...,s N ] represents the translation and scaling parameters, respectively. The operator o is element-wise multiplication, meaning that the elements of the vectors on both sides of the operator are multiplied one by one to obtain a vector of the same dimension. The parameters of this layer are T and S.
[0061] The second layer is the feature similarity loss calculation layer. It calculates the expected similarity loss between the features output by the previous network structure and the learned features. The loss value for each feature channel ranges from 0 to 1; the higher the similarity, the closer the loss is to 0, and the lower the similarity, the closer the loss is to 1. The input to this layer is Fb. The output of this layer is a matrix Fc with dimensions N by M. The operations performed by this layer are as follows:
[0062]
[0063] The parameters of this layer are μ and σ, where subscript i is the feature channel number and subscript j is the category number.
[0064] The third layer is the category similarity loss calculation layer. First, each feature channel is multiplied by a loss weight, and then the category similarity loss is jointly calculated based on the similarity losses of all feature channels. The input to this layer is Fc. The output of this layer is a category loss vector Fd of length M. The operations performed by this layer are as follows:
[0065]
[0066] The parameter of this layer is W, where subscript i is the feature channel number and subscript j is the category number.
[0067] The fourth layer is the classification loss output layer, which retains only the classification prediction loss corresponding to the class of the input image signal during training and transforms the classification loss into an output between 0 and 1. The input to this layer is Fd. The output of this layer is a scalar loss, i.e., the actual classification loss value of the model. The operation performed by this layer is as follows:
[0068]
[0069] Where Y is a ground truth (real data) class vector of length M, N is the number of output feature channels of the fully connected layer, and the subscript j is the class number. Neither Y nor N is trainable. Y is one of the inputs to the model, and N remains unchanged after the model structure is determined, unless the number of channels in the fully connected layer is increased or decreased, in which case N will change accordingly.
[0070] Please refer to Figure 3 The method for reinforcement training of a Gaussian classification neural network provided in this embodiment of the invention may include the following steps:
[0071] S101, The original Gaussian network is reinforced and trained based on the reinforcement network loss layer to obtain the target Gaussian classification neural network.
[0072] Step 1: Initialize the Gaussian classification neural network. Keep the parameters of the previous convolutional and fully connected layers unchanged, and calculate the initialization parameters of the Gaussian mixture discriminant layer according to the parameter initialization method of the Gaussian mixture discriminant layer.
[0073] Step 2: Perform standard training on the Gaussian classification neural network. Use the target dataset to perform standard training on the Gaussian classification neural network until the accuracy can no longer be improved.
[0074] Step 3: Substitute the parameters of the convolutional and fully connected layers of the Gaussian classification neural network into the reinforcement training neural network, and initialize the parameters of the reinforcement network loss layer. The parameters of the reinforcement network loss layer are calculated according to the method for initializing reinforcement network loss layer parameters.
[0075] Step 4: Train the convolutional and fully connected layers of the reinforcement training neural network. Set the parameters of the reinforcement training loss layer to non-trainable, and train the convolutional and fully connected layers of the reinforcement training neural network using the target dataset until the output loss value no longer shows a significant decreasing trend.
[0076] Step 5: Substitute the parameters of the reinforced convolutional and fully connected layers into the Gaussian classification neural network, and initialize the parameters of the Gaussian mixture discriminant layer. The parameters of the Gaussian mixture discriminant layer are calculated according to the Gaussian mixture discriminant layer parameter initialization method;
[0077] Repeat steps 2-5 in a loop until the Gaussian classification neural network achieves a satisfactory classification accuracy.
[0078] It should be noted that the specific reinforcement training methods mentioned in the above steps can be further described in the following three versions according to different parameter initialization methods:
[0079] I. Basic Version – Basic Methods for Parameter Initialization
[0080] Generally, the specific implementation methods for initializing the Gaussian mixture discriminant layer parameters in steps 1 and 5 and the reinforcement training loss layer parameters in step 3 are as follows:
[0081] 1. Initialization method for Gaussian mixture discriminant layer parameters
[0082] First, initialize the values of parameters μ and σ. Then, for each feature channel (i.e., each dimension of the output features from the fully connected layer), independently compute the mean μ of the Gaussian distribution for each class of training samples. i-j and standard sample difference σ i-j , where the subscript i is the feature channel number and the subscript j is the category number.
[0083] Then initialize the values of parameters S and T.
[0084]
[0085]
[0086] Where μ' i 、μ" i These are the maximum and minimum values of the mean of all categories in channel i, respectively.
[0087] The simplified initialization method for W is to set all parameters to 1.
[0088] 2. Enhanced method for initializing parameters of the network loss layer
[0089] First, initialize the values of parameters μ and σ. Then, for each feature channel (i.e., each dimension of the output features from the fully connected layer), independently compute the mean μ of the Gaussian distribution for each class of training samples. i-j and standard sample difference σ i-j , where the subscript i is the feature channel number and the subscript j is the category number.
[0090] Then initialize the values of parameters T and S.
[0091]
[0092]
[0093] Where μ' i 、μ" i These are the maximum and minimum values of the mean of all categories in channel i, respectively.
[0094] The parameter μ is modified as follows to initialize μ so that the maximum value of the mean of all categories in channel i is 1 and the minimum value is -1:
[0095]
[0096] The simplified initialization method for W is to set all parameters to 1.
[0097] The fast convergence initialization method for W is as follows:
[0098]
[0099] II. Advanced Version – Targeted Enhancement of Feature Separability
[0100] Furthermore, during the reinforcement training process, after each step 2 is completed, a feature separability enhancement method is used to independently calculate the feature separability score for each pair of training samples in each feature channel of the fully connected layer output of the Gaussian classification neural network. The channel number with the highest separability score for the best-separable class pair and the class number for the worst-separable class pair are calculated. Combined with parameter optimization, feature separability enhancement can be achieved for the worst-separable class pairs. There are two feature separability enhancement methods: channel replacement and channel addition.
[0101] The alternative channel-based feature separability enhancement method uses the channel with the highest separability score corresponding to the best-separable class pair to enhance the feature separability of the worst-separable class pair. The specific implementation is as follows:
[0102] First, after step 2 is completed, calculate the feature separability score between each pair of categories.
[0103]
[0104] Where subscript i is the feature channel number, and subscripts j and k are the category numbers. ijk This refers to the feature separability scores of category j and category k on feature channel i.
[0105] Calculate the channel number with the highest separability score corresponding to the category with the best separability.
[0106] [i max ,j max ,k max ] = Find(max(q) ijk (12)
[0107] The operator Find is a matrix element subscript operator, which calculates the subscript of the element in the matrix that has the same value as the element on the right side of the operator.max j is the channel number with the highest separability score. max ,k max These are the category numbers of the two categories in the category pair with the highest separability scores.
[0108] Calculate the class number of the class pair with the worst separability.
[0109]
[0110] [j min ,k min ] = Find(min(qmean) jk ),j≠k (14)
[0111] Where N is the number of output feature channels of the fully connected layer. qmeanjk Let j be the average of the separability scores of class j and class k across all feature channels. min ,k min These are the category numbers of the two categories in the category pair with the worst separability scores.
[0112] Finally, during the initialization of the enhanced network loss layer in step 3, after the parameter μ is initialized, the following correction is made:
[0113]
[0114] This method can also be flexibly extended to replace multiple channels at once.
[0115] The feature separability enhancement method by adding channels involves adding feature channels to the class pair with the worst separability to enhance its feature separability. The specific implementation is as follows:
[0116] Similar to the feature separability enhancement method with alternative channels, firstly, after step 2 is completed, the feature separability score between each pair of categories is calculated according to formula (11), and the category number of the category pair with the worst separability is calculated according to formulas (13) and (14).
[0117] Then, in step 3, a feature channel, namely the N+1th channel, is added to the fully connected layer of the enhanced training neural network. The parameters of the added feature channel are set to randomly initialized values between 0 and 1, while the parameters of the original N channels are still substituted from the fully connected layer of the Gaussian classification neural network.
[0118] After initializing the parameters according to the method for initializing the loss layer of the enhanced network, the parameters are then modified as follows:
[0119]
[0120] σN+1-j =0.5 (17)
[0121] t N+1 =0 (18)
[0122] s N+1 =1 (19)
[0123] If W is initialized using a fast convergence initialization method, then let
[0124]
[0125] Finally, when performing step 5, add a feature channel to the fully connected layer of the Gaussian classification neural network, and substitute the parameters of the reinforced training convolutional layer and fully connected layer into the Gaussian classification neural network.
[0126] This method can also be flexibly extended to add multiple channels at once.
[0127] III. Advanced Version – Achieving Free Feature Encoding
[0128] Furthermore, reinforcement training methods allow for flexible feature encoding based on application requirements. Specific implementation methods are as follows:
[0129] During reinforcement training, when initializing the parameter μ, the initialization method is modified as follows: Let...
[0130] μ i-j =v i-j (twenty one)
[0131] Where the subscript 'i' is the feature channel number and the subscript 'j' is the category number. vi-j Let be the cluster center value of the training sample of category j on the i-th feature channel. Other parameters are initialized using the same method.
[0132] S102, acquire the image signal to be classified.
[0133] S103, the image signal to be classified is input into the target Gaussian classification neural network for processing to obtain the classification result.
[0134] In implementing this embodiment of the invention, the original Gaussian classification neural network is enhanced and trained to obtain a target Gaussian classification neural network. An image signal to be classified is acquired, and the image signal is input into the target Gaussian classification neural network for processing to obtain a classification result. The target Gaussian classification neural network includes an enhanced network loss layer connected to a convolutional-fully connected layer. This enhanced loss layer replaces the Gaussian mixture discriminant layer in the original Gaussian classification neural network during training, improving the classification performance of the Gaussian classification neural network and fulfilling special application requirements such as feature encoding. Furthermore, inputting the image signal to be classified into the target Gaussian classification neural network improves the accuracy of signal classification prediction.
[0135] Based on the same inventive concept, embodiments of the present invention provide a device for reinforcement training of Gaussian classification neural networks. For example... Figure 4 As shown, the device includes:
[0136] Training unit 10 performs reinforcement training on the original Gaussian classification neural network to obtain the target Gaussian classification neural network;
[0137] Acquisition unit 11 is used to acquire the image signal to be classified;
[0138] The processing unit 12 is used to input the image signal to be classified into the target Gaussian classification neural network for processing in order to obtain the classification result;
[0139] The target Gaussian classification neural network is obtained by reinforcing the original Gaussian classification neural network through reinforcement training. The reinforcement training neural network includes a reinforcement loss layer connected to a convolutional-fully connected layer, which replaces the Gaussian mixture discriminant layer in the original Gaussian classification neural network. The reinforcement loss layer sequentially comprises four sub-structures:
[0140] The first layer is the normalization layer, which is used to adjust the feature distribution range of each feature channel to between -1 and +1 as much as possible.
[0141] The second layer is the feature similarity loss calculation layer, which is used to calculate the expected similarity loss between the features output by the previous network structure and the learned features.
[0142] The third layer is the category similarity loss calculation layer, which is used to multiply each feature channel by the loss weight and jointly calculate the category similarity loss based on the similarity loss of all feature channels.
[0143] The fourth layer is the classification loss output layer, which retains only the classification prediction loss corresponding to the category of the input image signal and transforms the classification loss into an output between 0 and 1.
[0144] Furthermore, training unit 10 is specifically used for:
[0145] (1) Initialize the original Gaussian classification neural network: Keep the parameters of the convolutional layer and the fully connected layer unchanged, and calculate the initialization parameters of the Gaussian mixture discriminant layer according to the Gaussian mixture discriminant layer parameter initialization method;
[0146] (2) Perform routine training on the original Gaussian classification neural network: Use the target dataset to train the original Gaussian classification neural network until the accuracy can no longer be improved;
[0147] (3) Substitute the parameters of the convolutional and fully connected layers of the original Gaussian classification neural network into the reinforcement training neural network, and initialize the parameters of the reinforcement network loss layer. The parameters of the reinforcement network loss layer are calculated according to the reinforcement network loss layer parameter initialization method; wherein, the reinforcement neural network is obtained by replacing the Gaussian mixture discriminant layer with the reinforcement network loss layer.
[0148] (4) Use reinforcement training neural network to train convolutional and fully connected layers: Set the parameters of the reinforcement network loss layer to be untrainable, and use the target dataset to train the convolutional and fully connected layers of the reinforcement training neural network until the output loss value has no obvious decreasing trend.
[0149] (5) Substitute the parameters of the reinforced convolutional layer and fully connected layer into the original Gaussian classification neural network, and initialize the parameters of the Gaussian mixture discriminant layer, wherein the parameters of the Gaussian mixture discriminant layer are calculated according to the Gaussian mixture discriminant layer parameter initialization method;
[0150] (6) Repeat steps (2)-(5) in a loop until the classification accuracy of the original Gaussian classification neural network reaches the preset value.
[0151] In another preferred embodiment of the invention, such as Figure 5 As shown, the device for reinforcement training of a Gaussian classification neural network may include: one or more processors 101, one or more input devices 102, one or more output devices 103, and a memory 104. The processors 101, input devices 102, output devices 103, and memory 104 are interconnected via a bus 105. The memory 104 stores a computer program, which includes program instructions. The processor 101 is configured to invoke the program instructions to execute the method described in the above-described method embodiment.
[0152] It should be understood that, in this embodiment of the invention, the processor 101 may be a central processing unit (CPU), but it may also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor.
[0153] Input device 102 may include a keyboard, etc., and output device 103 may include a display (LCD, etc.), a speaker, etc.
[0154] The memory 104 may include read-only memory and random access memory, and provides instructions and data to the processor 101. A portion of the memory 104 may also include non-volatile random access memory. For example, the memory 104 may also store device type information.
[0155] In specific implementations, the processor 101, input device 102, and output device 103 described in the embodiments of the present invention can execute the implementation methods described in the embodiments of the method for reinforcement training of Gaussian classification neural networks provided in the embodiments of the present invention, which will not be repeated here.
[0156] It should be noted that the specific workflow and related details of the device for reinforcement training of Gaussian classification neural networks in this embodiment of the invention are described in the foregoing method embodiment section, and will not be repeated here.
[0157] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.
[0158] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed may be indirect coupling or communication connection through some interfaces, devices or units, or may be electrical, mechanical or other forms of connection.
[0159] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of the embodiments of the present invention, depending on actual needs.
[0160] Furthermore, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0161] 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 technical scope disclosed in the present invention, and these modifications or substitutions should all be covered within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.
Claims
1. A method for reinforcement training of a Gaussian classification neural network, characterized in that, include: The original Gaussian classification neural network is reinforced and trained to obtain the target Gaussian classification neural network; Acquire the image signal to be classified; The image signal to be classified is input into the target Gaussian classification neural network for classification processing to obtain the classification result; The target Gaussian classification neural network is obtained by reinforcing the original Gaussian classification neural network through reinforcement training. The reinforcement training neural network includes a reinforcement loss layer connected to a convolutional-fully connected layer, which replaces the Gaussian mixture discriminant layer in the original Gaussian classification neural network. The reinforcement loss layer sequentially comprises four sub-structures: The first layer is the normalization layer, which is used to adjust the feature distribution range of each feature channel to between -1 and +1. The second layer is the feature similarity loss calculation layer, which is used to calculate the expected similarity loss between the features output by the previous network structure and the learned features. The third layer is the category similarity loss calculation layer, which is used to multiply each feature channel by the loss weight and jointly calculate the category similarity loss based on the similarity loss of all feature channels. The fourth layer is the classification loss output layer, which is used to retain only the classification prediction loss corresponding to the category of the input image signal and transform the classification loss into an output between 0 and 1; The original Gaussian classification neural network includes convolutional layers, fully connected layers, and Gaussian mixture discriminant layers; the original Gaussian classification neural network is subjected to reinforcement training to obtain the target Gaussian classification neural network, specifically including the following steps: (1) Initialize the original Gaussian classification neural network: Keep the parameters of the convolutional layer and the fully connected layer unchanged, and calculate the initialization parameters of the Gaussian mixture discriminant layer according to the Gaussian mixture discriminant layer parameter initialization method; (2) Perform routine training on the original Gaussian classification neural network: Use the target dataset to perform routine training on the original Gaussian classification neural network until the accuracy can no longer be improved; (3) Substitute the parameters of the convolutional and fully connected layers of the original Gaussian classification neural network into the reinforcement training neural network, and initialize the parameters of the reinforcement network loss layer. The parameters of the reinforcement network loss layer are calculated according to the reinforcement network loss layer parameter initialization method; wherein, the reinforcement neural network is obtained by replacing the Gaussian mixture discriminant layer with the reinforcement network loss layer. (4) Use reinforcement training neural network to train convolutional and fully connected layers: Set the parameters of the reinforcement network loss layer to be untrainable, and use the target dataset to train the convolutional and fully connected layers of the reinforcement training neural network until the output loss value has no obvious decreasing trend. (5) Substitute the parameters of the reinforced convolutional layer and fully connected layer into the original Gaussian classification neural network, and initialize the parameters of the Gaussian mixture discriminant layer, wherein the parameters of the Gaussian mixture discriminant layer are calculated according to the Gaussian mixture discriminant layer parameter initialization method; (6) Repeat steps (2)-(5) in a loop until the classification accuracy of the original Gaussian classification neural network reaches the preset value.
2. The method as described in claim 1, characterized in that, The initialization of Gaussian mixture discriminant layer parameters specifically includes: (1) Initialize the values of parameters μ and σ: For each dimension of the output features of the fully connected layer, independently calculate the mean μ of the Gaussian distribution for each class of training samples. i-j and standard sample difference σ i-j , where the subscript i is the feature channel number and the subscript j is the category number; (2) Initialize the values of parameters S and T: Where μ' i 、μ" i These are the maximum and minimum values of the mean of all categories in channel i, respectively, where T = [t1, t2, ..., t]. N ] and S = [s1,s2,...,s N ] are translation and scaling parameters, respectively. The function W is an N-by-M matrix. The simplified initialization method for W is to set all parameters to 1. The initialization of parameters for the enhanced network loss layer specifically includes: (1) Initialize the values of parameters μ and σ: For each dimension of the output features of the fully connected layer, independently calculate the mean μ of the Gaussian distribution for each class of training samples. i-j and standard sample difference σ i-j , where the subscript i is the feature channel number and the subscript j is the category number; (2) Initialize the values of parameters T and S: Where μ' i 、μ" i These are the maximum and minimum values of the mean of all categories in channel i, respectively; The parameter μ is modified as follows to initialize μ so that the maximum value of the mean of all categories in channel i is 1 and the minimum value is -1: The function W is an N-by-M matrix, and the simplified initialization method for W is to set all parameters to 1; The fast convergence initialization method for W is as follows:
3. The method as described in claim 1, characterized in that, Parameter initialization methods include methods to enhance the separability of channel-based features, specifically including: (1) After performing conventional training on the original Gaussian classification neural network, calculate the feature separability score between each pair of categories. Where subscript i is the feature channel number, subscripts j and k are the category numbers, and q is the feature channel number. ijk That is, the feature separability scores of category j and category k on feature channel i; (2) Calculate the channel number with the highest separability score corresponding to the category with the best separability. [i max ,j max ,k max ]=Find(max(q ijk )) (2) The operator Find is the matrix element subscript operator, which calculates the index of the element in the matrix that is equal to the value on the right side of the operator; i max j is the channel number with the highest separability score. max ,k max These are the category numbers of the two categories in the category pair with the highest separability scores; (3) Calculate the category number of the category pair with the worst separability. [j min ,k min ]=Find(min(qmean jk )),j≠k (4) Where N is the number of output feature channels of the fully connected layer, and qmean jk Let j be the average of the separability scores of class j and class k across all feature channels; j min ,k min These are the category numbers of the two categories in the category pair with the worst separability scores; (4) When initializing the loss layer of the reinforcement network, after the parameter μ is initialized, the following correction is made:
4. The method as described in claim 1, characterized in that, Parameter initialization methods include methods to enhance the separability of channel-based features, specifically including: (1) After performing regular training on the original Gaussian classification neural network, the feature separability score between each two categories is calculated using formula (1); (2) Calculate the category number of the category pair with the worst separability using formulas (3) and (4); (3) When initializing the loss layer of the reinforcement network, add a feature channel to the fully connected layer of the reinforcement training neural network. The parameters of the added feature channel are set to values between 0 and 1 with random initialization. The parameters of the original N channels are still substituted from the fully connected layer of the Gaussian classification neural network. After initializing the parameters according to the method for initializing the loss layer of the enhanced network, the parameters are then modified as follows: s N+1-j =0.5 t N+1 =0 s N+1 =1 Let W be an N x M matrix. If W is initialized using a fast convergent initialization method, then let... (4) When performing step 5 in claim 2, a feature channel is added to the fully connected layer of the Gaussian classification neural network, and the parameters of the convolutional layer and the fully connected layer that have been reinforced are substituted into the Gaussian classification neural network.
5. The method as described in claim 1, characterized in that, Parameter initialization methods include methods for performing free feature encoding, specifically including: During reinforcement training, when initializing the parameter μ, the initialization method is modified as follows: Let... m i-j =v i-j (21) Where subscript i is the feature channel number, subscript j is the category number, and v i-j The desired cluster center value for the training sample of category j on the i-th feature channel is given, while other parameters are initialized in the same way.
6. A device for reinforcement training of a Gaussian classification neural network, characterized in that, include: The training unit is used to reinforce the original Gaussian classification neural network to obtain the target Gaussian classification neural network. The acquisition unit is used to acquire the image signal to be classified; The processing unit is used to input the image signal to be classified into the target Gaussian classification neural network for processing to obtain the classification result; The target Gaussian classification neural network is obtained by reinforcing the original Gaussian classification neural network through reinforcement training. The reinforcement training neural network includes a reinforcement loss layer connected to a convolutional-fully connected layer, which replaces the Gaussian mixture discriminant layer in the original Gaussian classification neural network. The reinforcement loss layer sequentially comprises four sub-structures: The first layer is the normalization layer, which is used to adjust the feature distribution range of each feature channel to between -1 and +1. The second layer is the feature similarity loss calculation layer, which is used to calculate the expected similarity loss between the features output by the previous network structure and the learned features. The third layer is the category similarity loss calculation layer, which is used to multiply each feature channel by the loss weight and jointly calculate the category similarity loss based on the similarity loss of all feature channels. The fourth layer is the classification loss output layer, which is used to retain only the classification prediction loss corresponding to the category of the input image signal and transform the classification loss into an output between 0 and 1; The original Gaussian classification neural network includes convolutional layers, fully connected layers, and Gaussian mixture discriminant layers. The training unit is specifically used for: (1) Initialize the original Gaussian classification neural network: Keep the parameters of the convolutional layer and the fully connected layer unchanged, and calculate the initialization parameters of the Gaussian mixture discriminant layer according to the Gaussian mixture discriminant layer parameter initialization method; (2) Perform routine training on the original Gaussian classification neural network: Use the target dataset to perform routine training on the original Gaussian classification neural network until the accuracy can no longer be improved; (3) Substitute the parameters of the convolutional and fully connected layers of the original Gaussian classification neural network into the reinforcement training neural network, and initialize the parameters of the reinforcement network loss layer. The parameters of the reinforcement network loss layer are calculated according to the reinforcement network loss layer parameter initialization method; wherein, the reinforcement neural network is obtained by replacing the Gaussian mixture discriminant layer with the reinforcement network loss layer. (4) Use reinforcement training neural network to train convolutional and fully connected layers: Set the parameters of the reinforcement network loss layer to be untrainable, and use the target dataset to train the convolutional and fully connected layers of the reinforcement training neural network until the output loss value has no obvious decreasing trend. (5) Substitute the parameters of the reinforced convolutional layer and fully connected layer into the original Gaussian classification neural network, and initialize the parameters of the Gaussian mixture discriminant layer, wherein the parameters of the Gaussian mixture discriminant layer are calculated according to the Gaussian mixture discriminant layer parameter initialization method; (6) Repeat steps (2)-(5) in a loop until the classification accuracy of the original Gaussian classification neural network reaches the preset value.
7. The device as described in claim 6, characterized in that, The initialization of Gaussian mixture discriminant layer parameters specifically includes: (1) Initialize the values of parameters μ and σ: For each dimension of the output features of the fully connected layer, independently calculate the mean μ of the Gaussian distribution for each class of training samples. i-j and standard sample difference σ i-j , where the subscript i is the feature channel number and the subscript j is the category number; (2) Initialize the values of parameters S and T: Where μ' i 、μ" i These are the maximum and minimum values of the mean of all categories in channel i, respectively. The function W is an N-by-M matrix, and the simplified initialization method for W is to set all parameters to 1. The initialization of parameters for the enhanced network loss layer specifically includes: (1) Initialize the values of parameters μ and σ: For each dimension of the output features of the fully connected layer, independently calculate the mean μ of the Gaussian distribution for each class of training samples. i-j and standard sample difference σ i-j , where the subscript i is the feature channel number and the subscript j is the category number; (2) Initialize the values of parameters T and S: Where μ' i 、μ" i These are the maximum and minimum values of the mean of all categories in channel i, respectively, where T = [t1, t2, ..., t]. N ] and S = [s1,s2,...,s N These are the translation and scaling parameters, respectively. The parameter μ is modified as follows to initialize μ so that the maximum value of the mean of all categories in channel i is 1 and the minimum value is -1: The function W is an N-by-M matrix, and the simplified initialization method for W is to set all parameters to 1; The fast convergence initialization method for W is as follows:
8. A device for reinforcement training of a Gaussian classification neural network, characterized in that, The system includes a processor, an input device, an output device, and a memory, which are interconnected. The memory is used to store a computer program, which includes program instructions. The processor is configured to invoke the program instructions to perform the method as described in any one of claims 1-5.