Customized production-oriented edge node lightweight AI model adaptive compression method
By integrating multi-strategy compression methods and an adaptive decision engine, the problem of balancing compression rate and performance in customized production of lightweight AI models for edge nodes is solved. This achieves high efficiency and stability of the model under different tasks and hardware environments, reducing resource consumption and migration costs.
Patent Information
- Application Number
- CN202511530516.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-24
- Publication Date
- 2026-01-09
AI Technical Summary
Lightweight AI models at edge nodes struggle to balance compression ratio and performance in customized production. Single compression strategies are ill-suited to dynamic loads and multi-task requirements. Traditional methods have limitations and unreliability, making it difficult to account for performance variations of the model under different tasks and data characteristics.
A multi-strategy compression method is adopted, integrating pruning, quantization, low-rank decomposition and knowledge distillation. An adaptive compression decision engine dynamically selects the optimal compression strategy based on task constraints and hardware resources, generating an adapted model compression scheme. The strategy is adjusted in real time during model deployment to balance accuracy, latency and resource consumption.
It enables the automatic generation of optimal model compression schemes based on customized production tasks and hardware environments, improving the flexibility and applicability of models in diverse application scenarios, reducing storage and computing resource consumption, enhancing the model's migration capability and application breadth in heterogeneous edge devices, and reducing the cost of repeated training and maintenance.
Smart Images

Figure CN121301016A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of intelligent manufacturing and edge computing technology, specifically to an adaptive compression method for lightweight AI models of edge nodes for customized production. Background Technology
[0002] Lightweight AI models for edge nodes are crucial for intelligent manufacturing and customized production, directly impacting the real-time performance, task execution efficiency, and resource consumption of the production process. Numerous studies have shown that the operational efficiency of edge node models is closely related to model structural complexity, hardware computing power, and task characteristics. Pre-optimization and adaptive model compression are essential for achieving efficient and low-cost customized production. In practical deployment, edge node AI models are affected by various factors, such as computing power constraints, memory capacity, task load fluctuations, and the diversity of data distribution, making model compression and deployment challenging. Traditional fixed pruning, quantization, or distillation methods can easily lead to decreased accuracy or insufficient adaptability, while also being computationally complex and time-consuming. The uncertainty, multi-task load, and dynamic data changes inherent in edge computing environments necessitate models with high adaptability and self-learning capabilities to balance compression efficiency and inference accuracy.
[0003] For edge node model compression, researchers have proposed various methods at different times. Early studies often employed linear pruning or quantization strategies, reducing model computation through empirical parameter setting, but this struggled to balance compression ratio and performance. With the development of adaptive algorithms, researchers began combining task requirements, computational constraints, and model structure to achieve dynamic adaptive compression, thereby improving the model's adaptability and deployment efficiency in customized production tasks. Simultaneously, the nonlinear fitting ability and self-learning characteristics of neural networks enable adaptive compression methods to improve the adaptability of lightweight models to multi-task and dynamic data environments while maintaining model accuracy. In recent years, common adaptive compression methods for edge node models include:
[0004] Method 1: Adaptive compression method for edge node models based on structural pruning:
[0005] By leveraging a teacher network to guide a lightweight model in learning key features, and by dynamically removing redundant parameters through structural pruning, combined with an adaptive optimization algorithm to adjust the weights and thresholds of the compressed model, we can reduce accuracy loss and improve inference efficiency.
[0006] Method 2: Adaptive Compression Method Based on Quantization Edge Node Model
[0007] By performing multi-granularity quantization representation of model parameters and dynamically selecting quantization precision based on the computing power of edge nodes and task requirements, it is helpful to maintain the performance stability of the model on the target task while effectively reducing storage and computing overhead, thereby achieving more efficient adaptive compression.
[0008] Method 3: Adaptive Compression Method for Edge Node Models Based on Knowledge Distillation
[0009] By employing knowledge distillation, knowledge from large models can be transferred to lightweight models, which can not only effectively reduce the model's parameter size but also improve adaptability while maintaining prediction accuracy. This method is commonly used in model compression and deployment at edge nodes.
[0010] The deployment of lightweight AI models on edge nodes in customized production is affected by various factors, such as device computing power, memory capacity, task complexity, and data distribution fluctuations, making model compression and optimization difficult. A single compression strategy cannot simultaneously balance inference efficiency and model accuracy, limiting the performance improvement potential of lightweight models in practical applications. Currently, edge node model compression mainly relies on a single method or fixed strategy, which has the following main drawbacks:
[0011] (1) A single compression strategy is difficult to adapt to dynamic load and multi-task requirements. Directly pruning or quantizing the original model may result in the loss of important parameters, and it is difficult to take into account the performance changes of the model under different tasks and data characteristics, and it is also difficult to make full use of the nonlinear information at different levels in the model structure.
[0012] (2) Whether it is a traditional compression method or a single adaptive strategy, a single method usually has unavoidable limitations or unreliability. Combined compression strategies can integrate the advantages of multiple methods and reduce the performance loss that a single strategy may cause. Summary of the Invention
[0013] To address the aforementioned shortcomings in existing technologies, this invention provides a lightweight adaptive compression method for edge node AI models designed for customized production.
[0014] To achieve the above-mentioned objectives, the technical solution adopted by this invention is as follows:
[0015] An adaptive compression method for lightweight AI models at edge nodes for customized production includes the following steps:
[0016] S1. Based on the personalized production task requirements, extract and analyze the constraints of AI model deployment at edge nodes, including prediction accuracy, inference latency, and energy consumption indicators.
[0017] S2. Obtain hardware resource information of edge nodes, including processor performance, storage capacity, memory size and network bandwidth;
[0018] S3. Based on a multi-strategy compressed candidate pool, at least one compression method among pruning, quantization, low-rank decomposition and knowledge distillation is integrated to form a candidate strategy set.
[0019] S4. Through the adaptive compression decision engine, the optimal compression strategy is dynamically selected or combined based on task constraints and hardware resources to generate an adapted model compression scheme.
[0020] S5. During model deployment, the compression strategy is dynamically adjusted based on real-time performance to form an iterative optimization mechanism that balances accuracy, latency, and resource consumption.
[0021] Furthermore, the specific method for analyzing the personalized customization production task requirements in S1 is as follows:
[0022] Based on the target type and performance requirements of the customized production task, the prediction accuracy threshold, maximum allowable inference latency, and energy consumption limit of the quantified model are quantified and mapped to a measurable constraint vector.
[0023] Furthermore, the specific method for edge node resource awareness in S2 is as follows:
[0024] The system interface collects real-time data on CPU / GPU computing power, memory capacity, storage space, and network bandwidth of edge nodes, and normalizes it into a unified resource description vector.
[0025] Furthermore, the construction method of the multi-strategy compression candidate pool in S3 is as follows:
[0026] The predefined pruning strategies include structured pruning based on channel sparsity, the quantization strategies include 8-bit fixed-point weights and activation compression, the knowledge distillation strategy uses a lightweight teacher model to transfer knowledge, and the low-rank decomposition strategy performs dimensionality reduction on the weight matrix.
[0027] Furthermore, the adaptive compression decision engine in S4 operates as follows:
[0028] S41. Represent the compression strategy as a hyperparameter configuration vector and construct the decision space;
[0029] S42. Design a performance scoring model that integrates accuracy, latency, memory usage, and energy consumption indicators, and calculates the strategy score using a weighted function.
[0030] S43. Integrating reinforcement learning and Bayesian optimization, the optimal policy is dynamically selected by fitting Markov decision processes and Gaussian processes.
[0031] Furthermore, the specific calculation method of the performance scoring model in S42 is as follows:
[0032] ;
[0033] In the formula, Let be the performance scoring function, s be the compression strategy combination vector, T be the production task constraints, and H be the edge node resources. To improve the accuracy of the compressed model, For reasoning delay, For memory usage, These are the corresponding weighting coefficients.
[0034] Furthermore, the collaborative approach between reinforcement learning and Bayesian optimization in S43 is as follows:
[0035] In the offline phase, Bayesian optimization is used to quickly explore the candidate policy space, and in the deployment phase, reinforcement learning is used to dynamically schedule policies based on real-time feedback to balance exploration and utilization.
[0036] Furthermore, the specific method of the iterative optimization mechanism in S5 is as follows:
[0037] S51. Real-time monitoring of model inference time, accuracy loss, memory usage, and energy consumption.
[0038] S52. Construct a closed-loop optimization objective function to minimize the weighted combination of accuracy loss and delay;
[0039] S53. Dynamically adjust the compression ratio and update the compression parameters through gradient descent or strategy search.
[0040] S54. Adjust the compression strategy in real time based on feedback indicators to form adaptive closed-loop control.
[0041] Furthermore, the dynamic adjustment strategy for the compression ratio in S53 is as follows:
[0042] ;
[0043] In the formula, For learning rate, The current compression ratio, This is the compression ratio for the next adjustment. This is the closed-loop loss function.
[0044] The present invention has the following beneficial effects:
[0045] (1) It can automatically generate the optimal model compression scheme according to different customized production task requirements and the hardware environment (such as computing power, storage and bandwidth) of the edge nodes. Compared with the traditional method of relying on manual parameter setting, the compression ratio and strategy are dynamically adjusted through the adaptive mechanism, avoiding the tedious manual parameter tuning process. This not only improves the efficiency of model optimization, but also enhances the flexibility and applicability of the model in diverse application scenarios, ensuring that the model can maintain stable performance under different conditions.
[0046] (2) It has high versatility and adaptability. After compression and optimization, the same lightweight AI model can be quickly deployed to various types of edge nodes according to different hardware conditions and task requirements. Whether it is a GPU node with strong computing power or a low-power CPU node with limited resources, the model can automatically adjust its structure and parameters to achieve efficient operation. This feature significantly improves the model's migration capability and application breadth in heterogeneous edge devices, meeting the diverse and cross-platform practical needs in customized production.
[0047] (3) The balance between accuracy, computational load and storage overhead was fully considered during the model compression and optimization process. Under the premise of ensuring prediction accuracy and task performance, the parameter size and computational complexity of the model were significantly reduced through reasonable compression strategies, thereby reducing the occupation of storage and computing resources.
[0048] (4) It can well meet the needs of small-batch, diversified and customized production. Through adaptive compression, the AI model can be quickly adjusted and deployed in different tasks and process scenarios, avoiding repeated training and manual tuning caused by frequent changes in scenarios. It has strong portability between different edge nodes, effectively reducing the cost of production line model migration and maintenance. Attached Figure Description
[0049] Figure 1 This is a flowchart illustrating the overall process framework of the method of the present invention.
[0050] Figure 2 This is a schematic diagram of the personalized production task requirements and edge node resource perception module in an embodiment of the present invention.
[0051] Figure 3 This is a schematic diagram illustrating the working principle of the adaptive compression decision engine in an embodiment of the present invention.
[0052] Figure 4 This is a flowchart illustrating the iterative optimization closed-loop process of an embodiment of the present invention. Detailed Implementation
[0053] The specific embodiments of the present invention are described below to enable those skilled in the art to understand the present invention. However, it should be understood that the present invention is not limited to the scope of the specific embodiments. For those skilled in the art, various changes are obvious as long as they are within the spirit and scope of the present invention as defined and determined by the appended claims. All inventions utilizing the concept of the present invention are protected.
[0054] An adaptive compression method for lightweight AI models at edge nodes for customized production, such as... Figure 1 As shown, it includes the following steps:
[0055] S1. Based on the personalized production task requirements, extract and analyze the constraints of AI model deployment at edge nodes, including prediction accuracy, inference latency, and energy consumption indicators.
[0056] like Figure 2 As shown, based on the specific customized production task requirements, the system comprehensively extracts and analyzes various constraints that the edge node AI model may face during actual deployment, including indicators such as model prediction accuracy, inference latency, and energy consumption. This embodiment describes a task on a personalized packaging production line where the task is target recognition, with an accuracy requirement of ≥95% and inference latency ≤50ms.
[0057] S2. Obtain hardware resource information of edge nodes, including processor performance, storage capacity, memory size and network bandwidth;
[0058] In this embodiment, before deploying and compressing the lightweight AI model on the edge node, it is necessary to comprehensively obtain the hardware information of the edge node, including key indicators such as processor performance (CPU / GPU computing power), storage capacity, memory size, and network bandwidth. In this embodiment, the edge node is an embedded GPU with 2GB of video memory and a power consumption limit of 15W.
[0059] S3. Based on a multi-strategy compressed candidate pool, at least one compression method among pruning, quantization, low-rank decomposition and knowledge distillation is integrated to form a candidate strategy set.
[0060] In this embodiment, multiple lightweight methods (pruning, quantization, low-rank decomposition, knowledge distillation, etc.) are pre-integrated to form a candidate strategy pool. The candidate strategy pool in this embodiment is as follows: 1) Pruning: Based on structured pruning, 20%~60% of parameters are pruned according to channel sparsity; 2) Quantization: 8-bit fixed-point quantization is used, supporting simultaneous compression of weights and activations; 3) Knowledge distillation: Lightweight teacher model is used to transfer knowledge and maintain detection accuracy.
[0061] S4. Through the adaptive compression decision engine, the optimal compression strategy is dynamically selected or combined based on task constraints and hardware resources to generate an adapted model compression scheme.
[0062] In this embodiment, as Figure 3 As shown, the goal of the adaptive compression decision engine is to dynamically select or combine the optimal model compression strategies (such as pruning, quantization, knowledge distillation, etc.) based on task constraints (such as latency, accuracy, and energy consumption) and hardware resources (such as memory and computing power). This system achieves this by integrating reinforcement learning and Bayesian optimization. In this embodiment, the system predicts the optimal "40% pruning + 8-bit quantization" combination scheme under the given hardware conditions, based on the task constraints.
[0063] (1) Compression strategy representation
[0064] Suppose there are N compression strategies, each with different hyperparameter settings, expressed as vectors. Let represent the choice and parameter configuration of the i-th strategy. The entire decision space can be represented as:
[0065] (1)
[0066] The compression strategy combination vector is:
[0067] (2)
[0068] in, It is a strategy Constraints of personalized customization production tasks and edge node resources The performance score is as follows.
[0069] (2) Performance scoring model
[0070] The performance scoring function of this method Taking into account model accuracy ,Delay Memory usage The comprehensive performance scoring model is as follows:
[0071] (3)
[0072] in This is a weighting coefficient, which can be adjusted accordingly based on changes in actual customized production task requirements.
[0073] (3) Integrating reinforcement learning and Bayesian optimization
[0074] Within the reinforcement learning framework, the selection of a compression policy can be viewed as a Markov decision process (MDP), and the optimal policy probability distribution is:
[0075] (4)
[0076] in It's a reward for each step. It is a discount factor. This is the optimal compression strategy selected by the adaptive strategy proposed in this invention.
[0077] In addition to reinforcement learning optimization, this method also integrates Bayesian optimization, that is, fitting the performance function through a Gaussian process. The Bayesian optimization update formula can be expressed as follows: The next compression strategy is selected through an acquisition function.
[0078] (5)
[0079] (6)
[0080] in This is the best performance observed so far. The desired improvement is to balance exploration and exploitation.
[0081] This method proposes to use Bayesian optimization to quickly explore and find a batch of candidate compression strategies in the offline stage, and to use reinforcement learning to dynamically schedule on the candidate set in the deployment stage.
[0082] S5. During model deployment, the compression strategy is dynamically adjusted based on real-time performance to form an iterative optimization mechanism that balances accuracy, latency, and resource consumption.
[0083] In actual deployment, the model compression strategy should not be static, but needs to be dynamically adjusted based on actual performance (such as inference time and accuracy loss) to form a closed-loop optimization mechanism. Closed-loop optimization ensures that the model maximizes performance under hardware resource constraints while maintaining task accuracy. In this embodiment, if the accuracy drops to <95% after deployment, the pruning ratio is appropriately reduced, and distillation is introduced to enhance training until the target is met.
[0084] like Figure 4 As shown, the specific steps include the following:
[0085] S51. Real-time monitoring of model inference time, accuracy loss, memory usage, and energy consumption.
[0086] Key metrics monitored during deployment include model inference time. Precision loss Memory usage Energy consumption Real-time performance can then be represented using vectors:
[0087] (7)
[0088] The real-time performance vector model can be obtained as follows:
[0089] (8)
[0090] in, For the current compression strategy, Due to hardware resource constraints, the function Describe the mapping between strategies and resources on performance.
[0091] S52. Construct a closed-loop optimization objective function to minimize the weighted combination of accuracy loss and delay;
[0092] The goal of closed-loop optimization is to minimize the weighted combination of inference latency and accuracy loss, resulting in the closed-loop optimization loss function:
[0093] (9)
[0094] in The weights of each indicator can be dynamically adjusted according to the specific application scenarios in personalized customized production.
[0095] S53. Dynamically adjust the compression ratio and update the compression parameters through gradient descent or strategy search.
[0096] Let the current compression ratio be Closed-loop optimization updates the compression ratio through gradient descent or policy search, yielding the compression ratio update strategy:
[0097] (10)
[0098] in, For learning rate, It reflects the sensitivity of compression ratio changes to latency, accuracy, and resource consumption.
[0099] S54. Adjust the compression strategy in real time based on feedback indicators to form adaptive closed-loop control.
[0100] Closed-loop optimization corrects the strategy by feeding back real-time metrics; that is, the closed-loop feedback strategy update model is as follows:
[0101] (11)
[0102] (12)
[0103] in, It is based on monitoring indicators Personalized customization production task constraints and edge node resources Generate a mapping function for policy adjustment amounts.
[0104] Through continuous iteration and updates and Edge computing systems in personalized production environments can achieve adaptive compression during inference, thereby achieving a balance between latency, accuracy, and resource consumption.
[0105] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0106] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0107] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0108] Specific embodiments have been used to illustrate the principles and implementation methods of this invention. The descriptions of the embodiments above are only for the purpose of helping to understand the method and core ideas of this invention. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this invention. Therefore, the content of this specification should not be construed as a limitation of this invention.
[0109] Those skilled in the art will recognize that the embodiments described herein are intended to help the reader understand the principles of the invention, and should be understood that the scope of protection of the invention is not limited to such specific statements and embodiments. Those skilled in the art can make various other specific modifications and combinations based on the technical teachings disclosed in this invention without departing from the spirit of the invention, and these modifications and combinations are still within the scope of protection of this invention.
Claims
1. An adaptive compression method for lightweight AI models at edge nodes for customized production, characterized in that, Includes the following steps: S1. Based on the personalized production task requirements, extract and analyze the constraints of AI model deployment at edge nodes, including prediction accuracy, inference latency, and energy consumption indicators. S2. Obtain hardware resource information of edge nodes, including processor performance, storage capacity, memory size and network bandwidth; S3. Based on a multi-strategy compressed candidate pool, at least one compression method among pruning, quantization, low-rank decomposition and knowledge distillation is integrated to form a candidate strategy set. S4. Through the adaptive compression decision engine, the optimal compression strategy is dynamically selected or combined based on task constraints and hardware resources to generate an adapted model compression scheme. S5. During model deployment, the compression strategy is dynamically adjusted based on real-time performance to form an iterative optimization mechanism that balances accuracy, latency, and resource consumption.
2. The adaptive compression method for lightweight AI models at edge nodes for customized production according to claim 1, characterized in that, The specific method for analyzing the personalized customization production task requirements in S1 is as follows: Based on the target type and performance requirements of the customized production task, the prediction accuracy threshold, maximum allowable inference latency, and energy consumption limit of the quantified model are mapped to a measurable constraint vector.
3. The adaptive compression method for lightweight AI models at edge nodes for customized production according to claim 1, characterized in that, The specific method for edge node resource awareness in S2 is as follows: The system interface collects real-time data on CPU / GPU computing power, memory capacity, storage space, and network bandwidth of edge nodes, and normalizes it into a unified resource description vector.
4. The adaptive compression method for lightweight AI models at edge nodes for customized production according to claim 1, characterized in that, The construction method of the multi-strategy compression candidate pool in S3 is as follows: The predefined pruning strategies include structured pruning based on channel sparsity, the quantization strategies include 8-bit fixed-point weights and activation compression, the knowledge distillation strategy uses a lightweight teacher model to transfer knowledge, and the low-rank decomposition strategy performs dimensionality reduction on the weight matrix.
5. The adaptive compression method for lightweight AI models at edge nodes for customized production according to claim 1, characterized in that, The adaptive compression decision engine in S4 operates as follows: S41. Represent the compression strategy as a hyperparameter configuration vector and construct the decision space; S42. Design a performance scoring model that integrates accuracy, latency, memory usage, and energy consumption indicators, and calculates the strategy score using a weighted function. S43. Integrating reinforcement learning and Bayesian optimization, the optimal policy is dynamically selected by fitting Markov decision processes and Gaussian processes.
6. The adaptive compression method for lightweight AI models at edge nodes for customized production according to claim 5, characterized in that, The specific calculation method of the performance scoring model in S42 is as follows: ; In the formula, Let be the performance scoring function, s be the compression strategy combination vector, T be the production task constraints, and H be the edge node resources. To improve the accuracy of the compressed model, For reasoning delay, For memory usage, These are the corresponding weighting coefficients.
7. The adaptive compression method for lightweight AI models at edge nodes for customized production according to claim 5, characterized in that, The collaborative approach of reinforcement learning and Bayesian optimization in S43 is as follows: In the offline phase, Bayesian optimization is used to quickly explore the candidate policy space, and in the deployment phase, reinforcement learning is used to dynamically schedule policies based on real-time feedback to balance exploration and utilization.
8. The adaptive compression method for lightweight AI models at edge nodes for customized production according to claim 1, characterized in that, The specific method of the iterative optimization mechanism in S5 is as follows: S51. Real-time monitoring of model inference time, accuracy loss, memory usage, and energy consumption. S52. Construct a closed-loop optimization objective function to minimize the weighted combination of accuracy loss and delay; S53. Dynamically adjust the compression ratio and update the compression parameters through gradient descent or strategy search. S54. Adjust the compression strategy in real time based on feedback indicators to form adaptive closed-loop control.
9. The adaptive compression method for lightweight AI models at edge nodes for customized production according to claim 8, characterized in that, The dynamic adjustment strategy for the compression ratio in S53 is as follows: ; In the formula, For learning rate, The current compression ratio, This is the compression ratio for the next adjustment. This is the closed-loop loss function.
Citation Information
Cited By
Model compression acceleration method for edge computing in unstable network environment
CN122114019A
An edge computing model compression acceleration method in an unstable network environment
CN122114019B
Lightweight AI annotation model deployment optimization method for low-computing-power terminal
CN122261852A
Quantitative perception training and dynamic updating method and system for cloud edge collaborative model
CN122340051A