Data classification method and device, electronic equipment and storage medium

By adopting a hybrid precision deep reinforcement learning model in the data classification task, classifying and optimizing the classified data, the problem of reducing recognition accuracy caused by unbalanced data sets is solved, and the efficiency and accuracy of data classification are improved.

CN119810507APending Publication Date: 2025-04-11INNOVATION CENTER OF YANGTZE RIVER DELTA ZHEJIANG UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411820442.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-11
Publication Date
2025-04-11

AI Technical Summary

Technical Problem

In the prior art, the uneven number of picture types in the dataset leads to a bias towards the majority of classes during model training, resulting in a reduction in the recognition accuracy of a few classes. In addition, large-scale data classification tasks have huge demands on computing resources and memory, limiting the training and inference speed of the model.

Method used

A mixed precision deep reinforcement learning model is adopted to propagate the classification data forward in each time step, and the classification results are obtained, and the classification results are evaluated in the next time step, corresponding rewards are given based on the preset evaluation criteria, and the model is optimized based on the rewards until the model reaches the convergence state.

Benefits of technology

By introducing a hybrid precision deep reinforcement learning model, the efficiency and accuracy of data classification are improved, especially suitable for processing a variety of data with uneven quantity, significantly improving the recognition accuracy of a few categories, and optimizing the use of computing resources and memory.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119810507A_ABST
    Figure CN119810507A_ABST
Patent Text Reader

Abstract

The invention provides a data classification method and device, electronic equipment and a storage medium, and the method comprises the steps: obtaining to-be-classified data from a to-be-classified data set, and the to-be-classified data set comprises a plurality of data with non-uniform quantity; inputting the to-be-classified data into the mixed precision deep reinforcement learning model; in the current time step, the mixed precision deep reinforcement learning model classifies the to-be-classified data to obtain a classification result of the to-be-classified data; in the next time step, the classification result is evaluated by the mixed precision deep reinforcement learning model, and rewards are obtained; optimizing the mixed precision deep reinforcement learning model according to the rewards; acquiring next to-be-classified data, and re-inputting the to-be-classified data into the mixed precision deep reinforcement learning model for classification until the mixed precision deep reinforcement learning model converges; and classifying the obtained target data by using the converged mixed precision deep reinforcement learning model to obtain a target classification result.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of data processing technology, and in particular to a data classification method, device, electronic device and storage medium. Background Art

[0002] In real-world applications, the imbalance of the number of image types in a dataset is a common problem. Unbalanced datasets often result in a bias toward majority class images during model training. As a result, the recognition accuracy of minority classes is significantly reduced, which can easily lead to missed detections and misjudgments, affecting the reliability of decision-making. In addition, large-scale data classification tasks have huge demands on computing resources and memory, which limits the training and reasoning speed of the model. Summary of the invention

[0003] The present disclosure provides a data classification method, device, electronic device and storage medium to at least solve the above technical problems existing in the prior art.

[0004] According to a first aspect of the present disclosure, a data classification method is provided, the method comprising:

[0005] Acquire data to be classified from a data set to be classified, wherein the data set to be classified includes a plurality of data of uneven quantities;

[0006] Inputting the data to be classified into a mixed precision deep reinforcement learning model;

[0007] In the current time step, the mixed precision deep reinforcement learning model classifies the data to be classified to obtain a classification result of the data to be classified;

[0008] In the next time step, the mixed precision deep reinforcement learning model evaluates the classification result and obtains a reward;

[0009] Optimizing the mixed precision deep reinforcement learning model according to the reward;

[0010] Obtain next data to be classified, and re-input the mixed precision deep reinforcement learning model for classification until the mixed precision deep reinforcement learning model converges;

[0011] The acquired target data is classified using the converged mixed precision deep reinforcement learning model to obtain the target classification results.

[0012] In one possible implementation, the categories of data in the to-be-classified data set include a minority class and a majority class;

[0013] The reward for the minority class is higher than the reward for the majority class.

[0014] In one possible implementation manner, the mixed precision deep reinforcement learning model includes a policy network, and the mixed precision deep reinforcement learning model classifies the data to be classified to obtain a classification result of the data to be classified, including:

[0015] The policy network performs a classification action on the data to be classified to obtain a classification result of the data to be classified; the classification action corresponds to a classification label of the data to be classified.

[0016] In one possible implementation, the mixed precision deep reinforcement learning model includes a value estimation network, and the mixed precision deep reinforcement learning model evaluates the classification result to obtain a reward, including:

[0017] The value estimation network evaluates the classification action of the data to be classified;

[0018] If the correct classification action is performed, a positive reward is given; otherwise, a negative reward is given.

[0019] In one possible implementation, optimizing the mixed precision deep reinforcement learning model according to the reward includes:

[0020] After normalizing the reward, it is fed into the gradient scaler and the loss value is calculated;

[0021] The mixed precision deep reinforcement learning model is optimized according to the loss value.

[0022] In one possible implementation, the mixed precision deep reinforcement learning model is migrated to the data processing module, and an automatic mixed precision mechanism is used to accelerate the calculation process of the model.

[0023] In one possible implementation manner, the data processing module is composed of a plurality of distributed data processing units, and the data processing units are gradient synchronized.

[0024] According to a second aspect of the present disclosure, a data classification device is provided, the device comprising:

[0025] An acquisition module is used to acquire the data to be classified from the data set to be classified, wherein the data set to be classified contains a plurality of data of uneven quantity;

[0026] An input module, used for inputting the data to be classified into a mixed precision deep reinforcement learning model;

[0027] A data processing module, used for classifying the data to be classified by the mixed precision deep reinforcement learning model in the current time step to obtain a classification result of the data to be classified;

[0028] The data processing module is further used to evaluate the classification result by the mixed precision deep reinforcement learning model in the next time step to obtain a reward;

[0029] A data processing module is further used to optimize the mixed precision deep reinforcement learning model according to the reward;

[0030] The data processing module is further used to obtain the next data to be classified and re-input the mixed precision deep reinforcement learning model for classification until the mixed precision deep reinforcement learning model converges;

[0031] The data processing module is also used to classify the acquired target data using the converged mixed precision deep reinforcement learning model to obtain the target classification result.

[0032] According to a third aspect of the present disclosure, there is provided an electronic device, including:

[0033] at least one processor; and

[0034] a memory communicatively connected to the at least one processor; wherein,

[0035] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method described in the present disclosure.

[0036] According to a fourth aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to cause the computer to execute the method described in the present disclosure.

[0037] The data classification method, device, electronic device and storage medium disclosed in the present invention obtain data from a data set to be classified that contains data of various types and uneven quantities, and input the data to be classified into a mixed precision deep reinforcement learning model for classification processing. In each time step, the model performs forward propagation according to the input data to obtain a classification result. Entering the next time step, the classification result is evaluated, and corresponding rewards are given according to preset evaluation criteria. The model is optimized and cycled according to the reward until the model reaches a convergence state. At this time, the converged model can be used to classify new target data to obtain more accurate and reliable classification results. This method improves the efficiency and accuracy of data classification by introducing a mixed precision deep reinforcement learning model, and is particularly suitable for processing a variety of data with uneven quantities.

[0038] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] The above and other objects, features and advantages of the exemplary embodiments of the present disclosure will become readily understood by reading the detailed description below with reference to the accompanying drawings. In the accompanying drawings, several embodiments of the present disclosure are shown in an exemplary and non-limiting manner, in which:

[0040] In the drawings, the same or corresponding reference numerals represent the same or corresponding parts.

[0041] Figure 1 A schematic diagram of the implementation process of the data classification method according to an embodiment of the present disclosure is shown;

[0042] Figure 2 A schematic diagram of the implementation process of optimizing a mixed-precision deep reinforcement learning model according to an embodiment of the present disclosure is shown;

[0043] Figure 3 A schematic diagram of the structure of a data classification device according to an embodiment of the present disclosure is shown;

[0044] Figure 4 A schematic diagram of the structure of an electronic device according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION

[0045] In order to make the purpose, features, and advantages of the present disclosure more obvious and easy to understand, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present disclosure.

[0046] The present disclosure provides a data classification method, such as Figure 1 As shown, the method includes:

[0047] Step 101: Obtain data to be classified from a data set to be classified, where the data set to be classified contains a variety of data with uneven quantities.

[0048] In this example, the data set to be classified contains multiple types of data, and the amount of each type of data is obviously uneven, that is, the amount of data in one category is much less than the amount of data in other categories.

[0049] Step 102: Input the data to be classified into the mixed precision deep reinforcement learning model.

[0050] In this example, the data to be classified obtained from the dataset to be classified is input into the mixed precision deep reinforcement learning model for classification. The mixed precision deep reinforcement learning model is a model that combines automatic mixed precision technology and deep reinforcement learning. Automatic mixed precision technology (Automatic Mixed Precision, AMP) is a mechanism for automatically adjusting mixed precision, which can intelligently determine when the model uses 16-bit floating point numbers (Float16, FP16) and when to keep 32-bit floating point numbers (Float32, FP32), thereby balancing the calculation accuracy and speed of the model. Deep reinforcement learning combines the advantages of deep learning and reinforcement learning, and can handle high-dimensional input data and complex decision-making processes.

[0051] Step 103: In the current time step, the mixed precision deep reinforcement learning model classifies the data to be classified and obtains the classification result of the data to be classified.

[0052] During the training process, the mixed precision deep reinforcement learning model is composed of a series of discrete time steps. In the current time step, the model performs forward propagation based on the input data to be classified, calculates the score or probability of each category, and obtains the classification result of the data to be classified.

[0053] Step 104: In the next time step, the mixed precision deep reinforcement learning model evaluates the classification result and obtains a reward.

[0054] After obtaining the classification results, the mixed precision deep reinforcement learning model will enter the next time step, evaluate the classification results according to the preset evaluation criteria, and give corresponding rewards. This reward can be used to guide the optimization learning process of the mixed precision deep reinforcement learning model.

[0055] Step 105: Optimize the mixed precision deep reinforcement learning model based on the reward.

[0056] In this example, after receiving a reward, the model adjusts its internal parameters according to the size and direction of the reward to optimize its classification performance. By using the back-propagation algorithm, the weights and parameters of the model are updated by calculating the gradient. Through continuous trial and error and adjustment, the mixed precision deep reinforcement learning model can gradually learn how to better classify data.

[0057] Step 106: Obtain the next data to be classified and re-input it into the mixed precision deep reinforcement learning model for classification until the mixed precision deep reinforcement learning model converges.

[0058] In this example, after the mixed precision deep reinforcement learning model completes a classification and evaluation, new data to be classified is obtained from the data set to be classified again, and the above steps (steps 102 to 105) are repeated. This process will continue until the model reaches a convergence state, that is, the performance of the mixed precision deep reinforcement learning model is no longer significantly improved or reaches the preset stop condition.

[0059] Step 107: Use the converged mixed precision deep reinforcement learning model to classify the acquired target data to obtain a target classification result.

[0060] In this example, after the mixed precision deep reinforcement learning model converges, the model can be used to classify new target data to obtain the target classification result. The classification process of the target data is the same as the classification process of the data to be classified, but at this time the model has been fully trained and optimized, so it can give more accurate and reliable classification results.

[0061] The present disclosure provides a data classification method, which obtains data from a data set to be classified that contains data of various types and uneven quantities, and inputs the data to be classified into a mixed precision deep reinforcement learning model for classification processing. In each time step, the model performs forward propagation according to the input data to obtain a classification result. Entering the next time step, the classification result is evaluated, and corresponding rewards are given according to preset evaluation criteria. The model is optimized and cycled according to the reward until the model reaches a convergence state. At this time, the converged model can be used to classify new target data to obtain more accurate and reliable classification results. This method improves the efficiency and accuracy of data classification by introducing a mixed precision deep reinforcement learning model, and is particularly suitable for processing a variety of data with uneven quantities.

[0062] In one example, the categories of data in the to-be-classified data set include a minority class and a majority class; and the reward of the minority class is higher than the reward of the majority class.

[0063] In this example, if the dataset to be classified is a binary imbalanced dataset, the extracted images to be classified are input into the mixed precision deep reinforcement learning model for forward propagation, and the classification results to be classified are minority or majority. In order to identify as many minority samples as possible, the rewards for minority and majority classes are set differently. Specifically, the reward value for minority classes is higher than that for majority classes.

[0064] In one example, a mixed precision deep reinforcement learning model includes a policy network, and the mixed precision deep reinforcement learning model classifies the data to be classified to obtain the classification result of the data to be classified, including: the policy network performs a classification action on the data to be classified to obtain the classification result of the data to be classified; the classification action corresponds to the classification label of the data to be classified.

[0065] In this example, the mixed precision deep reinforcement learning model includes a policy network, which is used to select and execute classification actions for the data to be classified. The executed classification actions correspond to the classification labels of the data to be classified, thereby obtaining classification results of the data to be classified.

[0066] The data to be processed is input into the policy network of the model, and forward propagation calculation is performed through a series of convolutional layers, pooling layers, fully connected layers, and output layer structures to extract the features in the data to be classified and map them to the classification space to obtain the classification results.

[0067] For example, when the data to be classified is a sample image, after the sample image is input through the input layer, the model will gradually extract local features and global features in the sample image in the convolution layer and pooling layer. Then, in the fully connected layer and the output layer, the model calculates the score or probability of each category based on the extracted features. Then, according to the score or probability, an optimal classification result is selected as the action output.

[0068] In one example, the mixed precision deep reinforcement learning model includes a value estimation network, and the mixed precision deep reinforcement learning model evaluates the classification results and obtains rewards, including:

[0069] The value estimation network evaluates the classification action of the classified data. If the correct classification action is performed, a positive reward is given; otherwise, a negative reward is given.

[0070] In this example, the value estimation network outputs a reward value that represents the potential reward for performing the classified action.

[0071] If the classification action performed is correct (i.e., consistent with the true label), the value estimation network will output a higher reward value, and the model will give a positive reward to encourage the model to continue to take similar correct classification actions. If the classification action performed is wrong (i.e., inconsistent with the true label), the value estimation network will output a lower reward value, giving the model a negative reward to punish it for performing incorrect classification actions and prompting the model to adjust its strategy during subsequent training.

[0072] In one example, a mixed precision deep reinforcement learning model is optimized based on rewards, such as Figure 2 As shown, including:

[0073] Step 201: After the reward is normalized, it is input into the gradient scaler and the loss value is calculated.

[0074] In this example, in a mixed precision deep reinforcement learning model, the value range of the reward may vary greatly, which will affect the training stability and efficiency of the model. Therefore, before using the reward for model optimization, it is usually necessary to normalize the reward. Normalization is the process of scaling the reward value to a specific value range (such as between 0 and 1), which helps ensure that different reward values ​​have similar influence during model training.

[0075] During training, due to the use of data types with different precisions, the gradient value may be too large or too small, thus affecting the training effect of the model. Therefore, a gradient scaler is needed to process the gradient value. The normalized reward value is input into the gradient scaler. The purpose of the gradient scaler is to adjust the size of the gradient value to ensure that they remain in a suitable range during training. The gradient scaler adopts a dynamic adjustment strategy to dynamically adjust the scaling factor according to the current gradient value and network parameters.

[0076] After the gradient scaler processes the gradient values, the loss value is calculated based on these gradient values ​​and the current network parameters.

[0077] Step 202: Optimize the mixed precision deep reinforcement learning model according to the loss value.

[0078] In this example, the back propagation algorithm is used to update the network parameters based on the calculated loss value. The back propagation algorithm calculates the gradient of each parameter based on the loss value and uses the optimizer to update these parameters. By continuously iterating this process, the model can gradually learn how to generate the correct classification actions based on the input data and maximize the long-term reward.

[0079] In one example, a mixed-precision deep reinforcement learning model is migrated to a data processing module, and an automatic mixed-precision mechanism is used to accelerate the model's calculation process.

[0080] In this example, the data processing module refers to a chip or module that accelerates data processing, such as a graphics processing unit (GPU), which can accelerate the mixed precision deep reinforcement learning model when processing graphics classification.

[0081] Mixed precision refers to the use of different precisions (such as 16-bit floating point FP16 and 32-bit floating point FP32) for calculations in deep learning to balance computational efficiency and numerical stability. FP16 can significantly reduce memory usage and computing time compared to FP32, but may face problems of numerical instability and loss of precision.

[0082] The automatic mixed precision mechanism is a mechanism that intelligently adjusts mixed precision and can automatically choose to use FP16 or FP32 based on computing requirements. By analyzing each part of the model and computing requirements, the precision is dynamically adjusted to optimize performance and reduce precision loss.

[0083] In the deep reinforcement learning model, classification behavior is optimized through training through deep learning models such as policy networks and value estimation networks. The present disclosure introduces the AMP mechanism, which enables the deep reinforcement learning model to automatically select appropriate accuracy for calculation during the training process, thereby improving training efficiency.

[0084] Specifically, AMP is used for forward and backward propagation in the training loop and application process of the mixed-precision deep reinforcement learning model. By leveraging AMP's autocast mechanism, for layers that are prone to numerical instability (such as reward normalization layers and loss calculation layers), 32-bit floating-point operations are usually maintained to avoid the accumulation of computational errors caused by low precision; while other layers (such as convolutional layers and fully connected layers) can use FP16 precision to improve computational efficiency. In addition, since the numerical range of FP16 is narrow, the AMP mechanism will also be used in conjunction with the loss scaler to ensure the numerical stability of the gradient.

[0085] Training history data is also an important resource in the training process. Since FP16 occupies half the memory space of FP32, we choose to save and operate these playback data in FP16 instead of traditional FP32. At the same time, due to the reduction in data volume, the speed of data loading and processing will also increase accordingly, thereby improving data loading efficiency.

[0086] In one example, the data processing module is composed of multiple distributed data processing units, and the data processing units are gradient synchronized.

[0087] In this example, the data processing module composed of multiple distributed data processing units provides powerful parallel computing capabilities for the training and application of mixed-precision deep reinforcement learning models, which can significantly improve the calculation speed of deep reinforcement learning models. The distributed framework is used to synchronize the gradients of multiple processing units to ensure that the model parameters on each processing unit can be updated in a timely manner.

[0088] The present disclosure also provides a data classification device, such as Figure 3 As shown, the device comprises:

[0089] An acquisition module 301 is used to acquire data to be classified from a data set to be classified, where the data set to be classified contains a variety of data with uneven quantities;

[0090] An input module 302, used to input the data to be classified into the mixed precision deep reinforcement learning model;

[0091] The data processing module 303 is used to classify the data to be classified using the mixed precision deep reinforcement learning model in the current time step to obtain the classification result of the data to be classified;

[0092] The data processing module 303 is also used to evaluate the classification result in the next time step using the mixed precision deep reinforcement learning model to obtain a reward;

[0093] The data processing module 303 is further used to optimize the mixed precision deep reinforcement learning model according to the reward;

[0094] The data processing module 303 is also used to obtain the next data to be classified and re-input it into the mixed precision deep reinforcement learning model for classification until the mixed precision deep reinforcement learning model converges;

[0095] The data processing module 303 is also used to classify the acquired target data using the converged mixed precision deep reinforcement learning model to obtain a target classification result.

[0096] In one example, the categories of data in the to-be-classified data set include a minority class and a majority class; and the reward of the minority class is higher than the reward of the majority class.

[0097] In one example, the data processing module 303, when the mixed precision deep reinforcement learning model includes a policy network, and the mixed precision deep reinforcement learning model classifies the data to be classified to obtain the classification result of the data to be classified, is specifically used for: the policy network performs a classification action on the data to be classified to obtain the classification result of the data to be classified; the classification action corresponds to the classification label of the data to be classified.

[0098] In one example, the data processing module 303, when the mixed precision deep reinforcement learning model includes a value estimation network, the mixed precision deep reinforcement learning model evaluates the classification results, and when a reward is obtained, it is specifically used for: the value estimation network evaluates the classification action of the classified data; if the correct classification action is performed, a positive reward is given; otherwise, a negative reward is given.

[0099] In one example, when optimizing a mixed precision deep reinforcement learning model based on rewards, the data processing module 303 is specifically used to: normalize the rewards, input them into a gradient scaler and calculate the loss value; and optimize the mixed precision deep reinforcement learning model based on the loss value.

[0100] In one example, a mixed precision deep reinforcement learning model is migrated to the data processing module 303, and an automatic mixed precision mechanism is used to accelerate the calculation process of the model.

[0101] In one example, the data processing module 303 is composed of multiple distributed data processing units, and the data processing units are gradient synchronized.

[0102] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device and a readable storage medium.

[0103] Figure 4 A schematic block diagram of an example electronic device 800 that can be used to implement an embodiment of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.

[0104] like Figure 4 As shown, the electronic device 800 includes a computing unit 801, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 802 or a computer program loaded from a storage unit 808 into a random access memory (RAM) 803. In the RAM 803, various programs and data required for the operation of the device 800 can also be stored. The computing unit 801, the ROM 802, and the RAM 803 are connected to each other via a bus 804. An input / output (I / O) interface 805 is also connected to the bus 804.

[0105] A number of components in the device 800 are connected to the I / O interface 805, including: an input unit 806, such as a keyboard, a mouse, etc.; an output unit 807, such as various types of displays, speakers, etc.; a storage unit 808, such as a disk, an optical disk, etc.; and a communication unit 809, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 809 allows the device 800 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.

[0106] The computing unit 801 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 801 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 801 performs the various methods and processes described above, such as data classification methods. For example, in some embodiments, the data classification method may be implemented as a computer software program, which is tangibly contained in a machine-readable medium, such as a storage unit 808. In some embodiments, part or all of the computer program may be loaded and / or installed on the device 800 via ROM 802 and / or communication unit 809. When the computer program is loaded into RAM 803 and executed by the computing unit 801, one or more steps of the data classification method described above may be performed. Alternatively, in other embodiments, the computing unit 801 may be configured to perform the data classification method in any other appropriate manner (e.g., by means of firmware).

[0107] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0108] The program code for implementing the method of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that the program code, when executed by the processor or controller, enables the functions / operations specified in the flow chart and / or block diagram to be implemented. The program code may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.

[0109] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0110] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0111] The systems and techniques described herein may be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.

[0112] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship of client and server is generated by computer programs running on respective computers and having a client-server relationship with each other. The server may be a cloud server, a server of a distributed system, or a server combined with a blockchain.

[0113] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document does not limit this.

[0114] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of the present disclosure, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.

[0115] The above is only a specific embodiment of the present disclosure, but the protection scope of the present disclosure is not limited thereto. Any person skilled in the art who is familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present disclosure, which should be included in the protection scope of the present disclosure. Therefore, the protection scope of the present disclosure should be based on the protection scope of the claims.

Claims

1. A data classification method, characterized in that: The method comprises: Acquire data to be classified from a data set to be classified, wherein the data set to be classified includes a plurality of data of uneven quantities; Inputting the data to be classified into a mixed precision deep reinforcement learning model; In the current time step, the mixed precision deep reinforcement learning model classifies the data to be classified to obtain a classification result of the data to be classified; In the next time step, the mixed precision deep reinforcement learning model evaluates the classification result and obtains a reward; Optimizing the mixed precision deep reinforcement learning model according to the reward; Obtain next data to be classified, and re-input the mixed precision deep reinforcement learning model for classification until the mixed precision deep reinforcement learning model converges; The acquired target data is classified using the converged mixed precision deep reinforcement learning model to obtain the target classification results.

2. The method according to claim 1, characterized in that The categories of data in the data set to be classified include minority classes and majority classes; The reward for the minority class is higher than the reward for the majority class.

3. The method according to claim 1, characterized in that The mixed precision deep reinforcement learning model includes a policy network. The mixed precision deep reinforcement learning model classifies the data to be classified to obtain a classification result of the data to be classified, including: The policy network performs a classification action on the data to be classified to obtain a classification result of the data to be classified; the classification action corresponds to a classification label of the data to be classified.

4. The method according to claim 3, characterized in that The mixed precision deep reinforcement learning model includes a value estimation network, and the mixed precision deep reinforcement learning model evaluates the classification result to obtain a reward, including: The value estimation network evaluates the classification action of the data to be classified; If the correct classification action is performed, a positive reward is given; otherwise, a negative reward is given.

5. The method according to claim 1, characterized in that: Optimizing the mixed precision deep reinforcement learning model according to the reward includes: After normalizing the reward, it is fed into the gradient scaler and the loss value is calculated; The mixed precision deep reinforcement learning model is optimized according to the loss value.

6. The method according to claim 1, characterized in that The mixed-precision deep reinforcement learning model is migrated to the data processing module, and an automatic mixed-precision mechanism is used to accelerate the model's calculation process.

7. The method according to claim 6, characterized in that The data processing module is composed of a plurality of distributed data processing units, and the data processing units are gradient synchronized.

8. A data classification device, characterized in that: The device comprises: An acquisition module is used to acquire the data to be classified from the data set to be classified, wherein the data set to be classified contains a plurality of data of uneven quantity; An input module, used for inputting the data to be classified into a mixed precision deep reinforcement learning model; A data processing module, used for classifying the data to be classified by the mixed precision deep reinforcement learning model in the current time step to obtain a classification result of the data to be classified; The data processing module is further used to evaluate the classification result by the mixed precision deep reinforcement learning model in the next time step to obtain a reward; A data processing module is further used to optimize the mixed precision deep reinforcement learning model according to the reward; The data processing module is further used to obtain the next data to be classified and re-input the mixed precision deep reinforcement learning model for classification until the mixed precision deep reinforcement learning model converges; The data processing module is also used to classify the acquired target data using the converged mixed precision deep reinforcement learning model to obtain the target classification result.

9. An electronic device, characterized in that: include: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 7.

10. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to cause the computer to execute the method according to any one of claims 1-7.