Edge-cloud model collaboration method and system
Through edge cloud model collaboration methods and systems, the problem of difficult real-time requirements of traditional cloud computing models in edge applications is solved, model sharing and collaborative deployment are realized, and model utilization value and production efficiency are improved.
Patent Information
- Application Number
- CN202210713585.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-22
- Publication Date
- 2025-03-14
- Estimated Expiration
- 2042-06-22
AI Technical Summary
Traditional cloud computing models are difficult to meet real-time requirements in edge applications, resulting in poor model universality, lack of high availability, high-precision edge-cloud collaborative optimization models, and lack of effective model sharing and collaboration mechanisms.
Through edge cloud model collaboration methods and systems, model sharing is realized in different departments, training models, algorithm models and model application templates are built, and computing resource scheduling strategies are adopted to realize model tasks decomposition, sorting and matching to ensure efficient and coordinated deployment of models in the cloud and the edge.
It maximizes the utilization value of the model, reduces production and operation costs, improves the sharing and reuse capabilities of model, simplifies the cross-departmental cooperation process, meets the needs of multi-objective cross-domain tasks, and improves real-time response efficiency.
Smart Images

Figure CN115098256B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of computer software technology, and in particular, relates to an edge-cloud model collaboration method and system. Background Art
[0002] In the traditional industrial operation and management process, models are scattered across various business systems. Enterprises have multi-domain and multi-type industrial mechanism models and analytical calculation models, but the models are scattered across different business systems, with a small scope of use and low reusability. At the same time, enterprises lack models and collaboration mechanisms that can be efficiently migrated between the cloud and the edge.
[0003] Intelligence promotes the transformation of traditional industries into high-tech intensive industries, and model-based analytical calculations have become an important means to support scientific decision-making. However, due to the centralized management of traditional cloud computing models, this model requires data to transcend geographical location restrictions, with great data transmission delays and network fluctuations, and it is difficult to meet the real-time requirements of edge applications. Therefore, the models built by various departments have poor versatility and lack high-availability and high-precision edge-cloud collaborative optimization models. Since personalized needs are difficult to unify and the degree of standardization is low, this requires enterprises to improve production efficiency while also enhancing the accuracy of decision-making. Therefore, the scheduling problem under the edge-cloud collaborative model needs to consider global optimization and real-time response.
[0004] Based on cloud-edge model collaboration, it is possible to share models of different departments to maximize the value of model utilization, and to uniformly manage the models used by different departments, thereby reducing production and operation costs, improving model sharing and reuse capabilities, and simplifying cross-departmental cooperation processes. Therefore, it is necessary to establish a model collaboration mechanism for edge-cloud collaboration, provide model collaboration services, and provide unified basic support and model collaboration capabilities for the industrial Internet platform.
[0005] The traditional cloud computing model can aggregate a large number of virtual heterogeneous computing resources and abstract them into a unified virtual shared resource pool, which can provide users with elastic and scalable computing resource pool services. However, the cloud computing model also has certain problems. Aggregating data for processing in the cloud has high requirements for load, throughput, bandwidth, etc., and also causes long latency, which is a waste of resources and has a certain dependence on the network. When multiple users send requests at the same time, the cloud cannot respond in time, affecting the user experience.
[0006] Edge computing is usually deployed at the edge of cloud computing, with the characteristics of flexible deployment, no bandwidth restrictions, and strong real-time performance. However, due to the influence of regional deployment, the flexibility of edge computing cannot keep pace with cloud computing; the computing and storage capabilities of edge computing are limited, which is a certain gap compared with cloud computing. Edge computing can make up for the shortcomings of traditional cloud computing such as extended latency, and cloud computing can also provide strong computing support for edge computing, so the edge-cloud combined computing model is proposed. In places where low latency is required and bandwidth is limited, edge computing can give full play to its role, reduce energy consumption losses, and reduce cost output. When higher data processing capabilities are required, cloud computing can provide service support. Therefore, through the model collaborative scheduling strategy, we can deal with the problems of increasing resource scale and diversified data development on cloud and edge resource scheduling, globally optimize and improve real-time response efficiency, and meet the needs of multi-target cross-domain tasks. However, there is currently no solution that can effectively realize model sharing among different departments, and the above effects cannot be achieved. This problem needs to be solved urgently. Summary of the invention
[0007] The purpose of the present invention is to provide an edge-cloud model collaboration method and system, which can realize model sharing among different departments through model collaboration, maximize the utilization value of the model, and provide unified basic support and model collaboration capabilities for the industrial Internet platform.
[0008] In order to achieve the above object, the technical solution adopted by the present invention is:
[0009] An edge-cloud model collaboration method includes the following steps:
[0010] Build the equipment object model on the plant side, map the measurement points to the equipment object model, and then synchronize the equipment object model to the group side;
[0011] The plant side collects static and dynamic data of each plant equipment, and uploads the time series data containing the static and dynamic data to the group side;
[0012] The group builds a training model based on the device object model and the acquired time series data containing static and dynamic data. Then, it creates an algorithm model based on the training model and manages it in a unified manner. Then, it creates a model application template based on the algorithm model.
[0013] When the plant side sends a subscription request to the group side, the group side creates an application instance based on the model application template and sends it to the plant side;
[0014] After receiving the application instance, the plant side deploys the application instance in the form of an application container.
[0015] Furthermore, the plant side collects static and dynamic data of each plant equipment through industrial protocols, and the industrial protocols include any one of OPC UA, Mod Bus, and MQTT. The static data includes device name, device attributes and historical records, and the dynamic data includes sensor collection data and equipment operating parameters.
[0016] Furthermore, building a training model includes:
[0017] Select the connection component step: select components by dragging and dropping them in a visual way, and implement the input and output between components through code;
[0018] Steps for training the model: First, by dragging the data, analyze and model the data that falls into the database or file to obtain the training model; then, by publishing the model task for the training model and using the computing resource scheduling strategy, the computing resources of the computing modeling unit are scheduled and controlled to complete the model task.
[0019] Furthermore, the computing resource scheduling strategy includes group-side scheduling strategy, matching of model tasks with computing modeling units, and real-time scheduling of computing modeling units; wherein:
[0020] The group-side scheduling strategy includes three steps: model task completion time prediction, model task decomposition, and computing task sorting. The model task completion time prediction step is to build a model task completion time prediction model, and predict the group-side model task completion time by inputting data into the model. The model task decomposition step is to split the published model task into multiple subtasks, and there are time constraints between the subtasks. The computing task sorting step is to weigh the model task priorities through weighted average, and determine the order of model task calculation according to the weight value.
[0021] Matching model tasks with computational modeling units: Matching subtasks with computational modeling units is done through a genetic algorithm. In this genetic algorithm, each gene represents a computational modeling unit assigned to a subtask. The fitness function of the computational modeling unit and the computational cost required to complete the task are calculated.
[0022] Real-time scheduling of computational modeling units: Based on the matching results between subtasks and computational modeling units, the computational modeling units will perform resource scheduling internally based on their respective subtasks while meeting the goal of minimizing the maximum completion time. During the scheduling process, the best computing device will first be selected in multiple optional sequences. Then, based on the order of the subtasks, each subtask will be carried out in sequence to achieve real-time dynamic scheduling of the entire computational modeling unit.
[0023] Furthermore, the input data types of the model task completion time prediction model include three categories: the first category is production data, including the number of model tasks, computing equipment utilization, computing accuracy and equipment failure rate; the second category is data related to the computing capacity of known computing modeling units; the third category is real-time and historical data related to model tasks created on the group side.
[0024] Furthermore, the specific steps of the model task completion time prediction include: first, determining the output items according to the task completion time; then determining the number of input items according to the factors affecting the task completion time; then using a three-layer BP neural network, and determining the number of neurons in the network input layer and output layer according to the input items and output items, determining the number of neurons in the hidden layer according to the empirical formula, determining the activation function of each layer, and constructing a model task completion time prediction model; finally, obtaining and screening the sample data set, and dividing it into a training set and a test set, using the training set to train the model, and using the test set to verify the model training effect, and using a qualified model task completion time prediction model to output the prediction result.
[0025] Furthermore, in the group-side scheduling strategy, a computing mode among cloud computing, edge-cloud collaborative computing and edge computing is selected as needed to train models and infer model tasks.
[0026] Furthermore, the real-time scheduling of the computational modeling unit also includes: using a segmented coding method to perform real-time scheduling within the computational modeling unit, which is divided into two steps: equipment selection and computational process scheduling; taking minimizing the maximum completion time as the objective function, and calculating the fitness function after decoding with chromosomes; calculating the scheduling calculation process and the scheduling process time of each individual in the population based on the fitness function, and saving and outputting the scheduling calculation order and the corresponding time under the minimized maximum completion time.
[0027] An edge-cloud model collaboration system includes: a device object management module, a device object library, a timing service module, a model development and training module, an algorithm model library management module, a model application template management module and a model application distribution module located on the group side, and a data acquisition module, a device object library, a device object management module, a timing service module, a model application receiving module and a model application deployment module located on the plant side; wherein,
[0028] The device object management module is used for communication between the group side and the plant side, and for uploading the device object model and timing data to the group side;
[0029] Device object library, used to store device object models;
[0030] A timing service module, used for generating and transmitting timing data including the timing data of the static and dynamic data;
[0031] Model development training module, which is used to build training models through a visual interface based on device objects and time series data containing static and dynamic information of devices;
[0032] The algorithm model library management module is used to create algorithm models based on training models and manage them in a unified manner, and supports the selection, dependency binding and model editing functions of algorithm model execution;
[0033] A model application template management module is used to select a specified algorithm model from the algorithm model library management module to create a model application template;
[0034] The model application delivery module is used to create an application instance according to the model application template and deliver it to the plant side after the plant side sends a subscription request to the group side;
[0035] Data acquisition module, used to collect static and dynamic data of each plant and station equipment;
[0036] The model application receiving module is used to communicate with the model application issuing module on the group side through the edge-cloud channel and receive the issued application instances;
[0037] The model application deployment module is used to call the computing scheduling engine, create an application container, and deploy the application instance in the application container.
[0038] Furthermore, the functions of the algorithm model library management module specifically include: algorithm model creation, algorithm model list query, specified algorithm model query, algorithm model modification, algorithm model version creation and algorithm model version deletion.
[0039] Furthermore, the functions of the model application template management module specifically include: model application template creation, model application template query, specified model application template viewing, model application template modification, model application template deletion and specified model application template code file download.
[0040] Furthermore, the functions of the model application delivery module specifically include: application instance creation, application instance query, application instance details query, application instance update and application instance deletion.
[0041] Furthermore, the functions of the model application deployment module specifically include: application instance deployment, application instance query, application instance update, application instance deletion and plant-side application status reporting.
[0042] The present invention realizes unified model basic support and coordination capabilities on the group side and the plant side through processes such as algorithm model construction, model application template construction, model control, subscription monitoring, model distribution, and model deployment. Through scheduling strategies, global optimization is achieved to improve real-time response efficiency and meet multi-target cross-domain requirements. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] Figure 1 This is a block diagram of an edge-cloud model collaborative system of the present invention.
[0044] Figure 2 It is a schematic diagram of the collaborative process of the group side and the plant side models.
[0045] Figure 3 This is a schematic diagram of the collaborative scheduling process between the group-side and plant-side models. DETAILED DESCRIPTION
[0046] In order to make the above features and advantages of the present invention more obvious and easy to understand, embodiments are given below and described in detail with reference to the accompanying drawings.
[0047] This embodiment provides an edge-cloud model collaboration system. Figure 1-2 As shown, it includes the device object management module, device object library, timing service module, model development and training module, algorithm model library management module, model application template management module and model application distribution module on the group side, and the data acquisition module, device object library, device object management module, timing service module, model application receiving module and model application deployment module on the plant side. The above modules are described in detail as follows.
[0048] 1. Group side module
[0049] 1. Equipment object management module: used to communicate with the equipment object management module on the plant side and receive the equipment object model and timing data uploaded by the plant side.
[0050] 2. Device object library: used to store received device object models.
[0051] 3. Timing service module, used to receive and store timing data uploaded by the plant side.
[0052] 4. Model development and training module: Model application modeling is realized through a visual interface to simplify model application development and training work. The development and training work is mainly divided into two stages: data preparation stage and model building stage, in which:
[0053] (1) Data preparation stage: The group collects and uploads time series data containing static and dynamic information of the equipment based on the constructed equipment objects for model development and training.
[0054] (2) Model building stage: It is mainly divided into two stages: selecting connection components and training models.
[0055] 1) Select connected components: Select components by dragging and dropping in a visual way. The logic calculation part has completed the input and output of the code in a fixed format, so that it has specific advanced functions, and components can be connected to each other.
[0056] 2) Training model: Through the drag-and-drop data analysis and modeling process, the data falling into the database or file can be analyzed and modeled to obtain the training model. Before execution, the model task for training the model can be published, and the scheduling control of computing resources can be realized through the computing resource scheduling strategy. After execution, it can be published to the algorithm model library management module.
[0057] 5. Algorithm model library management module: The group side creates an algorithm model based on the training model through the algorithm model library management module, and provides unified management services for the algorithm model. It also supports functions such as algorithm model execution selection, dependency binding, and algorithm model editing, and is then called by the model application template management module.
[0058] The main functions of the algorithm model library management module include:
[0059] (1) Algorithm model creation. Provides options to select general algorithms or professional algorithms, or select models for data analysis development services. If you select an algorithm, you only need to enter basic information such as name, description, algorithm type, runtime language, function execution entry, input parameters, and output parameters; if you select a model, in addition to the above specified parameters, the background will also encapsulate the model into an algorithm of the specified runtime language for subsequent use.
[0060] (2) Algorithm model list query. The query will display the basic information of the algorithm models that have been added to the system in pages.
[0061] (3) Query the specified algorithm model. The query will display detailed information about the specified algorithm model.
[0062] (4) Algorithm model modification: You can modify the description, function execution entry, input parameters, output parameters and other information of the specified algorithm model.
[0063] (5) Algorithm model version creation. Release a new version, fill in the version number and description information, and release the corresponding algorithm model version. Modifications are not allowed after the version is released. Only the released version can be created and applied.
[0064] (6) Deleting the algorithm model version. Select Delete version to delete the published version.
[0065] 6. Model application template management module: The group side uses the model application template management module and creates a model application template based on the algorithm model library management module after selecting the specified algorithm model. The model application template is managed by the group side and supports version upgrades, configuration changes and other functions for the application. It is finally deployed on the plant side by the deployment service in the form of an application container. The model application template is mainly for the specified algorithm model, and pre-configures a set of application settings to facilitate users to uniformly issue application instances. These settings mainly include the selection of the algorithm and its version, basic application configuration such as the application name, application container configuration such as CPU and memory, and algorithm parameter and device model binding information configuration.
[0066] The main functions of the model application template management module include:
[0067] (1) Model application template creation. Create an algorithm model through the algorithm model library management module, specify the model application template name, CPU configuration, memory configuration, port configuration, description, environment variable configuration, log configuration, parameter and device model binding and other information, and create a model application template.
[0068] (2) Model application template query: You can use the model application template name as the query condition to query the specified model application template list.
[0069] (3) Specify the model application template to view. According to the specified template, view various information of the template.
[0070] (4) Model application template modification: You can modify the specified model application template name, CPU configuration, memory configuration, port configuration, description, environment variable configuration, log configuration, parameter and device model binding, and other information.
[0071] (5) Model application template deletion: You can delete the specified model application template.
[0072] (6) Download the specified model application template code file. Provide a download interface for the algorithm deployment service.
[0073] 7. Model application delivery module: After the model application template is created, it is not executed. The application needs to be delivered to the plant side for execution.
[0074] The main functions of the model application distribution module include:
[0075] (1) Application instance creation. When creating an application instance, first select the model application template. The system will bring the configuration parameters that need to be filled in the template to this page. The user only needs to modify the necessary parameters. The number of application instances defaults to 1, and the user can modify it according to needs. Secondly, according to the input and output parameters preset on the group side, bind the measurement points of the model service to complete the one-to-one mapping of parameters and measurement points. Finally, through the edge-cloud channel and the model application receiving module, it is sent to the model application deployment service on the plant side, and the model application deployment module makes the final deployment.
[0076] (2) Application instance query: Query the application instance list based on the application instance name (optional).
[0077] (3) Query application instance details. View application instance details based on the application instance ID, and support modifying the number of application instances.
[0078] (4) Application instance update. This includes updating the basic configuration of the application and the binding information of the application measurement points, which is consistent with the creation of the application instance. Updating the application instance does not allow updating the model application template.
[0079] (5) Application instance deletion: Delete the application instance according to the application instance ID.
[0080] 2. Plant side module
[0081] 1. Data acquisition module: Through industrial protocols such as OPC UA and Mod Bus, it collects static (such as device name, device attributes, historical records, etc.) and dynamic (such as sensor collection, equipment operating parameters, etc.) data of each plant and station equipment.
[0082] 2. Device object library: used to store device object models.
[0083] 3. Equipment object management module: used to communicate with the equipment object management module on the group side, upload the equipment object library on the plant side, realize the synchronization of the equipment object models on the group side and the plant side, and provide a data set acquisition interface.
[0084] 4. Timing service module: used to report timing data to the group side.
[0085] 5. Model application receiving module: The model application is deployed and run on the plant side, and communicates with the model application sending module on the group side through the edge-cloud channel to receive the sent application instances.
[0086] 6. Model application deployment module: used to execute deployment services. After receiving the request from the model application delivery module on the group side, it calls the provided deployment interface to actually deploy the application instance.
[0087] The main functions of the model application deployment module include:
[0088] (1) Application instance deployment. After receiving the application deployment request from the cloud, the deployment service will call the computing scheduling engine on the plant side to create application containers and other resources.
[0089] (2) Application instance query. The deployment service periodically queries the application details from the system and sends the status and other information to the group side through the cloud-edge channel through the timing service module.
[0090] (3) Application instance update. After receiving the application instance update request from the group, the deployment service will notify the algorithm scheduling engine on the plant side to update the application container parameters and other resources.
[0091] (4) Application instance deletion: After receiving the application instance deletion request from the group side, the computing scheduling engine on the plant side is notified to delete the application container and other resources.
[0092] (5) Plant-side application status reporting. After the application instance is started, the plant-side needs to regularly report the status to the group side, so that the group side can monitor and manage the plant-side application instance. For this status information, the timing service module on the plant-side asynchronously sends it to the group side through the edge-cloud channel.
[0093] This embodiment correspondingly provides an edge-cloud model collaboration method, such as Figure 1-2 As shown, it includes the following steps:
[0094] S1: Construct the equipment object model at the plant side, and map the measuring points to the equipment object model through the data acquisition module. After the equipment object model is constructed, it will be collected into the equipment object library at the plant side.
[0095] S2: The equipment object management module on the plant side communicates with the equipment object management module on the group side, uploads the equipment object library on the plant side, and synchronizes the equipment object models on the group side and the plant side. After the equipment object model is synchronized on the group side and the plant side, the group side and the plant side will have a unified data acquisition interface, thereby supporting the deployment of model services on the group side and the plant side.
[0096] S3: The data acquisition module on the plant side collects static (such as device name, device attributes, historical records, etc.) and dynamic (such as data collected by sensors, equipment operating parameters, etc.) data of each plant equipment through industrial protocols such as OPC UA and Mod Bus.
[0097] S4: The plant side reports the timing data through the plant side timing service module. The timing data communicates with the group side object management module through the plant side equipment object management module and is uploaded to the group side timing service module for storage.
[0098] S5: The group side uses the model development and training module to implement model application modeling with a visual interface, simplifying the model application development and training work. The development and training work is mainly divided into two stages: data preparation stage and model building stage, in which:
[0099] (1) Data preparation stage: Based on the constructed device object model, the group collects and uploads time series data containing static and dynamic information of the device for model development and training.
[0100] (2) Model building stage: It is divided into two steps: selecting connection components and training the model.
[0101] 1) Select connected components: Select components by dragging and dropping in a visual way. The logic calculation part has completed the input and output of the code in a fixed format, so that it has specific advanced functions, and components can be connected to each other.
[0102] 2) Training model: Analyze the modeling process by dragging and dropping data, analyze and model the data in the database or file, and obtain the training model. Before execution, you can publish the model task for training the model and use the computing resource scheduling strategy to control the scheduling of computing resources.
[0103] like Figure 3 As shown in the figure, the computing resource scheduling strategy is mainly divided into three parts, namely, the group-side scheduling strategy, the matching of model tasks and computing modeling units, and the real-time scheduling of computing modeling units. The computing modeling unit completes the model task, which can be the group side (cloud) or the plant side (edge end). The computing resource scheduling strategy distributes the split model subtasks to different computing modeling units to complete according to specific requirements, so that idle resources can be utilized and the overall efficiency can be improved.
[0104] 2-1) Group-side scheduling strategy, mainly including model task completion time prediction, model task decomposition, and computing task sorting. Model task completion time prediction is completed through the constructed model task completion time prediction model. The input data types of this model mainly include three categories: the first category is production data such as the number of model tasks, computing equipment utilization, computing accuracy, and equipment failure rate; the second category is data related to the known plant-side computing modeling unit capabilities, such as the computing capacity of each unit; the third is real-time and historical data related to the creation of model tasks on the group side. Combining the above data, the group-side model task completion time prediction is realized, making the plant-side scheduling more accurate and efficient.
[0105] The computing mode is selected based on the group-side scheduling strategy. The computing modes are divided into the following three types:
[0106] (1) Cloud computing: training and reasoning model tasks are completely done on the group side;
[0107] (2) Edge-cloud collaborative computing: training and reasoning of model tasks in an edge-cloud collaborative manner;
[0108] (3) Edge computing: training and reasoning model tasks at the plant side.
[0109] Specifically, the task completion time prediction model of the group side is constructed through a back-propagation neural network. First, the output items are determined according to the task completion time, and then the number of input items is determined according to the factors affecting the task completion time. A three-layer BP neural network is adopted, and the number of neurons in the input layer and output layer of the network is determined according to the input items and output items. The number of neurons in the hidden layer is determined according to the empirical formula, and the activation function of each layer is determined. Then, the sample data set is obtained and screened, divided into a training set and a test set, the network is trained using the training set, and the network training effect is verified with the test set data, and finally the prediction result is obtained.
[0110] The group has Q computing modeling units, each of which has W computing devices and Z different model tasks. The prediction model data set is shown in the following formula. TCT represents the task completion time. P represents the number of tasks. D represents the computing device utilization rate, CA represents the computing accuracy rate in the most recently completed task, OI represents the equipment operation information, and FR represents the equipment failure rate.
[0111]
[0112] According to the four input variables (number of tasks, computing equipment utilization, computing accuracy, and equipment failure rate), the number of output neurons is 1, and the number of hidden layer nodes is 4 through the empirical formula. represents the number of nodes in the hidden layer, α represents the number of neurons in the input layer, and β represents the number of neurons in the output layer.
[0113]
[0114] The following function is used as the transfer function of the BP neural network to perform standard normalization on the data. After the data analysis is completed, it is denormalized to restore the data type, where θ is the independent variable of the S function.
[0115]
[0116] The weight between the input layer and the hidden layer is ω αβ , α=1,2,3,4, bias is η β , the weight between the hidden layer and the output layer is ω βγ , with a bias of λ γ , learning rate ρ = 0.01, HP β is the input of each neuron in the hidden layer, θ αis the input variable.
[0117] Input of each neuron in the hidden layer:
[0118]
[0119] The output of each neuron in the hidden layer is:
[0120] HO β =f(HP β ),β=1,2,3,4
[0121] Input of each neuron in the output layer:
[0122]
[0123] The output of each neuron in the output layer is:
[0124] ζ α =f(OP γ )
[0125] After completing the completion time prediction based on historical data, the group side analyzes the model tasks to be performed and divides the model tasks into multiple subtasks according to the calculation mode. For example, the group side N model tasks are decomposed into multiple subtasks to form a task set (T nm ), a task package can contain subtasks of different computing processes, and there are timing constraints between the orders of the decomposed tasks.
[0126] The weighted average method is used to weigh the priorities of model tasks to construct a mathematical model, and the order of model task calculation is determined according to the size of the sorting weight in the formula.
[0127] MTC(T nm )=ε1E nm +ε2CS nm
[0128]
[0129] ε1 and ε2 represent the efficiency ratio and user demand weight respectively, satisfying ε1+ε2=1. nm Indicates T nm The calculation ratio of C nm Indicates T nm Expected value of CS nm Indicates from T nm The level of the user.
[0130] 2-2) Matching model tasks with computational modeling units. After the group has completed the decomposition and sorting of model tasks, it is necessary to match the tasks with the plant side. The group will centrally summarize the subtasks of the model task decomposition and match the tasks according to the computing power and efficiency of each computational modeling unit.
[0131] According to the matching characteristics, tasks and computational modeling units are matched through genetic algorithms. Each gene represents the computational modeling unit assigned to the subtask, such as T 22 Assign computational modeling units to 6, T 33 The allocation calculation modeling unit is 7, and so on until the subtask allocation of different users is completed. The fitness function of an individual is defined as F(f(x))=f(x), where f(x) is the objective function of each stage.
[0132] Therefore, in the task and computational modeling unit allocation stage, the fitness function C is as follows, where n is the model task identifier, m is the subtask identifier, and C nm To complete subtask T nm The required computational cost.
[0133]
[0134] The function fitness value is calculated according to the chromosome decoding process. 1) The chromosome is decoded to obtain the allocation matrix of subtasks and computational modeling units. 2) The total computation time is calculated. The two matrices are multiplied, and the result is the total computation time required.
[0135] 2-3) Real-time scheduling of computing modeling units is mainly based on the matching results of subtasks and computing modeling units on the group side. In order to optimize the efficiency of each subtask, the group side will assign tasks to computing modeling units with sufficient computing resources and appropriate computing capabilities. After the matching of group-side tasks and computing modeling units is completed, the computing modeling units will perform resource scheduling internally according to their respective tasks while meeting the goal of minimizing the maximum completion time. During the scheduling process, the best computing device will be selected in multiple optional sequences, and then each subtask will be carried out in sequence according to the subtask sorting results of the group-side model task, so as to achieve real-time dynamic scheduling of the entire computing modeling unit.
[0136] When performing real-time scheduling within the computational modeling unit, a segmented coding method is used. Since the process of each subtask can be performed on different computing devices, this stage can be divided into two parts: device selection and computing process scheduling, and the chromosome is also divided into two sections. For example, after the 30 computing tasks assigned to the computational modeling unit A are sorted, their subtasks are numbered from 1 to 30.
[0137] In the internal scheduling stage of the computational modeling unit, the objective function is to minimize the maximum completion time. After chromosome decoding, the inverse of the maximum completion time is used as the fitness function:
[0138]
[0139] Minimized FT max It is the objective function and also the fitness function, which affects the convergence speed of the genetic algorithm and whether it can find the optimal solution. The scheduling calculation process and the scheduling process time of each individual in the population can be calculated based on the gene, and the scheduling calculation order and its corresponding time under the minimized maximum completion time can be saved and output.
[0140] S6: After the training model is built, it can be published to the algorithm model library management module, through which an algorithm model is created based on the training model and unified management services are provided.
[0141] S7: The group side uses the model application template management module to select a specified algorithm model based on the algorithm model in the algorithm model library management module and creates a model application template, but it is not executed after creation.
[0142] S8: When the user on the plant side sends a subscription request, the group side sends the application instance to the plant side for execution through the model application sending module.
[0143] S9: After the model application receiving module on the plant side receives the request sent by the application instance on the group side, the model application deployment module calls the provided deployment interface to deploy the application instance on the plant side in the form of an application container.
[0144] Although the present invention has been disclosed as above by way of embodiments, it is not intended to limit the present invention. Appropriate modifications or equivalent substitutions of the technical solutions of the present invention made by ordinary technicians in the field should all be included in the protection scope of the present invention. The protection scope of the present invention shall be based on what is defined in the claims.
Claims
1. An edge-cloud model collaboration method, characterized in that: The following steps are involved: Build the equipment object model on the plant side, map the measurement points to the equipment object model, and then synchronize the equipment object model to the group side; The plant side collects static and dynamic data of each plant equipment, and uploads the time series data containing the static and dynamic data to the group side; The group side builds a training model based on the device object model and the acquired time series data containing static and dynamic data; Building a training model includes: Selecting connection components: drag and drop components in a visual way, and implementing input and output between components through code; Training model: First, analyze and model the data in the database or file by dragging data to obtain a training model; then publish a model task for the training model, and use a computing resource scheduling strategy to schedule and control the computing resources of the computing modeling unit to complete the model task; Then select the algorithm model to be created and enter the model parameter information, encapsulate the existing training model into the algorithm model and manage it in a unified manner, and then set the configuration parameters for the algorithm model to form a model application template for deployment; When the plant side sends a subscription request to the group side, the group side configures the necessary parameters for creating an application instance based on the model application template, binds the parameters to the measurement points of the model service, generates the application instance, and sends it to the plant side; After receiving the application instance, the plant side deploys the application instance in the form of an application container.
2. The method according to claim 1, characterized in that The plant side collects static and dynamic data of each plant equipment through industrial protocols. The industrial protocols include any one of OPC UA, Mod Bus, and MQTT. The static data includes device name, device attributes, and historical records. The dynamic data includes sensor collection data and equipment operating parameters.
3. The method according to claim 1, characterized in that The computing resource scheduling strategy includes group-side scheduling strategy, matching of model tasks with computing modeling units, and real-time scheduling of computing modeling units; among which: The group-side scheduling strategy includes three steps: model task completion time prediction, model task decomposition, and computing task sorting. The model task completion time prediction step is to build a model task completion time prediction model, and predict the group-side model task completion time by inputting data into the model. The model task decomposition step is to split the published model task into multiple subtasks, and there are time constraints between the subtasks. The computing task sorting step is to weigh the model task priorities through weighted average, and determine the order of model task calculation according to the weight value. Matching model tasks with computational modeling units: Matching subtasks with computational modeling units is done through a genetic algorithm. In this genetic algorithm, each gene represents a computational modeling unit assigned to a subtask. The fitness function of the computational modeling unit and the computational cost required to complete the task are calculated. Real-time scheduling of computational modeling units: Based on the matching results between subtasks and computational modeling units, the computational modeling units will perform resource scheduling internally based on their respective subtasks while meeting the goal of minimizing the maximum completion time. During the scheduling process, the best computing device will first be selected in multiple optional sequences. Then, based on the order of the subtasks, each subtask will be carried out in sequence to achieve real-time dynamic scheduling of the entire computational modeling unit.
4. The method according to claim 3, characterized in that The input data types of the model task completion time prediction model include three categories: the first category is production data, including the number of model tasks, computing equipment utilization, computing accuracy and equipment failure rate; the second category is data related to the computing capacity of known computing modeling units; The third type is real-time and historical data related to model creation tasks on the group side.
5. The method according to claim 3, characterized in that The specific steps of the model task completion time prediction include: first, determine the output items according to the task completion time; then determine the number of input items according to the factors that affect the task completion time; then use a three-layer BP neural network, and determine the number of neurons in the network input layer and output layer according to the input items and output items, determine the number of neurons in the hidden layer according to the empirical formula, determine the activation function of each layer, and construct a model task completion time prediction model; finally, obtain and screen the sample data set, and divide it into a training set and a test set, use the training set to train the model, and use the test set to test the model training effect, and use the qualified model task completion time prediction model to output the prediction result.
6. The method according to claim 3, characterized in that In the group-side scheduling strategy, a computing mode among cloud computing, edge-cloud collaborative computing and edge computing is selected as needed to train models and infer model tasks.
7. The method according to claim 3, characterized in that The real-time scheduling of the computational modeling unit also includes: using segmented coding to perform real-time scheduling within the computational modeling unit, which is divided into two steps: equipment selection and computational process scheduling; taking minimization of the maximum completion time as the objective function, and calculating the fitness function after chromosome decoding; calculating the scheduling calculation process and the scheduling process time of each individual in the population based on the fitness function, and saving and outputting the scheduling calculation order and the corresponding time under the minimized maximum completion time.
8. An edge-cloud model collaborative system, characterized in that: include: The equipment object management module, equipment object library, timing service module, model development and training module, algorithm model library management module, model application template management module and model application distribution module located on the group side, and the data acquisition module, equipment object library, equipment object management module, timing service module, model application receiving module and model application deployment module located on the plant side; among them, The device object management module is used for communication between the group side and the plant side, and for uploading the device object model and timing data to the group side; Device object library, used to store device object models; A timing service module, which is used to generate and transmit timing data including static and dynamic data; The model development training module is used to build a training model through a visual interface based on the device object and the time series data containing the static and dynamic information of the device; building the training model includes: selecting the connection component step: dragging and selecting the component in a visual way, and realizing the input and output between components through code; training model step: firstly, by dragging the data, analyzing and modeling the data falling into the database or file to obtain the training model; then, by publishing the model task for the training model and through the computing resource scheduling strategy, the computing resources of the computing modeling unit are scheduled and controlled to complete the model task; The algorithm model library management module is used to select the algorithm model and input the model parameter information, encapsulate the existing training model into the selected algorithm model and manage it in a unified manner, and supports the selection, dependency binding and model editing functions of algorithm model execution; A model application template management module is used to select a specified algorithm model from the algorithm model library management module, set configuration parameters for the algorithm model, and form a model application template for deployment; The model application delivery module is used to configure the necessary parameters required to create an application instance based on the model application template after the plant side sends a subscription request to the group side, and bind the parameters to the measurement points of the model service, generate the application instance and deliver it to the plant side; Data acquisition module, used to collect static and dynamic data of each plant and station equipment; The model application receiving module is used to communicate with the model application issuing module on the group side through the edge-cloud channel and receive the issued application instances; The model application deployment module is used to call the computing scheduling engine, create an application container, and deploy the application instance in the application container.
9. The system according to claim 8, characterized in that The functions of the algorithm model library management module specifically include: algorithm model creation, algorithm model list query, specified algorithm model query, algorithm model modification, algorithm model version creation and algorithm model version deletion; the functions of the model application template management module specifically include: model application template creation, model application template query, specified model application template viewing, model application template modification, model application template deletion and specified model application template code file download; the functions of the model application delivery module specifically include: application instance creation, application instance query, application instance details query, application instance update and application instance deletion; the functions of the model application deployment module specifically include: application instance deployment, application instance query, application instance update, application instance deletion and plant-side application status reporting.
Citation Information
Patent Citations
Industrial Internet of Things low-code rapid development system and method based on micro-service
CN113495724A
Garbage collection based on transmission object models
US11093387B1