Cloud-edge-end collaborative large model and lightweight model joint deployment method and system

Through the joint deployment method of cloud-edge-end collaboration large model and lightweight model, the problem of limited bandwidth on the cloud side and insufficient end-side accuracy is solved, efficient and reliable detection is achieved, and suitable for complex application scenarios.

CN120342828APending Publication Date: 2025-07-18CHINA ELECTRIC POWER RESEARCH INSTITUTE CO LTD +2
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510531010.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-25
Publication Date
2025-07-18

AI Technical Summary

Technical Problem

In application scenarios with high precision requirements, simply deploying large models on the cloud side may face bandwidth limitations, while deploying lightweight models on the end side only has the problem of insufficient detection accuracy.

Method used

The joint deployment method of cloud-edge-end collaboration and lightweight model is adopted. By setting the initial trusted threshold and optimizing detection accuracy and missed-report rate, the minimum bandwidth and maximum number of devices are calculated, and the particle swarm optimization algorithm is used to optimize the detection accuracy to achieve the coordinated work of cloud servers and end-side devices.

Benefits of technology

Optimizes system performance, reduces latency, improves overall efficiency, ensures detection accuracy and reliability, provides a reference for key parameter settings, and is suitable for actual deployment of complex application scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120342828A_ABST
    Figure CN120342828A_ABST
Patent Text Reader

Abstract

The invention discloses a cloud-edge-end collaborative large model and lightweight model joint deployment method and system, and the method comprises the steps: building a cloud server and end-side equipment for environment early warning detection according to a system use environment, setting an initial credible threshold value, transmitting data from the end-side equipment to a cloud side or obtaining a processing result from the cloud side, and carrying out the cloud-edge-end collaborative large model and lightweight model joint deployment. Through cloud-edge-end cooperative work, tasks can be allocated among different computing resources to optimize performance, reduce delay and improve the overall efficiency of the system, and the relationship between bandwidth and the number of end-side devices supported by the system is analyzed when the minimum detection accuracy and the maximum missing report rate are given. And the influence of the number of control channels on the maximum detection accuracy rate when the bandwidth, the number of devices and the maximum missing report rate allowed by the system are given, so that a reference is provided for collaborative design of a large model and a lightweight model in the future, and the method has important significance for setting key parameters during actual deployment of related applications.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of computer model data processing, and particularly relates to a method and system for jointly deploying a large model and a lightweight model with cloud-edge-end collaboration. Background Art

[0002] With the rapid development of artificial intelligence technology, the scale and complexity of models are constantly increasing. Especially in some complex application scenarios with high-precision requirements, large models have become the core of many tasks due to their excellent performance and accuracy. However, large models usually require powerful computing resources and storage capabilities to support, so they are often deployed on cloud servers. On the other hand, lightweight models are more suitable for deployment on edge devices (such as smartphones, Internet of Things devices) due to their lower requirements for computing resources and storage, but there is usually a certain compromise in accuracy.

[0003] Large model: The large model has high-precision prediction and classification capabilities and can handle complex tasks such as image recognition and natural language processing. Such models usually contain a large number of parameters and complex structures, so they require powerful computing capabilities and storage spaces and usually run on cloud servers. However, when the number of edge devices is large, sending all data to the cloud for processing may face problems such as bandwidth limitations and data transmission delays.

[0004] Lightweight model: The lightweight model reduces the requirements for computing resources and storage space by simplifying the model structure and reducing the number of parameters, enabling it to run efficiently on edge devices. Although these models are no longer restricted by bandwidth when processing data locally and can improve data privacy, their accuracy is lower than that of large models and it is difficult to meet some application scenarios that require high precision.

[0005] Currently, some solutions only deploy large models on cloud servers to utilize the powerful computing capabilities on the cloud side to provide high-precision data processing. However, this method has significant defects. Since edge devices need to transmit a large amount of raw data to the cloud side for processing, when the number of edge devices is large, the communication link (edge) may be unable to transmit some data in time due to insufficient bandwidth, thus affecting the overall performance and response speed of the system.

[0006] To avoid bandwidth limitation problems, some other solutions choose to deploy lightweight models on edge devices. Although this method can process data locally and avoid dependence on the cloud side, there is also a problem of insufficient accuracy. Due to the simplification of the lightweight model structure, its prediction accuracy is usually lower than that of large models. In some applications with high-precision requirements, such as disaster warning, health monitoring, and intelligent transportation systems, relying solely on the lightweight models on the edge side may be difficult to meet the requirements, resulting in inaccurate prediction or detection results. Summary of the Invention

[0007] The object of the present invention is to provide a method and system for jointly deploying a large model and a lightweight model with cloud-edge-end collaboration, so as to overcome the bandwidth-limited challenges that may be encountered when simply deploying a large model on the cloud side in the prior art, and the problem of insufficient detection accuracy that may be faced when only deploying a lightweight model on the edge side.

[0008] To achieve the above object, the technical solution adopted by the present invention is as follows:

[0009] In the first aspect of the present invention, a method for jointly deploying a large model and a lightweight model with cloud-edge-end collaboration is characterized by including the following steps:

[0010] Establish a cloud server and edge-side devices for environmental early warning detection according to the system usage environment, and set an initial trust threshold;

[0011] Obtain the detection accuracy rates of the cloud server and the edge-side devices according to the initial trust threshold, obtain the minimum detection accuracy rate and the maximum false alarm rate according to the detection accuracy rates of the cloud server and the edge-side devices, and calculate the maximum number of edge-side devices that can be set according to the minimum detection accuracy rate, the maximum false alarm rate, and the set system bandwidth;

[0012] Calculate the minimum system bandwidth required that can be set according to the minimum detection accuracy rate, the maximum false alarm rate, and the set number of edge-side devices;

[0013] Calculate the trust threshold of the maximum detection accuracy rate according to the given number of edge-side devices, system bandwidth, and the maximum false alarm rate allowed by the system.

[0014] Preferably, obtaining the detection accuracy rates of the cloud server and the edge-side devices according to the initial trust threshold specifically includes the following steps:

[0015] For any edge-side device It judges the current environmental state within any period τ and gives the probability of the correctness of this judgment If not less than the initial trust threshold Γ P , then the judgment of the edge-side device u is trustworthy, and when the edge-side device u judges that the current environment is abnormal, it sends an abnormal state early warning to the cloud side; if then the judgment of the edge-side device u is untrustworthy, then the edge-side device u sends a task migration request to the cloud server and sends the original data after being authorized by the cloud server, and the cloud server makes a further judgment and the probability of the correctness of the judgment is denoted as

[0016] Preferably, obtaining the minimum detection accuracy rate and the maximum false alarm rate according to the detection accuracy rates of the cloud server and the edge-side devices specifically includes the following steps:

[0017] Edge device When detecting at , the probability of accurately judging the environmental state is The probability of misjudging abnormal data as normal is The probability of accurately judging the environmental state detected by the cloud server is The probability of misjudging abnormal data as normal is

[0018] Then τ max During cycles, the overall detection accuracy rate and false negative rate of the system are respectively

[0019]

[0020] and

[0021]

[0022] Wherein is The probability of this event occurring. The minimum detection accuracy rate and the maximum false negative rate are respectively denoted as Γ acc and Γ miss , then R acc ≥Γ acc and R miss <Γ miss .

[0023] Preferably, the maximum number of edge devices that can be set is calculated according to the minimum detection accuracy rate, the maximum false negative rate, and the set system bandwidth, specifically including the following steps:

[0024] Initial setting: Set the upper and lower limits of the number of edge devices: The lower limit U min is set to The upper limit U max The set value makes the detection accuracy rate Γ acc or the false negative rate Γ miss unable to meet the requirements;

[0025] Iterative calculation: In each iteration, calculate the intermediate value of the number of devices Then perform performance evaluation. When the number of devices is U mid , if the detection accuracy rate R acc is not lower than the set threshold Γ acc and the false negative rate R miss is lower than the set threshold Γ miss , then gradually increase the number of devices, set U min =U mid , repeat the calculation until R acc and R missIf one or all of them do not meet the requirements, then set U max = U mid until the gap between U min and U max meets the precision ε U required by the system. The finally obtained U mid is the maximum number of edge devices supported by the system.

[0026] Preferably, the minimum bandwidth required by the system that can be set is calculated according to the minimum detection accuracy, the maximum false negative rate, and the set number of edge devices, and the specific steps are as follows:

[0027] Initial setting: Set the upper and lower limits of the bandwidth. The lower limit B min is close to the minimum bandwidth that the system can support, and the set upper limit B max value ensures that the detection accuracy Γ acc and the false negative rate Γ miss of the system both meet the requirements;

[0028] Iterative calculation: Calculate the intermediate value If the detection accuracy R acc is not lower than the set threshold Γ acc and the false negative rate R miss is lower than the set threshold Γ miss , then gradually reduce the bandwidth, let B max = B mid ; otherwise, it means that this bandwidth is insufficient and the bandwidth needs to be increased, let B min = B mid , until |B max - B min | ≤ ε B , ε B is the set precision requirement, and the finally obtained B mid is the minimum bandwidth that meets the requirements of detection accuracy and false negative rate.

[0029] Preferably, the credible threshold of the maximum detection accuracy is calculated according to the given number of edge devices, the system bandwidth, and the maximum false negative rate allowed by the system. Specifically, the initial credible threshold Γ P is optimized to maximize the detection accuracy R acc , and the particle swarm optimization algorithm is used to solve it. The specific process is as follows:

[0030] Fitness function: Let the fitness function This function takes Γ P as input and returns a fitness value. If the constraint R miss < Γ miss is satisfied, the fitness value is R acc , otherwise the fitness value is set to a smaller value -1 as a penalty;

[0031] Particle swarm initialization: Set N particles, and the set Initialize a position and velocity

[0032] Fitness evaluation: Adopt to represent the fitness value obtained by particle n at position , and use x pBest,n and f(x pBest,n ) to represent the individual optimal position and individual optimal value of particle n, and use x gBest and f(x gBest ) = max{f(x pBest,1 ), …, f(x pBest,N )} to represent the global optimal position and global optimal value of all particles; At the first iteration, and

[0033] Update individual optimal and global optimal: Assume that the current iteration is the i-th iteration. For any particle n, compare its fitness value with the individual optimal position it has experienced. If , then set Then compare the fitness value of each particle with f(x gBest ). If it is larger than f(x gBest ), then replace it;

[0034] Update the velocity and position of each particle: For any particle n, calculate the new velocity according to the velocity update formula and position update formula respectively:

[0035]

[0036] and the new position

[0037]

[0038] where w is the inertia weight, which is used to control the tendency of the particle to maintain its current velocity; The learning factors c1 and c2 respectively determine the degree to which the particle learns from the individual historical optimal position and the global optimal position; r1 and r2 are random numbers uniformly and randomly selected from [0, 1]. If the new position exceeds the boundary [0, 1], then limit it within [0, 1], and then enter the (i + 1)-th iteration. After reaching the maximum number of iterations I, the optimal credible threshold and the maximum detection accuracy rate are obtained.

[0039] In the second aspect of the present invention, a joint deployment system of a large model and a lightweight model for cloud-edge-end collaboration includes a preset module, a number acquisition module for edge devices, a minimum bandwidth acquisition module, and a trust threshold acquisition module:

[0040] The preset module establishes a cloud server and edge devices for environmental early warning detection according to the system usage environment, and sets an initial trust threshold;

[0041] The number acquisition module for edge devices obtains the detection accuracy rates of the cloud server and edge devices according to the initial trust threshold, obtains the minimum detection accuracy rate and the maximum false negative rate according to the detection accuracy rates of the cloud server and edge devices, and calculates the maximum number of edge devices that can be set according to the minimum detection accuracy rate, the maximum false negative rate, and the set system bandwidth;

[0042] The minimum bandwidth acquisition module calculates the minimum system bandwidth that can be set according to the minimum detection accuracy rate, the maximum false negative rate, and the set number of edge devices;

[0043] The trust threshold acquisition module calculates the trust threshold of the maximum detection accuracy rate according to the given number of edge devices, system bandwidth, and the maximum false negative rate allowed by the system.

[0044] Preferably, obtaining the detection accuracy rates of the cloud server and edge devices according to the initial trust threshold specifically includes the following steps:

[0045] For any edge device It judges the current environmental state within any period τ and gives the probability that this judgment is correct If Not less than the initial trust threshold Γ P , then the judgment of edge device u is trustworthy, and when edge device u judges that the current environment is abnormal, it sends an abnormal state early warning to the cloud side; if Then the judgment of edge device u is untrustworthy, and then edge device u sends a task migration request to the cloud server and sends the original data after being authorized by the cloud server. The cloud server makes a further judgment and the probability that the judgment is correct is denoted as

[0046] Preferably, obtaining the minimum detection accuracy rate and the maximum false negative rate according to the detection accuracy rates of the cloud server and edge devices specifically includes the following steps:

[0047] Edge device The probability that the environmental state is accurately judged during detection is The probability that abnormal data is judged as normal is 1-α·1-Puτ; the probability that the cloud server accurately judges the environmental state is The probability that abnormal data is judged as normal is

[0048] Then τ max The overall detection accuracy and false alarm rate of the system within a cycle are respectively

[0049]

[0050] and

[0051]

[0052] The large false alarm rates are respectively denoted as Γ acc and Γ miss , then R acc ≥Γ acc and R miss <Γ miss .

[0054] Preferably, the maximum number of settable edge devices is calculated according to the minimum detection accuracy, the maximum false alarm rate, and the set system bandwidth, and specifically includes the following steps:

[0055] Initial setting: Set the upper and lower limits of the number of edge devices: The lower limit U min is set to The upper limit U max is set so that the detection accuracy Γ acc or the false alarm rate Γ miss of the system cannot meet the requirements;

[0056] Iterative calculation: In each iteration, calculate the intermediate value of the number of devices Then perform performance evaluation. When the number of devices is U mid , if the detection accuracy R acc is not lower than the set threshold Γ acc and the false alarm rate R miss is lower than the set threshold Γ miss , then gradually increase the number of devices, set U min =U mid , and repeat the calculation until one or all of R acc and R miss do not meet the requirements, then set U max =U mid , until the gap between U min and U max meets the system-required precision ε U , and the finally obtained U mid is the maximum number of edge devices supported by the system.

[0057] Preferably, the minimum bandwidth required for the system that can be set is calculated according to the minimum detection accuracy rate, the maximum false negative rate, and the set number of edge devices, and the specific steps are as follows:

[0058] Initial setting: Set the upper and lower limits of the bandwidth. The lower limit B min is close to the minimum bandwidth that the system can support. The set upper limit B max value ensures that the detection accuracy rate Γ acc and the false negative rate Γ miss both meet the requirements;

[0059] Iterative calculation: Calculate the intermediate value If the detection accuracy rate R acc is not lower than the set threshold Γ acc and the false negative rate R miss is lower than the set threshold Γ miss , then gradually reduce the bandwidth, and let B max =B mid ; otherwise, it means that this bandwidth is insufficient and the bandwidth needs to be increased. Let B min =B mid , until |B max -B min |≤ε B , where ε B is the set accuracy requirement. The finally obtained B mid is the minimum bandwidth that meets the requirements of the detection accuracy rate and the false negative rate.

[0060] Preferably, the credible threshold of the maximum detection accuracy rate is calculated according to the given number of edge devices, the system bandwidth, and the maximum false negative rate allowed by the system. Specifically, the initial credible threshold Γ P is optimized to maximize the detection accuracy rate R acc , and the particle swarm optimization algorithm is used to solve it. The specific process is as follows:

[0061] Fitness function: Let the fitness function This function accepts Γ P as input and returns a fitness value. If the constraint R miss <Γ miss is satisfied, the fitness value is R acc , otherwise the fitness value is set to a smaller value -1 as a penalty;

[0062] Particle swarm initialization: Set N particles, and the set Initialize a position and a velocity

[0063] Fitness evaluation: Use to represent the fitness of particle n at position The obtained fitness values are represented by x respectively pBest,n and f(x pBest,n ) represent the individual optimal position and individual optimal value of particle n, which are represented by x gBest and f(x gBest ) = max{f(x pBest,1 ) , …, f(x pBest,N )} represent the global optimal position and global optimal value of all particles; at the first iteration, And

[0064] Update the individual optimal and global optimal: Assume that the current iteration is the i-th iteration. For any particle n, compare its fitness value with the individual optimal position it has experienced. If then set Then compare the fitness value of each particle with f(x gBest ). If it is larger than f(x gBest ) then perform replacement;

[0065] Update the velocity and position of each particle: For any particle n, calculate the new velocity according to the velocity update formula and position update formula respectively:

[0066]

[0067] and the new position

[0068]

[0069] where w is the inertia weight, which is used to control the tendency of the particle to maintain its current velocity; the learning factors c1 and c2 respectively determine the degree to which the particle learns from the individual historical optimal position and the global optimal position; r1 and r2 are random numbers uniformly and randomly selected from [0, 1]. If the new position exceeds the boundary [0, 1], then limit it within [0, 1], and then enter the (i + 1)-th iteration. After reaching the maximum number of iterations I, the optimal credible threshold and the maximum detection accuracy rate are obtained.

[0070] In the third aspect of the present invention, a computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the above-mentioned method for jointly deploying the large model and the lightweight model in cloud-edge-end collaboration are implemented.

[0071] In the fourth aspect of the present invention, a computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the above-mentioned method for jointly deploying the large model and the lightweight model in cloud-edge-end collaboration are implemented.

[0072] Compared with the prior art, the present invention has the following beneficial technical effects:

[0073] The present invention provides a method for jointly deploying a large model and a lightweight model with cloud-edge-end collaboration. A cloud server and edge devices for environmental early warning detection are established according to the system usage environment, and an initial trust threshold is set, which is responsible for transmitting data from the edge devices to the cloud side or obtaining processing results from the cloud side. Through the collaboration of cloud-edge-end, tasks can be allocated among different computing resources to optimize performance, reduce latency, and improve the overall efficiency of the system. The relationship between bandwidth and the number of edge devices supported by the system is analyzed when the minimum detection accuracy and the maximum false alarm rate are given, and the influence of the number of control channels on the maximum detection accuracy is analyzed when the bandwidth, the number of devices, and the maximum false alarm rate allowed by the system are given. This provides a reference for the collaborative design of future large models and lightweight models and is of great significance for setting key parameters during the actual deployment of related applications. The present invention can achieve the trust threshold with the optimal detection accuracy, which is of crucial guiding significance and practical value for successfully deploying and applying this invention to actual scenarios. BRIEF DESCRIPTION OF THE DRAWINGS

[0074] Figure 1 It is a schematic flow chart of the method for jointly deploying a large model and a lightweight model with cloud-edge-end collaboration in an embodiment of the present invention.

[0075] Figure 2 It is a curve graph showing the variation of the maximum number of edge devices supported by the system with bandwidth in an embodiment of the present invention.

[0076] Figure 3 It is a schematic diagram of the minimum bandwidth required when the number of edge devices is given in an embodiment of the present invention.

[0077] Figure 4 It is a working flow chart of the cloud server and edge devices in an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0078] In order to enable those skilled in the art to better understand the solution of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

[0079] It should be noted that the terms "first", "second", etc. in the description, claims and above-mentioned drawings of the present invention are used to distinguish similar objects, and do not necessarily need to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances, so that the embodiments of the present invention described here can be implemented in an order other than those illustrated or described here. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device comprising a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.

[0080] As Figure 1 shown, the present invention provides a method for jointly deploying a large model and a lightweight model with cloud-edge-end collaboration, which is used to accurately deploy a corresponding system according to the system usage scenario to ensure the detection accuracy and reliability of the system under limited resources; specifically, it includes the following steps:

[0081] Establish a cloud server and edge devices for environmental early warning detection according to the system usage environment, and set an initial trust threshold;

[0082] Obtain the detection accuracy rates of the cloud server and the edge devices according to the initial trust threshold, obtain the minimum detection accuracy rate and the maximum false alarm rate according to the detection accuracy rates of the cloud server and the edge devices, and calculate the maximum number of edge devices that can be set according to the minimum detection accuracy rate, the maximum false alarm rate and the set system bandwidth;

[0083] Calculate the minimum system bandwidth required that can be set according to the minimum detection accuracy rate, the maximum false alarm rate and the set number of edge devices;

[0084] Calculate the trust threshold of the maximum detection accuracy rate according to the given number of edge devices, system bandwidth and the maximum false alarm rate allowed by the system.

[0085] In the specific implementation of this application, the cloud server adopts a large model that can achieve high-precision detection of environmental early warning results, and the edge devices adopt a lightweight model with a lower detection accuracy for environmental early warning detection. The cloud server (denoted by c) is a large model with a higher detection accuracy, and the edge devices (denoted by the set are) lightweight models with a lower detection accuracy. All edge devices complete a detection every period T. Specifically, for any edge device at the beginning of any period τ, it uses the locally deployed lightweight model to judge the current environmental state (normal or abnormal), and gives the probability that this judgment is correct If is not less than the initial trust threshold Γ P (i.e., ) Then, it is considered that the judgment of u is credible, and when u determines that the current environment is abnormal, it sends an abnormal status warning to the cloud side; if it is considered that the judgment of u is not credible, then u sends a task migration request to the cloud server and sends the original data after being authorized by the cloud server. The cloud server makes a further judgment and the probability of correct judgment is denoted as

[0086] Let the available bandwidth of the system be B, and the bandwidth occupied by a single edge device when sending the original data be B sub , and it will continuously occupy the entire cycle; the edge device sends the abnormal status warning and the task migration request through an additional control channel and does not occupy the bandwidth B. In view of the characteristics of the lightweight model and the large model, when the original data is typical data (i.e., easy to classify), the probabilities of correct judgment of both the lightweight model and the large model are relatively high. When the original data is atypical data (i.e., difficult to classify), the probability of correct judgment of the lightweight model is relatively low, but the probability of correct judgment of the large model is greater than the probability of correct judgment of the lightweight model.

[0087] When the edge device the probability of correct judgment when the data in the period τ is typical data is Conversely Similarly, when the data in the period τ of the cloud server is typical data, the probability of correct judgment is Conversely In particular, in this invention, respectively follow the uniform distributions Uniform(0.96, 0.98), Uniform(0.9, 0.96), Uniform(0.995, 1), Uniform(0.99, 0.995).

[0088] Let α represent the probability that a data is typical data, and β represent the probability that a data is abnormal data. Then, the probability that the environmental state is accurately judged during detection at the edge device is The probability that abnormal data is judged as normal is Similarly, the probability that the environmental state is accurately judged during detection at the cloud server c can be obtained as The probability that abnormal data is judged as normal is

[0089] Then τ can be calculated max The overall detection accuracy rate (the ratio of the number of accurately detected data to the total number of data) and the false negative rate (the ratio of the number of data that is actually abnormal but is detected as normal to the number of actual abnormal data) of the system within τ

[0090]

[0091] and

[0092]

[0093] where is the probability of this event occurring. Denote the minimum detection accuracy rate and the maximum false negative rate allowed by the system as Γ acc and Γ miss , respectively. For the early warning system, in addition to improving the detection accuracy rate as much as possible, it is also very important to keep the false negative rate at a low level. Compared with false alarms, false negatives usually cause more serious consequences. Therefore, it should satisfy R acc ≥Γ acc and R miss <Γ miss .

[0094] Calculate the maximum number of edge devices that can be set according to the minimum detection accuracy rate, the maximum false negative rate, and the set system bandwidth. The specific process is as follows:

[0095] Performing detection on the cloud server side always results in a more accurate judgment of the environmental state than on the edge device side. However, due to bandwidth constraints, it is impossible to migrate the tasks of all edge devices to the cloud side for completion. In addition, from formulas (1) and (2), it can be seen that having as many detections as possible with high detection accuracy on the cloud side not only helps to improve R acc , but also can reduce the false negative rate R miss . Therefore, when the available system bandwidth B is given, since the bandwidth occupied by a single device is B sub , in each cycle, devices can migrate their detection tasks to the cloud server to use the large model to complete accurate detection.

[0096] Specifically, which devices can migrate their detection tasks to the cloud side will be determined based on the following criterion: At the beginning of each cycle, after all devices complete local detection, regardless of the probability of correct judgment, they send requests to the cloud side. Then, the cloud server sorts the probabilities of correct judgment of all devices in ascending order from small to large, and selects the first devices to authorize bandwidth resources for them, and the remaining requests will be rejected.

[0097] Therefore, increasing the number of edge devices means that more devices with a relatively small probability of correct judgment will not be able to migrate their tasks to the cloud side, thus reducing the detection accuracy rate and increasing the false negative rate. Therefore, the bandwidth B, the detection accuracy rate Γ acc and the false negative rate Γ missWhen given, there is a maximum value for the number of edge devices that the system can support, and the bisection method is used to solve it. It should be noted that the above inference is completed on the premise that all devices can successfully send task migration requests through the control channel, that is, it is assumed that the control channel is infinite by default. However, this is an ideal assumption and the control channel is usually limited in the actual system. Therefore, the maximum number of edge devices that the system can support obtained in this part is an upper bound.

[0098] The specific solution process is as follows:

[0099] ① Initial setting: First, set the upper and lower limits of the number of edge devices: the lower limit U min is set to a relatively small value, such as the upper limit U max is set to a relatively large value to ensure that under this setting, the detection accuracy rate Γ acc or the false negative rate Γ miss cannot meet the requirements.

[0100] ② Iterative calculation: First, calculate the intermediate value. In each iteration, calculate the intermediate value of the number of devices Then, perform performance evaluation. When the number of devices is U mid , if the detection accuracy rate R acc is not lower than the set threshold Γ acc and the false negative rate R miss is lower than the set threshold Γ miss , it means that the system can fully support this number of devices. Next, gradually increase the number of devices and set U min = U mid . If one or both of R acc and R miss do not meet the requirements, it means that the number of devices is too large and needs to be reduced. Set U max = U mid .

[0101] ③ Convergence determination: Continuously repeat the above process until the gap between U min and U max is small enough to meet the system requirement of accuracy ε U (that is, |U max - U min | ≤ ε U ), and the final obtained U mid is the maximum number of edge devices that the system can support.

[0102] The minimum bandwidth required for the system can be set according to the minimum detection accuracy rate, the maximum false negative rate, and the set number of edge devices. The specific calculation process is as follows:

[0103] The system supports that the number of end - side devices, the detection accuracy rate are positively correlated with the bandwidth, and the false - negative rate is negatively correlated with the bandwidth. Therefore, when U, Γ acc and Γ miss are given, the bisection method can still be used to solve for the required minimum bandwidth such that R acc ≥Γ acc and R miss <Γ miss are satisfied. Similar to solving for the maximum number of end - side devices that the system can support given a bandwidth, it is also assumed that the control channel is infinite when solving for the minimum bandwidth required by the system. Therefore, the minimum bandwidth required by the system obtained in this part is a lower bound.

[0104] The specific solution process is as follows:

[0105] ① Initial setting: First, set the upper and lower limits of the bandwidth. The lower limit B min is close to the minimum bandwidth that the system can support, and the upper limit B max needs to ensure that the detection accuracy rate Γ acc and the false - negative rate Γ miss can meet the requirements under this setting.

[0106] ② Iterative process: First, calculate the intermediate value If the detection accuracy rate R acc is not lower than the set threshold Γ acc and the false - negative rate R miss is lower than the set threshold Γ miss , it means that this bandwidth is feasible. Next, try to reduce the bandwidth, let B max =B mid ; otherwise, it means that this bandwidth is insufficient and the bandwidth needs to be increased, let B min =B mid .

[0107] ③ Convergence determination: Continuously repeat the above process until |B max - B min |≤ε B (ε B is the set accuracy requirement). The finally obtained B mid is the minimum bandwidth that meets the requirements of the detection accuracy rate and the false - negative rate.

[0108] Finding the minimum bandwidth can not only effectively save resources but also improve the overall efficiency of the system in scenarios with limited bandwidth resources. For example, in an actual scenario, multiple subsystems may share the same communication link. If the early - warning system occupies too much bandwidth, it may affect the data transmission of other critical tasks.

[0109] Calculate the number of control channels that can achieve the maximum detection accuracy according to the given number of edge devices, system bandwidth, and the maximum false negative rate allowed by the system. The specific process is as follows:

[0110] In the actual scenario, the control channels are usually limited. That is, too many devices sending task migration requests to the cloud side will cause congestion in the control channels, resulting in the failure of request sending and affecting the system performance. On the other hand, if too few devices send requests, although it will not fail due to control channel congestion, there may be many devices with a relatively small probability of correct judgment that do not send migration requests, making the system performance also poor. Therefore, when the control channels are limited, it is very important to control the number of edge devices sending requests in each cycle to improve the detection accuracy. In addition, when the number of devices sending requests is fixed, it is also crucial to further determine which devices send requests.

[0111] The credible threshold Γ P can be combined to determine which devices send task migration requests. Specifically, for any device u, if its probability of correct judgment is less than Γ P , then randomly select one control channel from the K control channels to send a request. If multiple devices simultaneously select the same control channel, it is considered that a collision occurs and the requests of all devices involved in the collision fail. In this context, given the system bandwidth B, the number of devices U, and the false negative rate Γ miss , the detection accuracy R P can be maximized by optimizing the initial credible threshold Γ acc . This optimization problem can be solved using the particle swarm optimization algorithm. The specific process is as follows:

[0112] ① Definition of fitness function: Define the fitness function This function takes Γ P as input and returns a fitness value. If the constraint R miss <Γ miss is satisfied, the fitness value is R acc , otherwise the fitness value is set to a smaller value -1 as a penalty.

[0113] ② Initialization of particle swarm: Set N particles (represented by the set ), and initialize a position (i.e., the initial value of Γ P ) and a velocity

[0114] for any particle n. ③ Fitness evaluation: Let represent the fitness value obtained by particle n at position pBest,n , and use x pBest,n) denote the individual optimal position and individual optimal value of particle n, denoted by x gBest and f(x gBest ) = max{f(x pBest,1 ), …, f(x pBest,N )} denote the global optimal position and global optimal value of all particles; Since it is currently the 1st iteration, so And

[0115] ④ Main loop:

[0116] a. Update individual optimal and global optimal: Without loss of generality, assume that it is currently the i-th iteration. For any particle n, compare its fitness value with the individual optimal position it has experienced. If then set Then compare the fitness value of each particle with f(x gBest ). If it is larger than f(x gBest ), then perform replacement.

[0117] b. Update the velocity and position of each particle: For any particle n, calculate the new velocity

[0118]

[0119] and new position

[0120]

[0121] respectively according to the velocity update formula and position update formula, where w is the inertia weight, which is used to control the tendency of the particle to maintain its current velocity; the learning factors c1 and c2 respectively determine the degree to which the particle learns from the individual historical optimal position and the global optimal position; r1 and r2 are random numbers uniformly randomly selected from [0, 1]. If the new position exceeds the boundary [0, 1], then limit it within [0, 1]. Then enter the (i + 1)-th iteration.

[0122] ⑤ Output result: After reaching the maximum number of iterations I, output the global optimal position x gBest (i.e., the optimal credible threshold) and the global optimal value f(x gBest )(i.e., the maximum detection accuracy).

[0123] This application will analyze the relationship between the bandwidth and the number of edge devices when the minimum detection accuracy and the maximum false alarm rate are given through simulation experiments, and the influence of the number of control channels on the maximum detection accuracy when the bandwidth, the number of devices, and the maximum false alarm rate allowed by the system are given. The specific simulation parameters are shown in Table 1.

[0124] Table 1: Simulation Parameter Settings

[0125]

[0126] As Figure 2 shown, the curve of the maximum number of edge devices supported by the system with respect to bandwidth. It can be seen from the figure that as the bandwidth increases, the maximum number of edge devices supported by the system also increases significantly; in addition, it can be seen that increasing the maximum false negative rate threshold Γ miss can also effectively increase the maximum number of edge devices supported by the system, because the number of edge devices is positively correlated with the false negative rate.

[0127] As Figure 3 shown, the impact of the number of edge devices on the minimum bandwidth required by the system is analyzed. It can be seen that the minimum bandwidth required by the system is positively correlated with the number of edge devices, that is, increasing the number of edge devices requires more bandwidth to migrate the detection task to the cloud server; in addition, increasing Γ miss helps to reduce the required bandwidth, indicating that the bandwidth shortage situation can be addressed by sacrificing some false negative rate performance.

[0128] Table 2: Impact of the Number of Control Channels on the Maximum Detection Accuracy

[0129]

[0130]

[0131] Table 2 shows the impact of the number of control channels on the maximum detection accuracy when the bandwidth is 100 MHz and the number of devices is 150. As the number of control channels increases, the number of devices that can successfully send migration requests increases, so the maximum detection accuracy that the system can achieve is improved; the larger Γ miss is, the looser the requirement for the system in terms of false negative rate, so the maximum detection accuracy is also improved.

[0132] Embodiment

[0133] The best specific application embodiment of the present invention is elaborated in detail taking the power grid fire warning system as an example as follows:

[0134] As Figure 4 shown, the power grid fire warning system needs to monitor the operating status of the power grid in real time, timely detect potential fire hazards, and ensure that effective preventive measures can be taken before a fire occurs. Due to the large scale of the power grid, the large number of devices involved, and the high requirement for detection accuracy, it is difficult to meet the requirements by simply relying on the large model on the cloud side or the lightweight model on the edge side alone. Therefore, the joint deployment scheme of the cloud-edge-end collaborative large model and lightweight model proposed by the present invention can be applied to this scenario to optimize the performance of the power grid fire warning system.

[0135] Modeling of a Power Grid Fire Early Warning System Assisted by Large Models and Lightweight Models:

[0136] Deploy a high-precision large model in the cloud to handle complex fire early warning algorithms and data analysis tasks; deploy lightweight models at each node of the power grid (i.e., the edge side) to monitor the operating status of the power grid in real time and trigger the early warning mechanism in a timely manner when abnormalities are detected.

[0137] Solving for the Maximum Number of Edge Devices Supported by the System Given a Bandwidth:

[0138] According to resource limitations such as the scale of the power grid, data transmission rate, and available bandwidth, calculate and determine the maximum number of edge devices (i.e., the number of power grid nodes) that the system can support under the given bandwidth condition. This helps optimize system resource allocation and ensure the real-time and efficient data transmission.

[0139] Solving for the Minimum Bandwidth Required by the System Given the Number of Edge Devices:

[0140] According to the number of power grid nodes and the required data transmission volume, calculate and determine the minimum bandwidth required by the system. This helps ensure that the system can operate normally and meet the data transmission requirements under the given number of devices.

[0141] Solving for the Optimal Trust Threshold with the Highest Detection Accuracy under Limited Control Channels:

[0142] Under the condition of limited control channels, through calculation and optimization, determine an optimal trust threshold to maximize the detection accuracy. This helps maintain the detection accuracy and reliability of the system under resource constraints.

[0143] In an embodiment of the present invention, a cloud-edge-end collaborative large model and lightweight model joint deployment system is provided, including a preset module, an edge device number acquisition module, a minimum bandwidth acquisition module, and a trust threshold acquisition module:

[0144] The preset module establishes a cloud server and edge devices for environmental early warning detection according to the system usage environment and sets an initial trust threshold;

[0145] The edge device number acquisition module obtains the detection accuracy of the cloud server and edge devices according to the initial trust threshold, obtains the minimum detection accuracy and the maximum false negative rate according to the detection accuracy of the cloud server and edge devices, and calculates the maximum number of edge devices that can be set according to the minimum detection accuracy, the maximum false negative rate, and the set system bandwidth;

[0146] The minimum bandwidth acquisition module calculates the minimum bandwidth required by the system that can be set according to the minimum detection accuracy, the maximum false negative rate, and the set number of edge devices;

[0147] A credible threshold acquisition module calculates a credible threshold for the maximum detection accuracy based on the given number of edge devices, system bandwidth, and the maximum false negative rate allowed by the system.

[0148] In another embodiment of the present invention, a terminal device is provided. The terminal device includes a processor and a memory. The memory is used to store a computer program, and the computer program includes program instructions. The processor is used to execute the program instructions stored in the computer storage medium. The processor may be a Central Processing Unit (CPU), or may also be other general-purpose processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field-Programmable Gate Arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. It is the computing core and control core of the terminal, and is suitable for implementing one or more instructions. Specifically, it is suitable for loading and executing one or more instructions to implement the corresponding method flow or corresponding function. The processor described in the embodiment of the present invention can be used for the operation of the method for jointly deploying large models and lightweight models in cloud-edge-terminal collaboration.

[0149] In another embodiment of the present invention, a storage medium is also provided, specifically a computer-readable storage medium (Memory). The computer-readable storage medium is a memory device in the terminal device and is used to store programs and data. It can be understood that the computer-readable storage medium here can include both the built-in storage medium in the terminal device and, of course, the extended storage medium supported by the terminal device. The computer-readable storage medium provides a storage space, and the operating system of the terminal is stored in this storage space. And, one or more instructions suitable for being loaded and executed by the processor are also stored in this storage space. These instructions can be one or more computer programs (including program codes). It should be noted that the computer-readable storage medium here can be a high-speed RAM memory or a non-volatile memory, such as at least one disk memory. One or more instructions stored in the computer-readable storage medium can be loaded and executed by the processor to implement the corresponding steps of the method for jointly deploying large models and lightweight models in cloud-edge-terminal collaboration in the above embodiments.

[0150] Those skilled in the art should understand that the embodiments of the present application can be provided as methods, systems, or computer program products. Therefore, the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.

[0151] The present application is described with reference to the flowcharts and / or block diagrams of methods, apparatuses (systems), and computer program products according to the embodiments of the present application. It should be understood that each flow and / or block in the flowchart and / or block diagram, as well as the combination of flows and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to generate a machine, such that the instructions executed by the processor of the computer or other programmable data processing devices generate means for implementing the functions specified in Figure 1 one or more of the processes Figure 1 or blocks.

[0152] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, such that the instructions stored in the computer-readable memory generate a manufactured article including instruction means that implement the functions specified in Figure 1 one or more of the processes Figure 1 or blocks.

[0153] These computer program instructions can also be loaded onto a computer or other programmable data processing device, such that a series of operation steps are executed on the computer or other programmable device to generate a computer-implemented process, and thus the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in Figure 1 one or more of the processes Figure 1 or blocks.

[0154] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit them. Although the present invention has been described in detail with reference to the above embodiments, those of ordinary skill in the art should understand that: modifications or equivalent replacements can still be made to the specific implementation manners of the present invention, and any modifications or equivalent replacements made without departing from the spirit and scope of the present invention should be covered by the protection scope of the claims of the present invention.

[0155] The present invention proposes a joint deployment of a large model and a lightweight model with cloud-edge-end collaboration, and analyzes the relationship between the bandwidth and the number of end-side devices supported by the system when the minimum detection accuracy and the maximum false alarm rate are given, as well as the influence of the number of control channels on the maximum detection accuracy when the bandwidth, the number of devices, and the maximum false alarm rate allowed by the system are given. This provides a reference for the collaborative design of large models and lightweight models in the future and is of great significance for setting key parameters during the actual deployment of related applications.

Claims

1. A method for jointly deploying a large model and a lightweight model with cloud-edge-end collaboration, characterized in that It includes the following steps: Establish a cloud server and edge devices for environmental early warning detection according to the system usage environment, and set an initial trust threshold; Obtain the detection accuracies of the cloud server and edge devices according to the initial trust threshold, obtain the minimum detection accuracy and the maximum false negative rate according to the detection accuracies of the cloud server and edge devices, and calculate the maximum number of edge devices that can be set according to the minimum detection accuracy, the maximum false negative rate, and the set system bandwidth; Calculate the minimum system bandwidth that can be set according to the minimum detection accuracy, the maximum false negative rate, and the set number of edge devices; Calculate the trust threshold of the maximum detection accuracy according to the given number of edge devices, system bandwidth, and the maximum false negative rate allowed by the system.

2. The method for jointly deploying a large model and a lightweight model with cloud-edge-end collaboration according to claim 1, wherein Obtain the detection accuracies of the cloud server and edge devices according to the initial trust threshold, which specifically includes the following steps: For any end - side device It determines the current environmental state within any period τ and gives the probability of the correctness of this determination If not less than the initial trust threshold Γ P , then the determination of the end - side device u is trustworthy, and when the end - side device u determines that the current environment is abnormal, it sends an abnormal state warning to the cloud - side; If then the determination of the end - side device u is untrustworthy. Then the end - side device u sends a task migration request to the cloud server and sends the original data after being authorized by the cloud server. The cloud server makes a further determination and the probability of the correctness of the determination is denoted as 3. A method for jointly deploying a large model and a lightweight model with cloud-edge-end collaboration according to claim 2, characterized in that Obtain the minimum detection accuracy and the maximum false negative rate according to the detection accuracies of the cloud server and edge devices, which specifically includes the following steps: Edge device The probability that the environmental state is accurately judged during detection at The probability that abnormal data is judged as normal is The probability that the cloud server accurately judges the environmental state is The probability that abnormal data is judged as normal is Then τ max The overall detection accuracy and false negative rate of the system within and Among them is the probability of this event occurring, and the minimum detection accuracy and the maximum false alarm rate are denoted as Γ acc and Γ miss respectively. Then R acc ≥Γ acc and R miss <Γ miss .

4. A method for jointly deploying a large model and a lightweight model with cloud-edge-end collaboration according to claim 3, characterized in that Calculate the maximum number of edge devices that can be set according to the minimum detection accuracy, the maximum false negative rate, and the set system bandwidth, which specifically includes the following steps: Initial setting: Set the upper and lower limits of the number of end-side devices: lower limit U min Set to Upper limit U max The set value causes the detection accuracy Γ of the system acc Or the false negative rate Γ miss Cannot meet the requirements; Iterative calculation: In each iteration step, calculate the intermediate value of the number of devices Then perform performance evaluation. When the number of devices is U mid If the detection accuracy rate R acc is not lower than the set threshold Γ acc and the false negative rate R miss is lower than the set threshold Γ miss , then gradually increase the number of devices, set U min = U mid , and repeat the calculation until one or both of R acc and R miss do not meet the requirements. Then set U max = U mid , until the gap between U min and U max meets the accuracy ε required by the system U . The finally obtained U mid is the maximum number of edge devices supported by the system.

5. A method for jointly deploying a large model and a lightweight model with cloud-edge-end collaboration according to claim 3, characterized in that Calculate the minimum system bandwidth that can be set according to the minimum detection accuracy, the maximum false negative rate, and the set number of edge devices, which specifically includes the following steps: Initial setting: Set the upper and lower limits of the bandwidth, the lower limit B min is close to the minimum bandwidth that the system can support, and the set upper limit B max value ensures the detection accuracy Γ acc and the false negative rate Γ miss both meet the requirements; Iterative calculation: Calculate the intermediate value If the detection accuracy rate R acc is not lower than the set threshold Γ acc and the false negative rate R miss is lower than the set threshold Γ miss , then gradually reduce the bandwidth, let B max = B mid ; otherwise, it means that this bandwidth is insufficient and the bandwidth needs to be increased, let B min = B mid , until |B max - B min | ≤ ε B , where ε B is the set precision requirement, and the finally obtained B mid is the minimum bandwidth that meets the requirements of the detection accuracy rate and the false negative rate.

6. A method for jointly deploying a large model and a lightweight model in cloud-edge-end collaboration according to claim 1, characterized in that, Calculate the credible threshold of the maximum detection accuracy based on the given number of edge devices, system bandwidth, and the maximum false negative rate allowed by the system. Specifically, optimize the initial credible threshold Γ P to maximize the detection accuracy R acc , and use the particle swarm optimization algorithm to solve it. The specific process is as follows: Fitness function: Let the fitness function This function accepts Γ P as input and returns a fitness value. If the constraint R miss <Γ miss is satisfied, the fitness value is R acc , otherwise the fitness value is set to a smaller value -1 as a penalty; Particle swarm initialization: Set N particles, and the set Initialize a position and velocity Fitness evaluation: Use to represent the fitness value obtained by particle n at position . Let x pBest,n and f(x pBest,n ) represent the individual best position and individual best value of particle n, respectively. Let x gBest and f(x gBest ) = max{f(x pBest,1 ), …, f(x pBest,N )} represent the global best position and global best value of all particles. At the first iteration, and Update the individual best and global best: Assume that the current iteration is the $i$-th iteration. For any particle $n$, compare its fitness value with its individual best position it has experienced. If then set Then compare the fitness value of each particle with $f(x gBest ). If it is greater than $f(x gBest ), then replace it; Update the velocity and position of each particle: For any particle n, calculate the new velocity according to the velocity update formula and the position update formula respectively: and the new position where w is the inertia weight, which is used to control the tendency of the particle to maintain its current velocity; the learning factors c1 and c2 respectively determine the degree to which the particle learns from its individual historical optimal position and the global optimal position; r1 and r2 are random numbers uniformly and randomly selected from [0,1]. If the new position exceeds the boundary [0,1], it is restricted within [0,1], and then enter the (i + 1)-th iteration. After reaching the maximum number of iterations I, obtain the optimal trust threshold and the maximum detection accuracy.

7. A joint deployment system for large models and lightweight models with cloud-edge-device collaboration, characterized in that, It includes a preset module, an edge device number acquisition module, a minimum bandwidth acquisition module, and a trust threshold acquisition module: The preset module establishes a cloud server and edge devices for environmental early warning detection according to the system usage environment, and sets an initial trust threshold; The edge device number acquisition module obtains the detection accuracies of the cloud server and edge devices according to the initial trust threshold, obtains the minimum detection accuracy and the maximum false negative rate according to the detection accuracies of the cloud server and edge devices, and calculates the maximum number of edge devices that can be set according to the minimum detection accuracy, the maximum false negative rate, and the set system bandwidth; The minimum bandwidth acquisition module calculates the minimum system bandwidth that can be set according to the minimum detection accuracy, the maximum false negative rate, and the set number of edge devices; The trust threshold acquisition module calculates the trust threshold of the maximum detection accuracy according to the given number of edge devices, system bandwidth, and the maximum false negative rate allowed by the system.

8. A joint deployment system of a large model and a lightweight model for cloud-edge-terminal collaboration according to claim 7, characterized in that, Obtain the detection accuracies of the cloud server and edge devices according to the initial trust threshold, which specifically includes the following steps: For any end-side device It determines the current environmental state within any period τ and gives the probability of the correctness of this determination If is not less than the initial trust threshold Γ P , then the determination of the end-side device u is trustworthy, and when the end-side device u determines that the current environment is abnormal, it sends an abnormal status warning to the cloud side; if then the determination of the end-side device u is not trustworthy, and then the end-side device u sends a task migration request to the cloud server and sends the original data after being authorized by the cloud server. The cloud server makes a further determination and the probability of the correctness of the determination is denoted as 9. The joint deployment system of a large model and a lightweight model with cloud-edge-end collaboration according to claim 8, characterized in that, Obtain the minimum detection accuracy and the maximum false negative rate according to the detection accuracies of the cloud server and edge devices, which specifically includes the following steps: Edge device The probability that the environmental status is accurately judged during detection at The probability that abnormal data is judged as normal is The probability that the cloud server accurately judges the environmental status is The probability that abnormal data is judged as normal is Then τ max In one cycle, the overall detection accuracy and false negative rate of the system are respectively and Among them is the probability of this event occurring. The minimum detection accuracy and the maximum false alarm rate are respectively denoted as Γ acc and Γ miss . Then R acc ≥ Γ acc and R miss < Γ miss .

10. A joint deployment system of a large model and a lightweight model with cloud-edge-end collaboration according to claim 9, characterized in that, Calculate the maximum number of edge devices that can be set according to the minimum detection accuracy, the maximum false negative rate, and the set system bandwidth. The specific steps are as follows: Initial setting: Set the upper and lower limits of the number of end-side devices: lower limit U min Set to Upper limit U max The set value makes the detection accuracy Γ of the system acc Or the false negative rate Γ miss Unable to meet the requirements; Iterative calculation: In each iteration, calculate the intermediate value of the number of devices Then perform performance evaluation. When the number of devices is U mid If the detection accuracy rate R acc is not lower than the set threshold Γ acc and the false negative rate R miss is lower than the set threshold Γ miss , then gradually increase the number of devices, set U min = U mid , and repeat the calculation until one or both of R acc and R miss do not meet the requirements. Then set U max = U mid , until the gap between U min and U max meets the accuracy ε U required by the system. The finally obtained U mid is the maximum number of edge devices supported by the system.

11. A cloud-edge-terminal collaborative large model and lightweight model joint deployment system according to claim 9, characterized in that, Calculate the minimum bandwidth required for the system that can be set according to the minimum detection accuracy, the maximum false negative rate, and the set number of edge devices. The specific steps are as follows: Initial setting: Set the upper and lower limits of the bandwidth, the lower limit B min is close to the minimum bandwidth that the system can support, and the set upper limit B max value ensures the detection accuracy Γ acc and the false negative rate Γ miss both meet the requirements; Iterative calculation: Calculate the intermediate value If the detection accuracy rate R acc is not lower than the set threshold Γ acc and the false negative rate R miss is lower than the set threshold Γ miss , then gradually reduce the bandwidth, let B max = B mid ; otherwise, it means that this bandwidth is insufficient and the bandwidth needs to be increased. Let B min = B mid , until |B max - B min | ≤ ε B , where ε B is the set precision requirement, and the finally obtained B mid is the minimum bandwidth that meets the requirements of the detection accuracy rate and the false negative rate.

12. A cloud-edge-terminal collaborative large model and lightweight model joint deployment system according to claim 7, characterized in that, Calculate the credible threshold of the maximum detection accuracy based on the given number of edge devices, system bandwidth, and the maximum false negative rate allowed by the system. Specifically, optimize the initial credible threshold Γ P to maximize the detection accuracy R acc , and use the particle swarm optimization algorithm to solve it. The specific process is as follows: Fitness function: Let the fitness function This function accepts Γ P as input and returns a fitness value. If the constraint R miss <Γ miss is satisfied, the fitness value is R acc , otherwise the fitness value is set to a smaller value -1 as a penalty; Particle swarm initialization: Set N particles, and the set Initialize a position for any particle n and velocity Fitness evaluation: Adopt to represent the position of particle n at The obtained fitness value is denoted by x pBest,n and f(x pBest,n ) represent the individual optimal position and individual optimal value of particle n, denoted by x gBest and f(x gBest ) = max{f(x pBest,1 ), …, f(x pBest,N )} represent the global optimal position and global optimal value of all particles; At the first iteration, and Update the individual best and global best: Assume that the current iteration is the $i$-th iteration. For any particle $n$, compare its fitness value with the individual best position it has experienced. If then set Then compare the fitness value of each particle with $f(x gBest ). If it is greater than $f(x gBest ), then replace it; Update the velocity and position of each particle: For any particle n, calculate the new velocity according to the velocity update formula and the position update formula respectively: And the new position where w is the inertia weight, which is used to control the tendency of the particle to maintain its current velocity; the learning factors c1 and c2 respectively determine the degree to which the particle learns from its individual historical optimal position and the global optimal position; r1 and r2 are random numbers uniformly and randomly selected from [0,1]. If the new position exceeds the boundary [0,1], it is restricted within [0,1], and then enter the (i + 1)-th iteration. After reaching the maximum number of iterations I, obtain the optimal credible threshold and the maximum detection accuracy.

13. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the cloud-edge-end collaborative large model and lightweight model joint deployment method according to any one of claims 1 to 6.

14. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the steps of the cloud-edge-end collaborative large model and lightweight model joint deployment method according to any one of claims 1 to 6.

Citation Information

Cited By

  • Intelligent management method and system for ecological environmental protection base

    CN121391050A