Quantification method, device, equipment and readable storage medium
By quantifying the parameters of the AI module and using a variety of quantification strategies and configuration parameters, the problem of increased complexity of the AI module is solved and system performance is improved.
Patent Information
- Application Number
- CN202110240917.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-03-04
- Publication Date
- 2024-09-06
- Estimated Expiration
- 2041-03-04
AI Technical Summary
The existing technology lacks a quantitative process for artificial intelligence (AI) modules, which leads to an increase in the complexity of the AI module and affects system performance.
By determining the quantization strategy, quantization level and quantization configuration parameters, the parameters of the AI module are quantified, using direct quantization method, uniform quantization method, non-uniform quantization method, weight sharing quantization method, group quantization method, transform domain quantization method and Methods such as parameter coding and quantization methods reduce the complexity of the AI module.
It effectively reduces the complexity of the AI module, improves system performance, improves the parameter accuracy of the AI module and the overall performance of the system.
Smart Images

Figure CN115037608B
Abstract
Description
Technical Field
[0001] The present application belongs to the field of communication technology, and specifically relates to a method, device, equipment and readable storage medium for quantifying an artificial intelligence (AI) module. Background Art
[0002] Artificial intelligence has been widely used in various fields. In communication networks, artificial intelligence can be realized through AI modules. However, there is currently no process to quantify AI modules, which increases the complexity of AI modules. Summary of the invention
[0003] The embodiments of the present application provide a quantization method, apparatus, device and readable storage medium to solve the problem of how to reduce the complexity of the AI module.
[0004] In a first aspect, a quantization method is provided, which is performed by a first communication device and includes:
[0005] Determine a quantization strategy, a quantization level and / or a quantization configuration parameter of a first module of the first communication device, wherein the first module is an artificial intelligence (AI) module;
[0006] The parameters of the first module are quantized according to the quantization strategy, quantization level and / or quantization configuration parameters.
[0007] In a second aspect, a quantization apparatus is provided, which is applied to a first communication device, including:
[0008] A first determination module, configured to determine a quantization strategy, a quantization level and / or a quantization configuration parameter of a first module of the first communication device, wherein the first module is an AI module;
[0009] The quantization module is used to quantize the parameters of the first module according to the quantization strategy, quantization level and / or quantization configuration parameters.
[0010] According to a third aspect, a communication device is provided, comprising: a processor, a memory, and a program stored in the memory and executable on the processor, wherein when the program is executed by the processor, the steps of the method described in the first aspect are implemented.
[0011] In a fourth aspect, a readable storage medium is provided, on which a program or instruction is stored. When the program or instruction is executed by a processor, the steps of the method described in the first aspect are implemented.
[0012] According to a fifth aspect, a program product is provided. The program product is stored in a non-volatile storage medium and is executed by at least one processor to implement the steps of the method described in the first aspect.
[0013] In a sixth aspect, a chip is provided, comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the method described in the first aspect.
[0014] In the embodiments of the present application, the AI module is quantized through quantization strategy, quantization level and / or quantization configuration parameters, so as to reduce the complexity of the AI module and improve the system performance. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] Figure 1 is a schematic diagram of a wireless communication system to which the embodiments of the present application can be applied;
[0016] Figure 2 is a flow chart of a quantification method provided in an embodiment of the present application;
[0017] Figure 3 is a schematic diagram of a quantification device provided in an embodiment of the present application;
[0018] Figure 4 A schematic diagram of a terminal according to an embodiment of the present application;
[0019] Figure 5 A schematic diagram of a network side device according to an embodiment of the present application. DETAILED DESCRIPTION
[0020] In order to facilitate understanding of the embodiments of the present application, the following technical points are first introduced below: artificial intelligence.
[0021] Artificial intelligence has been widely used in various fields. There are many ways to implement AI modules for artificial intelligence, such as neural networks, decision trees, support vector machines, Bayesian classifiers, etc.
[0022] Taking neural networks as an example, the parameters of neural networks are optimized through optimization algorithms. Optimization algorithms are a type of algorithm that can minimize or maximize an objective function (sometimes called a loss function). The objective function is often a mathematical combination of model parameters and data. For example, given data X and its corresponding label Y, a neural network model f(.) is constructed. With the model, the predicted output f(x) can be obtained based on the input x, and the difference between the predicted value and the true value (f(x)-Y) can be calculated. This is the loss function. The purpose is to find a suitable W,b to minimize the value of the above loss function. The smaller the loss value, the closer the model is to the actual situation.
[0023] At present, the common optimization algorithms are basically based on the error back propagation (BP) algorithm. The basic idea of the BP algorithm is that the learning process consists of two processes: the forward propagation of the signal and the back propagation of the error. During the forward propagation, the input sample is transmitted from the input layer, processed by each hidden layer layer by layer, and then transmitted to the output layer. If the actual output of the output layer does not match the expected output, it will enter the error back propagation stage. Error back propagation is to propagate the output error layer by layer through the hidden layer to the input layer in some form, and distribute the error to all units in each layer, so as to obtain the error signal of each layer unit, and this error signal is used as the basis for correcting the weights of each unit. This process of adjusting the weights of each layer of the signal forward propagation and error back propagation is repeated. The process of continuous adjustment of weights is the learning and training process of the network. This process continues until the error of the network output is reduced to an acceptable level, or until the pre-set number of learning times is reached.
[0024] Common optimization algorithms include Gradient Descent, Stochastic Gradient Descent (SGD), mini-batch gradient descent, Momentum, Nesterov (the name of the inventor, specifically stochastic gradient descent with momentum), Adaptive Gradient Descent (Adagrad), Adaptive delta (Adadelta), Root Mean Square prop (RMSprop), Adaptive Momentum Estimation (Adam), etc.
[0025] When the error is back-propagated, these optimization algorithms calculate the derivative / partial derivative of the current neuron based on the error / loss obtained by the loss function, add the influence of the learning rate, the previous gradient / derivative / partial derivative, etc., get the gradient, and pass the gradient to the previous layer.
[0026] The following will be combined with the drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0027] The terms "first", "second", etc. in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specified order or sequence. It should be understood that the terms used in this way are interchangeable where appropriate, so that the embodiments of the present application can be implemented in an order other than those illustrated or described herein, and 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 can be one or more. In addition, "and" in the specification and claims represents at least one of the connected objects, and the character " / " generally represents that the objects associated with each other are in an "or" relationship.
[0028] It is worth noting that the technology described in the embodiments of the present application is not limited to the Long Term Evolution (LTE) / LTE-Advanced (LTE-A) system, but can also be used in other wireless communication systems, such as Code Division Multiple Access (CDMA), Time Division Multiple Access (TDMA), Frequency Division Multiple Access (FDMA), Orthogonal Frequency Division Multiple Access (OFDMA), Single-carrier Frequency-Division Multiple Access (SC-FDMA) and other systems. The terms "system" and "network" in the embodiments of the present application are often used interchangeably, and the described technology can be used for the systems and radio technologies mentioned above as well as for other systems and radio technologies. However, the following description describes a New Radio (NR) system for illustrative purposes, and NR terms are used in most of the following descriptions. These technologies can also be applied to applications other than NR system applications, such as the 6th generation (6 th Generation, 6G) communication system.
[0029] Figure 1A block diagram of a wireless communication system applicable to an embodiment of the present application is shown. The wireless communication system includes a terminal 11 and a network side device 12. Among them, the terminal 11 can also be called a terminal device or a user terminal (User Equipment, UE), and the terminal 11 can be a mobile phone, a tablet computer (Tablet Personal Computer), a laptop computer (Laptop Computer) or a notebook computer, a personal digital assistant (Personal Digital Assistant, PDA), a handheld computer, a netbook, an ultra-mobile personal computer (ultra-mobile personal computer, UMPC), a mobile Internet device (Mobile Internet Device, MID), a wearable device (Wearable Device) or a vehicle-mounted device (VUE), a pedestrian terminal (PUE) and other terminal side devices, and the wearable device includes: a bracelet, a headset, glasses, etc. It should be noted that the specific type of the terminal 11 is not limited in the embodiment of the present application. The network side device 12 can be a base station or a core network side device, wherein the base station can be called a node B, an evolved node B, an access point, a base transceiver station (Base Transceiver Station, BTS), a radio base station, a radio transceiver, a basic service set (Basic Service Set, BSS), an extended service set (Extended Service Set, ESS), a B node, an evolved B node (eNB), a home B node, a home evolved B node, a WLAN access point, a WiFi node, a transmitting and receiving point (Transmitting Receiving Point, TRP) or some other suitable term in the field. As long as the same technical effect is achieved, the base station is not limited to the specified technical vocabulary. It should be noted that in the embodiment of the present application, only the base station in the NR system is taken as an example, but the specific type of the base station is not limited.
[0030] In the following, in combination with the accompanying drawings, a quantization method, apparatus, device and readable storage medium provided by the embodiments of the present application are described in detail through some embodiments and their application scenarios.
[0031] See also Figure 2 The embodiment of the present application provides a quantization method, and the execution subject of the method may be a first communication device, including:
[0032] Step 201: Determine a quantization strategy, a quantization level and / or a quantization configuration parameter of a first module of the first communication device, where the first module is an AI module;
[0033] Step 202: quantize the parameters of the first module according to the quantization strategy, quantization level and / or quantization configuration parameters.
[0034] The above quantization strategy can also be called a quantization method, which refers to the method used to quantize the parameters of the AI module.
[0035] The above quantization level can represent the accuracy of the quantization of the parameters of the AI module. For example, the higher the quantization level, the more accurate the parameters of the AI module are and the closer they are to the original parameters; the lower the quantization level, the coarser the parameters of the AI module are and the further away they are from the original parameters. For example, the quantization level is divided by bits. A quantization level of X bits represents that the parameters of the AI module are quantized to X bits. Then, when the value of X is larger, the number of bits occupied by the parameters of the AI module is more, where X is a positive integer. The single-precision type (float type) commonly used in computers currently occupies 32 bits, and the double-precision type (double type) occupies 64 bits, which is actually a very high-precision quantization.
[0036] The above-mentioned quantization configuration parameters are used to indicate the configuration for quantizing the AI module. For example, the quantization configuration parameters include one or more of the following: what quantization strategy the AI module adopts and how the details of the quantization strategy are configured, whether all parameters of the AI module adopt a unified quantization level, whether the quantization level of the multiplicative coefficient of the AI module is the same as the quantization level of the additive coefficient, what the quantization level of the AI module is, how many bits are used for parameter quantization of the AI module, and the like.
[0037] For example, if the quantization level is configured to 8 bits and the quantization strategy is direct quantization, all parameters of the AI module are quantized from floating point numbers to 8 bits. Assuming that the AI module is a neural network, the multiplicative coefficients and additive coefficients of all neurons are quantized to 8 bits.
[0038] In one embodiment of the present application, the quantification strategy may include one or more of the following:
[0039] (1) Direct quantification method;
[0040] The above-mentioned direct quantization method refers to quantizing various parameters of the AI module directly according to the quantization level and / or quantization configuration parameters.
[0041] (2) Uniform quantization method;
[0042] The above-mentioned uniform quantization method refers to a quantization method that divides the parameters of the AI module (such as the value range of the input parameters) into equal intervals.
[0043] (3) Non-uniform quantization method;
[0044] The non-uniform quantization method is a quantization method in which the quantization intervals within the dynamic range of the parameters (eg, input parameters) of the AI module are unequal.
[0045] For example, the quantization interval / quantization level of different input intervals is determined according to the probability density, probability distribution, cumulative probability distribution, etc. For example, for an interval with a small input value, the quantization interval is also small; conversely, for an interval with a large input value, the quantization interval is large.
[0046] (4) Weight sharing quantization method;
[0047] (5) Group quantification method;
[0048] In the weight sharing quantization method and the group quantization method, the parameters of the AI module can be divided into multiple sets, and the elements in each set share a value.
[0049] (6) Transform domain quantization method;
[0050] The transform domain quantization method refers to transforming the parameters of the AI module (such as weights, biases, convolution kernels, etc.) to another domain, such as the frequency domain, S domain, Z domain, etc., performing quantization operations in another domain, and then transforming them back.
[0051] Exemplarily, the network convolution kernel is first transformed into the frequency domain, and then random hashing is performed in the frequency domain, and a lower number of hash bits is used for the less important high-frequency parts to achieve higher compression.
[0052] (7) Parameter coding quantization method;
[0053] The parameter coding quantization method refers to encoding the parameters of the AI module. The encoding methods include but are not limited to: lossy coding, lossless coding (such as Huffman coding), etc.
[0054] (8) Product Quantization method.
[0055] The product quantization method refers to dividing the network weights into multiple subspaces and performing quantization operations on each subspace, such as weight sharing quantization on each subspace.
[0056] Optionally, the above-mentioned multiple quantization strategies can be cascaded or combined. Exemplarily, the quantization strategies include: uniform quantization method, weight sharing quantization method and parameter coding quantization method. The network is first uniformly quantized by the uniform quantization method, and then the uniformly quantized weights are quantized again using the weight sharing quantization method, and then the weights are quantized according to the parameter coding quantization method.
[0057] In one implementation of the present application, the step of quantizing the parameters of the first module includes:
[0058] During the network training phase, the parameters of the first module are quantized according to the quantization strategy, quantization level and / or quantization configuration parameters.
[0059] For example, use the ordinary gradient calculation method to get the gradient corresponding to each weight. According to the previous weight grouping, the weight gradient values of the same group are accumulated to get the update amount of the cluster center in this round of network training. The cluster center value minus the product of the update amount and the learning rate will get the cluster center after this round of training.
[0060] In one implementation of the present application, the parameter division method in the group quantization method includes:
[0061] (1) Random division method;
[0062] In the random partitioning method, the parameters of the AI modules may be grouped in a random manner.
[0063] (2) determining the set identifier of the parameter according to the identifier of the parameter;
[0064] The above method (2) can also be called direct addressing. For example, sort the parameters of the AI module, determine the ID of each parameter, and then input the parameter ID into a linear function or an N-order function or other common function to obtain a new value X, and obtain the set ID of the network parameter through X. Among them, the linear function includes a function whose output is equal to the input.
[0065] In one implementation of the present application, determining the set identifier of the parameter according to the identifier of the parameter includes:
[0066] Obtaining a first value according to the identifier of the parameter;
[0067] Determine, according to the first value, a set identifier to which the parameter belongs;
[0068] Wherein, determining the set identifier to which the parameter belongs according to the first value includes one or more of the following:
[0069] (a) rounding the first value to obtain a set identifier to which the parameter belongs;
[0070] (b) taking at least one bit from the first value and combining them into a set identifier to which the parameter belongs;
[0071] (c) dividing the first value by a preset value, and using the remainder obtained as the set identifier to which the parameter belongs.
[0072] Optionally, the identification parameter of the parameter is input into a linear function or other common mathematical functions to obtain a first value (X). Common mathematical functions include combinations of various common mathematical operations such as addition and subtraction of multipliers, Nth power, Nth square root, logarithm, derivation, partial derivative, etc. N is an arbitrary number, for example, N can be a positive number or a negative number or 0, a real number or a complex number.
[0073] Optionally, the method of obtaining the set ID of the network parameter through X includes:
[0074] a) X is rounded up to the nearest integer, which is the set ID. Rounding up includes rounding up, rounding down, or rounding off. For example, if X is 3.23, the set ID can be 3 or 4, where 3 represents rounding down or rounding off, and 4 represents rounding up.
[0075] b) Take at least one digit of X and combine them into a set ID.
[0076] For example, if X is 3215217, the second and fourth digits from the front are taken, and the set ID is 25, or the first and third digits from the back are taken, and the set ID is 72 or 27.
[0077] For another example, if X is 872351.1237, the first and second decimal places are taken, and the set ID is 12 or 21; or the first and second decimal places are taken, and the set ID is 51 or 15; or the second decimal place and the third decimal place are taken, and the set ID is 53 or 35.
[0078] For example:
[0079] (i) Take at least two digits, and the values on these digits are arranged according to a certain pattern to form a set ID.
[0080] For example, from the beginning to the end, or from the end to the beginning, or from the largest to the smallest, or from the smallest to the largest. For example, if X is 67429815, and the first, third, and fifth digits are counted from the beginning to the end, the values of these digits are 5, 8, and 2. If the digits are counted from the beginning to the end, the set ID is 285; if the digits are counted from the end to the beginning, the set ID is 582; if the values are counted from the largest to the smallest, the set ID is 852; if the values are counted from the smallest to the largest, the set ID is 258.
[0081] (ii) If a bit is missing, the value of that bit is 0, or other default value.
[0082] For example, if X is 52, and we count from the first, third, and fifth digits, the corresponding values are 5, 0, and 0.
[0083] c) Divide X by a number and take the remainder.
[0084] For example, if X is 752 and a certain number is 11, then the set ID is 4=752mod(11).
[0085] d) According to X, randomly divide the set ID.
[0086] (3) Clustering division method.
[0087] In the clustering method, the parameters of the AI module are grouped according to the cluster center.
[0088] For example, if the data is divided into K groups in advance, K objects are randomly selected as the initial cluster centers, and then the distance between each object and each seed cluster center is calculated, and each object is assigned to the cluster center closest to it. The cluster centers and the objects assigned to them represent a cluster. Each time a sample is assigned, the cluster center of the cluster is recalculated based on the existing objects in the cluster. This process will be repeated until a certain termination condition is met. The termination condition can be that no (or a minimum number of) objects are reassigned to different clusters, no (or a minimum number of) cluster centers change again, and the sum of squared errors is locally minimized.
[0089] In one implementation of the present application, the quantization strategy and / or quantization configuration parameter is determined according to one or more of the following:
[0090] (1) Terminal reporting;
[0091] That is, the network side can obtain the quantization strategy and / or quantization configuration parameters according to the reporting method of the terminal.
[0092] (2) Terminal capabilities;
[0093] That is, the quantization strategy and / or quantization configuration parameter may be used as the capability of the terminal.
[0094] (3) Network side configuration.
[0095] That is, the terminal side can obtain the quantization strategy and / or quantization configuration parameters according to the configuration of the network side.
[0096] For example, the network side configures, activates or triggers through Radio Resource Control (RRC), Media Access Control Control Element (MAC CE) or Downlink Control Information (DCI).
[0097] In one implementation of the present application, the quantization strategy is a direct quantization method, and the step of quantizing the parameters of the first module according to the quantization strategy, the quantization level and / or the quantization configuration parameter includes:
[0098] The parameters of the first module are quantized according to the quantization level and / or quantization configuration parameters of the first module.
[0099] In one embodiment of the present application, the quantization level is determined according to one or more of the following:
[0100] (1) information related to the parameters of the first module;
[0101] Optionally, the information related to the parameters of the first module includes: the size of the parameters;
[0102] For example, the larger the parameter is, the higher the quantization level is; or, the larger the parameter is, the lower the quantization level is.
[0103] For another example, the smaller the parameter is, the lower the quantization level is; or, the smaller the parameter is, the higher the quantization level is.
[0104] That is, different quantization levels can be determined according to the size of the AI module parameters. For example, the larger the AI module parameters, the finer the quantization; the smaller the AI module parameters, the coarser the quantization. Alternatively, the larger the AI module parameters, the coarser the quantization; the smaller the AI module parameters, the finer the quantization.
[0105] (2) Terminal reporting;
[0106] That is, the network side can obtain the quantization level according to the reporting method of the terminal.
[0107] (3) Terminal capabilities;
[0108] That is, the quantization level can be used as the capability of the terminal.
[0109] (4) Network side configuration;
[0110] (5) Output accuracy requirements of the first module;
[0111] For example, the higher the output accuracy requirement of the AI module, the higher the quantization level.
[0112] (6) Performance requirements of the first module.
[0113] For example, the performance requirements of AI modules are divided into multiple levels, and different levels of performance requirements correspond to different quantitative levels.
[0114] In one embodiment of the present application, the higher the quantization level, the more accurate the quantization accuracy of the parameters of the first module is, or the lower the quantization level, the coarser the quantization accuracy of the parameters of the first module is.
[0115] In one embodiment of the present application, the type of the first module is a neural network;
[0116] wherein the quantization levels of neurons in different layers of the neural network are the same;
[0117] and / or,
[0118] The neurons in the same layer of the neural network have the same quantization level;
[0119] and / or,
[0120] The quantization level of the multiplicative coefficients in the neural network is the same as the quantization level of the additive coefficients.
[0121] In one embodiment of the present application, the type of the first module is a neural network;
[0122] Wherein, the quantization levels of neurons in different layers of the neural network are different;
[0123] and / or,
[0124] The quantization levels of neurons in the same layer of the neural network are different;
[0125] and / or,
[0126] The quantization level of the multiplicative coefficients in the neural network is different from the quantization level of the additive coefficients.
[0127] In one embodiment of the present application, the type of the first module is a recurrent neural network (RNN);
[0128] The quantization level of the parameters of the memory unit in the recurrent neural network (e.g., multiplicative coefficients, additive coefficients) is the same as the quantization level of the parameters of the non-memory neurons (including neurons and non-neuronal units) in the recurrent neural network, or the same as the quantization level of the non-memory parameters of the neurons in the recurrent neural network.
[0129] or,
[0130] The quantization level of the parameters of the memory unit in the recurrent neural network is different from the quantization level of the parameters of the non-memory neurons in the recurrent neural network, or is different from the quantization level of the non-memory parameters of the neurons in the recurrent neural network.
[0131] In one embodiment of the present application, the type of the first module is a convolutional neural network (CNN);
[0132] in,
[0133] The quantization level of the parameters of the convolution kernel of the convolution neural network is the same as or different from the quantization level of the parameters of the non-convolution kernel in the convolution neural network,
[0134] or,
[0135] The quantization level of the pooling parameters (multiplicative coefficients, additive coefficients) of the convolutional neural network is the same as or different from the quantization level of the non-pooling parameters in the convolutional neural network.
[0136] In one embodiment of the present application, the input or output of the first module is first information;
[0137] The first information includes one or more of the following:
[0138] (1) Reference signal;
[0139] The reference signal is used for signal processing, including signal detection, filtering, equalization, etc., such as demodulation reference signal (DMRS), sounding reference signal (SRS), synchronization signal block (SSB), tracking reference signal (TRS), phase tracking reference signal (PTRS), channel state information reference signal (CSI-RS), etc.
[0140] (2) The signal carried by the channel;
[0141] The channel may include one or more of the following: physical downlink control channel (PDCCH), physical downlink shared channel (PDSCH), physical uplink control channel (PUCCH), physical uplink shared channel (PUSCH), physical random access channel (PRACH), physical broadcast channel (PBCH), etc.
[0142] (3) Channel state information;
[0143] Optionally, the channel state information includes channel state information feedback information and / or channel state information of uplink and downlink partial reciprocity in a frequency division duplex (Frequency Division Duplex, FDD) system.
[0144] Among them, the channel state information feedback information includes one or more of the following: channel-related information, channel matrix-related information, channel characteristic information, channel matrix characteristic information, precoding matrix indicator (Precoding matrix indicator, PMI), rank indicator (Rank indicator, RI), CSI-RS resource indicator (CSI-RS Resource Indicator, CRI), channel quality indicator (CQI), layer indication (Layer Indicator, LI), etc.
[0145] For the FDD system, based on partial reciprocity, the base station obtains angle and delay information based on the uplink channel, and can notify the UE of the angle and delay information through CSI-RS precoding or direct indication. The UE reports according to the indication of the base station or selects and reports within the indication range of the base station, thereby reducing the UE's calculation amount and the CSI reporting overhead.
[0146] (4) beam information;
[0147] Beam information includes one or more of the following: beam quality, beam indication information (reference signal ID), beam failure indication information, and new beam indication information in beam failure recovery. It is used for beam management, including beam measurement, beam reporting, beam prediction, beam failure detection, beam failure recovery, and new beam indication in beam failure recovery.
[0148] (5) Channel prediction information;
[0149] Channel prediction information includes: channel state information prediction and beam prediction.
[0150] (6) Interference information;
[0151] The interference information includes one or more of the following: intra-cell interference information, inter-cell interference information, out-of-band interference information, intermodulation interference information, etc.
[0152] (7) Positioning information (or trajectory information);
[0153] The specific position (including horizontal position and / or vertical position) or possible future trajectory of the UE, or information to assist position estimation or trajectory estimation is estimated through a reference signal (such as a sounding reference signal (SRS)).
[0154] (8) Prediction information of high-level services and / or parameters;
[0155] (9) Management information of high-level services and / or parameters;
[0156] For example, the prediction information or management information may include throughput, required packet size, service requirements, mobile speed, and / or noise information.
[0157] (10) Control signaling.
[0158] For example, related signaling for power control and related signaling for beam management.
[0159] In one implementation of the present application, when the output of the first module is first information, the method further includes:
[0160] The first information is sent to a second communication device, or the first information is sent to a second module of the first communication device.
[0161] Among them, the first information includes the following: the first communication device is a terminal, the second communication device is a network side device, or the first communication device is a network side device and the second communication device is a terminal; or the first communication device is a first terminal and the second communication device is a second terminal; or the first communication device is a first network side device and the second communication device is a second network side device.
[0162] In the embodiments of the present application, the AI module is quantized through quantization strategy, quantization level and / or quantization configuration parameters, so as to reduce the complexity of the AI module and improve the system performance.
[0163] See also Figure 3 , an embodiment of the present application provides a quantization device, which is applied to a first communication device, and the device 300 includes:
[0164] A first determination module 301, configured to determine a quantization strategy, a quantization level and / or a quantization configuration parameter of a first module of the first communication device, wherein the first module is an AI module;
[0165] The quantization module 302 is used to quantize the parameters of the first module according to the quantization strategy, quantization level and / or quantization configuration parameters.
[0166] In one embodiment of the present application, the quantification strategy includes one or more of the following:
[0167] (1) Direct quantification method;
[0168] (2) Uniform quantization method;
[0169] (3) Non-uniform quantization method;
[0170] (4) Weight sharing quantization method;
[0171] (5) Group quantification method;
[0172] (6) Transform domain quantization method;
[0173] (7) Parameter coding quantization method;
[0174] (8) Product quantization method.
[0175] In one embodiment of the present application, the quantization strategy includes: uniform quantization method, weight sharing quantization method and parameter coding quantization method, wherein the network is uniformly quantized by the uniform quantization method, and then the uniformly quantized weights are quantized again using the weight sharing quantization method, and then the weights are subjected to the parameter coding quantization method.
[0176] In one implementation of the present application, the quantization module 302 is further used to: during the network training phase, perform quantization processing on the parameters of the first module according to the quantization strategy, quantization level and / or quantization configuration parameters.
[0177] In one implementation of the present application, the parameter division method in the group quantization method includes:
[0178] (1) Random division method;
[0179] (2) determining the set identifier of the parameter according to the identifier of the parameter;
[0180] (3) Clustering method.
[0181] In one implementation of the present application, determining the set identifier of the parameter according to the identifier of the parameter includes:
[0182] Obtaining a first value according to the identifier of the parameter;
[0183] Determine, according to the first value, a set identifier to which the parameter belongs;
[0184] Wherein, determining the set identifier to which the parameter belongs according to the first value includes one or more of the following:
[0185] (1) rounding the first value to obtain a set identifier to which the parameter belongs;
[0186] (2) taking at least one bit from the first value and combining them into a set identifier to which the parameter belongs;
[0187] (3) Divide the first value by a preset value, and use the remainder obtained as the set identifier of the parameter.
[0188] In one implementation of the present application, the quantization strategy and / or quantization configuration parameter is determined according to one or more of the following:
[0189] (1) Terminal reporting;
[0190] (2) Terminal capabilities;
[0191] (3) Network side configuration.
[0192] In one implementation of the present application, the quantization strategy is a direct quantization method, and the quantization module 302 is further used to: perform quantization processing on the parameters of the first module according to the quantization level and / or quantization configuration parameters of the first module.
[0193] In one embodiment of the present application, the quantization level is determined according to one or more of the following:
[0194] (1) information related to the parameters of the first module;
[0195] (2) Terminal reporting;
[0196] (3) Terminal capabilities;
[0197] (4) Network side configuration;
[0198] (5) Output accuracy requirements of the first module;
[0199] (6) Performance requirements of the first module.
[0200] In one embodiment of the present application, the relevant information of the parameters of the first module includes: the size of the parameter; wherein, the larger the parameter is, the higher the quantization level is, and the smaller the parameter is, the lower the quantization level is; or, the larger the parameter is, the lower the quantization level is, and the smaller the parameter is, the higher the quantization level is.
[0201] In one embodiment of the present application, the higher the quantization level, the more accurate the quantization accuracy of the parameters of the first module is, or the lower the quantization level, the coarser the quantization accuracy of the parameters of the first module is.
[0202] In one embodiment of the present application, the type of the first module is a neural network;
[0203] wherein the quantization levels of neurons in different layers of the neural network are the same;
[0204] and / or,
[0205] The neurons in the same layer of the neural network have the same quantization level;
[0206] and / or,
[0207] The quantization level of the multiplicative coefficients in the neural network is the same as the quantization level of the additive coefficients.
[0208] In one embodiment of the present application, the type of the first module is a neural network;
[0209] Wherein, the quantization levels of neurons in different layers of the neural network are different;
[0210] and / or,
[0211] The quantization levels of neurons in the same layer of the neural network are different;
[0212] and / or,
[0213] The quantization level of the multiplicative coefficients in the neural network is different from the quantization level of the additive coefficients.
[0214] In one embodiment of the present application, the type of the first module is a recurrent neural network;
[0215] The quantization level of the parameters of the memory unit in the recurrent neural network is the same as the quantization level of the parameters of the non-memory neurons in the recurrent neural network, or the same as the quantization level of the non-memory parameters of the neurons of the recurrent neural network.
[0216] or,
[0217] The quantization level of the parameters of the memory unit in the recurrent neural network is different from the quantization level of the parameters of the non-memory neurons in the recurrent neural network, or is different from the quantization level of the non-memory parameters of the neurons in the recurrent neural network.
[0218] In one embodiment of the present application, the type of the first module is a convolutional neural network;
[0219] in,
[0220] The quantization level of the parameters of the convolution kernel of the convolution neural network is the same as or different from the quantization level of the parameters of the non-convolution kernel in the convolution neural network,
[0221] or,
[0222] The quantization level of the pooled parameters of the convolutional neural network is the same as or different from the quantization level of the non-pooled parameters in the convolutional neural network.
[0223] In one embodiment of the present application, the input or output of the first module is first information;
[0224] The first information includes one or more of the following:
[0225] (1) Reference signal;
[0226] (2) The signal carried by the channel;
[0227] (3) Channel state information;
[0228] (4) beam information;
[0229] (5) Channel prediction information;
[0230] (6) Interference information;
[0231] (7) Positioning information;
[0232] (8) Prediction information of high-level services and / or parameters;
[0233] (9) Management information of high-level services and / or parameters;
[0234] (10) Control signaling.
[0235] In one implementation of the present application, when the output of the first module is the first information, the device further includes:
[0236] A sending module is used to send the first information to a second communication device, or to send the first information to a second module of the first communication device.
[0237] In one embodiment of the present application, the first communication device is a terminal and the second communication device is a network side device, or the first communication device is a network side device and the second communication device is a terminal; or the first communication device is a first terminal and the second communication device is a second terminal; or the first communication device is a first network side device and the second communication device is a second network side device.
[0238] The device provided in the embodiment of the present application can achieve Figure 2 The various processes implemented by the method embodiment shown achieve the same technical effect and will not be described again here to avoid repetition.
[0239] Figure 4 To implement a hardware structure diagram of a terminal in an embodiment of the present application, the terminal 400 includes but is not limited to: a radio frequency unit 401, a network module 402, an audio output unit 403, an input unit 404, a sensor 405, a display unit 406, a user input unit 407, an interface unit 408, a memory 409, and a processor 410 and other components.
[0240] Those skilled in the art will appreciate that the terminal 400 may also include a power source (such as a battery) for supplying power to various components, and the power source may be logically connected to the processor 410 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Figure 4 The terminal structure shown in the figure does not constitute a limitation on the terminal. The terminal may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.
[0241] It should be understood that in the embodiment of the present application, the input unit 404 may include a graphics processor (Graphics Processing Unit, GPU) 4041 and a microphone 4042, and the graphics processor 4041 processes the image data of the static picture or video obtained by the image capture device (such as a camera) in the video capture mode or the image capture mode. The display unit 406 may include a display panel 4061, and the display panel 4061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 407 includes a touch panel 4071 and other input devices 4072. The touch panel 4071 is also called a touch screen. The touch panel 4071 may include two parts: a touch detection device and a touch controller. Other input devices 4072 may include, but are not limited to, a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, and a joystick, which will not be repeated here.
[0242] In the embodiment of the present application, the radio frequency unit 401 receives downlink data from the network side device and sends it to the processor 410 for processing; in addition, the uplink data is sent to the network side device. Generally, the radio frequency unit 401 includes but is not limited to an antenna, at least one amplifier, a transceiver, a coupler, a low noise amplifier, a duplexer, etc.
[0243] The memory 409 can be used to store software programs or instructions and various data. The memory 409 can mainly include a program or instruction storage area and a data storage area, wherein the program or instruction storage area can store an operating system, an application program or instruction required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory 409 can include a high-speed random access memory, and can also include a non-volatile memory, wherein the non-volatile memory can be a read-only memory (Read-Only Memory, ROM), a programmable read-only memory (Programmable ROM, PROM), an erasable programmable read-only memory (Erasable PROM, EPROM), an electrically erasable programmable read-only memory (Electrically EPROM, EEPROM) or a flash memory. For example, at least one disk storage device, a flash memory device, or other non-volatile solid-state storage devices.
[0244] The processor 410 may include one or more processing units; optionally, the processor 410 may integrate an application processor and a modem processor, wherein the application processor mainly processes an operating system, a user interface, and application programs or instructions, etc., and the modem processor mainly processes wireless communications, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor 410.
[0245] The terminal provided in the embodiment of the present application can achieve Figure 2 The various processes implemented by the method embodiment shown achieve the same technical effect and will not be described again here to avoid repetition.
[0246] The present application embodiment also provides a network side device. Figure 5 As shown, the network side device 500 includes: an antenna 501, a radio frequency device 502, and a baseband device 503. The antenna 501 is connected to the radio frequency device 502. In the uplink direction, the radio frequency device 502 receives information through the antenna 501 and sends the received information to the baseband device 503 for processing. In the downlink direction, the baseband device 503 processes the information to be sent and sends it to the radio frequency device 502. The radio frequency device 502 processes the received information and sends it out through the antenna 501.
[0247] The frequency band processing device may be located in the baseband device 503 . The method performed by the network-side device in the above embodiment may be implemented in the baseband device 503 . The baseband device 503 includes a processor 504 and a memory 505 .
[0248] The baseband device 503 may include, for example, at least one baseband board on which a plurality of chips are arranged. Figure 5 As shown, one of the chips is, for example, a processor 504, which is connected to a memory 505 to call a program in the memory 505 to execute the network device operations shown in the above method embodiment.
[0249] The baseband device 503 may further include a network interface 506 for exchanging information with the radio frequency device 502 . The interface may be, for example, a common public radio interface (CPRI).
[0250] Specifically, the network side device of the embodiment of the present application further includes: instructions or programs stored in the memory 505 and executable on the processor 504, and the processor 504 calls the instructions or programs in the memory 505 to execute. Figure 3 The methods executed by the modules shown achieve the same technical effects, and therefore will not be described here in detail to avoid repetition.
[0251] The embodiment of the present application also provides a program product, which is stored in a non-volatile storage medium and is executed by at least one processor to implement the following Figure 2 The steps of the processing method.
[0252] The embodiment of the present application also provides a readable storage medium on which a program or instruction is stored. When the program or instruction is executed by a processor, the above Figure 2The various processes of the method embodiment shown can achieve the same technical effect, and will not be described again here to avoid repetition.
[0253] The processor is the processor in the terminal described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0254] The present application also provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a network side device program or instruction to implement the above Figure 2 The various processes of the method embodiment shown can achieve the same technical effect, and will not be described again here to avoid repetition.
[0255] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.
[0256] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.
[0257] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for enabling a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.
[0258] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
Claims
1. A quantification method, characterized in that: The method is executed by a first communication device and includes: Determine a quantitative configuration parameter of a first module of the first communication device, where the first module is an artificial intelligence (AI) module; According to the quantization configuration parameters, quantizing the parameters of the first module; The quantization configuration parameters are determined according to one or more of the following: terminal reporting; terminal capabilities; network side configuration; the quantization configuration parameters include one or more of the following: whether all parameters of the AI module adopt a unified quantization level, whether the quantization level of the multiplicative coefficient of the AI module is the same as the quantization level of the additive coefficient, and the quantization level of the AI module; The quantization level is determined according to one or more of the following: relevant information of the parameters of the first module; terminal report; terminal capability; network side configuration; output accuracy requirements of the first module; performance requirements of the first module; The input or output of the first module is first information; wherein the first information includes one or more of the following: reference signal; signal carried by the channel; channel state information; beam information; channel prediction information; interference information; positioning information; prediction information of high-level services and / or parameters; management information of high-level services and / or parameters; and control signaling.
2. The method according to claim 1, characterized in that The quantization configuration parameters also include a quantization strategy, which includes one or more of the following: Direct quantification method; Uniform quantization method; Non-uniform quantization method; Weight sharing quantization method; Group quantification method; Transform domain quantization method; Parameter coding quantization method; Product quantization method.
3. The method according to claim 1, characterized in that The step of quantizing the parameters of the first module according to the quantization configuration parameters includes: During the network training phase, the parameters of the first module are quantized according to the quantization configuration parameters.
4. The method according to claim 2, characterized in that: The parameter division method in the group quantization method includes: Random division method; Determine the set identifier of the parameter according to the identifier of the parameter; Clustering method.
5. The method according to claim 4, characterized in that The determining, according to the identifier of the parameter, the set identifier to which the parameter belongs includes: Obtaining a first value according to the identifier of the parameter; Determine, according to the first value, a set identifier to which the parameter belongs; Wherein, determining the set identifier to which the parameter belongs according to the first value includes one or more of the following: Rounding the first value to obtain a set identifier of the parameter; Take at least one bit from the first value and combine them into a set identifier to which the parameter belongs; The first value is divided by a preset value, and the remainder obtained is used as the set identifier to which the parameter belongs.
6. The method according to claim 1, characterized in that The relevant information of the parameters of the first module includes: the size of the parameters; The larger the parameter is, the higher the quantization level is; or, the larger the parameter is, the lower the quantization level is.
7. The method according to claim 1, characterized in that The higher the quantization level, the more precise the quantization accuracy of the parameters of the first module is, or the lower the quantization level, the coarser the quantization accuracy of the parameters of the first module is.
8. The method according to claim 1, characterized in that: The type of the first module is a neural network; wherein the quantization levels of neurons in different layers of the neural network are the same; and / or, The neurons in the same layer of the neural network have the same quantization level; and / or, The quantization level of the multiplicative coefficients in the neural network is the same as the quantization level of the additive coefficients.
9. The method according to claim 1, characterized in that: The type of the first module is a neural network; Wherein, the quantization levels of neurons in different layers of the neural network are different; and / or, The quantization levels of neurons in the same layer of the neural network are different; and / or, The quantization level of the multiplicative coefficients in the neural network is different from the quantization level of the additive coefficients.
10. The method according to claim 1, characterized in that The type of the first module is a recurrent neural network; The quantization level of the parameters of the memory unit in the recurrent neural network is the same as the quantization level of the parameters of the non-memory neurons in the recurrent neural network, or the same as the quantization level of the non-memory parameters of the neurons of the recurrent neural network. or, The quantization level of the parameters of the memory unit in the recurrent neural network is different from the quantization level of the parameters of the non-memory neurons in the recurrent neural network, or is different from the quantization level of the non-memory parameters of the neurons in the recurrent neural network.
11. The method according to claim 1, characterized in that: The type of the first module is a convolutional neural network; in, The quantization level of the parameters of the convolution kernel of the convolution neural network is the same as or different from the quantization level of the parameters of the non-convolution kernel in the convolution neural network, or, The quantization level of the pooled parameters of the convolutional neural network is the same as or different from the quantization level of the non-pooled parameters in the convolutional neural network.
12. The method according to claim 1, characterized in that In the case where the output of the first module is first information, the method further includes: The first information is sent to a second communication device, or the first information is sent to a second module of the first communication device.
13. The method according to claim 12, characterized in that The first communication device is a terminal, and the second communication device is a network side device; or, The first communication device is a network side device, and the second communication device is a terminal; or, The first communication device is a first terminal, and the second communication device is a second terminal; or, The first communication device is a first network side device, and the second communication device is a second network side device.
14. A quantization device, applied to a first communication device, characterized in that: include: A first determination module, configured to determine a quantized configuration parameter of a first module of the first communication device, wherein the first module is an AI module; A quantization module, used for quantizing the parameters of the first module according to the quantization configuration parameters; The quantization configuration parameters are determined according to one or more of the following: terminal reporting; terminal capabilities; network side configuration; the quantization configuration parameters include one or more of the following: whether all parameters of the AI module adopt a unified quantization level, whether the quantization level of the multiplicative coefficient of the AI module is the same as the quantization level of the additive coefficient, and the quantization level of the AI module; The quantization level is determined according to one or more of the following: relevant information of the parameters of the first module; terminal report; terminal capability; network side configuration; output accuracy requirements of the first module; performance requirements of the first module; The input or output of the first module is first information; wherein the first information includes one or more of the following: reference signal; signal carried by the channel; channel state information; beam information; channel prediction information; interference information; positioning information; prediction information of high-level services and / or parameters; management information of high-level services and / or parameters; and control signaling.
15. A communication device, characterized in that: include: A processor, a memory, and a program stored in the memory and executable on the processor, wherein the program implements the steps of the method according to any one of claims 1 to 13 when executed by the processor.
16. A readable storage medium, characterized in that: The readable storage medium stores a program or an instruction, and when the program or the instruction is executed by a processor, the steps of the method according to any one of claims 1 to 13 are implemented.
