WO2021057186A1 - Procédé d'entraînement de réseau de neurones, procédé de traitement de données, et appareils associés - Google Patents

Procédé d'entraînement de réseau de neurones, procédé de traitement de données, et appareils associés Download PDF

Info

Publication number
WO2021057186A1
WO2021057186A1 PCT/CN2020/101009 CN2020101009W WO2021057186A1 WO 2021057186 A1 WO2021057186 A1 WO 2021057186A1 CN 2020101009 W CN2020101009 W CN 2020101009W WO 2021057186 A1 WO2021057186 A1 WO 2021057186A1
Authority
WO
WIPO (PCT)
Prior art keywords
neural network
batch
module
output
enhanced
Prior art date
Application number
PCT/CN2020/101009
Other languages
English (en)
Chinese (zh)
Inventor
张新雨
袁鹏
钟钊
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP20869339.0A priority Critical patent/EP4030348A4/fr
Publication of WO2021057186A1 publication Critical patent/WO2021057186A1/fr
Priority to US17/701,101 priority patent/US20220215259A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • G06N3/084Backpropagation, e.g. using gradient descent
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/044Recurrent networks, e.g. Hopfield networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/77Processing image or video features in feature spaces; using data integration or data reduction, e.g. principal component analysis [PCA] or independent component analysis [ICA] or self-organising maps [SOM]; Blind source separation
    • G06V10/774Generating sets of training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/82Arrangements for image or video recognition or understanding using pattern recognition or machine learning using neural networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/50Context or environment of the image
    • G06V20/56Context or environment of the image exterior to a vehicle by using sensors mounted on the vehicle
    • G06V20/58Recognition of moving objects or obstacles, e.g. vehicles or pedestrians; Recognition of traffic objects, e.g. traffic signs, traffic lights or roads
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V2201/00Indexing scheme relating to image or video recognition or understanding
    • G06V2201/07Target detection

Definitions

  • This application relates to the field of artificial intelligence, and more specifically, to methods for training neural networks, data processing methods, and related devices.
  • Artificial intelligence is a theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge, and use knowledge to obtain the best results.
  • artificial intelligence is a branch of computer science that attempts to understand the essence of intelligence and produce a new kind of intelligent machine that can react in a similar way to human intelligence.
  • Artificial intelligence is to study the design principles and implementation methods of various intelligent machines, so that the machines have the functions of perception, reasoning and decision-making.
  • Research in the field of artificial intelligence includes robotics, natural language processing, computer vision, decision-making and reasoning, human-computer interaction, recommendation and search, and basic AI theories.
  • neural networks such as deep neural networks
  • a neural network with good performance generally requires a large amount of training data to obtain ideal results.
  • data augmentation can be used to increase the diversity of training samples, improve the robustness of the network model, and avoid overfitting.
  • Data enhancement means transforming existing data, such as flipping, shifting, or rotating, to create more data.
  • data enhancement includes offline enhancement and online enhancement.
  • Offline enhancement refers to directly processing the data set.
  • the number of data is equal to the product of the enhancement factor and the number of the original data set. This method is often used in scenarios where the data set is small.
  • Online enhancement is also called dynamic enhancement, and is mainly applied to large-scale data sets. Online enhancement can obtain more data by performing corresponding changes to the small batch of data that will be input to the model.
  • a data enhancement method is proposed.
  • a search space is designed.
  • the search space includes one or more strategies, and each strategy includes multiple sub-strategies. It consists of two operations.
  • Each operation is an image processing function similar to translation, rotation or shearing.
  • Each operation has two hyperparameters. One hyperparameter is the probability of applying the operation, and the other hyperparameter is the application of the operation. Magnitude.
  • the data enhancement method applies a search algorithm to find a better strategy from the search space, so that the neural network trained based on these better measurements can obtain higher verification accuracy.
  • the search space includes shearing to the x coordinate (ShearX), shearing to the y coordinate (ShearY), flipping the x-axis coordinate (TranslateX), flipping the y coordinate (Translate Y), rotation, automatic contrast, 16 operations such as inversion, equalization, exposure, layering, contrast, color, brightness, sharpness, notch, sample pairing, etc.
  • the amplitude of each operation is discretized into 10 discrete values (uniform spacing).
  • the probability is discrete into 11 values (uniform distribution). Therefore, searching for each sub-strategy becomes a problem of searching for one possible combination in (16*10*11) 2 combinations. Since a strategy includes 5 sub-strategies, the search strategy in the search space becomes a possibility to search for (16*10*11) 10 combinations (ie (16*10*11) 10) strategies) The problem of combination.
  • the algorithm of the search strategy consists of two components, one is the controller of the recurrent neural network, and the other is the training algorithm of the approximate strategy optimization algorithm.
  • the controller samples the above (16*10*11) 10 strategies, and uses the sampling enhancement strategy to enhance the data of the sub-training set, and then uses the data obtained from the data enhancement to train the sub-model to obtain the feedback signal. After the feedback signal is fed back to the controller, the controller performs strategic sampling according to the feedback signal. Repeat the above process until the algorithm converges or reaches the termination condition.
  • the 5 strategies with the best performance are selected from all the strategies obtained from the sampling to form a set of strategies containing 25 sub-strategies, and then this set of strategies containing 25 sub-strategies is used to enhance the training data of the target model. Train the target model based on the enhanced training data.
  • the above method usually requires more than 15,000 samplings to obtain a better strategy.
  • the strategy sampling efficiency of the aforementioned strategy search algorithm is relatively low. Since the training data of the target model is sampled according to the aforementioned strategy search algorithm, the lower sampling efficiency of the aforementioned strategy search algorithm makes the training efficiency of the target model lower.
  • This application provides a training method of a neural network, a data processing method of the neural network, and related devices, which are helpful for improving training efficiency and improving the performance of the neural network.
  • this application provides a neural network training method.
  • the method includes: generating an i-th batch of strategies according to the i-1th group of loss values, where the i-1th group of loss values is the target neural network passing the i-th
  • the output value of the loss function after training of a batch of enhanced training set, i is taken from 2 to N in turn, N is a preset positive integer; according to the i-th batch of strategies, the original training set of the target neural network is data
  • train the target neural network according to the i-th batch of enhanced training set to obtain the loss value of the i-th group; output the target neural network according to the Nth batch of enhanced training set Neural network obtained by network training.
  • the target neural network and the search strategy are alternately trained, so that the generated strategy can change with the state of the target neural network, so that the enhanced training set obtained according to the strategy can be compared with the target neural network.
  • the training process is more suitable, and the performance of the target neural network can be greatly improved.
  • the training device can improve the efficiency of strategy generation, thereby improving the training efficiency of the target neural network.
  • the target neural network trained by this method can be an actual business neural network, it is possible to achieve alternate and synchronous completion of strategy search and business neural network training, which helps to improve training efficiency and provide business neural network performance.
  • the i-th batch of strategies needs to satisfy: after the original training set is input into the target neural network through the i-th batch of enhanced training set obtained by the i-th batch of policy enhancements, the target neural network enhances the i-th batch
  • the loss function value of the inference output of the training set should be greater than the loss function value of the target neural network after the i-1th batch of enhanced training set is input to the target neural network, and the target neural network inference output of the i-1th batch of enhanced training set .
  • the loss value of the target neural network should be reduced.
  • this method trains the target neural network in a confrontational manner, and can continuously discover the weaknesses of the target neural network, and generate higher-quality strategies based on the weaknesses, and perform data enhancement according to the strategies to obtain higher-quality According to the data, a higher quality target neural network can be trained based on this data.
  • the generating the i-th batch of strategies according to the i-1th group of loss values includes: generating all the strategies according to the enhanced strategy neural network and the i-1th group of loss values
  • the enhancement strategy neural network includes a long and short time memory unit, a normalization module, and sampling Module
  • the long and short time memory unit is used to map the operation information output by the sampling module at the previous time step into an M-dimensional vector, where M is the information set to which the operation information output by the sampling module at the current time step belongs
  • the normalization module is used to generate the probability distribution of the M operation information in the information set according to the M-dimensional vector output by the long and short time memory unit, and the information set is an operation type set and an operation probability set Or a set of operation amplitudes
  • the sampling module is configured to sample and output one of the M pieces of
  • the enhanced strategy neural network further includes a word vector embedding module, the word vector embedding module is used to: map the one-bit effective code vector of the operation information output by the sampling module in the previous time step to the real number domain
  • the long and short time memory unit is specifically used to: map the vector output by the word vector embedding module into the M-dimensional vector.
  • the method further includes: using the target neural network trained by the i-1th batch of enhanced training set to perform inference on the original training set, To obtain the i-th batch of features in the target neural network of the data in the original training set.
  • the generating the i-th batch of policies according to the i-1th group of loss values includes: generating the i-th batch of policies according to the i-1th group of loss values and the i-th batch of characteristics.
  • the generating the i-th batch of policies according to the i-1th group of loss values and the i-th batch of features includes: according to enhancement
  • the strategy neural network, the i-th batch of features and the i-1th group of loss values generate the i-th batch of strategies, wherein the i-1 group of loss values and the i-th batch of features are used to guide the
  • the enhanced strategy neural network updates parameters based on the machine learning method.
  • the enhanced strategy neural network includes a long and short time memory unit, a normalization module, a sampling module, and a splicing module.
  • the splicing module is used to combine the i-th batch of features with the
  • the operation information output by the sampling module in the previous time is spliced into a vector
  • the long and short time memory unit is used to obtain an M-dimensional vector according to the vector mapping output by the splicing module
  • M is the output of the sampling module at the current time step
  • the length of the information set to which the operation information belongs is used to generate the probability distribution of the M operation information in the information set according to the M-dimensional vector output by the long and short time memory unit
  • the information set is The operation type set, the operation probability set or the operation amplitude set
  • the sampling module is configured to sample and output one of the M pieces of operation information according to the probability distribution.
  • the enhanced strategy neural network further includes a word vector embedding module, the word vector embedding module is used to map the one-bit effective code vector of the operation information output by the sampling module in the previous time step into a real number domain Vector; the long-short-term memory unit is specifically configured to embed the word vector into the vector output by the module into the M-dimensional vector.
  • this application provides a data processing method, including: acquiring data to be processed; processing the data to be processed according to a target neural network, which is obtained through N trainings, and after the N trainings In the i-th training in, the target neural network is trained through the i-th batch of enhanced training sets, and the i-th batch of enhanced training sets is the training set obtained by the original training set through the i-th batch of strategies.
  • the i-th batch of strategies is a strategy generated according to the i-1th group of loss values, and the i-1th group of loss values is the target neural network when the target neural network is trained according to the i-1th batch of enhanced training set
  • the output value of the loss function, N is a preset positive integer.
  • the method can process data according to the target neural network trained by the method in the first aspect, so that the processing performance can be improved.
  • the target neural network is an image classification network
  • the performance of the target neural network trained by the method in the first aspect is higher, the result of image classification based on the target neural network is more accurate.
  • the i-th batch of strategies is generated according to the enhanced strategy neural network and the i-1th group of loss values, and the i-1 group of loss values is used for Instruct the enhanced strategy neural network to update parameters based on a machine learning method.
  • the enhanced strategy neural network includes a long and short time memory unit, a normalization module, and a sampling module.
  • the long and short time memory unit is used to: prioritize the sampling module
  • M is the length of the information set to which the operation information output by the sampling module belongs at the current time step
  • the normalization module is used to store the unit according to the long and short time
  • the output M-dimensional vector generates the probability distribution of the M operation information in the information set
  • the information set is an operation type set, an operation probability set, or an operation amplitude set
  • the sampling module is used to sample and output according to the probability distribution One of the M pieces of operation information.
  • the enhanced strategy neural network further includes a word vector embedding module, the word vector embedding module is used to map the one-bit effective code vector of the operation information output by the sampling module in the previous time step into a real number domain Vector; the long and short time memory unit is specifically configured to map the vector output by the word vector embedding module into the M-dimensional vector.
  • the i-th batch of strategies is generated based on the i-1th group of loss values and the i-th batch of features, and the i-th batch of features is generated by using The target neural network trained by the i-1th batch of enhanced training set is obtained by inference on the original training set.
  • the i-th batch of strategies is generated based on the enhanced strategy neural network, the i-th batch of features, and the i-1th group of loss values , wherein the i-1 group of loss values and the i-th batch of features are used to guide the enhancement strategy neural network to update parameters based on a machine learning method, and the enhancement strategy neural network includes a long and short time memory unit and a normalization module , A sampling module and a splicing module, the splicing module is used for splicing the i-th batch of features and the operation information output by the sampling module in the previous time into a vector, and the long and short time memory unit is used for according to the
  • the vector mapping output by the splicing module is obtained as an M-dimensional vector, where M is the length of the information set to which the operation information output by the sampling module belongs at the current time step, and the normalization module is used to output according to the long and short time memory unit
  • the M-dimensional vector generates
  • the enhanced strategy neural network further includes a word vector embedding module, the word vector embedding module is used to map the one-bit effective code vector of the operation information output by the sampling module in the previous time step into a real number field The above vector; the long and short time memory unit is specifically used to: embed the word vector into the vector output by the module into the M-dimensional vector.
  • a neural network training device which includes a module for executing the method in the first aspect or any one of the first aspects.
  • a data processing device in a fourth aspect, includes a module for executing the method in the foregoing second aspect or any one of the second aspects.
  • a neural network training device in a fifth aspect, includes: a memory for storing a program; a processor for executing the program stored in the memory. When the program stored in the memory is executed, the device The processor is configured to execute the first aspect or the method in any one of the first aspects.
  • a data processing device which includes: a memory for storing a program; a processor for executing the program stored in the memory, and when the program stored in the memory is executed, the processing The device is used to execute the method in the second aspect or any one of the second aspects.
  • a computer-readable medium stores instructions for device execution, and the instructions are used to implement the method in any one of the first aspect to the second aspect.
  • a computer program product containing instructions when the computer program product runs on a computer, the computer executes the method in any one of the foregoing first aspect to the second aspect.
  • a chip in a ninth aspect, includes a processor and a data interface, the processor reads instructions stored in a memory through the data interface, and executes any one of the first aspect to the second aspect described above The method in the implementation mode.
  • the chip may further include a memory in which instructions are stored, and the processor is configured to execute instructions stored on the memory.
  • the processor is configured to execute the method in any one of the implementation manners of the first aspect to the second aspect.
  • FIG. 1 is a schematic structural diagram of a system architecture provided by an embodiment of the present application.
  • Fig. 2 is a schematic structural diagram of a training device according to an embodiment of the present application.
  • Fig. 3 is a schematic deployment diagram of a training device according to another embodiment of the present application.
  • FIG. 4 is a schematic deployment diagram of a training device according to another embodiment of the present application.
  • Fig. 5 is a schematic structural diagram of a data processing device according to an embodiment of the present application.
  • Fig. 6 is a schematic flowchart of a training method according to an embodiment of the present application.
  • FIG. 7 is a schematic flowchart of a training method according to another embodiment of the present application.
  • Fig. 8 is a schematic structural diagram of a strategy search neural network according to an embodiment of the present application.
  • FIG. 9 is a schematic flowchart of a training method according to another embodiment of the present application.
  • FIG. 10 is a schematic flowchart of a training method according to another embodiment of the present application.
  • FIG. 11 is a schematic structural diagram of a strategy search neural network according to another embodiment of the present application.
  • FIG. 12 is a schematic structural diagram of a strategy search neural network according to another embodiment of the present application.
  • FIG. 13 is a schematic flowchart of a data processing method according to an embodiment of the present application.
  • Fig. 14 is a schematic structural diagram of a device according to an embodiment of the present application.
  • Fig. 15 is a schematic structural diagram of a strategy search neural network according to another embodiment of the present application.
  • the solution of this application can be applied in many fields of artificial intelligence, such as smart terminals, smart manufacturing, smart transportation, smart home, smart medical, smart security, autonomous driving, safe cities and other fields.
  • artificial intelligence such as smart terminals, smart manufacturing, smart transportation, smart home, smart medical, smart security, autonomous driving, safe cities and other fields.
  • Application Scenario 1 Assisted/Automatic Driving System
  • the training method of the embodiment of this application to train the data processing network, and apply the data processing network to the input road picture in the advanced driving assistance system (ADAS) and the automatic driving system (ADS). Processing to identify different objects in the road screen.
  • ADAS advanced driving assistance system
  • ADS automatic driving system
  • the sensor data processing network is used to detect and avoid pedestrians or obstacles on the road, especially to avoid collisions with pedestrians.
  • Application scenario 3 Smart terminal (album classification, image recognition, etc.)
  • the training method of the embodiment of the application to train the album classification neural network, and then use the album classification neural network on the smart terminal (such as smart phone, tablet computer, etc.) to classify the pictures, thereby labeling pictures of different categories, It is convenient for users to view and find.
  • the classification tags of these pictures can also be provided to the album management system for classification management, saving users management time, improving the efficiency of album management, and enhancing user experience.
  • the embodiments of the present application relate to related applications of neural networks.
  • the following first introduces related terms and other related concepts of neural networks that may be involved in the embodiments of the present application.
  • a neural network can be composed of neural units.
  • a neural unit can refer to an arithmetic unit that takes x s and intercept 1 as inputs.
  • the output of the arithmetic unit can be as shown in formula (1-1):
  • s 1, 2,...n, n is a natural number greater than 1
  • W s is the weight of x s
  • b is the bias of the neural unit.
  • f is the activation function of the neural unit, which is used to introduce nonlinear characteristics into the neural network to convert the input signal in the neural unit into an output signal.
  • the output signal of the activation function can be used as the input of the next convolutional layer, and the activation function can be a sigmoid function.
  • a neural network is a network formed by connecting multiple above-mentioned single neural units together, that is, the output of one neural unit can be the input of another neural unit.
  • the input of each neural unit can be connected with the local receptive field of the previous layer to extract the characteristics of the local receptive field.
  • the local receptive field can be a region composed of several neural units.
  • Deep neural network also known as multi-layer neural network
  • the DNN is divided according to the positions of different layers.
  • the neural network inside the DNN can be divided into three categories: input layer, hidden layer, and output layer.
  • the first layer is the input layer
  • the last layer is the output layer
  • the number of layers in the middle are all hidden layers.
  • the layers are fully connected, that is to say, any neuron in the i-th layer must be connected to any neuron in the i+1th layer.
  • DNN looks complicated, it is not complicated as far as the work of each layer is concerned. Simply put, it is the following linear relationship expression: among them, Is the input vector, Is the output vector, Is the offset vector, W is the weight matrix (also called coefficient), and ⁇ () is the activation function.
  • Each layer is just the input vector After such a simple operation, the output vector is obtained Due to the large number of DNN layers, the coefficient W and the offset vector The number is also relatively large.
  • DNN The definition of these parameters in DNN is as follows: Take coefficient W as an example: Suppose in a three-layer DNN, the linear coefficients from the fourth neuron in the second layer to the second neuron in the third layer are defined as The superscript 3 represents the number of layers where the coefficient W is located, and the subscript corresponds to the output third-level index 2 and the input second-level index 4.
  • the coefficient from the kth neuron of the L-1 layer to the jth neuron of the Lth layer is defined as
  • the classifier is generally composed of a fully connected layer and a softmax function (which can be called a normalized exponential function, or a normalized function for short), and can output different types of probabilities according to the input.
  • Convolutional neural network is a deep neural network with convolutional structure.
  • the convolutional neural network contains a feature extractor composed of a convolutional layer and a sub-sampling layer.
  • the feature extractor can be seen as a filter, and the convolution process can be seen as using a trainable filter to convolve with an input image or convolution feature map.
  • the convolutional layer refers to the neuron layer that performs convolution processing on the input signal in the convolutional neural network.
  • a neuron can only be connected to a part of the neighboring neurons.
  • a convolutional layer usually contains several feature planes, and each feature plane can be composed of some rectangularly arranged neural units.
  • Neural units in the same feature plane share weights, and the shared weights here are the convolution kernels. Sharing weight can be understood as the way of extracting image information has nothing to do with location. The underlying principle is that the statistical information of a certain part of the image is the same as that of other parts. This means that the image information learned in one part can also be used in another part. So for all positions on the image, we can use the same learning image information. In the same convolution layer, multiple convolution kernels can be used to extract different image information. Generally, the more the number of convolution kernels, the richer the image information reflected by the convolution operation.
  • the convolution kernel can be initialized in the form of a matrix of random size, and the convolution kernel can obtain reasonable weights through learning during the training process of the convolutional neural network.
  • the direct benefit of sharing weights is to reduce the connections between the layers of the convolutional neural network, and at the same time reduce the risk of overfitting.
  • Convolutional neural networks can use backpropagation (BP) algorithms to modify the size of the parameters in the initial super-resolution model during the training process, so that the reconstruction error loss of the super-resolution model becomes smaller and smaller. Specifically, forwarding the input signal to the output will cause error loss, and the parameters in the initial super-resolution model are updated by backpropagating the error loss information, so that the error loss is converged.
  • the backpropagation algorithm is a backpropagation motion dominated by error loss, and aims to obtain the optimal super-resolution model parameters, such as a weight matrix.
  • RNNs The purpose of RNNs is to process sequence data.
  • the layers In the traditional neural network model, from the input layer to the hidden layer and then to the output layer, the layers are fully connected, and the nodes between each layer are not connected. But this ordinary neural network is powerless for many problems. For example, if you want to predict what the next word of a sentence is, you generally need to use the previous word, because the preceding and following words in a sentence are not independent.
  • RNNs are called recurrent neural networks, that is, the current output of a sequence is also related to the previous output.
  • RNNs can process sequence data of any length
  • RNN is the same as the training of traditional artificial neural network (ANN).
  • ANN artificial neural network
  • Important equation taking the loss function as an example, the higher the output value (loss) of the loss function, the greater the difference, then the training of the deep neural network becomes a process of reducing this loss as much as possible.
  • a strategy includes one or more sub-strategies, a sub-strategy is composed of one or more operations, an operation is an image processing function similar to translation, rotation or shearing, and an operation has two hyper-parameters, and one hyper-parameter is the application The probability of this operation, another hyperparameter is the magnitude of application of this operation.
  • the operations in the sub-strategy can include any of the following: cut to the x coordinate, cut to the y coordinate, flip to the x coordinate, flip to the y coordinate, rotate, automatic contrast, inversion, equalization, exposure, layering, Contrast, color, brightness, sharpness, cutout, sample pairing, etc.
  • a sub-policy includes multiple operations
  • the types of the multiple operations can be the same.
  • Data enhancement means transforming existing data, such as flipping, shifting, or rotating, to create more data.
  • Neural network model is a kind of mathematical calculation model that imitates the structure and function of biological neural network (animal's central nervous system).
  • a neural network model can include a variety of neural network layers with different functions, and each layer includes parameters and calculation formulas. According to different calculation formulas or different functions, different layers in the neural network model have different names. For example, the layer that performs convolution calculations is called a convolutional layer.
  • the convolutional layer is often used for input signals (for example: image ) Perform feature extraction.
  • a neural network model can also be composed of a combination of multiple existing neural network models.
  • Neural network models with different structures can be used in different scenes (for example, classification, recognition or image segmentation) or provide different effects when used in the same scene.
  • Different neural network model structures specifically include one or more of the following: the number of network layers in the neural network model is different, the order of each network layer is different, and the weights, parameters or calculation formulas in each network layer are different.
  • neural network models with higher accuracy for application scenarios such as recognition or classification or image segmentation in the industry.
  • some neural network models can be trained by a specific training set to complete a task alone or combined with other neural network models (or other functional modules) to complete a task.
  • Some neural network models can also be used directly to complete a task alone or in combination with other neural network models (or other functional modules) to complete a task.
  • the neural network model is referred to as neural network for short.
  • Edge device refers to any device with computing resources and network resources between the source of data generation and the cloud center.
  • a mobile phone is an edge device between a person and a cloud center
  • a gateway is an edge device between a smart home and a cloud center.
  • edge devices refer to devices that analyze or process data near the source of the data. Since there is no data flow, network traffic and response time are reduced.
  • the edge devices in the embodiments of this application may be mobile phones with computing capabilities, tablet personal computers (TPC), media players, smart homes, laptop computers (LC), and personal digital assistants (personal digital assistants).
  • assistant PDA
  • personal computer PC
  • camera video camera
  • smart watch wearable device
  • self-driving vehicle etc. It is understandable that the embodiment of the present application does not limit the specific form of the edge device.
  • Inference is relative to training. It means that after the neural network inputs data, the neural network outputs the value of the loss function, feature maps and other information without updating the parameters of the neural network.
  • FIG. 1 is a schematic diagram of the system architecture of an embodiment of the present application.
  • the system architecture 100 includes a data processing device 110, a training device 120, a database 130, a client device 140, a data storage system 150, and a data collection system 160.
  • the data collection device 160 is used to collect training data.
  • the training data may include training images and annotation data, where the annotation data gives the coordinates of the bounding box of the target in the training image.
  • the data collection device 160 stores the training data in the database 130, and the training device 120 trains to obtain the target model/rule 101 based on the training data maintained in the database 130.
  • the target model/rule 101 in the embodiment of the present application may specifically be a neural network. It should be noted that, in actual applications, the training data maintained in the database 130 may not all come from the collection of the data collection device 160, and may also be received from other devices. In addition, it should be noted that the training device 120 does not necessarily perform the training of the target model/rule 101 completely based on the training data maintained by the database 130. It may also obtain training data from the cloud or other places for model training. The above description should not be used as a reference to this application. Limitations of the embodiment.
  • FIG. 2 for an exemplary structure of the training device 120, and refer to FIG. 6 or FIG. 7 for an exemplary deployment manner of the training device 120.
  • the target model/rule 101 trained according to the training device 120 can be applied to different systems or devices, such as the execution device 110 shown in FIG. 1. Refer to FIG. 8 for an exemplary structure of the data processing device 110, and refer to FIG. 9 for an exemplary deployment manner of the data processing device 110.
  • the data processing device 110 may be a terminal, such as a mobile phone terminal, a tablet computer, a notebook computer, augmented reality (AR)/virtual reality (VR), a vehicle-mounted terminal, etc., or may be applied to these devices
  • the chip on it can also be a server or cloud.
  • the data processing apparatus 110 is configured with an input/output (I/O) interface 112 for data interaction with external devices.
  • the user can input data to the I/O interface 112 through the client device 140.
  • the user may input data to be processed, such as an image to be processed, through the client device 140.
  • the data processing device 110 includes a calculation module 111 and an acquisition module 113, and the calculation module 111 includes a target model/rule 101.
  • the obtaining module 113 is used to obtain the data to be processed.
  • the data processing device 110 may call data, codes, etc. in the data storage system 150 for use Corresponding processing, data, instructions, etc. obtained by corresponding processing may also be stored in the data storage system 150.
  • the I/O interface 112 presents the processing result, such as the target detection result calculated by the target model/rule 101, to the client device 140, so as to provide it to the user.
  • the data processing apparatus 110 and the client device in the embodiment of the present application may be the same device, for example, the same terminal device.
  • the training device 120 can generate corresponding target models/rules 101 based on different training data for different goals or different tasks (or services), and the corresponding target models/rules 101 can be used for To achieve the above goals or complete the above tasks, so as to provide users with the desired results.
  • the user can manually set input data, and the manual setting can be operated through the interface provided by the I/O interface 112.
  • the client device 140 can automatically send input data to the I/O interface 112. If the client device 140 is required to automatically send the input data and the user's authorization is required, the user can set the corresponding authority in the client device 140.
  • the user can view the result output by the execution device 110 in the client device 140, and the specific presentation form may be a specific manner such as display, sound, and action.
  • the client device 140 can also be used as a data collection terminal to collect the input data of the input I/O interface 112 and the output result of the output I/O interface 112 as new sample data, and store it in the database 130 as shown in the figure.
  • the I/O interface 112 directly uses the input data input to the I/O interface 112 and the output result of the output I/O interface 112 as a new sample as shown in the figure.
  • the data is stored in the database 130.
  • FIG. 1 is only a schematic diagram of a system architecture provided by an embodiment of the present application, and the positional relationship between the devices, devices, modules, etc. shown in the figure does not constitute any limitation.
  • the data The storage system 150 is an external memory relative to the execution device 110. In other cases, the data storage system 150 may also be placed in the execution device 110.
  • FIG. 2 is a schematic structural diagram of a neural network training device 200 according to an embodiment of the present application.
  • the training device 200 may include a strategy search module 210, a data enhancement module 220, and a training module 230.
  • the strategy search module 210 is used in S610 to implement corresponding functions
  • the data enhancement module is used to implement S620 to implement corresponding functions
  • the training module 230 is used to implement S630 to implement corresponding functions.
  • the training device 200 may further include an inference module 240, and the inference module 240 is used in S840 to implement corresponding functions.
  • the training device can be deployed in a cloud environment, which is an entity that uses basic resources to provide cloud services to users in a cloud computing mode.
  • the cloud environment includes a cloud data center and a cloud service platform.
  • the cloud data center includes a large number of basic resources (including computing resources, storage resources, and network resources) owned by a cloud service provider.
  • the computing resources included in the cloud data center can be a large number of computing resources.
  • Device for example, server).
  • the training device may be a server used for training the target neural network in the cloud data center.
  • the training device may also be a virtual machine created in a cloud data center for training the target neural network.
  • the training device can also be a software device deployed on a server or virtual machine in a cloud data center.
  • the software device is used to train the target neural network.
  • the software device can be distributed on multiple servers or distributed Deployed on multiple virtual machines, or distributed on virtual machines and servers.
  • the strategy search module 210, the data enhancement module 220, the training module 230, and the inference module 240 in the training device 200 may be distributed on multiple servers, or distributed on multiple virtual machines, or distributed Locally deployed on virtual machines and servers.
  • the data enhancement module 220 includes multiple sub-modules
  • the multiple sub-modules may be deployed on multiple servers, or distributedly deployed on multiple virtual machines, or distributedly deployed on virtual machines and servers.
  • the training device can be abstracted by the cloud service provider into a cloud service for training neural networks on the cloud service platform and provided to the user.
  • the cloud environment uses the cloud service to provide the user with Provides cloud services for training neural networks.
  • the training device receives the target neural network to be trained and the original training set, and generates a strategy, uses the strategy to enhance the original training set, and uses the enhanced data set to train the target neural network to be trained, and then according to the training After the feedback information generation strategy, repeat the above steps until the training conditions are met, and finally the target neural network obtained by training is returned to the edge device where the user is located by the training device.
  • API application program interface
  • the training device receives the target neural network to be trained and the original training set, and generates a strategy, uses the strategy to enhance the original training set, and uses the enhanced data set to train the target neural network to be trained, and then according to the training After the feedback information generation strategy, repeat the above steps until the training conditions are met, and finally the target neural network obtained by training is returned to the edge device where the user is located by the training device.
  • the training device can also be separately deployed on a computing device in any environment, for example, separately deployed on a computing device or separately deployed on a computing device in a data center.
  • the computing device 400 includes a bus 401, a processor 402, a communication interface 403, and a memory 404.
  • the processor 402 may be a central processing unit (CPU).
  • the memory 404 may include a volatile memory (volatile memory), such as a random access memory (random access memory, RAM).
  • the memory 704 may also include a non-volatile memory (2non-volatile memory, 2NVM), such as a read-only memory (2read-only memory, 2ROM), a flash memory, a hard disk drive (HDD), or a solid-state starter ( solid state disk, SSD).
  • the memory 404 stores executable codes included in the training device, and the processor 402 reads the executable codes in the memory 404 to execute the training method.
  • the memory 404 may also include an operating system and other software modules required for running processes.
  • the operating system can be LINUX TM , UNIX TM , WINDOWS TM etc.
  • the communication interface 403 receives the original training set and the target neural network
  • the memory 404 stores executable codes that implement the functions of the various modules in the training device 200
  • the processor 402 reads these executable codes to implement the functions of the various modules. , And finally achieve the training of the target neural network.
  • FIG. 5 is a schematic structural diagram of a data processing device 500 according to an embodiment of the present application.
  • the data processing device 500 may include an acquisition module 510 and a calculation module 520.
  • the obtaining module 510 is used to execute S1110 in FIG. 11 to implement corresponding functions.
  • the calculation module 520 is used to execute S1120 in the method shown in FIG. 11 to implement corresponding functions.
  • the data processing apparatus 500 may be separately deployed on a computing device in any environment, for example, separately deployed on a computing device or separately deployed on a computing device in a data center.
  • An exemplary structure of the computing device is shown in FIG. 4, where the communication interface 403 receives the original training set and the target neural network, and the memory 404 stores executable codes that implement the functions of each module in the data processing device 500, and processes The device 402 reads these executable codes, realizes the functions of the various modules, and finally realizes the functions of the target neural network.
  • the data processing device of the embodiment of the present application can process data according to the target neural network trained by the training device 200, thereby improving processing performance.
  • the target neural network is an image classification network
  • the performance of the target neural network trained by the training device 200 is higher, the result of the image classification performed by the execution device according to the target neural network is more accurate.
  • Fig. 6 is a schematic flowchart of a method for training a neural network according to an embodiment of the present application.
  • the method includes S610 to S630.
  • S610 Generate an i-th batch of strategies according to the i-1th group of loss values, where the i-1th group of loss values are the values output by the loss function of the target neural network after the i-1th batch of enhanced training sets are trained, i in turn From 2 to N, N is the preset value.
  • the loss value of the i-1th group includes one or more loss values
  • the strategy of the i-th batch includes one or more strategies.
  • the number of the loss value of the i-1th group and the number of the i-1th batch of enhanced training set corresponds to the incremental training set in the i-1th batch of enhanced training set, that is, the jth loss value in the i-1th group of loss values is the target neural network
  • the output loss function value after training of the corresponding enhanced training set in the i-1th batch of enhanced training set, j is a positive integer less than or equal to M
  • M is the number of loss values in the i-1th group.
  • the number of enhanced training sets in the i-1th batch is usually the same as the number of strategies in the i-1th batch, and the enhanced training set in the i-1th enhanced training set corresponds to the strategies in the i-1th batch of strategies, namely
  • the j-th enhanced training set in the i-1th group of enhanced training set is the training set obtained by the original training set through the enhancement of the corresponding strategy in the i-1th batch of strategies.
  • the i-th batch of strategies needs to satisfy: after the original training set is input into the target neural network through the i-th batch of enhanced training set obtained by the i-th batch of policy enhancements, the target neural network enhances the i-th batch
  • the loss function value of the inference output of the training set should be greater than the loss function value of the target neural network after the i-1th batch of enhanced training set is input to the target neural network, and the target neural network inference output of the i-1th batch of enhanced training set .
  • the target neural network may also be called a business realization neural network, that is, a neural network that is actually used to implement the corresponding business after the training is completed.
  • An example of a target neural network is a convolutional neural network.
  • the target neural network is an image classification network, it is trained in this method and used for image classification on edge devices.
  • the target neural network is a sensor data processing network, it is used to identify people, buildings, roads, or vehicles on edge devices after being trained in this method.
  • the first batch of strategies can be randomly initialized, the original training set is augmented according to the first batch of strategies to obtain the first batch of enhanced training set, and the target neural network is trained according to the first batch of enhanced training set , Get the first set of loss values; in other possible implementations, you can first input the original training set into the target neural network for training, and generate the first set of loss values based on this training.
  • S620 Perform data enhancement on the original training set of the target neural network according to the i-th batch of strategies to obtain the i-th batch of enhanced training sets.
  • the original training set described here is for the enhanced training set, that is, the original training set refers to a data set that has not been enhanced by a strategy.
  • the data enhancement module 220 can be used to randomly select a sub-strategy from the five sub-strategies included in the strategy, and compare information such as the operation type, probability, and strength value in the sub-strategy The data in the original training set is enhanced to obtain an enhanced training set.
  • the data enhancement module 220 can be used to: for each image in each batch of data in the training set, randomly select a sub-strategy from five sub-strategies, and according to the sub-strategies Information such as operation type, probability, and intensity value is data-enhanced to obtain an enhanced training set, and the enhanced training set includes an enhanced image.
  • the implementation manner of using the enhanced training set to train the target neural network may refer to the implementation manner of using the training set to train the neural network in the prior art.
  • the loss value output by S630 is used as the loss value in S610, and S610 to S630 are repeated until the termination condition is satisfied, and the neural network obtained by training the target neural network according to the Nth batch of enhanced training set is output.
  • An exemplary termination condition is that the number of training times of the target neural network reaches a preset maximum value, such as the above-mentioned N; another exemplary termination condition is that at least X different strategies in the search space have been used to perform the original training set. Data enhancement. It can be understood that the termination condition is not limited to the above example, and X is a positive integer.
  • the target neural network and the search strategy are alternately trained, so that the generated strategy can change with the state of the target neural network, so that the enhanced training set obtained according to the strategy can be compared with the target neural network.
  • the training process is more suitable, and the performance of the target neural network can be greatly improved.
  • the training device can improve the efficiency of strategy generation, thereby improving the training efficiency of the target neural network.
  • the target neural network is trained in an adversarial manner, so that the weaknesses of the target neural network can be continuously discovered, and higher-quality strategies are generated according to the weaknesses, and data enhancement is performed according to the strategies to obtain higher Quality data, based on which a higher quality target neural network can be trained.
  • S730 Perform data enhancement on the original training set of the target neural network according to the i-th batch of strategies to obtain the i-th batch of enhanced training sets.
  • S750 Generate the i+1th batch of strategies according to the i-th group of loss values.
  • S760 Determine whether i is less than N, where N is a preset number of training times. That is to say whether the termination condition is met. If yes, execute S770; otherwise, execute S720 again.
  • generating a strategy based on the loss value may include: generating a strategy based on the enhanced strategy network and the loss value.
  • the output loss value of the target neural network after inputting the enhanced strategy neural network, can instruct the enhanced strategy neural network to update the parameters, so that the strategy generated by the enhanced strategy neural network under the updated parameter state is enhanced.
  • the inference loss value of the target neural network increases.
  • the enhancement strategy neural network can use the existing method based on the reinforcement learning algorithm to update the parameters according to the feedback information output by the target neural network.
  • the inference loss value of the target neural network refers to the loss function value obtained by the target neural network inferring the enhanced training set.
  • FIG. 8 is a schematic structural diagram of an enhanced strategy neural network according to an embodiment of the application.
  • the enhanced strategy neural network includes a long short-term memory (LSTM) unit 801, a normalization module 802, and a sampling module 803.
  • LSTM long short-term memory
  • each column represents the execution process of a time step
  • different columns represent different time steps
  • the columns from left to right are the operations in the time steps arranged in chronological order.
  • the LSTM unit may also be referred to as an LSTM layer
  • the normalization module may also be referred to as a normalization (softmax) layer
  • the sampling module may also be referred to as a sample layer.
  • the LSTM unit 801 When the enhanced strategy neural network is started, at the first time step, the LSTM unit 801 performs feature mapping according to the randomly initialized initial state 1 to obtain an M-dimensional feature vector.
  • M is the operation information that the sampling module 803 will output at the current time step belongs to The length of the information set. For example, when the sampling module 803 outputs the operation type at the first time step, if the operation type set includes 16 "operations", the LSTM unit 801 maps the initial state of initialization to a 16-dimensional Feature vector; the normalization module 802 generates the probability distribution of the M operation information in the above-mentioned information set according to the M-dimensional feature vector output by the LSTM unit 801.
  • the normalization module 802 outputs the probability distributions of these 16 "operations” (P1, P2,..., P16); the sampling module 803 performs sampling according to the probability distribution output by the normalization module 802 to obtain an operation information in the above information set by sampling, for example According to the probability distribution of these 16 "operations", one of the "operations" is sampled.
  • the LSTM unit 801 maps the operation information output by the sampling module 803 in the previous time step into an M-dimensional vector.
  • M is the operation information that the sampling module 803 will output in the second time step belongs to The length of the information set.
  • the operation type output by the sampling module 803 at the first time step is "rotation", and when the sampling module 803 will output the operation probability at the second time step, if the operation probability set includes 11 “Probability”, the LSTM unit 801 obtains the 11-dimensional feature vector according to the “rotation” mapping; after the normalization module 802 inputs the 11-dimensional feature vector, the probability distribution of the probability value of the “operation” is generated according to the 11-dimensional feature vector ; The sampling module 803 performs sampling according to the probability distribution, obtains one of the probability values and outputs the value.
  • the LSTM unit 801 maps the operation information output by the sampling module 803 in the second time step into an M-dimensional vector.
  • M is the operation information output by the sampling module 803 in the third time step.
  • the length of the information set to which it belongs, for example, the operation probability that the sampling module 803 outputs at the second time step is "0.9", and when the sampling module 803 outputs the operation amplitude at the third time step, if the operation amplitude set is Including 10 kinds of "amplitudes", the LSTM unit 801 obtains a 10-dimensional feature vector according to the "0.9" mapping; after the normalization module 802 inputs the 10-dimensional feature vector, it generates the amplitude value of the "operation” according to the high-dimensional feature vector Probability distribution; the sampling module 803 performs sampling according to the probability distribution, obtains an amplitude value and outputs the value.
  • the steps in the subsequent time step refer to the operation information output by the previous time step, the performance of the generated strategy can be improved
  • the three outputs of the sampling unit 803 at these three time steps constitute an "operation”.
  • the enhanced strategy neural network continues to circulate the steps in the above-mentioned time steps, and every three time steps can get an "operation", multiple operations constitute a sub-strategy, and multiple sub-strategies constitute a strategy.
  • time sequence of sampling "operation”, "probability” and “amplitude” above is only an example, and one operation type in a sub-strategy, the probability and amplitude of this type of operation can be obtained by sampling in other time sequences. .
  • the enhanced strategy neural network can output multiple strategies, and these multiple strategies are called a batch of strategies.
  • the original training set is enhanced according to this batch of strategies, and multiple enhanced training sets can be obtained.
  • These multiple enhanced training sets correspond to these multiple strategies one-to-one, and each enhanced training set is determined by the corresponding strategy.
  • Data enhancement is performed on the original training set.
  • multiple loss values can be obtained. These multiple loss values are called a set of loss values. These multiple loss values correspond to the multiple enhanced training sets one-to-one. Each loss value is obtained by training the target neural network with the corresponding enhanced training set.
  • the enhanced strategy neural network may also include a word vector embedding module 804, which is used to:
  • the one-bit effective code vector of the operation information output by the sampling module 803 in the previous time step is mapped to a vector in the real number domain.
  • the long and short time memory unit is specifically used to: embed according to the word vector
  • the vector output of the module 804 is mapped to obtain the M-dimensional vector.
  • the word vector embedding module may also be called an embedding layer.
  • the sampling module 803 outputs the third operation type "rotation" in the operation type set.
  • An example of a valid code vector of this operation type is [0010000000000000]
  • the word vector embedding module 804 can use the 16-dimensional one-bit effective coding vector to be a 3-dimensional real number domain vector [0.2, 0.9, 0.5], and the long and short time memory unit 801 obtains the 11-dimensional operation probability according to the real number domain vector mapping. Probability distribution; at the second time step, the sampling module 803 outputs the second probability "0.8" in the set of operating probabilities.
  • the 11-dimensional one-bit effective encoding vector will be a 4-dimensional real number domain vector [0.22, 0.54, 0.42, 0.91], and the long and short time memory unit 801 can obtain a 10-dimensional real number domain vector mapping according to the real number domain vector. Probability distribution of operating amplitude. This method can reduce the amount of calculation and increase the correlation between the output between two time steps.
  • the training method of the embodiment of the present application may further include S910, and accordingly, S610 includes S920.
  • the target neural network when the target neural network is an image classification network, the target neural network performs inference and outputs feature maps extracted from one or more layers.
  • the target neural network's inference on the original training set means that after the data in the original training set is input to the target neural network, the target neural network outputs loss function values, features and other information while not updating the parameters in the target neural network. .
  • the first batch of features are the features obtained by inputting the original training set into the target neural network for inference.
  • S920 Generate an i-th batch of policies according to the i-1th group of loss values and the i-th batch of characteristics.
  • the i-th batch of strategies is generated according to the i-1th group of loss values, the i-th batch of features, and the enhanced strategy neural network.
  • the enhanced strategy neural network is instructed to update the parameters, and the enhanced training set corresponding to the strategy generated by the enhanced strategy neural network after the updated parameters is used for
  • the loss value of the target neural network should be greater than the last loss value.
  • FIG. 10 For the training method shown in FIG. 9, a more detailed schematic flowchart of the training method in an embodiment of the present application is shown in FIG. 10.
  • S1030 Perform inference on the original training set according to the target neural network to obtain the i-th batch of features.
  • S1040 Perform data enhancement on the original training set of the target neural network according to the i-th batch of strategies to obtain the i-th batch of enhanced training sets.
  • S1060 Generate the (i+1)th batch of strategies according to the loss value of the i-th group.
  • S1070 Determine whether i is less than N, where N is a preset number of training times. That is to say whether the termination condition is met. If yes, execute S1080, otherwise execute S1020 again.
  • the enhanced strategy neural network includes an LSTM unit 1101, a normalization module 1102, a sampling module 1103, and a splicing module 1105.
  • the splicing module may also be referred to as a concat layer.
  • the execution process of the enhanced strategy neural network shown in FIG. 11 is similar to that of the enhanced strategy neural network shown in FIG. 8, except that the splicing module is used to perform inference on the original training set to obtain features and sampling module 1103.
  • the operation information output in a period of time is spliced into a vector.
  • the LSTM unit 1101 is used to obtain an M-dimensional vector according to the vector mapping output by the splicing module, where M is the length of the information set to which the operation information output by the sampling module 1103 at the current time step belongs.
  • This implementation method refers to the current state of the target neural network to generate a strategy, which can enable the enhanced strategy neural network to generate more difficult strategies, thereby improving the quality of the target neural network.
  • FIG. 12 For the training method shown in FIG. 9 or FIG. 10, a schematic structural diagram of an enhanced strategy neural network according to an embodiment of the present application is shown in FIG. 12.
  • the enhanced strategy neural network includes an LSTM unit 1201, a normalization module 1202, a sampling module 1203, a word vector embedding module 1204, and a splicing module 1205.
  • the execution process of the enhanced strategy neural network shown in FIG. 12 is similar to the execution process of the enhanced strategy neural network shown in FIG. 11, wherein the function of the word vector embedding module 1204 can refer to the word vector embedding module 804.
  • the enhanced strategy neural network shown in FIG. 8, FIG. 11, or FIG. 12 is only an example, and the enhanced strategy neural network in the technical solution of the present application may also include more functional modules or units, of which one unit Or a module can also be called a layer.
  • a hyperbolic tangent function can also be included between the LSTM unit and the normalization module to compress the data range of the feature vector mapped by the LSTM to prevent The enhancement strategy neural network appears over-fitting too quickly.
  • a strategy can also be generated based on other information.
  • the i-th batch of strategies can be generated according to the i-1th group of loss values and the i-1th group of test accuracy values, and the i-1th group of test accuracy values are the target neural network after the i-1th batch of enhanced training Set the accuracy value obtained by testing after training.
  • the test accuracy value of the i-1 group has the same function as the loss value of the i-1 group, and is used to guide the enhancement strategy neural network to update the parameters.
  • the enhanced strategy neural network can be guided to update the parameters according to the similarity between the previous two adjacent batches of strategies, or it can also be based on one of the strategies generated at the previous time step.
  • the similarity between the two to guide the enhancement strategy neural network to update the parameters can be guided to update the parameters according to the similarity between the previous two adjacent batches of strategies, or it can also be based on one of the strategies generated at the previous time step.
  • FIG. 13 is a schematic flowchart of a data processing method according to an embodiment of the present application.
  • the method may include S1310 and S1320.
  • S1310 Obtain data to be processed.
  • the image to be processed is acquired, and further, the image to be classified or the image to be recognized is acquired.
  • the i-th batch of enhanced training sets is used to compare the The target neural network is trained, the i-th batch of enhanced training set is the training set obtained by the enhancement of the original training set through the i-th batch of strategies, and the i-th batch of strategies are the strategies generated according to the i-1th group of loss values, so
  • the loss value of the i-1th group is the value output by the loss function of the target neural network when the target neural network is trained according to the i-1th batch of enhanced training set.
  • the method of the embodiment of the present application can process data according to the target neural network trained by the method shown in FIG. 6, thereby improving processing performance.
  • the target neural network is an image classification network
  • the performance of the target neural network trained by the method shown in FIG. 6 is higher, the result of image classification based on the target neural network is more accurate.
  • the i-th batch of strategies is a strategy generated based on the i-1th group of loss values and the i-th batch of features. That is to say, the method of the embodiment of the present application can process data according to the target neural network trained in the method shown in FIG. 9, thereby improving the processing performance. For example, when the target neural network is an image classification network, since the performance of the target neural network trained by the method shown in FIG. 9 is higher, the result of image classification based on the target neural network is more accurate.
  • the present application also provides an apparatus 1400 as shown in FIG. 14.
  • the apparatus 1400 includes a processor 1402, a communication interface 1403, and a memory 1404.
  • Another example of the apparatus 1400 is a computing device.
  • the processor 1402, the memory 1404, and the communication interface 1403 communicate through a bus.
  • the processor 1402 may be a CPU.
  • the memory 1404 may include volatile memory, such as RAM.
  • the memory 1404 may also include 2NVM, such as 2ROM, flash memory, HDD or SSD.
  • Executable code is stored in the memory 1404, and the processor 1402 reads the executable code in the memory 1404 to execute the corresponding method.
  • the memory 1404 may also include an operating system and other software modules required for running processes.
  • the operating system can be LINUX TM , UNIX TM , WINDOWS TM etc.
  • the executable code in the memory 1404 is used to implement the method shown in FIG. 6 or FIG. 9, and the processor 1402 reads the executable code in the memory 1404 to execute the method shown in FIG. 6 or FIG. 9.
  • the executable code in the memory 1404 is used to implement the method shown in FIG. 13, and the processor 1402 reads the executable code in the memory 1404 to execute the method shown in FIG. 13.
  • the disclosed system, device, and method may be implemented in other ways.
  • the device embodiments described above are merely illustrative, for example, the division of the units is only a logical function division, and there may be other divisions in actual implementation, for example, multiple units or components may be combined or It can be integrated into another system, or some features can be ignored or not implemented.
  • the displayed or discussed mutual coupling or direct coupling or communication connection may be indirect coupling or communication connection through some interfaces, devices or units, and may be in electrical, mechanical or other forms.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the objectives of the solutions of the embodiments.
  • the functional units in the various embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units may be integrated into one unit.
  • the function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer readable storage medium.
  • the technical solution of the present application essentially or the part that contributes to the existing technology or the part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including Several instructions are used to make a computer device (which may be a personal computer, a server, or a network device, etc.) execute all or part of the steps of the method described in each embodiment of the present application.
  • the aforementioned storage media include: U disk, mobile hard disk, read-only memory (read-only memory, ROM), random access memory (random access memory, RAM), magnetic disks or optical disks and other media that can store program codes. .

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Evolutionary Computation (AREA)
  • Artificial Intelligence (AREA)
  • General Physics & Mathematics (AREA)
  • Health & Medical Sciences (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • General Health & Medical Sciences (AREA)
  • Computing Systems (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • General Engineering & Computer Science (AREA)
  • Biophysics (AREA)
  • Molecular Biology (AREA)
  • Mathematical Physics (AREA)
  • Computational Linguistics (AREA)
  • Biomedical Technology (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Databases & Information Systems (AREA)
  • Medical Informatics (AREA)
  • Multimedia (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Evolutionary Biology (AREA)
  • Image Analysis (AREA)

Abstract

L'invention concerne un procédé d'entraînement de réseau de neurones appliqué au domaine de l'intelligence artificielle, un procédé de traitement de données à l'aide d'un réseau de neurones obtenu par entraînement au moyen du procédé, et des appareils associés. Selon le procédé d'entraînement, un réseau de neurones cible est entraîné dans un mode antagoniste, de telle sorte qu'un module de recherche de politique puisse découvrir en continu les faiblesses du réseau de neurones cible, et une politique de plus haute qualité est générée en fonction des faiblesses ; une augmentation de données est réalisée selon la politique pour obtenir des données de plus haute qualité ; et un réseau de neurones cible de plus haute qualité peut être obtenu par entraînement au moyen des données. Selon le procédé, un traitement de données est effectué à l'aide du réseau de neurones cible, de telle sorte qu'un résultat de traitement plus précis puisse être obtenu.
PCT/CN2020/101009 2019-09-24 2020-07-09 Procédé d'entraînement de réseau de neurones, procédé de traitement de données, et appareils associés WO2021057186A1 (fr)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP20869339.0A EP4030348A4 (fr) 2019-09-24 2020-07-09 Procédé d'entraînement de réseau de neurones, procédé de traitement de données, et appareils associés
US17/701,101 US20220215259A1 (en) 2019-09-24 2022-03-22 Neural network training method, data processing method, and related apparatus

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910904970.7 2019-09-24
CN201910904970.7A CN112633459A (zh) 2019-09-24 2019-09-24 训练神经网络的方法、数据处理方法和相关装置

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US17/701,101 Continuation US20220215259A1 (en) 2019-09-24 2022-03-22 Neural network training method, data processing method, and related apparatus

Publications (1)

Publication Number Publication Date
WO2021057186A1 true WO2021057186A1 (fr) 2021-04-01

Family

ID=75166365

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/101009 WO2021057186A1 (fr) 2019-09-24 2020-07-09 Procédé d'entraînement de réseau de neurones, procédé de traitement de données, et appareils associés

Country Status (4)

Country Link
US (1) US20220215259A1 (fr)
EP (1) EP4030348A4 (fr)
CN (1) CN112633459A (fr)
WO (1) WO2021057186A1 (fr)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113283592A (zh) * 2021-05-13 2021-08-20 北京大学 基于低复杂度lstm的接收端均衡方法及系统
CN113917938A (zh) * 2021-10-08 2022-01-11 北京京航计算通讯研究所 小样本条件下的飞行器姿态控制数据增强和模型训练方法
CN115345285A (zh) * 2022-10-18 2022-11-15 北京白海科技有限公司 基于gpu的时序图神经网络训练方法、系统及电子设备

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113221979B (zh) * 2021-04-27 2023-05-23 北京市商汤科技开发有限公司 样本的生成方法、神经网络的训练方法以及装置
CN113642667B (zh) * 2021-08-30 2024-02-02 重庆紫光华山智安科技有限公司 一种图片增强策略确定方法、装置、电子设备及存储介质
CN113836330A (zh) * 2021-09-13 2021-12-24 清华大学深圳国际研究生院 基于生成对抗性自动增强网络的图像检索方法及装置
CN114511041B (zh) * 2022-04-01 2022-07-22 北京世纪好未来教育科技有限公司 模型训练方法、图像处理方法、装置、设备和存储介质
CN114749342B (zh) * 2022-04-20 2023-09-26 华南理工大学 一种锂电池极片涂布缺陷识别方法、装置及介质
CN115659243B (zh) * 2022-12-22 2023-04-28 四川九通智路科技有限公司 基于mems的基础设施风险监测方法及监测系统
CN116628284B (zh) * 2023-07-19 2023-10-20 益企商旅(山东)科技服务有限公司 一种基于记忆网络的客户信息管理方法及系统

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108427941A (zh) * 2018-04-08 2018-08-21 百度在线网络技术(北京)有限公司 用于生成人脸检测模型的方法、人脸检测方法和装置
CN108460464A (zh) * 2017-02-22 2018-08-28 中兴通讯股份有限公司 深度学习训练方法及装置
CN109359815A (zh) * 2018-09-10 2019-02-19 华北电力大学 基于生成对抗网络的智能电网深度学习训练样本生成方法
KR101947650B1 (ko) * 2017-11-14 2019-05-20 국방과학연구소 게임 엔진 기반의 머신 러닝 학습이미지 생성 장치 및 방법
CN110110689A (zh) * 2019-05-15 2019-08-09 东北大学 一种行人重识别方法

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017158058A1 (fr) * 2016-03-15 2017-09-21 Imra Europe Sas Procédé de classification de cas uniques/rares par renforcement de l'apprentissage dans des réseaux neuronaux
CN109902798A (zh) * 2018-05-31 2019-06-18 华为技术有限公司 深度神经网络的训练方法和装置

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108460464A (zh) * 2017-02-22 2018-08-28 中兴通讯股份有限公司 深度学习训练方法及装置
KR101947650B1 (ko) * 2017-11-14 2019-05-20 국방과학연구소 게임 엔진 기반의 머신 러닝 학습이미지 생성 장치 및 방법
CN108427941A (zh) * 2018-04-08 2018-08-21 百度在线网络技术(北京)有限公司 用于生成人脸检测模型的方法、人脸检测方法和装置
CN109359815A (zh) * 2018-09-10 2019-02-19 华北电力大学 基于生成对抗网络的智能电网深度学习训练样本生成方法
CN110110689A (zh) * 2019-05-15 2019-08-09 东北大学 一种行人重识别方法

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP4030348A4

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113283592A (zh) * 2021-05-13 2021-08-20 北京大学 基于低复杂度lstm的接收端均衡方法及系统
CN113283592B (zh) * 2021-05-13 2022-08-05 北京大学 基于低复杂度lstm的接收端均衡方法及系统
CN113917938A (zh) * 2021-10-08 2022-01-11 北京京航计算通讯研究所 小样本条件下的飞行器姿态控制数据增强和模型训练方法
CN113917938B (zh) * 2021-10-08 2024-04-19 北京京航计算通讯研究所 小样本条件下的飞行器姿态控制数据增强和模型训练方法
CN115345285A (zh) * 2022-10-18 2022-11-15 北京白海科技有限公司 基于gpu的时序图神经网络训练方法、系统及电子设备
CN115345285B (zh) * 2022-10-18 2023-02-03 北京白海科技有限公司 基于gpu的时序图神经网络训练方法、系统及电子设备

Also Published As

Publication number Publication date
CN112633459A (zh) 2021-04-09
US20220215259A1 (en) 2022-07-07
EP4030348A4 (fr) 2022-12-14
EP4030348A1 (fr) 2022-07-20

Similar Documents

Publication Publication Date Title
WO2021057186A1 (fr) Procédé d'entraînement de réseau de neurones, procédé de traitement de données, et appareils associés
WO2021190451A1 (fr) Procédé et appareil d'apprentissage d'un modèle de traitement d'image
CN111930992B (zh) 神经网络训练方法、装置及电子设备
CN111062871B (zh) 一种图像处理方法、装置、计算机设备及可读存储介质
Wang et al. Industrial cyber-physical systems-based cloud IoT edge for federated heterogeneous distillation
WO2020228525A1 (fr) Procédé et appareil de reconnaissance de lieu, procédé et appareil d'apprentissage de modèle pour la reconnaissance de lieu et dispositif électronique
WO2021147325A1 (fr) Procédé et appareil de détection d'objets, et support de stockage
EP4002161A1 (fr) Procédé et appareil de récupération d'image, support de stockage et dispositif
EP3884426B1 (fr) Classification d'actions dans des clips vidéo à l'aide de réseaux neuronaux basés sur l'attention
WO2020238353A1 (fr) Procédé et appareil de traitement de données, support de stockage et dispositif électronique
CN114418030B (zh) 图像分类方法、图像分类模型的训练方法及装置
Pan et al. Hierarchical support vector machine for facial micro-expression recognition
WO2021190433A1 (fr) Procédé et dispositif de mise à jour de modèle de reconnaissance d'objet
CN117033609B (zh) 文本视觉问答方法、装置、计算机设备和存储介质
WO2024067884A1 (fr) Procédé de traitement de données et appareil associé
CN113821668A (zh) 数据分类识别方法、装置、设备及可读存储介质
EP4318322A1 (fr) Procédé de traitement de données et dispositif associé
CN114943937A (zh) 行人重识别方法、装置、存储介质及电子设备
Wu et al. Self-learning and explainable deep learning network toward the security of artificial intelligence of things
Obeso et al. Introduction of explicit visual saliency in training of deep cnns: Application to architectural styles classification
CN116958852A (zh) 视频与文本的匹配方法、装置、电子设备和存储介质
Chen et al. Edge artificial intelligence camera network: an efficient object detection and tracking framework
WO2021129668A1 (fr) Procédé d'apprentissage de réseau neuronal et dispositif
Xu et al. Learning to generalize aerial person re‐identification using the meta‐transfer method
CN112766407B (zh) 一种图像识别方法、装置及存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20869339

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 2020869339

Country of ref document: EP

Effective date: 20220411