CN-117077755-B - Channel coefficient adjustment method, device, storage medium and computer equipment
Abstract
The application discloses a channel coefficient adjustment method, a device, a storage medium and computer equipment, wherein the method comprises the steps of determining a pre-task of a data processing model based on a processing type of a multimedia task, performing data expansion processing on a first multimedia data set by adopting the pre-task to obtain a second multimedia data set, inputting the first multimedia data set into the data processing model to obtain a first loss parameter of the data processing model, inputting the first multimedia data set and the second multimedia data set into the data processing model to perform training to obtain a second loss parameter of the data processing model, and updating a channel importance coefficient of a convolution channel in the data processing model based on the first loss parameter and the second loss parameter to obtain the trained data processing model. By adopting the application, the accuracy of data output by the data processing model is improved.
Inventors
- LIU SONG
Assignees
- OPPO广东移动通信有限公司
Dates
- Publication Date
- 20260512
- Application Date
- 20220506
Claims (12)
- 1. A channel coefficient adjustment method, the method comprising: determining a front-end task of the data processing model based on the processing type of the multimedia task; performing data expansion processing on the first multimedia data set by adopting the pre-task to obtain a second multimedia data set; The first multimedia data set is input to the data processing model to obtain a first loss parameter of the data processing model, wherein the first loss parameter is generated according to a plurality of first data features and a loss function in the data processing model, and the first data features are obtained by the data processing model according to the first multimedia data set; Inputting the first multimedia data set and the second multimedia data set into the data processing model for training to obtain a second loss parameter of the data processing model, wherein the second loss parameter is generated according to a plurality of second data features and a loss function in the data processing model, and the second data features are obtained by the data processing model according to the first multimedia data set and the second multimedia data set; and updating the channel importance coefficients of the convolution channels in the data processing model based on the first loss parameters and the second loss parameters to obtain a trained data processing model.
- 2. The method of claim 1, wherein said inputting the first set of multimedia data into the data processing model to obtain a first loss parameter for the data processing model comprises: based on a basic network in the data processing model, performing convolution operation on a plurality of first multimedia data in the first multimedia data set to obtain a plurality of first data features; performing convolution operation on a plurality of first multimedia data in the first multimedia data set based on a pruning network in the data processing model to obtain a plurality of second data features; a first loss parameter of the data processing model is obtained based on the plurality of first data features and the plurality of second data features.
- 3. The method of claim 1, wherein inputting the first and second sets of multimedia data into the data processing model for training to obtain the second loss parameters of the data processing model comprises: based on a basic network in the data processing model, carrying out convolution operation on a plurality of first multimedia data in the first multimedia data set and a plurality of second multimedia data in the second multimedia data set to obtain a plurality of third data features; Based on a pruning network in the data processing model, carrying out convolution operation on a plurality of first multimedia data in the first multimedia data set and a plurality of second multimedia data in the second multimedia data set to obtain a plurality of fourth data features; a second loss parameter of the data processing model is obtained based on the third plurality of data features and the fourth plurality of data features.
- 4. The method of claim 1, wherein inputting the first and second sets of multimedia data into the data processing model for training to obtain the second loss parameters of the data processing model comprises: traversing the first multimedia data set and the second multimedia data set to acquire target multimedia data in the first multimedia data set and the second multimedia data set, wherein the target multimedia data is any multimedia data in the first multimedia data set and the second multimedia data set; based on a basic network in the data processing model, performing convolution operation on the target multimedia data to obtain fifth data characteristics; based on a pruning network in the data processing model, performing convolution operation on the target multimedia data to obtain a sixth data characteristic; Acquiring a third loss parameter of the data processing model based on the fifth data feature and the sixth data feature; and if the first multimedia data set and the second multimedia data set are traversed, acquiring second loss parameters of the data processing model based on a plurality of third loss parameters.
- 5. The method of claim 1, wherein inputting the first and second sets of multimedia data into the data processing model for training to obtain the second loss parameters of the data processing model comprises: based on a pruning network in the data processing model, carrying out convolution operation on a plurality of first multimedia data in the first multimedia data set and a plurality of second multimedia data in the second multimedia data set to obtain a plurality of seventh data features; a second loss parameter of the data processing model is obtained based on the seventh plurality of data features.
- 6. The method of claim 5, wherein the obtaining a second loss parameter of the data processing model based on the plurality of seventh data features comprises: Traversing the plurality of seventh data features to obtain any two seventh data features from the plurality of seventh data features; Acquiring a fourth loss parameter of the data processing model based on the arbitrary two seventh data features; and if the traversal of the seventh data features is finished, acquiring second loss parameters of the data processing model based on the fourth loss parameters.
- 7. The method according to any one of claims 1-6, wherein updating the channel importance coefficients of the convolved channels in the data processing model based on the first loss parameter and the second loss parameter to obtain a trained data processing model comprises: updating channel importance coefficients of a convolution channel in the data processing model based on the first loss parameter and the second loss parameter; acquiring pruning rate of a pruning network in the data processing model; if the pruning rate is greater than or equal to the set pruning rate, stopping training the data processing model to obtain a trained data processing model; And if the pruning rate is smaller than the set pruning rate, acquiring a set number of multimedia data, taking the set number of multimedia data as a first multimedia data set, and executing the data expansion processing on the first multimedia data set by adopting the pre-task to obtain a second multimedia data set.
- 8. The method of claim 7, wherein prior to obtaining the pruning rate of the pruning network in the data processing model, further comprising: Acquiring network precision of a pruning network in the data processing model; if the network precision is greater than or equal to a precision threshold, acquiring the pruning rate of a pruning network in the data processing model; And if the network precision is smaller than the precision threshold, acquiring a set number of multimedia data, taking the set number of multimedia data as a first multimedia data set, and executing the data expansion processing of the first multimedia data set by adopting the pre-task to obtain a second multimedia data set.
- 9. The method of claim 1, wherein prior to determining the pre-task of the data processing model based on the processing type of the multimedia task, further comprising: acquiring an initial data processing network; Setting an initial channel importance coefficient in a plurality of convolution channels of the initial data processing network to obtain a pruning data processing network; And taking the initial data processing network as a basic network of a data processing model, and taking the pruning data processing network as a pruning network of the data processing model.
- 10. A channel coefficient adjustment apparatus, comprising: the task determining module is used for determining a front task of the data processing model based on the processing type of the multimedia task; The data processing module is used for carrying out data expansion processing on the first multimedia data set by adopting the pre-task so as to obtain a second multimedia data set; The first acquisition module is used for inputting the first multimedia data set into the data processing model to obtain a first loss parameter of the data processing model, wherein the first loss parameter is generated according to a plurality of first data features and a loss function in the data processing model, and the first data features are acquired by the data processing model according to the first multimedia data set; The second acquisition module is used for inputting the first multimedia data set and the second multimedia data set into the data processing model for training so as to obtain a second loss parameter of the data processing model, wherein the second loss parameter is generated according to a plurality of second data features and a loss function in the data processing model, and the second data features are acquired by the data processing model according to the first multimedia data set and the second multimedia data set; And the coefficient updating module is used for updating the channel importance coefficient of the convolution channel in the data processing model based on the first loss parameter and the second loss parameter so as to obtain a trained data processing model.
- 11. A storage medium having stored thereon a computer program, which when executed by a processor implements the channel coefficient adjustment method of any of claims 1-9.
- 12. A computer device comprising a processor and a memory, wherein the memory stores a computer program adapted to be loaded by the processor and to perform the steps of the channel coefficient adjustment method according to any of claims 1-9.
Description
Channel coefficient adjustment method, device, storage medium and computer equipment Technical Field The present application relates to the field of machine learning technologies, and in particular, to a channel coefficient adjustment method, a device, a storage medium, and a computer apparatus. Background Machine learning is the core and basis for implementing artificial intelligence, and artificial neural network algorithms are one common implementation of artificial intelligence. Specifically, a neural network model is designed according to an artificial neural network algorithm, the neural network model comprises a large number of convolution kernels and convolution channels, model parameters in an original neural network model are trained through a large number of training data, a trained neural network model is obtained, and the trained neural network model carries out convolution operation and the like based on any input data to obtain output data. Disclosure of Invention The application provides a channel coefficient adjusting method, a device, a storage medium and computer equipment, which can solve the technical problem of how to improve the accuracy of data output by a data processing model. In a first aspect, an embodiment of the present application provides a channel coefficient adjustment method, including: determining a front-end task of the data processing model based on the processing type of the multimedia task; performing data expansion processing on the first multimedia data set by adopting the pre-task to obtain a second multimedia data set; Inputting the first multimedia data set to the data processing model to obtain a first loss parameter of the data processing model; Inputting the first multimedia data set and the second multimedia data set into the data processing model for training so as to obtain a second loss parameter of the data processing model; and updating the channel importance coefficients of the convolution channels in the data processing model based on the first loss parameters and the second loss parameters to obtain a trained data processing model. In a second aspect, an embodiment of the present application provides a channel coefficient adjustment apparatus, including: the task determining module is used for determining a front task of the data processing model based on the processing type of the multimedia task; The data processing module is used for carrying out data expansion processing on the first multimedia data set by adopting the pre-task so as to obtain a second multimedia data set; The first acquisition module is used for inputting the first multimedia data set into the data processing model so as to obtain a first loss parameter of the data processing model; the second acquisition module is used for inputting the first multimedia data set and the second multimedia data set into the data processing model for training so as to obtain a second loss parameter of the data processing model; And the coefficient updating module is used for updating the channel importance coefficient of the convolution channel in the data processing model based on the first loss parameter and the second loss parameter so as to obtain a trained data processing model. In a third aspect, embodiments of the present application provide a storage medium storing a computer program adapted to be loaded by a processor and to perform the steps of the above method. In a fourth aspect, embodiments of the present application provide a computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the method described above when the program is executed. According to the embodiment of the application, a preposed task aiming at a data processing model is additionally arranged according to the processing type of a multimedia task, so that the data expansion processing is carried out on a first multimedia data set through the preposed task, a large number of second multimedia data sets are obtained, then a first loss parameter corresponding to the first multimedia data set is obtained, meanwhile, a second loss parameter corresponding to the first multimedia data set and the second multimedia data set is obtained, channel coefficients of convolution channels in the data processing model are updated according to the loss parameters obtained through the two synchronous training, therefore, pruning accuracy of the data processing model is improved through increasing the training data volume of the data processing model, robustness and generalization of the data processing model are improved through adding an acquisition approach of the loss parameter, and pruning accuracy, robustness and generalization of the data processing model aiming at the processing type of the multimedia task are improved, so that pruning accuracy of output data obtained by the data processing model under different scenes or di