Neural network operation method, device, and storage medium

By adding a random mask layer to a neural network and replacing it with a tensor transform layer, the method addresses the complexity and memory issues of multiple neural networks, allowing efficient deployment and evolution.

JP7743634B2Active Publication Date: 2025-09-24DATANG MOBILE COMM EQUIP CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
JP2024538204
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Priority Date
2022-01-13
Filing Date
2022-10-20
Publication Date
2025-09-24
Estimated Expiration
2042-10-20

AI Technical Summary

Technical Problem

The increase in the number of neural networks required to accommodate different dimensional situations leads to high training complexity and large memory overhead, making it difficult to deploy and continuously evolve online learning.

Method used

A random mask layer is added to a neural network to create a second neural network, which is trained using sample data, allowing it to adapt to variable input, output, or intermediate dimensions, and is later replaced with a tensor transform layer to handle different dimensional requirements.

Benefits of technology

This approach reduces training complexity and storage overhead, enabling efficient deployment and continuous evolution of neural networks by requiring only one neural network to be trained and deployed.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007743634000105
    Figure 0007743634000105
  • Figure 0007743634000106
    Figure 0007743634000106
  • Figure 0007743634000107
    Figure 0007743634000107
Patent Text Reader

Abstract

The embodiments of the present disclosure provide a neural network operation method, device, and storage medium, the method including: adding a random mask layer to a first neural network according to a type of variable dimension to obtain a second neural network, the random mask layer is for performing random mask processing on a tensor input to the random mask layer; and training the second neural network using sample data. The neural network operation method, device, and storage medium according to the embodiments of the present disclosure only need to train and deploy one neural network to adapt to different input / output dimension requirements by adding a random mask layer to the neural network, and the method has low training complexity, low storage overhead, and is easy to deploy and continuously evolve online training.
Need to check novelty before this filing date? Find Prior Art

Description

[Technical Field]

[0001] [Cross reference] This application claims priority to a Chinese patent application filed on December 23, 2021, bearing application number 202111593613.7 and entitled "Neural network training and configuration method, device and storage medium," and a Chinese patent application filed on January 13, 2022, bearing application number 202210039452.5 and entitled "Neural network operation method, device and storage medium," both of which are incorporated herein by reference in their entireties.

[0002] The present disclosure relates to the technical field of communications, and more particularly to a neural network operation method, apparatus, and storage medium. [Background technology]

[0003] When the input dimension (input dimension varies depending on the collected data) and / or output dimension of a neural network are uncertain, it is necessary to train one neural network for each possible input dimension and / or output dimension to accommodate different dimensional and task needs.

[0004] Figure 1 shows the principle of the prior art training method for a dimension-variable neural network. As shown in Figure 1, the conventional feasible solution is to train one neural network for each input dimension. As shown in Figure 1, the system automatically selects the corresponding neural network according to the input dimension to make predictions. As the input dimension continues to increase (the data collected in real time goes from partial to complete), the neural network prediction value gradually changes from "rough" to "accurate."

[0005] However, the number of neural networks in the above technical solutions increases with the increase in the number of possible dimensional situations, which increases the complexity of training the neural network (model) and the large memory overhead of the model, which is disadvantageous to the actual deployment and continuous evolution of online learning of neural networks. Summary of the Invention [Problem to be solved by the invention]

[0006] The embodiments of the present disclosure provide a neural network operation method, apparatus and storage medium to solve the technical problem in the prior art that the number of neural networks increases with the increase in the possible situations of dimensions. [Means for solving the problem]

[0007] In a first aspect, an embodiment of the present disclosure comprises: According to the type of variable dimension, a random mask layer is added to the first neural network to obtain a second neural network, wherein the random mask layer is for performing a random mask process on the tensor input to the random mask layer; and training said second neural network using sample data.

[0008] In some embodiments, the type of variable dimension is: A type with variable input dimensions; A type with variable output dimensions; and a type in which the intermediate dimension is variable.

[0009] In some embodiments, adding a random mask layer to the first neural network according to the type of variable dimension described above includes: If the variable dimension type is a type in which the input dimension is variable, it includes adding a random mask layer before the input layer of the first neural network.

[0010] In some embodiments, adding a random mask layer to the first neural network according to the type of variable dimension described above includes: If the variable dimension type is a type in which the output dimension is variable, it includes adding a random mask layer after the output layer of the first neural network.

[0011] In some embodiments, adding a random mask layer to the first neural network according to the type of variable dimension described above includes: If the variable dimension type is a type in which the intermediate dimension is variable, it includes adding a random mask layer to an intermediate layer of the first neural network.

[0012] In some embodiments, adding a random mask layer to an intermediate layer of the first neural network comprises: If only one intermediate dimension is variable, this involves adding one random mask layer before or after the associated intermediate layer.

[0013] In some embodiments, adding a random mask layer to an intermediate layer of the neural network comprises: If multiple intermediate dimensions are variable, this involves adding one random mask layer before or after each of the associated intermediate layers, respectively.

[0014] In some embodiments, training the second neural network using sample data comprises: When the input data dimensions of each sample data are all equal to a first threshold, directly using all sample data to train the second neural network, wherein the first threshold is the maximum value of the input data dimensions of all sample data.

[0015] In some embodiments, training the second neural network using sample data comprises: When at least one first sample data exists, the method includes first performing a reinforcement process on the first sample data, and then training the second neural network using all of the first sample data and all of the second sample data, wherein the first sample data is sample data whose input data dimension is not a first threshold, the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0016] In some embodiments, performing the augmentation process on the first sample data includes: padding the input data of the first sample data with leading zeros.

[0017] In some embodiments, performing the augmentation process on the first sample data includes: padding lower zeros on the input data of the first sample data.

[0018] In some embodiments, training the second neural network using sample data comprises: If at least one first sample data exists, the method includes first removing the first sample data, and then using all second sample data to train the second neural network, wherein the first sample data is sample data whose input data dimension is not a first threshold, the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0019] In some embodiments, performing a random masking process on the tensor input to the random mask layer includes: determining a tensor input to the random mask layer and a random mask tensor; and performing a random mask process on a tensor input to the random mask layer using the random mask tensor.

[0020] In some embodiments, the formula for performing random masking on a tensor input to the random mask layer is:

number

number

number

number

number

[0021] In some embodiments, the random mask tensor is a hard masking tensor.

[0022] In some embodiments, the random mask tensor is a soft masking tensor.

[0023] In some embodiments, the random mask tensor is a combination of a hard masking tensor and a soft masking tensor.

[0024] In some embodiments, after training the second neural network using the sample data as described above, The method further includes replacing the random mask layer in the second neural network after training with a tensor transform layer, the tensor transform layer being for performing a dimensional transformation on a tensor input to the tensor transform layer.

[0025] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained, as described above, comprises: If a random mask layer exists before the input layer of the second neural network after training, replacing the random mask layer before the input layer of the second neural network after training with a tensor padding layer, wherein the tensor padding layer is configured to increase the dimension of a tensor input to the tensor padding layer up to a first threshold, the first threshold being the maximum value of the dimension of input data of all sample data.

[0026] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained, as described above, comprises: If a random mask layer exists after the output layer of the second neural network after training, replacing the random mask layer after the output layer of the second neural network after training with a tensor cropping layer, the tensor cropping layer for reducing the dimension of a tensor input to the tensor cropping layer to a first target value.

[0027] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained, as described above, comprises: If a random mask layer exists in the intermediate layer of the second neural network after training, replacing the random mask layer in the intermediate layer of the second neural network after training with a cascaded tensor cropping and tensor padding layer, wherein the cascaded tensor cropping and tensor padding layer is configured to first reduce the dimension of a tensor input to the cascaded tensor cropping and tensor padding layer to a second target value and then increase it to its original dimension.

[0028] In a second aspect, an embodiment of the present disclosure comprises: a memory for storing a computer program; a transceiver for transmitting and receiving data under the control of said processor; and reading the computer program in said memory; According to the type of variable dimension, a random mask layer is added to the first neural network to obtain a second neural network, wherein the random mask layer is for performing a random mask process on the tensor input to the random mask layer; and training the second neural network using sample data. and a processor for performing the operations.

[0029] In some embodiments, the type of variable dimension is: A type with variable input dimensions; A type with variable output dimensions; and a type in which the intermediate dimension is variable.

[0030] In some embodiments, adding a random mask layer to the first neural network according to the type of variable dimension described above includes: If the variable dimension type is a type in which the input dimension is variable, it includes adding a random mask layer before the input layer of the first neural network.

[0031] In some embodiments, adding a random mask layer to the first neural network according to the type of variable dimension described above includes: If the variable dimension type is a type in which the output dimension is variable, it includes adding a random mask layer after the output layer of the first neural network.

[0032] In some embodiments, adding a random mask layer to the first neural network according to the type of variable dimension described above includes: If the variable dimension type is a type in which the intermediate dimension is variable, it includes adding a random mask layer to an intermediate layer of the first neural network.

[0033] In some embodiments, adding a random mask layer to an intermediate layer of the first neural network comprises: If only one intermediate dimension is variable, this involves adding one random mask layer before or after the associated intermediate layer.

[0034] In some embodiments, adding a random mask layer to an intermediate layer of the neural network comprises: If multiple intermediate dimensions are variable, this involves adding one random mask layer before or after each of the associated intermediate layers, respectively.

[0035] In some embodiments, training the second neural network using sample data comprises: When the input data dimensions of each sample data are all equal to a first threshold, directly using all sample data to train the second neural network, wherein the first threshold is the maximum value of the input data dimensions of all sample data.

[0036] In some embodiments, training the second neural network using sample data comprises: When at least one first sample data exists, the method includes first performing a reinforcement process on the first sample data, and then training the second neural network using all of the first sample data and all of the second sample data, wherein the first sample data is sample data whose input data dimension is not a first threshold, the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0037] In some embodiments, performing the augmentation process on the first sample data includes: padding the input data of the first sample data with leading zeros.

[0038] In some embodiments, performing the augmentation process on the first sample data includes: padding lower zeros on the input data of the first sample data.

[0039] In some embodiments, training the second neural network using sample data comprises: If at least one first sample data exists, the method includes first removing the first sample data, and then using all second sample data to train the second neural network, wherein the first sample data is sample data whose input data dimension is not a first threshold, the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0040] In some embodiments, performing a random masking process on the tensor input to the random mask layer includes: determining a tensor input to the random mask layer and a random mask tensor; and performing a random mask process on a tensor input to the random mask layer using the random mask tensor.

[0041] In some embodiments, the formula for performing random masking on a tensor input to the random mask layer is:

number

number

number

number

number

[0042] In some embodiments, the random mask tensor is a hard masking tensor.

[0043] In some embodiments, the random mask tensor is a soft masking tensor.

[0044] In some embodiments, the random mask tensor is a combination of a hard masking tensor and a soft masking tensor.

[0045] In some embodiments, after training the second neural network using the sample data as described above, The method further includes replacing the random mask layer in the second neural network after training with a tensor transform layer, the tensor transform layer being for performing a dimensional transformation on a tensor input to the tensor transform layer.

[0046] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained, as described above, comprises: If a random mask layer exists before the input layer of the second neural network after training, replacing the random mask layer before the input layer of the second neural network after training with a tensor padding layer, wherein the tensor padding layer is configured to increase the dimension of a tensor input to the tensor padding layer up to a first threshold, the first threshold being the maximum value of the dimension of input data of all sample data.

[0047] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained, as described above, comprises: If a random mask layer exists after the output layer of the second neural network after training, replacing the random mask layer after the output layer of the second neural network after training with a tensor cropping layer, the tensor cropping layer for reducing the dimension of a tensor input to the tensor cropping layer to a first target value.

[0048] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained, as described above, comprises: If a random mask layer exists in the intermediate layer of the second neural network after training, replacing the random mask layer in the intermediate layer of the second neural network after training with a cascaded tensor cropping and tensor padding layer, wherein the cascaded tensor cropping and tensor padding layer is configured to first reduce the dimension of a tensor input to the cascaded tensor cropping and tensor padding layer to a second target value and then increase it to its original dimension.

[0049] In a third aspect, embodiments of the present disclosure provide a method for manufacturing a pharmaceutical composition comprising: Obtaining forecast data; inputting the prediction data into a target neural network that has already been deployed, and obtaining a prediction result output by the target neural network, wherein the target neural network includes at least one tensor transform layer, the tensor transform layer being for performing a dimension transformation on a tensor input to the tensor transform layer.

[0050] In some embodiments, the target neural network is the second neural network of any one of the first aspects.

[0051] In a fourth aspect, an embodiment of the present disclosure provides a method for manufacturing a medicament for a medicament comprising: a memory for storing a computer program; a transceiver for transmitting and receiving data under the control of said processor; and reading the computer program in said memory; Obtaining forecast data; and a processor for performing operations including: inputting the prediction data into a deployed target neural network to obtain a prediction result output by the target neural network, the target neural network including at least one tensor transform layer, the tensor transform layer for performing a dimensional transformation on a tensor input to the tensor transform layer.

[0052] In some embodiments, the target neural network is the second neural network of any one of the first aspects.

[0053] In a fifth aspect, an embodiment of the present disclosure provides a method for manufacturing a medicament for a medicament comprising: an additional module configured to add a random mask layer to the first neural network according to the type of variable dimension to obtain a second neural network, the random mask layer being for performing a random mask operation on a tensor input to the random mask layer; a training module configured to train the second neural network using sample data.

[0054] In some embodiments, the type of variable dimension is: A type with variable input dimensions; A type with variable output dimensions; and a type in which the intermediate dimension is variable.

[0055] In some embodiments, the additional modules specifically include: The variable dimension type is configured to add a random mask layer before an input layer of the first neural network if the variable dimension type is a type in which the input dimension is variable.

[0056] In some embodiments, the additional modules specifically include: When the variable dimension type is a type in which the output dimension is variable, a random mask layer is added after the output layer of the first neural network.

[0057] In some embodiments, the additional modules specifically include: When the variable dimension type is a type in which the intermediate dimension is variable, a random mask layer is added to an intermediate layer of the first neural network.

[0058] In some embodiments, the additional modules specifically include: If only one intermediate dimension is variable, one can configure to add one random mask layer before or after the associated intermediate layer.

[0059] In some embodiments, the additional modules specifically include: If multiple intermediate dimensions are variable, one random mask layer is configured to be added before or after each associated intermediate layer, respectively.

[0060] In some embodiments, the training module specifically: When the input data dimensions of each sample data are all equal to a first threshold, all sample data are directly used to train the second neural network, and the first threshold is the maximum value of the input data dimensions of all sample data.

[0061] In some embodiments, the training module specifically: When at least one first sample data exists, the method is configured to first perform a reinforcement process on the first sample data, and then train the second neural network using all of the first sample data and all of the second sample data, where the first sample data is sample data whose input data dimension is not a first threshold, the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0062] In some embodiments, the training module specifically: The input data of the first sample data is configured to be padded with leading zeros.

[0063] In some embodiments, the training module specifically: The input data of the first sample data is configured to be padded with lower zeros.

[0064] In some embodiments, the training module specifically: When at least one first sample data exists, the first sample data is first removed, and then all second sample data are used to train the second neural network, where the first sample data is sample data whose input data dimension is not a first threshold, the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0065] In some embodiments, the training module specifically: determining a tensor input to the random mask layer and a random mask tensor; and performing a random masking process on a tensor input to the random mask layer using the random mask tensor.

[0066] In some embodiments, the formula for performing random masking on a tensor input to the random mask layer is:

number

number

number

number

number

[0067] In some embodiments, the random mask tensor is a hard masking tensor.

[0068] In some embodiments, the random mask tensor is a soft masking tensor.

[0069] In some embodiments, the random mask tensor is a combination of a hard masking tensor and a soft masking tensor.

[0070] In some embodiments, The method further includes an alignment module configured to replace a random mask layer in the second neural network after it has been trained with a tensor transform layer, the tensor transform layer being for performing a dimensional transformation on a tensor input to the tensor transform layer.

[0071] In some embodiments, the placement module specifically: If a random mask layer exists before the input layer of the second neural network after training, the random mask layer before the input layer of the second neural network after training is replaced with a tensor padding layer, the tensor padding layer is configured to increase the dimension of a tensor input to the tensor padding layer up to a first threshold, the first threshold being the maximum value of the dimension of input data of all sample data.

[0072] In some embodiments, the placement module specifically: If a random mask layer exists after the output layer of the second neural network after training, the random mask layer after the output layer of the second neural network after training is replaced with a tensor cropping layer, the tensor cropping layer for reducing the dimension of a tensor input to the tensor cropping layer to a first target value.

[0073] In some embodiments, the placement module specifically: If a random mask layer exists in the intermediate layer of the second neural network after training, the random mask layer in the intermediate layer of the second neural network after training is configured to replace the random mask layer with a cascade tensor cropping and tensor padding layer, wherein the cascade tensor cropping and tensor padding layer is configured to first reduce the dimension of a tensor input to the cascade tensor cropping and tensor padding layer to a second target value and then increase it to the original dimension.

[0074] In a sixth aspect, an embodiment of the present disclosure provides a method for producing a medicament for a medicament comprising: an acquisition module configured to acquire prediction data; and a processing module configured to input the prediction data into a deployed target neural network to obtain a prediction result output by the target neural network, the target neural network including at least one tensor transform layer, the tensor transform layer for performing dimension transformation on a tensor input to the tensor transform layer.

[0075] In some embodiments, the target neural network is the second neural network of any one of the fifth aspects.

[0076] In a seventh aspect, an embodiment of the present disclosure further provides a processor-readable storage medium having stored thereon a computer program for causing a processor to perform the steps of the method for operating a neural network according to the first or third aspect as described above.

[0077] In an eighth aspect, an embodiment of the present disclosure further provides a computer-readable storage medium having stored thereon a computer program for causing a computer to perform the steps of the method for operating a neural network according to the first or third aspect as described above.

[0078] In a ninth aspect, an embodiment of the present disclosure further provides a communication device-readable storage medium having stored thereon a computer program for causing a communication device to execute the steps of the neural network operation method according to the first or third aspect as described above.

[0079] In a tenth aspect, an embodiment of the present disclosure further provides a chip product-readable storage medium having stored thereon a computer program for causing a chip product to perform the steps of the neural network operation method described in the first or third aspect as described above. [Effects of the Invention]

[0080] The neural network operation method, device, and storage medium according to embodiments of the present disclosure require only one neural network to be trained and deployed to accommodate different input / output dimensional requirements by adding a random mask layer to the neural network, and the method has low training complexity, low storage overhead, and is easy to deploy and continuously evolve online training. [Brief explanation of the drawings]

[0081] In order to more clearly describe the embodiments of the present disclosure or the technical solutions in the prior art, the drawings necessary for describing the embodiments or the prior art will be briefly described below. Of course, the drawings in the following description are some embodiments of the present disclosure, and those skilled in the art can further obtain other drawings based on these drawings without creative work. [Figure 1] FIG. 1 is a diagram illustrating the principle of a training method for a dimension-variable neural network in the prior art. [Figure 2] 1 is a flowchart of a method for operating a neural network according to an embodiment of the present disclosure. [Figure 3] FIG. 1 is a block diagram of a training dimension-variable neural network according to an embodiment of the present disclosure. [Figure 4] FIG. 1 is a schematic diagram of a hard masking tensor according to an embodiment of the present disclosure. [Figure 5] FIG. 1 is a block diagram of a configuration of a dimension-variable neural network according to an embodiment of the present disclosure. [Figure 6] FIG. 1 is a schematic diagram of a tensor padding and tensor cropping module according to an embodiment of the present disclosure. [Figure 7] FIG. 1 is a schematic diagram of an autoencoder neural network according to an embodiment of the present disclosure. [Figure 8] 1A and 1B are schematic diagrams of single-symbol and dual-symbol DMRS according to an embodiment of the present disclosure. [Figure 9] FIG. 1 is a block diagram of an autoencoder-based CSI compressed feedback system according to an embodiment of the present disclosure. [Figure 10] 1 is a schematic diagram of a structure of an electronic device according to an embodiment of the present disclosure. [Figure 11] FIG. 1 is a schematic diagram of the structure of a neural network operation device according to an embodiment of the present disclosure. DETAILED DESCRIPTION OF THE INVENTION

[0082] An artificial neural network (ANN) is a simplified model established by abstracting the neuron network of the human brain from the perspective of information processing. In academia and industry, an ANN, abbreviated as "neural network," is a computational model composed of a large number of computational nodes connected to each other in a specific manner. This model is usually a representation or approximation of a certain algorithm or function mapping. In the training phase of a neural network, engineers must first determine the neural network's structure and hyperparameters. Then, they feed data into the model and apply gradient backpropagation to update the weights of the trained neural network. The trained neural network is an approximation of the mapping relationship between input data and labels. In the deployment phase, new data is fed into the neural network to obtain predictions. Common neural networks include fully connected forward propagation neural networks, convolutional neural networks, and recurrent neural networks. With the increasing performance of computers and the widespread deployment of graphics processors (GPUs), neural networks are widely used in the fields of computer vision, natural language processing, biomedicine, and automatic control.

[0083] Because neural network training and deployment are typically tailored to specific tasks, the input and output dimensions of the neural network are generally determined. A neural network designed for task A training generally cannot be used for task B, or performs poorly when used for task B. When the input and output dimensions of a neural network are uncertain, it is necessary to train one neural network for each possible input and output dimension to accommodate different dimensional and task needs. For example, a system responds based on the predicted values ​​of a deployed neural network, and the neural network's input is data collected in real time. When the system has high real-time requirements, the system hopes that the neural network can make some "rough" predictions based on some collected data, allowing the system to respond in an optimal direction in advance and thereby reducing the total time required to respond in an optimal direction. A conventional feasible solution, as shown in Figure 1, is to train one neural network for each different input dimension (the input dimension varies depending on the collected data). The system automatically selects the corresponding neural network according to the input dimension to make predictions, and as the input dimension continues to increase (the data collected in real time goes from partial to complete), the neural network's prediction value gradually changes from "rough" to "accurate."

[0084] When the input and output dimensions of a neural network are uncertain, the prior art requires the deployment of multiple neural networks to accommodate different input and output dimension requirements. As the number of neural networks increases with the increase in the possible dimensional situations, the model training complexity is high, and the model storage overhead is large, which is unfavorable for the actual deployment and continuous evolution of online learning of neural networks.

[0085] Based on the above technical problems, the embodiments of the present disclosure provide a neural network operation method, device, and storage medium, which adds a random mask layer to the neural network to adapt to different input / output dimensional requirements, requiring only one neural network to be trained and deployed, with low training complexity, low storage overhead, and ease of deployment and continuous evolution of online training.

[0086] In order to make the objectives, technical solutions and advantages of the embodiments of the present disclosure clearer, the technical solutions of the embodiments of the present disclosure will be described below clearly and completely with reference to the drawings in the embodiments of the present disclosure, and of course, the described embodiments are only some embodiments of the present disclosure, and not all embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present disclosure without creative work belong to the scope of protection of the present disclosure.

[0087] 2 is a flowchart of a neural network operation method according to an embodiment of the present disclosure. As shown in FIG. 2, an embodiment of the present disclosure provides a neural network operation method, the execution body of which may be an electronic device such as a terminal, a base station, a core network element, etc. The method includes steps 201 and 202: In step 201, according to the type of variable dimension, a random mask layer is added to the first neural network to obtain a second neural network, and the random mask layer is for performing random mask processing on the tensor input to the random mask layer; In step 202, the second neural network is trained using sample data.

[0088] In some embodiments, the type of variable dimension is: A type with variable input dimensions; A type with variable output dimensions; and a type in which the intermediate dimension is variable.

[0089] In some embodiments, adding a random mask layer to the first neural network in response to the type of variable dimension comprises: If the variable dimension type is a type in which the input dimension is variable, it includes adding a random mask layer before the input layer of the first neural network.

[0090] In some embodiments, adding a random mask layer to the first neural network in response to the type of variable dimension comprises: If the variable dimension type is a type in which the output dimension is variable, it includes adding a random mask layer after the output layer of the first neural network.

[0091] In some embodiments, adding a random mask layer to the first neural network in response to the type of variable dimension comprises: If the variable dimension type is a type in which the intermediate dimension is variable, it includes adding a random mask layer to the intermediate layer of the first neural network.

[0092] In some embodiments, adding a random mask layer to an intermediate layer of the first neural network comprises: If only one intermediate dimension is variable, this involves adding one random mask layer before or after the associated intermediate layer.

[0093] In some embodiments, adding a random mask layer to an intermediate layer of the neural network comprises: If multiple intermediate dimensions are variable, this involves adding one random mask layer before or after each of the associated intermediate layers, respectively.

[0094] In some embodiments, training the second neural network using sample data comprises: When the input data dimensions of each sample data are all equal to a first threshold, the second neural network is trained by directly using all the sample data, and the first threshold is the maximum value of the input data dimensions of all the sample data.

[0095] In some embodiments, training the second neural network using sample data comprises: When at least one first sample data exists, the method includes first performing a reinforcement process on the first sample data, and then training the second neural network using all of the first sample data and all of the second sample data, wherein the first sample data is sample data whose input data dimension is not a first threshold, the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0096] In some embodiments, performing augmentation processing on the first sample data includes: This includes padding the input data of the first sample data with leading zeros.

[0097] In some embodiments, performing augmentation processing on the first sample data includes: This includes padding lower zeros on the input data of the first sample data.

[0098] In some embodiments, training the second neural network using sample data comprises: If there is at least one first sample data, first remove the first sample data, and then use all second sample data to train the second neural network, where the first sample data is sample data whose input data dimension is not a first threshold, and the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0099] In some embodiments, performing a random masking operation on a tensor input to the random mask layer comprises: determining a tensor input to the random mask layer and a random mask tensor; and using the random mask tensor to perform a random mask process on the tensor input to the random mask layer.

[0100] In some embodiments, the formula for random masking the tensors input to the random mask layer is:

number

number

number

number

number

[0101] In some embodiments, the random mask tensor is a hard masking tensor.

[0102] In some embodiments, the random mask tensor is a soft masking tensor.

[0103] In some embodiments, the random mask tensor is a combination of a hard masking tensor and a soft masking tensor.

[0104] In some embodiments, after training the second neural network using the sample data, The method further includes replacing the random mask layer in the second neural network after it has been trained with a tensor transform layer, the tensor transform layer being for performing a dimensional transformation on a tensor input to the tensor transform layer.

[0105] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained comprises: If a random mask layer exists before the input layer of the second neural network after training, replacing the random mask layer before the input layer of the second neural network after training with a tensor padding layer, the tensor padding layer is for increasing the dimension of a tensor input to the tensor padding layer up to a first threshold, the first threshold being the maximum value of the dimension of input data of all sample data.

[0106] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained comprises: If a random mask layer exists after the output layer of the second neural network after being trained, replacing the random mask layer after the output layer of the second neural network after being trained with a tensor cropping layer, the tensor cropping layer for reducing the dimension of a tensor input to the tensor cropping layer to a first target value.

[0107] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained comprises: If a random mask layer exists in the intermediate layer of the second neural network after being trained, replacing the random mask layer in the intermediate layer of the second neural network after being trained with a cascaded tensor cropping and tensor padding layer, wherein the cascaded tensor cropping and tensor padding layer is for first reducing the dimension of a tensor input to the cascaded tensor cropping and tensor padding layer to a second target value and then increasing it to the original dimension.

[0108] An embodiment of the present disclosure determines the input tensor dimensions and output tensor dimensions of the neural input layer, output layer, and some intermediate layers based on the maximum dimension of the training data, the maximum dimension of the labels, and task requirements.

[0109] 3 is a block diagram of a dimension-varying neural network training method according to an embodiment of the present disclosure. As shown in FIG. 3, in the training stage, a random mask module (also referred to as a "random mask layer") is added to a layer corresponding to a tensor that requires dimension variation to train the network. Specifically, the method may include the following steps: 1. If the input dimension of the neural network is variable, add a random mask module to the left of the input layer. 2. If the output dimension of the neural network is variable, add a random mask module to the right of the output layer. 3. When the output dimension of the i-th hidden layer and the input dimension of the i+1-th hidden layer in a neural network are variable, a random mask module is added between the i-th hidden layer and the i+1-th hidden layer. 4. When multiple dimension variable requirements exist simultaneously in the input layer, output layer, and hidden layer of the neural network, multiple random mask modules are added to the corresponding positions. 5. On the left side of the input layer, the training data may only adopt the maximum dimension data (if non-maximum dimension data exists, these data can be removed first), or data augmentation processing may be performed first before training, and low-dimensional input data may be increased to the maximum dimension by using upper or lower zero padding methods.

[0110] After adding the random mask module, the neural network updates the trained neural network by calculating the gradient of the loss function with respect to the neural network weights. The random mask operation (random masking) is performed on the tensor

number

number

number

number

number

number

number

number

number

number

number

number

number

number

number

[0111] 1. Hard Masking

number

number

number

number

number

number

number

number

number

number

number

number

[0112] 2. Soft-Masking For example, exponentially decaying soft masking is

number

number

number

number

number

number

number

[0113] 3.

number

[0114] When the mask tensor acts on a tensor, it is equivalent to performing a weighting operation on the tensor without changing the dimension of the tensor itself.

number

[0115] For example, for first-order tensors (vectors), hard masking

number

number

number

number

number

number

[0116] During the training process, the optimizer calculates gradient backpropagation based on the loss and updates the weight parameters of the neural network.

[0117] Furthermore, FIG. 3 may include the following: 1. The neural network may be, but is not limited to, a convolutional neural network, a forward propagation fully connected neural network, a recurrent neural network, and combinations thereof. 2. The loss function may be, but is not limited to, mean squared error, 1-norm, categorical cross-entropy, and cosine similarity. 3. The random mask module customizes the gradient and avoids the problem of vanishing or non-differentiable gradients by treating the mask tensor as a constant tensor. 4. The input random mask, output random mask, and intermediate layer random mask may exist simultaneously, or only some of them may exist. The number of random masks to be used may be determined according to the specific task.

[0118] 5 is a block diagram of a variable-dimension neural network configuration according to an embodiment of the present disclosure. As shown in FIG. 5, in the configuration stage, the variable-dimension neural network is configured by removing a random mask module from a trained neural network and adding a tensor padding module (also referred to as a "tensor padding layer") and a tensor cropping module (also referred to as a "tensor cropping layer") to the trained neural network. Specifically, the configuration may include the following steps: 1. Replace the random mask module on the left side of the input layer with a tensor padding module, and pad the input tensor to the maximum input dimension using either lower or upper zero padding. 2. Replace the random mask module on the right side of the output layer with a tensor cropping module, and output the tensor using the upper or lower cropping method. 3. Replace the random mask module between hidden layer i and hidden layer i+1 with a cascaded tensor cropping and tensor padding module.

[0119] In the whole process, only one neural network needs to be trained and deployed to adapt to different input / output dimension requirements, avoiding the problems of training and storing multiple neural networks.

[0120] As shown in Figure 5, the variable dimension neural network is constructed based on the trained neural network by removing the random mask module and replacing it with a tensor padding and tensor cropping module. As shown in Figure 6, the replaced tensor padding and tensor cropping modules are used to

number

number

number

number

[0121] Output Tensor

number

number

number

[0122] It can be seen that the system only needs to deploy one neural network, the output tensor is cropped as needed, and the input tensor is simply padded with zeros to meet different input and output dimensional requirements.

[0123] The following further illustrates the above method with some specific examples.

[0124] Example 1: As shown in Figure 7, the neural network is an autoencoder used for image compression, where the encoder module is used to compress the image and the decoder module is used to restore the image. The input of the encoder and the output of the decoder are both

number

number

number

[0125] Example 2: As in Example 1, an autoencoder is used for image compression, and both the input of the encoder and the output of the decoder are

number

number

number

number

number

number

number

[0126] Example 3: In an artificial intelligence-based channel estimation algorithm, the receiver estimates channel coefficients for all time-frequency resource blocks based on the received values ​​of a demodulation reference signal (DMRS), and the channel recovery algorithm is implemented based on a neural network. For a single time slot (14 OFDM symbols) and eight physical resource blocks (96 frequencies), the single-symbol DMRS and dual-symbol DMRS configurations are shown in Figure 8. The single-symbol DMRS configuration corresponds to a neural network with input dimensions of 48x1x2 (48 corresponds to frequency, 1 corresponds to time, and 2 corresponds to the real and imaginary parts of the complex number). The dual-symbol DMRS configuration (one DMRS symbol is further configured on top of the single-symbol configuration) corresponds to a neural network with input dimensions of 48x2x2 and output dimensions of 96x14x2. The maximum input dimension of the neural network for channel estimation is

number

number

[0127] Example 4: As in Example 3, for a single time slot (14 OFDM symbols) and 8 physical resource blocks (96 frequencies), the single-symbol DMRS configuration corresponds to a neural network with input dimensions of 48x1x2, and the dual-symbol DMRS configuration corresponds to a neural network with input dimensions of 48x2x2. The maximum input dimension of the neural network for channel estimation is

number

number

number

[0128] Example 5: As shown in Figure 9, the artificial intelligence-based channel state information (CSI) compression algorithm is realized using an autoencoder, where the encoder is located on the UE side and the decoder is located on the base station side. The UE side estimates the channel H based on the CSI reference signal (RS) to calculate the precoding vector V, and the dimension of the precoding vector V is

number

number

number

number

number

[0129] The neural network operation method provided by the embodiments of the present disclosure only requires training and deployment of one neural network to accommodate different input / output dimensional requirements, and the method has low training complexity, low storage overhead, and is easy to deploy and continuously evolve online training.

[0130] FIG. 10 is a schematic diagram of the structure of an electronic device according to an embodiment of the present disclosure. As shown in FIG. 10, the electronic device includes: a memory 1020 for storing a computer program; a transceiver 1000 for transmitting and receiving data under the control of the processor 1010; and a processor 1010 for reading the computer program in the memory 1020 and According to the type of variable dimension, a random mask layer is added to the first neural network to obtain a second neural network, wherein the random mask layer is for performing a random mask process on the tensor input to the random mask layer; and training the second neural network utilizing sample data.

[0131] Specifically, the transceiver 1000 is used to receive and transmit data under the control of a processor 1010 .

[0132] 10, the bus architecture may include any number of interconnected buses and bridges, specifically linking together various circuits, such as one or more processors, represented by processor 1010, and memory, represented by memory 1020. The bus architecture may also link together various other circuits, such as peripheral devices, voltage regulators, and power management circuits, all of which are well known in the art and will not be further described herein. The bus interface provides an interface. The transceiver 1000 may be multiple elements, i.e., includes a transmitter and a receiver, and provides a unit for communicating with various other devices over transmission media. These transmission media include wireless channels, wired channels, optical cables, and the like. The processor 1010 manages the bus architecture and general processing, and the memory 1020 can store data used by the processor 1010 to perform operations.

[0133] The processor 1010 may be a central processing unit (CPU), an application specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or a complex programmable logic device (CPLD), and the processor may employ a multi-core architecture.

[0134] In some embodiments, the type of variable dimension is: A type with variable input dimensions; A type with variable output dimensions; and a type in which the intermediate dimension is variable.

[0135] In some embodiments, adding a random mask layer to the first neural network according to the type of variable dimension described above includes: If the variable dimension type is a type in which the input dimension is variable, it includes adding a random mask layer before the input layer of the first neural network.

[0136] In some embodiments, adding a random mask layer to the first neural network according to the type of variable dimension described above includes: If the variable dimension type is a type in which the output dimension is variable, it includes adding a random mask layer after the output layer of the first neural network.

[0137] In some embodiments, adding a random mask layer to the first neural network according to the type of variable dimension described above includes: If the variable dimension type is a type in which the intermediate dimension is variable, it includes adding a random mask layer to an intermediate layer of the first neural network.

[0138] In some embodiments, adding a random mask layer to an intermediate layer of the first neural network comprises: If only one intermediate dimension is variable, this involves adding one random mask layer before or after the associated intermediate layer.

[0139] In some embodiments, adding a random mask layer to an intermediate layer of the neural network comprises: If multiple intermediate dimensions are variable, this involves adding one random mask layer before or after each of the associated intermediate layers, respectively.

[0140] In some embodiments, training the second neural network using sample data comprises: When the input data dimensions of each sample data are all equal to a first threshold, directly using all sample data to train the second neural network, wherein the first threshold is the maximum value of the input data dimensions of all sample data.

[0141] In some embodiments, training the second neural network using sample data comprises: When at least one first sample data exists, the method includes first performing a reinforcement process on the first sample data, and then training the second neural network using all of the first sample data and all of the second sample data, wherein the first sample data is sample data whose input data dimension is not a first threshold, the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0142] In some embodiments, performing the augmentation process on the first sample data includes: padding the input data of the first sample data with leading zeros.

[0143] In some embodiments, performing the augmentation process on the first sample data includes: padding lower zeros on the input data of the first sample data.

[0144] In some embodiments, training the second neural network using sample data comprises: If at least one first sample data exists, the method includes first removing the first sample data, and then using all second sample data to train the second neural network, wherein the first sample data is sample data whose input data dimension is not a first threshold, the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0145] In some embodiments, performing a random masking process on the tensor input to the random mask layer includes: determining a tensor input to the random mask layer and a random mask tensor; and performing a random mask process on a tensor input to the random mask layer using the random mask tensor.

[0146] In some embodiments, the formula for performing random masking on a tensor input to the random mask layer is:

number

number

number

number

number

[0147] In some embodiments, the random mask tensor is a hard masking tensor.

[0148] In some embodiments, the random mask tensor is a soft masking tensor.

[0149] In some embodiments, the random mask tensor is a combination of a hard masking tensor and a soft masking tensor.

[0150] In some embodiments, after training the second neural network using the sample data as described above, The method further includes replacing the random mask layer in the second neural network after training with a tensor transform layer, the tensor transform layer being for performing a dimensional transformation on a tensor input to the tensor transform layer.

[0151] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained, as described above, comprises: If a random mask layer exists before the input layer of the second neural network after training, replacing the random mask layer before the input layer of the second neural network after training with a tensor padding layer, wherein the tensor padding layer is configured to increase the dimension of a tensor input to the tensor padding layer up to a first threshold, the first threshold being the maximum value of the dimension of input data of all sample data.

[0152] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained, as described above, comprises: If a random mask layer exists after the output layer of the second neural network after training, replacing the random mask layer after the output layer of the second neural network after training with a tensor cropping layer, the tensor cropping layer for reducing the dimension of a tensor input to the tensor cropping layer to a first target value.

[0153] In some embodiments, replacing the random mask layer with a tensor transform layer in the second neural network after it has been trained, as described above, comprises: If a random mask layer exists in the intermediate layer of the second neural network after training, replacing the random mask layer in the intermediate layer of the second neural network after training with a cascaded tensor cropping and tensor padding layer, wherein the cascaded tensor cropping and tensor padding layer is configured to first reduce the dimension of a tensor input to the cascaded tensor cropping and tensor padding layer to a second target value and then increase it to its original dimension.

[0154] Specifically, the electronic device according to the embodiment of the present disclosure can implement all the method steps implemented by the method embodiment in which the execution body is an electronic device, and can achieve the same technical effects, and details of the same parts and beneficial effects of this embodiment as those of the method embodiment will be omitted here.

[0155] An embodiment of the present disclosure comprises: Obtaining forecast data; The present invention further provides a neural network operation method, comprising: inputting the prediction data into a deployed target neural network to obtain a prediction result output by the target neural network, wherein the target neural network includes at least one tensor transform layer, the tensor transform layer for performing dimension transformation on a tensor input to the tensor transform layer.

[0156] In some embodiments, the target neural network is the second neural network of any one of the above embodiments.

[0157] The neural network operation method provided by the embodiments of the present disclosure only requires training and deployment of one neural network to accommodate different input / output dimensional requirements, and the method has low training complexity, low storage overhead, and is easy to deploy and continuously evolve online training.

[0158] An embodiment of the present disclosure comprises: a memory for storing a computer program; a transceiver for transmitting and receiving data under the control of said processor; and reading the computer program in said memory; Obtaining forecast data; and a processor for performing operations including: inputting the prediction data into a deployed target neural network to obtain a prediction result output by the target neural network, the target neural network including at least one tensor transform layer, the tensor transform layer for performing a dimensional transformation on a tensor input to the tensor transform layer.

[0159] Specifically, the transceiver is used to receive and transmit data under the control of a processor.

[0160] A bus architecture may include any number of interconnected buses and bridges, specifically linking together various circuits, such as one or more processors represented by the processor and memory represented by the memory. The bus architecture may also link together various other circuits, such as peripheral devices, voltage regulators, power management circuits, etc., all of which are well known in the art and will not be further described herein. A bus interface provides an interface. A transceiver may be multiple elements, i.e., includes a transmitter and a receiver, and provides a unit for communicating with various other devices over a transmission medium. These transmission media include wireless channels, wired channels, optical cables, and the like. The processor manages the bus architecture and normal processing, and the memory may store data used by the processor to perform operations.

[0161] The processor may be a central processing unit (CPU), an application specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or a complex programmable logic device (CPLD), and the processor may employ a multi-core architecture.

[0162] In some embodiments, the target neural network is the second neural network of any one of the above embodiments.

[0163] The electronic device provided by the embodiments of the present disclosure only needs to train and deploy one neural network to adapt to different input / output dimensional requirements, and the method has low training complexity, low storage overhead, and is easy to deploy and continuously evolve online training.

[0164] FIG. 11 is a schematic diagram of the structure of a neural network operation device according to an embodiment of the present disclosure. As shown in FIG. 11, the embodiment of the present disclosure includes: The present invention provides a neural network operation device, including: an adding module 1101 configured to add a random mask layer to a first neural network according to a type of variable dimension to obtain a second neural network, wherein the random mask layer is for performing random mask processing on a tensor input to the random mask layer; and a training module 1102 configured to train the second neural network using sample data.

[0165] In some embodiments, the type of variable dimension is: A type with variable input dimensions; A type with variable output dimensions; and a type in which the intermediate dimension is variable.

[0166] In some embodiments, the additional modules specifically include: The variable dimension type is configured to add a random mask layer before an input layer of the first neural network if the variable dimension type is a type in which the input dimension is variable.

[0167] In some embodiments, the additional modules specifically include: When the variable dimension type is a type in which the output dimension is variable, a random mask layer is added after the output layer of the first neural network.

[0168] In some embodiments, the additional modules specifically include: When the variable dimension type is a type in which the intermediate dimension is variable, a random mask layer is added to an intermediate layer of the first neural network.

[0169] In some embodiments, the additional modules specifically include: If only one intermediate dimension is variable, one can configure to add one random mask layer before or after the associated intermediate layer.

[0170] In some embodiments, the additional modules specifically include: If multiple intermediate dimensions are variable, one random mask layer is configured to be added before or after each associated intermediate layer, respectively.

[0171] In some embodiments, the training module specifically: When the input data dimensions of each sample data are all equal to a first threshold, all sample data are directly used to train the second neural network, and the first threshold is the maximum value of the input data dimensions of all sample data.

[0172] In some embodiments, the training module specifically: When at least one first sample data exists, the method is configured to first perform a reinforcement process on the first sample data, and then train the second neural network using all of the first sample data and all of the second sample data, where the first sample data is sample data whose input data dimension is not a first threshold, the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0173] In some embodiments, the training module specifically: The input data of the first sample data is configured to be padded with leading zeros.

[0174] In some embodiments, the training module specifically: The input data of the first sample data is configured to be padded with lower zeros.

[0175] In some embodiments, the training module specifically: When at least one first sample data exists, the first sample data is first removed, and then all second sample data are used to train the second neural network, where the first sample data is sample data whose input data dimension is not a first threshold, the second sample data is sample data whose input data dimension is the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

[0176] In some embodiments, the training module specifically: determining a tensor input to the random mask layer and a random mask tensor; and performing a random masking process on a tensor input to the random mask layer using the random mask tensor.

[0177] In some embodiments, the formula for performing random masking on a tensor input to the random mask layer is:

number

number

number

number

number

[0178] In some embodiments, the random mask tensor is a hard masking tensor.

[0179] In some embodiments, the random mask tensor is a soft masking tensor.

[0180] In some embodiments, the random mask tensor is a combination of a hard masking tensor and a soft masking tensor.

[0181] In some embodiments, The method further includes an alignment module configured to replace a random mask layer in the second neural network after it has been trained with a tensor transform layer, the tensor transform layer for performing a dimensional transformation on a tensor input to the tensor transform layer.

[0182] In some embodiments, the placement module specifically: If a random mask layer exists before the input layer of the second neural network after training, the random mask layer before the input layer of the second neural network after training is replaced with a tensor padding layer, the tensor padding layer is configured to increase the dimension of a tensor input to the tensor padding layer up to a first threshold, the first threshold being the maximum value of the dimension of input data of all sample data.

[0183] In some embodiments, the placement module specifically: If a random mask layer exists after the output layer of the second neural network after training, the random mask layer after the output layer of the second neural network after training is replaced with a tensor cropping layer, the tensor cropping layer for reducing the dimension of a tensor input to the tensor cropping layer to a first target value.

[0184] In some embodiments, the placement module specifically: If a random mask layer exists in the intermediate layer of the second neural network after training, the random mask layer in the intermediate layer of the second neural network after training is configured to replace the random mask layer with a cascade tensor cropping and tensor padding layer, wherein the cascade tensor cropping and tensor padding layer is configured to first reduce the dimension of a tensor input to the cascade tensor cropping and tensor padding layer to a second target value and then increase it to the original dimension.

[0185] Specifically, the neural network operation device according to the embodiment of the present disclosure can implement all the method steps implemented by the method embodiment in which the execution body is an electronic device, and can achieve the same technical effects, and details of the same parts and beneficial effects of this embodiment as those of the above method embodiment will be omitted here.

[0186] An embodiment of the present disclosure comprises: an acquisition module configured to acquire prediction data; and a processing module configured to input the prediction data into a deployed target neural network to obtain a prediction result output by the target neural network, wherein the target neural network includes at least one tensor transform layer, the tensor transform layer for performing dimension transformation on a tensor input to the tensor transform layer.

[0187] In some embodiments, the target neural network is the second neural network of any one of the above embodiments.

[0188] The neural network operation device provided by the embodiments of the present disclosure only needs to train and deploy one neural network to accommodate different input / output dimension requirements, and the method has low training complexity, low storage overhead, and is easy to deploy and continuously evolve online training.

[0189] In the embodiments of the present disclosure, the division into units is merely a schematic and logical functional division, and other division methods may be used in actual implementation. In addition, in each embodiment of the present disclosure, each functional unit may be integrated into a single processing unit, or each unit may exist physically alone, or two or more units may be integrated into a single unit. The integrated units may be implemented in the form of hardware or software functional units.

[0190] The above-mentioned integrated units can be realized in the form of software functional units and stored in a processor-readable storage medium when sold or used as an independent product. Based on this understanding, the technical solution of the present disclosure, its essence, the portion contributing to the prior art, or all or part of the technical means may be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions that cause a computer device (which may be a personal computer, a server, a network device, etc.) or a processor to execute all or part of the steps of the method described in each embodiment of the present disclosure. The storage medium includes various media capable of storing program code, such as a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0191] In some embodiments, there is further provided a computer-readable storage medium having stored thereon a computer program for causing a computer to execute the steps of the neural network operation method according to each of the above method embodiments.

[0192] Specifically, the computer-readable storage medium according to the embodiment of the present disclosure can implement all the method steps implemented by the above-described method embodiments and can achieve the same technical effects, and details of the same parts and beneficial effects of this embodiment as those of the above-described method embodiments will be omitted here.

[0193] The computer-readable storage medium may be any available medium or data storage device that can be accessed by a processor, including, but not limited to, magnetic memory (e.g., flexible disks, hard disks, magnetic tapes, magneto-optical disks (MO), etc.), optical memory (e.g., CDs, DVDs, BDs, HVDs, etc.), semiconductor memory (e.g., ROM, EPROM, EEPROM, non-volatile memory (NAND FLASH), solid-state drives (SSD)), etc.

[0194] Furthermore, the terms "first," "second," and the like in the embodiments of the present disclosure are intended to distinguish between similar objects and are not intended to describe a specific order or chronological order. Terms used in this manner are interchangeable where appropriate, so that the embodiments of the present disclosure can be implemented in an order other than that illustrated or described herein. It should be understood that the objects distinguished by "first" and "second" are generally of the same type, and the number of objects is not limited; for example, the first object may be one or more.

[0195] Furthermore, the term "and / or" in the embodiments of the present disclosure describes a relation between related objects and indicates that three types of relations may exist. For example, A and / or B may indicate three cases: A exists alone, A and B exist simultaneously, and B exists alone. The character " / " generally indicates that the related objects before and after it are in an "or" relation.

[0196] The term "plurality" in the embodiments of the present disclosure means two or more than two, and other quantifiers similar thereto.

[0197] The technical solutions according to the embodiments of the present disclosure are applicable to various systems, particularly 5G systems. For example, applicable systems include a global system of mobile communication (GSM) system, a code division multiple access (CDMA) system, a wideband code division multiple access (WCDMA) system, a general packet radio service (GPRS) system, a long term evolution (LTE) system, an LTE frequency division duplex (FDD) system, an LTE time division duplex (TDD) system, a long term evolution advanced (LTE-A) system, a universal mobile telecommunication system (UMTS), a worldwide interoperability for microwave access (WiMAX) system, and a 5G New Radio (NR) system. Each of these various systems includes a terminal device and a network device. The system may also include a core network portion such as an evolved packet system (EPS), a 5G system (5GS), or the like.

[0198] A terminal device according to an embodiment of the present disclosure may be a device providing voice and / or data connectivity to a user, a handheld device with wireless connectivity, or other processing device connected to a wireless modem. Different systems may refer to terminal devices by different names. For example, in a 5G system, terminal devices may be referred to as user equipment (UE). A wireless terminal device can communicate with one or more core networks (CN) via a radio access network (RAN). The wireless terminal device may be a mobile terminal device, such as a mobile phone (also called a "cellular" phone) or a computer with a mobile terminal device, e.g., a portable, pocket-sized, handheld, computer-integrated, or vehicle-mounted mobile device, which exchanges voice and / or data with the radio access network. Examples of such devices include a personal communication service (PCS) phone, a cordless phone, a session initiated protocol (SIP) phone, a wireless local loop (WLL) station, a personal digital assistant (PDA), and other devices. A wireless terminal device may also be called a system, a subscriber unit, a subscriber station, a mobile station, a mobile, a remote station, an access point, a remote terminal, an access terminal, a user terminal, a user agent, or a user device, and is not limited to these terms in the embodiments of the present disclosure.

[0199] The network equipment according to an embodiment of the present disclosure may be a base station that can include multiple cells serving terminals. Depending on a specific application scenario, the base station may also be called an access point, a device that communicates with wireless terminal devices over one or more sectors over an air interface in an access network, or other names. The network equipment may be used as a router between the wireless terminal devices and the rest of the access network to exchange received air frames and Internet Protocol (IP) packets with each other, where the rest of the access network may include an Internet Protocol (IP) communication network. The network equipment may also coordinate attribute management of the air interface. For example, the network device according to the embodiment of the present disclosure may be a network device (BTS: Base Transceiver Station) in Global System for Mobile communications (GSM) or Code Division Multiple Access (CDMA), a network device (Node B) in Wide-band Code Division Multiple Access (WCDMA (registered trademark)), an evolved network device (eNB or e-Node B: evolutionary Node B) in a Long Term Evolution (LTE) system, a 5G base station (gNB) in a 5G network architecture (next generation system), a Home evolved Node B (HeNB), a relay node, a home base station (femto), a pico base station (pico), or the like, and is not limited to these in the embodiment of the present disclosure.In some network architectures, the network equipment may include a centralized unit (CU) node and a distributed unit (DU) node, and the centralized unit and the distributed unit may be located geographically separated.

[0200] Between the network device and the terminal device, multi-input multi-output (MIMO) transmission can be performed using one or more antennas, and the MIMO transmission may be single user MIMO (SU-MIMO) or multi-user MIMO (MU-MIMO). Depending on the type and number of antenna combinations, the MIMO transmission may be 2D-MIMO, 3D-MIMO, FD-MIMO, or massive-MIMO, and may be diversity transmission, precoding transmission, beam focusing transmission, etc.

[0201] As will be appreciated by those skilled in the art, embodiments of the present disclosure may be provided as a method, a system, or a computer program product. Thus, the present disclosure may employ an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. The present disclosure may also employ the form of a computer program product embodied in one or more computer-usable storage media (including, but not limited to, magnetic disk memory, optical memory, etc.) containing computer-usable program code.

[0202] The present disclosure will be described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present disclosure. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, and combinations of flows and / or blocks in the flowcharts and / or block diagrams, can be implemented by computer-executable instructions. These computer-executable instructions are provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, and the instructions, executed by the processor of the computer or other programmable data processing device, generate an apparatus for implementing the function(s) specified in one or more flows in the flowcharts and / or one or more blocks in the block diagrams.

[0203] These processor-executable instructions may be stored in a processor-readable memory that causes a computer or other programmable data processing device to operate in a particular manner to produce an article of manufacture that includes instruction means, the instruction means implementing a function or functions specified in one or more flows in the flowcharts and / or one or more blocks in the block diagrams.

[0204] These processor-executable instructions may be loaded into a computer or other programmable data processing device and cause the computer or other programmable device to perform a series of operational steps to generate a computer-implemented process, whereby the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in one or more flows in the flowcharts and / or one or more blocks in the block diagrams.

[0205] Of course, those skilled in the art can make various changes and modifications to the present disclosure without departing from the spirit and scope of the present disclosure. Thus, if these changes and modifications of the present disclosure fall within the scope of the claims of the present disclosure and their equivalents, the present disclosure also intends to include these changes and modifications. [Explanation of symbols]

[0206] 1000 Transmitters 1010 processor 1020 memory 1101 Additional Module 1102 Training Module

Claims

1. According to the type of variable dimension, a random mask layer is provided in the first neural network to obtain a second neural network, wherein the random mask layer is for performing a random mask process on a tensor input to the random mask layer; and training said second neural network using sample data.

2. The type of variable dimension is: A type with variable input dimensions; A type with variable output dimensions; A type in which the intermediate dimension is variable, and 2. The method of claim 1, wherein the neural network is operated in a manner similar to that of claim 1.

3. providing a random mask layer in the first neural network according to the type of the variable dimension, If the variable dimension type is a type in which the input dimension is variable, providing a random mask layer before the input layer of the first neural network; or If the variable dimension type is a type in which the output dimension is variable, a random mask layer is provided after the output layer of the first neural network; or When the variable dimension type is a type in which an intermediate dimension is variable, the method includes providing a random mask layer in an intermediate layer of the first neural network.

3. The method of claim 2, wherein the neural network is operated in a manner similar to that of claim 2.

4. Providing a random mask layer in the intermediate layer of the first neural network includes: If only one intermediate dimension is variable, then providing one random mask layer before or after the associated intermediate layer, or When multiple intermediate dimensions are variable, the method includes providing one random mask layer before or after each associated intermediate layer.

4. The method of claim 3, wherein the neural network is operated in a manner similar to that described in claim 3.

5. Training the second neural network using the sample data includes: When the input data dimensions of each sample data are all equal to a first threshold, directly using all sample data to train the second neural network, where the first threshold is the maximum value of the input data dimensions of all sample data; or When at least one first sample data exists, the method includes first performing a reinforcement process on the first sample data, and then training the second neural network using all of the first sample data and all of the second sample data, wherein the first sample data is sample data whose input data dimensions are not equal to a first threshold, the second sample data is sample data whose input data dimensions are equal to the first threshold, and the first threshold is the maximum value of the input data dimensions of all of the sample data.

2. The method of claim 1, wherein the neural network is operated in a manner similar to that of claim 1.

6. Performing a reinforcement process on the first sample data includes: padding the input data of the first sample data with leading zeros; or and padding lower zeros on the input data of the first sample data.

6. A method for operating a neural network according to claim 5.

7. Training the second neural network using the sample data includes: When at least one first sample data exists, the first sample data is first removed, and then all second sample data are used to train the second neural network, wherein the first sample data is sample data whose input data dimension is not equal to a first threshold, the second sample data is sample data whose input data dimension is equal to the first threshold, and the first threshold is the maximum value of the input data dimension of all the sample data.

2. The method of claim 1, wherein the neural network is operated in a manner similar to that of claim 1.

8. Performing random mask processing on a tensor input to the random mask layer includes: determining a tensor input to the random mask layer and a random mask tensor; and performing a random mask process on the tensor input to the random mask layer using the random mask tensor.

2. The method of claim 1, wherein the neural network is operated in a manner similar to that of claim 1.

9. A formula for performing random masking on a tensor input to the random mask layer is as follows: [Equation 1] where: [Equation 2] denotes the tensor output by the random mask layer, [Equation 3] denotes the tensor input to the random mask layer, [Equation 4] denotes the bitwise product operation on tensors, [Equation 5] denotes the random mask tensor, the random mask tensor is a hard masking tensor, or the random mask tensor is a soft masking tensor, or The random mask tensor is a combination of a hard masking tensor and a soft masking tensor.

9. A method for operating a neural network according to claim 8.

10. After training the second neural network using the sample data, The method further includes updating the random mask layer in the second neural network after training to a tensor transform layer, wherein the tensor transform layer is for performing a dimension transformation on a tensor input to the tensor transform layer.

2. The method of claim 1, wherein the neural network is operated in a manner similar to that of claim 1.

11. updating the random mask layer in the trained second neural network to a tensor transform layer; If a random mask layer exists before the input layer of the second neural network after training, updating the random mask layer before the input layer of the second neural network after training to a tensor padding layer, wherein the tensor padding layer is for increasing the dimension of a tensor input to the tensor padding layer up to a first threshold, and the first threshold is the maximum value of the dimension of input data of all sample data; or If a random mask layer exists after the output layer of the second neural network after being trained, updating the random mask layer after the output layer of the second neural network after being trained to a tensor cropping layer, wherein the tensor cropping layer is for reducing the dimension of a tensor input to the tensor cropping layer to a first target value; or If a random mask layer exists in the intermediate layer of the second neural network after training, the random mask layer in the intermediate layer of the second neural network after training is updated to a cascade tensor cropping and tensor padding layer, wherein the cascade tensor cropping and tensor padding layer is configured to first reduce the dimension of a tensor input to the cascade tensor cropping and tensor padding layer to a second target value and then increase it to the original dimension.

11. A method for operating a neural network according to claim 10.

12. Obtaining forecast data; 12. A method for operating a neural network executed by a computing device, comprising inputting the prediction data into a configured target neural network to obtain a prediction result output by the target neural network, wherein the target neural network is a second neural network as recited in any one of claims 1 to 11.

13. an additional module configured to provide a random mask layer to the first neural network according to the type of variable dimension to obtain a second neural network, the random mask layer being for performing a random mask operation on a tensor input to the random mask layer; a training module configured to train the second neural network using sample data.

14. an acquisition module configured to acquire prediction data; and a processing module configured to input the prediction data into a deployed target neural network to obtain a prediction result output by the target neural network, wherein the target neural network is the second neural network of any one of claims 1 to 11.

Citation Information

Patent Citations

  • Neural network structured pruning method, pruning device and electronic equipment

    CN109948794A

  • Named entity detection method and device, electronic equipment and readable storage medium

    CN110399616A

  • Visually-aware encoding for character

    JP2021089714A

  • Device, method, and program for natural language processing

    WO2019167296A1