Intelligent prediction method for hardware resource layout in cloud and data integration
By implementing data integration and preprocessing, time series analysis and resource elastic management, regression analysis and machine learning technology, cost optimization strategies and compliance inspection in the cloud-number integrated environment, the problems of unbalanced resource utilization, opacity of cost management and compliance challenges in the cloud-number integrated environment are solved, and resource utilization and cost-effective optimization are achieved.
Patent Information
- Application Number
- CN202411796799.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-09
- Publication Date
- 2025-05-02
AI Technical Summary
In the prior art, Cloud Digital Integration faces problems such as unbalanced resource utilization, opaque cost management, compliance and security challenges, and lack of continuous optimization mechanisms.
Using data integration and preprocessing solutions, data integration and cleaning across data sources is achieved through cloud service synchronization tools, and features related to resource use are extracted. Combining time series analysis and resource elastic management, dynamically adjust resources to improve utilization. Multivariate analysis using regression analysis and machine learning techniques, optimize cost management, and ensure long-term effectiveness of the model through compliance checks and feedback loops.
Improve resource utilization, optimize the cost-effectiveness of cloud resources, reduce compliance risks, and ensure long-term effectiveness and optimal performance of the prediction model through continuous monitoring and optimization mechanisms.
Smart Images

Figure CN119918019A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to an intelligent prediction method for hardware resource layout in cloud-data integration. Background Art
[0002] In the existing technology, cloud-data integration uses the capabilities of cloud computing infrastructure as a service (IaaS), platform as a service (PaaS) and software as a service (SaaS), combined with big data storage, processing and analysis technologies, to provide users with an integrated and scalable data processing and analysis environment;
[0003] Since data and computing resources are concentrated in the cloud, if the cloud service provider's security measures are not sound enough, the risk of data leakage and privacy violation may increase; especially when sensitive data is involved, cloud-data integration may face complex legal and regulatory compliance challenges; cloud-data integration services rely on stable network connections, and network instability or delays may cause service interruptions or performance degradation; large-scale data transmission may require higher bandwidth, and bandwidth limitations will affect the efficiency of data processing;
[0004] The above content has the following disadvantages:
[0005] Traditional resource management methods are unable to adapt to dynamically changing loads, resulting in uneven resource utilization and the risk of resource waste or service interruption. Resource usage is affected by multiple variables, and traditional analysis methods find it difficult to accurately identify and predict these complex relationships. Cloud resource cost management lacks transparency, making it difficult to optimize resource procurement and usage strategies. Resource prediction and adjustment in a cloud-data integrated environment must meet strict compliance and security requirements. Existing technologies lack an effective continuous optimization mechanism, which may cause the prediction model to become invalid over time.
[0006] The present invention proposes a solution to the above-mentioned disadvantages as follows:
[0007] In order to solve the problem of data islands in existing technologies, a data integration and preprocessing solution is adopted. The cloud service synchronization tool is used to achieve data integration across data sources. The big data processing framework is used to clean data and extract features related to resource usage to ensure unified data management and analysis quality. To solve the problem of uneven resource utilization, time series analysis and resource elasticity management are implemented. Resource usage data is collected through real-time monitoring tools, and resources are dynamically adjusted based on prediction results to effectively improve resource utilization. In the face of the complexity of multivariate influences, regression analysis and machine learning techniques are used to accurately identify and predict complex relationships in resource usage through multivariate analysis and distributed training. In response to the challenge of opaque cost management, a cost optimization strategy is introduced. Cloud service cost management tools are used for monitoring and analysis, and resource elasticity management is combined to automatically adjust the size of the resource pool to optimize cost-effectiveness. To overcome compliance and security challenges, compliance checks are strictly performed to ensure that the resource prediction and adjustment process meets the security and compliance requirements of cloud service providers. Finally, in order to make up for the lack of a continuous optimization mechanism, a continuous monitoring and optimization mechanism is established. Through feedback loops and A / B testing, the prediction model is continuously optimized to ensure the long-term effectiveness and optimal performance of the model. Summary of the invention
[0008] In order to solve the above-mentioned technical problems, the present invention provides an intelligent prediction method for hardware resource layout in cloud-data integration.
[0009] The technical solution of the present invention is implemented as follows: A method for intelligent prediction of hardware resource layout in cloud-data integration:
[0010] S1. Use cloud service synchronization tools to integrate data across data sources, clean the data through the framework, and then extract features related to resource usage;
[0011] S2. Collect resource usage data in real time through cloud service monitoring tools, and use automatic expansion functions to dynamically adjust resources based on time series prediction results;
[0012] S3, multivariate analysis uses regression analysis and leverages the distributed computing power of cloud services for large-scale machine training;
[0013] S4. Use cloud service cost management tools to monitor and analyze costs, and use automatic adjustment of resource pool size for resource elasticity management;
[0014] S5. Ensure that the resource forecasting and adjustment process complies with the security and compliance requirements of the cloud service provider to reduce compliance risks;
[0015] S6. Establish a feedback loop and compare the performance of different models through A / B testing to continuously select the optimal model.
[0016] Furthermore, the data integration and preprocessing in step S1:
[0017] Data synchronization uses the automated data movement and conversion capabilities of AWS Data Pipeline, combined with the complex data stream processing capabilities of Azure Data Factory, for data synchronization across cloud platforms. By configuring data pipelines, defining data stream mappings, and setting scheduled tasks, data can be synchronized to the central database in real time or periodically.
[0018] Data cleaning uses Apache Spark's DataFrame API for distributed data processing, combined with HadoopYARN for resource management, and writes Spark cleaning scripts to perform data quality checks to remove duplicate, abnormal, and data that does not comply with business rules.
[0019] Furthermore, the time series analysis and resource elasticity management in step S2:
[0020] Real-time monitoring uses Prometheus and Grafana for system monitoring and data visualization. By deploying monitoring agents and configuring alarm rules, resource usage indicators are collected in real time.
[0021] Resource elasticity management uses AWS Auto Scaling and Azure Virtual Machine Scale Sets to automatically adjust resources and dynamically increase or decrease virtual machine instances based on prediction results by setting elasticity policies.
[0022] Furthermore, the multivariate analysis of regression analysis and machine learning in step S3 uses multivariate regression and random forest to model the relationship between variables, through data preprocessing, feature selection, model training, and cross validation;
[0023] Distributed training uses Apache Spark MLlib for large-scale data processing and model training. It configures a Spark cluster, loads training data, and executes distributed training tasks.
[0024] Furthermore, the cost monitoring and analysis in the cost optimization strategy in step S4 uses AWS CostExplorer and Azure Cost Management to perform cost monitoring and analysis, and analyzes cost trends and identifies cost optimization opportunities by setting up a cost monitoring dashboard;
[0025] Resource elasticity management uses cloud service APIs to automate resource adjustments by writing automated scripts to adjust resource pools based on cost and performance indicators.
[0026] Furthermore, the compliance check in step S5 uses the cloud service provider's security compliance tools, including AWSConfig and Azure Policy, to configure compliance rules and regularly audit resource configuration to ensure compliance with regulatory requirements.
[0027] Furthermore, the feedback loop in step S6 utilizes a closed-loop control system in combination with a machine learning algorithm to adjust model parameters by collecting actual resource usage data and comparing it with the output of the prediction model;
[0028] A / B testing uses experimental design platforms, including Optimizely or Google Optimize, to set up experimental groups and control groups to test the performance of different prediction models and select the optimal model.
[0029] Beneficial Effects
[0030] Data integration and preprocessing uses cloud service synchronization tools (AWS Data Pipeline and Azure DataFactory) to synchronize data scattered in different data sources into a central data warehouse. Subsequently, a big data processing framework (Apache Spark) is used to clean the data, remove invalid and erroneous data, and extract features related to resource usage.
[0031] Real-time monitoring and resource elasticity management collects resource usage data in real time through cloud service monitoring tools (Prometheus and Grafana), predicts resource demand based on time series analysis, and then uses automatic expansion functions (AWS AutoScaling and Azure Virtual Machine Scale Sets) to dynamically adjust resources to meet the predicted demand;
[0032] Multivariate analysis and machine learning use regression analysis and machine learning techniques (multivariate linear regression and random forest) to analyze multiple variables and perform distributed training through Apache Spark MLlib to build a more accurate resource usage prediction model;
[0033] Cost monitoring and optimization Use cloud service cost management tools (AWS Cost Explorer and Azure Cost Management) to monitor and analyze costs, and automatically adjust resource pool sizes in combination with resource elasticity management to optimize cost effectiveness;
[0034] Compliance check: Perform compliance checks through the cloud service provider's security compliance tools (AWS Config and Azure Policy) to ensure that the resource forecasting and adjustment process complies with relevant laws, regulations and security requirements;
[0035] Continuous monitoring and optimization establish a feedback loop, continuously adjust and optimize the prediction model by comparing actual resource usage with the predicted results. At the same time, conduct A / B testing to compare the performance of different models and select the optimal model to achieve continuous optimization.
[0036] Working principle:
[0037] First, cloud service synchronization tools such as AWS Data Pipeline and Azure Data Factory are used to integrate data from different data sources into a central data warehouse, and data cleaning and feature extraction are performed through big data processing frameworks such as Apache Spark. Next, resource usage data is collected through real-time monitoring tools such as Prometheus and Grafana, and time series analysis and automatic expansion functions such as AWS Auto Scaling and Azure Virtual Machine Scale Sets are used to dynamically adjust resources. In this process, regression analysis and machine learning techniques such as multivariate linear regression and random forests are applied to multivariate analysis to improve prediction accuracy. At the same time, cloud service cost management tools such as AWS Cost Explorer and Azure Cost Management are used to monitor and analyze costs, and optimize cost-effectiveness in combination with resource elasticity management. In addition, compliance checks ensure that resource management complies with laws and regulations through tools such as AWS Config and Azure Policy. Finally, a feedback loop and A / B testing mechanism are established to achieve continuous optimization of the prediction model by comparing actual resource usage with prediction results and testing the performance of different models, thereby ensuring the long-term effectiveness and optimal performance of the entire system. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] Figure 1 It is a structural block diagram of a method for intelligent prediction of hardware resource layout in cloud-data integration in an embodiment of the present invention;
[0039] Figure 2 This is a flowchart of a method for intelligently predicting hardware resource layout in cloud-data integration according to an embodiment of the present invention. DETAILED DESCRIPTION
[0040] In order to make the objects and advantages of the present invention more clearly understood, the present invention is further described below in conjunction with embodiments; it should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0041] The preferred implementation methods of the present invention are described below with reference to the accompanying drawings. It should be understood by those skilled in the art that these implementation methods are only used to explain the technical principles of the present invention and are not intended to limit the protection scope of the present invention.
[0042] It should be noted that when an element is considered to be "connected" to another element, it can be directly connected to the other element, or connected to the other element through an intermediate element. In addition, the "connection" in the following embodiments should be understood as "electrical connection", "communication connection", etc. if there is transmission of electrical signals or data between the connected objects.
[0043] When used herein, the singular forms "a", "an", and "said / the" may also include plural forms, unless the context clearly indicates otherwise. It should also be understood that the terms "include / comprise" or "have" and the like specify the presence of stated features, wholes, steps, operations, components, parts, or combinations thereof, but do not exclude the possibility of the presence or addition of one or more other features, wholes, steps, operations, components, parts, or combinations thereof. At the same time, the term "and / or" used in this specification includes any and all combinations of the relevant listed items.
[0044] See also Figure 1-Figure 2 As shown, a method for intelligently predicting hardware resource layout in cloud-data integration includes:
[0045] S1. Use cloud service synchronization tools to integrate data across data sources, clean the data through the framework, and then extract features related to resource usage;
[0046] S2. Collect resource usage data in real time through cloud service monitoring tools, and use automatic expansion functions to dynamically adjust resources based on time series prediction results;
[0047] S3, multivariate analysis uses regression analysis and leverages the distributed computing power of cloud services for large-scale machine training;
[0048] S4. Use cloud service cost management tools to monitor and analyze costs, and use automatic adjustment of resource pool size for resource elasticity management;
[0049] S5. Ensure that the resource forecasting and adjustment process complies with the security and compliance requirements of the cloud service provider to reduce compliance risks;
[0050] S6. Establish a feedback loop and compare the performance of different models through A / B testing to continuously select the optimal model.
[0051] Furthermore, the data integration and preprocessing in step S1:
[0052] Data synchronization uses the automated data movement and transformation capabilities of AWS Data Pipeline, combined with the complex data flow processing capabilities of Azure Data Factory, for data synchronization across cloud platforms. By configuring data pipelines, defining data flow mappings, and setting scheduled tasks, data can be synchronized to the central database in real time or periodically.
[0053] Data cleaning uses Apache Spark's DataFrame API for distributed data processing, combined with HadoopYARN for resource management, and writes Spark cleaning scripts to perform data quality checks to remove duplicate, abnormal, and data that does not comply with business rules.
[0054] Specifically, the computing objectives in the data synchronization verification are: verifying whether AWS Data Pipeline and Azure DataFactory can synchronize data according to the configured data pipeline and schedule;
[0055] Network transmission efficiency calculation:
[0056] The average data size of each data source is preset to be Davg = 1GB, the number of data sources N = 100, the synchronization period Tsync is 1 hour, that is, Tsync = 3600 seconds, and the data transmission efficiency Rtrans needs to meet
[0057] Network bandwidth requirements:
[0058] The predetermined data compression ratio is Cratio, then the actual required bandwidth is
[0059] If Cratio=0.5, then
[0060] Parallel synchronous task calculation in data pipeline performance optimization:
[0061] The processing time of each synchronization task is preset to Ttask. The maximum number of tasks that the cluster can process in parallel is M. In order to complete all tasks within one hour, M×T must be met. task ≤T sync ;
[0062] Resource allocation optimization calculation:
[0063] Use queuing theory (M / M / 1 or M / M / C model) to simulate the task queue of the data pipeline, calculate the average waiting time W and the average response time R, and minimize W+R by adjusting M and Ttask;
[0064] Calculation of data cleaning verification:
[0065] Spark cluster resource management calculation, presetting each node memory Mnode = 32GB, node number Nnode = 10; the memory multiple required for DataFrame operation is Fmemory, then the total memory requirement Mtotal = Nnode × Mnode × Mnode × Fmemory;
[0066] Task parallelism calculation:
[0067] The preset number of data shards is S, and the processing time of each shard is Tslice; the total processing time Ttotal = S × Tslice; by adjusting S to optimize the CPU utilization of the cluster, while ensuring that S ≤ Nnode ≤ cores per node;
[0068] Complexity analysis in data cleaning efficiency optimization:
[0069] Perform algorithmic complexity analysis on the data cleaning script to determine the time complexity 0 and space complexity SK; estimate the processing time Tprocess = O(D) under different data volumes;
[0070] Performance Tuning
[0071] Use Spark's Tungsten execution engine to optimize memory management and execution plans; improve performance by adjusting serialization / deserialization formats, memory allocation strategies (such as storage vs. execution memory), and data partitioning strategies;
[0072] The calculation formulas and their physical meanings involved in the above content are as follows:
[0073] Data transfer rate calculation:
[0074] Davg: average data size of each data source, in gigabytes (GB);
[0075] N: the number of data sources;
[0076] Tsync: synchronization period, in seconds (s);
[0077] Rtrans: data transmission rate in bits per second (bps);
[0078] Network bandwidth requirements:
[0079] Cratio: data compression ratio, unitless, indicating the ratio of the compressed data size to the original data size;
[0080] Breq: actual required network bandwidth, in megabits per second (Mbps);
[0081] Parallel synchronous task calculation:
[0082] Ttask: the processing time of each synchronization task, in seconds (s);
[0083] M: the maximum number of tasks that the cluster can process in parallel;
[0084] Resource allocation optimization:
[0085] W: average waiting time, in seconds (s);
[0086] R: average response time, in seconds (s);
[0087] Memory requirement calculation:
[0088] Mnode: The memory size of each node, in gigabytes (GB);
[0089] Nnode: number of nodes;
[0090] Fmemory: The memory multiple required for DataFrame operations, unitless;
[0091] Mtotal: total memory requirement in gigabytes (GB);
[0092] Task parallelism calculation:
[0093] S: number of data shards;
[0094] Tslice: processing time of each slice, in seconds (s);
[0095] Ttotal: total processing time, in seconds (s);
[0096] Complexity analysis:
[0097] O: The time complexity of the algorithm, usually expressed as O(f(D)), where D is the amount of data;
[0098] SK: The space complexity of an algorithm, which is a measure of the storage space required during the execution of the algorithm;
[0099] Tprocess: processing time, in seconds (s).
[0100] Furthermore, the time series analysis and resource elasticity management in step S2:
[0101] Real-time monitoring uses Prometheus and Grafana for system monitoring and data visualization. By deploying monitoring agents and configuring alarm rules, resource usage indicators are collected in real time.
[0102] Resource elasticity management uses AWS Auto Scaling and Azure Virtual Machine Scale Sets to automatically adjust resources and dynamically increase or decrease virtual machine instances based on prediction results by setting elasticity policies.
[0103] Specifically, the time series and resource elasticity management in step S2 are:
[0104] The computing goal of real-time monitoring verification is to verify whether the monitoring system can respond to changes in resource usage in a timely manner under the set alarm rules;
[0105] Calculation steps: Set alarm thresholds, preset CPU usage thresholds to 70%, and memory usage thresholds to 80%; Monitoring data collection frequency: Preset Prometheus to collect data every 5 minutes, Tcollect = 5 minutes; Alarm response time is calculated as follows: After the preset resource usage exceeds the threshold, the monitoring system should trigger an alarm within 1 minute, Talert = 1 minute; Verify alarm rules: If the resource usage exceeds the threshold, the monitoring system should trigger an alarm within Tcollect + Talert, Tresponse = Tcollect + Talert = 5 + 1 = 6 minutes;
[0106] Compute objectives for resource elasticity management verification: Verify that AWS Auto Scaling and Azure VirtualMachine Scale Sets can dynamically adjust resources according to the set elasticity policies;
[0107] Calculation steps: Define elasticity policies. If the CPU usage exceeds 70%, automatically add a virtual machine instance. If the CPU usage is less than 30%, automatically reduce a virtual machine instance.
[0108] The current resource usage is 10 virtual machine instances, and the CPU usage of each instance is 60%;
[0109] The resource demand forecast is that the preset time series analysis predicts that the CPU usage will rise to 80% in the next hour, Pforecast = 80%;
[0110] Calculate the number of required instances: According to the forecast, the maximum CPU usage of each instance is 70%, so the current resources are insufficient to meet the forecast demand. The number of instances that need to be added, Ninstance_add, is calculated using the following formula:
[0111]
[0112] Wherein, Ncurrent_instances = 10, CPUthreshold = 70%;
[0113]
[0114] Verify elastic adjustment. According to calculations, two virtual machine instances should be automatically added to cope with the predicted resource demand.
[0115] The meaning of the physical characters in the above calculation formula is:
[0116] Ninstance_add: the number of virtual machine instances that need to be added;
[0117] Pforecast: indicates the predicted resource usage or load;
[0118] Ncurrent_instances: the number of currently running virtual machine instances;
[0119] CPUthreshold: The alarm threshold of CPU usage, expressed as a percentage (%);
[0120] Ncurrent_instances: The number of currently running virtual machine instances.
[0121] Furthermore, the multivariate analysis of regression analysis and machine learning in step S3 uses multivariate regression and random forest to model the relationship between variables, through data preprocessing, feature selection, model training, and cross validation;
[0122] Distributed training uses Apache Spark MLlib for large-scale data processing and model training. It configures a Spark cluster, loads training data, and executes distributed training tasks.
[0123] Specifically, the multivariate analysis and distributed training in step S3 are:
[0124] In multivariate analysis, data preprocessing, feature selection, model training, and cross validation are performed. Data preprocessing uses standardization to scale feature X to a range, using zScore standardization or minimum-maximum standardization; standardization formula:
[0125]
[0126] Among them, X is the original feature, μ is the mean of the feature, and σ is the standard deviation of the feature;
[0127] Correlation analysis in feature selection calculates the correlation coefficient r between feature Xi and target variable Y; correlation coefficient formula:
[0128]
[0129] Where N is the number of samples, X i,n is the ith eigenvalue of the nth sample, is the mean of the ith feature, Y n is the target variable value of the nth sample, is the mean of the target variable;
[0130] In model training, multivariate linear regression uses the least squares method to estimate the regression coefficient. The regression coefficient formula is: β = (X T X) -1 X T Y; where X is the standardized feature matrix, Y is the target variable vector, and β is the regression coefficient vector;
[0131] Random forest builds multiple decision trees and predicts the results by voting or averaging, which can be represented by the following steps:
[0132] 1. Randomly extract samples with replacement from the original data set to form multiple subsets;
[0133] 2. Train a decision tree for each subset separately, and randomly select a feature subset for segmentation at each node;
[0134] 3. Combine the prediction results of all decision trees;
[0135] In cross-validation, K-fold cross-validation divides the data set into K subsets, and takes each subset as a validation set in turn, and the rest as a training set. The validation process is formalized as follows:
[0136]
[0137] Among them, Test ErrorkTest Errork is the error of the k-th fold verification;
[0138] Distributed training focuses on how to distribute data to multiple nodes for parallel processing, expressed as:
[0139] 1. Data partitioning: divide the data set D into M partitions D1, D2, ..., D M ;
[0140] 2. Parallel processing, performing model training independently on each partition;
[0141] 3. Model merging: merging the model results of all partitions to form the final model;
[0142] Steps S1-S2 provide the data basis, monitoring parameters, preliminary analysis results and system requirements for step S3, which are prerequisites for implementing data analysis, model training and verification in step S3.
[0143] Furthermore, the cost monitoring and analysis in the cost optimization strategy in step S4 uses AWS CostExplorer and Azure Cost Management to perform cost monitoring and analysis, and analyzes cost trends and identifies cost optimization opportunities by setting up a cost monitoring dashboard;
[0144] Resource elasticity management uses cloud service APIs to automate resource adjustments by writing automated scripts to adjust resource pools based on cost and performance indicators.
[0145] Specifically, the cost monitoring analysis and resource elasticity management in step S4 are as follows:
[0146] In the cost monitoring and analysis, the total cost calculation assumes that there are n services, and the cost of each service is C1, C2, ..., Cn. The total cost C_total is expressed as:
[0147]
[0148] Cost change rate calculation, assuming that the cost of the current cycle is C_current and the cost of the previous cycle is C_previous, then the cost change rate R_cost is:
[0149]
[0150] Cost efficiency analysis,For each service Si, its cost efficiency Ei is expressed as the ratio of cost Ci to service performance index Pi:
[0151]
[0152] If Ei exceeds a certain efficiency threshold E_threshold, the service is a candidate for cost optimization:
[0153] E i >E threshold
[0154] In resource elasticity management, the resource adjustment decision is assumed to be C_vm, and the performance index is P_vm. Then the resource adjustment factor AF is:
[0155]
[0156] If AF is greater than the high threshold AF_high, resources need to be reduced;
[0157] If AF is less than the low threshold AF_low, resources need to be increased;
[0158] Calculation of resource adjustment amount, assuming that the current resource amount is R_current and the adjustment coefficient is α (α<1 when reducing resources, α>1 when increasing resources), then the new resource amount R_new is:
[0159] R new =R current ×α
[0160] Cost monitoring and analysis and resource elasticity management in step S4 verify calculations that help determine when and how to adjust resources to optimize cost and performance;
[0161] The physical meanings of the characters in the above calculation formula are:
[0162] C i : represents the cost of the i-th service;
[0163] C total : represents the total cost of all services;
[0164] n: indicates the total number of services;
[0165] C current : Indicates the cost of the current cycle;
[0166] C previous : represents the cost of the previous cycle;
[0167] R cost : It indicates the rate of change of cost, that is, the percentage change of cost over time;
[0168] E i : represents the cost efficiency of the i-th service, that is, the ratio of cost to performance index;
[0169] P i : represents the performance indicator of the i-th service;
[0170] E threshold : represents the threshold of cost efficiency, which is used to determine whether the service needs to be optimized;
[0171] C vm : represents the cost of a virtual machine (or other resource);
[0172] P vm : Indicates the performance indicators of the virtual machine;
[0173] AF: stands for resource adjustment factor, which is the ratio of cost to performance index and is used to decide whether to adjust resources;
[0174] AF high : Indicates the high threshold of the resource adjustment factor. When this value is exceeded, resources need to be reduced;
[0175] AFlow : Indicates the lower threshold of the resource adjustment factor. When the value is lower than this, additional resources are required.
[0176] R current : Indicates the current amount of resources;
[0177] α: represents the resource adjustment coefficient, which is used to calculate the new resource amount. Its value depends on whether the resource needs to be increased or decreased.
[0178] R new : Indicates the new resource volume after adjustment;
[0179] The above characters represent different physical quantities involved in the cost monitoring and analysis and resource elasticity management processes, through which the use and cost of cloud resources are quantified and managed.
[0180] Furthermore, the compliance check in step S5 uses the cloud service provider's security compliance tools, including AWSConfig and Azure Policy, to configure compliance rules and regularly audit resource configuration to ensure compliance with regulatory requirements.
[0181] Specifically, the S5 step configures compliance rules and regularly audits resource configuration:
[0182] Single compliance rule evaluation for compliance checking, for each compliance rule G j , define an evaluation function F j (R), where R represents resource allocation, F j The result of (R) is a Boolean value represented by:
[0183]
[0184] Among them, F j The value of (R) is binary, 1 indicates compliance and 0 indicates noncompliance;
[0185] The total compliance score calculation is based on m compliance rules. The total compliance score Scompliance is calculated using the following formula:
[0186]
[0187] The value of Scompliance ranges from 0 to m, where 0 indicates complete noncompliance and m indicates complete compliance;
[0188] Compliance check, for each resource configuration Ri, its compliance needs to be checked:
[0189]
[0190] Among them, C iIs a Boolean value indicating the resource configuration R i Is it fully compliant? If all F j (R i ) are all 1, then C i =1, indicating compliance; if any F j (R i ) is 0, then C i =0, indicating non-compliance;
[0191] Statistics of non-compliant resource configurations. The number of non-compliant resource configurations N non-compliant is calculated using the following formula:
[0192]
[0193] Where n is the total number of all resource configurations, 1-C i It means that if C i =0 (non-compliant), then the count increases by 1;
[0194] The above content verifies the compliance check in step S5. These calculations help determine whether the resource configuration complies with all compliance rules and count the number of non-compliant resource configurations.
[0195] The meaning of the physical characters in the calculation formula in the above content is:
[0196] F j (R): represents the evaluation function for the jth compliance rule, whose input is the resource configuration R, and the output is a Boolean value indicating whether the configuration satisfies the jth rule;
[0197] G j : represents the jth compliance rule;
[0198] R: indicates resource configuration, including the settings of various hardware, software or other resources;
[0199] m: indicates the total number of compliance rules;
[0200] S compliance : represents the total compliance score, which is the cumulative sum of all compliance rule evaluation results and is used to measure the overall compliance level;
[0201] C i : Indicates the compliance status of the i-th resource configuration, which is a Boolean value, where i represents a different resource configuration;
[0202] n: indicates the total number of resource configurations to be checked;
[0203] N non-compliant : Indicates the number of non-compliant resource configurations, which is the count of all non-compliant configurations.
[0204] Furthermore, the feedback loop in step S6 utilizes a closed-loop control system in combination with a machine learning algorithm to adjust model parameters by collecting actual resource usage data and comparing it with the output of the prediction model;
[0205] A / B testing uses experimental design platforms, including Optimizely or Google Optimize, to set up experimental groups and control groups to test the performance of different prediction models and select the optimal model.
[0206] Specifically, the closed-loop control system and A / B testing in step S6 are used to optimize the prediction model:
[0207] For feedback loop and model adjustment, a prediction model M(x;θ) is preset, where x is the input data and θ is the model parameter; the actual resource usage data is Y and the prediction model output is The error E is expressed as the difference between the actual data and the predicted data:
[0208]
[0209] By minimizing the error E, the model parameters θ are adjusted using an optimization algorithm such as gradient descent:
[0210]
[0211] Among them, α is the learning rate, is the gradient of the error with respect to the model parameters;
[0212] A / B testing and model selection, two preset models M A and M B , suppose experimental group A uses model M A , control group B used model M B ; Collect performance metrics for both groups, including mean squared error (MSE):
[0213]
[0214] Among them, n A and n B are the number of data points in the experimental group and the control group, respectively, and Y i is the actual value, and is the predicted value;
[0215] Select the better performing model, i.e. the model with smaller MSE:
[0216] If MSE A <MSE B , then select M A ; Otherwise select MB ;
[0217] The meanings of the physical characters in the calculation formulas in the above content are as follows:
[0218] M(x;θ): represents the prediction model, where x is the input data of the model and θ is the parameter of the model;
[0219] Y: represents the actual resource usage data, i.e., the observed value or true value;
[0220] Represents the output of the prediction model M, that is, the predicted value;
[0221] E: represents the prediction error, that is, the difference between the actual data Y and the predicted data The difference between
[0222] θ new : represents the adjusted model parameters;
[0223] α: represents the learning rate, which is used to control the step size of model parameter update;
[0224] Represents the gradient of the error E with respect to the model parameter θ;
[0225] MSE A and MSE B : Represents the mean square error of the experimental group A and the control group B, respectively, used to evaluate the performance of the model;
[0226] n A and n B : Represents the number of data points in the experimental group A and the control group B respectively;
[0227] Y i : represents the actual value of the i-th data point;
[0228] and Represent the predicted values of experimental group A and control group B respectively;
[0229] Through the above content, it is verified that the feedback loop in step S6 utilizes the closed-loop control system and the A / B testing process to optimize and select the optimal prediction model.
[0230] So far, the technical solutions of the present invention have been described in conjunction with the preferred embodiments shown in the accompanying drawings. However, it is easy for those skilled in the art to understand that the protection scope of the present invention is obviously not limited to these specific embodiments. Without departing from the principle of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after these changes or substitutions will fall within the protection scope of the present invention.
[0231] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and rules of the present invention shall be included in the protection scope of the present invention.
Claims
1. A method for intelligent prediction of hardware resource layout in cloud-data integration, characterized by: S1. Use cloud service synchronization tools to integrate data across data sources, clean the data through the framework, and then extract features related to resource usage; S2. Collect resource usage data in real time through cloud service monitoring tools, and use automatic expansion functions to dynamically adjust resources based on time series prediction results; S3, multivariate analysis uses regression analysis and uses the distributed computing power of cloud services for machine training; S4. Use cloud service cost management tools to monitor and analyze costs, and use automatic adjustment of resource pool size for resource elasticity management; S5. Ensure that the resource forecasting and adjustment process complies with the security and compliance requirements of the cloud service provider; S6. Establish a feedback loop and compare the performance of different models through A / B testing to continuously select the optimal model.
2. According to claim 1, a method for intelligent prediction of hardware resource layout in cloud-data integration is characterized by: The calculation target in the data synchronization verification in the S1 step is to verify whether AWS Data Pipeline and Azure Data Factory can synchronize data according to the configured data pipeline and schedule; The data transmission efficiency Rtrans needs to meet Actual bandwidth required The maximum number of tasks that the cluster can process in parallel is M, which needs to satisfy M×T task ≤T sync ; Resource allocation optimization calculation uses queuing theory to minimize W+R by adjusting M and Ttask; Spark cluster resource management calculation; The memory multiple required for DataFrame operation is Fmemory, then the total memory requirement Mtotal=Nnode×Mnode×Mnode×Fmemory; Task parallelism calculates the total processing time Ttotal=S×Tslice; Optimize the CPU utilization of the cluster by adjusting S, while ensuring S≤Nnode≤cores per node; Complexity analysis in data cleaning efficiency optimization, estimate the processing time Tprocess=O(D) under different data volumes; Performance tuning uses Spark's Tungsten execution engine to optimize memory management and execution plans; Data transfer rate calculation: Davg: average data size of each data source, in gigabytes (GB); N: the number of data sources; Tsync: synchronization period, in seconds (s); Rtrans: data transmission rate in bits per second (bps); Network bandwidth requirements: Cratio: data compression ratio, unitless, indicating the ratio of the compressed data size to the original data size; Breq: actual required network bandwidth, in megabits per second (Mbps); Parallel synchronous task calculation: Ttask: the processing time of each synchronization task, in seconds (s); M: the maximum number of tasks that the cluster can process in parallel; Resource allocation optimization: W: average waiting time, in seconds (s); R: average response time, in seconds (s); Memory requirement calculation: Mnode: The memory size of each node, in gigabytes (GB); Nnode: number of nodes; Fmemory: The memory multiple required for DataFrame operations, unitless; Mtotal: total memory requirement in gigabytes (GB); Task parallelism calculation: S: number of data shards Tslice: processing time of each slice, in seconds (s); Ttotal: total processing time, in seconds (s); Complexity analysis: O: The time complexity of the algorithm, expressed as O(f(D)), where D is the amount of data; SK: The space complexity of an algorithm, which is a measure of the storage space required during the execution of the algorithm; Tprocess: processing time, in seconds (s).
3. According to the method of intelligent prediction of hardware resource layout in cloud-data integration in claim 1, it is characterized by: The S2 step intermediate sequence and resource elasticity management: The computing goal of real-time monitoring verification is to verify whether the monitoring system can respond to changes in resource usage in a timely manner under the set alarm rules; Calculation steps: Set the alarm threshold, preset the CPU usage threshold to 70%, and the memory usage threshold to 80%; Monitoring data collection frequency: Preset Prometheus to collect data every 5 minutes, Tcollect = 5 minutes; The alarm response time is calculated as follows: after the preset resource usage exceeds the threshold, the monitoring system should trigger an alarm within 1 minute, Talert = 1 minute; Verify the alarm rule: if the resource usage exceeds the threshold, the monitoring system triggers an alarm within Tcollect+Talert, Tresponse=Tcollect+Talert=5+1=6 minutes; Compute objectives for resource elasticity management verification: Verify whether AWS Auto Sca l ing and Azure Virtual MachineScale Sets can dynamically adjust resources according to the set elasticity policy; Calculation steps: Define elasticity policies. If the CPU usage exceeds 70%, automatically add a virtual machine instance. If the CPU usage is less than 30%, automatically reduce a virtual machine instance. The current resource usage is 10 virtual machine instances, and the CPU usage of each instance is 60%; The resource demand forecast is that the preset time series analysis predicts that the CPU usage will rise to 80% in the next hour, Pforecast = 80%; Calculate the number of required instances: According to the forecast, the maximum CPU usage of each instance is 70%, so the current resources are insufficient to meet the forecast demand. The number of instances that need to be added, Ninstance_add, is calculated using the following formula: Wherein, Ncurrent_instances = 10, CPUthreshold = 70%; Verify elastic adjustment. According to calculations, two virtual machine instances should be automatically added to cope with the predicted resource demand. The meaning of the physical characters in the above calculation formula is: Ninstance_add: the number of virtual machine instances that need to be added; Pforecast: indicates the predicted resource usage or load; Ncurrent_instances: the number of currently running virtual machine instances; CPUthreshold: The alarm threshold of CPU usage, expressed as a percentage (%); Ncurrent_instances: The number of currently running virtual machine instances.
4. According to the method of intelligent prediction of hardware resource layout in cloud-data integration in claim 1, it is characterized by: The multivariate analysis and distributed training in step S3 are as follows: In multivariate analysis, data preprocessing, feature selection, model training, and cross validation are performed. Data preprocessing uses standardization to scale feature X to a range, using z-score standardization or minimum-maximum standardization; standardization formula: Among them, X is the original feature, μ is the mean of the feature, and σ is the standard deviation of the feature; Correlation analysis in feature selection calculates the correlation coefficient r between feature Xi and target variable Y; correlation coefficient formula: Where N is the number of samples, X i,n is the ith eigenvalue of the nth sample, is the mean of the ith feature, Y n is the target variable value of the nth sample, is the mean of the target variable; In model training, multivariate linear regression uses the least squares method to estimate the regression coefficient. The regression coefficient formula is: β = (X T X) - 1 X T Y; where X is the standardized feature matrix, Y is the target variable vector, and β is the regression coefficient vector.
5. The method for intelligent prediction of hardware resource layout in cloud-data integration according to claim 1, characterized in that: Cost monitoring analysis and resource elasticity management in step S4: In the cost monitoring and analysis, the total cost calculation assumes that there are n services, and the cost of each service is C1, C2, ..., Cn. The total cost C_total is expressed as: Cost change rate calculation, assuming that the cost of the current cycle is C_current and the cost of the previous cycle is C_previous, then the cost change rate R_cost is: Cost efficiency analysis,For each service Si, its cost efficiency Ei is expressed as the ratio of cost Ci to service performance index Pi: If Ei exceeds a certain efficiency threshold E_threshold, the service is a candidate for cost optimization: AND i >And threshold In resource elasticity management, the resource adjustment decision is assumed to be C_vm, and the performance index is P_vm. Then the resource adjustment factor AF is: If AF is greater than the high threshold AF_high, resources need to be reduced; If AF is less than the low threshold AF_low, resources need to be increased; Resource adjustment amount calculation, the current resource amount is preset as R_current, the adjustment coefficient is α (α < 1 when reducing resources, α > 1 when increasing resources), then the new resource amount R_new is R new =R current ×α The physical meanings of the characters in the above calculation formula are: C i : represents the cost of the i-th service; C total : represents the total cost of all services; n: indicates the total number of services; C current : Indicates the cost of the current cycle; C previous : represents the cost of the previous cycle; R cost : It indicates the rate of change of cost, that is, the percentage change of cost over time; E i : represents the cost efficiency of the i-th service, that is, the ratio of cost to performance index; P i : represents the performance indicator of the i-th service; E threshold : represents the threshold of cost efficiency, which is used to determine whether the service needs to be optimized; C vm : represents the cost of the virtual machine; P vm : Indicates the performance indicators of the virtual machine; AF: stands for resource adjustment factor, which is the ratio of cost to performance index and is used to decide whether to adjust resources; AF high : Indicates the high threshold of the resource adjustment factor. When this value is exceeded, resources need to be reduced; AF low : Indicates the lower threshold of the resource adjustment factor. When the value is lower than this, additional resources are required. R current : Indicates the current amount of resources; α: represents the resource adjustment coefficient, which is used to calculate the new resource amount. Its value depends on whether the resource needs to be increased or decreased. R new : Indicates the new resource quantity after adjustment.
6. The method for intelligent prediction of hardware resource layout in cloud-data integration according to claim 1, characterized in that: In step S5, configure compliance rules and regularly audit resource configuration: Single compliance rule evaluation for compliance checking, for each compliance rule G j , define an evaluation function F j (R), where R represents resource allocation, F j The result of (R) is a Boolean value represented by: Among them, F j The value of (R) is binary, 1 indicates compliance and 0 indicates noncompliance; The total compliance score calculation is based on m compliance rules. The total compliance score Scompliance is calculated using the following formula: The value of Scompliance ranges from 0 to m, where 0 indicates complete noncompliance and m indicates complete compliance; Compliance check, for each resource configuration R i , you need to check its compliance: Among them, C i Is a Boolean value indicating the resource configuration R i Is it fully compliant? If all F j (R i ) are all 1, then C i =1, indicating compliance; if any F j (R i ) is 0, then C i =0, indicating non-compliance; Statistics of non-compliant resource configurations. The number of non-compliant resource configurations N non-compliant is calculated using the following formula: Where n is the total number of all resource configurations, 1-C i It means that if C i =0 (non-compliant), then the count increases by 1; Verify the compliance check in step S5 through the above content, calculate and determine whether the resource configuration complies with all compliance rules, and count the number of non-compliant resource configurations; The meaning of the physical characters in the calculation formula in the above content is: F j (R): represents the evaluation function for the jth compliance rule, whose input is the resource configuration R, and the output is a Boolean value indicating whether the configuration satisfies the jth rule; G j : represents the jth compliance rule; R: indicates resource configuration, including the settings of various hardware, software or other resources; m: indicates the total number of compliance rules; S compliance : represents the total compliance score, which is the cumulative sum of all compliance rule evaluation results and is used to measure the overall compliance level; C i : Indicates the compliance status of the i-th resource configuration, which is a Boolean value, where i represents a different resource configuration; n: indicates the total number of resource configurations to be checked; N non-compliant : Indicates the number of non-compliant resource configurations, which is the count of all non-compliant configurations.
7. The method for intelligent prediction of hardware resource layout in cloud-data integration according to claim 1, characterized in that: In step S6, a prediction model M(x;θ) is preset for feedback loop and model adjustment, where x is input data and θ is model parameter; the actual resource usage data is Y and the prediction model output is The error E is expressed as the difference between the actual data and the predicted data: By minimizing the error E, the model parameters θ are adjusted, which is done through the optimization algorithm gradient descent: Among them, α is the learning rate, is the gradient of the error with respect to the model parameters; A / B testing and model selection, two preset models M A and M B , suppose experimental group A uses model M A , control group B used model M B ; Collect performance metrics for both groups, including mean squared error (MSE): Among them, n A and n B are the number of data points in the experimental group and the control group, respectively, and Y i is the actual value, and is the predicted value; Select the better performing model, i.e. the model with smaller MSE: If MSE A <MSE B , then select M A ; Otherwise select M B ; The meanings of the physical characters in the calculation formulas in the above content are as follows: M(x;θ): represents the prediction model, where x is the input data of the model and θ is the parameter of the model; Y: represents the actual resource usage data, i.e., the observed value or true value; Represents the output of the prediction model M, that is, the predicted value; E: represents the prediction error, that is, the difference between the actual data Y and the predicted data The difference between θ new : represents the adjusted model parameters; α: represents the learning rate, which is used to control the step size of model parameter update; Represents the gradient of the error E with respect to the model parameter θ; MSE A and MSE B : Represents the mean square error of the experimental group A and the control group B, respectively, used to evaluate the performance of the model; n A and n B : Represents the number of data points in the experimental group A and the control group B respectively; Y i : represents the actual value of the i-th data point; and Represent the predicted values of experimental group A and control group B respectively.