Disclosure of Invention
In order to overcome the defects and shortcomings of the prior art, the invention provides a reliable edge-cloud computing service delay optimization method for an information physical system.
The second purpose of the invention is to provide an information physical fusion system.
In order to achieve the first purpose, the invention adopts the following technical scheme:
a reliable edge-cloud computing service delay optimization method facing an cyber-physical system comprises the following steps:
step 1: modeling service delay of a base station based on computation unloading transmission delay and execution delay, and setting a service delay target of edge cloud computing according to energy budget and reliability characteristics, wherein the service delay target of the edge cloud computing comprises a static stage target and a dynamic stage target, the static stage target is used for searching optimal computation unloading mapping and task backup quantity, and the dynamic stage target is used for avoiding transmission and execution of redundant tasks during operation;
step 2: calculating system service delay, and converting a service delay target of edge cloud computing into 5 scheduling constraint conditions, wherein the 5 scheduling constraint conditions comprise a first scheduling constraint condition, a second scheduling constraint condition, a third scheduling constraint condition, a fourth scheduling constraint condition and a fifth scheduling constraint condition;
the first scheduling constraint condition is that each base station only allows to forward the computing task to one edge/cloud server, the second scheduling constraint condition is that the workload of any edge/cloud server cannot exceed the maximum processing capacity of the edge/cloud server, the third scheduling constraint condition is that the energy consumed by the whole system cannot exceed a given energy threshold, the fourth scheduling constraint condition is that the task backup quantity of each base station cannot exceed the maximum backup quantity specified by the system, and the fifth scheduling constraint condition is that the reliability of the system with fault tolerance is higher than a preset reliability threshold;
and step 3: obtaining the backup number according to a backup number calculation formula by using an error adaptive factor, wherein the error adaptive factor is used for representing the uncertainty of the average arrival rate caused by the occurrence of bit errors and soft errors, and the backup number calculation formula is specifically represented as follows:
in the formula
Denotes the jth base station
With the mth edge/cloud server
Backup ofThe number of the components is equal to or less than the total number of the components,
representing slave base stations
To edge/cloud server
The average fault-tolerant arrival rate of (c),
represents an average arrival rate in the best case where no error occurs in the process of calculating the forwarding of the base station,
to represent
And
a rounded value in orientation after division;
and 4, step 4: in a static stage, determining the optimal calculation unloading mapping and task backup number through Monte Carlo simulation and integer linear programming to minimize system service delay;
and 5: and in the dynamic stage, determining that a backup task is successfully transmitted and executed once based on an online backup self-adaptive dynamic strategy, traversing all base stations, respectively finding out all edge/cloud servers which are in communication connection with the base stations, finding out the updated task backup quantity of each base station after traversing, and executing backup in all task backups of each base station.
As a preferred technical solution, in step 4, the determining the optimal calculation unloading mapping and task backup number to minimize the system service delay through monte carlo simulation and integer linear programming specifically includes: and searching for an optimal calculation unloading mapping by repeating the Monte Carlo simulation process by using an error adaptive factor and an ILP algorithm, obtaining the backup quantity of each base station and each edge/cloud server according to a backup quantity calculation formula, obtaining the system reliability by using Monte Carlo simulation, and screening and outputting the optimal calculation unloading mapping and the task backup quantity of each base station in a static optimization stage according to 5 scheduling constraint conditions.
As a preferred technical solution, in step 5, once the first successful backup is detected, the transmission and execution of the other task backups are cancelled.
As a preferred technical scheme, the step 1 specifically comprises the following steps:
step A1: modeling the calculation unloading transmission delay of the base station, calculating the jth base station according to the Poisson distribution satisfied by the calculation task services sent to the base station by a plurality of terminal users
And mth edge/cloud server
Communication delay between:
wherein D
j,mIs composed of
And
distance between, xi is the electromagnetic wave propagation speed, W
jFor end user at jth base station
Total amount of task data on, C
j,mIs composed of
And
bandwidth of communication between, order
Is k edge servers and cloud servers
The set of (a) and (b),
the concrete expression is as follows:
step A2: modeling the computation unloading execution delay of the base station, quantifying the execution delay connected to the edge/cloud server and the base station based on an M/G/1 queue model, and making the execution time of the task on the edge/cloud server follow an average value mumStandard deviation of deltamA general probability distribution function of;
computing
And
the execution delay in between:
wherein a plurality of end users transmit to a base station
The computational tasks of (a) are subject to a poisson distribution,
is the jth base station
The average arrival rate of the tasks is calculated,
to represent
Supported calculation speed, μ
mAnd delta
mSeparately representing tasks at edge/cloud servers
Mean and standard deviation of the probability distribution function obeyed by the upper execution time, phi
mIs to remove
Outside base station mapping
Sum of task arrival rates of (a);
step A3: computing base station
With edge/cloud servers
Total service delay when establishing a connection:
step A4: the calculated system service delay is expressed as the average service delay of all base stations:
in the formula
A communication connection state identification is represented and,
a binary decision variable of 0 or 1 when
Determining and
when the communication is carried out,
otherwise
Step A5: calculating the jth base station
Energy consumption of (2):
in the formula
Indicating a base station
Energy dissipation in the transmission of the responsible end-user computing tasks,
is a base station
A power consumption constant of;
step A6: computing mth edge/cloud server
Energy consumption of (2):
in the formula
Representing edge/cloud servers
The amount of energy that is consumed,
is a static power constant, α
mFor edge/cloud servers
Parameter of power consumption, α
mBeing constants associated with the processor architecture, v
mFor edge/cloud servers
The processor supply voltage of (a);
step A7: combining step A5 and step A6, calculating system energy consumption:
step A8: calculating slave base station
To edge/cloud server
Reliability of transmission:
in the formula
Represents from
To edge/cloud server
A constant bit error rate of the link of (1);
step A9: compute edge/cloud server
Average failure occurrence rate of (2):
in the formula C
mAnd
respectively the m-th edge/cloud server
First and second fault occurrence parameters of C
mAnd
are all constants, when practically used, C
mAnd
depending on the hardware architecture of the actual device.
As a preferred technical solution, the step 2 specifically comprises the following steps:
step B1: service delay target establishing undirected graph based on edge cloud computing
Undirected graph
Computing system service latency for describing topological relationships between base stations and edge/cloud servers
Step B2: ensuring a base station based on a first scheduling constraint
Mapping to edge/cloud server exactly and only one edge/cloud server:
step B3: ensuring that each edge/cloud server satisfies a maximum processing capacity constraint based on a second scheduling constraint:
step B4: and ensuring the satisfaction of the energy upper limit constraint based on a third scheduling constraint condition:
step B5: and ensuring that the backup quantity constraint is met based on a fourth scheduling constraint condition:
in the formula
A maximum number of backups specified for the system;
step B6: and ensuring that the system reliability constraint is met based on a fifth scheduling constraint condition:
in the formula
Representing a preset system reliability threshold.
As a preferred technical solution, the specific steps of step 3 include:
step C1: for the worst case, the base station
Co-completion
A backup is provided with
In the best case where no errors occur in the process of calculating the forwarding at the base station,
the average arrival rate of the base station at that time, i.e. the average arrival rate of the best case,
the average arrival rate is the worst case in which no error occurs in the process of calculating and forwarding of the base station;
step C2: introducing an error adaptation factor phi representing the uncertainty of the average arrival rate due to the occurrence of bit errors and soft errors from the base station
To edge/cloud server
The average fault-tolerant arrival rate of (c) is:
step C3: according to average fault-tolerant arrival rate
And obtaining the backup quantity based on a backup quantity calculation formula, wherein the backup quantity calculation formula is expressed as:
in the formula
Denotes the jth base station
With the mth edge/cloud server
The number of backups.
As a preferred technical solution, the step 4 specifically comprises the following steps:
step D1: undirected graph
Wherein
Respectively representing position information and link communication information, undirected graph
For describing base stations and edge/cloud servicesThe topological relation between the devices is that the devices,
and
for use as undirected graphs
The input of (1);
step D2: will be provided with
The value is 0, i.e.:
step D3: will phistartAssigned a value of 0, phiendAssigned a value of 1, i.e. phistart←0,Φend←1;
Step D4: judgment of
Whether the result is true or not;
if yes, go to step D5;
otherwise, go to step D12;
step D5: will phistart+(Φend-Φstart) Per 2 is assigned to Φ, i.e., < ← Φstart+(Φend-Φstart)/2;
Step D6: for each
Each of (1)
Calculating the number of backups using C3
Step D7: processing an ILP plan with 5 scheduling constraint conditions by adopting an ILP solver, wherein the 5 scheduling constraint conditions are the 5 scheduling constraint conditions in the step 2;
step D8: obtaining the reliability of the current system by Monte Carlo simulation
Step D9: judgment of
Whether the result is true or not;
if so, will phistartAssigned a value of phi +1, i.e. phistartC, going to step D10;
otherwise, will phiendAssigned a value of phi-1, i.e. phiendC, going to step D10;
step D10: and outputting the optimal calculation unloading mapping and the task backup quantity of each base station in the static optimization stage.
As a preferred technical solution, the step D8 specifically includes:
step D8-1: calculating a base station using exponential distribution
The system execution reliability of (a), the system execution reliability being expressed as:
step D8-2: calculating base station based on system execution reliability
System backup reliability of when
Back up as a base station
When reservedThe computing system backup reliability is expressed as:
step D8-3: obtaining the characteristics of system reliability according to the system backup reliability of all base stations;
the system reliability is characterized by the product of system backup reliability of all base stations establishing connection with the edge/cloud server in the system, which is specifically expressed as:
as a preferred technical solution, the step 5 specifically comprises the following steps:
step E1: j is assigned as 1, namely j ← 1;
step E2: judging whether J is equal to or less than J, if so, executing a step E3, otherwise, exiting;
step E3: assigning m to be 0, namely m ← 0;
step E4: judging whether m is less than or equal to k, if so, executing a step E5, otherwise, executing a step E13;
step E5: judgment of
If yes, performing a step E6, otherwise performing a step E12;
step E6: assigning i to be 1, namely i ← 1;
step E7: judgment of
If yes, executing a step E8, otherwise, executing a step E12;
step E8: determining whether the transfer was successfully propagated, if so, performing step E9, otherwise, performing step E11;
step E9: slave base station
Executing backup in all task backups;
step E10: updating
Namely, it is
Step E12 is executed;
step E11: updating i, i ← i + 1;
step E12: updating m, namely m ← m + 1;
step E13: update j, i.e., j ← j +1, and proceed to step E2.
In order to achieve the second object, the invention adopts the following technical scheme:
the cyber-physical system is a CPS formed by typical edge/cloud computing coupling and comprises a plurality of terminal users, a plurality of base stations, a plurality of heterogeneous edge servers and a cloud server, wherein the plurality of heterogeneous edge servers and the cloud server form the edge/cloud server, the plurality of terminal users are in wireless connection with adjacent base stations, and the edge/cloud server is in wireless connection with the adjacent base stations.
Compared with the prior art, the invention has the following advantages and beneficial effects:
(1) in the technical problem of minimizing the service delay of the edge cloud computing embedded CPS application program, particularly in the service delay optimization process, optimization algorithms are respectively carried out in a static stage and a dynamic stage by considering the energy budget and the reliability requirements of the CPS application program; in a static stage, Monte Carlo simulation and Integer Linear Programming (ILP) technology are utilized to find the optimal calculation unloading mapping and task backup quantity, and in a dynamic stage, a backup self-adaptive mechanism is adopted to avoid transmission and execution of redundant tasks during operation; the invention effectively reduces the service delay of the system by combining the static state and the dynamic state for optimization.
Detailed Description
In the description of the present disclosure, it should be noted that the terms "first", "second", and "third" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance. Also, the use of the terms "a," "an," or "the" and similar referents do not denote a limitation of quantity, but rather denote the presence of at least one. The word "comprising" or "comprises", and the like, means that the element or item appearing before the word covers the element or item listed after the word and its equivalents, but does not exclude other elements or items. The terms "connected" or "coupled" and the like are not restricted to physical or mechanical connections, but may include electrical connections, whether direct or indirect.
In the description of the present disclosure, it is to be noted that the terms "mounted," "connected," and "connected" are to be construed broadly unless otherwise explicitly stated or limited. For example, the connection can be fixed, detachable or integrated; can be mechanically or electrically connected; they may be connected directly or indirectly through intervening media, or they may be interconnected between two elements. The specific meaning of the above terms in the present disclosure can be understood in specific instances by those of ordinary skill in the art. In addition, technical features involved in different embodiments of the present disclosure described below may be combined with each other as long as they do not conflict with each other.
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
Examples
Example 1
As shown in fig. 2, the present embodiment provides a reliable edge-cloud computing service delay optimization method for an cyber-physical system, where the method includes the following steps:
step 1: modeling service delay of a base station based on computation unloading transmission delay and execution delay, and setting a service delay target of edge cloud computing according to energy budget and reliability characteristics, wherein the service delay target of the edge cloud computing comprises a static stage target and a dynamic stage target, the static stage target is used for searching optimal computation unloading mapping and task backup quantity, and the dynamic stage target is used for avoiding transmission and execution of redundant tasks during operation;
step 2: calculating system service delay, and converting a service delay target of edge cloud computing into 5 scheduling constraint conditions, wherein the 5 scheduling constraint conditions comprise a first scheduling constraint condition, a second scheduling constraint condition, a third scheduling constraint condition, a fourth scheduling constraint condition and a fifth scheduling constraint condition;
the method comprises the following steps that a first scheduling constraint condition is that each base station only allows a computing task to be forwarded to one edge/cloud server, a second scheduling constraint condition is that the workload of any edge/cloud server cannot exceed the maximum processing capacity of the edge/cloud server, a third scheduling constraint condition is that the energy consumed by the whole system cannot exceed a given energy threshold, a fourth scheduling constraint condition is that the task backup quantity of each base station cannot exceed the maximum backup quantity specified by the system, and a fifth scheduling constraint condition is that the reliability of the system with fault tolerance is higher than a preset reliability threshold;
and step 3: obtaining the backup number according to a backup number calculation formula by using an error adaptive factor, wherein the error adaptive factor is used for expressing uncertainty of an average arrival rate caused by occurrence of bit errors and soft errors, and the backup number calculation formula is specifically expressed as follows:
in the formula
Denotes the jth base station
With the mth edge/cloud server
The number of backups of (a) is,
representing slave base stations
To edge/cloud server
The average fault-tolerant arrival rate of (c),
indicating computational forwarding at the base stationThe average arrival rate in the best case without error in the process of (2),
to represent
And
a rounded value in orientation after division;
and 4, step 4: in a static stage, minimizing system service delay by determining the optimal calculation unloading mapping and task backup quantity;
searching for an optimal calculation unloading mapping by repeating a Monte Carlo simulation process by using an error adaptive factor and an ILP algorithm, obtaining the backup quantity of each base station and each edge/cloud server according to a backup quantity calculation formula, obtaining the system reliability by using Monte Carlo simulation, and screening and outputting the optimal calculation unloading mapping and the task backup quantity of each base station in a static optimization stage according to 5 scheduling constraint conditions;
and 5: and in the dynamic stage, determining that a backup task is successfully transmitted and executed once based on an online backup self-adaptive dynamic strategy, traversing all base stations, respectively finding out all edge/cloud servers which are in communication connection with the base stations, finding out the updated task backup quantity of each base station after traversing, and executing backup in all task backups of each base station. In actual application, once the first successful backup is detected, the transmission and execution of other task backups are cancelled.
In this embodiment, the step 1 specifically includes:
step A1: modeling the calculation unloading transmission delay of the base station, calculating the jth base station according to the Poisson distribution satisfied by the calculation task services sent to the base station by a plurality of terminal users
And mth edge/cloud server
Communication delay between:
wherein D
j,mIs composed of
And
distance between, xi is the electromagnetic wave propagation speed, W
jFor end user at jth base station
Total amount of task data on, C
j,mIs composed of
And
bandwidth of communication between, order
Is k edge servers and cloud servers
The set of (a) and (b),
the concrete expression is as follows:
step A2: modeling the computation offload execution delay of the base station, quantifying the execution delay connected to the edge/cloud server and the base station based on the M/G/1 queue model, and tasking atExecution time on edge/cloud server obeys an average value mumStandard deviation of deltamA general probability distribution function of;
computing
And
the execution delay in between:
wherein a plurality of end users transmit to a base station
The computational tasks of (a) are subject to a poisson distribution,
is the jth base station
The average arrival rate of the tasks is calculated,
to represent
Supported calculation speed, μ
mAnd delta
mSeparately representing tasks at edge/cloud servers
Mean and standard deviation of the probability distribution function obeyed by the upper execution time, phi
mIs to remove
Outside base station mapping
Sum of task arrival rates of (a);
step A3: computing base station
With edge/cloud servers
Total service delay when establishing a connection:
step A4: the calculated system service delay is expressed as the average service delay of all base stations:
in the formula
A communication connection state identification is represented and,
a binary decision variable of 0 or 1 when
Determining and
when the communication is carried out,
otherwise
Step A5: calculating the jth base station
Energy consumption of (2):
in the formula
Indicating a base station
Energy dissipation in the transmission of the responsible end-user computing tasks,
is a base station
A power consumption constant of;
step A6: computing mth edge/cloud server
Energy consumption of (2):
in the formula
Representing edge/cloud servers
The amount of energy that is consumed,
is a static power constant, α
mFor edge/cloud servers
Parameter of power consumption, α
mBeing constants associated with the processor architecture, v
mFor edge/cloud servers
The processor supply voltage of (a);
step A7: combining step A5 and step A6, calculating system energy consumption:
step A8: calculating slave base station
To edge/cloud server
Reliability of transmission:
in the formula
Represents from
To edge/cloud server
A constant bit error rate of the link of (1);
step A9: compute edge/cloud server
Average failure occurrence rate of (2):
in the formula C
mAnd
respectively the m-th edge/cloud server
First and second fault occurrence parameters of C
mAnd
are all constants, when practically used, C
mAnd
depending on the hardware architecture of the actual device.
In this embodiment, step 2 specifically includes the following steps:
step B1: service delay target establishing undirected graph based on edge cloud computing
Undirected graph
Computing system service latency for describing topological relationships between base stations and edge/cloud servers
Step B2: ensuring a base station based on a first scheduling constraint
Mapping to edge/cloud server exactly and only one edge/cloud server:
step B3: ensuring that each edge/cloud server satisfies a maximum processing capacity constraint based on a second scheduling constraint:
step B4: and ensuring the satisfaction of the energy upper limit constraint based on a third scheduling constraint condition:
step B5: and ensuring that the backup quantity constraint is met based on a fourth scheduling constraint condition:
in the formula
A maximum number of backups specified for the system;
step B6: and ensuring that the system reliability constraint is met based on a fifth scheduling constraint condition:
in the formula
Representing a preset system reliability threshold.
In this embodiment, the step 3 specifically includes:
step C1: for the worst case, the base station
Co-completion
A backup is provided with
In the best case where no errors occur in the process of calculating the forwarding at the base station,
the average arrival rate of the base station at that time, i.e. the average arrival rate of the best case,
is the worst-case average arrival rate at which no errors occur during the process of calculating the forwarding at the base station. When the utility model is used in the practical application,
and
constant for each base station;
step C2: introducing an error adaptation factor phi representing the uncertainty of the average arrival rate due to the occurrence of bit errors and soft errors from the base station
To edge/cloud server
The average fault-tolerant arrival rate of (c) is:
step C3: according to average fault-tolerant arrival rate
And obtaining the backup quantity based on a backup quantity calculation formula, wherein the backup quantityThe quantity calculation formula is expressed as:
in the formula
Denotes the jth base station
With the mth edge/cloud server
The number of backups.
In this embodiment, the step 4 specifically includes:
step D1: undirected graph
Wherein
Respectively representing position information and link communication information, undirected graph
For describing the topological relationship between the base station and the edge/cloud server,
and
for use as undirected graphs
The input of (1);
step D2: will be provided with
The value is 0, i.e.:
step D3: will phistartAssigned a value of 0, phiendAssigned a value of 1, i.e. phistart←0,Φend←1;
Step D4: judgment of
Whether the result is true or not;
if yes, go to step D5;
otherwise, go to step D12;
step D5: will phistart+(Φend-Φstart) Per 2 is assigned to Φ, i.e., < ← Φstart+(Φend-Φstart)/2;
Step D6: for each
Each of (1)
Calculating the number of backups using C3
Step D7: processing the ILP plan with 5 scheduling constraint conditions by adopting an ILP solver, wherein the 5 scheduling constraint conditions are the 5 scheduling constraint conditions in the step 2;
step D8: obtaining the reliability of the current system by Monte Carlo simulation
In this embodiment, the step D8 includes the following specific steps:
step D8-1: calculating a base station using exponential distribution
System execution reliability ofExpressed as:
step D8-2: calculating base station based on system execution reliability
System backup reliability of when
Back up as a base station
While retained, computing system backup reliability:
step D8-3: obtaining the characteristic of system reliability according to the system backup reliability of all base stations, wherein the characteristic of the system reliability is the product of the system backup reliability of all base stations which establish connection with the edge/cloud server in the system, namely:
step D9: judgment of
Whether the result is true or not;
if so, will phistartAssigned a value of phi +1, i.e. phistartC, going to step D10;
otherwise, will phiendAssigned a value of phi-1, i.e. phiendC, going to step D10;
step D10: and outputting the optimal calculation unloading mapping and the task backup number of each base station in the static optimization stage, and then exiting, wherein the task backup number is calculated through the step C3.
In this embodiment, the step 5 specifically includes the following steps:
step E1: j is assigned as 1, namely j ← 1;
step E2: and E, judging whether J is less than or equal to J, if so, executing the step E3, and otherwise, exiting.
Step E3: assigning m to be 0, namely m ← 0;
step E4: judging whether m is less than or equal to k, if so, executing a step E5, otherwise, executing a step E13;
step E5: judgment of
If yes, performing a step E6, otherwise performing a step E12;
step E6: assigning i to be 1, namely i ← 1;
step E7: judgment of
If yes, executing a step E8, otherwise, executing a step E12;
step E8: determining whether the transfer was successfully propagated, if so, performing step E9, otherwise, performing step E11;
step E9: slave base station
Executing backup in all task backups;
step E10: updating
Namely, it is
Step E12 is executed;
step E11: updating i, i ← i + 1;
step E12: updating m, namely m ← m + 1;
step E13: update j, i.e., j ← j +1, and proceed to step E2.
Example 2
The embodiment describes how the reliable edge-cloud computing service delay optimization method for the cyber-physical system is applied by taking the cyber-physical system as an example, where the cyber-physical system is a CPS formed by coupling typical edge/cloud computing and specifically includes a plurality of end users, a plurality of base stations, a plurality of heterogeneous edge servers and a cloud server, where the plurality of heterogeneous edge servers and the cloud server form an edge/cloud server, the plurality of end users are wirelessly connected with adjacent base stations, and the edge/cloud server is wirelessly connected with the adjacent base stations.
In the present embodiment, the base station is represented as
J is the number of base stations and the heterogeneous edge servers are denoted as
Kappa is the number of heterogeneous edge servers, edge/cloud servers are denoted as
In practical applications, each heterogeneous edge server has server heterogeneity, which is mainly expressed in computing power, i.e., any two different edge servers have different computing power.
Base station
For the jth base station, each base station unloads the computing task of the terminal user connected in the service range to a processing server for processing the computing task, wherein the processing server is an edge server
Or
And the cloud server processes the computing task by entrusting the selected edge server or cloud server.
The embodiment respectively calculates the unloading transmission delay and the execution delay for the base station
The service delay of (a):
model for calculating offload transfer delay:
multiple end users transmitting to a base station
The computing task server satisfies the slave Poisson distribution and makes the jth base station
The average arrival rate of the computing task is
Specifically, with reference to step A1, the jth BS is calculated
And m is
Communication delay between servers
Model for calculating offload execution delay:
selecting M/G/1 queue model to quantify connectivity to edge/cloud servers
And base station
The execution of (2). In this model, tasks are at edge/cloud servers
When is executedWithout being limited by any given probability distribution, i.e. allowed to obey a mean value μ
mStandard deviation of delta
mGeneral probability distribution function of (1). It is noted that this general probability distribution function should be given in advance before the system starts to operate. Once the system is in operation, tuning of the probability distribution function is disabled. Specifically, as shown in step A2, the calculation is performed
And
execution delay therebetween
Step A3 is executed, the calculation results of step A1 and step A2 are combined to calculate the base station
With edge/cloud servers
Total traffic delay in setting up a connection
From step A4, the system service delay is calculated
The overall energy consumption of the edge-cloud computing coupling CPS mainly comprises two parts, namely energy consumed by a base station for unloading a computing task from an end user to an edge/cloud server, and energy consumed by the edge/cloud server for processing the unloaded computing task. Base station
Is constant
Therefore, in step A5, the base station is calculated
Energy dissipation in the transmission of end-user computing tasks for which it is responsible
In practical applications, the power consumption of the edge/cloud server depends to a large extent on several functional components such as processors, disks, memories, fans, and cooling systems. The processor power consumption is a large part of the total power consumption of the edge/cloud server, and therefore, the power consumption of the processor is used as the power consumption of the edge/cloud server when modeling the power consumption of the edge/cloud server. Estimating the edge/cloud server according to the energy model and the step A6
Energy consumed
From step A7, the system energy consumption is calculated and expressed as E
sys。
The reliability of base station tasks is defined as the probability that these tasks are first successfully transmitted to the target edge/cloud server without bit errors and then successfully executed by the target edge/cloud server without soft errors. In the digital transmission process, the bit error rate is mainly caused by environmental factors, which are derived from noise, interference, distortion and bit synchronization errors on a link. Calculated according to step A8
To edge/cloud server
The reliability of the transmission is
Unlike bit errors, soft errors are mainly caused by transient faults caused by cosmic radiation or electromagnetic interference. According to step A9, compute edge/cloud server
Mean rate of failure of
System execution reliability is calculated according to step D8-1 using an exponential distribution assumption
In order to meet the reliability requirement of the system, the implementation utilizes a backup technology to achieve the purpose of simultaneously tolerating bit errors and soft errors. In addition, in order to check whether the task is successfully processed, an acceptance test is performed after the current backup is performed on any edge/cloud server. If the acceptance test has no error, the output result of the current backup is accepted; otherwise, they will be discarded directly. When in use
Back up as a base station
When the backup is reserved, according to the step D8-2, the backup reliability is calculated
From step D8-3, the system reliability is characterized
In order to reduce the system service delay, the embodiment minimizes the system service delay by determining the optimal strategy for computation offloading and task backup of each base station under the given scheduling constraint condition.
The service delay optimization problem is defined as: for no directionDrawing (A)
The described system, determining
i) A computing offload map sum from the base station to the edge/cloud server;
ii) the number of task backups per base station, minimizing system service delay.
In order to ensure feasibility of system scheduling, five scheduling constraints, namely a first scheduling constraint to a fifth scheduling constraint, need to be satisfied.
The method comprises the following steps that a first scheduling constraint condition is that each base station only allows a computing task to be forwarded to one edge/cloud server, a second scheduling constraint condition is that the workload of any edge/cloud server cannot exceed the maximum processing capacity of the edge/cloud server, a third scheduling constraint condition is that the energy consumed by the whole system cannot exceed a given energy threshold, a fourth scheduling constraint condition is that the task backup quantity of each base station cannot exceed the maximum backup quantity specified by the system, and a fifth scheduling constraint condition is that the reliability of the system with fault tolerance is higher than a preset reliability threshold. A mathematical expression of the optimization problem is determined using step 2.
To solve the problem defined above, a two-stage approach consisting of static and dynamic service delay optimization is employed:
in the static optimization stage, Monte Carlo simulation and LLP technology are adopted to perform static calculation on the loading mapping and the task backup quantity of each base station. To describe the random nature of error occurrence, the definition of the error adaptation factor is first introduced. And solving the optimization problem determined under the energy consumption constraint by utilizing an ILP algorithm based on the error adaptive factor, and judging whether the system reliability constraint is met or not through Monte Carlo simulation. Through a plurality of attempts of adjusting the error adaptive factor, an optimal solution which meets both the energy consumption and the system reliability constraint is obtained.
Further, in order to reduce the system runtime service delay caused by redundant backup transmission and execution operations generated in the static optimization stage, the present embodiment utilizes a backup adaptive dynamic optimization mechanism to reduce the enhanced system runtime service delay: in the dynamic optimization phase, as soon as the first successful backup is detected, the transmission is cancelled and other unnecessary task backups are performed immediately.
Through the two stages, the system can achieve the aim of minimizing the service delay of the system.
And (3) a static stage:
as previously described, backup techniques are employed to tolerate bit errors and soft errors. At a base station
Under the best conditions that no errors occur in the calculation forwarding and processing processes, redundant backup is obviously not needed to provide fault tolerance. Then is provided with
Is the base station at this time
Average arrival rate of. On the contrary, in the worst case,
the base station should totally complete
And (4) backup. Is provided with
Is a worst case base station
Average arrival rate of
Then it is given by step C1. It is clear that,
and
for each base station
Are all constants. However, due to the randomness of the error, the base station usually
Average arrival rate of
Is a random variable. Thus, an error adaptation factor φ ∈ [0.1 ] is defined]The error adaptation factor is used to describe the uncertainty of the average arrival rate due to the occurrence of bit errors and soft errors. Using the error adaptation factor, the slave base station is calculated by step C2
To edge/cloud server
Average fault-tolerant arrival rate of
The goal is to minimize system service delay by determining the optimal computation offload map and number of task backups. Determining the number of backups by step C3
The number of backups is calculated using step C3 given an error-adaptive factor
To determine an optimal computation offload mapping, the present embodiment adopts an effective computation offload mapping method based on monte carlo simulation of ILP algorithm. Specifically, the ILP algorithm is firstly adopted to obtain the optimal of a single base station under the current error adaptive factor phi
Wherein the computing system service delay in step B1 is set
To the linear target, the first to fifth scheduling constraints in steps B2 to B5 are set as linear constraints. Bit errors are then generated for each communication link and soft errors are generated for each edge/cloud server based on the probability distribution of error occurrences. Next, the system reliability characteristics corresponding to the current bit error rate and the soft bit error rate are calculated by using step D8-3. Only one Monte Carlo simulation sample is generated in the two steps, and sufficient Monte Carlo samples can be obtained by repeating the process. According to the ratio of the feasible samples to the total samples satisfying step B6, the system reliability monte carlo samples corresponding to a large number of monte carlo samples can be safely estimated. Outputting a computation offload mapping variable if the system reliability is not less than a predefined reliability

Otherwise, adjusting the current value of the error adaptive factor, and repeating the Monte Carlo simulation process by using an ILP algorithm until a first feasible calculation unloading mapping solution is found, so as to obtain the optimal calculation unloading mapping.
And (3) a dynamic stage:
as described above with respect to the reliability model, to meet the reliability requirements of the system, the present embodiment employs a task backup technique to tolerate bit errors and soft errors. The task backup technology has a strong capability of handling various errors, but inevitably increases system service delay due to redundant backup transmission and execution. For example, task backup techniques strictly allow unnecessary transmissions and performing the remaining backups even if the first backup of any task was successfully processed, without bit errors and soft errors. Obviously, as long as one backup task is successfully transmitted and executed, the correctness of the processing result is ensured. On this basis, the embodiment adopts an online backup adaptive dynamic policy in step 5. At this stage, once the first successful backup is detected using the acceptance test method, the transmission and execution of other task backups is cancelled to enhance system service latency.
In order to evaluate the effectiveness of the reliable edge-cloud computing service delay optimization method for the cyber-physical system on the reliable edge cloud computing solution, a large number of experiments are performed on the base station database of the oversea telecommunication system in the embodiment. Specifically, as shown in fig. 3, fig. 3 is a position distribution of 3233 base stations in the base station database, wherein the numbers in the red circles indicate the number of base stations that have been correctly deployed in the area. For each base station, the task arrival rate and the data volume are averagely set to [4 × 106,6 × 108 ] respectively]And [1,100 ]]Mb apart. In addition, a set of heterogeneous edge/cloud servers is constructed based on five real-world commercial servers. The first type of server is from microsoft Azure china (shanghai). Randomly selecting a server containing 10 processor cores from the servers, wherein the operating frequency of each core is 3.6GHz, and requiring the server to act as a cloud server

The role of (c). The second type of server is established on an HPE ProLiant MicroServer Gen10 server, each server comprises four processor cores, and the working frequency of each core is 3.4 GHz. The third server is built on Dell R230 servers, each server comprises 6 processor cores, and the working frequency of each core is 3.0 GHz. The fourth server is built on associative TS250 servers, each server contains two processor cores, and the operating frequency of each processor core is 3.9 GHz. The fifth server is built on the Langchao NP3020 server, each server includes four processor cores, and the operating frequency of each processor core is 3.0 GHz.
A set of heterogeneous edge servers is constructed using the latter four servers. The number of each edge server is equally set to 50, so the size of the edge server set is 200. Assuming that the task execution time on each edge server follows a normal distribution, the mean-variance parameter of the normal distribution is set to the pairs of (20,5), (14,8), (35,15), and (17,10) in this order. The location distribution of the edge servers is randomly generated, assuming that each edge server is strictly configured with a selected base station. The interval of the communication capacity for each link between the base station and the edge/cloud server is [100,1000] KB/s. The propagation speed of the electromagnetic wave is 2 multiplied by 105 km/s.
As shown in fig. 4, the system service delay comparison implemented by the three solutions under the fixed edge server position and different base station workloads includes a reliable edge-cloud computing service delay optimization method for an cyber-physical system, GAES, and RTWI. As can be seen from fig. 4, each data point in the graph is an average of 100 simulation experiments. Compared with the baseline solution GAES, the reliable edge-cloud computing service delay optimization method facing the cyber-physical system, provided by the embodiment 1, shortens the service delay by 18.3%.
The baseline solution GAES is a computational offloading mechanism based on an enhanced non-dominated ranking genetic algorithm, which can jointly optimize energy optimization and service delay. This approach does not take into account the task reliability constraints. In addition, as can be seen from fig. 4, the reliable edge-cloud computing service delay optimization method for the cyber-physical system is lower than the baseline solution RTWI in terms of service delay, and the average gap is 13.2%. The baseline solution RTWI is to minimize not only the average response time of all base stations, but also the response time of each base station. However, it does not take into account the constraints of energy budget and reliability requirements.
As shown in fig. 5, three solutions implement system service delay under fixed base station workload and different edge server locations. Similar to fig. 4, each data point in the graph is also the average of 100 simulation experiments. As can be seen from the figure, the reliable edge-cloud computing service delay optimization method for the cyber-physical system has the system service delay 17.4% less than that of the baseline solution GAES, but 19.1% higher than that of the baseline solution RTWI. This is mainly because the reliable edge-cloud computing service delay optimization method for cyber-physical systems allows multiple executions of the same task to provide the required fault tolerance requirements, but the baseline solution RTWI ignores the fault tolerance requirements, and one task is executed only once, even bit errors or soft errors occur.
As shown in fig. 6, the results of comparing the feasibility of task scheduling for the reliable edge-cloud computing service delay optimization method for an cyber-physical system and two benchmark solutions are shown. The feasibility of task scheduling is derived by the ratio of the number of simulations to the total number of simulations tested to successfully schedule tasks under the constraints of energy budget and reliability requirements. In practical application, the total number of tested simulations is set to 10000, and those skilled in the art can adjust the total number of tested simulations according to practical situations, which is not limited herein.
The results of fig. 6 show that the reliable edge-cloud computing service delay optimization method for the cyber-physical system can maintain 100% of task scheduling feasibility, and the other two reference solutions cannot guarantee the task scheduling feasibility. This is because the method takes into account energy budget and reliability requirements, while the other two baseline solutions ignore energy and reliability constraints.
In this embodiment, the reliable edge-cloud computing service delay optimization method for the cyber-physical system solves the problem of minimizing the service delay of the edge cloud computing by a two-stage method considering the energy budget and the reliability requirement. The goal of the static phase is to find the optimal number of compute offload maps and task backups, and the goal of the dynamic phase is to avoid the transmission and execution of redundant tasks at runtime. A large number of experimental results show that the method reduces the system service delay by 18.3% while ensuring that specific energy budget and reliability requirements are met.
The above embodiments are preferred embodiments of the present invention, but the present invention is not limited to the above embodiments, and any other changes, modifications, substitutions, combinations, and simplifications which do not depart from the spirit and principle of the present invention should be construed as equivalents thereof, and all such changes, modifications, substitutions, combinations, and simplifications are intended to be included in the scope of the present invention.