CN113806624B - Data processing method and device - Google Patents

Data processing method and device Download PDF

Info

Publication number
CN113806624B
CN113806624B CN202010543594.6A CN202010543594A CN113806624B CN 113806624 B CN113806624 B CN 113806624B CN 202010543594 A CN202010543594 A CN 202010543594A CN 113806624 B CN113806624 B CN 113806624B
Authority
CN
China
Prior art keywords
model
target
training
prediction model
image file
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010543594.6A
Other languages
Chinese (zh)
Other versions
CN113806624A (en
Inventor
于士袁
赵宇
李明浩
骆卫华
龙旺钦
施杨斌
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN202010543594.6A priority Critical patent/CN113806624B/en
Publication of CN113806624A publication Critical patent/CN113806624A/en
Application granted granted Critical
Publication of CN113806624B publication Critical patent/CN113806624B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9535Search customisation based on user profiles and personalisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/958Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The embodiment of the specification provides a data processing method and a device, wherein the data processing method comprises the following steps: determining a task flow according to the received model construction request, starting a model construction node in the task flow based on the model construction request, and constructing an initial prediction model; under the condition that the construction is completed, triggering a model training node of the task flow, and training the initial prediction model through a first thread according to sample data carried in the model construction request; based on the execution of the training, triggering a polling task node of the task flow, and polling the training progress of the initial prediction model through a second thread according to a preset polling mechanism; and under the condition that the initial prediction model is determined to be trained according to the polling result, triggering a model release node, constructing a target service image file based on a preset basic frame image file and a target training model obtained by training, and releasing the target service image file.

Description

Data processing method and device
Technical Field
The embodiment of the specification relates to the technical field of machine learning, in particular to a data processing method. One or more embodiments of the present specification also relate to a data processing apparatus, a computing device, and a computer-readable storage medium.
Background
Along with the development of science and technology, the intellectualization is a current development trend, the intellectualization is based on the automatic processing of data, and the automatic processing of data is not separated from various data processing models. Therefore, the deep learning technology is widely applied in many fields, such as the fields of computer vision, image processing, natural language processing, information classification, searching, recommendation, big data and the like, and plays a great pushing role.
Many network platforms have proposed deep neural network algorithm-based recommendation and search services, which are typically implemented by incorporating deep learning models into the network platform, which require training by technicians and publishing to the platform for use by users.
However, when model release is performed on a network platform, a fully manual or semi-automatic mode is often adopted, and the release process has high labor cost, poor real-time performance and low time consumption, so that a method is needed to solve the problems.
Disclosure of Invention
In view of this, the present embodiments provide a data processing method. One or more embodiments of the present specification are also directed to a data processing apparatus, a computing device, and a computer-readable storage medium, which address the technical deficiencies of the prior art.
According to a first aspect of embodiments of the present specification, there is provided a data processing method, including:
determining a task flow according to the received model construction request, starting a model construction node in the task flow based on the model construction request, and constructing an initial prediction model;
under the condition that the construction is completed, triggering a model training node of the task flow, and training the initial prediction model through a first thread according to sample data carried in the model construction request;
based on the execution of the training, triggering a polling task node of the task flow, and polling the training progress of the initial prediction model through a second thread according to a preset polling mechanism;
and under the condition that the initial prediction model is determined to be trained according to the polling result, triggering a model release node, constructing a target service image file based on a preset basic frame image file and a target training model obtained by training, and releasing the target service image file.
Optionally, the training, by the first thread, the initial prediction model according to the sample data carried in the model building request includes:
creating a model training task by the first thread based on the sample data;
Submitting the model training task to a target platform to enable the target platform to train the initial predictive model according to the sample data.
Optionally, before the step of constructing the target service image file based on the preset basic frame image file and the target training model obtained by training and publishing the target service image file is executed, the method further includes:
judging whether the target prediction model meets a release condition or not;
if yes, executing the step of constructing and publishing the target service image file based on the preset basic framework image file and the target training model obtained through training.
Optionally, the building and publishing the target service image file based on the preset basic framework image file and the target training model obtained by training includes:
obtaining a deep learning basic framework image file pre-stored in an image file warehouse, wherein the target training model is obtained based on deep learning basic framework pre-training;
constructing a target service image file based on the basic framework image file and the target training model;
and publishing the target training model to a target platform based on the target service image file.
Optionally, the publishing the target training model to the target platform based on the target service image file includes:
Creating a model release task based on the target service image file, wherein the model release task at least comprises a model name, path information and version number of the target prediction model;
submitting the model release task to the target platform; and the target platform generates target services through a deployment container based on the target service image file.
Optionally, the publishing the target training model to the target platform based on the target service image file includes:
pushing the target service image file to an image file warehouse; and the target platform pulls the target service image file from the image file warehouse, and generates the target service by adopting a deployment container based on the target service image file.
Optionally, the determining whether the target prediction model meets the release condition includes:
detecting whether a model automatic issuing instruction of the target prediction model exists or not;
and if so, determining that the target prediction model meets the release condition.
Optionally, if the target prediction model obtained by the judgment training meets the execution result of the release condition step, executing the following operations:
Sending prompt information of model training completion to a user and updating the model release state of the target prediction model to be released;
generating a model release page based on the state to be released of the target prediction model and displaying the model release page;
receiving touch click operation of the user on the model release page;
and under the condition that the model issuing instruction submitted by the user through the model issuing page is detected, executing the step of constructing and issuing a target service image file based on the preset basic framework image file and the target training model obtained through training.
Optionally, after the step of building the target service image file based on the preset basic frame image file and the target training model obtained by training and publishing the target service image file is executed, the method further includes:
polling task nodes of the task flow are triggered based on the issued execution, and the issuing progress of the target prediction model is polled according to a preset polling mechanism;
under the condition that the object prediction model is successfully released according to the polling result, modifying the release state of the object prediction model into release success, and sending prompt information of release success to the user.
Optionally, after the building and publishing of the target service image file based on the preset basic framework image file and the target training model obtained by training, the method further includes:
receiving an index prediction request submitted by a user, wherein the index prediction request carries prediction data related to an index to be predicted;
and inputting the prediction data into the target prediction model, obtaining a prediction result of the index to be predicted, which is output by the target prediction model, and feeding back the prediction result to the user.
Optionally, the container is deployed based on Kubernetes.
According to a second aspect of embodiments of the present specification, there is provided a data processing apparatus comprising:
the construction module is configured to determine a task flow according to the received model construction request, and start a model construction node in the task flow based on the model construction request to construct an initial prediction model;
the training module is configured to trigger a model training node of the task flow under the condition that construction is completed, and train the initial prediction model through a first thread according to sample data carried in the model construction request;
the training module is configured to trigger a polling task node of the task flow based on the execution of the training, and poll the training progress of the initial prediction model through a second thread according to a preset polling mechanism;
And the release module is configured to trigger a model release node to construct and release a target service image file based on a preset basic frame image file and a target training model obtained by training under the condition that the initial prediction model is determined to be trained according to a polling result.
According to a third aspect of embodiments of the present specification, there is provided a computing device comprising:
a memory and a processor;
the memory is for storing computer-executable instructions, and the processor is for executing the computer-executable instructions:
determining a task flow according to the received model construction request, starting a model construction node in the task flow based on the model construction request, and constructing an initial prediction model;
under the condition that the construction is completed, triggering a model training node of the task flow, and training the initial prediction model through a first thread according to sample data carried in the model construction request;
based on the execution of the training, triggering a polling task node of the task flow, and polling the training progress of the initial prediction model through a second thread according to a preset polling mechanism;
and under the condition that the initial prediction model is determined to be trained according to the polling result, triggering a model release node, constructing a target service image file based on a preset basic frame image file and a target training model obtained by training, and releasing the target service image file.
According to a fourth aspect of embodiments of the present description, there is provided a computer-readable storage medium storing computer-executable instructions which, when executed by a processor, implement the steps of the data processing method.
According to one embodiment of the specification, a task flow is determined according to a received model construction request, a model construction node in the task flow is started based on the model construction request, an initial prediction model is constructed, a model training node of the task flow is triggered under the condition that construction is completed, the initial prediction model is trained through a first thread according to sample data carried in the model construction request, a task polling node of the task flow is triggered based on execution of training, the training progress of the initial prediction model is polled through a second thread according to a preset polling mechanism, a model issuing node is triggered under the condition that training of the initial prediction model is determined to be completed according to a polling result, and a target service image file is constructed and issued based on a preset basic frame image file and a target training model obtained through training;
after receiving a model creation request, a task flow is started, a model construction node and a model training node in the task flow are used for respectively constructing and training a model, a polling task node in the task flow is used for polling the training progress of the initial prediction model, and under the condition that the training of the initial prediction model is completed, a model release node can be used for automatically releasing a target prediction model obtained through training, on one hand, the operation flow of a user is simplified in a task flow mode, the convenience of the algorithm for self-learning platform is improved, on the other hand, when the training time of the model is long, the automatic release model is beneficial to improving the release efficiency of the model, so that the time for obtaining available services of the user is shortened, and the service experience of the user is improved.
Drawings
FIG. 1 is a process flow diagram of a data processing method provided in one embodiment of the present disclosure;
FIG. 2 is a process flow diagram of a data processing method according to one embodiment of the present disclosure;
FIG. 3 is a schematic diagram of a data processing apparatus according to one embodiment of the present disclosure;
FIG. 4 is a block diagram of a computing device provided in one embodiment of the present description.
Detailed Description
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present description. This description may be embodied in many other forms than described herein and similarly generalized by those skilled in the art to whom this disclosure pertains without departing from the spirit of the disclosure and, therefore, this disclosure is not limited by the specific implementations disclosed below.
The terminology used in the one or more embodiments of the specification is for the purpose of describing particular embodiments only and is not intended to be limiting of the one or more embodiments of the specification. As used in this specification, one or more embodiments and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used in one or more embodiments of the present specification refers to and encompasses any or all possible combinations of one or more of the associated listed items.
It should be understood that, although the terms first, second, etc. may be used in one or more embodiments of this specification to describe various information, these information should not be limited by these terms. These terms are only used to distinguish one type of information from another. For example, a first may also be referred to as a second, and similarly, a second may also be referred to as a first, without departing from the scope of one or more embodiments of the present description. The word "if" as used herein may be interpreted as "at … …" or "at … …" or "responsive to a determination", depending on the context.
First, terms related to one or more embodiments of the present specification will be explained.
Algorithm self-learning platform: a platform integrating various types of algorithm capabilities and providing model creation and release iteration and data annotation capabilities is provided, a user can select an algorithm model required by the user on the platform by himself, and the model of the release iteration is created so as to obtain the prediction capability of the model.
Task flow: and the task group is formed by arranging one or more tasks, so that the dependency relationship among the tasks is realized.
And (3) automatically releasing a model: model release is an important link in an algorithm self-learning platform, and automatic release refers to a system action of completing model release without human participation in a release process.
In the present specification, a data processing method is provided, and the present specification relates to a data processing apparatus, a computing device, and a computer-readable storage medium, which are described in detail in the following embodiments one by one.
Fig. 1 shows a process flow diagram of a data processing method according to one embodiment of the present disclosure, including steps 102 to 108.
Step 102, determining a task flow according to the received model construction request, starting a model construction node in the task flow based on the model construction request, and constructing an initial prediction model.
With the development of scientific technology, deep learning technology is widely applied in many fields, such as computer vision, image processing, natural language processing, information classification, searching, recommendation, big data and the like, and plays a great pushing role. Therefore, many network platforms have proposed recommendation and search services based on deep neural network algorithms, and the recommendation and search services are usually implemented by embedding deep learning models in the network platforms, and the models need to be trained by technicians and released to the platforms for users to use.
Based on this, the data processing method provided in the embodiments of the present disclosure is applied to an algorithm self-learning Xi Ping platform (NLP self-learning platform), after receiving a model creation request, a task flow is started, a model is respectively constructed and trained by a model construction node and a model training node in the task flow, and the training progress of the initial prediction model is polled by a polling task node in the task flow.
Specifically, the task flow is a task group formed by arranging one or more tasks, so as to realize the dependency relationship among the tasks, or the task flow can be understood as a process for solving the problem, and is composed of task nodes, wherein each task node is used for solving one link of the target problem. In the embodiment of the present disclosure, the task flow for publishing the model may include 5 task nodes, which are respectively a model building node (for building an initial prediction model), a model training node (for training the initial prediction model), a task polling node (for polling the training progress of the initial prediction model), a model publishing node (for publishing a target prediction model obtained by training), and a model publishing progress polling node (for polling the publishing progress of the target prediction model).
After receiving the model building request, a task flow matched with the model building request can be determined first, and model building nodes in the task flow are started to build an initial prediction model.
In practical application, a user can submit a model construction request through an interface provided by an NLP self-learning platform, and the NLP self-learning platform performs subsequent operations such as model construction, model training, model release and the like; firstly, a user can create target services, such as text classification, short text matching, commodity evaluation analysis and the like, on the NLP self-learning platform; after creating the target service, data management can be performed through the NLP self-learning platform, namely, a user can upload the pre-collected marking data on the platform, or upload the data to be marked to the NLP self-learning platform, and perform data marking through the platform; after the data management is completed, the model management can be performed, including the construction of a model, the training of the model, the release of the model and the like, wherein a user can input model basic information on a creation model page and select labeling data for model training.
And 104, triggering a model training node of the task flow under the condition that the construction is completed, and training the initial prediction model through a first thread according to sample data carried in the model construction request.
Specifically, the thread refers to an execution flow in a task flow, each thread executes different tasks, and multiple threads can execute in parallel, where the task flow includes 5 task nodes, as described above, and when the model building node completes the initial prediction model building, the model training node can be triggered to train the initial prediction model through the first thread.
After the initial prediction model is built, training the initial prediction model based on sample data carried in the model building request, in practical application, after entering the model creation, selecting a corresponding model (inputting a model name), and adding marked data as sample data to perform model training. In the training process of the model, a model detail page can be entered to check a training log and specific evaluation indexes.
In addition, the initial prediction model can be trained through Kubernetes, which is called K8s for short, is an open source and is used for managing containerized applications on a plurality of hosts in a cloud platform, the purpose of Kubernetes is to enable the containerized applications to be deployed simply and efficiently, and the Kubernetes provides a mechanism for application deployment, planning, updating and maintenance.
In specific implementation, the initial prediction model is trained through Kubernetes, and the training can be realized in the following way:
creating a model training task by the first thread based on the sample data;
submitting the model training task to a target platform to enable the target platform to train the initial predictive model according to the sample data.
Specifically, after the initial prediction model is constructed, a model training task may be created based on sample data carried in a model construction request and the initial prediction model, and the model training task may be submitted to Kubernetes, where the model training task is executed by Kubernetes, that is, the initial prediction model is trained based on the sample data.
And step 106, based on the execution of the training, triggering a polling task node of the task flow, and polling the training progress of the initial prediction model through a second thread according to a preset polling mechanism.
Specifically, as described above, the thread refers to an execution flow in a task flow, each thread performs a different task, and multiple threads may be executed in parallel, so while the initial prediction model is trained by the first thread, an asynchronous polling node may be triggered based on the execution of training to asynchronously detect the training progress of the initial prediction model by the second thread.
In practical application, the preset polling mechanism polls repeatedly according to a preset time period, wherein the preset time period can be determined according to the training time of the model, or can be reasonably set according to practical service experience under the condition that the training time of the model cannot be determined, and the specific preset time period can be determined according to practical requirements without any limitation.
And step 108, triggering a model release node to construct and release a target service image file based on a preset basic frame image file and a target training model obtained by training under the condition that the initial prediction model is determined to be trained according to a polling result.
Specifically, the polling task node is used for polling the training result of the initial prediction model, after the polling task node is triggered, the node periodically polls the training progress of the initial prediction model according to a preset duration, and if the training progress of the initial prediction model is determined to be training completion according to the polling result, the polling is stopped, and the model release node is triggered to release the model.
If the model training task is executed by the Kubernetes, determining the training progress of the initial prediction model as training completion under the condition that the execution of the model training task is completed; alternatively, the training progress of the initial prediction model can be determined according to the model state of the initial prediction model, and in the case that training is completed, the state of the initial prediction model is updated to be that training is completed.
Further, under the condition that the training progress of the initial prediction model is determined to be training completion according to the polling result, whether the target prediction model obtained through training meets the model release condition or not is also required to be judged, and under the condition that the target prediction model is determined to meet the model release condition, the target prediction model is released.
In practical application, whether the target prediction model meets the release condition can be determined by determining whether there is an automatic release instruction of the model of the target prediction model, if yes, the target prediction is determinedThe model meets the model release condition; wherein the model automatic issuing instruction can be submitted by a user while submitting a model construction request, or can be submitted while finishing model construction and starting training, if an initial prediction model is defined as M 0 The target prediction model is defined as M 1 Since the model issuing instruction is submitted while the model building request is submitted or while the model starts to be trained, the target training model M does not exist at the moment of submitting the model issuing instruction 1 Thus, it can be seen that the user trains the initial predictive model M for expectations 0 Obtained predictive model M X Automatic instruction issuing of submission model, expected prediction model M X Can include training the obtained target prediction model M 1
In addition, if the target prediction model obtained through training does not meet the release condition, namely, the model automatic release condition of the target prediction model does not exist, prompt information is sent to a user to prompt the user to release the target prediction model, and the method can be specifically realized by the following steps of:
sending prompt information of model training completion to a user and updating the model release state of the target prediction model to be released;
generating a model release page based on the state to be released of the target prediction model and displaying the model release page;
receiving touch click operation of the user on the model release page;
under the condition that a model issuing instruction submitted by the user through the model issuing page is detected, a target service image file is built and issued based on a preset basic frame image file and a target training model obtained through training.
Specifically, under the condition that the training progress of the initial prediction model is determined to be training completion according to the polling result, whether the target prediction model obtained through training meets the model release condition is further required to be judged, namely whether a model automatic release instruction of the target prediction model exists is detected, if the model automatic release instruction does not exist, namely the model automatic release instruction is not preset by a user, the target prediction model cannot be released automatically, and the model release instruction is required to be submitted by the user so as to trigger a model release node to release the model.
In practical application, when the training of the initial prediction model is completed, but the target prediction model obtained by training does not meet the release condition, prompt information of the completion of model training can be sent to a user, and the model release state of the target prediction model is updated to be released so as to generate a model release page based on the state to be released of the model, so that a model release instruction submitting interface (the model release page comprises a release instruction submitting control) is provided for the user through the model release page, and the user can submit the release instruction of the target prediction model by clicking the release instruction submitting control.
Under the condition that the model automatic issuing instruction of the target prediction model is not detected, the user is prompted to issue the model by sending prompt information of model training completion to the user, and the model issuing efficiency of the system is improved.
In specific implementation, the target service image file is constructed and issued based on the preset basic framework image file and the target training model obtained through training, and the method can be realized specifically by the following steps:
obtaining a deep learning basic framework image file pre-stored in an image file warehouse, wherein the target training model is obtained based on deep learning basic framework pre-training;
Constructing a target service image file based on the basic framework image file and the target training model;
and publishing the target training model to a target platform based on the target service image file.
Further, the publishing of the target training model to the target platform based on the target service image file may be further implemented by:
pushing the target service image file to an image file warehouse; and the target platform pulls the target service image file from the image file warehouse, and generates the target service by adopting a deployment container based on the target service image file.
Specifically, the container is deployed based on Kubernetes, the initial prediction model may be constructed based on a deep learning infrastructure, and thus, the target prediction model obtained by training the initial prediction model may be a prediction model obtained by training based on the deep learning infrastructure; and, the initial predictive model may be constructed by the user based on a deep learning infrastructure according to actual needs.
Under the condition that the training of the initial prediction model is completed, a target service mirror image can be constructed through a Dockerfile (a text file used for constructing the mirror image, the text content comprises a plurality of instructions and descriptions required for constructing the mirror image) based on a preset deep learning basic frame mirror image and a target prediction model obtained through training, the target service mirror image is pushed to a mirror image warehouse, when a target platform issues the target prediction model, the target service mirror image file is pulled from the mirror image file warehouse, and a deployment container is adopted to generate the target service based on the target service mirror image file.
In order to improve the release efficiency, the Kubernetes can be adopted to automatically schedule the computing nodes and deploy containers to generate target services, so that after a target prediction model is obtained through training, the model is automatically released, and users do not need to manually construct and deploy to release the model, so that the time consumed by releasing the model is effectively reduced, and the release efficiency is improved.
In addition, the target training model is published to a target platform based on the target service image file, which can be realized specifically by the following ways:
creating a model release task based on the target service image file, wherein the model release task at least comprises a model name, path information and version number of the target prediction model;
submitting the model release task to the target platform; and the target platform generates target services through a deployment container based on the target service image file.
Specifically, the target platform may be Kubernetes, and when the target prediction model is obtained through training and it is determined that the target prediction model meets the release condition, a model release task may be created based on a target service image file, where the model release task includes at least a model name, path information and version number of the target prediction model, and the model release task is submitted to Kubernetes, and the Kubernetes executes the model release task, that is, based on the target service image file, to generate a target service through a deployment container.
Further, after the target service image file is constructed and issued based on the preset basic framework image file and the target training model obtained through training, the issuing progress of the asynchronous polling model can be further performed, and under the condition that the issuing is successful, related prompt information is sent to the user, and the method can be specifically realized by the following steps of:
polling task nodes of the task flow are triggered based on the issued execution, and the issuing progress of the target prediction model is polled according to a preset polling mechanism;
under the condition that the object prediction model is successfully released according to the polling result, modifying the release state of the object prediction model into release success, and sending prompt information of release success to the user.
Specifically, as previously described, each thread performs a different task, and multiple threads may execute in parallel, so that while the target prediction model is published by one thread, an asynchronous polling node may be triggered based on the execution of model publication to asynchronously detect the publication progress of the target prediction model by another thread.
In practical application, the preset polling mechanism polls repeatedly according to a preset time period, wherein the preset time period can be determined according to the time required by the model release completion, or can be reasonably set according to practical service experience under the condition that the time required by the model release cannot be determined, and the specific preset time period can be determined according to practical requirements without any limitation.
If the model release task is executed by the Kubernetes, the release progress of the target prediction model can be determined to be release success under the condition that the execution of the model release task is completed.
After the model is successfully released, prediction service can be provided for the user, so that after the model is successfully released, prompt information of the success release can be sent to the user, and the prediction service can be provided for the user in time.
In addition, after the target service image file is constructed and issued based on the preset basic frame image file and the target training model obtained by training, the target prediction model can provide prediction service for the user, and the method can be realized specifically by the following steps:
receiving an index prediction request submitted by a user, wherein the index prediction request carries prediction data related to an index to be predicted;
and inputting the prediction data into the target prediction model, obtaining a prediction result of the index to be predicted, which is output by the target prediction model, and feeding back the prediction result to the user.
Specifically, after the model is successfully released, prediction service can be provided for a user, after the user submits an index prediction request, prediction data carried in the index prediction request can be input into the target prediction model to obtain a prediction result of an index to be predicted, which is output by the target prediction model, and the prediction result is sent to the user.
According to one embodiment of the specification, a task flow is determined according to a received model construction request, a model construction node in the task flow is started based on the model construction request, an initial prediction model is constructed, a model training node of the task flow is triggered under the condition that construction is completed, the initial prediction model is trained through a first thread according to sample data carried in the model construction request, a task polling node of the task flow is triggered based on execution of training, the training progress of the initial prediction model is polled through a second thread according to a preset polling mechanism, a model issuing node is triggered under the condition that training of the initial prediction model is determined to be completed according to a polling result, and a target service image file is constructed and issued based on a preset basic frame image file and a target training model obtained through training;
after receiving a model creation request, a task flow is started, a model construction node and a model training node in the task flow are used for respectively constructing and training a model, a polling task node in the task flow is used for polling the training progress of the initial prediction model, and under the condition that the training of the initial prediction model is completed, a model release node can be used for automatically releasing a target prediction model obtained through training, on one hand, the operation flow of a user is simplified in a task flow mode, the convenience of the algorithm for self-learning platform is improved, on the other hand, when the training time of the model is long, the automatic release model is beneficial to improving the release efficiency of the model, so that the time for obtaining available services of the user is shortened, and the service experience of the user is improved.
The application of the data processing method provided in the present specification in an actual scenario is taken as an example, with reference to fig. 2, to further describe the data processing method. Fig. 2 is a flowchart of a processing procedure of a data processing method according to an embodiment of the present disclosure, and specific steps include steps 202 to 222.
Step 202, a model building request is received.
Specifically, a user can submit a model construction request through a data transmission interface of the NLP self-learning platform, and upload pre-acquired sample data through the data transmission interface.
Step 204, the workflow is started.
Specifically, the workflow is a task group formed by arranging one or more tasks, so as to realize the dependency relationship among the tasks, or the workflow can be understood as a process for solving the problem, and is composed of task nodes, wherein each task node is used for solving one link of the target problem. The workflow of the embodiment of the present disclosure may include 5 task nodes, which are respectively a model building node, a model training node, a polling task node, a model publishing node, and a model publishing progress polling node.
And 206, constructing an initial prediction model.
Specifically, after receiving the model building request, a workflow matched with the model building request may be determined first, and model building nodes in the workflow may be started to build an initial prediction model.
Step 208, training the initial predictive model.
Specifically, under the condition that the initial prediction model is built, triggering a model training node of the workflow, and training the initial prediction model through a first thread according to sample data carried in the model building request.
Step 210, polling.
Specifically, a thread refers to one execution flow in a workflow, each thread performs a different task, and multiple threads may execute in parallel, so while the initial prediction model is trained by a first thread, an asynchronous polling node may be triggered based on the execution of the training to asynchronously poll the training progress of the initial prediction model by a second thread.
Step 212, judging whether the model is trained; if yes, go to step 214; if not, go to step 210.
Specifically, the polling task node is used for polling the training result of the initial prediction model, after the polling task node is triggered, the node repeatedly polls the training progress of the initial prediction model according to a preset time period, and under the condition that the training progress of the initial prediction model is determined to be training completion according to the polling result, the polling is stopped, and the model release node is triggered to release the model.
Step 214, it is determined whether the release condition is satisfied.
Specifically, under the condition that the training progress of the initial prediction model is determined to be training completion according to the polling result, whether the target prediction model obtained through training meets the model release condition is also required to be judged;
in practical application, whether the target prediction model meets the release condition can be determined by determining whether a model automatic release instruction of the target prediction model exists, and if so, the target prediction model is determined to meet the model release condition.
Step 216, release the model.
Specifically, under the condition that the target prediction model meets the model release condition, releasing the target prediction model, namely constructing and releasing a target service image file based on a preset basic framework image file and a target training model obtained through training.
Step 218, polling.
Specifically, after the target prediction model is released, the release progress of the model can be asynchronously polled.
Step 220, judging whether the model is issued successfully; if yes, go to step 222; if not, go to step 218.
Specifically, in the case that the target prediction model is determined to be successfully issued according to the polling result, step 222 may be performed.
Step 222, updating the model state to be successful in release, and sending prompt information of successful release to the user.
Specifically, after the model is successfully released, prediction service can be provided for the user, so that after the model is successfully released, prompt information of the success release can be sent to the user, and the prediction service can be provided for the user in time.
After receiving a model creation request, the embodiment of the specification starts a task flow, respectively builds and trains a model through a model building node and a model training node in the task flow, polls the training progress of the initial prediction model through a polling task node in the task flow, and can automatically release a target prediction model obtained through training through a model release node under the condition that the training of the initial prediction model is completed.
Corresponding to the above method embodiments, the present disclosure further provides an embodiment of a data processing apparatus, and fig. 3 shows a schematic diagram of a data processing apparatus provided in one embodiment of the present disclosure. As shown in fig. 3, the apparatus includes:
A building module 302 configured to determine a task flow according to a received model building request, and to start a model building node in the task flow based on the model building request, to build an initial prediction model;
the training module 304 is configured to trigger a model training node of the task flow to train the initial prediction model through a first thread according to sample data carried in the model construction request under the condition that construction is completed;
the training module 306 is configured to trigger a polling task node of the task flow based on the execution of the training, and poll the training progress of the initial prediction model through a second thread according to a preset polling mechanism;
the publishing module 308 is configured to trigger a model publishing node to construct and publish a target service image file based on a preset base frame image file and a target training model obtained by training, if the initial prediction model is determined to be trained according to the polling result.
Optionally, the training module 304 includes:
a task creation sub-module configured to create a model training task by the first thread based on the sample data;
A submitting sub-module configured to submit the model training task to a target platform to cause the target platform to train the initial predictive model in accordance with the sample data.
Optionally, the data processing apparatus further includes:
a judging module configured to judge whether the target prediction model satisfies a release condition;
if the execution result of the judging module is yes, the publishing module 308 is executed.
Optionally, the publishing module 308 includes:
the acquisition sub-module is configured to acquire a deep learning basic framework image file pre-stored in an image file warehouse, wherein the target training model is obtained based on deep learning basic framework pre-training;
a building sub-module configured to build a target service image file based on the base frame image file and the target training model;
and the issuing sub-module is configured to issue the target training model to a target platform based on the target service image file.
Optionally, the publishing sub-module includes:
a task creation unit configured to create a model issuing task based on the target service image file, wherein the model issuing task at least includes a model name, path information and version number of the target prediction model;
A task submitting unit configured to submit the model issuing task to the target platform; and the target platform generates target services through a deployment container based on the target service image file.
Optionally, the publishing sub-module includes:
the pushing unit is configured to push the target service image file to an image file warehouse; and the target platform pulls the target service image file from the image file warehouse, and generates the target service by adopting a deployment container based on the target service image file.
Optionally, the judging module includes:
a detection sub-module configured to detect whether there is a model auto-issue instruction for the target prediction model;
and if the operation result of the detection sub-module is that the target prediction model exists, determining that the target prediction model meets the release condition.
Optionally, the data processing apparatus further includes:
the state updating module is configured to send prompt information of model training completion to a user and update the model release state of the target prediction model to be released;
the display module is configured to generate a model release page based on the state to be released of the target prediction model and display the model release page;
The operation receiving module is configured to receive touch click operation of the user on the model release page;
the publishing module 308 is executed upon detecting a model publishing instruction submitted by the user via the model publishing page.
Optionally, the data processing apparatus further includes:
the issuing progress polling module is configured to trigger polling task nodes of the task flow based on the issued execution and poll the issuing progress of the target prediction model according to a preset polling mechanism;
and the information sending module is configured to modify the release state of the target prediction model into release success under the condition that the release success of the target prediction model is determined according to the polling result, and send prompt information of release success to the user.
Optionally, the data processing apparatus further includes:
the prediction request receiving module is configured to receive an index prediction request submitted by a user, wherein the index prediction request carries prediction data related to an index to be predicted;
and the prediction result feedback module is configured to input the prediction data into the target prediction model, acquire the prediction result of the to-be-predicted index output by the target prediction model and feed back the prediction result to the user.
Optionally, the container is deployed based on Kubernetes.
The above is a schematic solution of a data processing apparatus of the present embodiment. It should be noted that, the technical solution of the data processing apparatus and the technical solution of the data processing method belong to the same conception, and details of the technical solution of the data processing apparatus, which are not described in detail, can be referred to the description of the technical solution of the data processing method.
Fig. 4 illustrates a block diagram of a computing device 400 provided in accordance with one embodiment of the present description. The components of the computing device 400 include, but are not limited to, a memory 410 and a processor 420. Processor 420 is coupled to memory 410 via bus 430 and database 450 is used to hold data.
Computing device 400 also includes access device 440, access device 440 enabling computing device 400 to communicate via one or more networks 460. Examples of such networks include the Public Switched Telephone Network (PSTN), a Local Area Network (LAN), a Wide Area Network (WAN), a Personal Area Network (PAN), or a combination of communication networks such as the internet. The access device 440 may include one or more of any type of network interface, wired or wireless (e.g., a Network Interface Card (NIC)), such as an IEEE802.11 Wireless Local Area Network (WLAN) wireless interface, a worldwide interoperability for microwave access (Wi-MAX) interface, an ethernet interface, a Universal Serial Bus (USB) interface, a cellular network interface, a bluetooth interface, a Near Field Communication (NFC) interface, and so forth.
In one embodiment of the present description, the above-described components of computing device 400, as well as other components not shown in FIG. 4, may also be connected to each other, such as by a bus. It should be understood that the block diagram of the computing device shown in FIG. 4 is for exemplary purposes only and is not intended to limit the scope of the present description. Those skilled in the art may add or replace other components as desired.
Computing device 400 may be any type of stationary or mobile computing device, including a mobile computer or mobile computing device (e.g., tablet, personal digital assistant, laptop, notebook, netbook, etc.), mobile phone (e.g., smart phone), wearable computing device (e.g., smart watch, smart glasses, etc.), or other type of mobile device, or a stationary computing device such as a desktop computer or PC. Computing device 400 may also be a mobile or stationary server.
Wherein the memory 410 is configured to store computer-executable instructions and the processor 420 is configured to execute the following computer-executable instructions:
determining a task flow according to the received model construction request, starting a model construction node in the task flow based on the model construction request, and constructing an initial prediction model;
Under the condition that the construction is completed, triggering a model training node of the task flow, and training the initial prediction model through a first thread according to sample data carried in the model construction request;
based on the execution of the training, triggering a polling task node of the task flow, and polling the training progress of the initial prediction model through a second thread according to a preset polling mechanism;
and under the condition that the initial prediction model is determined to be trained according to the polling result, triggering a model release node, constructing a target service image file based on a preset basic frame image file and a target training model obtained by training, and releasing the target service image file.
The foregoing is a schematic illustration of a computing device of this embodiment. It should be noted that, the technical solution of the computing device and the technical solution of the data processing method belong to the same concept, and details of the technical solution of the computing device, which are not described in detail, can be referred to the description of the technical solution of the data processing method.
An embodiment of the present specification also provides a computer-readable storage medium storing computer instructions that, when executed by a processor, perform the steps of the data processing method.
The above is an exemplary version of a computer-readable storage medium of the present embodiment. It should be noted that, the technical solution of the storage medium and the technical solution of the data processing method belong to the same concept, and details of the technical solution of the storage medium which are not described in detail can be referred to the description of the technical solution of the data processing method.
The foregoing describes specific embodiments of the present disclosure. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims can be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
The computer instructions include computer program code that may be in source code form, object code form, executable file or some intermediate form, etc. The computer readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a U disk, a removable hard disk, a magnetic disk, an optical disk, a computer Memory, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), an electrical carrier signal, a telecommunications signal, a software distribution medium, and so forth. It should be noted that the computer readable medium contains content that can be appropriately scaled according to the requirements of jurisdictions in which such content is subject to legislation and patent practice, such as in certain jurisdictions in which such content is subject to legislation and patent practice, the computer readable medium does not include electrical carrier signals and telecommunication signals.
It should be noted that, for simplicity of description, the foregoing method embodiments are all expressed as a series of combinations of actions, but it should be understood by those skilled in the art that the embodiments are not limited by the order of actions described, as some steps may be performed in other order or simultaneously according to the embodiments of the present disclosure. Further, those skilled in the art will appreciate that the embodiments described in the specification are all preferred embodiments, and that the acts and modules referred to are not necessarily all required for the embodiments described in the specification.
In the foregoing embodiments, the descriptions of the embodiments are emphasized, and for parts of one embodiment that are not described in detail, reference may be made to the related descriptions of other embodiments.
The preferred embodiments of the present specification disclosed above are merely used to help clarify the present specification. Alternative embodiments are not intended to be exhaustive or to limit the invention to the precise form disclosed. Obviously, many modifications and variations are possible in light of the teaching of the embodiments. The embodiments were chosen and described in order to best explain the principles of the embodiments and the practical application, to thereby enable others skilled in the art to best understand and utilize the invention. This specification is to be limited only by the claims and the full scope and equivalents thereof.

Claims (13)

1. A data processing method, comprising:
determining a task flow according to the received model construction request, starting a model construction node in the task flow based on the model construction request, and constructing an initial prediction model;
under the condition that the construction is completed, triggering a model training node of the task flow, and training the initial prediction model through a first thread according to sample data carried in the model construction request;
based on the execution of the training, triggering a polling task node of the task flow, and polling the training progress of the initial prediction model through a second thread according to a preset polling mechanism;
under the condition that the initial prediction model training is determined to be completed according to the polling result, triggering a model release node to acquire a deep learning basic framework image file prestored in an image file warehouse,
constructing a target service image file based on the base frame image file and a target prediction model, wherein the target prediction model is obtained based on deep learning base frame pre-training,
and publishing the target prediction model to a target platform based on the target service image file.
2. The data processing method according to claim 1, wherein the training of the initial predictive model by the first thread according to the sample data carried in the model construction request includes:
Creating a model training task by the first thread based on the sample data;
submitting the model training task to a target platform to enable the target platform to train the initial predictive model according to the sample data.
3. The data processing method according to claim 1, wherein before the publishing the target prediction model to a target platform based on the target service image file, further comprising:
judging whether the target prediction model meets a release condition or not;
if yes, executing the deep learning basic framework image file pre-stored in the image file warehouse, and constructing a target service image file based on the basic framework image file and a target prediction model, wherein the target prediction model is obtained based on deep learning basic framework pre-training, and publishing the target prediction model to a target platform based on the target service image file.
4. The data processing method according to claim 3, wherein the publishing the target prediction model to the target platform based on the target service image file includes:
creating a model release task based on the target service image file, wherein the model release task at least comprises a model name, path information and version number of the target prediction model;
Submitting the model release task to the target platform; and the target platform generates target services through a deployment container based on the target service image file.
5. The data processing method according to claim 1, the publishing the target prediction model to the target platform based on the target service image file, comprising:
pushing the target service image file to an image file warehouse; and the target platform pulls the target service image file from the image file warehouse, and generates the target service by adopting a deployment container based on the target service image file.
6. A data processing method according to claim 3, said determining whether the target prediction model satisfies a release condition, comprising:
detecting whether a model automatic issuing instruction of the target prediction model exists or not;
and if so, determining that the target prediction model meets the release condition.
7. The data processing method according to claim 4, wherein if the target prediction model obtained by the judgment training satisfies the execution result of the release condition step is no, the following operations are executed:
sending prompt information of model training completion to a user and updating the model release state of the target prediction model to be released;
Generating a model release page based on the state to be released of the target prediction model and displaying the model release page;
receiving touch click operation of the user on the model release page;
and under the condition that a model issuing instruction submitted by the user through the model issuing page is detected, executing the deep learning basic framework image file pre-stored in the image file acquisition warehouse, and constructing a target service image file based on the basic framework image file and a target prediction model, wherein the target prediction model is obtained based on the deep learning basic framework pre-training, and issuing the target prediction model to a target platform based on the target service image file.
8. The data processing method according to claim 1, wherein after the publishing the target prediction model to a target platform based on the target service image file, further comprising:
polling task nodes of the task flow are triggered based on the issued execution, and the issuing progress of the target prediction model is polled according to a preset polling mechanism;
under the condition that the object prediction model is successfully released according to the polling result, modifying the release state of the object prediction model into release success, and sending prompt information of release success to a user.
9. The data processing method according to claim 8, wherein after the publishing the target prediction model to a target platform based on the target service image file, further comprising:
receiving an index prediction request submitted by a user, wherein the index prediction request carries prediction data related to an index to be predicted;
and inputting the prediction data into the target prediction model, obtaining a prediction result of the index to be predicted, which is output by the target prediction model, and feeding back the prediction result to the user.
10. The data processing method of claim 4 or 5, the container being based on a Kubernetes deployment.
11. A data processing apparatus comprising:
the construction module is configured to determine a task flow according to the received model construction request, and start a model construction node in the task flow based on the model construction request to construct an initial prediction model;
the training module is configured to trigger a model training node of the task flow under the condition that construction is completed, and train the initial prediction model through a first thread according to sample data carried in the model construction request;
the training module is configured to trigger a polling task node of the task flow based on the execution of the training, and poll the training progress of the initial prediction model through a second thread according to a preset polling mechanism;
The publishing module is configured to trigger a model publishing node to acquire a deep learning base frame image file pre-stored in an image file warehouse under the condition that the initial prediction model is determined to be trained according to a polling result, and construct a target service image file based on the base frame image file and a target prediction model, wherein the target prediction model is obtained based on the deep learning base frame pre-training, and publish the target prediction model to a target platform based on the target service image file.
12. A computing device, comprising:
a memory and a processor;
the memory is for storing computer-executable instructions, and the processor is for executing the computer-executable instructions:
determining a task flow according to the received model construction request, starting a model construction node in the task flow based on the model construction request, and constructing an initial prediction model;
under the condition that the construction is completed, triggering a model training node of the task flow, and training the initial prediction model through a first thread according to sample data carried in the model construction request;
based on the execution of the training, triggering a polling task node of the task flow, and polling the training progress of the initial prediction model through a second thread according to a preset polling mechanism;
Under the condition that the initial prediction model training is determined to be completed according to the polling result, triggering a model release node to acquire a deep learning basic framework image file prestored in an image file warehouse,
constructing a target service image file based on the base frame image file and a target prediction model, wherein the target prediction model is obtained based on deep learning base frame pre-training,
and publishing the target prediction model to a target platform based on the target service image file.
13. A computer readable storage medium storing computer instructions which, when executed by a processor, implement the steps of the data processing method of any one of claims 1 to 10.
CN202010543594.6A 2020-06-15 2020-06-15 Data processing method and device Active CN113806624B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010543594.6A CN113806624B (en) 2020-06-15 2020-06-15 Data processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010543594.6A CN113806624B (en) 2020-06-15 2020-06-15 Data processing method and device

Publications (2)

Publication Number Publication Date
CN113806624A CN113806624A (en) 2021-12-17
CN113806624B true CN113806624B (en) 2024-03-08

Family

ID=78944454

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010543594.6A Active CN113806624B (en) 2020-06-15 2020-06-15 Data processing method and device

Country Status (1)

Country Link
CN (1) CN113806624B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108734293A (en) * 2017-04-13 2018-11-02 北京京东尚科信息技术有限公司 Task management system, method and apparatus
CN110413294A (en) * 2019-08-06 2019-11-05 中国工商银行股份有限公司 Service delivery system, method, apparatus and equipment

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107885762B (en) * 2017-09-19 2021-06-11 北京百度网讯科技有限公司 Intelligent big data system, method and equipment for providing intelligent big data service

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108734293A (en) * 2017-04-13 2018-11-02 北京京东尚科信息技术有限公司 Task management system, method and apparatus
CN110413294A (en) * 2019-08-06 2019-11-05 中国工商银行股份有限公司 Service delivery system, method, apparatus and equipment

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
一种IaaS模式"云训练"系统设计;陈志佳;朱元昌;邸彦强;冯少冲;;系统仿真学报(第05期);第1095-1104页 *

Also Published As

Publication number Publication date
CN113806624A (en) 2021-12-17

Similar Documents

Publication Publication Date Title
US10725827B2 (en) Artificial intelligence based virtual automated assistance
US20210304075A1 (en) Batching techniques for handling unbalanced training data for a chatbot
US11038821B1 (en) Chatbot artificial intelligence
EP3617896A1 (en) Method and apparatus for intelligent response
US20220358292A1 (en) Method and apparatus for recognizing entity, electronic device and storage medium
EP4252149A1 (en) Method and system for over-prediction in neural networks
CN111242710A (en) Business classification processing method and device, service platform and storage medium
CN111078855A (en) Information processing method, information processing device, electronic equipment and storage medium
CN111651989B (en) Named entity recognition method and device, storage medium and electronic device
CN113806624B (en) Data processing method and device
CN116757270A (en) Data processing method and server based on man-machine interaction model or large model
Khusnutdinov et al. Open source platform digital personal assistant
US20220171816A1 (en) Auxiliary control mechanisms for complex query processing
CN113190154B (en) Model training and entry classification methods, apparatuses, devices, storage medium and program
US11847614B2 (en) Method and system for determining collaboration between employees using artificial intelligence (AI)
US20160266874A1 (en) Technology recommendation for software environment
US11803358B1 (en) Adaptive issue type identification platform
CN115829169B (en) Business processing method and device based on mixed integer linear programming
CN115827171B (en) Cloud parameter adjusting system, parameter adjusting method and parameter adjusting system
CN116757254B (en) Task processing method, electronic device and storage medium
US20220300884A1 (en) Method and system for evaluating performance of developers using artificial intelligence (ai)
US20240134682A1 (en) Automatic workflow generation and optimization
CN111046162A (en) Information processing method and device and electronic equipment
Usachev et al. Open source platform Digital Personal Assistant
Yang et al. AutoMMLab: Automatically Generating Deployable Models from Language Instructions for Computer Vision Tasks

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant