Cloud video analysis system
Through resource prediction and allocation and task priority adjustment, the resource allocation of the cloud video analysis system is dynamically optimized, and label generation is optimized based on user feedback, which solves the traditional system resource bottleneck and label accuracy problems, and improves the efficiency and quality of video analysis.
Patent Information
- Application Number
- CN202410641089.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-22
- Publication Date
- 2024-09-06
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Traditional cloud video analysis systems have serious resource bottlenecks when faced with large or complex video processing tasks, resulting in low processing speed and efficiency, and a lack of consideration of user feedback, resulting in a lack of pertinence and accuracy in generated content tags.
The resource prediction and allocation module and the task priority adjustment module are used to predict and optimize resource demand through historical resource usage data and current task queues, dynamically adjust resource allocation, and prioritize key tasks; the video frame feature analysis module identifies key frames and extracts vision The feature and label generation optimization module combines user feedback to adjust feature weights and optimize label generation.
Significantly improves the cost efficiency and operational flexibility of cloud video analysis, ensures rapid response to critical tasks, and enhances the accuracy and relevance of video analysis quality and label generation.
Smart Images

Figure CN118608922A
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of video content recognition, and in particular to a cloud video analysis system. Background Art
[0002] The field of video content recognition technology involves the use of algorithms to automatically detect, analyze, and classify content in video streams, including facial recognition, scene understanding, object recognition, and behavioral pattern recognition. The core technologies of video content recognition include machine learning, deep learning, computer vision, and artificial intelligence, which can process and analyze large amounts of video data to achieve applications such as automated video editing, content tag generation, and security monitoring. This technology is also widely used in advertising, copyright monitoring, media library management, and other fields, providing more personalized and secure video services by accurately analyzing video content.
[0003] Among them, the cloud video analysis system is a video content recognition system based on a cloud computing platform. Its main purpose is to use cloud resources to analyze and process video data in real time or in batches. The system can efficiently process large-scale video data and provide functions such as facial recognition, behavior analysis, and scene analysis. The main advantages of the cloud system are its scalability, flexibility, and cost efficiency, which eliminates the need for users to deploy heavyweight hardware facilities locally. The system is widely used in public safety, traffic monitoring, marketing analysis, and online content supervision, helping enterprises and institutions improve operational efficiency.
[0004] Traditional analysis systems rely on fixed hardware resources and preset processing flows, and lack the ability to dynamically adjust resource usage. This results in resource bottlenecks in traditional systems when faced with large or complex video processing tasks, affecting processing speed and efficiency. For example, in public safety emergencies, traditional analysis systems will delay processing of key video content due to insufficient resource allocation, affecting timely response to events. In addition, traditional systems rarely consider user feedback needs in video feature extraction and analysis, resulting in the lack of pertinence and accuracy in the generated content labels. Summary of the invention
[0005] The purpose of the present invention is to solve the shortcomings of the prior art and to propose a cloud video analysis system.
[0006] In order to achieve the above object, the present invention adopts the following technical solution: a cloud video analysis system, the system comprising:
[0007] The resource prediction and allocation module is based on historical cloud resource usage data, combined with the current video processing task queue, and through resource demand trend analysis, it predicts the cloud server resource usage demand in the future period, dynamically adjusts resource allocation, balances the cost and efficiency of video analysis and processing, and obtains optimized configuration parameters;
[0008] The task priority adjustment module analyzes the type and urgency of the video analysis task based on the optimized configuration parameters, formulates a matching processing priority for each video processing task, adjusts resource allocation, prioritizes key tasks, and obtains a task priority list;
[0009] The video frame feature analysis module performs continuous frame analysis of actions and expressions on the video data based on the task priority list, identifies key frame positions, extracts visual features of key frames, analyzes feature recognition action sequences and emotional states in the video, and obtains a feature data set;
[0010] The label generation optimization module adjusts the feature weights based on the feature data set, calculates and compares the influence of differentiated features, combines user feedback, formulates corresponding label weights, optimizes the accuracy and relevance of labels, and generates optimized labels for each video tag that matches the video.
[0011] The present invention is improved in that the method for predicting resource usage demand is:
[0012] Based on the historical cloud resource usage data, calculate the average resource usage rate in different time periods, normalize the usage data in each time period, standardize the data to the same level, and obtain standardized data;
[0013] Based on the standardized data, combined with the current video processing task queue, through the formula:
[0014] T(t)=α·t+β
[0015] Predict the increase and decrease trend of the task volume in the future time period and obtain the predicted task volume;
[0016] Where T(t) represents the predicted task volume, α is the slope parameter, β is the intercept parameter, and t represents the time variable;
[0017] Through resource demand trend analysis, the historical resource utilization average is combined with the predicted task volume, and the resource usage demand prediction formula is used:
[0018] R(t)=γ·μ+δ·T(t)+∈·log(t+1)
[0019] Predict the resource usage demand of cloud servers in the future period and obtain the resource usage demand prediction value;
[0020] Among them, R(t) is the predicted value of resource usage demand, μ represents the average resource utilization rate in the historical time period, γ is the resource weight coefficient, δ is the prediction weight coefficient, and ∈ is the adjustment factor.
[0021] The present invention is improved in that the step of obtaining the optimization configuration parameters is:
[0022] Collect the requirements of the current video processing task, including the number of videos to be processed and the computing resources required for each video processing, and obtain the requirement matrix N;
[0023] The resource usage demand forecast value R(t) is compared with the current task demand matrix N, the supply and demand difference of each resource type is calculated, and the resource allocation strategy is adjusted according to the supply and demand difference, through the formula:
[0024] C=κ·R(t)+λ·(NR(t))+ξ·sgn(NR(t))
[0025] Dynamically adjust resource allocation to obtain optimized configuration parameters;
[0026] Among them, C is the optimization configuration parameter, N is the demand matrix, which represents the demand of the current video processing task for computing resources, R(t) is the predicted value of resource usage demand, which represents the predicted resource demand, κ, λ and ξ are weight factors, and sgn is the symbolic function.
[0027] The present invention is improved in that the steps of obtaining the task priority list are:
[0028] Analyze the type and urgency of each video processing task, and assign a type index P to each task based on the content characteristics of each task, including video size, expected processing time, and user-specified deadline. type and urgency index U urgency ;
[0029] Combined with the optimization configuration parameter C, analyze the actual resource demand of each task and set the resource demand index R of each task. task ;
[0030] According to the type index P type , Urgency Index U urgency and resource demand index R task , through the formula:
[0031]
[0032] Calculate the priority value P of each task task , and according to the task priority value P task Generate a task priority list from high to low order;
[0033] Among them, P type is the type index, U urgency is the urgency index, R task is the resource demand index, σ, ρ and τ are weight coefficients, P max , Umax and R max is the maximum theoretical value of the index, P task The task priority value.
[0034] The present invention is improved in that the method for identifying the key frame position is:
[0035] According to the task priority list, select the video processing task, read the video stream and cache consecutive frames, perform visual analysis on each frame, detect changes between frames, and use the formula:
[0036]
[0037] Calculate the visual difference between every two frames to obtain the visual difference D;
[0038] Among them, Δp is the pixel intensity difference, Δh is the color histogram difference, Δe is the edge detection intensity difference, ω, μ and ν are weight coefficients, P avg , H avg and E avg Represents the statistical mean of the corresponding differences, D visual difference;
[0039] According to the visual difference D, a judgment threshold T is set, the visual difference D is compared with the judgment threshold T, and the frames exceeding the judgment threshold T are marked as key frames.
[0040] The present invention is improved in that the step of acquiring the feature data set is:
[0041] Based on the keyframes, visual features including edge information, color distribution and texture features are extracted. The features are obtained by applying a feature extraction function to each keyframe, referring to the formula:
[0042]
[0043] Among them, E represents the edge detection result, C represents the color histogram, T represents the texture analysis result, α, β and γ are the weights of the differential features in the total feature vector, and E max , C max and T max is the maximum value of the corresponding feature, and F is the feature extraction function;
[0044] Based on the extracted visual features, feature comparison logic is applied:
[0045] L=δ·F action +∈·F emotion
[0046] Identify and classify actions and emotions in videos, summarize the analysis results, and build a feature dataset based on the feature extraction results of key frames;
[0047] Among them, F action and F emotion They represent the feature subsets of action and emotion associated with the feature data, respectively. δ and ∈ are weight coefficients, and L is the feature analysis logic.
[0048] The present invention is improved in that the method for formulating the corresponding label weight is:
[0049] According to the feature data set, statistical data of differentiated features are extracted, including the contribution of each feature to video content recognition, using the feature influence evaluation function:
[0050]
[0051] Calculate the influence of each feature and obtain the feature influence evaluation result;
[0052] Among them, I is the feature influence evaluation function, which calculates the relative importance of each feature, S feature is the statistical score of the feature, S max is the maximum value of the feature score, η is the scaling factor of the influence, R is the stability score of the feature, and θ is the weight factor of stability;
[0053] According to the feature influence evaluation results, collect user feedback on the automatic labeling results, including positive and negative feedback, and count the accuracy and error rate of each label, using the formula:
[0054] W=ξ·I+λ·F positive -μ·F negative
[0055] Calculate the tag weights and apply the tag weights to the corresponding video tags;
[0056] Among them, F positive and F negative are the positive and negative adjustment factors obtained according to user feedback, ξ, λ and μ are weight adjustment coefficients, and W is the label weight.
[0057] The present invention is improved in that the step of obtaining the optimized label is:
[0058] Based on the label weight W, for each video, by the formula:
[0059]
[0060] Calculate the label matching score L;
[0061] Among them, W i is the weight of the i-th feature, F i is the i-th feature of the video, F maxis the maximum value of the feature value, K is the normalization adjustment coefficient, L is the label matching score, and n is the total number of features:
[0062] According to the label matching score L, the label matching score L is compared with a preset label score threshold. If the label matching score L exceeds the preset threshold, the corresponding video label is assigned to the video to obtain an optimized label.
[0063] Compared with the prior art, the advantages and positive effects of the present invention are:
[0064] In the present invention, by analyzing historical resource usage data and considering real-time video processing task queues, it is possible to predict future resource requirements and dynamically adjust resource allocation, significantly improving the cost efficiency and operational flexibility of cloud-based video analysis. By intelligently analyzing task types and urgency, it is possible to ensure that key tasks are given priority, thereby enabling rapid response in emergency situations and enhancing emergency handling capabilities. Continuous analysis of video frames can accurately identify and extract key frames, making the identification of action sequences and emotional states more accurate, improving the quality of video analysis, and enhancing the relevance and accuracy of subsequent content tag generation. Moreover, by adjusting feature weights and combining user feedback, the pertinence and accuracy of tag generation are optimized. BRIEF DESCRIPTION OF THE DRAWINGS
[0065] Figure 1 is a system flow chart of the present invention;
[0066] Figure 2 A flow chart of resource usage demand prediction of the present invention;
[0067] Figure 3 A flow chart for obtaining optimized configuration parameters for the present invention;
[0068] Figure 4 A flowchart for obtaining a task priority list for the present invention;
[0069] Figure 5 A flowchart for identifying key frame positions of the present invention;
[0070] Figure 6 A flow chart for obtaining a feature data set for the present invention;
[0071] Figure 7 A flow chart for formulating corresponding tag weights for the present invention;
[0072] Figure 8 The flowchart of obtaining optimized labels for the present invention. DETAILED DESCRIPTION
[0073] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0074] In the description of the present invention, it should be understood that the terms "length", "width", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", etc., indicating positions or positional relationships, are based on the positions or positional relationships shown in the accompanying drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as limiting the present invention. In addition, in the description of the present invention, the meaning of "multiple" is two or more, unless otherwise clearly and specifically defined.
[0075] Example
[0076] See also Figure 1 The present invention provides a technical solution: a cloud video analysis system, the system comprising:
[0077] The resource prediction and allocation module is based on historical cloud resource usage data, combined with the current video processing task queue, and through resource demand trend analysis, it predicts the cloud server resource usage demand in the future period, dynamically adjusts resource allocation, balances the cost and efficiency of video analysis and processing, and obtains optimized configuration parameters;
[0078] The task priority adjustment module analyzes the type and urgency of video analysis tasks based on optimized configuration parameters, formulates matching processing priorities for each video processing task, adjusts resource allocation, prioritizes key tasks, and obtains a task priority list;
[0079] The video frame feature analysis module analyzes the continuous frames of actions and expressions of the video data based on the task priority list, identifies the key frame positions, extracts the visual features of the key frames, analyzes the action sequences and emotional states in the feature recognition videos, and obtains the feature data set;
[0080] The label generation optimization module adjusts the feature weights based on the feature data set, calculates and compares the influence of differentiated features, and combines user feedback to formulate corresponding label weights, optimize the accuracy and relevance of labels, and generates optimized labels for each video tag matching the video label;
[0081] The optimized configuration parameters include resource allocation diagram, energy-saving indicators and response time optimization. The task priority list includes emergency response level, task processing queue and resource allocation priority. The feature data set includes key frame features, motion vectors and sentiment scores. The optimized labels include scene labels, action labels and emotion labels.
[0082] See also Figure 2 , the method for resource usage demand prediction is:
[0083] Based on the historical cloud resource usage data, calculate the average resource usage rate in different time periods, normalize the usage data in each time period, standardize the data to the same level, and obtain standardized data;
[0084] Based on the standardized data and the current video processing task queue, the formula is:
[0085] T(t)=α·t+β
[0086] Predict the increase and decrease trend of the task volume in the future time period and obtain the predicted task volume;
[0087] Where T(t) represents the predicted task volume, α is the slope parameter, which is used to describe the rate of change of the task volume with time t, β is the intercept parameter, which reflects the basic task volume when time t is zero, and t represents the time variable;
[0088] Through resource demand trend analysis, the historical resource utilization average is combined with the predicted task volume, and the resource usage demand prediction formula is used:
[0089] R(t)=γ·μ+δ·T(t)+∈·log(t+1)
[0090] Predict the resource usage demand of cloud servers in the future period and obtain the resource usage demand prediction value;
[0091] Among them, R(t) is the predicted value of resource usage demand, μ represents the average resource utilization rate in the historical time period, γ is the resource weight coefficient, which is used to adjust the influence of the historical resource utilization rate μ in the resource demand prediction function, δ is the prediction weight coefficient, which is used to adjust the influence of the future task volume obtained according to the task volume prediction model T(t) in the resource demand prediction function, reflecting the direct contribution of the future task volume to the resource demand, and ∈ is the adjustment factor, which is used to consider the impact of the logarithmic growth of time t on resource demand.
[0092] formula:
[0093] T(t)=α·t+β
[0094] R(t)=γ·μ+δ·T(t)+∈·log(t+1)
[0095] Parameter meaning and acquisition method:
[0096] Historical resource usage μ: The parameter represents the average resource usage of the cloud server in the past period of time. It can be obtained by collecting resource usage data within a specific period, such as the daily CPU and memory usage in the past 30 days, and then calculating the average value of the data. The specific acquisition process includes data collection, data cleaning, and average value calculation.
[0097] Task volume prediction model parameters α and β: These two parameters are the slope and intercept used in the linear regression model to predict future task volumes. The process of obtaining the parameters involves collecting historical task data, then using the data for linear regression analysis, and calculating the slope α and intercept β using the least squares method.
[0098] Resource weight coefficient γ and forecast weight coefficient δ: The coefficients are used to balance the influence of historical data and forecast data in resource demand forecasting. The weight coefficients are usually set empirically based on historical performance and future expectations, or adjusted in simulation or real environments through optimization algorithms to minimize forecast errors.
[0099] Time adjustment factor ∈: A coefficient used to adjust the impact of time, which can be obtained based on the analysis of historical data time series or set through expert experience. It reflects the growth or decrease trend of resource demand over time.
[0100] Calculation example:
[0101] Assume that in the past 30 days, the daily resource usage data of the server is as follows:
[0102] 20%, 25%, 30%, ..., 50% (assuming arithmetic growth)
[0103] The historical video processing task volume data is:
[0104] 100,105,110,...,200 (assuming arithmetic growth)
[0105] Set resource weight coefficient γ = 0.5, prediction weight coefficient δ = 0.3, time adjustment factor ∈ = 0.2
[0106] Calculate the average historical resource usage μ:
[0107]
[0108] Analyze the historical task data, assuming that time t is the number of days, t = 1 corresponds to the first day's task volume of 100, t = 30 corresponds to the last day's task volume of 200, and solve α and β:
[0109] T(t)=α·t+β
[0110] 100 = α·1 + β
[0111] 200 = α·30 + β
[0112] By solving the equations, we obtain α=3.45 and β=96.55.
[0113] Calculation of prediction function R(t):
[0114] R(t)=γ·μ+δ·T(t)+∈·log(t+1)
[0115] R(31)=0.5·35+0.3·(3.45·31+96.55)+0.2·log(32)
[0116] R(31)=17.5+0.3·204.95+0.2·3.47≈17.5+61.485+0.694≈79.679
[0117] The process shows how to calculate basic parameters from the collected data and then apply the parameters in the forecasting model to calculate the resource usage demand forecast at a specific point in time.
[0118] See also Figure 3 , the steps to obtain the optimized configuration parameters are:
[0119] Collect the requirements of the current video processing task, including the number of videos to be processed and the computing resources required for each video processing, and obtain the requirement matrix N;
[0120] Compare the resource usage demand forecast value R(t) with the current task demand matrix N, calculate the supply and demand difference of each resource type, and adjust the resource allocation strategy according to the supply and demand difference, through the formula:
[0121] C=κ·R(t)+λ·(NR(t))+ξ·sgn(NR(t))
[0122] Dynamically adjust resource allocation to obtain optimized configuration parameters;
[0123] Among them, C is the optimization configuration parameter, N is the demand matrix, which represents the demand for computing resources of the current video processing task, R(t) is the predicted value of resource usage demand, which represents the predicted resource demand, κ, λ and ξ are weight factors, which are used to adjust the influence of various factors in resource allocation, among which κ emphasizes the conservatism of the prediction, λ adjusts the deviation between the actual demand and the prediction, ξ is used to enhance the flexibility of resource allocation, sgn is the sign function, which returns 1 or -1 according to the positive or negative of NR(t), indicating the comparison result between the actual demand and the prediction, and is used to adjust the resource allocation caused by the fluctuation of the actual demand.
[0124] formula:
[0125] C=κ·R(t)+λ·(NR(t))+ξ·sgn(NR(t))
[0126] Parameter meaning and acquisition method
[0127] Demand matrix N: A data matrix directly obtained from the current task queue, which records the computing resources required for each video processing task. For example, each task requirement may include CPU hours, memory GB, etc. The matrix can be obtained by collecting task data through a real-time monitoring system.
[0128] Resource usage demand forecast R(t): The resource usage at a certain point in the future is predicted based on previous calculations. For example, it can be derived based on past resource usage data and future task prediction algorithms.
[0129] Weight factors κ, λ, and ξ: The weight factors are set based on the performance of historical data and management strategies. For example, κ can be based on the stability assessment of past resource usage, while λ and ξ can be adjusted in a simulation environment through optimization models, such as gradient descent, to achieve optimal resource utilization and cost efficiency.
[0130] Sign function sgn: A mathematical function used to indicate the positive or negative value of a number. In resource management, it is used to determine whether there is a surplus or shortage between actual demand and forecast, thereby adjusting the resource allocation strategy.
[0131] Calculation example:
[0132] Assume that N is the demand matrix, and the specific task requirements are 300 minutes of CPU and 150 GB of memory.
[0133] R(t) is the predicted resource usage demand at a certain point in the future, with a predicted CPU time of 280 minutes and a memory time of 140 GB.
[0134] The weight factors are set to κ=0.6, λ=0.3, ξ=0.1.
[0135] Determine the calculation of the sgn function. Assuming that the actual CPU demand is higher than the forecast (300-280=20>0), and the memory demand is also higher than the forecast (150-140=10>0), then: sgn(CPU)=1, sgn(Memory)=1
[0136] Calculate the optimized configuration parameter C:
[0137] C CPU =κ·280+λ·(300-280)+ξ·sgn(300-280)
[0138] C CPU=0.6·280+0.3·20+0.1·1=168+6+0.1=174.1
[0139] C Memory =κ·140+λ·(150-140)+ξ·sgn(150-140)
[0140] C Memory =0.6·140+0.3·10+0.1·1=84+3+0.1=87.1
[0141] The process shows how to dynamically adjust resource allocation by utilizing the difference between actual demand and forecasted demand and the actual surplus or shortage of resource types to achieve the optimal balance between cost and efficiency.
[0142] See also Figure 4 , the steps to obtain the task priority list are:
[0143] Analyze the type and urgency of each video processing task, and assign a type index P to each task based on the content characteristics of each task, including video size, expected processing time, and user-specified deadline. type and urgency index U urgency ;
[0144] Combined with the optimization configuration parameter C, analyze the actual resource demand of each task and set the resource demand index R of each task. task ;
[0145] According to the type index P type , Urgency Index U urgency and resource demand index R task , through the formula:
[0146]
[0147] Calculate the priority value P of each task task , and according to the task priority value P task Generate a task priority list from high to low order;
[0148] Among them, P type is the type index, which is assigned according to the video type of the task and affects the processing priority of the task. urgency is the urgency index, which is based on the deadline set by the user and the expected processing time of the task, reflecting the urgency of the task. task is the resource demand index, which is set by the optimization configuration parameter C and represents the intensity of the task's demand for resources. σ, ρ, and τ are weight coefficients used to balance the contribution of the type index, urgency index, and resource demand index in the total priority calculation, ensuring that each index has a balanced impact on the final priority ranking.max , U max and R max is the maximum theoretical value of the index, used to convert P type , U urgency and R task Normalized to the same scale to fairly compare the urgency and resource requirements of different tasks, P task The task priority value determines the position of the task in the priority list.
[0149] formula:
[0150]
[0151] Parameter meaning and acquisition method:
[0152] Type Index P type : A numerical value assigned based on the specific category of the video processing task. For example, real-time surveillance video is assigned a higher type index due to its immediacy. The index is usually automatically assigned by the task management system based on the attributes of the task.
[0153] Urgency Index U urgency : An index assigned based on the urgency of the task, usually determined by the user-specified deadline and expected processing time. Shorter deadlines correspond to higher urgency indexes.
[0154] Resource Demand Index R task : represents the position of each task in the resource competition. The index is determined by the resource demand of the task and can be set by optimizing the configuration parameter C.
[0155] Weight coefficients σ, ρ, and τ: coefficients used to balance the impact of each index in the task priority calculation. They can be adjusted based on historical data analysis or management decisions.
[0156] Maximum theoretical value P max , U max and R max : In order to compare different tasks fairly, each index needs to be standardized. The maximum value represents the theoretical maximum value of each index, which is used to convert the actual index value into a standard value between 0 and 1.
[0157] Calculation example:
[0158] Assumption type index P type On a scale from 1 to 10, the P value of real-time surveillance video type =10.
[0159] Urgency Index U urgency is 1 to 10, a task with a tight deadline urgency =9.
[0160] Resource Demand Index R task , assuming that from 1 to 100, the R of a resource-intensive task task =80.
[0161] The weight coefficients are set to σ=0.3, ρ=0.4, τ=0.3.
[0162] The maximum value is set to P max =10,U max =10, R max =100.
[0163] Compute the normalized value for each index:
[0164] Normalized Type Index:
[0165] Normalized Urgency Index:
[0166] Normalized Resource Requirement Index:
[0167] Application priority calculation formula:
[0168]
[0169] P task =0.3·1.0+0.4·0.9+0.3·0.8
[0170] P task =0.3+0.36+0.24
[0171] P task =0.9
[0172] The process shows how to calculate the overall task priority based on the weights of each index, where the priority value P of each task is task The position of the task in the priority list is determined based on the combined effects of the type index, urgency index, and resource requirement index.
[0173] See also Figure 5 , the method to identify the key frame position is:
[0174] According to the task priority list, select the video processing task, read the video stream and cache continuous frames, perform visual analysis on each frame, detect changes between frames, and use the formula:
[0175]
[0176] Calculate the visual difference between every two frames to obtain the visual difference D;
[0177] Among them, Δp is the pixel intensity difference, Δh is the color histogram difference, Δe is the edge detection intensity difference, which is calculated according to the difference in edge detection results between the two frames. ω, μ and ν are weight coefficients, which respectively adjust the contribution ratio of pixel intensity difference, color histogram difference and edge detection intensity difference in the total difference metric. avg , H avg and E avg Represents the statistical average of the corresponding differences, used to standardize the difference data so that multiple types of data can be compared fairly, D visual difference;
[0178] According to the visual difference D, a judgment threshold T is set, the visual difference D is compared with the judgment threshold T, and the frames exceeding the judgment threshold T are marked as key frames.
[0179] formula:
[0180]
[0181] Parameter meaning and acquisition method:
[0182] Pixel intensity difference Δp: obtained by calculating the brightness difference of corresponding pixels between two frames. For each pixel, take its brightness value in the two frames, calculate the absolute value of the difference in brightness value, and find the average of all the differences.
[0183] Color histogram difference Δh: It is calculated by comparing the color histograms of two frames. The histogram describes the distribution of different colors in the image. By calculating the difference between the two histograms and using the Bhattacharyya distance or similarity metric, the quantitative value of the color change can be obtained.
[0184] Edge detection strength difference Δe: Edge detection is used to identify the boundaries of objects in an image. The parameter is calculated by performing edge detection in two frames and then comparing the difference between the edge images of the two frames.
[0185] Weight coefficients ω, μ, and ν: The coefficients are set by analyzing the contribution of different features to the importance of video content and can be trained on labeled data based on experience or through machine learning methods.
[0186] The average difference P avg , H avg and E avg : A statistical average calculated based on a large amount of data to standardize the difference data so that the differences between different videos can be compared fairly.
[0187] Judgment threshold T: used to judge when the frame difference is large enough to mark the frame as a key frame, usually preset and selected according to the dynamics of the video content.
[0188] Calculation example:
[0189] Assume that in two consecutive frames, the average difference in pixel intensity is 15 (i.e. Δp = 15)
[0190] The Bhattacharyya distance of the color histogram is 0.3 (ie, Δh = 0.3)
[0191] The average difference in edge detection is 0.2 (i.e. Δe = 0.2)
[0192] The weight coefficients are set to ω = 0.5, μ = 0.3, ν = 0.2
[0193] The average difference value is set as P avg =10,H avg =0.5, E avg =0.25.
[0194] Compute the standardized difference values:
[0195] Normalized pixel intensity difference:
[0196] Normalized color histogram difference:
[0197] Normalized edge detection strength difference:
[0198] Apply the formula to calculate the frame difference D:
[0199]
[0200] D=0.5·1.5+0.3·0.6+0.2·0.8
[0201] D=0.75+0.18+0.16
[0202] D=1.09
[0203] The value D=1.09 can be used to compare with the dynamic threshold T to determine whether to mark the current frame as a key frame. Assuming T=1.0, when D exceeds T, the frame is identified as a key frame.
[0204] See also Figure 6 , the steps to obtain the feature data set are:
[0205] Based on the keyframes, visual features including edge information, color distribution and texture features are extracted. The features are obtained by applying the feature extraction function to each keyframe, referring to the formula:
[0206]
[0207] Among them, E represents the edge detection result, C represents the color histogram, T represents the texture analysis result, α, β and γ are the weights of the differential features in the total feature vector, and E max , C max and T max is the maximum value of the corresponding feature, F is the feature extraction function, which integrates different visual features into a comprehensive feature vector;
[0208] Based on the extracted visual features, feature comparison logic is applied:
[0209] L=δ·F action +∈·F emotion
[0210] Identify and classify actions and emotions in videos, summarize the analysis results, and build a feature dataset based on the feature extraction results of key frames;
[0211] Among them, F action and F emotion They represent the feature subsets associated with actions and emotions separated from the feature data respectively. δ and ∈ are weight coefficients used to balance the contribution of action and emotion features in the feature analysis module. They can be preset by experts by analyzing historical data. L is the feature analysis logic, which is used to convert the extracted visual features into recognition results of actions and emotions.
[0212] formula:
[0213]
[0214] Parameter meaning and acquisition method:
[0215] Edge detection result E: Edge detection is a technique used in image processing to determine the boundaries of objects in an image. E is obtained by applying an edge detection algorithm. The result is an edge intensity value that reflects the rate of change of pixel intensity in the image.
[0216] Color histogram C: The color histogram reflects the frequency of occurrence of various colors in the image. It is calculated by counting the number of pixels of each color in the image and is a way to understand the color distribution of the image.
[0217] Texture analysis results T: Texture analysis involves calculating the regularity and randomness of textures in an image. This can be done using various texture analysis algorithms, such as gray-level co-occurrence matrices or Tamura features.
[0218] Maximum E max , C max and T max : It is the maximum theoretical value that the corresponding feature can reach, which is used for normalization calculation. The maximum value can be obtained based on the statistical analysis of a large amount of historical image data.
[0219] Weight coefficients α, β, and γ: The weights reflect the relative importance of edge detection, color histogram, and texture analysis in the feature vector. The weights are usually determined based on the contribution of the feature to subsequent tasks.
[0220] Calculation example:
[0221] Assume that the edge detection result E=120, the color histogram C=200, and the texture analysis result T=80.
[0222] The corresponding maximum value is E max =255, C max =300, T max =100.
[0223] The weight coefficients are set to α=0.4, β=0.3, and γ=0.3.
[0224] Normalization process:
[0225] Normalized edge detection results:
[0226] Normalized color histogram:
[0227] Normalized texture analysis results:
[0228] Eigenvector calculation:
[0229] Apply the formula to calculate the comprehensive visual feature F:
[0230]
[0231] F=0.4·0.471+0.3·0.667+0.3·0.800
[0232] F=0.1884+0.2001+0.240
[0233] F≈0.6285
[0234] The computational example shows how to extract a comprehensive visual feature vector from edge, color, and texture data of a single keyframe.
[0235] See also Figure 7 , the method to formulate the corresponding label weight is:
[0236] According to the feature data set, extract the statistical data of the differentiated features, including the contribution of each feature to the video content recognition, and use the feature influence evaluation function:
[0237]
[0238] Calculate the influence of each feature and obtain the feature influence evaluation result;
[0239] Among them, I is the feature influence evaluation function, which calculates the relative importance of each feature, S feature is the statistical score of the feature, which is obtained based on the performance of the feature in the classification or recognition task. max is the maximum value of the feature score, which is used for data normalization. η is the scaling factor of influence, which adjusts the influence value to adapt to subsequent calculations. R is the stability score of the feature, which measures the consistency of the feature performance on different data sets. θ is the weight factor of stability, which determines the contribution of stability in the influence calculation.
[0240] According to the feature influence evaluation results, collect user feedback on the automatic labeling results, including positive and negative feedback, and count the accuracy and error rate of each label. The formula is:
[0241] W=ξ·I+λ·F positive -μ·F negative
[0242] Calculate the tag weights and apply the tag weights to the corresponding video tags;
[0243] Among them, F positive and F negative are the positive and negative adjustment factors obtained according to user feedback, ξ, λ and μ are weight adjustment coefficients used to balance the original influence and the influence of user feedback, and W is the label weight.
[0244] formula:
[0245]
[0246] W=ξ·I+λ·F positive -μ·F negative
[0247] Parameter meaning and acquisition method
[0248] S feature : It is the performance score of each feature in the classification or recognition task, calculated on the training data set through statistical methods such as accuracy, recall or specific performance indicators.
[0249] S max : It is the maximum value of all feature scores and is used to normalize the feature scores to make them comparable when compared between different features.
[0250] η: is a scaling factor, preset by experts based on historical data, used to adjust the normalized score so that it can be used as an influence measure.
[0251] R: It is the stability score of the feature, which is usually calculated based on the consistency of the feature's performance on multiple independent data sets.
[0252] θ: is a weight factor used to adjust the contribution of the stability score in the influence calculation, which is preset by experts based on historical data.
[0253] F positive and F negative : Based on the user feedback statistics on the automatic tagging results, representing the positive and negative feedback impacts respectively.
[0254] ξ, λ, and μ: are weight adjustment coefficients, which are preset by experts based on historical data and are used to balance the influence of original features and the influence of user feedback.
[0255] W: label weight, which takes into account feature influence and user feedback and is used to generate optimized video labels.
[0256] Calculation Example
[0257] Assume S feature =80, indicating the score of a specific feature in the classification task.
[0258] S max =100, the maximum value among all feature scores.
[0259] η=0.5, scaling factor of the normalized score.
[0260] R=0.8, stability score of the feature.
[0261] θ=0.2, weighting factor for stability.
[0262] Calculate the normalized and weighted influence I:
[0263]
[0264]
[0265] I=0.5·(0.8+0.16)=0.5·0.96=0.48
[0266] Assumption F positive = 0.3 and F negative =0.1, representing positive and negative feedback adjustment factors respectively.
[0267] The weight adjustment coefficients ξ=0.7, λ=0.2, μ=0.1.
[0268] Calculate the label weight W:
[0269] W=ξ·I+λ·Fpositive -μ·F negative
[0270] W=0.7·0.48+0.2·0.3-0.1·0.1
[0271] W = 0.336 + 0.06 - 0.01 = 0.386
[0272] The process shows how to combine feature scores, stability scores, user feedback, and various weight factors to calculate the final label weights, ensuring that the generated video labels are both accurate and relevant.
[0273] See also Figure 8 , the steps to obtain the optimized label are:
[0274] Based on the label weight W, for each video, the formula is:
[0275]
[0276] Calculate the label matching score L;
[0277] Among them, W i is the weight of the i-th feature, F i is the i-th feature of the video, such as color histogram, edge information, etc., F max is the maximum value of the feature value, K is the normalization adjustment coefficient, which ensures that the score ratio remains reasonable after feature normalization, L is the label matching score, which is used to evaluate the matching degree between the video and each label, and n is the total number of features:
[0278] According to the label matching score L, the label matching score L is compared with the preset label score threshold. If the label matching score L exceeds the preset threshold, the corresponding video label is assigned to the video to obtain the optimized label.
[0279] formula:
[0280]
[0281] Parameter meaning and acquisition method:
[0282] W i : The feature weight obtained by combining the feature influence and user feedback. Calculated in the previous step.
[0283] F i : represents the i-th feature value of the video, such as color histogram value, edge detection score, obtained by the previous step.
[0284] F max: The maximum value of all eigenvalues, used to normalize the eigenvalues to ensure that the comparison of features at different scales is fair. It is the maximum value selected from all similar eigenvalues in the entire data set.
[0285] K: Normalization adjustment coefficient, used to adjust the score ratio after normalization of feature values to maintain the consistency of the scoring system and the rationality of comparison. The coefficient is preset based on historical data for testing.
[0286] L: Label matching score, which is the weighted sum of the feature normalized value and its weight. The score is used to determine the degree of match between the video and the preset label.
[0287] Calculation example:
[0288] Assume the following data:
[0289] Total number of features n = 3, feature weight W = [0.5, 0.3, 0.2], eigenvalue F = [120, 80, 60], maximum eigenvalue F max =120, normalization adjustment coefficient K=2.
[0290] Normalize each feature:
[0291]
[0292] Apply weights and normalization adjustment factors:
[0293] The label matching score L is calculated using the normalization adjustment coefficient K and feature weight W:
[0294] L=(0.5·1.0+0.3·0.667+0.2·0.5)·2
[0295] L=(0.5+0.2+0.1)·2=0.8·2=1.6
[0296] The calculation process shows how to combine feature weights, feature values, normalization processing and adjustment coefficients to calculate the label matching score L of the video, so that each video can be matched to the most appropriate label to ensure the accuracy and relevance of the label.
[0297] The above are only preferred embodiments of the present invention and are not intended to limit the present invention in other forms. Any technician familiar with the profession may use the technical contents disclosed above to change or modify them into equivalent embodiments with equivalent changes and apply them to other fields. However, any simple modification, equivalent change and modification made to the above embodiments based on the technical essence of the present invention without departing from the technical solution of the present invention still falls within the protection scope of the technical solution of the present invention.
Claims
1. A cloud video analysis system, characterized in that: The system comprises: The resource prediction and allocation module is based on historical cloud resource usage data and the current video processing task queue. Through resource demand trend analysis, it predicts the cloud server resource usage demand in the future period, dynamically adjusts resource allocation, balances the cost and efficiency of video analysis and processing, and obtains optimized configuration parameters. The task priority adjustment module analyzes the type and urgency of the video analysis task based on the optimized configuration parameters, formulates a matching processing priority for each video processing task, adjusts resource allocation, prioritizes key tasks, and obtains a task priority list; The video frame feature analysis module performs continuous frame analysis of actions and expressions on the video data based on the task priority list, identifies key frame positions, extracts visual features of key frames, analyzes feature recognition action sequences and emotional states in the video, and obtains a feature data set; The label generation optimization module adjusts the feature weights based on the feature data set, calculates and compares the influence of differentiated features, combines user feedback, formulates corresponding label weights, optimizes the accuracy and relevance of labels, and generates optimized labels for each video tag that matches the video.
2. The cloud video analysis system according to claim 1, characterized in that: The method for predicting resource usage demand is: Based on the historical cloud resource usage data, calculate the average resource usage rate in different time periods, normalize the usage data in each time period, standardize the data to the same level, and obtain standardized data; Based on the standardized data, combined with the current video processing task queue, through the formula: T(t)=α·t+β Predict the increase and decrease trend of the task volume in the future time period and obtain the predicted task volume; Among them, T(t) represents the predicted task volume, α is the slope parameter, β is the intercept parameter, and t represents the time variable; Through resource demand trend analysis, the historical resource utilization average is combined with the predicted task volume, and the resource usage demand prediction formula is used: R(t)=γ·μ+δ·T(t)+∈·log(t+1) Predict the resource usage demand of cloud servers in the future period and obtain the resource usage demand prediction value; Among them, R(t) is the predicted value of resource usage demand, μ represents the average resource utilization rate in the historical time period, γ is the resource weight coefficient, δ is the prediction weight coefficient, and ∈ is the adjustment factor.
3. The cloud video analysis system according to claim 1, characterized in that: The steps for obtaining the optimization configuration parameters are: Collect the requirements of the current video processing task, including the number of videos to be processed and the computing resources required for each video processing, and obtain the requirement matrix N; The resource usage demand forecast value R(t) is compared with the current task demand matrix N, the supply and demand difference of each resource type is calculated, and the resource allocation strategy is adjusted according to the supply and demand difference, through the formula: C=κ·R(t)+λ·(NR(t))+ξ·sgn(NR(t)) Dynamically adjust resource allocation to obtain optimized configuration parameters; Among them, C is the optimization configuration parameter, N is the demand matrix, which represents the demand of the current video processing task for computing resources, R(t) is the predicted value of resource usage demand, which represents the predicted resource demand, κ, λ and ξ are weight factors, and sgn is the symbolic function.
4. The cloud video analysis system according to claim 1, characterized in that: The steps for obtaining the task priority list are: Analyze the type and urgency of each video processing task, and assign a type index P to each task based on the content characteristics of each task, including video size, expected processing time, and user-specified deadline. type and urgency index U urgency ; Combined with the optimization configuration parameter C, analyze the actual resource demand of each task and set the resource demand index R of each task. task ; According to the type index P type , Urgency Index U urgency and resource demand index R task , through the formula: Calculate the priority value P of each task task , and according to the task priority value P task Generate a task priority list from high to low order; Among them, P type is the type index, U urgency is the urgency index, R task is the resource demand index, σ, ρ and τ are weight coefficients, P max , U max and R max is the maximum theoretical value of the index, P task The task priority value.
5. The cloud video analysis system according to claim 1, characterized in that: The method for identifying the key frame position is: According to the task priority list, select the video processing task, read the video stream and cache consecutive frames, perform visual analysis on each frame, detect changes between frames, and use the formula: Calculate the visual difference between every two frames to obtain the visual difference D; Among them, Δp is the pixel intensity difference, Δh is the color histogram difference, Δe is the edge detection intensity difference, ω, μ and ν are weight coefficients, P avg , H avg and E avg Represents the statistical mean of the corresponding differences, D visual difference; According to the visual difference D, a judgment threshold T is set, the visual difference D is compared with the judgment threshold T, and the frames exceeding the judgment threshold T are marked as key frames.
6. The cloud video analysis system according to claim 1, characterized in that: The steps for obtaining the feature data set are: Based on the keyframes, visual features including edge information, color distribution and texture features are extracted. The features are obtained by applying a feature extraction function to each keyframe, referring to the formula: Among them, E represents the edge detection result, C represents the color histogram, T represents the texture analysis result, α, β and γ are the weights of the differential features in the total feature vector, and E max , C max and T max is the maximum value of the corresponding feature, and F is the feature extraction function; Based on the extracted visual features, feature comparison logic is applied: L=δ·F action +∈·F emotion Identify and classify actions and emotions in videos, summarize the analysis results, and build a feature dataset based on the feature extraction results of key frames; Among them, F action and F emotion They represent the feature subsets of action and emotion associated with the feature data, respectively. δ and ∈ are weight coefficients, and L is the feature analysis logic.
7. The cloud video analysis system according to claim 1, characterized in that: The method for formulating the corresponding label weight is: According to the feature data set, statistical data of differentiated features are extracted, including the contribution of each feature to video content recognition, using the feature influence evaluation function: Calculate the influence of each feature and obtain the feature influence evaluation result; Among them, I is the feature influence evaluation function, which calculates the relative importance of each feature, S feature is the statistical score of the feature, S max is the maximum value of the feature score, η is the scaling factor of the influence, R is the stability score of the feature, and θ is the weight factor of stability; According to the feature influence evaluation results, collect user feedback on the automatic labeling results, including positive and negative feedback, and count the accuracy and error rate of each label, using the formula: W=ξ·I+λ·F positive -μ·F negative Calculate the tag weights and apply the tag weights to the corresponding video tags; Among them, F positive and F negative are the positive and negative adjustment factors obtained according to user feedback, ξ, λ and μ are weight adjustment coefficients, and W is the label weight.
8. The cloud video analysis system according to claim 1, characterized in that: The steps for obtaining the optimized label are: Based on the label weight W, for each video, by the formula: Calculate the label matching score L; Among them, W i is the weight of the i-th feature, F i is the i-th feature of the video, F max is the maximum value of the feature value, K is the normalization adjustment coefficient, L is the label matching score, and n is the total number of features: According to the label matching score L, the label matching score L is compared with a preset label score threshold. If the label matching score L exceeds the preset threshold, the corresponding video label is assigned to the video to obtain an optimized label.
Citation Information
Cited By
Financial data synchronization method and system, computer equipment and storage medium
CN119645988A
Video analysis task scheduling method and system based on intelligent scheduling mode
CN119668819A
Data resource directory management method based on metadata driving
CN119884257A
Dynamic video monitoring resource management system
CN119988042A
