A parameter tuning system and method for a device-edge-cloud collaborative PID controller
Through the PID controller parameter tuning system that collaborates with end-edge cloud, PID control parameters are automatically tuned using data processing of edge communication devices and cloud servers, which solves the problem of relying on manual experience and improves control performance and system stability.
Patent Information
- Application Number
- CN202310264519.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-17
- Publication Date
- 2025-09-02
- Estimated Expiration
- 2043-03-17
AI Technical Summary
The existing PID controller parameter tuning method relies on engineer experience, is time-consuming and labor-intensive, and the control performance is degraded due to changes in dynamic characteristics, making it difficult to maintain good control effects for a long time.
The PID controller parameter tuning system with end-edge cloud collaboration is adopted. Data is collected through edge communication devices and sent to the cloud server for model correction. The edge server uses edge digital twin model and parameter tuning algorithm to obtain PID control parameters, and evaluates it in the edge control system until the preset indicators are met, and the model is updated to ensure accuracy.
It realizes automatic adjustment of PID control parameters, improves control performance and system stability, reduces the time and cost of manual parameter adjustment, and ensures long-term control effect.
Smart Images

Figure CN116466675B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of industrial production process control technology, and in particular to a parameter tuning system and method for a PID controller in end-edge-cloud collaboration. Background Art
[0002] Complex industrial processes primarily refer to those characterized by long flow paths, significant hysteresis, strong nonlinearity, complex chemical reactions and physical changes, exposure to unknown interference, changes in dynamic characteristics, and difficulty in establishing accurate models. Industrial processes are composed of multiple control systems, each of which includes multiple field loops. Therefore, loop control is a critical component of the entire industrial process. However, loop control is susceptible to frequent, unknown, and large-scale interference, and the complex physical changes and chemical reactions within materials complicate the control process.
[0003] Currently, PID controllers are commonly used for loop control. By using PID controllers, engineers can determine the control parameters of the PID controller through field experiments without having to establish a precise mathematical model, simplifying the control process and achieving better control results. However, this method of determining PID controller parameters relies heavily on the engineer's expert experience, which is time-consuming and labor-intensive. Furthermore, due to the variability of the dynamic characteristics of industrial processes, control performance can be degraded, and the control effect cannot be maintained in the long term. Summary of the Invention
[0004] The purpose of the embodiments of the present invention is to provide a parameter tuning system and method for a PID controller in end-edge-cloud collaboration, which solves the problem of time-consuming and labor-intensive manual parameter adjustment that relies on engineers' experience, as well as the problem of decreased control performance due to changes in dynamic characteristics. It can realize automatic tuning of PID control parameters during the operation of the control system, improve control performance, and ensure that the system maintains good control effects for a long time.
[0005] To achieve the above objectives, an embodiment of the present invention provides a parameter tuning system for a PID controller in a device-edge-cloud collaborative manner, comprising a field control system and edge communication equipment deployed on a field end, an edge control system and edge server deployed on an edge end consistent with the field control system, and a cloud server deployed on a cloud end; the field control system includes a controlled object controlled by a PID controller;
[0006] The edge communication device is used to collect data from the field control system and send the collected data to the cloud server;
[0007] The cloud server is used to perform parameter correction on the cloud digital twin model based on the PID control process according to the received data, and send the obtained corrected model parameters to the edge server;
[0008] The edge server is used to obtain PID control parameters using an edge digital twin model and a parameter tuning algorithm based on a PID control process and send them to the edge control system for evaluation. When the PID control parameters do not meet the preset evaluation indicators, the PID control parameters are re-acquired and re-evaluated until the PID control parameters meet the preset evaluation indicators. When the PID control parameters meet the preset evaluation indicators, the PID control parameters that meet the preset evaluation indicators are sent to the edge communication device;
[0009] The edge server is further configured to update the edge digital twin model according to the corrected model parameters when receiving the corrected model parameters, and use the updated edge digital twin model when acquiring the PID control parameters next time;
[0010] The edge communication device is further configured to send the received PID control parameters to the PID controller in the field control system to control the controlled object in the field control system.
[0011] Furthermore, the cloud digital twin model consists of a linear model and a nonlinear compensation model; the expression of the cloud digital twin model is: Wherein, b0u(k-1-d)+c0 is the linear model, b0 and c0 are model parameters, is the nonlinear compensation model, a0 is the model parameter, k is the sampling time, d is the delay time, u(k) is the output value of the PID controller in the field control system, K p , K i and K d is the control parameter of the PID controller in the field control system, e(k) is the tracking error of the controlled object in the field control system, e(k)=y sp (k)-y(k),y sp (k) is the set value of the controlled object in the field control system, and y(k) is the feedback value of the controlled object in the field control system.
[0012] Furthermore, the edge communication device collects data from the field control system, specifically including:
[0013] The edge communication device collects data on at least the output value of the PID controller in the field control system, the feedback value and the set value of the controlled object in the field control system;
[0014] Then, the cloud server performs parameter correction on the cloud digital twin model based on the PID control process according to the received data, specifically including:
[0015] The cloud server performs parameter correction on the cloud digital twin model based on the PID control process based at least on the received output value of the PID controller in the field control system, the feedback value and set value of the controlled object in the field control system, and obtains the corrected model parameters; wherein the model parameters include weight parameters and bias parameters.
[0016] Furthermore, the cloud server is further configured to store the received data in a database;
[0017] Then, the cloud server performs parameter correction on the cloud digital twin model based on the PID control process according to the received data, specifically including:
[0018] The cloud server performs data preprocessing on the data stored in the database, and performs parameter correction on the cloud digital twin model based on the PID control process according to the preprocessed data.
[0019] Furthermore, the cloud server sends the obtained corrected model parameters to the edge server, specifically including:
[0020] The cloud server obtains a first comprehensive score of the cloud digital twin model and a second comprehensive score of the edge digital twin model based on the PID control process. When the difference between the first comprehensive score and the second comprehensive score is greater than a preset first score threshold, the obtained corrected model parameters are sent to the edge server.
[0021] Furthermore, the calculation formula of the first comprehensive score is: Among them, MSE s , RMSE s 、R 2 s 、TPR s and TNR s They are mean square error MSE, root mean square error RMSE, and goodness of fit R 2 The scores of the five evaluation indicators, true positive rate TPR and true negative rate TNR, are calculated as follows:
[0022]
[0023]
[0024]
[0025]
[0026]
[0027] MSE max , RMSE max 、R 2 min 、TPR min and TNR min They are mean square error MSE, root mean square error RMSE, and goodness of fit R 2 , the thresholds of the five evaluation indicators: true positive rate TPR and true negative rate TNR.
[0028] Furthermore, the edge server uses an edge digital twin model and parameter tuning algorithm based on the PID control process to obtain PID control parameters and sends them to the edge control system for evaluation, specifically including:
[0029] The edge server obtains a third comprehensive score of the controlled object in the field control system. When the third comprehensive score is less than a preset second score threshold, the edge server uses an edge digital twin model and a parameter tuning algorithm based on the PID control process to obtain PID control parameters and sends them to the edge control system for evaluation.
[0030] Furthermore, the calculation formula of the third comprehensive score is:
[0031] Among them, MEI s 、IAEI s 、IAE s 、ISE s 、TVy s 、OS s 、TVu s 、CIM s , CMSF and AP s The scores of the ten evaluation indicators are respectively the maximum value of the exceeded interval MEI, the absolute cumulative sum of exceeded interval IAEI, the absolute error cumulative sum IAE, the error square sum ISE, the fluctuation cumulative sum TVy, the overshoot OS, the input fluctuation cumulative sum TVu, the input mean CIM, the input vibration degree CMSF and the utilization rate AP. The calculation formula for each score is:
[0032]
[0033]
[0034]
[0035]
[0036]
[0037]
[0038]
[0039]
[0040]
[0041]
[0042] MEI max 、IAEI max 、IAE max 、ISE max 、TVy max 、OS max 、TVu max 、CIM max , CMSF max and AP min They are the thresholds of the ten evaluation indicators, namely, the maximum value of the interval exceeded MEI, the absolute cumulative sum exceeded IAEI, the absolute error cumulative sum IAE, the error square sum ISE, the fluctuation cumulative sum TVy, the overshoot OS, the input fluctuation cumulative sum TVu, the input mean CIM, the input vibration degree CMSF and the utilization rate AP.
[0043] Furthermore, the cloud server is further configured to send the received data to the edge server; wherein the data includes at least an output value of a PID controller in the field control system, a feedback value and a set value of a controlled object in the field control system;
[0044] Then, the edge server uses the edge digital twin model and parameter tuning algorithm based on the PID control process to obtain the PID control parameters and send them to the edge control system for evaluation, specifically including:
[0045] The edge server calculates the tracking error based on the feedback value and set value of the controlled object in the field control system. When the tracking error is greater than the preset error limit value and lasts for a first preset time period, the edge server obtains the PID control parameters based on the edge digital twin model based on the PID control process and the parameter tuning algorithm based on reinforcement learning, at least based on the output value of the PID controller in the field control system at the previous moment and the tracking error, and sends the obtained PID control parameters to the edge control system for evaluation.
[0046] Furthermore, the edge server sends the obtained PID control parameters to the edge control system for evaluation, specifically including:
[0047] The edge server sends the obtained PID control parameters to the edge control system;
[0048] The edge control system sets parameters of the PID controller in the edge control system according to the received PID control parameters, uses the set PID controller to control the operation of the edge digital twin model, and sends the obtained operation results to the edge server;
[0049] The edge server obtains an evaluation result based on the received operation result. When the evaluation result is not greater than a preset algorithm convergence threshold and lasts for a second preset time period, it is determined that the obtained PID control parameter meets the preset evaluation index; otherwise, it is determined that the obtained PID control parameter does not meet the preset evaluation index.
[0050] Furthermore, the edge server reacquires the PID control parameters and re-evaluates them, specifically including:
[0051] The edge server uses the evaluation result as a guide, utilizes the edge digital twin model and the parameter tuning algorithm to reacquire the PID control parameters, and sends the obtained PID control parameters to the edge control system for re-evaluation.
[0052] Furthermore, the expression of the preset evaluation index is: The goal of the parameter tuning algorithm is to find a set of PID control parameters that minimizes the value of the preset evaluation index and satisfies the constraints. Where k is the sampling time, e(i) is the tracking error of the controlled object in the edge control system at time i, and e(i)=y sp (i)-y(i),y sp (i) is the set value of the controlled object in the edge control system at time i, y(i) is the feedback value of the controlled object in the edge control system at time i, δ is the limit value of e(i), u(i) is i The output value of the PID controller in the edge control system at time u min is the lower limit of the amplitude of u(i), u max is the upper limit of the amplitude of u(i).
[0053] Furthermore, the network architecture of the parameter tuning algorithm includes an Actor network and a Critic network, and the steps of the parameter tuning algorithm include:
[0054] Step 1. Initialize the network parameters θ of the Actor network A 、Network parameters w of the Critic network C And the experience replay pool R, and introduce the variance σ of Gaussian noise 2 ;
[0055] Step 2: Initialize the target network parameters, let θ′A =θ A , w′ C =w C ;
[0056] Step 3. Get the model state S(k) and input it into the Actor network to get the action a(k);
[0057] Step 4: Send a(k) to the edge control system, so that the edge control system controls the operation of the edge digital twin model according to a(k);
[0058] Step 5. Get the state S(k+1) and reward function r(k);
[0059] Step 6. Store the state transition matrix [S(k), a(k), r(k), S(k+1)] into the experience replay pool R;
[0060] Step 7: Attenuate the noise variance, let σ 2 =σ 2 *ξ;
[0061] Step 8. If the experience replay pool R is full, continue to Step 9, otherwise return to Step 3;
[0062] Step 9, according to the formula Loss C =(T(k)-Q(k)) 2 The network parameters w of the Critic network C Make updates;
[0063] Step 10, according to the formula Loss A =Q(k) for the network parameters θ of the Actor network A Make updates;
[0064] Step 11, according to the formula Update the two target network parameters;
[0065] Step 12: If e(k)≤e ζ If the condition persists for t2, then continue to Step 13, otherwise return to Step 3;
[0066] Step 13: Send the adjusted PID control parameters to the edge communication device;
[0067] Among them, ξ is the noise attenuation coefficient, Loss C is the error of the Critic network, Loss Ais the error of the Actor network, T(k) is the temporal difference target, Q(k) is the action value function about the state S(k) and action a(k), ρ is the soft update learning rate, e ξ is the algorithm convergence threshold, t2 is the second preset time period, and the reward function r(k) is defined as r(k)=e 2 (k)+β1(|e(k)-δ|)+β2(|u(k)-ε|), β1 and β2 are Lagrangian operators, and β1+β2=1, e(k) is the tracking error of the controlled object in the edge control system at time k, e(k)=y sp (k)-y(k),y sp (k) is the set value of the controlled object in the edge control system at time k, y(k) is the feedback value of the controlled object in the edge control system at time k, δ is the e(k) limit value, and δ>e ξ , u(k) is the output value of the PID controller in the edge control system at time k, and ε is the u(k) limit value.
[0068] To achieve the above objectives, an embodiment of the present invention further provides a parameter tuning method for a device-edge-cloud collaborative PID controller, which is applicable to any of the above-mentioned device-edge-cloud collaborative PID controller parameter tuning systems, wherein the system includes a field control system and edge communication equipment deployed at a field end, an edge control system and edge server deployed at an edge end that are consistent with the field control system, and a cloud server deployed in the cloud; the field control system includes a controlled object controlled by the PID controller; and the method includes:
[0069] Collecting data from the field control system through the edge communication device and sending the collected data to the cloud server;
[0070] The cloud server performs parameter correction on the cloud digital twin model based on the PID control process according to the received data, and sends the obtained corrected model parameters to the edge server;
[0071] The edge server uses an edge digital twin model and a parameter tuning algorithm based on the PID control process to obtain PID control parameters and sends them to the edge control system for evaluation. When the PID control parameters do not meet the preset evaluation indicators, the PID control parameters are re-acquired and re-evaluated until the PID control parameters meet the preset evaluation indicators. When the PID control parameters meet the preset evaluation indicators, the PID control parameters that meet the preset evaluation indicators are sent to the edge communication device; wherein, when the edge server receives the corrected model parameters, it updates the edge digital twin model according to the corrected model parameters, and uses the updated edge digital twin model when obtaining the PID control parameters next time;
[0072] The received PID control parameters are sent to the PID controller in the field control system through the edge communication device to control the controlled object in the field control system.
[0073] Compared with the prior art, the embodiment of the present invention provides a parameter tuning system and method for a PID controller in end-edge-cloud collaboration, which collects data from the field control system through edge communication equipment and sends the collected data to the cloud server; the cloud server performs parameter correction on the cloud digital twin model based on the PID control process according to the received data, and sends the obtained corrected model parameters to the edge server; the edge server obtains the PID control parameters by using the edge digital twin model based on the PID control process and the parameter tuning algorithm and sends them to the edge control system for evaluation. When the PID control parameters do not meet the preset evaluation indicators, the PID control parameters are obtained again and re-evaluated until the PID control parameters meet the preset evaluation indicators. When the PID control parameters When the preset evaluation indicators are met, the PID control parameters that meet the preset evaluation indicators are sent to the edge communication device, and when the edge server receives the corrected model parameters, it updates the edge digital twin model according to the corrected model parameters, and uses the updated edge digital twin model the next time the PID control parameters are obtained; the received PID control parameters are sent to the PID controller in the field control system through the edge communication device to control the controlled object in the field control system; thereby solving the original problem of manual parameter adjustment based on engineer experience, which is time-consuming and labor-intensive, and the problem of control performance degradation due to changes in dynamic characteristics, and can realize automatic tuning of PID control parameters during the operation of the control system, improve control performance, and ensure that the system maintains good control effects for a long time. BRIEF DESCRIPTION OF THE DRAWINGS
[0074] Figure 1 This is a structural diagram of a preferred embodiment of a parameter tuning system for a device-edge-cloud collaborative PID controller provided by the present invention;
[0075] Figure 2 This is a structural diagram of a PID control parameter tuning process for device-edge-cloud collaboration provided by an embodiment of the present invention;
[0076] Figure 3 This is a structural diagram of a cloud digital twin model of a PID control process with device-edge-cloud collaboration provided by an embodiment of the present invention;
[0077] Figure 4 This is a structural diagram of a nonlinear compensation model in a cloud digital twin model of a PID control process in device-edge-cloud collaboration provided by an embodiment of the present invention;
[0078] Figure 5 1 is a schematic diagram of a network architecture of a parameter tuning algorithm based on reinforcement learning provided by an embodiment of the present invention;
[0079] Figure 6 1 is a schematic diagram of the structure of an Actor network in a parameter tuning algorithm based on reinforcement learning provided by an embodiment of the present invention;
[0080] Figure 7 1 is a schematic diagram of the structure of a critic network in a parameter tuning algorithm based on reinforcement learning provided by an embodiment of the present invention;
[0081] Figure 8 This is a schematic diagram of the structure of the hardware platform of a device-edge-cloud collaborative PID controller parameter tuning system provided by an embodiment of the present invention;
[0082] Figure 9 It is a flowchart of a preferred embodiment of a parameter tuning method for an end-edge-cloud collaborative PID controller provided by the present invention. DETAILED DESCRIPTION
[0083] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. All other embodiments obtained by ordinary technicians in this technical field based on the embodiments of the present invention without making any creative efforts shall fall within the scope of protection of the present invention.
[0084] The embodiment of the present invention provides a parameter tuning system for a PID controller in a device-edge-cloud collaborative manner. Figure 1FIG2 is a schematic diagram showing a preferred embodiment of a parameter tuning system for a device-edge-cloud collaborative PID controller provided by the present invention. The system includes a field control system and edge communication equipment deployed on the field side, an edge control system and edge server deployed on the edge side that are consistent with the field control system, and a cloud server deployed on the cloud side. The field control system includes a controlled object controlled by the PID controller.
[0085] The edge communication device is used to collect data from the field control system and send the collected data to the cloud server;
[0086] The cloud server is used to perform parameter correction on the cloud digital twin model based on the PID control process according to the received data, and send the obtained corrected model parameters to the edge server;
[0087] The edge server is used to obtain PID control parameters using an edge digital twin model and a parameter tuning algorithm based on a PID control process and send them to the edge control system for evaluation. When the PID control parameters do not meet the preset evaluation indicators, the PID control parameters are re-acquired and re-evaluated until the PID control parameters meet the preset evaluation indicators. When the PID control parameters meet the preset evaluation indicators, the PID control parameters that meet the preset evaluation indicators are sent to the edge communication device;
[0088] The edge server is further configured to update the edge digital twin model according to the corrected model parameters when receiving the corrected model parameters, and use the updated edge digital twin model when acquiring the PID control parameters next time;
[0089] The edge communication device is further configured to send the received PID control parameters to the PID controller in the field control system to control the controlled object in the field control system.
[0090] Combine Figure 1As shown, the system is mainly distributed on the field side and the laboratory side, and the field side and the laboratory side can communicate through a firewall and a switch (using a 4G network); wherein, the field side mainly includes a field control system and edge communication equipment deployed on the field end, the field control system includes a PID controller, which is used to control the controlled object in the industrial production process through a bus, and the field control system and the edge communication equipment can communicate through a switch (using the TCP / IP protocol); the laboratory side mainly includes an edge control system and an edge server deployed on the edge end, the edge control system runs a PID controller and a control scheme for the controlled object that are completely consistent with the field control system, and the edge control system and the edge server can communicate; the laboratory side also includes a cloud server deployed on the cloud, and the cloud server and the edge server can communicate.
[0091] When implementing the parameter tuning of the PID controller, the edge communication device is mainly used to collect data from the field control system. For example, data can be collected periodically according to a preset time interval and the collected data can be sent to the cloud server; the cloud server is mainly used to perform parameter correction on the pre-set cloud digital twin model based on the PID control process according to the currently received data and all previously received data after receiving the data sent by the edge communication device (the cloud server uses the continuously collected big data of the on-site production process to correct the model. As the number of data collection increases, more and more data is collected, and the corrected model becomes more and more accurate), and the corrected model parameters are obtained accordingly. If the accuracy of the edge digital twin model based on the PID control process at the edge does not meet the preset requirements, the cloud server will send the latest corrected model parameters to the edge server; the edge server is mainly used to obtain PID control parameters (PID control parameters specifically include but are not limited to K) by using the pre-set edge digital twin model based on the PID control process and parameter tuning algorithm when PID control parameter tuning is required. p , K i and K dPID controller parameters including the PID control parameters), and the obtained PID control parameters are sent to the edge control system to evaluate the obtained PID control parameters. When the obtained PID control parameters are determined to not meet the preset evaluation indicators according to the evaluation results, the PID control parameters are re-obtained using the edge digital twin model and the parameter tuning algorithm, and the re-obtained PID control parameters are evaluated using the edge control system until the obtained PID control parameters are determined to meet the preset evaluation indicators. When the obtained PID control parameters are determined to meet the preset evaluation indicators according to the evaluation results, the PID control parameters that meet the preset evaluation indicators are sent to the edge communication device. In the process of obtaining the PID control parameters, when the edge server receives the corrected model parameters sent by the cloud server, it is necessary to update the edge digital twin model accordingly according to the corrected model parameters, and use the updated edge digital twin model the next time and each subsequent time the PID control parameters are obtained. The edge communication device is also used to send the received PID control parameters to the field control system when receiving the PID control parameters that meet the preset evaluation indicators sent by the edge server. The field control system sets the parameters of the PID controller in the field control system according to the received PID control parameters, and controls the operation of the PID controller after the parameter setting to control the controlled object in the field control system.
[0092] It should be noted that the cloud digital twin model on the cloud side and the edge digital twin model on the edge side have the same structure. When the accuracy of the edge digital twin model does not meet the requirements, it will affect the PID parameter tuning results, thereby affecting the control effect of the industrial production process. Therefore, when the accuracy of the edge digital twin model does not meet the requirements, the edge digital twin model needs to be updated to meet the accuracy requirements to ensure that the edge digital twin model used in the PID parameter tuning process is consistent with the actual PID control process of the controlled object. In an embodiment of the present invention, the update of the edge digital twin model is achieved based on the model self-correction mechanism of the cloud. The cloud server uses the continuously collected on-site production process big data to perform parameter correction on the cloud digital twin model (parameter correction is performed once every fixed time interval) and obtains the corrected model parameters accordingly. When the accuracy of the edge digital twin model does not meet the requirements, the cloud server triggers the model self-correction mechanism and sends the latest corrected model parameters to the edge server. Once the edge server receives the corrected model parameters sent by the cloud server, it updates the edge digital twin model accordingly according to the received corrected model parameters to ensure the accuracy of the edge digital twin model used in the PID parameter tuning process, thereby ensuring the accuracy of the parameter tuning.
[0093] It should be noted that when the edge server is actually performing PID parameter tuning, it generally needs to execute at least one "obtain PID control parameters-evaluate PID control parameters" loop tuning process. In each cycle, "obtaining PID control parameters" is based on the edge digital twin model and PID control parameter self-tuning mechanism at the edge, and "evaluating PID control parameters" is based on the PID control parameter evaluation mechanism at the edge and the edge control system. Since the edge server will also update the edge digital twin model according to the received corrected model parameters after receiving the corrected model parameters sent by the cloud server, the entire PID parameter tuning process may involve the update of the edge digital twin model. For example, if you are executing the current " During the loop tuning process of "obtaining PID control parameters-evaluating PID control parameters", if the edge digital twin model is updated, the updated edge digital twin model will be used to obtain the PID control parameters during the next and subsequent loop tuning processes of "obtaining PID control parameters-evaluating PID control parameters". If the edge digital twin model is updated again during a subsequent loop tuning process of "obtaining PID control parameters-evaluating PID control parameters", the updated edge digital twin model will be used to obtain the PID control parameters during the next and subsequent loop tuning processes of "obtaining PID control parameters-evaluating PID control parameters". Once the edge digital twin model is found to be updated, the updated edge digital twin model will be used to obtain the PID control parameters to ensure model accuracy and thus obtain more accurate PID control parameters.
[0094] See also Figure 2 The figure is a structural diagram of a PID control parameter tuning process of end-edge-cloud collaboration provided by an embodiment of the present invention. The parameter tuning process mainly consists of a PID controller, a PID control process edge digital twin model and a PID control parameter tuning algorithm; wherein, the input of the PID controller is the set value y sp The error e(k) between the model feedback value y(k) and the output of the PID control parameter tuning algorithm [K p ,K i ,K d ], the output is u(k); the input of the digital twin model of the PID control process is the output u(k) of the PID controller, and the output is y(k+1); the input of the PID control parameter tuning algorithm is the output u(k-1) of the PID controller at the previous moment, the set value y spThe error e(k) between the PID controller (k) and the model feedback value y(k), the error change rate Δe(k), and the quadratic error change rate Δ(Δe(k)). The PID controller and the PID control process edge digital twin model form a reinforcement learning interactive environment. The PID control process edge digital twin model operates under a self-tuning mechanism. When control performance deteriorates, the edge end adjusts the PID control parameters to update the PID controller's control parameters, thereby ensuring control performance.
[0095] For example, in the mineral processing industry production process, feed rate control is a key control loop in production. Since the feed rate is affected by frequent fluctuations in the quality of the products of the previous crushing process and large-scale frequent interference of unknown return ore, the feed rate fluctuates frequently, making it difficult for the PID controller to achieve the expected control effect. For this complex industrial process, a parameter tuning system of a PID controller with end-edge-cloud collaboration provided by an embodiment of the present invention can be used to tune the parameters of the PID controller in the feed rate control loop.
[0096] In the application scenario of feed rate control in the mineral processing process, the field control system consists of PLC, IO module and underlying equipment. The PLC control system obtains the real-time reading of the belt scale set on site through the IO module, performs range conversion and filtering on the obtained data, and sends the processed data to the PID control module (i.e. PID controller) inside the PLC control system. The module calculates the output control quantity, i.e. the frequency of the vibrating feeder, and sends the frequency to the feeder through the IO module to control the operation of the feeder; the edge communication equipment is connected to the PLC control system through the TCP / IP protocol to collect relevant data of the feed rate control loop, such as feed rate, vibration feeding, etc. The collected data, such as machine frequency and start-stop signals, belt current, and feed bin material level, are sent to the cloud through the 4G network module of the edge communication device. The cloud can use the data collected by the edge communication device to establish a cloud digital twin model based on the PID control process. Under the action of the model self-correction mechanism, when the accuracy of the edge digital twin model based on the PID control process does not meet the requirements, the cloud will transmit the latest corrected model parameters to the edge end. When the edge end completes the model update and obtains the PID control parameters that meet the requirements through parameter tuning, it will send the parameters to the edge communication device, and the edge communication device will then write the parameters into the on-site PLC control system for control.
[0097] Compared with the control effect corresponding to the PID control parameters obtained by the discrete ZN tuning method, by applying the parameter tuning system of the end-edge-cloud collaborative PID controller provided by the embodiment of the present invention, the mean square error (MSE) corresponding to the feed rate feedback value is 12.6932, a decrease of 44.58%, and the mean absolute error (MAE) is 1.856, a decrease of 45.09%, and the control effect is significantly improved.
[0098] An embodiment of the present invention provides a parameter tuning system for a device-edge-cloud collaborative PID controller. This system introduces the system architecture of a device-edge-cloud system. The cloud implements parameter calibration of the digital twin model based on big data by running a cloud digital twin model based on the PID control process. The edge implements automatic tuning of the PID control parameters by running the edge digital twin model and a parameter tuning algorithm based on the PID control process and performing parameter evaluation. This solves the problem of time-consuming and labor-intensive manual parameter adjustment based on engineer experience and the problem of control performance degradation due to dynamic characteristic changes. It can automatically tune the PID control parameters during control system operation, improve control performance, ensure that the system maintains good control effects over the long term, and thus improve the stability of system operation. At the same time, the powerful data storage and computing power of the cloud are utilized to perform parameter calibration of the digital twin model in real time, improving the accuracy of the model. The system is independent of the control system of the industrial process, is easy to deploy, does not introduce security issues, and has high security. In addition, the system allows operators to manually modify parameters according to on-site conditions or the system to automatically update control parameters, reducing the intensity of system maintenance work and increasing the flexibility of parameter tuning.
[0099] As a preferred solution, the cloud digital twin model consists of a linear model and a nonlinear compensation model; the expression of the cloud digital twin model is: Wherein, b0u(k-1-d)+c0 is the linear model, b0 and c0 are model parameters, is the nonlinear compensation model, a0 is the model parameter, k is the sampling time, d is the delay time, u(k) is the output value of the PID controller in the field control system, K p , K i and K d is the control parameter of the PID controller in the field control system, e(k) is the tracking error of the controlled object in the field control system, e(k)=y sp (k)-y(k),y sp (k) is the set value of the controlled object in the field control system, and y(k) is the feedback value of the controlled object in the field control system.
[0100] Specifically, in combination with the above embodiment, the cloud digital twin model based on the PID control process and the edge digital twin model based on the PID control process are both models corresponding to the controlled object (or controlled process) on site. Here, the model structure of the cloud digital twin model is used as an example for explanation:
[0101] See also Figure 3 As shown in FIG, a schematic diagram of the structure of a PID control process cloud digital twin model of end-edge-cloud collaboration provided by an embodiment of the present invention is shown. The controlled object with first-order inertia lag can be expressed as formula (1):
[0102] (1+a0z -1 )y(k)=z -d b0u(k)+v(k), in formula (1), u(k) is the input value of the controlled object (that is, the output value of the PID controller), y(k) is the feedback value of the controlled object, v(k) is the output value of the nonlinear dynamic compensation system, k is the sampling time of data acquisition, d is the delay time of the control system, and a0 and b0 are model parameters;
[0103] For the discrete incremental PID controller, its expression is formula (2):
[0104] u(k)=u(k-1)+K p [e(k)-e(k-1)]+K i e(k)+K d [e(k)-2e(k-1)+e(k-2)], in formula (2), K p , K i and K d is the control parameter of the PID controller, e(k) is the tracking error of the controlled object, e(k)=y sp (k)-y(k),y sp (k) is the set value of the controlled object, and y(k) is the feedback value of the controlled object;
[0105] Substituting formula (2) into formula (1), the closed-loop equation is obtained as formula (3):
[0106]
[0107] According to formula (3), the first-order inertia lag controlled object model with u(k) as input and y(k) as output after the introduction of the incremental PID controller can be expressed as formula (4):
[0108]
[0109] According to formula (4), the expression of the PID control process cloud digital twin model can be obtained as formula (5):
[0110] In formula (5), b0u(k-1-d)+c0 is the linear model in the cloud digital twin model, b0 and c0 are model parameters, It is the nonlinear compensation model in the cloud digital twin model. a0 is the model parameter (the model parameters of the linear model can be obtained by parameter identification using the least squares method, and the model parameters of the nonlinear compensation model can be obtained by fitting based on self-correction deep learning).
[0111] It should be noted that, combined with Figure 4 As shown in the figure, it is a structural diagram of a nonlinear compensation model in a PID control process cloud digital twin model of an end-edge-cloud collaboration provided by an embodiment of the present invention. The model architecture of the nonlinear compensation model adopts a deep learning network based on the LSTM-Attention structure. The LSTM layer and the fully connected layer select the ReLU activation function. The model input of the nonlinear compensation model is X=[v,u,y,(r1,...,r n )],in, v is the compensation value of the high-order nonlinear model, u is the control input, y is the model feedback, r i are other process variables, and n is the number of neurons in the network.
[0112] As a preferred solution, the edge communication device collects data from the field control system, specifically including:
[0113] The edge communication device collects data on at least the output value of the PID controller in the field control system, the feedback value and the set value of the controlled object in the field control system;
[0114] Then, the cloud server performs parameter correction on the cloud digital twin model based on the PID control process according to the received data, specifically including:
[0115] The cloud server performs parameter correction on the cloud digital twin model based on the PID control process based at least on the received output value of the PID controller in the field control system, the feedback value and set value of the controlled object in the field control system, and obtains the corrected model parameters; wherein the model parameters include weight parameters and bias parameters.
[0116] Specifically, in combination with the above embodiment, the model parameters of the cloud digital twin model based on the PID control process are at least related to the output value u(k) of the PID controller, the feedback value y(k) of the controlled object and the set value y sp(k), and all loop-related process variables including other process influencing factors in the field control system (for example, in the application of the above-mentioned mineral processing project, it is also related to data such as belt current r1(k), silo material level r2(k)). Therefore, when the edge communication device is collecting data, it can at least monitor the output value u(k) of the PID controller in the field control system, the feedback value y(k) of the controlled object in the field control system, and the set value y sp (k) can be used to collect data, and data can also be collected for all loop-related process variables including other process influencing factors in the field control system. Accordingly, when the cloud server performs parameter correction on the cloud digital twin model based on the PID control process according to all received data, it can at least collect the output value u(k) of the PID controller in the field control system, the feedback value y(k) of the controlled object in the field control system, and the set value y in real time according to all received edge communication devices. sp (k) and all loop-related process variables including other process influencing factors in the field control system are used to perform parameter correction on the cloud digital twin model based on the PID control process, and correspondingly obtain the corrected model parameters, which include the corrected weight parameters and bias parameters.
[0117] It should be noted that the specific model parameter correction scheme can be implemented using existing correction methods, and it is allowed to adaptively adjust the existing correction method based on the characteristics of the embodiment of the present invention to be applicable to the embodiment of the present invention.
[0118] Combine Figure 1 As shown, as a preferred solution, the cloud server is also used to store the received data in a database;
[0119] Then, the cloud server performs parameter correction on the cloud digital twin model based on the PID control process according to the received data, specifically including:
[0120] The cloud server performs data preprocessing on the data stored in the database, and performs parameter correction on the cloud digital twin model based on the PID control process according to the preprocessed data.
[0121] Specifically, in combination with the above embodiments, each time the cloud server receives the collected data of the field control system sent by the edge communication device, it is also used to store the received data in a pre-set database (such as a MySQL database) for subsequent use. In order to ensure the correctness, validity and accuracy of the data self-correction, when the cloud server performs parameter correction on the cloud digital twin model based on the PID control process, it first preprocesses all the data stored in the database, and then performs parameter correction on the cloud digital twin model based on the PID control process based on the preprocessed data.
[0122] It should be noted that data preprocessing includes filtering inevitable measurement noise and data outliers in industrial production data, removing outliers from the data, and other means, which are not specifically limited in the embodiment of the present invention.
[0123] As a preferred solution, the cloud server sends the obtained corrected model parameters to the edge server, specifically including:
[0124] The cloud server obtains a first comprehensive score of the cloud digital twin model and a second comprehensive score of the edge digital twin model based on the PID control process. When the difference between the first comprehensive score and the second comprehensive score is greater than a preset first score threshold, the obtained corrected model parameters are sent to the edge server.
[0125] Specifically, in combination with the above embodiment, when the accuracy of the edge digital twin model does not meet the requirements, the cloud server will trigger the model self-correction mechanism and send the latest corrected model parameters to the edge server. Therefore, before sending the latest corrected model parameters to the edge server, the cloud server needs to further judge whether the accuracy of the edge digital twin model meets the requirements to determine whether the latest corrected model parameters need to be sent to the edge server. The embodiment of the present invention provides a judgment scheme based on model evaluation. In the specific implementation, the cloud server first performs a model evaluation on the cloud digital twin model and obtains a first comprehensive score S corresponding to the cloud digital twin model. cloud , and obtain the second comprehensive score S corresponding to the edge digital twin model at the edge edge (Second comprehensive score S edge The edge server can obtain the corresponding model evaluation of the edge digital twin model and send it to the cloud server, or the cloud server can directly obtain the corresponding model evaluation of the edge digital twin model) and then calculate the first comprehensive score S cloud With the second comprehensive score S edge The difference between the two values is calculated and the difference is compared with the preset first scoring threshold S min1 When the first comprehensive score S is comparedcloud With the second comprehensive score S edge The difference between them is greater than the preset first scoring threshold S min1 When (i.e., satisfying S cloud -S edge >S min1 ), if it is determined that the accuracy of the edge digital twin model does not meet the requirements, the cloud server will send the latest corrected model parameters to the edge server. Otherwise, there is no need to send the corrected model parameters to the edge server.
[0126] As a preferred solution, the calculation formula for the first comprehensive score is: Among them, MSE s , RMSE s 、R 2 s 、TPR s and TNR s They are mean square error MSE, root mean square error RMSE, and goodness of fit R 2 The scores of the five evaluation indicators, true positive rate TPR and true negative rate TNR, are calculated as follows:
[0127]
[0128]
[0129]
[0130]
[0131]
[0132] MSE max , RMSE max 、R 2 min 、TPR min and TNR min They are mean square error MSE, root mean square error RMSE, and goodness of fit R 2 , the thresholds of the five evaluation indicators: true positive rate TPR and true negative rate TNR.
[0133] Specifically, in combination with the above embodiment, the cloud server obtains the first comprehensive score S corresponding to the cloud digital twin model cloud When you can use MSE (Mean Square Error, mean square error), RMSE (Root Mean Square Error, root mean square error), R 2The cloud digital twin model is evaluated by five evaluation indicators: goodness of fit (TPR), true positive rate (TPR), and true negative rate (TNR). The scores corresponding to the five evaluation indicators are obtained, and the scores are calculated based on the mean square error (MSE), root mean square error (RMSE), goodness of fit (R 2 The first comprehensive score S is obtained by calculating the scores corresponding to the five evaluation indicators: true positive rate TPR and true negative rate TNR cloud , the first comprehensive score S cloud The calculation formula is as follows: Among them, MSE s , RMSE s 、R 2 s 、TPR s and TNR s They are the mean square error MSE, root mean square error RMSE, and goodness of fit R of the cloud digital twin model. 2 , the scores corresponding to the five evaluation indicators of true rate TPR and true negative rate TNR, MSE s , RMSE s 、R 2 s 、TPR s and TNR s The calculation formulas are:
[0134]
[0135]
[0136]
[0137]
[0138]
[0139] MSE max , RMSE max 、R 2 min 、TPR min and TNR min They are the mean square error MSE, root mean square error RMSE, and goodness of fit R of the cloud digital twin model. 2 , the thresholds corresponding to the five evaluation indicators: true positive rate TPR and true negative rate TNR.
[0140] It should be noted that the mean square error MSE, root mean square error RMSE, and goodness of fit R 2The calculation formulas corresponding to the five evaluation indicators of true positive rate TPR and true negative rate TNR are: y i (k) represents the feedback value of the controlled object in the field control system collected for the i-th time, represents the output value of the cloud digital twin model collected for the i-th time. The definitions of TP, FP, TN and FN are shown in Table 1, where Δy(k+1)=y(k+1)-y(k).
[0141] Table 1 Relationship between TP, FP, TN and FN
[0142]
[0143] It can be understood that the second comprehensive score S corresponding to the edge digital twin model edge The calculation method and the first comprehensive score S corresponding to the cloud digital twin model cloud The calculation method is similar, just replace It can be replaced with the output value of the edge digital twin model. The specific calculation process will not be repeated here.
[0144] As a preferred solution, the edge server uses an edge digital twin model and parameter tuning algorithm based on the PID control process to obtain PID control parameters and sends them to the edge control system for evaluation, specifically including:
[0145] The edge server obtains a third comprehensive score of the controlled object in the field control system. When the third comprehensive score is less than a preset second score threshold, the edge server uses an edge digital twin model and a parameter tuning algorithm based on the PID control process to obtain PID control parameters and sends them to the edge control system for evaluation.
[0146] Specifically, in combination with the above embodiment, the edge server will trigger the PID control parameter self-tuning mechanism only when PID control parameter tuning is needed. Therefore, before the edge server uses the edge digital twin model and parameter tuning algorithm based on the PID control process to obtain the PID control parameters and sends them to the edge control system for evaluation, it is necessary to further determine whether PID control parameter tuning is needed to determine whether the control parameters of the PID controller in the field control system meet the changing working conditions in the field. In specific implementation, the edge server analyzes the PID control effect in the field control system to obtain the third comprehensive score S corresponding to the controlled object in the field control system. field , and the third comprehensive score S field and the preset second scoring threshold S min2 When compared, the third comprehensive score Sfield Less than the preset second scoring threshold S min2 When (i.e., satisfying S field min2 ), and determines that PID parameter tuning is required, the edge server uses the edge digital twin model and parameter tuning algorithm based on the PID control process to obtain the PID control parameters and send them to the edge control system for evaluation.
[0147] It should be noted that the edge server can periodically splice the control effect of the field control system, as long as it finds the third comprehensive score S field Satisfy S field min2 , it triggers the PID control parameter self-tuning mechanism at the edge end, thereby realizing the parameter update of the PID controller in the field control system.
[0148] As a preferred solution, the calculation formula for the third comprehensive score is:
[0149] Among them, MEI s 、IAEI s 、IAE s 、ISE s 、TVy s 、OS s 、TVu s 、CIM s , CMSF and AP s The scores of the ten evaluation indicators are respectively the maximum value of the exceeded interval MEI, the absolute cumulative sum of exceeded interval IAEI, the absolute error cumulative sum IAE, the error square sum ISE, the fluctuation cumulative sum TVy, the overshoot OS, the input fluctuation cumulative sum TVu, the input mean CIM, the input vibration degree CMSF and the utilization rate AP. The calculation formula for each score is:
[0150]
[0151]
[0152]
[0153]
[0154]
[0155]
[0156]
[0157]
[0158]
[0159]
[0160] MEI max 、IAEI max 、IAE max 、ISE max 、TVy max 、OS max 、TVu max 、CIM max , CMSF max and AP min They are the thresholds of the ten evaluation indicators, namely, the maximum value of the interval exceeded MEI, the absolute cumulative sum exceeded IAEI, the absolute error cumulative sum IAE, the error square sum ISE, the fluctuation cumulative sum TVy, the overshoot OS, the input fluctuation cumulative sum TVu, the input mean CIM, the input vibration degree CMSF and the utilization rate AP.
[0161] Specifically, in combination with the above embodiment, the edge server obtains the third comprehensive score S field When the control effect of the field control system is analyzed, the ten evaluation indicators, including the maximum value of the exceeded interval MEI, the absolute cumulative sum of exceeded interval IAEI, the absolute error cumulative sum IAE, the error square sum ISE, the fluctuation cumulative sum TVy, the overshoot OS, the input fluctuation cumulative sum TVu, the input mean CIM, the input vibration degree CMSF and the utilization rate AP, can be used to analyze the control effect of the field control system, and the scores corresponding to the ten evaluation indicators can be obtained accordingly. The third comprehensive score S is calculated based on the scores corresponding to the ten evaluation indicators. field , the third comprehensive score S field The calculation formula is as follows:
[0162] Among them, MEI s 、IAEI s 、IAE s 、ISE s 、TVy s 、OS s 、TVu s 、CIM s , CMSF and AP s The scores corresponding to the ten evaluation indicators of the field control system are respectively the maximum value of the exceeded interval MEI, the absolute cumulative sum of the exceeded interval IAEI, the absolute error cumulative sum IAE, the error square sum ISE, the fluctuation cumulative sum TVy, the overshoot OS, the input fluctuation cumulative sum TVu, the input mean CIM, the input vibration degree CMSF and the utilization rate AP. MEI s 、IAEIs 、IAE s 、ISE s 、TVy s 、OS s 、TVu s 、CIM s , CMSF and AP s The calculation formulas are:
[0163]
[0164]
[0165]
[0166]
[0167]
[0168]
[0169]
[0170]
[0171]
[0172]
[0173] MEI max 、IAEI max 、IAE max 、ISE max 、TVy max 、OS max 、TVu max 、CIM max , CMSF max and AP min These are the thresholds corresponding to the ten evaluation indicators of the field control system, namely, the maximum value of the exceeded interval MEI, the absolute cumulative sum of the exceeded interval IAEI, the cumulative absolute error IAE, the sum of squared errors ISE, the cumulative fluctuation TVy, the overshoot OS, the cumulative input fluctuation TVu, the input mean CIM, the input vibration degree CMSF and the utilization rate AP.
[0174] It should be noted that the calculation formulas corresponding to the ten evaluation indicators, namely, the maximum value of the exceeded interval MEI, the absolute cumulative sum of exceeded interval IAEI, the cumulative absolute error IAE, the error square sum ISE, the cumulative fluctuation TVy, the overshoot OS, the cumulative input fluctuation TVu, the input mean CIM, the input vibration degree CMSF and the utilization rate AP, are as follows: Among them, y(k) is the feedback value of the controlled object in the field control system, y sp (k) is the set value of the controlled object in the field control system, δ is the threshold of the allowable fluctuation range, N is the length of the evaluation data window, y max is the maximum feedback value in the collected data, y final is the feedback value of the window length at the last moment, auto is the manual-automatic flag of the control loop in the field control system. auto=True means it is automatically put into use, and auto=False means it is manually put into use.
[0175] As a preferred solution, the cloud server is further configured to send the received data to the edge server; wherein the data includes at least the output value of the PID controller in the field control system, the feedback value and the set value of the controlled object in the field control system;
[0176] Then, the edge server uses the edge digital twin model and parameter tuning algorithm based on the PID control process to obtain the PID control parameters and send them to the edge control system for evaluation, specifically including:
[0177] The edge server calculates the tracking error based on the feedback value and set value of the controlled object in the field control system. When the tracking error is greater than the preset error limit value and lasts for a first preset time period, the edge server obtains the PID control parameters based on the edge digital twin model based on the PID control process and the parameter tuning algorithm based on reinforcement learning, at least based on the output value of the PID controller in the field control system at the previous moment and the tracking error, and sends the obtained PID control parameters to the edge control system for evaluation.
[0178] Specifically, in combination with the above embodiment, the cloud server receives the collected data of the field control system sent by the edge communication device (including at least the output value u(k) of the PID controller in the field control system, the feedback value y(k) of the controlled object in the field control system and the set value y sp (k), and all loop-related process variables including other process influencing factors in the field control system) are also used to send the received data to the edge server; accordingly, after receiving the data sent by the cloud server, the edge server receives the feedback value y(k) and the set value y of the controlled object in the field control system. sp(k), calculate the tracking error e(k) = y sp (k)-y(k), and compare the tracking error e(k) with the preset error limit value δ to determine whether it is necessary to trigger the PID control parameter self-tuning mechanism of the edge end according to the comparison result. When e(k)>δ and the state of e(k)>δ is maintained for a continuous first preset time period, it is determined that the PID control parameter self-tuning mechanism of the edge end needs to be triggered. Then, based on at least the output value u(k-1) of the PID controller at the previous moment and the current tracking error e(k) in the field control system, combined with the error change rate Δe(k) and the error quadratic change rate Δ(Δe(k)) of the tracking error e(k), the PID control parameters are obtained using the edge digital twin model based on the PID control process and the parameter tuning algorithm based on reinforcement learning, and the obtained PID control parameters are sent to the edge control system for evaluation.
[0179] It can be understood that when the tracking error e(k) does not satisfy "e(k)>δ and maintains the state of e(k)>δ for a continuous first preset time period", it means that the tracking error of the control system is still within the allowable error range, and the current PID control parameters can still ensure good control effects, so there is no need to trigger the PID control parameter self-tuning mechanism at the edge end.
[0180] As a preferred solution, the edge server sends the obtained PID control parameters to the edge control system for evaluation, specifically including:
[0181] The edge server sends the obtained PID control parameters to the edge control system;
[0182] The edge control system sets parameters of the PID controller in the edge control system according to the received PID control parameters, uses the set PID controller to control the operation of the edge digital twin model, and sends the obtained operation results to the edge server;
[0183] The edge server obtains an evaluation result based on the received operation result. When the evaluation result is greater than a preset algorithm convergence threshold, it is determined that the obtained PID control parameter does not meet the preset evaluation index. When the evaluation result is not greater than the preset algorithm convergence threshold and lasts for a second preset time period, it is determined that the obtained PID control parameter meets the preset evaluation index.
[0184] Specifically, in combination with the above embodiment, when the edge server sends the obtained PID control parameters to the edge control system for evaluation, the obtained PID control parameters can be sent to the edge control system; the edge control system sets the parameters of the PID controller in the edge control system according to the received PID control parameters, and uses the PID controller after parameter setting to control the operation of the edge digital twin model at the edge end, and obtains the operation results corresponding to the current PID control parameters (including relevant data in the PID control process), and returns the obtained operation results to the edge server; after receiving the operation results returned by the edge control system, the edge server obtains the evaluation results according to the received operation results (that is, obtains the tracking error of the controlled object in the edge control system), and compares the obtained evaluation results with the preset algorithm convergence threshold e ξ Compare the PID control parameters to determine whether they meet the preset parameter evaluation index according to the comparison results. If the evaluation result is not greater than the preset algorithm convergence threshold e, ξ And the algorithm convergence threshold value e is maintained within the second preset time period. ξ , it is determined that the currently obtained PID control parameters meet the preset evaluation index; otherwise, it is determined that the currently obtained PID control parameters do not meet the preset evaluation index.
[0185] As a preferred solution, the edge server reacquires the PID control parameters and re-evaluates them, specifically including:
[0186] The edge server uses the evaluation result as a guide, utilizes the edge digital twin model and the parameter tuning algorithm to reacquire the PID control parameters, and sends the obtained PID control parameters to the edge control system for re-evaluation.
[0187] Specifically, in combination with the above embodiments, when it is determined that the currently obtained PID control parameters do not meet the preset evaluation indicators, the edge server needs to re-acquire the PID control parameters and re-evaluate them, and in the actual execution process, the evaluation results obtained based on the currently obtained PID control parameters can be used as a guide to feed back the evaluation results to the PID control parameter self-tuning mechanism, and use the edge digital twin model and the parameter tuning algorithm based on reinforcement learning at the edge to re-acquire the PID control parameters, and send the re-acquired PID control parameters to the edge control system for re-evaluation, and perform corresponding processing based on the evaluation results.
[0188] As a preferred solution, the expression of the preset evaluation index is: The goal of the parameter tuning algorithm is to find a set of PID control parameters that minimizes the value of the preset evaluation index and satisfies the constraints. Where k is the sampling time, e(i) is the tracking error of the controlled object in the edge control system at time i, and e(i)=y sp (i)-y(i),y sp (i) is the set value of the controlled object in the edge control system at time i, y(i) is the feedback value of the controlled object in the edge control system at time i, δ is the limit value of e(i), u(i) is the output value of the PID controller in the edge control system at time i, u min is the lower limit of the amplitude of u(i), u max is the upper limit of the amplitude of u(i).
[0189] Specifically, in combination with the above embodiment, the goal of the parameter tuning algorithm based on reinforcement learning is: Under the constraints of The PID control parameter with the minimum value J(k) is selected. However, since there are unknown terms in the process of solving the minimum value of J(k), it cannot be solved directly. J(k) is related to the tracking error of the controlled object. Therefore, it can be judged whether J(k) reaches the minimum value by the tracking error of the controlled object. According to the above embodiment, the PID control parameter meets the preset evaluation index, which means that the edge control system obtains the operation result based on this set of PID control parameters, and the edge server obtains the evaluation result e(k) according to the operation result of the edge control system, and satisfies e(k)≤e ξ And keep e(k)≤e within the second preset time period ξ Therefore, we can judge whether the evaluation result e(k) satisfies “e(k)≤e ξ And keep e(k)≤e within the second preset time period ξ The condition of "state" is used to judge whether the corresponding PID control parameters meet the preset evaluation indicators (that is, whether the value of J(k) can be minimized).
[0190] As a preferred solution, the network architecture of the parameter tuning algorithm includes an Actor network and a Critic network, and the steps of the parameter tuning algorithm include:
[0191] Step 1. Initialize the network parameters θ of the Actor network A 、Network parameters w of the Critic network C And the experience replay pool R, and introduce the variance σ of Gaussian noise 2 ;
[0192] Step 2: Initialize the target network parameters, let θ′ A =θ A , w′ C =wC ;
[0193] Step 3. Get the model state S(k) and input it into the Actor network to get the action a(k);
[0194] Step 4: Send a(k) to the edge control system, so that the edge control system controls the operation of the edge digital twin model according to a(k);
[0195] Step 5. Get the state S(k+1) and reward function r(k);
[0196] Step 6. Store the state transition matrix [S(k), a(k), r(k), S(k+1)] into the experience replay pool R;
[0197] Step 7: Attenuate the noise variance, let σ 2 =σ 2 *ξ;
[0198] Step 8. If the experience replay pool R is full, continue to Step 9, otherwise return to Step 3;
[0199] Step 9, according to the formula Loss C =(T(k)-Q(k)) 2 The network parameters w of the Critic network C Make updates;
[0200] Step 10, according to the formula Loss A =Q(k) for the network parameters θ of the Actor network A Make updates;
[0201] Step 11, according to the formula Update the two target network parameters;
[0202] Step 12: If e(k)≤e ζ If the condition persists for t2, then continue to Step 13, otherwise return to Step 3;
[0203] Step 13: Send the adjusted PID control parameters to the edge communication device;
[0204] Among them, ξ is the noise attenuation coefficient, Loss C is the error of the Critic network, Loss A is the error of the Actor network, T(k) is the temporal difference target, Q(k) is the action value function about the state S(k) and action a(k), ρ is the soft update learning rate, e ξis the algorithm convergence threshold, t2 is the second preset time period, and the reward function r(k) is defined as r(k)=e 2 (k)+β1(|e(k)-δ|)+β2(|u(k)-ε|), β1 and β2 are Lagrangian operators, and β1+β2=1, e(k) is the tracking error of the controlled object in the edge control system at time k, e(k)=y sp (k)-y(k),y sp (k) is the set value of the controlled object in the edge control system at time k, y(k) is the feedback value of the controlled object in the edge control system at time k, δ is the e(k) limit value, and δ>e ξ , u(k) is the output value of the PID controller in the edge control system at time k, and ε is the u(k) limit value.
[0205] Specifically, in combination with the above embodiment, the network architecture of the parameter tuning algorithm based on reinforcement learning includes an Actor network and a Critic network. Based on the Actor-Critic network architecture, by executing the parameter tuning algorithm steps of Step 1 to Step 13, PID control parameters that meet the requirements can be obtained.
[0206] See also Figure 5 As shown in FIG, a network architecture diagram of a parameter tuning algorithm based on reinforcement learning provided by an embodiment of the present invention, the input of the Actor network is the state S(k), and the output is the action a(k), which is used to fit the optimal strategy and output the optimal action a * The input of the Critic network is the state S(k) and the action a(k), and the output is the action value function Q(k), which is used to guide the Actor network. The network update algorithm includes the parameter update algorithm of the two networks. The input is the reward r(k) and the action value function Q(k) provided by the environment, and the output is the new parameters θ of the two networks. A and w C .
[0207] It should be noted that according to formula (2) in the above embodiment, formula (6) can be obtained:
[0208]
[0209] According to formula (6), the output value u(k) of the PID controller at the current moment is related to the output value u(k-1) at the previous moment, the tracking error e(k), the error change rate Δe(k), and the error quadratic change rate Δ(Δe(k)). Therefore, the state S(k) can be defined as: S(k) = [u(k-1), e(k), Δe(k), Δ[Δe(k)]], where k is the current moment when the parameter tuning algorithm is running;
[0210] Define the action a(k) as: a(k) = [K p (k),K i (k),K d (k)], where considering the parameter tuning problem, the action space should be restricted to accelerate convergence and ensure system stability, that is, K pmin K p The lower limit of (k), K pmax K p The upper limit of (k), K imin K i The lower limit of (k), K imax K i The upper limit of (k), K dmin K d The lower limit of (k), K dmax K d The upper limit value of (k) is the action space limit value;
[0211] The reward function r(k) is defined as: r(k) = e 2 (k)+β1(|e(k)-δ|)+β2(|u(k)-ε|), where β1 and β2 are Lagrangian operators, and β1+β2=1.
[0212] See also Figure 6 The figure shows a schematic diagram of the structure of the Actor network in a parameter tuning algorithm based on reinforcement learning provided by an embodiment of the present invention. The Actor network consists of layer normalization, a fully connected layer, a Sigmoid activation function and Gaussian noise. Gaussian noise is introduced as the change of action during the exploration process. During the exploration process, poorly performing parameters will cause the model to vibrate significantly, causing the output of the Actor network to approach the boundary of the action space and resulting in insufficient exploration. By introducing layer normalization to process the state, the impact of fluctuations on the Actor network can be reduced; considering that the parameters in the parameter tuning problem are all positive, by introducing the Sigmoid activation function, it can be ensured that the actions are within the bounds; the Actor network hyperparameters include the number of neurons in the hidden layer Number of layers L A and learning rate α1.
[0213] See also Figure 7The figure shows a schematic diagram of the structure of the Critic network in a parameter tuning algorithm based on reinforcement learning provided by an embodiment of the present invention. The Critic network consists of layer normalization, a fully connected layer, and a ReLU activation function. Similar to the structural design of the Actor network, when the model jitters, the output of the Actor network will also fluctuate, thereby affecting the output of the Critic network. By introducing layer normalization, the impact of fluctuations on the Critic network can be reduced; the hyperparameters of the Critic network include the number of neurons in the hidden layer. Number of layers L C and learning rate α2.
[0214] When updating the network, the continuous policy gradient (DPG) algorithm can be used to update the two network parameters separately. The network update introduces the target networks A' and C' of the Actor network and the Critic network. The structures of these two target networks are exactly the same as the corresponding original networks. After completing the parameter update of the original network, the parameter update is performed by soft update to improve the convergence of the algorithm, that is: Among them, θ A The network parameters of the Actor network (i.e. weights and biases), w C are the network parameters of the Critic network (i.e. weights and biases), θ A ′ is the network parameter of the target network A′ of the Actor network, w′ C is the parameter of the target network C′ of the Critic network, and ρ is the soft update learning rate.
[0215] For the Critic network, the parameter update can use the temporal difference method (TD Learning), use the target network C' to calculate the temporal difference target (TD Target) and perform gradient descent to update the network parameters. The temporal difference target is: T(k) = r(k) + Q'(k+1), where Q'(k+1) represents the predicted value of the future evaluation index obtained after sending the state S(k+1) and action a'(k+1) to the target network C' of the Critic network, and a'(k+1) represents the action obtained after sending the state S(k+1) to the target network A' of the Actor network; the error of the Critic network is: Loss C =(T(k)-Q(k)) 2 , we can use the gradient descent algorithm to convert the error formula to w C Perform derivation to complete the network parameter update.
[0216] For the Actor network, the parameter update can adopt the Policy Gradient Descent algorithm, and the network parameters are updated using the output Q(k) of the Critic network, so that the output value of the Critic network increases continuously, and the error of the Actor network is Loss A =Q(k), the error formula can be applied to θ using the gradient ascent algorithm. A Perform derivation to complete the network parameter update.
[0217] It should be noted that the tuning results of the parameter tuning algorithm based on reinforcement learning are affected by the learning rate α1 of the Actor network, the learning rate α2 of the Critic network, the number of neurons in the Actor network and its target network A′ and the number of layers L A And the number of neurons in the critic network and its target network C′ and the number of layers L C These parameters can be adaptively adjusted according to different application scenarios.
[0218] See also Figure 8 Figure 1 is a schematic diagram of the hardware platform of a device-edge-cloud collaborative PID controller parameter tuning system provided by an embodiment of the present invention. The hardware platform consists of two parts: the field part and the laboratory part.
[0219] The site consists of a PLC control system and edge communication equipment. The PLC control system is connected to the equipment in the production process through the field bus to complete data transmission; the edge communication equipment and the PLC control system are connected through an industrial switch to complete data collection, and the edge communication equipment transmits the collected data through the public network through the 4G network to the big data center in the cloud server to complete data storage.
[0220] The laboratory consists of cloud and edge. The cloud includes cloud servers (i.e. Figure 8 The cloud server in the cloud has a big data center and an artificial intelligence computing platform. The industrial big data center stores data, and the artificial intelligence computing platform obtains data and completes the correction of the PID control process cloud digital twin model to complete the update of the PID control process edge digital twin model at the edge through the self-correction mechanism; the edge includes an edge server (that is, Figure 8 The edge server in the field) and the PLC control system run the PID control process digital twin model and parameter tuning algorithm in the edge server, and the PLC control system runs a PID controller consistent with the field structure, and the PID control parameters are given by the parameter tuning algorithm.
[0221] It should be noted that for the software platform of the on-site part, the on-site PLC mainly performs loop control, logic control, data processing and data acquisition functions. The software platform of the on-site edge communication equipment can use Linux, and the application software platform can be Python or MySQL. The application software includes edge data storage, parameter distribution, cloud interaction and data acquisition.
[0222] It should be noted that for the software platform of the laboratory part, the laboratory PLC mainly performs PID control, data acquisition, data processing and data storage functions at the edge; the laboratory edge model machine software platform can be Windows, and the application software platform can be Python, MySQL, front-end framework Vue and back-end software. The application software includes PID parameter tuning, edge digital twin model, data communication, data storage and edge function visualization; the laboratory cloud software platform can be Linux, and the application software platform includes Python, MySQL, Docker. The application software includes data communication, field control performance evaluation, cloud digital twin model training, edge digital twin model accuracy evaluation, digital twin model self-correction and cloud database.
[0223] The present invention also provides a method for parameter tuning of a PID controller for device-edge-cloud collaboration. Figure 9 As shown, it is a flowchart of a preferred embodiment of a parameter tuning method of a device-edge-cloud collaborative PID controller provided by the present invention. The method is applicable to the parameter tuning system of the device-edge-cloud collaborative PID controller described in any of the above embodiments. The system includes a field control system and edge communication equipment deployed on the field end, an edge control system and edge server deployed on the edge end that are consistent with the field control system, and a cloud server deployed on the cloud; the field control system includes a controlled object controlled by the PID controller; the method includes steps S11 to S14:
[0224] Step S11: collecting data from the field control system through the edge communication device, and sending the collected data to the cloud server;
[0225] Step S12: calibrating the cloud digital twin model based on the PID control process according to the received data through the cloud server, and sending the obtained calibrated model parameters to the edge server;
[0226] Step S13: The edge server obtains PID control parameters using an edge digital twin model and a parameter tuning algorithm based on the PID control process and sends them to the edge control system for evaluation. When the PID control parameters do not meet the preset evaluation indicators, the PID control parameters are re-acquired and re-evaluated until the PID control parameters meet the preset evaluation indicators. When the PID control parameters meet the preset evaluation indicators, the PID control parameters that meet the preset evaluation indicators are sent to the edge communication device; wherein, when the edge server receives the corrected model parameters, it updates the edge digital twin model according to the corrected model parameters, and uses the updated edge digital twin model when obtaining the PID control parameters next time;
[0227] Step S14: Send the received PID control parameters to the PID controller in the field control system through the edge communication device to control the controlled object in the field control system.
[0228] It should be noted that the parameter tuning method of the end-edge-cloud collaborative PID controller provided in an embodiment of the present invention can realize all processing flows in the parameter tuning system of the end-edge-cloud collaborative PID controller described in any of the above embodiments. The specific parameter tuning scheme and the technical effects achieved are respectively the same as the parameter tuning scheme and the technical effects achieved in the parameter tuning system of the end-edge-cloud collaborative PID controller described in the above embodiments, and will not be repeated here.
[0229] In summary, the embodiment of the present invention provides a parameter tuning system and method for a device-edge-cloud collaborative PID controller, which introduces the system architecture of the device-edge-cloud system. The cloud implements parameter correction of the digital twin model based on big data by running a cloud digital twin model based on the PID control process. The edge implements automatic tuning of the PID control parameters by running the edge digital twin model and parameter tuning algorithm based on the PID control process and performing parameter evaluation. This solves the problem of time-consuming and labor-intensive manual parameter adjustment based on the original reliance on engineer experience and the problem of control performance degradation due to changes in dynamic characteristics. It can automatically tune the PID control parameters during the operation of the control system, improve control performance, ensure that the system maintains a good control effect for a long time, and thus improve the stability of the system operation. At the same time, the powerful data storage capacity and computing power of the cloud are utilized to perform parameter correction on the digital twin model in real time, thereby improving the accuracy of the model. At the same time, the system is independent of the control system of the industrial process, is easy to deploy, does not introduce security issues, and has high security. In addition, the system allows operators to manually modify parameters according to on-site conditions or the system automatically updates control parameters, reducing the maintenance intensity of the system and improving the flexibility of parameter tuning.
[0230] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the technical principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A parameter tuning system for a PID controller in device-edge-cloud collaboration, characterized by: It includes a field control system and edge communication equipment deployed at the field end, an edge control system and edge server deployed at the edge end that are consistent with the field control system, and a cloud server deployed in the cloud; the field control system includes a controlled object controlled by a PID controller; The edge communication device is used to collect data from the field control system and send the collected data to the cloud server; The cloud server is used to perform parameter correction on the cloud digital twin model based on the PID control process according to the received data, and send the obtained corrected model parameters to the edge server; The edge server is used to obtain PID control parameters using an edge digital twin model and a parameter tuning algorithm based on a PID control process and send them to the edge control system for evaluation. When the PID control parameters do not meet the preset evaluation indicators, the PID control parameters are re-acquired and re-evaluated until the PID control parameters meet the preset evaluation indicators. When the PID control parameters meet the preset evaluation indicators, the PID control parameters that meet the preset evaluation indicators are sent to the edge communication device; The edge server is further configured to update the edge digital twin model according to the corrected model parameters when receiving the corrected model parameters, and use the updated edge digital twin model when acquiring the PID control parameters next time; The edge communication device is further configured to send the received PID control parameters to a PID controller in the field control system to control a controlled object in the field control system; The network architecture of the parameter tuning algorithm includes an Actor network and a Critic network. The steps of the parameter tuning algorithm include: Step 1. Initialize the network parameters θ of the Actor network A 、Network parameters w of the Critic network C And the experience replay pool R, and introduce the variance σ of Gaussian noise 2 ; Step 2: Initialize the target network parameters, let θ A ′=θ A , w′ C =w C ; Step 3. Get the model state S(k) and input it into the Actor network to get the action a(k); Step 4: Send a(k) to the edge control system, so that the edge control system controls the operation of the edge digital twin model according to a(k); Step 5. Get the state S(k+1) and reward function r(k); Step 6. Store the state transition matrix [S(k), a(k), r(k), S(k+1)] into the experience replay pool R; Step 7: Attenuate the noise variance, let σ 2 =σ 2 *ξ; Step 8. If the experience replay pool R is full, continue to Step 9, otherwise return to Step 3; Step 9, according to the formula Loss C =(T(k)-Q(k)) 2 The network parameters w of the Critic network C Make updates; Step 10, according to the formula Loss A =Q(k) for the network parameters θ of the Actor network A Make updates; Step 11, according to the formula Update the two target network parameters; Step 12: If e(k)≤e ζ If the condition persists for t2, then continue to Step 13, otherwise return to Step 3; Step 13: Send the adjusted PID control parameters to the edge communication device; Among them, ξ is the noise attenuation coefficient, Loss C is the error of the Critic network, Loss A is the error of the Actor network, T(k) is the temporal difference target, Q(k) is the action value function about the state S(k) and action a(k), ρ is the soft update learning rate, e ξ is the algorithm convergence threshold, t2 is the second preset time period, and the reward function r(k) is defined as r(k)=e 2 (k)+β1(|e(k)-δ|)+β2(|u(k)-ε|), β1 and β2 are Lagrangian operators, and β1+β2=1, e(k) is the tracking error of the controlled object in the edge control system at time k, e(k)=y sp (k)-y(k),y sp (k) is the set value of the controlled object in the edge control system at time k, y(k) is the feedback value of the controlled object in the edge control system at time k, δ is the e(k) limit value, and δ>e ξ , u(k) is the output value of the PID controller in the edge control system at time k, and ε is the u(k) limit value.
2. The parameter tuning system for the device-edge-cloud collaborative PID controller according to claim 1, characterized in that: The cloud digital twin model consists of a linear model and a nonlinear compensation model; the expression of the cloud digital twin model is: Wherein, b0u(k-1-d)+c0 is the linear model, b0 and c0 are model parameters, is the nonlinear compensation model, a0 is the model parameter, k is the sampling time, d is the delay time, u(k) is the output value of the PID controller in the field control system, v(k) is the output value of the nonlinear dynamic compensation system, K p , K i and K d is the control parameter of the PID controller in the field control system, e(k) is the tracking error of the controlled object in the field control system, e(k)=y sp (k)-y(k),y sp (k) is the set value of the controlled object in the field control system, and y(k) is the feedback value of the controlled object in the field control system.
3. The parameter tuning system for the device-edge-cloud collaborative PID controller according to claim 1, characterized in that: The edge communication device collects data from the field control system, specifically including: The edge communication device collects data on at least the output value of the PID controller in the field control system, the feedback value and the set value of the controlled object in the field control system; Then, the cloud server performs parameter correction on the cloud digital twin model based on the PID control process according to the received data, specifically including: The cloud server performs parameter correction on the cloud digital twin model based on the PID control process based at least on the received output value of the PID controller in the field control system, the feedback value and set value of the controlled object in the field control system, and obtains the corrected model parameters; wherein the model parameters include weight parameters and bias parameters.
4. The parameter tuning system for the device-edge-cloud collaborative PID controller according to claim 1, characterized in that: The cloud server is further configured to store the received data in a database; Then, the cloud server performs parameter correction on the cloud digital twin model based on the PID control process according to the received data, specifically including: The cloud server performs data preprocessing on the data stored in the database, and performs parameter correction on the cloud digital twin model based on the PID control process according to the preprocessed data.
5. The parameter tuning system for the device-edge-cloud collaborative PID controller according to claim 1, characterized in that: The cloud server sends the obtained corrected model parameters to the edge server, specifically including: The cloud server obtains a first comprehensive score of the cloud digital twin model and a second comprehensive score of the edge digital twin model based on the PID control process. When the difference between the first comprehensive score and the second comprehensive score is greater than a preset first score threshold, the obtained corrected model parameters are sent to the edge server.
6. The parameter tuning system for the device-edge-cloud collaborative PID controller according to claim 5, characterized in that: The calculation formula of the first comprehensive score is: Among them, MSE s , RMSE s 、R 2 s 、TPR s and TNR s They are mean square error MSE, root mean square error RMSE, and goodness of fit R 2 The scores of the five evaluation indicators, true positive rate TPR and true negative rate TNR, are calculated as follows: MSE max , RMSE max 、R 2 min 、TPR min and TNR min They are mean square error MSE, root mean square error RMSE, and goodness of fit R 2 , the thresholds of the five evaluation indicators: true positive rate TPR and true negative rate TNR.
7. The parameter tuning system for the device-edge-cloud collaborative PID controller according to claim 1, characterized in that: The edge server uses the edge digital twin model and parameter tuning algorithm based on the PID control process to obtain PID control parameters and sends them to the edge control system for evaluation, specifically including: The edge server obtains a third comprehensive score of the controlled object in the field control system. When the third comprehensive score is less than a preset second score threshold, the edge server uses an edge digital twin model and a parameter tuning algorithm based on the PID control process to obtain PID control parameters and sends them to the edge control system for evaluation.
8. The parameter tuning system for the device-edge-cloud collaborative PID controller according to claim 7, characterized in that: The calculation formula of the third comprehensive score is: Among them, MEI s 、IAEI s 、IAE s 、ISE s 、TVy s 、OS s 、TVu s 、CIM s , CMSF and AP s The scores of the ten evaluation indicators are respectively the maximum value of the exceeded interval MEI, the absolute cumulative sum of exceeded interval IAEI, the absolute error cumulative sum IAE, the error square sum ISE, the fluctuation cumulative sum TVy, the overshoot OS, the input fluctuation cumulative sum TVu, the input mean CIM, the input vibration degree CMSF and the utilization rate AP. The calculation formula for each score is: MEI max 、IAEI max 、IAE max 、ISE max 、TVy max 、OS max 、TVu max 、CIM max , CMSF max and AP min They are the thresholds of the ten evaluation indicators, namely, the maximum value of the interval exceeded MEI, the absolute cumulative sum exceeded IAEI, the absolute error cumulative sum IAE, the error square sum ISE, the fluctuation cumulative sum TVy, the overshoot OS, the input fluctuation cumulative sum TVu, the input mean CIM, the input vibration degree CMSF and the utilization rate AP.
9. The parameter tuning system for the device-edge-cloud collaborative PID controller according to claim 1, characterized in that: The cloud server is further configured to send the received data to the edge server; wherein the data includes at least an output value of a PID controller in the field control system, a feedback value and a set value of a controlled object in the field control system; Then, the edge server uses the edge digital twin model and parameter tuning algorithm based on the PID control process to obtain the PID control parameters and send them to the edge control system for evaluation, specifically including: The edge server calculates the tracking error based on the feedback value and set value of the controlled object in the field control system. When the tracking error is greater than the preset error limit value and lasts for a first preset time period, the edge server obtains the PID control parameters based on the edge digital twin model based on the PID control process and the parameter tuning algorithm based on reinforcement learning, at least based on the output value of the PID controller in the field control system at the previous moment and the tracking error, and sends the obtained PID control parameters to the edge control system for evaluation.
10. The parameter tuning system for the device-edge-cloud collaborative PID controller according to claim 9, characterized in that: The edge server sends the obtained PID control parameters to the edge control system for evaluation, specifically including: The edge server sends the obtained PID control parameters to the edge control system; The edge control system sets parameters of the PID controller in the edge control system according to the received PID control parameters, uses the set PID controller to control the operation of the edge digital twin model, and sends the obtained operation results to the edge server; The edge server obtains an evaluation result based on the received operation result. When the evaluation result is not greater than a preset algorithm convergence threshold and lasts for a second preset time period, it is determined that the obtained PID control parameter meets the preset evaluation index; otherwise, it is determined that the obtained PID control parameter does not meet the preset evaluation index.
11. The parameter tuning system for the device-edge-cloud collaborative PID controller according to claim 10, characterized in that: The edge server reacquires the PID control parameters and re-evaluates them, specifically including: The edge server uses the evaluation result as a guide, utilizes the edge digital twin model and the parameter tuning algorithm to reacquire the PID control parameters, and sends the obtained PID control parameters to the edge control system for re-evaluation.
12. The parameter tuning system for a PID controller in device-edge-cloud collaboration according to claim 1, characterized in that: The expression of the preset evaluation index is: The goal of the parameter tuning algorithm is to find a set of PID control parameters that minimizes the value of the preset evaluation index and satisfies the constraints. Where k is the sampling time, e(i) is the tracking error of the controlled object in the edge control system at time i, and e(i)=y sp (i)-y(i),y sp (i) is the set value of the controlled object in the edge control system at time i, y(i) is the feedback value of the controlled object in the edge control system at time i, δ is the limit value of e(i), u(i) is the output value of the PID controller in the edge control system at time i, u min is the lower limit of the amplitude of u(i), u max is the upper limit of the amplitude of u(i).
13. A parameter tuning method for a PID controller in device-edge-cloud collaboration, characterized in that: A parameter tuning system for a PID controller in end-edge-cloud collaboration according to any one of claims 1 to 12, the system comprising a field control system and edge communication equipment deployed on a field end, an edge control system and an edge server deployed on an edge end that are consistent with the field control system, and a cloud server deployed on a cloud end; The field control system includes a controlled object controlled by a PID controller; the method includes: Collecting data from the field control system through the edge communication device and sending the collected data to the cloud server; The cloud server performs parameter correction on the cloud digital twin model based on the PID control process according to the received data, and sends the obtained corrected model parameters to the edge server; The edge server uses an edge digital twin model and a parameter tuning algorithm based on the PID control process to obtain PID control parameters and sends them to the edge control system for evaluation. When the PID control parameters do not meet the preset evaluation indicators, the PID control parameters are re-acquired and re-evaluated until the PID control parameters meet the preset evaluation indicators. When the PID control parameters meet the preset evaluation indicators, the PID control parameters that meet the preset evaluation indicators are sent to the edge communication device; wherein, when the edge server receives the corrected model parameters, it updates the edge digital twin model according to the corrected model parameters, and uses the updated edge digital twin model when obtaining the PID control parameters next time; The received PID control parameters are sent to the PID controller in the field control system through the edge communication device to control the controlled object in the field control system.
Citation Information
Patent Citations
PID parameter setting method based on image recognition
CN114740708A
Continuous calibration of sensors in a remotely monitored cooling system
US20210088390A1