A method and system for improving the accuracy and efficiency of AI analysis of surveillance videos
By performing secondary editing of image materials for video surveillance AI analysis system and screening of IED rules for recognition results, combined with non-negative matrix decomposition and convolutional neural network, the recognition accuracy of video surveillance AI analysis system in complex scenarios is solved. and efficiency issues significantly improve recognition accuracy and system performance.
Patent Information
- Application Number
- CN202411314173.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-20
- Publication Date
- 2025-01-14
- Estimated Expiration
- 2044-09-20
AI Technical Summary
The existing video surveillance AI analysis system has high false recognition and false alarm rates when identifying target objects and analyzing behaviors, and the calculation load is too high, resulting in low analysis accuracy and low efficiency, especially in complex scenarios and changing environments. Poor performance.
By performing secondary editing of the image materials trained by the model, combining non-negative matrix decomposition and convolutional neural network to optimize the batch recognition process, IED rules are used to filter the recognition results, and the efficiency of AI analysis of monitoring videos is improved based on the detection frame rate. Specific measures include mirror flip, affine transformation, Gaussian hybrid model, fractal geometry and Fourier transformation, and optimize the model training and recognition process.
It significantly improves the accuracy and system efficiency of the identification results, reduces the false alarm rate and missed alarm rate, enhances the robustness and adaptability of the model, optimizes the allocation of computing resources, and ensures the efficient operation of the system in complex scenarios and High recognition accuracy.
Smart Images

Figure CN118840698B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of video surveillance technology, and specifically to a method and system for improving the accuracy and efficiency of AI analysis of surveillance videos. Background Art
[0002] With the popularization of video surveillance systems and the advent of the big data era, the use of artificial intelligence technology to automatically analyze surveillance videos has become a trend. This automatic analysis technology can greatly improve the efficiency and accuracy of video surveillance systems while reducing the pressure of manual monitoring. Through intelligent analysis, the monitoring system can detect abnormal behavior and identify specific objects or people in real time, thereby responding to security incidents more promptly and providing effective monitoring data. The application of video surveillance AI analysis technology covers various fields from public safety, traffic management to commercial security, greatly improving the work efficiency and security capabilities in these fields.
[0003] Although video surveillance AI analysis technology has made significant progress, some challenges and problems still exist:
[0004] Low accuracy: The current surveillance video AI analysis system has a certain misidentification rate and false alarm rate in identifying target objects and analyzing behaviors, resulting in low accuracy of analysis results. This is mainly because the existing technology lacks sufficient robustness and adaptability when facing complex scenes and changing environments. Especially in low light, occlusion and changes in viewing angles, the recognition results are often unsatisfactory.
[0005] Low efficiency: When analyzing large-scale surveillance video data, existing surveillance video AI analysis systems often consume a lot of computing resources and time, and the analysis efficiency is low. When processing high-frame rate video streams, most systems have too high a computing load and are difficult to meet real-time requirements. In addition, the existing technology is not sufficiently optimized in batch processing and parallel computing, which further limits the overall performance of the system. Summary of the invention
[0006] In view of the above-mentioned problems, the present invention is proposed.
[0007] Therefore, the technical problem solved by the present invention is that the existing video surveillance AI analysis method has the problems of low accuracy, low efficiency, high computing load, and limited overall system performance.
[0008] To solve the above technical problems, the present invention provides the following technical solutions: a method for improving the accuracy and efficiency of AI analysis of surveillance videos, comprising secondary editing of picture materials for model training, training models and identifying video streams; screening recognition results according to IED rules, and comparing the number of frames reported according to system configuration; optimizing the batch recognition process by combining non-negative matrix decomposition and convolutional neural networks; and improving the efficiency of AI analysis of surveillance videos based on the detection frame rate.
[0009] As a preferred solution of the method for improving the accuracy and efficiency of AI analysis of surveillance videos described in the present invention, the secondary editing of the picture material for model training includes mirror-flipping the original picture to output a new picture;
[0010] Extract the target in the original image, copy and fill it into the original image to output a new image, use affine transformation and Gaussian mixture model to transform the target position and size, and the radial transformation is expressed as:
[0011] ,
[0012] in, Represents the position coordinates of the original target in the image, Indicates the position coordinates of the transformed target in the image, Represents the affine transformation matrix, which contains the parameters of rotation, scaling and shearing transformations. Indicates control zoom, represents a rotation transformation, represents the control transformation, represents the shear transformation, Represents the translation vector, which controls the translation amount of the target position after transformation;
[0013] The Gaussian mixture model is expressed as:
[0014] The Gaussian mixture model is expressed as:
[0015] ,
[0016] in, represents the probability density function at position (x, y), represents the number of Gaussian distributions, that is, the number of components in the Gaussian mixture model, Indicates Gaussian distribution weight coefficients satisfy =1, Indicates The probability density function of a Gaussian distribution at position (x, y), Indicates The mean vector of a Gaussian distribution, represents the covariance matrix associated with the kth Gaussian distribution;
[0017] Expand the content of the original image and output a new image.
[0018] As a preferred solution of the method for improving the accuracy and efficiency of AI analysis of surveillance videos described in the present invention, the training model and identifying the video stream include using data to strengthen the training of image materials and outputting the model, reading the surveillance video stream for identification according to the number of frames per second configured by the system, outputting the identification results, and transmitting them to the identification service system.
[0019] As a preferred solution of the method for improving the accuracy and efficiency of AI analysis of surveillance videos described in the present invention, wherein: the screening of recognition results according to IED rules includes constructing IED rules, screening the output recognition results based on the IED rules, and filtering out recognition results that do not comply with the IED rules, and the IED rules include:
[0020] For the detection area, configure the part of the image as the detection area, and the recognition results of the non-detection area will be invalid;
[0021] For the inspection-free area, part of the area in the configuration image is the inspection-free area, and the recognition results of the inspection-free area will be invalidated;
[0022] For the confidence level, the confidence level of the recognition result is compared with the confidence level of the system configuration. If the confidence level is lower than the threshold, the result is invalidated. Combining the confidence level, target area, location and time factors, a comprehensive screening is performed through a multi-factor weighted model, which is expressed as:
[0023] ,
[0024] in, Indicates The comprehensive score of the recognition results is used as the basis for screening. represents the weight parameter related to the confidence level, represents the weight parameter related to the area ratio, represents the weight parameter related to the Gaussian attenuation term of the position distance, represents the weight parameter associated with the time difference Gaussian decay term, Indicates The confidence level of the recognition result, Indicates The area of the recognition results, Represents the total area of the image, Indicates The timestamp of the recognition result, represents the standard deviation of the position row coordinates, represents the standard deviation of the position column coordinates, Indicates the row coordinates of the center position of the detection area, Indicates the center position column coordinates of the detection area, Indicates The row coordinates of the position of the recognition result in the image, Indicates The position coordinates of the recognition results in the picture are listed. Indicates the time center value or expected value of the detection area, represents the time standard deviation;
[0025] Fractal geometry and Fourier transform are introduced to consider the shape complexity and area ratio of the target. The area ratio and shape complexity are expressed as:
[0026] ,
[0027] in, represents the weight parameter related to the inverse proportion of the area, represents the weight parameter related to shape compactness, represents the weight parameter related to shape complexity, Represents the absolute value of the Fourier transform coefficient and the related weight parameter, Indicates The perimeter of the recognition result, Indicates The boundary length of the recognition results, represents the fractal dimension, Indicates Fourier transform coefficients, which are The frequency domain features of the recognition results are Represents the number of coefficients of the Fourier transform;
[0028] If the ratio of the recognition result to the image does not meet the configuration rules, the recognition result will be invalidated and the saliency will be expressed as:
[0029] ,
[0030] in, represents the recognition result area, Indicates the image area, It represents the ratio of the two;
[0031] when , if the output result validity is 1, the image is not invalidated;
[0032] when , if the output result validity is 0, the image is invalid;
[0033] Indicates the minimum ratio set by the system. Indicates the maximum ratio set by the system.
[0034] As a preferred solution of the method for improving the accuracy and efficiency of AI analysis of surveillance videos described in the present invention, wherein: the comparison according to the number of frames reported by the system configuration includes collecting the number of frames reported by the system configuration, comparing the number of frames reported by the system configuration with the screened recognition results, and if the number of recognition results after screening is less than the number of reported frames, the recognition results of this round are discarded;
[0035] The information entropy and Lagrange multiplier method are combined to optimize the frame timing, ensure the representativeness and uniformity of the frame timing, and construct a frame timing distribution model, which is expressed as:
[0036] ,
[0037] in, represents the optimal frame fetching opportunity set, represents the entropy value of the jth frame, represents the weight parameter, Indicates the total number of frames taken. Indicates the frame fetching timing of the jth frame, Indicates the total time, represents the ideal frame-taking timing of the jth frame when it is evenly distributed;
[0038] The entropy value of the jth frame is expressed as:
[0039] ,
[0040] in, represents the probability of the kth category;
[0041] The probability of the kth category is expressed as:
[0042] ,
[0043] in, represents the row coordinates of the center position of the kth category, represents the center position column coordinates of the kth category, represents the mean vector of the target row coordinates, Represents the mean vector of the target column coordinates, the expected center position coordinates, represents the target row coordinate standard deviation, Represents the standard deviation of the target column coordinates, used to normalize the distance.
[0044] As a preferred solution of the method for improving the accuracy and efficiency of AI analysis of surveillance videos described in the present invention, the process of optimizing batch recognition by combining non-negative matrix decomposition and convolutional neural network includes batch recognition. In a patrol process, video frames are combined into arrays, batch recognition is performed using recognition services, the overhead of cyclic single frame processing is reduced, and a non-negative matrix decomposition model is constructed, which is expressed as:
[0045] ,
[0046] in, Represents a video frame data matrix, where each column or row represents a feature vector of a video frame. Represents the basic feature matrix, each column represents a basic feature, Represents the weight matrix, where each row represents the weight of each video frame on the corresponding basic feature. represents the error in the decomposition process;
[0047] Construct the optimization target model, expressed as:
[0048] ,
[0049] in, Represents the optimization matrix and , so that the objective function reaches the minimum value, Represents the data matrix and the reconstruction matrix The sum of squares of the errors between Representation Matrix The sum of the absolute values of all elements in is used for regularization to control the sparsity of the matrix. Representation Matrix The sum of the absolute values of all elements in is used for regularization to control the sparsity of the matrix. Represents the video frame data matrix The element in the i-th row and j-th column of , is the j-th eigenvalue of the i-th video frame, Represents the element in the i-th row and j-th column of the basic feature matrix W, the element in the basic feature matrix, Represents the element in the i-th row and j-th column of the matrix H, the element in the weight matrix;
[0050] Non-negative matrix factorization decomposes the matrix are two non-negative matrices and The product of , to reduce the dimension of the data, the optimization goal is to make the data matrix and the reconstruction matrix The error between them is minimized, and a regularization term is introduced to control the sparsity of the decomposition matrix and the stability of the decomposition result.
[0051] As a preferred solution of the method for improving the accuracy and efficiency of surveillance video AI analysis according to the present invention, wherein: the improving the efficiency of surveillance video AI analysis based on the detection frame rate includes setting a service patrol interval so that the recognition service runs once every fixed time;
[0052] Set the detection frame rate to control the number of frames recognized per second;
[0053] Using frame-taking algorithm and batch recognition, video frames are combined into arrays during a patrol process and batch recognized using recognition service.
[0054] Another object of the present invention is to provide a system for improving the accuracy and efficiency of surveillance video AI analysis, which can improve the recognition readiness rate of the training model through data enhancement, thereby solving the problem of low accuracy of current video surveillance AI analysis methods.
[0055] As a preferred solution of the system for improving the accuracy and efficiency of surveillance video AI analysis described in the present invention, it includes: a data enhancement module, a result screening module, and an analysis efficiency improvement module; the data enhancement module is used for secondary editing of image materials for model training; the result screening module is used for screening recognition results according to IED rules; the analysis efficiency improvement module is used to improve the efficiency of surveillance video AI analysis.
[0056] A computer device includes a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program as a step to implement a method for improving the accuracy and efficiency of AI analysis of surveillance videos.
[0057] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of a method for improving the accuracy and efficiency of AI analysis of surveillance videos.
[0058] Beneficial effects of the present invention: The method for improving the accuracy and efficiency of AI analysis of surveillance videos provided by the present invention can improve the recognition readiness rate of the training model through data enhancement, and filter out the recognition results that do not meet the rules by IED screening of the recognition results, thereby effectively improving the accuracy and reliability of the final recognition results. By setting the service patrol interval, detection frame rate control, and batch recognition, the allocation of computing resources is optimized, the processing time is reduced, waste is avoided, and the efficient use of computing resources is ensured, thereby optimizing the overall performance of the system and improving the system efficiency. Through optimization in multiple aspects, not only the accuracy of recognition is improved, but also the overall efficiency of the system is significantly improved. Through the reasonable scheduling of recognition services and the efficient use of resources, it is ensured that the system maintains high recognition accuracy and stability while running efficiently, adapts to various complex application scenarios, and improves comprehensive performance. The present invention achieves better results in terms of the accuracy of recognition results, system efficiency, and reliability. BRIEF DESCRIPTION OF THE DRAWINGS
[0059] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative work.
[0060] Figure 1 An overall flow chart of a method for improving the accuracy and efficiency of AI analysis of surveillance videos provided in the first embodiment of the present invention.
[0061] Figure 2 A specific flow chart of a method for improving the accuracy and efficiency of AI analysis of surveillance videos provided in the second embodiment of the present invention.
[0062] Figure 3 An overall flow chart of a system for improving the accuracy and efficiency of AI analysis of surveillance videos provided in the third embodiment of the present invention. DETAILED DESCRIPTION
[0063] In order to make the above-mentioned purposes, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are described in detail below in conjunction with the drawings of the specification. Obviously, the described embodiments are part of the embodiments of the present invention, but not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary persons in the art without creative work should fall within the scope of protection of the present invention.
[0064] Example 1, reference Figure 1-Figure 2 , as an embodiment of the present invention, provides a method for improving the accuracy and efficiency of surveillance video AI analysis, comprising:
[0065] S1: Secondary editing of the image materials for model training, model training and recognition video stream.
[0066] Furthermore, the secondary editing of the image material for model training includes mirroring the original image to output a new image, mirroring the original image left-right or top-bottom to generate a new image. The target object is extracted from the original image, copied and filled into the original image to form multiple new images. On this basis, affine transformation is applied to simulate the performance of the target at different viewing angles and positions through operations such as rotation, scaling, shearing and translation.
[0067] Extract the target in the original image, copy and fill it into the original image to output a new image, use affine transformation and Gaussian mixture model to transform the target position and size, and the radial transformation is expressed as:
[0068] ,
[0069] in, Represents the position coordinates of the original target in the image, Indicates the position coordinates of the transformed target in the image, Represents the affine transformation matrix, which contains the parameters of rotation, scaling and shearing transformations. Indicates control zoom, represents a rotation transformation, represents the control transformation, represents the shear transformation, Represents the translation vector, which controls the translation amount of the target position after the transformation.
[0070] Through affine transformation, the performance of the target at different perspectives and distances is simulated, which not only helps to improve the accuracy of the model in common scenarios, but also enhances the model's ability to cope with extreme conditions such as occlusion, deformation, angle changes, etc.
[0071] The Gaussian mixture model is expressed as:
[0072] ,
[0073] in, represents the probability density function at position (x, y), represents the number of Gaussian distributions, that is, the number of components in the Gaussian mixture model, Indicates Gaussian distribution weight coefficients satisfy =1, Indicates The probability density function of a Gaussian distribution at position (x, y), Indicates The mean vector of a Gaussian distribution, Indicates The covariance matrix associated with the Gaussian distributions.
[0074] The application of Gaussian mixture models randomizes the position and size of the targets, allowing the training data to cover a wider range of possible actual situations. This approach not only expands the dimension of the dataset, but also improves the robustness and generalization ability of the model, making it perform better in complex monitoring scenarios.
[0075] In the process of training the model, the training is combined with the data set based on image enhancement, and the content of the original image is expanded to output a new image.
[0076] It should be noted that data is used to strengthen the training of image materials and output the model, and the surveillance video stream is read for recognition according to the number of frames per second configured by the system, and the recognition results are output and transmitted to the recognition service system.
[0077] It should also be noted that data enhancement is to increase the diversity of data by diversifying the training data, including mirror flipping, target duplication and content expansion, so as to improve the generalization ability of the model in complex scenes. By re-editing the image materials for model training, using mirror flipping, target duplication, affine transformation and Gaussian mixture model and other means, the diversity of training data is greatly increased. Mirror flipping, target duplication, affine transformation and Gaussian mixture model data enhancement means enable the model to be exposed to more diverse scenes during the training process, thereby improving the model's ability to adapt to various complex situations in practical applications.
[0078] S2: Filter the recognition results according to the IED rules and compare them according to the number of frames reported by the system configuration.
[0079] Furthermore, the system first designates certain areas in the image as detection areas or inspection-free areas according to the preset configuration. The recognition results in the detection area will be given priority, while the results in the inspection-free area will be directly filtered out.
[0080] Construct IED rules, filter the output recognition results based on IED rules, and filter out the recognition results that do not meet the IED rules. IED rules include:
[0081] For the detection area, configure the part of the image as the detection area, and the recognition results of the non-detection area will be invalid;
[0082] For the inspection-free area, part of the area in the configuration image is the inspection-free area, and the recognition results of the inspection-free area will be invalidated;
[0083] For the confidence level, the confidence level of the recognition result is compared with the confidence level of the system configuration. If the confidence level is lower than the threshold, the result is invalidated. Combining the confidence level, target area, location and time factors, a comprehensive screening is performed through a multi-factor weighted model, which is expressed as:
[0084] ,
[0085] in, Indicates The comprehensive score of the recognition results is used as the basis for screening. represents the weight parameter related to the confidence level, represents the weight parameter related to the area ratio, represents the weight parameter related to the Gaussian attenuation term of the position distance, represents the weight parameter associated with the time difference Gaussian decay term, Indicates The confidence level of the recognition result, Indicates The area of the recognition results, Represents the total area of the image, Indicates The timestamp of the recognition result, represents the standard deviation of the position row coordinates, represents the standard deviation of the position column coordinates, Indicates the row coordinates of the center position of the detection area, Indicates the center position column coordinates of the detection area, Indicates The row coordinates of the position of the recognition result in the image, Indicates The position coordinates of the recognition results in the picture are listed. Indicates the time center value or expected value of the detection area, represents the time standard deviation;
[0086] The system evaluates the confidence of each recognition result and excludes those that are below the set threshold.
[0087] Fractal geometry and Fourier transform are introduced to consider the shape complexity and area ratio of the target. The area ratio and shape complexity are expressed as:
[0088] ,
[0089] in, represents the weight parameter related to the inverse proportion of the area, represents the weight parameter related to shape compactness, represents the weight parameter related to shape complexity, Represents the absolute value of the Fourier transform coefficient and the related weight parameter, Indicates The perimeter of the recognition result, Indicates The boundary length of the recognition results, represents the fractal dimension, Indicates Fourier transform coefficients, which are The frequency domain features of the recognition results are Represents the number of coefficients of the Fourier transform;
[0090] If the ratio of the recognition result to the image does not meet the configuration rules, the recognition result will be invalidated and the saliency will be expressed as:
[0091] ,
[0092] in, represents the recognition result area, Indicates the image area, It represents the ratio of the two;
[0093] when , if the output result validity is 1, the image is not invalidated;
[0094] when , if the output result validity is 0, the image is invalid;
[0095] Indicates the minimum ratio set by the system. Indicates the maximum ratio set by the system.
[0096] It should be noted that the number of frames reported by the system configuration is collected, and the number of frames reported by the system configuration is compared with the screened recognition results. If the number of screened recognition results is less than the number of reported frames, the recognition results of this round are discarded;
[0097] The information entropy and Lagrange multiplier method are combined to optimize the frame timing, ensure the representativeness and uniformity of the frame timing, and construct a frame timing distribution model, which is expressed as:
[0098] ,
[0099] in, represents the optimal frame fetching opportunity set, represents the entropy value of the jth frame, represents the weight parameter, Indicates the total number of frames taken. Indicates the frame fetching timing of the jth frame, Indicates the total time, represents the ideal frame-taking timing of the jth frame when it is evenly distributed;
[0100] The entropy value of the jth frame is expressed as:
[0101] ,
[0102] in, represents the probability of the kth category;
[0103] The probability of the kth category is expressed as:
[0104] ,
[0105] in, represents the row coordinates of the center position of the kth category, represents the center position column coordinates of the kth category, represents the mean vector of the target row coordinates, Represents the mean vector of the target column coordinates, the expected center position coordinates, represents the target row coordinate standard deviation, Represents the standard deviation of the target column coordinates, used to normalize the distance.
[0106] It should also be noted that in the IED rule screening of the recognition results, through comprehensive consideration of factors such as confidence, target area, location, time, etc., the recognition results that do not meet expectations are effectively filtered out. The introduction of IED rules enables the recognition system to more accurately identify key targets and reduce the possibility of false alarms. In particular, by combining fractal geometry and Fourier transform, the system can analyze the shape complexity and frequency domain characteristics of the target, which is particularly important for processing targets with complex structures. Ultimately, this multi-factor weighted screening model can ensure that only the most qualified recognition results are retained, thereby improving the overall accuracy and reliability of the system.
[0107] Furthermore, the design of IED rules is not only to eliminate noise and false alarms, but more importantly, to ensure high-precision output of recognition results through a multi-dimensional comprehensive evaluation mechanism. The confidence screening is not limited to simple threshold judgment, but also combines the area ratio and location distribution of the target. By analyzing the ratio of the target area to the total area of the image, the system can identify those targets with high confidence but small area ratio, thereby avoiding the situation where the target is ignored because it is too small. At the same time, by introducing fractal geometry and Fourier transform, the system can analyze the shape complexity of the target, thereby more accurately identifying complex targets. This multi-dimensional screening method greatly improves the accuracy of the recognition results, especially in complex scenarios, significantly reducing the false alarm rate and missed alarm rate.
[0108] S3: Combining non-negative matrix factorization and convolutional neural network to optimize the batch recognition process.
[0109] Furthermore, multiple frames of data in the video stream are constructed into a matrix, and each row or column represents a feature vector of a frame. These features can be various features such as pixel values, edge information, color histograms, etc.
[0110] When processing large-scale surveillance video data, batch recognition is a key technology to improve system efficiency. In order to further optimize the batch recognition process, non-negative matrix factorization is combined with convolutional neural networks to significantly improve the system's processing capabilities by reducing data dimensions and extracting key features.
[0111] Batch recognition, in a patrol process, the video frames are combined into an array, and batch recognition is performed using the recognition service to reduce the overhead of looping single frame processing and build a non-negative matrix factorization model, which is expressed as:
[0112] ,
[0113] in, Represents a video frame data matrix, where each column or row represents a feature vector of a video frame. Represents the basic feature matrix, each column represents a basic feature, Represents the weight matrix, where each row represents the weight of each video frame on the corresponding basic feature. represents the error in the decomposition process;
[0114] Construct the optimization target model, expressed as:
[0115] ,
[0116] in, Represents the optimization matrix and , so that the objective function reaches the minimum value, Represents the data matrix and the reconstruction matrix The sum of squares of the errors between Representation Matrix The sum of the absolute values of all elements in is used for regularization to control the sparsity of the matrix. Representation Matrix The sum of the absolute values of all elements in is used for regularization to control the sparsity of the matrix. Represents the video frame data matrix The element in the i-th row and j-th column of , is the j-th eigenvalue of the i-th video frame, Represents the basic characteristic moment The element in the i-th row and j-th column of the basic feature matrix, Representation Matrix The element in the i-th row and j-th column of , the element in the weight matrix;
[0117] The goal is to optimize the matrix and , so that the objective function reaches the minimum value.
[0118] is the Frobenius norm, representing the data matrix and the reconstruction matrix The sum of squares of the errors between is defined as:
[0119] ,
[0120] is the L1 norm, indicating the matrix The sum of the absolute values of all elements in is used for regularization to control the sparsity of the matrix and is defined as:
[0121] ,
[0122] is the L1 norm, indicating the matrix The sum of the absolute values of all elements in is used for regularization to control the sparsity of the matrix and is defined as:
[0123] ,
[0124] It is an additional regularization term used to control the stability of matrix decomposition and ensure that the decomposition result is as accurate as possible in terms of the proportion of the original data.
[0125] Non-negative matrix factorization decomposes the matrix are two non-negative matrices and The product of , to reduce the dimension of the data, the optimization goal is to make the data matrix and the reconstruction matrix The error between them is minimized, and a regularization term is introduced to control the sparsity of the decomposition matrix and the stability of the decomposition result.
[0126] NMF achieves data dimensionality reduction by decomposing the video frame data matrix into a basic feature matrix and a weight matrix. This method not only reduces data redundancy, but also retains the most representative feature information, making the subsequent recognition process more efficient. The introduction of CNN further enhances the system's feature extraction capabilities. Through multi-layer convolution operations, the system can extract more delicate and complex feature information from video frames, ensuring that high-precision recognition effects can be maintained when batch processing multiple video frames.
[0127] S4: Improve the efficiency of surveillance video AI analysis based on detection frame rate.
[0128] Furthermore, the service patrol interval is set so that the recognition service runs at a fixed time interval, reducing the real-time computing pressure of the system and ensuring efficient use of computing resources. The system will regularly trigger the AI recognition service at fixed time intervals.
[0129] Set the detection frame rate to control the number of frames recognized per second. Reduce the amount of computation required to process video frames per second.
[0130] The setting of the service patrol interval enables the system to run the recognition task regularly within the specified time, avoiding unnecessary computing pressure and ensuring that the system can respond quickly at critical moments. Secondly, the optimization of the detection frame rate not only reduces the number of frames processed per second, thereby reducing the computing burden of the system, but also reasonably selects the most representative frames through the frame-taking algorithm, ensuring that the key information in these frames can be accurately captured and analyzed.
[0131] The frame-taking algorithm is used to make the distribution of frame-taking opportunities within 1 second more uniform, ensuring that the frames taken are more representative, improving the accuracy and consistency of recognition, and avoiding recognition errors caused by large differences between frames. The system flexibly adjusts the number of frames processed per second according to actual needs.
[0132] Batch recognition, in one round trip, combines multiple video frames into an array and uses the recognition service to batch recognize them, reducing the overhead of cyclic single frame processing.
[0133] The system combines multiple video frames into an array and processes them simultaneously using batch recognition technology. Through batch recognition technology, multiple video frames are combined into an array for processing, significantly reducing the repetitive work of single frame processing. The system throughput is improved, and the overall performance of the system is optimized through parallel computing, which is especially suitable for processing large-scale surveillance video data.
[0134] Example 2, an embodiment of the present invention, provides a method for improving the accuracy and efficiency of AI analysis of surveillance videos. In order to verify the beneficial effects of the present invention, scientific demonstration is carried out through economic benefit calculation and simulation experiments.
[0135] First, the surveillance video of a certain unit is configured with 5 detection models. According to different data processing methods, the false alarm rates are shown in Table 1:
[0136] Table 1 False alarm rate experimental data table
[0137] ,
[0138] Taking model 1 as an example, after optimizing the patrol interval, detection frame rate, frame acquisition algorithm, and batch recognition, some performance comparison results before and after optimization are obtained, as shown in Table 2:
[0139] Table 2 Performance test data table
[0140] ,
[0141] The experimental results in Table 1 and Table 2 show that the present invention can effectively reduce the false alarm rate of the final recognition result, thereby improving the accuracy of the result. At the same time, through the reasonable scheduling of recognition services and the efficient use of resources, the processing time is reduced, the utilization rate of the GPU is significantly reduced, and the overall performance of the system is optimized.
[0142] Example 3, reference Figure 3 , is an embodiment of the present invention, and provides a system for improving the accuracy and efficiency of AI analysis of surveillance videos, including a data enhancement module, a result screening module, and an analysis efficiency improvement module.
[0143] The data enhancement module is used for secondary editing of image materials for model training, the result screening module is used to screen the recognition results according to IED rules, and the analysis efficiency improvement module is used to improve the efficiency of AI analysis of surveillance videos.
[0144] If the function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods of each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.
[0145] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by an instruction execution system, device or apparatus (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or apparatus and execute instructions), or in conjunction with such instruction execution systems, devices or apparatuses. For the purposes of this specification, "computer-readable medium" can be any device that can contain, store, communicate, propagate or transmit a program for use by an instruction execution system, device or apparatus, or in conjunction with such instruction execution systems, devices or apparatuses.
[0146] More specific examples of computer-readable media (a non-exhaustive list) include the following: an electrical connection with one or more wires (electronic devices), a portable computer disk case (magnetic devices), a random access memory (RAM), a read-only memory (ROM), an erasable and programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disk read-only memory (CDROM). In addition, the computer-readable medium may even be a paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, deciphering or, if necessary, processing in another suitable manner, and then stored in a computer memory.
[0147] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, multiple steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logical function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc. It should be noted that the above embodiments are only used to illustrate the technical solution of the present invention and are not limited. Although the present invention is described in detail with reference to the preferred embodiments, it should be understood by those skilled in the art that the technical solution of the present invention can be modified or replaced by equivalents without departing from the spirit and scope of the technical solution of the present invention, which should be included in the scope of the claims of the present invention.
[0148] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solutions of the present invention may be modified or replaced by equivalents without departing from the spirit and scope of the technical solutions of the present invention, which should all be included in the scope of the claims of the present invention.
Claims
1. A method for improving the accuracy and efficiency of surveillance video AI analysis, characterized in that: include: Secondary editing of the image materials used for model training, model training and recognition of video streams; Filter the identification results according to IED rules and compare them according to the number of frames reported by the system configuration; Construct IED rules, filter the output recognition results based on IED rules, and filter out the recognition results that do not meet the IED rules. IED rules include: For the detection area, configure the part of the image as the detection area, and the recognition results of the non-detection area will be invalid; For the inspection-free area, part of the area in the configuration image is the inspection-free area, and the recognition results of the inspection-free area will be invalidated; For the confidence level, the confidence level of the recognition result is compared with the confidence level of the system configuration. If the confidence level is lower than the threshold, the result is invalidated. Combining the confidence level, target area, location and time factors, a comprehensive screening is performed through a multi-factor weighted model, which is expressed as: in, Indicates The comprehensive score of the recognition results is used as the basis for screening. represents the weight parameter related to the confidence level, represents the weight parameter related to the area ratio, represents the weight parameter related to the Gaussian attenuation term of the position distance, represents the weight parameter associated with the time difference Gaussian decay term, Indicates The confidence level of the recognition result, Indicates The area of the recognition results, Represents the total area of the image, Indicates The timestamp of the recognition result, represents the standard deviation and position row coordinates, represents the standard deviation of the position column coordinates, Indicates the row coordinates of the center position of the detection area, Indicates the center position column coordinates of the detection area, Indicates The row coordinates of the position of the recognition result in the image, Indicates The position coordinates of the recognition results in the picture are listed. Indicates the time center value or expected value of the detection area, represents the time standard deviation; Fractal geometry and Fourier transform are introduced to consider the shape complexity and area ratio of the target. The area ratio and shape complexity are expressed as: in, represents the weight parameter related to the inverse proportion of the area, represents the weight parameter related to shape compactness, represents the weight parameter related to shape complexity, Represents the absolute value of the Fourier transform coefficient and the related weight parameter, Indicates The perimeter of the recognition result, Indicates The boundary length of the recognition result, represents the fractal dimension, Indicates Fourier transform coefficients, which are The frequency domain features of the recognition results are Represents the number of coefficients of Fourier transform; If the ratio of the recognition result to the image does not meet the configuration rules, the recognition result will be invalidated and the saliency will be expressed as: in, represents the recognition result area, Indicates the image area, It represents the ratio of the two; when , if the output result validity is 1, the image is not invalidated; when , if the output result validity is 0, the image is invalid; Indicates the minimum ratio set by the system. Indicates the maximum ratio set by the system; Collect the number of frames reported by the system configuration, and compare the number of frames reported by the system configuration with the filtered recognition results. If the number of filtered recognition results is less than the number of reported frames, the recognition results of this round will be discarded; The information entropy and Lagrange multiplier method are combined to optimize the frame timing, ensure the representativeness and uniformity of the frame timing, and construct a frame timing distribution model, which is expressed as: in, represents the optimal frame fetching opportunity set, represents the entropy value of the jth frame, represents the weight parameter, Indicates the total number of frames taken. Indicates the frame fetching timing of the jth frame, Indicates the total time, represents the ideal frame-taking timing of the jth frame when it is evenly distributed; The entropy value of the jth frame is expressed as: in, represents the probability of the kth category; The probability of the kth category is expressed as: in, represents the row coordinates of the center position of the kth category, represents the center position column coordinates of the kth category, represents the mean vector of the target row coordinates, Represents the mean vector of the target column coordinates, the expected center position coordinates, represents the target row coordinate standard deviation, Represents the standard deviation of the target column coordinates, used to normalize the distance; Combining non-negative matrix factorization and convolutional neural network to optimize batch recognition process; Batch recognition, in a patrol process, the video frames are combined into an array, and batch recognition is performed using the recognition service to reduce the overhead of looping single frame processing and build a non-negative matrix factorization model, which is expressed as: in, Represents a video frame data matrix, where each column or row represents a feature vector of a video frame. Represents the basic feature matrix, each column represents a basic feature, Represents the weight matrix, where each row represents the weight of each video frame on the corresponding basic feature. represents the error in the decomposition process; Construct the optimization target model, expressed as: in, Represents the optimization matrix and , so that the objective function reaches the minimum value, Represents the data matrix and the reconstruction matrix The sum of squares of the errors between Representation Matrix The sum of the absolute values of all elements in is used for regularization to control the sparsity of the matrix. Representation Matrix The sum of the absolute values of all elements in is used for regularization to control the sparsity of the matrix. Represents the video frame data matrix The element in the i-th row and j-th column of , is the j-th eigenvalue of the i-th video frame, Represents the element in the i-th row and j-th column of the basic feature matrix W, the element in the basic feature matrix, Represents the element in the i-th row and j-th column of the matrix H, the element in the weight matrix; Non-negative matrix factorization reduces the dimension of data by decomposing the matrix X into the product of two non-negative matrices W and H. The optimization goal is to minimize the error between the data matrix X and the reconstruction matrix WH. At the same time, a regularization term is introduced to control the sparsity of the decomposition matrix and the stability of the decomposition result. Improve the efficiency of surveillance video AI analysis based on detection frame rate.
2. The method for improving the accuracy and efficiency of surveillance video AI analysis as claimed in claim 1, characterized in that: The secondary editing of the picture material for model training includes mirror-flipping the original picture to output a new picture; Extract the target in the original image, copy and fill it into the original image to output a new image, use affine transformation and Gaussian mixture model to transform the target position and size, and the radial transformation is expressed as: in, Represents the position coordinates of the original target in the image, Indicates the position coordinates of the transformed target in the image, Represents the affine transformation matrix, which contains the parameters of rotation, scaling and shearing transformations. Indicates control zoom, represents a rotation transformation, represents the control transformation, represents the shear transformation, Represents the translation vector, which controls the translation amount of the target position after transformation; The Gaussian mixture model is expressed as: in, Indicates at location The probability density function on , represents the number of Gaussian distributions, that is, the number of components in the Gaussian mixture model, Indicates Gaussian distribution weight coefficients satisfy =1, Indicates Gaussian distribution at position The probability density function on , Indicates The mean vector of a Gaussian distribution, represents the covariance matrix associated with the kth Gaussian distribution; Expand the content of the original image and output a new image.
3. The method for improving the accuracy and efficiency of surveillance video AI analysis as claimed in claim 2, characterized in that: The training model and identifying video streams include using data to strengthen picture material training and outputting models, reading surveillance video streams for identification according to the frames per second configured by the system, outputting identification results, and transmitting them to the identification service system.
4. The method for improving the accuracy and efficiency of surveillance video AI analysis as claimed in claim 3, characterized in that: Improving the efficiency of surveillance video AI analysis based on the detection frame rate includes setting a service patrol interval so that the recognition service runs once at a fixed time interval; Set the detection frame rate to control the number of frames recognized per second; Using frame-taking algorithm and batch recognition, video frames are combined into arrays during one round of patrol, and batch recognition is performed using recognition service.
5. A system using the method for improving the accuracy and efficiency of surveillance video AI analysis as described in any one of claims 1 to 4, characterized in that: Including data enhancement module, result screening module, and analysis efficiency improvement module; The data enhancement module is used for secondary editing of picture materials for model training; The result screening module is used to screen the identification results according to IED rules; The analysis efficiency improvement module is used to improve the efficiency of surveillance video AI analysis.
6. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the steps of the method for improving the accuracy and efficiency of surveillance video AI analysis described in any one of claims 1 to 4 are implemented.
7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method for improving the accuracy and efficiency of surveillance video AI analysis described in any one of claims 1 to 4 are implemented.
Citation Information
Patent Citations
High-altitude safety operation detection method and system based on Internet of Things and visual AI
CN118470610A
Person / object image and screening
US8300890B1