An edge computing method, apparatus, computer device, and readable storage medium
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-04-27
- Publication Date
- 2026-08-14
AI Technical Summary
但是端端协同的边缘计算技术对端节点的选择要求较高,并且若智能超表面的参数设置不合理,反而会引起信号减弱
Smart Images

Figure CN122579228A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of edge computing technology, and in particular to an edge computing method, apparatus, computer device, and readable storage medium. Background Technology
[0002] With the rapid development of 5G, artificial intelligence and Internet of Things (IoT) technologies, the power IoT is playing an increasingly important role in promoting the digitalization and intelligentization of power networks. The power IoT has requirements for high-performance computing, low latency, high data privacy and security.
[0003] In related technologies, edge computing combined with smart metasurfaces is often used to improve the computing efficiency, privacy, and communication quality of the power Internet of Things (IoT). Edge computing deploys computing nodes with computing capabilities in the power production area, offloading computational tasks to each end node, thereby reducing network transmission latency and improving data privacy. Furthermore, smart metasurfaces enhance the wireless communication capabilities of end nodes located on either side of the smart metasurface, thus improving communication quality. However, edge computing technology with end-to-end collaboration places high demands on the selection of end nodes, and improper parameter settings on the smart metasurface can actually weaken the signal.
[0004] Therefore, how to select appropriate end nodes to jointly execute computing tasks and how to reasonably adjust the parameters of intelligent metasurfaces have become urgent technical problems to be solved. Summary of the Invention
[0005] Therefore, it is necessary to provide an edge computing method, apparatus, computer device, and readable storage medium to address the aforementioned technical problems.
[0006] In a first aspect, this application provides an edge computing method for the power Internet of Things, applied to an edge computing decision controller, comprising:
[0007] Obtain the computing tasks issued by the smart grid application, as well as the available computing resources of each IoT terminal in the IoT terminal area;
[0008] Based on the computing task and available computing resources, an edge joint computing strategy is determined, which includes the determination of the migration terminal pair, the determination of the metasurface working coefficient, the determination of the target channel, and the determination of the computing task execution strategy.
[0009] Based on the edge joint computing strategy, the sum of the transmission rate of the transmission side terminal and the current transmission rate of the reflection side terminal of the migration terminal is calculated. If the sum of the current transmission rates is detected to be greater than or equal to the sum of the initial transmission rates obtained in advance, the edge joint computing strategy is taken as the target strategy.
[0010] The cells in the metasurface are adjusted according to the target strategy, and the computation task is sent to the migration terminal pair through the target channel determined based on the target strategy. The migration terminal pair is used to coordinate the computation task.
[0011] In one embodiment, the method further includes:
[0012] If the sum of the current transmission rates is detected to be less than the sum of the initial transmission rates, a new edge joint computing strategy is formulated until the sum of the current transmission rates calculated according to the new edge joint computing strategy is greater than or equal to the sum of the initial transmission rates. The new edge joint computing strategy is then adopted as the target strategy. The current transmission rate is calculated using the bandwidth of the target channel, the transmit power from the base station to the terminal, and the channel gain of the terminal determined based on the operating coefficients of each unit in the smart metasurface. The initial transmission rate is calculated using the bandwidth of the target channel, the transmit power from the base station to the terminal, and the channel gain of the terminal determined based on the initial operating coefficients.
[0013] In one embodiment, determining the metasurface working factor includes:
[0014] The channel factor from the base station to each unit in the smart metasurface and the channel factor from each unit in the smart metasurface to each terminal are obtained. The edge computing decision controller is connected to the smart grid application and the base station respectively. Each terminal obtains the signal sent by the base station through the smart metasurface, and the base station sends the signal to the smart metasurface through the channel.
[0015] Based on a preset optimization algorithm, and under the condition of satisfying preset constraints, the working coefficient of each unit in the smart metasurface is iteratively optimized until the preset number of iterations is reached, so as to obtain the working coefficient corresponding to each unit.
[0016] In one embodiment, determining the target channel includes:
[0017] Based on the working coefficients of the migrating terminal pairs and each unit in the smart metasurface, the sum of the transmission channel gain and the reflection channel gain on each channel is calculated. Each channel has a corresponding transmission channel gain and a reflection channel gain. The transmission channel gain is calculated based on the channel factor from the base station to each unit in the smart metasurface, the channel factor from each unit in the smart metasurface to the transmission-side terminal, and the transmission coefficient of the smart metasurface. The reflection channel gain is calculated based on the channel factor from the base station to each unit in the smart metasurface, the channel factor from each unit in the smart metasurface to the reflection-side terminal, and the reflection coefficient of the smart metasurface.
[0018] The channel corresponding to the sum of the maximum transmission channel gain and the maximum reflection channel gain is taken as the target channel.
[0019] In one embodiment, the execution strategy for the computing task includes the decoding order of each terminal in the migration terminal pair; determining the execution strategy for the computing task includes:
[0020] Determine the channel gain of each terminal in the migration terminal pair on the target channel; each terminal in the migration terminal pair corresponds to a channel gain.
[0021] Terminals with lower channel gain are configured as the first decoding order, and terminals with higher channel gain are configured as the second decoding order.
[0022] In one embodiment, the computation task execution strategy includes determining the amount of data to be migrated; determining the amount of data to be migrated includes:
[0023] Determine the transmission rates from the base station to the transmission-side terminal and the reflection-side terminal, as well as the available computing resources for the transmission-side terminal and the reflection-side terminal, respectively.
[0024] The first computational weight of the transmission side terminal is calculated based on the transmission rate from the base station to the transmission side terminal and the available computing resources of the transmission side terminal. The second computational weight of the reflection side terminal is calculated based on the transmission rate from the base station to the reflection side terminal and the available computing resources of the reflection side terminal.
[0025] Based on the first calculation weight, the second calculation weight, and the computational amount of the calculation task, the first migration data amount migrated to the transmission side terminal and the second migration data amount migrated to the reflection side terminal in the calculation task are calculated. The migration data amount includes the first migration data amount and the second migration data amount.
[0026] In one embodiment, adjusting the cells in the metasurface according to a target strategy includes:
[0027] Send the edge joint computing strategy to the metasurface controller;
[0028] A metasurface controller is used to adjust the smart metasurface based on an edge-joint computing strategy.
[0029] Secondly, this application also provides an edge computing device for the power Internet of Things, comprising:
[0030] The acquisition module is used to acquire computing tasks issued by the smart grid application, as well as the available computing resources of each IoT terminal in the IoT terminal area;
[0031] The strategy formulation module is used to determine the edge joint computing strategy based on the computing task and available computing resources. The edge joint computing strategy includes determining the migration terminal pair, the metasurface working coefficient, the target channel, and the computing task execution strategy.
[0032] The optimization module is used to calculate the sum of the transmission rate of the transmission side terminal and the current transmission rate of the reflection side terminal in the migration terminal based on the edge joint computing strategy. If the sum of the current transmission rates is detected to be greater than or equal to the sum of the initial transmission rates obtained in advance, the edge joint computing strategy is used as the target strategy.
[0033] The adjustment module is used to adjust the cells in the metasurface according to the target strategy, and to send the computation task to the migration terminal pair through the target channel determined based on the target strategy. The migration terminal pair is used to coordinate the computation task.
[0034] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to perform the following steps:
[0035] Obtain the computing tasks issued by the smart grid application, as well as the available computing resources of each IoT terminal in the IoT terminal area;
[0036] Based on the computing task and available computing resources, an edge joint computing strategy is determined, which includes the determination of the migration terminal pair, the determination of the metasurface working coefficient, the determination of the target channel, and the determination of the computing task execution strategy.
[0037] Based on the edge joint computing strategy, the sum of the transmission rate of the transmission side terminal and the current transmission rate of the reflection side terminal of the migration terminal is calculated. If the sum of the current transmission rates is detected to be greater than or equal to the sum of the initial transmission rates obtained in advance, the edge joint computing strategy is taken as the target strategy.
[0038] The cells in the metasurface are adjusted according to the target strategy, and the computation task is sent to the migration terminal pair through the target channel determined based on the target strategy. The migration terminal pair is used to coordinate the computation task.
[0039] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, performs the following steps:
[0040] Obtain the computing tasks issued by the smart grid application, as well as the available computing resources of each IoT terminal in the IoT terminal area;
[0041] Based on the computing task and available computing resources, an edge joint computing strategy is determined, which includes the determination of the migration terminal pair, the determination of the metasurface working coefficient, the determination of the target channel, and the determination of the computing task execution strategy.
[0042] Based on the edge joint computing strategy, the sum of the transmission rate of the transmission side terminal and the current transmission rate of the reflection side terminal of the migration terminal is calculated. If the sum of the current transmission rates is detected to be greater than or equal to the sum of the initial transmission rates obtained in advance, the edge joint computing strategy is taken as the target strategy.
[0043] The cells in the metasurface are adjusted according to the target strategy, and the computation task is sent to the migration terminal pair through the target channel determined based on the target strategy. The migration terminal pair is used to coordinate the computation task.
[0044] The aforementioned edge computing method, apparatus, computer equipment, and readable storage medium acquire computing tasks issued by smart grid applications, as well as the available computing resources of each IoT terminal in the IoT terminal area.
[0045] Based on the computational task and available computing resources, an edge joint computing strategy is determined. This strategy includes determining the migration terminal pair, the metasurface operating coefficient, the target channel, and the computational task execution strategy. Based on this strategy, the sum of the transmission rates of the transmission-side terminals and the current transmission rates of the reflection-side terminals in the migration terminal pair is calculated. If the sum of the current transmission rates is greater than or equal to the pre-acquired initial transmission rate sum, the edge joint computing strategy is adopted as the target strategy. The cells in the metasurface are adjusted according to the target strategy, and the computational task is distributed to the migration terminal pair through the target channel determined by the target strategy. The migration terminal pair is used to collaboratively perform the computational task. This embodiment effectively selects suitable end nodes to jointly execute the computational task and reasonably adjusts the parameters of the smart metasurface. Attached Figure Description
[0046] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0047] Figure 1 This is a diagram illustrating the application environment of an edge computing method in one embodiment.
[0048] Figure 2 This is a flowchart illustrating an edge computing method in one embodiment;
[0049] Figure 3 This is a flowchart illustrating the process of determining the metasurface working factor in one embodiment;
[0050] Figure 4This is a flowchart illustrating the process of determining the execution strategy for a computing task in one embodiment;
[0051] Figure 5 This is a flowchart illustrating the process of determining the amount of migration data in one embodiment;
[0052] Figure 6 This is a structural block diagram of an edge computing device in one embodiment. Detailed Implementation
[0053] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0054] The technical background of this application will be explained below.
[0055] With the rapid development of 5G, artificial intelligence and Internet of Things (IoT) technologies, the power IoT is playing an increasingly important role in promoting the digitalization and intelligentization of the power network. The power IoT collects data such as power environment and power supply status by deploying various sensors in power terminals and power production environments, and uploads the data to computing servers for artificial intelligence calculations to achieve automated management and intelligent decision-making of the power network.
[0056] The Internet of Things (IoT) in the power sector not only requires high-performance computing and low-latency services, but also data privacy and security. The cloud computing paradigm requires uploading power data to remote cloud computing centers via the public internet, which not only subjects power computing tasks to network transmission latency of hundreds of milliseconds, but also easily leads to data leakage, making it difficult to meet the requirements of low latency and high privacy and security. Edge computing, by deploying computing nodes with computing capabilities in the power production area, offloads computing tasks to end nodes, reducing network transmission latency and improving data privacy and security. Therefore, edge computing is a key technology driving the digitalization and intelligence of the power IoT. Compared to cloud computing nodes, end nodes have relatively limited computing power; therefore, the edge computing paradigm requires the coordinated computing power of multiple end nodes to jointly execute computing tasks.
[0057] In related technologies, the quality of wireless communication is generally improved by using a simultaneously transmitting and reflecting reconfigurable intelligent surface (STAR-RIS). STAR-RIS achieves full-space coverage of the wireless signal by splitting the incident signal into transmitted and reflected signals and sending them separately to terminals on both sides of the RIS. Furthermore, by reconfiguring the RIS phase shift and amplification factor, the signal at the receiving end can be enhanced, improving the wireless communication capability. However, improper RIS phase shift settings can also lead to signal attenuation. In addition, in non-orthogonal multiple access (NOMA) wireless channel mode, both transmitted and reflected signals propagate in the same NOMA channel. While this can improve channel utilization, it also causes mutual interference between transmitted and reflected signals during channel decoding. The channel decoding order directly affects the transmission and reflection rates.
[0058] In summary, edge computing for power IoT applications faces challenges such as unstable wireless communication quality and limited end-node resources, leading to low reliability of task offloading and long latency, making it difficult to meet the low-latency, high-performance computing requirements of power IoT applications. Furthermore, improper parameter settings in smart metasurfaces can actually weaken the signal.
[0059] The above describes the main problems existing in the related technologies: In end-to-end collaborative edge computing based on smart metasurfaces, how to set the transmission / reflection phase shift and amplification factor of the smart metasurface, and the joint optimization of the computing resource allocation of the terminal nodes is a non-convex NP-hard problem. That is, how to select suitable terminal nodes to jointly execute computing tasks and reasonably adjust the parameters of the smart metasurface has become an urgent technical problem to be solved.
[0060] Based on this, this application provides an edge computing method for the power Internet of Things (IoT), applied to an edge computing decision controller: It acquires computing tasks issued by smart grid applications and the available computing resources of each IoT terminal in the IoT terminal area; determines the operating coefficients of each unit in the smart metasurface based on a preset metasurface beamforming strategy, and selects a target channel from a preset channel set that maximizes the gain of the migrating terminal pair, wherein the migrating terminal pair is the terminal pair located on both sides of the smart metasurface with the largest sum of transmission rates; determines an edge joint computing strategy based on the operating coefficients of the smart metasurface, the available computing resources of the migrating terminal pair, and the target channel; adjusts the units in the metasurface according to the edge joint computing strategy, and issues the computing tasks to the migrating terminal pair through the target channel, whereby the migrating terminal pair is used to collaboratively perform the computing tasks. This embodiment can quickly determine suitable end nodes to jointly execute computing tasks and reasonably adjust the parameters of the smart metasurface, thereby completing edge computing. For details, please refer to the following embodiments:
[0061] The edge computing method for the power Internet of Things provided in this application embodiment can be applied to, for example... Figure 1 The application environment shown includes a collection of IoT terminals (i.e., including...) Figure 1 The system comprises multiple IoT reflective terminals and IoT transmittance terminals with computing capabilities, a base station, a smart metasurface capable of simultaneous transmission and reflection, an edge computing decision controller, and a smart metasurface controller. The smart metasurface is placed in the area where the power IoT terminals are located, forming a transmission beam / link or a reflection beam / link between the IoT terminals and the base station. The edge computing decision controller is located on the base station side. The IoT terminals communicate with the edge decision controller through the base station. The smart grid application uses this to issue computational tasks requiring calculation. The edge computing method described in this application is applied to the aforementioned edge computing decision controller.
[0062] In one exemplary embodiment, such as Figure 2 As shown, an edge computing method is provided, which is applied to... Figure 1 Taking the edge computing decision controller in the example, the following is an explanation:
[0063] S210: Obtain the computing tasks issued by the smart grid application, as well as the available computing resources of each IoT terminal in the IoT terminal area.
[0064] In this context, smart grid applications refer to software programs running in the upper-level management system of the power Internet of Things (IoT), used to issue computational tasks that need to be executed by terminal devices, such as data analysis and fault diagnosis. Similarly, these computational tasks are the specific computational work required by IoT terminals for smart grid applications. IoT terminals are hardware devices integrating power-specific sensors or environmental sensors and possessing data processing capabilities, such as smart meters and circuit monitoring devices; each terminal has a certain computing capacity. Likewise, available computing resources are the currently idle computing power of the IoT terminal that can be allocated to computational tasks.
[0065] In this embodiment, the edge computing decision controller receives the computing task submitted by the smart grid application and extracts the task information of the computing task and the available computing resource size and terminal location of each terminal in the IoT terminal set. The task information includes, but is not limited to, task type and task size.
[0066] S220, Based on the computing task and available computing resources, determine the edge joint computing strategy, which includes determining the migration terminal pair, the metasurface working coefficient, the target channel, and the computing task execution strategy.
[0067] First, an edge joint computing strategy is formulated. In the edge joint computing strategy, the migration terminal pair refers to a transmission-side terminal (receiving data through transmission signals) and a reflection-side terminal (receiving data through reflection signals) selected from multiple terminals. This migration terminal pair is the terminal pair with the largest sum of transmission rates on both sides of the smart metasurface. Therefore, the migration terminal pair can be selected from multiple terminals based on the transmission rate.
[0068] The above-mentioned metasurface operating parameters include the transmission amplification factor, reflection amplification factor, transmission phase shift, and reflection phase shift of each unit. The above-mentioned intelligent metasurface is a general-purpose intelligent surface that can simultaneously transmit and reflect (STAR-RIS). The above-mentioned unit refers to the smallest independent working element that constitutes the intelligent metasurface. Each unit has a transmission channel and a reflection channel, which control the amplitude and phase of the transmitted signal and the reflected signal, respectively.
[0069] Furthermore, multiple channels exist between the base station and the terminal. These multiple channels together constitute a channel set, which refers to multiple frequency resource blocks used for wireless communication between the base station and the terminal. Each channel has a specific center frequency and bandwidth. The sum H of the channel gain of the transmitting terminal and the channel gain of the reflecting terminal on each channel is calculated. k Compare the H values of all channelsk The sum of gains H k The channel with the largest value is determined as the target channel.
[0070] The aforementioned computation task execution strategy includes the decoding order of the received computation tasks by the computing terminal, and the amount of migration data that each of the transmission-side terminal and the reflection-side terminal needs to perform computations on. In this embodiment, if the signal of the transmission-side terminal in the migration terminal pair is found to be weak, the transmission-side terminal will be decoded first, and the reflection-side terminal will be decoded after the transmission-side terminal, and vice versa. The aforementioned allocation of migration data is determined based on the total time required for one bit of data to be transmitted to the terminal (either the transmission-side terminal or the reflection-side terminal of the migration terminal pair) and to complete the computation. This allocation method allows the terminal with a shorter total time to process one bit to handle more data.
[0071] In this embodiment, the migration terminal pair is first determined. For each possible combination of transmission-side terminal and reflection-side terminal, the controller calculates the sum of its transmission rates under default metasurface parameters (such as initializing the transmission and reflection amplification coefficients of each unit to 0.5 and randomly initializing the transmission and reflection phase shifts of the smart metasurface array), compares the sum of the rates of all possible terminal pair combinations, selects the pair with the largest value as the above-mentioned migration terminal pair, and records the identity information of the terminal pair and the sum of the rates before optimization.
[0072] When determining the operating coefficients of each unit, for each unit, the optimization objective is to maximize the overall channel gain. Under preset constraints, the operating coefficients of each unit are iteratively optimized until a preset number of iterations are reached, resulting in a set of operating coefficients that maximizes the total gain. These constraints include that for each unit, the sum of its transmission coefficient and reflection coefficient equals 1, and the transmission phase shift and reflection phase shift are between 0 and 2π. It should be noted that the operating coefficients of each unit are not required to be identical; therefore, optimization calculations are necessary for each unit's operating coefficients.
[0073] Finally, each channel is sequentially selected from the preset channel set. For the currently determined migration terminal pair and the optimized smart metasurface, the sum of the channel gain H of the transmission terminal and the reflection terminal on each channel is calculated. k Compare the H values of all channels k The sum of gains H k The channel with the largest value is determined as the target channel.
[0074] In summary, the edge joint computing strategy has been formulated.
[0075] S230, based on the edge joint computing strategy, calculates the sum of the transmission rate of the transmission side terminal and the current transmission rate of the reflection side terminal of the migration terminal. If it is detected that the sum of the current transmission rates is greater than or equal to the sum of the initial transmission rates obtained in advance, the edge joint computing strategy is taken as the target strategy.
[0076] The initial transmission rate sum is the sum of the transmission rate of the transmission-side terminal and the transmission rate of the reflection-side terminal, calculated under the condition that each unit of the smart metasurface uses the default operating coefficients set in the initial settings (such as the transmission amplification factor of each unit being equal to 0.5, the reflection amplification factor being equal to 0.5, the transmission phase shift being equal to 0, and the reflection phase shift being equal to 0). Other data such as channel, decoding order, transmission power, and bandwidth can be randomly selected or the same as those in the edge joint computing strategy to ensure fair comparison.
[0077] After determining the edge joint computing strategy, the sum of the current transmission rates of the transmission-side terminals and the reflection-side terminals is calculated according to the strategy. This sum is then compared to the initial sum of transmission rates. If the sum of current transmission rates is greater than or equal to the initial sum, it indicates that the edge joint computing strategy has achieved a positive effect and communication performance has not degraded. Therefore, the edge joint computing strategy can be used as the target strategy.
[0078] S240, adjust the cells in the metasurface according to the target strategy, and send the computation task to the migration terminal pair through the target channel determined based on the target strategy. The migration terminal pair is used to coordinate the computation task.
[0079] In this embodiment, the operating coefficients of each unit are sent to the smart metasurface for adjustment. Simultaneously, the controller splits the computational task data according to the aforementioned migration data allocation strategy, resulting in data packets sent to the transmission-side terminal and data packets sent to the reflection-side terminal. These data packets are then transmitted to the corresponding transmission-side and reflection-side terminals via the target channel. Since the metasurface's operating coefficients have been optimized, the signals of the two data packets arrive at their respective terminals along the transmission and reflection paths, respectively. Upon receiving its data packet, the transmission terminal begins computation using its own computing resources; the same applies to the reflection-side terminal. After both terminals complete their computations, they return the results to the controller or smart grid application, completing the collaborative computation.
[0080] Through the embodiments of this application, the disclosed end-to-end collaborative edge computing method assisted by a simultaneously transmissive and reflective smart metasurface achieves collaborative edge computing by placing a simultaneously transmissive and reflective smart metasurface array in the power Internet of Things (IoT) terminal area and optimizing the transmission and reflection phase shifts of the smart metasurface. This splits the computing task and simultaneously migrates it to computing terminals on both sides of the smart metasurface for collaborative edge computing, enhancing wireless transmission performance and reducing transmission latency of computing migration tasks. Furthermore, the end-to-end collaborative edge computing method assisted by the simultaneously transmissive and reflective smart metasurface described in this application improves the utilization rate of end computing resources and wireless channel resources and reduces end-to-end latency of computing tasks by jointly optimizing the computing edge joint computing strategy. This allows for the determination of suitable end nodes to jointly execute computing tasks and the reasonable adjustment of smart metasurface parameters.
[0081] In one exemplary embodiment, the method further includes:
[0082] If the sum of the current transmission rates is detected to be less than the sum of the initial transmission rates, a new edge joint computing strategy is formulated until the sum of the current transmission rates calculated according to the new edge joint computing strategy is greater than or equal to the sum of the initial transmission rates. The new edge joint computing strategy is then adopted as the target strategy. The current transmission rate is calculated using the bandwidth of the target channel, the transmit power from the base station to the terminal, and the channel gain of the terminal determined based on the operating coefficients of each unit in the smart metasurface. The initial transmission rate is calculated using the bandwidth of the target channel, the transmit power from the base station to the terminal, and the channel gain of the terminal determined based on the initial operating coefficients.
[0083] In this embodiment, when the sum of the current transmission rates is detected to be less than the sum of the initial transmission rates, it indicates that the optimized communication performance is worse than the initial state. This situation may be caused by the following reasons: the iterative optimization algorithm gets trapped in a poor local optimum; although the selected target channel has the maximum gain, its absolute value is still lower than the initial channel; or there is an error in the channel estimation, causing the working coefficients to deviate from the true optimal value, etc. Therefore, it is necessary to formulate a new edge joint computing strategy, starting from selecting a new migration terminal pair, and repeating the subsequent steps such as the above-mentioned metasurface working coefficient optimization, target channel selection, decoding order configuration, and migration data volume calculation.
[0084] Specifically, the sum of current transmission rates is calculated based on the current transmission rate of the transmission-side terminal and the current transmission rate of the reflection-side terminal. The current transmission rates of transmission-side terminal i are:
[0085]
[0086] Where i represents the transmission-side terminal device. This represents the transmit power of the base station's normal transmission-side terminal. , This indicates the channel gain of the transmission terminal and the reflection terminal in the assigned target channel. This serves as an indicator variable for the current decoding priority of the transmission and reflection channels. , Let represent the channel gain of the current transmission terminal and the reflection terminal in the allocated target channel, respectively. Similarly, the current transmission rate of the reflection terminal j is:
[0087]
[0088] In summary, the sum of the above current transmission rates is:
[0089]
[0090] Understandably, the sum of the initial transmission rates can be calculated using the same method.
[0091] Repeat the above steps until the sum of the current transmission rates is greater than or equal to the sum of the initial transmission rates. At this point, it is determined that the new edge joint computing strategy can be adopted as the target strategy. In summary, this embodiment verifies the new edge joint computing strategy to ensure that the final adopted strategy can bring performance improvements.
[0092] In this embodiment, by calculating and comparing the sum of the transmission rates before and after optimization, the failure of metasurface optimization or improper channel selection can be detected, thus avoiding the use of a communication link that is worse than the initial state and ensuring that the communication foundation for computational migration is not lower than the system default level.
[0093] In one exemplary embodiment, such as Figure 3 As shown, the working factor of the metasurface is determined, including:
[0094] S310: Obtain the channel factor from the base station to each unit in the smart metasurface, and the channel factor from each unit in the smart metasurface to each terminal. The edge computing decision controller is connected to the smart grid application and the base station respectively. Each terminal obtains the signal sent by the base station through the smart metasurface, and the base station sends the signal to the smart metasurface through the channel.
[0095] The channel factor is a complex number that characterizes the amplitude attenuation and phase shift experienced by the signal as it propagates from the transmitter to the receiver.
[0096] In this embodiment, the channel factor from the base station (transmitter) to each unit in the smart metasurface (receiver) and the channel factor from each unit (transmitter) in the smart metasurface to each terminal (receiver) are obtained. In practical applications, these measurements can be performed and recorded in advance.
[0097] S320, based on a preset optimization algorithm, iteratively optimizes the working coefficient of each unit in the smart metasurface under preset constraints until a preset number of iterations is reached, thus obtaining the working coefficient corresponding to each unit.
[0098] The optimization algorithms include, but are not limited to, alternating optimization algorithms and gradient descent. The optimization objective of these algorithms is to maximize the total channel gain, i.e.:
[0099]
[0100] in, The transmission channel gain of the k-th channel. Let be the reflection channel gain of the k-th channel.
[0101] The above constraints are:
[0102]
[0103] Among them, the diagonal matrix , representing the transmission coefficient of the smart metasurface array, a diagonal matrix. This represents the reflectance coefficient of the smart metasurface array. These represent the transmission and reflection amplification factors of unit n, respectively. , This represents the transmission and reflection phase shift of element n. Represents a diagonal matrix. , , , , This represents the channel factor from the base station to the intelligent metasurface array element n. , Let n and K represent the channel factors from the smart metasurface array n to the transmission-side terminal and the reflection-side terminal, respectively, where n ∈ {1, 2, ..., N}, N represents the number of elements in the smart metasurface array, and K represents the number of channels.
[0104] In summary, based on the above optimization objectives and constraints, each metasurface element is simultaneously optimized. The sum of the total gain after each iteration is judged. If the increase in the sum of the total gain in the current round compared to the previous iteration is less than a preset threshold (e.g., 0.001), then convergence is considered achieved and the iteration stops. Otherwise, the iteration continues until the preset maximum number of iterations is reached.
[0105] After the iteration is completed, record the set of working coefficients that maximizes the sum of gains, i.e., the working coefficients of each unit, namely the transmission amplification coefficient, the reflection amplification coefficient, the transmission phase shift, and the reflection phase shift.
[0106] In one exemplary embodiment, the step of determining the target channel includes:
[0107] Based on the working coefficients of the migrating terminal pairs and each unit in the smart metasurface, the sum of the transmission channel gain and the reflection channel gain on each channel is calculated. Each channel corresponds to a transmission channel gain and a reflection channel gain. The transmission channel gain is calculated based on the channel factor from the base station to each unit in the smart metasurface, the channel factor from each unit in the smart metasurface to the transmission-side terminal, and the transmission coefficient of the smart metasurface. The reflection channel gain is calculated based on the channel factor from the base station to each unit in the smart metasurface, the channel factor from each unit in the smart metasurface to the reflection-side terminal, and the reflection coefficient of the smart metasurface.
[0108] The channel corresponding to the sum of the maximum transmission channel gain and the maximum reflection channel gain is taken as the target channel.
[0109] Among them, the transmission channel gain is the ratio of the received power to the base station's transmitted power when the signal travels from the base station through the intelligent metasurface to the transmission terminal. Similarly, the reflection channel gain is a dimensionless positive number that reflects the signal enhancement of the signal transmission link. The larger the gain, the better the communication quality of the channel for the terminal.
[0110] In this embodiment of the application, from a preset channel set A channel is selected such that the aforementioned migration terminal, based on the operating coefficients of the aforementioned metasurface, obtains the maximum sum of the transmission-side channel gain and the reflection-side channel gain on that channel; that is, the target channel satisfies the following condition:
[0111]
[0112] in, This represents the sum of the transmission channel gain and the reflection channel gain of the migrating terminal on the k-th channel, which is then used to determine the target channel.
[0113] In one exemplary embodiment, such as Figure 4 As shown, the execution strategy for the computation task includes the decoding order of each terminal in the migration terminal pair; determining the execution strategy for the computation task includes:
[0114] S410, determine the channel gain of each terminal in the migration terminal pair on the target channel; each terminal in the migration terminal pair corresponds to a channel gain.
[0115] In this embodiment, channel factor data corresponding to the target channel is obtained, and the channel gain of the migrating terminal on the transmission side and the reflection side on the target channel is calculated using the known metasurface working coefficients, respectively. and .
[0116] S420 configures terminals with low channel gain as the first decoding order and terminals with high channel gain as the second decoding order.
[0117] In this embodiment, the terminal with lower channel gain is selected as the first decoding order, meaning its channel decoding priority indicator variable is set to 1, indicating that decoding is performed first. The other terminal (with higher gain) is selected as the second decoding order, meaning its channel decoding priority indicator variable is set to 0. This determines the decoding order. Furthermore, the edge joint computing strategy is determined based on the working coefficients of each unit, the available computing resources for the migrated terminal pair, the decoding order, and the target channel.
[0118] In this embodiment of the application, by setting the above decoding order, the interference of weak signals can be minimized, while strong signals can obtain a clean decoding environment after the interference is eliminated, thereby maximizing the sum of the transmission rates of the two terminals and providing higher communication bandwidth for computation migration.
[0119] In one exemplary embodiment, such as Figure 5 As shown, the computation task execution strategy includes determining the amount of data to be migrated; determining the amount of data to be migrated includes:
[0120] S510 determines the transmission rate from the base station to the transmission side terminal and the reflection side terminal, as well as the available computing resources for the transmission side terminal and the reflection side terminal.
[0121] The transmission rate is the amount of data transmitted per unit time from the base station to the terminal on the target channel.
[0122] In this embodiment, the transmission rates from the base station to the transmission-side terminal and the reflection-side terminal are calculated separately. Specifically, the transmission rate from the base station to the transmission-side terminal is:
[0123]
[0124] Transmission rate from base station to the reflecting terminal:
[0125]
[0126] The sum of the optimized transmission rates is: Where B represents the bandwidth of the target channel, p t p r These represent the transmission power from the base station to the transmitting terminal and the reflecting terminal, respectively. , Let I(t) and I(r) represent the channel gains of the transmission terminal and the reflection terminal on the target channel, respectively. I(t) and I(r) are the decoding priority indicator variables for the transmission and reflection channels, respectively. When I(t) = 1 and I(r) = 0, the reflection-side terminal decodes first. When I(t) = 0 and I(r) = 1, the transmission-side terminal prioritizes decoding.
[0127] S520: Based on the transmission rate from the base station to the transmission terminal and the available computing resources of the transmission terminal, the first computing weight of the transmission terminal is calculated, and based on the transmission rate from the base station to the reflection terminal and the available computing resources of the reflection terminal, the second computing weight of the reflection terminal is calculated.
[0128] In this embodiment of the application, the first calculation weight have:
[0129]
[0130] Among them, R t The transmission rate of the transmission terminal. Let S be the computational complexity per unit bit, and S be the data size of the computational task described above. Then, the computational complexity of the computational task can be represented by... It means that f t The available computing resources allocated to the transmission-side terminal for this computing task.
[0131] Similarly, the second calculation weight have:
[0132]
[0133] Among them, R r f is the transmission rate of the reflecting terminal. r The reflective side terminal is allocated available computing resources for this computing task.
[0134] S530, based on the first calculation weight, the second calculation weight, and the calculation amount of the calculation task, calculates the first migration data amount migrated to the transmission side terminal and the second migration data amount migrated to the reflection side terminal in the calculation task.
[0135] In this embodiment of the application, the first migration data volume includes:
[0136]
[0137] Similarly, the second migration data volume is:
[0138]
[0139] In summary, the amount of migration data allocated to the transmission-side terminal and the reflection-side terminal can be determined.
[0140] In one exemplary embodiment, adjusting the cells in the metasurface according to a target strategy includes:
[0141] Send the edge joint computing strategy to the metasurface controller;
[0142] A metasurface controller is used to adjust the smart metasurface based on an edge-joint computing strategy.
[0143] Among them, the metasurface controller is a control unit with a communication interface and a drive circuit, used to receive instructions from the edge computing decision controller and convert the instructions into actual control voltage or current for each unit, thereby adjusting the operating coefficient of each unit.
[0144] In this embodiment, the edge joint computing strategy is sent to the metasurface controller, which then adjusts each unit in the smart metasurface accordingly to complete the setup of all units.
[0145] This application also provides a preferred embodiment of an edge computing method applied to the power Internet of Things.
[0146] 1. The edge computing decision controller receives computing tasks issued by the smart grid application. At the same time, the controller sends query commands to all terminals within the IoT terminal area to collect the current available computing resources of each terminal and record whether each terminal is located on the transmission side or the reflection side of the smart metasurface.
[0147] 2. The controller iterates through all terminal combinations located on the transmission and reflection sides. Based on the current initial operating parameters of the metasurface (transmission amplification factor of 0.5, reflection amplification factor of 0.5, transmission phase shift of zero, and reflection phase shift of zero for each unit), it calculates the sum of the transmission rates of each pair of terminals, selects the pair with the largest sum as the migrated terminal pair, and records the sum of rates before optimization. The migrated terminal pair must simultaneously meet the following requirements: a) The terminal pair is located on both sides of the smart metasurface array. The terminal receiving the transmitted signal from the base station through the smart metasurface array is represented as the transmission-side terminal, and the terminal receiving the reflected signal from the base station through the smart metasurface array is represented as the reflection-side terminal; b) The sum of the transmission rates of the terminal pair is the largest among all terminal pair combinations located on both sides of the smart metasurface array.
[0148] 3. The controller calculates the optimal transmission amplification factor, reflection amplification factor, transmission phase shift, and reflection phase shift for each unit based on the channel factors from the base station to each unit of the metasurface and from each unit to the transmission and reflection terminals. The goal is to maximize the sum of the transmission gain and reflection gain of all channels. Each unit satisfies the preset constraints. The controller uses an optimization algorithm to iteratively calculate and obtain the optimal transmission amplification factor, reflection amplification factor, transmission phase shift, and reflection phase shift for each unit, which are used as the working coefficients of the metasurface.
[0149] 4. The controller calculates the sum of transmission gain and reflection gain on each channel according to the migration terminal pair, and selects the channel with the largest sum as the target channel.
[0150] 5. The controller compares the channel gain of the transmission-side terminal and the reflection-side terminal on the target channel, and configures the terminal with the smaller gain as the first decoding order and the terminal with the larger gain as the second decoding order.
[0151] 6. The controller calculates the transmission rates of the transmission-side terminal and the reflection-side terminal based on the target channel bandwidth, base station transmit power, channel gain, decoding order, and noise power. Then, based on the transmission rate and available computing resources of each terminal, it calculates a weight according to the total time required to process one bit of data, and allocates the task data volume inversely proportional to the weight, thus obtaining the amount of data to be processed by the reflection-side terminal and the transmission-side terminal. In summary, the determination of the migration terminal pairs, the determination of the working coefficients, the determination of the target channel, the determination of the decoding order, and the determination of the migration data volume collectively constitute the aforementioned edge joint computing strategy.
[0152] 7. The controller calculates the sum of the transmission rates of the two terminals under the current strategy and compares it with the sum of the rates before optimization recorded in step 2 above. If the sum of the current optimized rates is not less than the sum of the initial rates before optimization, the current optimized strategy is adopted and the current joint calculation strategy is taken as the target strategy. If the sum of the current rates is less than the sum of the initial rates before optimization, the current strategy is abandoned, and the process returns to step 2 to reselect the migration terminal pair and repeat the subsequent steps until a strategy with performance not lower than the initial state is determined. Finally, the new strategy is taken as the target strategy.
[0153] 8. The controller sends the optimized metasurface operating coefficients to the intelligent metasurface controller. The intelligent metasurface controller adjusts the parameters of each unit of the intelligent metasurface, sends the target channel and decoding order to the base station, and sends the allocated data volume to the transmission-side terminal and the reflection-side terminal. The base station uses the target channel and sends the calculation task data to both terminals simultaneously according to the decoding order. After receiving the data, each terminal completes the calculation using its local computing resources and returns the result to the controller.
[0154] In summary, the end-to-end collaborative edge computing method assisted by intelligent metasurfaces capable of simultaneous transmission and reflection disclosed in this application reduces the algorithm complexity by using a joint optimization strategy that combines global distributed iterative optimization and local establishment and solution of optimization objective equations. This enables the algorithm to be executed and solved quickly on edge computing systems with limited computing power.
[0155] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.
[0156] Based on the same inventive concept, this application also provides an edge computing device for implementing the edge computing method described above. The solution provided by this device is similar to the implementation scheme described in the above method; therefore, the specific limitations in one or more edge computing device embodiments provided below can be found in the limitations of the edge computing method described above, and will not be repeated here.
[0157] In one exemplary embodiment, such as Figure 6 As shown, an edge computing device is provided, comprising:
[0158] The acquisition module 61 is used to acquire the computing tasks issued by the smart grid application and the available computing resources of each IoT terminal in the IoT terminal area;
[0159] The strategy formulation module 62 is used to determine the edge joint computing strategy based on the computing task and available computing resources. The edge joint computing strategy includes the determination of the migration terminal pair, the determination of the metasurface working coefficient, the determination of the target channel, and the determination of the computing task execution strategy.
[0160] The optimization module 63 is used to calculate the sum of the transmission rate of the transmission side terminal and the current transmission rate of the reflection side terminal in the migration terminal based on the edge joint computing strategy. If the sum of the current transmission rates is detected to be greater than or equal to the sum of the initial transmission rates obtained in advance, the edge joint computing strategy is used as the target strategy.
[0161] The adjustment module 64 is used to adjust the cells in the metasurface according to the target strategy, and to send the computation task to the migration terminal pair through the target channel determined based on the target strategy. The migration terminal pair is used to coordinate the computation task.
[0162] Each module in the aforementioned edge computing device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the memory of a computer device as software, so that the processor can invoke and execute the operations corresponding to each module.
[0163] In one exemplary embodiment, a computer device is provided, including a memory and a processor, the memory storing a computer program, the processor executing the computer program to implement any of the edge computing methods described above.
[0164] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements any of the edge computing methods described above.
[0165] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements any of the edge computing methods described above.
[0166] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.
[0167] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.
[0168] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.
Claims
1. An edge computing method applied to the power Internet of Things, characterized in that, The method, applied to an edge computing decision controller, includes: Obtain the computing tasks issued by the smart grid application, as well as the available computing resources of each IoT terminal in the IoT terminal area; Based on the computing task and the available computing resources, an edge joint computing strategy is determined, wherein the edge joint computing strategy includes determining the migration terminal pair, determining the metasurface working coefficient, determining the target channel, and determining the computing task execution strategy. Based on the edge joint computing strategy, the sum of the transmission rate of the transmission side terminal and the current transmission rate of the reflection side terminal in the migration terminal is calculated. If the sum of the current transmission rates is detected to be greater than or equal to the sum of the initial transmission rates obtained in advance, the edge joint computing strategy is taken as the target strategy. The cells in the metasurface are adjusted according to the target strategy, and the computing task is sent to the migration terminal pair through the target channel determined based on the target strategy. The migration terminal pair is used to collaboratively perform the computing task.
2. The method according to claim 1, characterized in that, The method further includes: If the sum of the current transmission rates is detected to be less than the sum of the initial transmission rates, a new edge joint computing strategy is formulated until the sum of the current transmission rates calculated according to the new edge joint computing strategy is greater than or equal to the sum of the initial transmission rates. The new edge joint computing strategy is then adopted as the target strategy. The current transmission rate is calculated using the bandwidth of the target channel, the transmit power from the base station to the terminal, and the channel gain of the terminal determined based on the operating coefficients of each unit in the smart metasurface. The initial transmission rate is calculated using the bandwidth of the target channel, the transmit power from the base station to the terminal, and the channel gain of the terminal determined based on the initial operating coefficients.
3. The method according to claim 1, characterized in that, Determining the working coefficient of the metasurface includes: The channel factor from the base station to each unit in the smart metasurface and the channel factor from each unit in the smart metasurface to each terminal are obtained. The edge computing decision controller is communicatively connected to the smart grid application and the base station, respectively. Each terminal obtains the signal sent by the base station through the smart metasurface, and the base station sends the signal to the smart metasurface through the channel. Based on a preset optimization algorithm, and under the condition of satisfying preset constraints, the working coefficient of each unit in the intelligent metasurface is iteratively optimized until a preset number of iterations is reached, so as to obtain the working coefficient corresponding to each unit.
4. The method according to claim 3, characterized in that, Determining the target channel includes: Based on the migrating terminal pair and the operating coefficients of each unit in the smart metasurface, the sum of the transmission channel gain and the reflection channel gain on each channel is calculated; wherein, each channel corresponds to a transmission channel gain and a reflection channel gain, the transmission channel gain being calculated based on the channel factor from the base station to each unit in the smart metasurface, the channel factor from each unit in the smart metasurface to the transmission-side terminal, and the transmission coefficient of the smart metasurface; the reflection channel gain being calculated based on the channel factor from the base station to each unit in the smart metasurface, the channel factor from each unit in the smart metasurface to the reflection-side terminal, and the reflection coefficient of the smart metasurface; The channel corresponding to the sum of the maximum transmission channel gain and the maximum reflection channel gain is taken as the target channel.
5. The method according to any one of claims 1 to 4, characterized in that, The execution strategy for the computing task includes the decoding order of each terminal in the migration terminal pair; Determining the execution strategy for the computing task includes: Determine the channel gain of each terminal in the migration terminal pair on the target channel; each terminal in the migration terminal pair corresponds to a channel gain; Terminals with lower channel gain are configured as the first decoding order, and terminals with higher channel gain are configured as the second decoding order.
6. The method according to any one of claims 1 to 4, characterized in that, The computation task execution strategy includes determining the amount of data to be migrated; determining the amount of data to be migrated includes: Determine the transmission rates from the base station to the transmission-side terminal and the reflection-side terminal, as well as the available computing resources for the transmission-side terminal and the reflection-side terminal, respectively. Based on the transmission rate from the base station to the transmission-side terminal and the available computing resources of the transmission-side terminal, a first computing weight of the transmission-side terminal is calculated, and based on the transmission rate from the base station to the reflection-side terminal and the available computing resources of the reflection-side terminal, a second computing weight of the reflection-side terminal is calculated. Based on the first calculation weight, the second calculation weight, and the computational amount of the calculation task, the first migration data amount migrated to the transmission side terminal and the second migration data amount migrated to the reflection side terminal in the calculation task are calculated.
7. The method according to any one of claims 1 to 4, characterized in that, The step of adjusting the cells in the metasurface according to the target strategy includes: The edge joint computing strategy is sent to the metasurface controller; The metasurface controller is controlled to adjust the smart metasurface based on the edge joint computing strategy.
8. An edge computing device for the power Internet of Things, characterized in that, The device includes: The acquisition module is used to acquire computing tasks issued by the smart grid application, as well as the available computing resources of each IoT terminal in the IoT terminal area; The strategy formulation module is used to determine an edge joint computing strategy based on the computing task and the available computing resources. The edge joint computing strategy includes determining the migration terminal pair, the metasurface working coefficient, the target channel, and the computing task execution strategy. The optimization module is used to calculate the sum of the transmission rate of the transmission side terminal and the current transmission rate of the reflection side terminal in the migration terminal pair based on the edge joint computing strategy. If the sum of the current transmission rates is detected to be greater than or equal to the sum of the initial transmission rates obtained in advance, the edge joint computing strategy is used as the target strategy. An adjustment module is used to adjust the cells in the metasurface according to the target strategy, and to send the computing task to the migration terminal pair through a target channel determined based on the target strategy. The migration terminal pair is used to collaboratively perform the computing task.
9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 7.