Database management method and device, equipment and storage medium

By detecting and updating data in the database, determining the sample data set, and using the simplified data analysis model for training, the problem of data analysis model update under high-speed inflow of data flow and dynamic changes is solved, and the accuracy and flexibility of data analysis are improved.

CN119739693APending Publication Date: 2025-04-01WUHAN DAMENG DATABASE
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411812243.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-10
Publication Date
2025-04-01

AI Technical Summary

Technical Problem

The prior art is difficult to effectively update the integrated data analysis model in the database in an environment of high-speed inflow and dynamic changes in data flow, resulting in the impact of the accuracy and flexibility of data analysis.

Method used

By detecting updated data within a set time interval, the sample data set is determined and trained on the sample data set using a preset simplified data analysis model, thereby updating and integrating into the database.

Benefits of technology

It realizes incremental updates of the data analysis model in the database, adapts to the dynamic changes of data flow, improves the accuracy and flexibility of data analysis, and saves storage and computing resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119739693A_ABST
    Figure CN119739693A_ABST
Patent Text Reader

Abstract

The embodiment of the invention discloses a database management method and device, equipment and a storage medium. Comprising the steps that when it is detected that a model updating condition is met currently, a sample data set is determined based on updating data of a database within a set time interval; obtaining a preset first data analysis model and a second data analysis model integrated in the database; and training a first data analysis model by adopting the sample data set, updating the second data analysis model by adopting the trained first data analysis model, and integrating the updated second data analysis model into the database. According to the technical scheme provided by the embodiment of the invention, the dynamic change and concept drift of the data stream are better dealt with, and the dynamic real-time updating of the data analysis model in the database is ensured; and storage resources and computing resources occupied by updating the data analysis model are effectively saved. Therefore, the data analysis model can play a better analysis role in a specific application scene.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Embodiments of the present invention relate to the field of database technology, and in particular to a database management method, apparatus, device and storage medium. Background Art

[0002] Data analysis has penetrated into various application fields. It can predict the future development trend of business applications based on the analysis of existing data, or serve as a basis for judging the current results of business applications for decision makers to make decisions.

[0003] The business data used for data analysis in different business applications are often stored in corresponding databases. In existing applications, the data analysis models (such as neural network models, decision tree models, etc.) used for data analysis are integrated into the database to facilitate rapid analysis of business data. For databases, the integrated data analysis models are often trained based on business data and can match the needs of business applications. Therefore, how to train the integrated data analysis models has also become a part of database management.

[0004] The current training of such data analysis models is mainly based on historical offline data. However, in the real world, data is often continuously generated and updated in the form of data streams. Traditional methods are often unable to effectively cope with the high speed and dynamics of data streams, resulting in the data analysis models obtained through offline data being unable to apply to dynamically changing business data analysis, thereby affecting the accuracy of data analysis and the flexibility of data analysis applications. Summary of the invention

[0005] The embodiments of the present invention provide a database management method, apparatus, device and storage medium, which can realize the effective update of the data analysis model in the database under the premise of high-speed inflow and dynamic change of data flow.

[0006] In a first aspect, an embodiment of the present invention provides a database management method, including:

[0007] When it is detected that the model update condition is currently met, a sample data set is determined based on the updated data of the database within a set time interval;

[0008] Acquire a preset first data analysis model and a second data analysis model integrated in the database, wherein the network layers and network parameters included in the first data analysis model are less than those in the second data analysis model;

[0009] The sample data set is used to train a first data analysis model, and the trained first data analysis model is used to update the second data analysis model, and the updated second data analysis model is integrated into the database.

[0010] In a second aspect, an embodiment of the present invention further provides a database management device, the device comprising:

[0011] A sample set determination module is used to determine a sample data set based on the updated data of the database within a set time interval when it is detected that the model update condition is currently met;

[0012] A model acquisition module, used to acquire a preset first data analysis model and a second data analysis model integrated in the database, wherein the network layers and network parameters included in the first data analysis model are less than those in the second data analysis model;

[0013] A model updating module is used to train a first data analysis model using the sample data set, and to update the second data analysis model using the trained first data analysis model, and to integrate the updated second data analysis model into the database.

[0014] In a third aspect, an embodiment of the present invention further provides an electronic device, the electronic device comprising:

[0015] at least one processor; and

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

[0017] The memory stores a computer program that can be executed by the at least one processor. The computer program is executed by the at least one processor so that the at least one processor can execute the database management method described in the embodiment of the present invention.

[0018] In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the database management method described in the embodiment of the present invention when executed.

[0019] The embodiment of the present invention discloses a database management method, device, equipment and storage medium, including: when it is detected that the model update condition is currently met, a sample data set is determined based on the updated data of the database within a set time interval; a preset first data analysis model and a second data analysis model integrated in the database are obtained, and the network layer and network parameters contained in the first data analysis model are less than those in the second data analysis model; the first data analysis model is trained using the sample data set, and the second data analysis model is updated using the trained first data analysis model, and the updated second data analysis model is integrated into the database. The above technical scheme can realize the incremental update of the data analysis model in the database, specifically considering the impact of the data flowing into the database within a time period on the data analysis model, so as to use the updated data within the time period as the sample data set required for the data analysis model update; at the same time, it also considers the incremental update of a simplified version of the data analysis model to realize the update of the data analysis model in the database, thereby simplifying the update logic of the data analysis model. Compared with the prior art, the technical scheme provided by this embodiment better copes with the dynamic changes and concept drift of the data stream, ensures the dynamic and real-time update of the data analysis model in the database; and effectively saves the storage resources and computing resources occupied by the data analysis model update. This enables the data analysis model to play a better analytical role in specific application scenarios. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] Figure 1 is a flow chart of a database management method in Embodiment 1 of the present invention;

[0021] Figure 2 is a flow chart of a database management method in Embodiment 2 of the present invention;

[0022] Figure 3 It is a structural diagram of a database management device in Embodiment 3 of the present invention;

[0023] Figure 4 It is a structural schematic diagram of an electronic device in Embodiment 4 of the present invention. DETAILED DESCRIPTION

[0024] The present invention will be further described in detail below in conjunction with the accompanying drawings and embodiments. It is to be understood that the specific embodiments described herein are only used to explain the present invention, rather than to limit the present invention. It should also be noted that, for ease of description, only parts related to the present invention, rather than all structures, are shown in the accompanying drawings.

[0025] Embodiment 1

[0026] Figure 1This is a flowchart of a database management method provided in the first embodiment of the present invention. This embodiment is applicable to the case of managing a data analysis model in a database. The method can be executed by a database management device, which can be implemented in the form of software and / or hardware. Optionally, it can be implemented by an electronic device, which can be a mobile terminal, PC or server associated with the database. Specifically, it includes the following steps:

[0027] S110: When it is detected that the model update condition is currently met, a sample data set is determined based on the updated data of the database within a set time interval.

[0028] It should be noted that the method provided in this embodiment can be specifically executed by a trigger defined on the execution subject, so the implementation logic of the method steps in this embodiment can actually be regarded as the execution logic of the trigger set by the relative database management in the electronic device. Among them, the setting of the relative trigger can be implemented through the JOB task created by DBMS_SCHEDULER.CREATE_JOB, and this step and subsequent steps are executed specifically by running the JOB task.

[0029] In this embodiment, the model update condition can be specifically understood as the trigger execution condition of the data analysis model update logic in the database. The model update condition can be that new data is inserted into the database or the data in the database is modified within a time period; or it can be determined that the existing data analysis model in the database cannot accurately analyze the data dynamically flowing into the database, or cannot adapt to the updated data.

[0030] In this embodiment, the database can be considered as a storage platform for a certain business application and used to store data corresponding to the business application. The database can integrate a data analysis model for business data analysis. As time goes by, the integrated data analysis model may not be applicable to the updated data that is subsequently dynamically updated to the database, so it is necessary to update the data analysis model through the method provided in this embodiment.

[0031] In this embodiment, the set time interval can be considered as a pre-set time period, and the updated data flowing into the database within a time period can be obtained according to the time period. The sample data set is a data set participating in the update of the data analysis model, and the sample data set specifically includes data that meets the screening conditions filtered out from the updated data flowing into the database within the set time interval.

[0032] In this embodiment, for determining a sample data set based on the updated data of the database within a set time interval, one implementation method can be described as: first locate the updated data within the set time interval from the database, and then search in the updated data according to the input query conditions, so as to find the data that meets the conditions, thereby forming a sample data set. Among them, the update time of the updated data can be recorded by adding a timestamp data column to the data table of the data stored in the database, so as to locate which data exists in the set time interval; at the same time, the query conditions in this embodiment can be formed using a structured query language that can be recognized by the database, such as using a WHERE clause, or using operators such as JOIN operations, so as to filter and connect tables in the database to obtain the required data.

[0033] It can be known that different businesses correspond to different databases. When implementing the execution logic of determining a sample data set from updated data, corresponding query conditions can be set according to different corresponding business scenarios.

[0034] Furthermore, in one implementation, the model update condition in this embodiment may be optimized as follows: it is detected that data is updated in the database within a set time interval; and / or the second data analysis model fails the model verification.

[0035] In this embodiment, the data update can be understood as new data being inserted into the current database, or can also be understood as modifying the data in the current database. The second data analysis model can be understood as a data analysis model integrated in the database, used to implement analysis of business data.

[0036] In this embodiment, it can be considered that the execution subject of this embodiment has a monitoring function, which can monitor the update of data in the database in real time and periodically give a trigger judgment. Exemplarily, it can be considered that the set time interval constitutes a time period, so that in the process of real-time monitoring of the database, it can be determined whether the data in the database is updated within the set time interval, and the update can include inserting new data or modifying existing data.

[0037] Following the above description, it can also be considered that the execution subject of this embodiment has a model verification function. Therefore, this embodiment can also determine whether the model update condition is met by verifying the output results of the data analysis model in the database, wherein this embodiment can record the data analysis model in the database as the second data analysis model. Exemplarily, this embodiment can determine that the model update condition is met when it is determined that the data analysis model has passed the model verification. It can be known that the data update monitoring and model verification judgment given above in this embodiment can be used as model update conditions to trigger model updates, respectively, or model updates can be triggered when one of the conditions is met.

[0038] In this embodiment, the model verification method can be preferably as follows: inputting the data in the prediction data set into the second data analysis model; if the matching degree between the model output result and the preset label result is within the set range, it is determined that the model verification has been passed; otherwise, it is determined that the model verification has not been passed.

[0039] It can be known that the process of updating the second data analysis model integrated in the database is dynamically iterative. With the continuous inflow of new data, the previously trained data analysis model may not be applicable to the data added later. Whether it is applicable can be verified by the prediction data set, wherein the prediction data set can be determined based on the updated data in the database. The updated data can specifically come from the data updated to the database between the last data analysis model update and the current time, thereby constituting the prediction data set.

[0040] Continuing with the above description, the prediction data set includes the prediction data and the actual results analyzed for the prediction data by other means, and the actual results can be used as the label results of this embodiment. At the same time, the prediction data in the prediction data set can be input into the second data analysis model, and the model output result can be obtained. The model output result can be compared with the label result, such as using a set loss function to determine the matching degree of the two. If the matching degree of the two is not within the set range, it can be considered that the model verification has not been passed.

[0041] S120: Acquire a preset first data analysis model and a second data analysis model integrated in a database.

[0042] The first data analysis model includes fewer network layers and network parameters than the second data analysis model.

[0043] In this embodiment, the data analysis model can be a decision tree model, a support vector machine model, a neural network model, etc. In different business application scenarios, the selected data analysis model is different; the preset first data analysis model can be understood as a pre-set data analysis model; the network layer can be understood as the number of layers in the data analysis model; the network parameters can be understood as the weights and regularization parameters of the data analysis model; relative to the second data analysis model, the first data analysis model is a simplified model with fewer network layers and parameters.

[0044] In this embodiment, the initial models of the first data analysis model and the second data analysis model are pre-trained based on historical data sets in the database.

[0045] In this embodiment, the preset first data analysis model and the second data analysis model integrated in the database have their own corresponding initial models respectively; the historical data set can be understood as the data set before the database receives no updated data.

[0046] Specifically, the method of initial model training can be optimized as follows: initializing network parameters of the initial models of the first data analysis model and the second data analysis model; inputting historical data sets in the database into the initialized initial models for training to obtain the initial models of the first data analysis model and the second data analysis model.

[0047] S130, using the sample data set to train the first data analysis model, and using the trained first data analysis model to update the second data analysis model, and integrating the updated second data analysis model into the database.

[0048] In this embodiment, for training the first data analysis model using a sample data set, and updating the second data analysis model using the trained first data analysis model, one implementation method can be described as: training the first data analysis model using the data in the sample data set, and verifying the trained first data analysis model using the data in the sample data set; and updating the second data analysis model using the verified first data analysis model.

[0049] Optionally, for verifying the trained first data analysis model using the data in the sample data set, one implementation method can be described as: inputting the data in the sample data set into the trained first data analysis model; if the matching degree between the model output result and the preset label result is within a set range, it indicates that the model verification has passed; otherwise, it indicates that the model verification has failed.

[0050] The technical solution of this embodiment, when it is detected that the model update condition is currently met, determines the sample data set based on the updated data of the database within a set time interval; obtains the preset first data analysis model, and the second data analysis model integrated in the database; uses the sample data set to train the first data analysis model, and uses the trained first data analysis model to update the second data analysis model, and integrates the updated second data analysis model into the database. The above technical solution takes into account the impact of the data in the database on the data analysis model, so the updated data in the database is used as the sample data set required by the data analysis model; it also considers using a simplified data analysis model to update the existing data analysis model in the database, simplifying the update logic of the data analysis model. The technical solution provided by this embodiment can better cope with the dynamic changes and concept drift of the data flow, while ensuring the dynamic real-time update of the data analysis model in the database; saving the storage resources and computing resources occupied by the data analysis model update. Thereby, the data analysis model plays a better analytical role in specific application scenarios.

[0051] Embodiment 2

[0052] Figure 2 This is a flowchart of a database management method provided in Embodiment 2 of the present invention. Based on the above embodiment, the method includes the following steps:

[0053] S210: When it is detected that the model update condition is currently met, the incremental data set updated to the database within a set time interval is extracted according to the timestamp of the data stored in the database.

[0054] In this embodiment, the timestamp is used to record the update time of the data in the database, such as the time when the data is inserted into the database, or the modification time of the data in the database; the incremental data set can be understood as the set of data updated to the database within a set time interval.

[0055] In this embodiment, for extracting incremental data sets updated to the database within a set time interval based on the timestamp of the data stored in the database, one implementation method can be described as: obtaining the data updated to the database within the set time interval based on the update time stored in the database.

[0056] S220 . Filter the sub-incremental data sets that meet the query condition from the incremental data set according to the set query statement.

[0057] In this embodiment, the set query statement can be understood as a query language recognizable by the database, such as an SQL statement; the query condition can be formed using the query statement; and the sub-incremental data set is part of the data in the incremental data set.

[0058] In this embodiment, since the incremental data set updated to the database contains data of various business types, when data of a certain business type needs to be obtained, it is necessary to filter out the sub-incremental data sets that meet the query conditions from the incremental data set according to the query statement.

[0059] S230, dividing the data in the sub-incremental data set into a training set, a validation set, and a prediction set to form a sample data set.

[0060] In this embodiment, the training set is used to train the data analysis model; the validation set is used to verify the trained data analysis model to ensure that the trained data analysis model can accurately analyze the data; and the prediction set is used to predict the verified data analysis model.

[0061] In this embodiment, the data in the sub-incremental data set can be divided into a training set, a validation set, and a prediction set in a random manner, wherein the amount of data contained in the training set, the validation set, and the prediction set can be the same or different.

[0062] S240: Acquire a preset first data analysis model and a second data analysis model integrated in the database.

[0063] S250, using the data in the training set in the sample data set to train the first data analysis model, and recording the first data analysis model verified by the verification set in the sample data set as a teacher model.

[0064] In this embodiment, the first data analysis model is trained using the data in the training set in the sample data set, and the trained first data analysis model is verified using the verification set in the sample data set, and the first data analysis model verified by the verification set in the sample data set is recorded as a teacher model. One implementation method can be described as: inputting the data in the training set into the first data analysis model, training the first data analysis model, and obtaining the trained first data analysis model; inputting the data in the verification set into the trained first data analysis model to obtain the model output result; if the matching degree of the model output result and the label result in the verification set is within a set range, it means that the trained first data analysis model passes the verification of the verification set, and the trained first data analysis model is recorded as the teacher model.

[0065] Continuing with the above description, if the matching degree between the model output result and the label result in the verification set is not within the set range, it means that the trained first data analysis model has not passed the verification of the verification set; then continue to train the first data analysis model until the trained first data analysis model passes the verification of the verification set.

[0066] S260. Use the second data analysis model as the model to be updated, update the model to be updated according to the teacher model, record the updated model to be updated as the second data analysis model, and integrate the second data analysis model into the database.

[0067] In this embodiment, the model to be updated can be understood as a data analysis model that needs to be updated; the teacher model is a data analysis model that has passed the verification of the verification set.

[0068] In this embodiment, the model to be updated is updated according to the data analysis model that has passed the verification set verification, which can achieve effective update of the data analysis model and simplify the update logic of the model. And the updated model to be updated is recorded as the second data analysis model, and the second data analysis model is integrated into the database, so that the second data analysis model can be applied to the analysis of dynamically changing business data in the database, thereby improving the accuracy of data analysis.

[0069] Optionally, in this embodiment, one implementation method of updating the model to be updated according to the teacher model can be described as the following steps:

[0070] a1) Input the data of the prediction set in the sample data set into the teacher model to obtain the model prediction results.

[0071] In this embodiment, the model prediction result can be understood as the prediction label result output by the teacher model; the data in the prediction set is input into the teacher model verified by the verification set, and the prediction label result is output.

[0072] b1) Reversely train the model to be updated according to the model prediction results until the matching degree between the output result of the model to be updated and the model prediction result is greater than a set threshold.

[0073] In this embodiment, the output result of the model to be updated can be understood as the label result outputted by inputting the data of the prediction set in the sample data set into the model to be updated; the set threshold can be a pre-set value.

[0074] In this embodiment, for reverse training of the model to be updated based on the model prediction results, one implementation method can be described as: determining the loss function based on the model prediction results and the output results of the model to be updated; reversely adjusting the network parameters in the model to be updated based on the loss function until the matching degree between the output results of the model to be updated and the model prediction results is greater than the set threshold, indicating that the model to be updated has been updated. At this time, the updated model to be updated is recorded as the second data analysis model, and is integrated into the database to realize the analysis of business data in the database.

[0075] Further, in this embodiment, another implementation method of updating the model to be updated according to the teacher model can also be described as the following steps:

[0076] a2) Serialize the teacher model and the model to be updated to obtain the first data matrix and the second data matrix respectively.

[0077] In this embodiment, the first data matrix can be understood as the result obtained after the teacher model is serialized; the second data matrix can be understood as the result obtained after the model to be updated is serialized. Among them, the first data matrix contains the network parameters of the teacher model, and the second data matrix contains the network parameters of the model to be updated. In this embodiment, serializing the teacher model and the model to be updated, and obtaining the first data matrix and the second data matrix respectively can be regarded as the process of obtaining the network parameters in the teacher model and the model to be updated.

[0078] b2) fusing the first data matrix and the second data matrix to obtain a third data matrix.

[0079] In this embodiment, the third data matrix can be understood as a data matrix obtained by fusing the first data matrix and the second data matrix. Optionally, the first data matrix and the second data matrix can be fused by multiplying the two data matrices or by other fusion methods, which are not limited here.

[0080] c2) Deserialize the third data matrix, and use the obtained deserialized model as the updated model to be updated.

[0081] In this embodiment, deserialization can be regarded as the inverse operation of serialization; the deserialization model can be understood as the model obtained after the deserialization operation is performed on the third data matrix.

[0082] In this embodiment, the third data matrix is ​​deserialized to obtain a deserialized model, and the deserialized model is used as the updated model to be updated. At this time, the deserialized model can be recorded as the second data analysis model, and the second data analysis model can be integrated into the database.

[0083] The technical solution of this embodiment is as follows: when it is detected that the model update condition is currently met, the incremental data set updated to the database within a set time interval is extracted according to the timestamp of the data stored in the database; according to the set query statement, the sub-incremental data set that meets the query condition is filtered from the incremental data set; the data in the sub-incremental data set is divided into a training set, a verification set and a prediction set to form a sample data set; a preset first data analysis model and a second data analysis model integrated in the database are obtained; the first data analysis model is trained using the data in the training set in the sample data set, and the first data analysis model verified by the verification set in the sample data set is recorded as a teacher model; the second data analysis model is used as the model to be updated, and the model to be updated is updated according to the teacher model, and the updated model to be updated is recorded as the second data analysis model, and the second data analysis model is integrated into the database. The above technical solution considers determining the incremental data set updated to the database based on the timestamp, which can quickly locate which data in the database belongs to the updated data; and uses query statements to filter out data that meets the query conditions, which can improve query efficiency; it also considers training the first data analysis model and using the verification set to verify the trained first data analysis model, which improves the accuracy of the data analysis model; finally, it considers using the teacher model to update the model to be updated, which can achieve effective update of the data analysis model and simplify the update logic of the model. The technical solution provided by this embodiment can improve the accuracy of the data analysis model, achieve effective update of the data analysis model, and simplify the update logic of the data analysis model, so that the data analysis model can play a better analysis role in specific application scenarios.

[0084] Embodiment 3

[0085] Figure 3 A schematic diagram of the structure of a database management device provided in Embodiment 3 of the present invention is shown in FIG. Figure 3 As shown, the device comprises:

[0086] The sample set determination module 310 is used to determine the sample data set based on the updated data of the database within a set time interval when it is detected that the model update condition is currently met;

[0087] A model acquisition module 320, used to acquire a preset first data analysis model and a second data analysis model integrated in a database, wherein the network layers and network parameters included in the first data analysis model are less than those in the second data analysis model;

[0088] The model updating module 330 is used to train the first data analysis model using the sample data set, and to update the second data analysis model using the trained first data analysis model, and to integrate the updated second data analysis model into the database.

[0089] Optionally, the sample set determination module 310 may be specifically configured to:

[0090] When it is detected that the model update conditions are currently met, the incremental data set updated to the database within the set time interval is extracted according to the timestamp of the data stored in the database; according to the set query statement, the sub-incremental data set that meets the query conditions is filtered from the incremental data set; the data in the sub-incremental data set is divided into a training set, a validation set, and a prediction set to form a sample data set.

[0091] Optionally, the model updating module 330 may specifically include:

[0092] A first updating unit, configured to train a first data analysis model using data in a training set in the sample data set, and record the first data analysis model verified by a verification set in the sample data set as a teacher model;

[0093] The second updating unit is used to take the second data analysis model as the model to be updated, update the model to be updated according to the teacher model, and record the updated model to be updated as the second data analysis model.

[0094] Optionally, the second updating unit may be specifically used for:

[0095] Using the second data analysis model as a model to be updated;

[0096] Input the data of the prediction set in the sample data set into the teacher model to obtain the model prediction results;

[0097] Reversely train the model to be updated according to the model prediction results until the matching degree between the output result of the model to be updated and the model prediction result is greater than the set threshold;

[0098] The updated model to be updated is recorded as the second data analysis model.

[0099] Optionally, the second updating unit may be further used for:

[0100] Using the second data analysis model as a model to be updated;

[0101] Serializing the teacher model and the model to be updated to obtain a first data matrix and a second data matrix respectively;

[0102] Performing fusion processing on the first data matrix and the second data matrix to obtain a third data matrix;

[0103] Deserializing the third data matrix, and using the obtained deserialized model as the updated model to be updated;

[0104] The updated model to be updated is recorded as the second data analysis model.

[0105] Optionally, the model update condition may be: monitoring that there is data update in the database within a set time interval; and / or, the second data analysis model fails to pass the model verification;

[0106] Based on the above optimization, the device may further include: an update verification module, which may be used to:

[0107] inputting the data in the prediction data set into a second data analysis model;

[0108] If the matching degree between the model output result and the preset label result is within the set range, it is determined that the model verification has been passed; otherwise, it is determined that the model verification has not been passed.

[0109] Optionally, the initial models of the first data analysis model and the second data analysis model are pre-trained based on historical data sets in the database.

[0110] The above device can execute the methods provided by all the above embodiments of the present invention, and has the corresponding functional modules and beneficial effects of executing the above methods. For technical details not described in detail in this embodiment, please refer to the methods provided by all the above embodiments of the present invention.

[0111] Embodiment 4

[0112] Figure 4 A schematic diagram of the structure of an electronic device 10 that can be used to implement an embodiment of the present invention 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 (such as helmets, glasses, watches, etc.) 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 invention described and / or required herein.

[0113] like Figure 4As shown, the electronic device 10 includes at least one processor 11, and a memory connected to the at least one processor 11, such as a read-only memory (ROM) 12, a random access memory (RAM) 13, etc., wherein the memory stores a computer program that can be executed by at least one processor, and the processor 11 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 12 or the computer program loaded from the storage unit 18 to the random access memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the electronic device 10 can also be stored. The processor 11, the ROM 12, and the RAM 13 are connected to each other through a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.

[0114] A number of components in the electronic device 10 are connected to the I / O interface 15, including: an input unit 16, such as a keyboard, a mouse, etc.; an output unit 17, such as various types of displays, speakers, etc.; a storage unit 18, such as a disk, an optical disk, etc.; and a communication unit 19, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 19 allows the electronic device 10 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.

[0115] The processor 11 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The processor 11 executes the various methods and processes described above, such as a database management method.

[0116] In some embodiments, the database management method may be implemented as a computer program, which is tangibly contained in a computer-readable storage medium, such as a storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed on the electronic device 10 via the ROM 12 and / or the communication unit 19. When the computer program is loaded into the RAM 13 and executed by the processor 11, one or more steps of the database management method described above may be performed. Alternatively, in other embodiments, the processor 11 may be configured to execute the database management method in any other appropriate manner (e.g., by means of firmware).

[0117] 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.

[0118] Computer programs for implementing the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that when the computer program is executed by the processor, the functions / operations specified in the flow chart and / or block diagram are implemented. The computer program 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.

[0119] In the context of the present invention, a computer-readable storage medium may be a tangible medium that may contain or store a computer program for use by or in combination with an instruction execution system, device or equipment. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or equipment, or any suitable combination of the foregoing. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. 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.

[0120] To provide interaction with a user, the systems and techniques described herein may be implemented on an electronic device 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 a pointing device (e.g., a mouse or trackball) through which the user can provide input to the electronic device. Other types of devices may also be used to provide interaction with the user; for example, the feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form (including acoustic input, voice input, or tactile input).

[0121] The systems and techniques described herein may be implemented in a computing system that includes backend 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 frontend 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 backend components, middleware components, or frontend 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), a blockchain network, and the Internet.

[0122] A computing 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 client and server relationship is generated by computer programs running on the corresponding computers and having a client-server relationship with each other. The server may be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system to solve the defects of difficult management and weak business scalability in traditional physical hosts and VPS services.

[0123] 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 described in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution of the present invention can be achieved, and this document does not limit this.

[0124] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims

1. A database management method, characterized in that: include: When it is detected that the model update condition is currently met, a sample data set is determined based on the updated data of the database within a set time interval; Acquire a preset first data analysis model and a second data analysis model integrated in the database, wherein the first data analysis model includes fewer network layers and network parameters than the second data analysis model; The sample data set is used to train a first data analysis model, and the trained first data analysis model is used to update the second data analysis model, and the updated second data analysis model is integrated into the database.

2. The method according to claim 1, characterized in that The sample data set is determined based on the updated data of the database within a set time interval, including: Extracting, according to the timestamps of the data stored in the database, the incremental data set updated to the database within the set time interval; According to the set query statement, the sub-incremental data set that meets the query condition is filtered from the incremental data set; The data in the sub-incremental data set is divided into a training set, a validation set and a prediction set to form the sample data set.

3. The method according to claim 1, characterized in that The adopting the sample data set to train the first data analysis model, and adopting the trained first data analysis model to update the second data analysis model, comprises: Using the data in the training set in the sample data set to train the first data analysis model, and recording the first data analysis model verified by the verification set in the sample data set as a teacher model; The second data analysis model is used as the model to be updated, the model to be updated is updated according to the teacher model, and the updated model to be updated is recorded as the second data analysis model.

4. The method according to claim 3, characterized in that: The updating of the model to be updated according to the teacher model comprises: Inputting the data of the prediction set in the sample data set into the teacher model to obtain the model prediction result; The model to be updated is reversely trained according to the model prediction result until the matching degree between the output result of the model to be updated and the model prediction result is greater than a set threshold.

5. The method according to claim 3, characterized in that: The updating of the model to be updated according to the teacher model comprises: Serializing the teacher model and the model to be updated to obtain a first data matrix and a second data matrix respectively; Performing fusion processing on the first data matrix and the second data matrix to obtain a third data matrix; The third data matrix is ​​deserialized, and the obtained deserialized model is used as the updated model to be updated.

6. The method according to any one of claims 1 to 5, characterized in that: The model update condition is: monitoring that the database has data updates within a set time interval; and / or the second data analysis model fails to pass model verification; The model verification step includes: inputting the data in the prediction data set into the second data analysis model; If the matching degree between the model output result and the preset label result is within a set range, it is determined that the model verification has been passed; otherwise, it is determined that the model verification has not been passed.

7. The method according to any one of claims 1 to 5, characterized in that: The initial models of the first data analysis model and the second data analysis model are pre-trained based on the historical data sets in the database.

8. A database management device, characterized in that: include: A sample set determination module is used to determine a sample data set based on the updated data of the database within a set time interval when it is detected that the model update condition is currently met; A model acquisition module, used to acquire a preset first data analysis model and a second data analysis model integrated in the database, wherein the network layers and network parameters included in the first data analysis model are less than those in the second data analysis model; A model updating module is used to train a first data analysis model using the sample data set, and to update the second data analysis model using the trained first data analysis model, and to integrate the updated second data analysis model into the database.

9. An electronic device, characterized in that: The electronic device comprises: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the database management method according to any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the database management method according to any one of claims 1 to 7 when executed.

Citation Information

Cited By

  • Open-Source Based AI Experiment Automation System

    KR103010393B1