A security monitoring method and system based on artificial intelligence
Through an artificial intelligence-based security monitoring system, combined with object recognition and behavioral analysis, coding parameters are optimized, and the problems of waste of resources and insufficient recognition capabilities in the existing technology are solved, achieving efficient security monitoring effects.
Patent Information
- Application Number
- CN202411487804.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-24
- Publication Date
- 2024-12-20
- Estimated Expiration
- 2044-10-24
AI Technical Summary
The existing adaptive coding technology ignores the differences in object importance in security monitoring, resulting in waste of resources and insufficient identification capabilities of potential threats, and the inability to provide picture information in a timely and accurate manner, especially in complex dynamic scenarios.
Adopting an artificial intelligence-based security monitoring system, through the object recognition module, behavior analysis module, coding adjustment module, scene perception module and feedback correction module, object recognition, behavior analysis, coding parameter adjustment and resource optimization are carried out separately to ensure high-definition of key objects. Presentation and resource allocation rationally.
It improves the intelligence level of monitoring, quickly recognizes abnormal behavior, enhances the ability to predict and handle potential threats, optimizes resource allocation, and significantly improves the monitoring accuracy and response speed of the security system for key objects.
Smart Images

Figure CN119011839B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of adaptive coding technology, and in particular to a security monitoring method and system based on artificial intelligence. Background Art
[0002] The field of adaptive coding technology is a technology that dynamically adjusts the data coding method. It aims to automatically optimize the coding parameters according to different situations such as network environment, transmission requirements and equipment processing capabilities to improve the efficiency and quality of data transmission. In the fields of video transmission and data compression, adaptive coding can reduce transmission delays and improve compression efficiency while maintaining high data quality by adjusting the coding algorithm in real time. It is widely used in scenarios such as video conferencing, network video playback, and video surveillance to ensure smooth picture and sound quality under network conditions with limited or fluctuating bandwidth. Security monitoring requires the use of adaptive coding technology.
[0003] However, existing adaptive coding technologies mainly focus on the dynamic adjustment of network environment and equipment performance, ignoring the differences in the importance of objects in security monitoring video content, resulting in the inability to prioritize key monitoring objects. When processing complex dynamic scenes, existing technologies adopt a unified coding strategy for all objects and backgrounds, which easily leads to waste of resources, especially when the static background occupies a large proportion, the coding efficiency is low. In addition, existing technologies are unable to conduct in-depth analysis of the behavioral characteristics of objects and lack accurate identification of abnormal behaviors, resulting in delayed response when responding to sudden security incidents, affecting the actual monitoring effect of security monitoring. These shortcomings have led to a waste of monitoring resources and insufficient ability to identify potential threats, making it difficult to provide timely and accurate image information at critical moments. Summary of the invention
[0004] The purpose of the present invention is to solve the shortcomings of the prior art and to propose a security monitoring method and system based on artificial intelligence.
[0005] In order to achieve the above purpose, the present invention adopts the following technical solution: A security monitoring system based on artificial intelligence includes:
[0006] The object recognition module extracts spatial information from the input security monitoring video frames, extracts spatial features of multiple objects in each frame by identifying changes in shape, color and contour, analyzes and identifies relative position information, determines the category of each object, generates target recognition classification results, and assigns a security level to each object by comparing category features, generating security level determination results;
[0007] A behavior analysis module, based on the target recognition and classification results and the security level determination results, extracts the motion trajectories in multiple video frames, performs time series analysis of the trajectory points, calculates the speed and path change amplitude of the object, determines the motion characteristics and interaction status between the objects, analyzes and identifies abnormal trajectory deviations, and generates behavior feature analysis results;
[0008] A coding adjustment module, based on the behavior feature analysis result, calculates the proportion of objects in each frame by extracting the priority and motion state of the objects, determines the resolution and frame rate requirements, allocates the bit rate according to the object distribution and importance, adjusts the parameters of the intra-frame image coding, and generates a coding parameter adjustment result;
[0009] A scene perception module, based on the coding parameter adjustment result, extracts background features in the frame, analyzes the difference between the background and the motion area, calculates the distribution of static and dynamic areas, identifies the distribution areas of the static parts and moving objects in the video frame, determines the coding requirements of the background area, adjusts the coding accuracy of each area, and generates a scene coding adjustment result;
[0010] The feedback correction module extracts the encoded video data based on the scene encoding adjustment result, compares the inter-frame differences and object distribution characteristics of the real-time video, analyzes the changes between the current encoding and the past encoding, calculates the real-time object priority update frequency, continuously analyzes the change trend of the object, adjusts the priority list, and generates encoding optimization feedback results.
[0011] Preferably, the target recognition classification results include the type, size and location information of the object, the security level determination results include high risk, medium risk and low risk levels, the behavior feature analysis results include the target's movement speed, movement direction and path deviation data, the encoding parameter adjustment results include the adjusted resolution, frame rate and bit rate allocation, the scene encoding adjustment results include low-precision encoding of static background areas, high-precision encoding of dynamic object areas and medium-precision encoding of moving edge areas, and the encoding optimization feedback results include object priority lists, real-time encoding parameter updates and past encoding comparison data.
[0012] Preferably, the object recognition module includes:
[0013] The spatial feature extraction submodule extracts the shape, color and contour features of each object based on the surveillance video frames, analyzes the inter-frame features through the convolutional neural network, compares the object morphology frame by frame, and marks the location information to generate the object spatial feature set;
[0014] The relative position analysis submodule extracts the coordinate information of multiple objects based on the object space feature set, calculates the relative positions between the objects, determines the spatial relationship between the objects by comparing the distance changes between the objects, and generates the relative position information of the objects;
[0015] The category judgment submodule classifies the object category based on the relative position information of the object and combined with the spatial features. By comparing the feature set of each object, the category to which it belongs is identified, and the object is classified and labeled according to the category characteristics of the object to generate the target recognition classification result and the security level determination result.
[0016] Preferably, the behavior analysis module includes:
[0017] A trajectory extraction submodule, based on the target recognition and classification results and the security level determination results, extracts the position changes of the object in multiple frames, analyzes the displacement information of the object frame by frame, records the motion path of the object, and generates a set of object motion trajectories;
[0018] A motion feature analysis submodule calculates the object's motion speed and direction based on the object's motion trajectory set, performs path length analysis, and generates motion feature analysis data by determining changes in the object's motion trajectory and analyzing the object's motion state.
[0019] The trajectory deviation judgment submodule compares the path of the normal trajectory based on the motion feature analysis data, identifies abnormal deviation, marks the abnormal trajectory, determines the location of the abnormal deviation, and obtains the behavior feature analysis result.
[0020] Preferably, the encoding adjustment module includes:
[0021] A priority extraction submodule, based on the behavior feature analysis results, extracts the motion state and safety level of the object, determines the priority order of the object, calculates the importance of the object in the video frame, and generates an object priority list;
[0022] A bit rate allocation submodule calculates the bandwidth required for each object based on the object priority list, allocates the bit rate according to the priority of the object through dynamic allocation of the bit rate, and generates bit rate allocation data;
[0023] The intra-frame coding adjustment submodule adjusts the image coding in the video frame based on the bit rate allocation data, adjusts the intra-frame coding accuracy according to the bit rate requirement of each object, optimizes the image clarity, and generates a coding parameter adjustment result.
[0024] Preferably, the scene perception module includes:
[0025] A background feature extraction submodule extracts the static background part in the video frame based on the encoding parameter adjustment result, identifies the features of the static area in the background by comparing the background area with the motion area, and generates background area feature data;
[0026] The dynamic area recognition submodule recognizes the dynamic object area in the video frame based on the background area feature data, determines the proportion of each area by comparing the distribution of the dynamic area and the static area, and generates dynamic area distribution data;
[0027] The coding precision adjustment submodule adjusts the coding precision of the static background and dynamic object regions respectively based on the dynamic region distribution data, optimizes the coding strategy through the precision of each region, and generates a scene coding adjustment result.
[0028] Preferably, the feedback correction module includes:
[0029] A coding data comparison submodule extracts coding data of a video frame based on the scene coding adjustment result, and calculates a coding difference between the coding data of a current frame and past coding data by comparing the coding data of the current frame and past coding data, thereby generating coding difference data;
[0030] A priority update submodule, based on the encoded difference data, adjusts the priority list of the object, updates the priority order in combination with the motion change and distribution of the current object, and generates a priority update list;
[0031] The strategy adjustment submodule adjusts the current encoding strategy based on the priority update list, reconfigures encoding parameters through current priority information, optimizes encoding allocation between frames, and generates encoding optimization feedback results.
[0032] Preferably, the convolutional neural network is according to the formula:
[0033] ;
[0034] Computes the object feature map value, where is the output feature map value, is the weight of the convolution kernel, is the pixel value of the input image, is the adjustment parameter of edge feature strength, To control the weight coefficient of edge feature influence, is the texture complexity parameter of the object, To control the weight coefficient of texture complexity, is the bias value, is the size of the convolution kernel.
[0035] An artificial intelligence-based security monitoring method, the artificial intelligence-based security monitoring method is performed based on the artificial intelligence-based security monitoring system, comprising the following steps:
[0036] S1: Based on the security monitoring video frame, extract the object information in the video frame, identify the shape, color and contour features, obtain multiple object spatial features in each frame, analyze the relative position information of the objects in the frame, determine the category of each object, calculate the security level by comparing the category features, and generate the target recognition classification result and security level determination result;
[0037] S2: Based on the target recognition classification result and the security level determination result, extract the object motion trajectory in the video frame, analyze the time series between the trajectory points, calculate the speed and path changes of the object in multiple frames, determine the motion characteristics of the object, analyze the interactive behavior between the objects, identify abnormal motion through trajectory changes, generate behavior feature analysis results, calculate the proportion of the object in each video frame according to the priority and motion state of the object, determine the resolution and frame rate requirements, and generate encoding parameter adjustment results;
[0038] S3: Based on the encoding parameter adjustment result, extract the background features in the video frame, calculate the difference between the background and the motion area, identify the distribution area of the static background and the dynamic object, analyze the encoding requirements of each area, adjust the encoding accuracy of the static background and the dynamic object, generate the scene encoding adjustment result, calculate the priority update frequency of the objects between frames by comparing the encoded video data, and generate the encoding optimization feedback result.
[0039] Compared with the prior art, the advantages and positive effects of the present invention are:
[0040] In the present invention, by extracting and identifying spatial features of objects in security monitoring videos, accurately analyzing the categories of objects and their importance in the video, the intelligent level of monitoring is effectively improved. Combined with the motion trajectory and time series analysis of the object, abnormal behavior can be quickly identified, and the ability to predict and handle potential threats is enhanced. At the same time, according to the priority and motion state of the object, the resolution and frame rate in the video are reasonably allocated, ensuring the high-definition presentation of key objects and optimizing resource allocation. The differences between background and dynamic areas are clearly distinguished, thereby effectively reducing the resource occupancy of unimportant areas during video encoding, ensuring the efficiency and quality of video transmission. In summary, through the refined processing of different areas, reasonable allocation and efficient utilization of resources are achieved, the monitoring accuracy of the security system for key objects is significantly improved, and the response speed and efficiency of the system are improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 It is a system flow chart of the present invention. DETAILED DESCRIPTION
[0042] 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.
[0043] 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" and the like indicate positions or positional relationships based on the positions or positional relationships shown in the 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, "multiple" means two or more, unless otherwise clearly and specifically defined.
[0044] Example
[0045] See also Figure 1 The present invention provides a technical solution: a security monitoring system based on artificial intelligence includes:
[0046] The object recognition module extracts spatial information from the input security monitoring video frames, extracts spatial features of multiple objects in each frame by identifying changes in shape, color and contour, analyzes and identifies relative position information, determines the category of each object, generates target recognition classification results, and assigns a security level to each object by comparing category features, generating security level determination results;
[0047] The behavior analysis module, based on the target recognition classification results and the safety level determination results, extracts the motion trajectory in multiple video frames, performs time series analysis of trajectory points, calculates the speed and path change amplitude of the object, judges the motion characteristics and interaction states between objects, analyzes and recognizes abnormal trajectory offsets, and generates behavioral characteristic analysis results;
[0048] The encoding adjustment module, based on the behavioral feature analysis results, extracts the priority and motion state of the object, calculates the proportion of each intra-frame object, judges the resolution and frame rate requirements, allocates the bit rate according to the object distribution and importance, adjusts the parameters of intra-frame image encoding, and generates the encoding parameter adjustment results;
[0049] The scene perception module, based on the encoding parameter adjustment results, extracts the background features in the frame, analyzes the differences between the background and the moving area, calculates the distribution of static and dynamic areas, identifies the distribution areas of the stationary parts in the video frame and the moving object, judges the encoding requirements of the background area, adjusts the encoding accuracy of each area, and generates scene encoding adjustment results;
[0050] The feedback correction module extracts the encoded video data based on the scene encoding adjustment results, compares the inter-frame differences and object distribution characteristics of real-time videos, analyzes the changes in the current encoding and past encodings, calculates the real-time object priority update frequency, continuously analyzes the change trend of the object, adjusts the priority list, and generates encoding optimization feedback results.
[0051] The target recognition and classification results include the type, size and location information of the object, the security level determination results include high risk, medium risk and low risk levels, the behavior feature analysis results include the target's movement speed, movement direction and path deviation data, the encoding parameter adjustment results include the adjusted resolution, frame rate and bit rate allocation, the scene encoding adjustment results include low-precision encoding of static background areas, high-precision encoding of dynamic object areas and medium-precision encoding of moving edge areas, and the encoding optimization feedback results include object priority lists, real-time encoding parameter updates and past encoding comparison data.
[0052] In this embodiment, the object recognition module includes:
[0053] The spatial feature extraction submodule extracts the shape, color and contour features of each object based on the surveillance video frames, analyzes the inter-frame features through the convolutional neural network, compares the object morphology frame by frame, and marks the location information to generate the object spatial feature set;
[0054] The relative position analysis submodule extracts coordinate information of multiple objects based on the object spatial feature set, performs relative position calculations between objects, and determines the spatial relationship between objects by comparing the distance changes between objects, and generates relative position information of objects;
[0055] The category judgment submodule classifies object categories based on the relative position information of the object and combines spatial characteristics. By comparing the feature set of each object, identifying the category, and classifying and annotating it according to the category characteristics of the object, generating object recognition classification results and security level judgment results.
[0056] Based on the surveillance video frames, the shape, color and contour features of each object are extracted. First, the input surveillance video frames are processed frame by frame to extract the pixel information of each object, including the contour boundary of the shape, the RGB value of the color and the closure of the contour. The shape features of the object are extracted by calculating the boundary change amplitude of each object. At the same time, the color values of adjacent pixels in each frame are gradient calculated to identify the color change area and extract the color features of the object. Then, the object morphology is analyzed by frame-by-frame comparison to detect the changed boundary points and mark the position information. Based on these features, the object space feature set is generated.
[0057] In the above content, the relative position between objects is calculated according to the formula:
[0058] ;
[0059] Calculates the change in distance between objects.
[0060] In the formula, represents the Euclidean distance between object i and object j, Represent the coordinates of object i, Represent the coordinates of object j respectively.
[0061] Detailed explanation of the formula and the process of formula calculation and derivation:
[0062] The formula is used to calculate the relative distance between two objects in a video frame. First, the coordinates of each object are extracted by monitoring the video frame. ,in, , represents the initial coordinates of object i, , represents the initial coordinates of object j. These coordinate values are put into the formula for calculation. First, The calculation is 120 - 200 = -80, This works out to 250 - 180 = 70, and plugging these results into the formula gives:
[0063] ;
[0064] The calculated result indicates that the distance between object i and object j in the current frame is 106.3 unit length. This result shows that the relative position change of the two objects in space can be obtained through the distance change, and is further used to judge the relationship between objects and generate the relative position information of the object.
[0065] Based on the relative position information of the objects and combined with spatial features, the object categories are classified. First, the spatial relationship between objects, including the states of approaching, far away and stationary, is extracted according to the acquired relative position information of the objects. The spatial features of each object, including shape features and color features, are combined to judge the category of the object by comparing the feature set of each object. Specifically, by comparing the standard shape and color of known categories, the object feature sets that meet the standards are screened out one by one. At the same time, the objects are classified and labeled according to their category characteristics, and the security level of each category is determined. Combined with the relative position changes of the objects, the preset security standards are matched to finally generate the target recognition classification results and security level determination results.
[0066] In this embodiment, the behavior analysis module includes:
[0067] The track extraction submodule extracts the position changes of the object in multiple frames based on the target recognition classification results and the security level determination results. By analyzing the object's displacement information frame by frame, recording the object's motion path, and generating the object's motion trajectory set;
[0068] The motion feature analysis submodule calculates the motion speed and direction of the object based on the object's motion trajectory set, performs path length analysis, and analyzes the object's motion state by judging the object's motion trajectory changes, analyzes the object's motion state, and generates motion feature analysis data;
[0069] The track offset judgment submodule uses motion feature analysis data, compares the paths of the normal trajectory, recognizes abnormal offsets, performs abnormal marking of the trajectory, determines the position of the abnormal offset, and obtains the results of behavioral feature analysis.
[0070] Based on the target recognition classification results and the security level determination results, the position changes of the object in multiple frames are extracted. First, the object in each frame is identified and the position information of each object is recorded. The displacement changes of the object are analyzed frame by frame to determine the motion trajectory of the object between frames. Specifically, the displacement value of each object in different frames is calculated, the changes of the object on the X-axis and Y-axis are analyzed, and the motion path of each object is extracted. In multiple frame images, the motion path of each object is accumulated into a motion trajectory set by comparing the changes in its displacement data. The motion trajectories of all objects will be recorded and stored for subsequent behavior analysis, and finally an object motion trajectory set will be generated.
[0071] In the above content, the speed and direction of the object are calculated according to the formula:
[0072] ;
[0073] Calculate the speed and direction of movement of an object.
[0074] In the formula, Represents the object's moving speed. Represents the distance change of the object between two frames, represents the time between frames, is the motion direction angle, and They are the displacement of the object on the Y and X axes respectively.
[0075] Detailed explanation of the formula and the process of formula calculation and derivation:
[0076] This formula is used to calculate the speed and motion direction of the object. First, by extracting the change in position coordinates of the object in two consecutive frames, calculating its displacement difference value on the X-axis and Y-axis, and setting the coordinates of the object in frame 1 as , the coordinates in frame 2 are ,but and , substitute the actual value, such as the coordinates of the object in frame 1 are , the coordinates in frame 2 are , then , , the distance change can be obtained by Calculated.
[0077] For example, the time between frames is 0.04 seconds, then the speed , the object's motion direction angle .
[0078] The result shows that the current object's movement speed is 1346.25 units / second, and the movement direction angle is 21.8 degrees, generating movement feature analysis data.
[0079] Based on the motion feature analysis data, the path of the normal trajectory is compared. First, the motion trajectory data of the current object is extracted, the position changes in each frame are recorded, and its motion state in multiple frames is calculated. Combined with the previous motion trajectory set, the path of the object under normal conditions is compared, and the current motion trajectory is gradually compared with the preset normal path. By comparing the changes in the trajectory path, it is determined whether the trajectory of the current object deviates. The specific position of the abnormal offset is detected mainly by calculating the path curvature and displacement change of the object. At the same time, each trajectory point that may have an abnormality is marked. The marking method is to compare the displacement data changes of the object between frames and set the abnormal marking threshold. When the displacement or path angle offset exceeds the threshold, the trajectory point is automatically marked as an abnormal point, and finally the behavior feature analysis result is obtained.
[0080] In this embodiment, the encoding adjustment module includes:
[0081] The priority extraction submodule is used to extract the motion state and security level of the object based on the behavior feature analysis results, determine the priority order of the object, calculate the importance of the object in the video frame, and generate an object priority list;
[0082] The bit rate allocation submodule calculates the bandwidth required for each object based on the object priority list, and dynamically allocates the bit rate according to the object's priority to generate bit rate allocation data;
[0083] The intra-coding adjustment submodule adjusts the image encoding in the video frame based on the bit rate allocation data, adjusts the intra-coding accuracy according to the bit rate requirements of each object, optimizes the image clarity, and generates encoding parameter adjustment results.
[0084] Based on the results of behavioral feature analysis, the motion state and security level of the object are extracted. First, the motion state of each object in different video frames is identified and extracted, and its speed, position, acceleration and other parameters are recorded frame by frame. At the same time, according to the object's motion trajectory and change trend, each object is classified by comparing the security level standard, and each object is marked with a security level. These objects are sorted according to priority. Specifically, a comprehensive evaluation is conducted on the security level and motion state of each object to determine its importance in the current frame and generate an object priority list. The priority of each object is determined by its comprehensive score under different conditions, which is used for subsequent bit rate allocation and encoding adjustment to finally generate an object priority list.
[0085] In the above content, calculate the bandwidth required for each object according to the formula:
[0086] ;
[0087] Calculates the bitrate requirement of an object.
[0088] In the formula, Representative object The bit rate requirement, Represents the object priority, Represents the resolution requirement of the object, Represents the proportion of screen area occupied by the object. Represents a time interval.
[0089] Detailed explanation of the formula and the process of formula calculation and derivation:
[0090] The formula used to calculate the bit rate requirement for each object is to first extract the priority of each object. , object The priority of the object is determined according to the priority list in the previous paragraph, such as Priority , then determine the resolution requirements of the object , usually the resolution depends on the size and importance of the object, e.g. Next, extract the screen area ratio of the object , for example, an object Occupies 20% of the screen, that is , time interval This is the time at standard frame rate, usually 0.04 seconds.
[0091] Plugging these values into the formula:
[0092] ;
[0093] Through this calculation, the object The bit rate requirement is 10800 bps (bits per second). This result shows that based on the priority, resolution requirement and occupied area ratio of the object, A bandwidth of 10800 bps is required to meet its bit rate allocation requirements and generate bit rate allocation data.
[0094] Based on the bit rate allocation data, the image encoding in the video frame is adjusted. First, the bit rate requirement of each object is extracted, and the accuracy of the corresponding encoding frame is adjusted according to the bit rate allocation result of each object. The encoding frame size and resolution of each object in the image are determined by the allocated bit rate. According to the importance of different objects and the proportion of their occupied bandwidth, their encoding accuracy is adjusted accordingly. Specifically, by controlling the pixel density and detail retention degree in the frame, higher encoding accuracy is provided for high-priority objects, while the bit rate allocation is reduced for low-priority or unimportant background parts, and finally the encoding parameter adjustment result is generated.
[0095] In this embodiment, the scene perception module includes:
[0096] The background feature extraction submodule extracts the static background part in the video frame based on the encoding parameter adjustment results. By comparing the background area and the moving area, identifying the characteristics of the static area in the background, and generating background area feature data;
[0097] The dynamic area identification submodule identifies the dynamic object area in the video frame based on the background area feature data. Through the distribution comparison between the dynamic area and the static area, the proportion of each area is determined and dynamic area distribution data is generated;
[0098] The encoding accuracy adjustment submodule, based on dynamic region distribution data, performs encoding accuracy adjustments on the static background and dynamic object areas respectively. Through the accuracy optimization of the coding strategy of each region, the scene encoding adjustment results are generated.
[0099] Based on the results of encoding parameter adjustment, the static background part in the video frame is extracted. First, the static area and moving area in each video frame are compared and analyzed to extract the pixel distribution of the static area. The static part of the background area is mainly judged by detecting the change in pixels between frames. The specific method includes calculating the intra-frame difference to identify areas without obvious changes, marking the pixel points of these static areas, recording the spatial features of the static background area, integrating these features into a background feature data set, further extracting the feature data of each static area in the background, and finally generating the background area feature data.
[0100] In the above content, by comparing the dynamic area and the static area, according to the formula:
[0101] ;
[0102] Calculate the dynamic area ratio.
[0103] In the formula, Represents the percentage of the dynamic area. Represents the number of dynamic pixels, Represents the total number of pixels.
[0104] Detailed explanation of the formula and the process of formula calculation and derivation:
[0105] This formula is used to calculate the percentage of dynamic area in a video frame to the total frame. First, the number of dynamic pixels is extracted. By comparing the pixel changes of adjacent frames in the video frame, the changed pixels are detected, such as the number of dynamic pixels detected in the current frame. , then extract the total number of pixels of the video frame , for example, the total number of pixels in a video frame is , substituting these values into the formula:
[0106] ;
[0107] Through calculation, it is found that the dynamic area accounts for 0.24% in the current frame. This result shows that in the current video frame, the dynamic area accounts for 0.24% of the total number of pixels, and the dynamic area distribution data is generated.
[0108] Based on the dynamic area distribution data, the encoding accuracy of the static background and dynamic object areas is adjusted respectively. First, the encoding requirements of the background area are extracted according to the distribution of dynamic and static areas in each video frame, and the bit rate allocation for the static background part is reduced. The dynamic area needs to retain more details and higher encoding accuracy due to the motion state of the object, so a higher bit rate is allocated. Specifically, the encoding accuracy of the static and dynamic areas is controlled to balance the bandwidth consumption within the frame, and the pixel density and clarity of each area are adjusted to finally generate the scene encoding adjustment result.
[0109] In this embodiment, the feedback correction module includes:
[0110] The encoded data comparison submodule extracts the encoded data of the video frame based on the scene encoding adjustment results, and calculates the encoding difference between the two by comparing the encoded data of the current frame and the past encoded data to generate the encoded difference data;
[0111] The priority update submodule adjusts the priority list of the object based on the encoded difference data, updates the priority order based on the motion changes and distribution of the current object, and generates a priority update list;
[0112] The policy adjustment submodule adjusts the current coding strategy based on the priority update list, adjusts the current coding strategy, reconfigures the encoding parameters through the current priority information, optimizes the encoding allocation between frames, and generates encoding optimization feedback results.
[0113] Based on the scene coding adjustment result, the coding data of the video frame is extracted. By comparing the coding data of the current frame with the coding data of the past frame, the coding parameters of each video frame are first recorded, and the data related to time, frame rate, resolution and bit rate in the coding data are extracted frame by frame for comparative analysis. The coding data of video frames in different time periods are gradually accumulated, and the differences between the current frame and the past frame are compared, including the changes in the coding frame size, displacement and texture details, so as to identify the coding difference information in the two time periods. These coding difference data are formed by inter-frame comparison, and finally the coding difference data are generated.
[0114] In the above content, adjust the priority list of objects according to the formula:
[0115] ;
[0116] Calculates the priority update value of an object.
[0117] In the formula, Representative object The current priority, Representative object Priority in the previous frame, The amount of change that represents the difference in object encoding, Represents the weight of the encoding difference on the priority.
[0118] Detailed explanation of the formula and the process of formula calculation and derivation:
[0119] This formula is used to adjust the priority of an object based on the encoding difference. First, the priority of the object in the previous frame is extracted. , for example, an object The priority in the previous frame is 10. Then, the encoding difference between the current frame and the past frame is extracted , for example, the change is 5, and the value is obtained by comparing the coded data. Next, determine the weight of the coding difference on the priority , for example, a weight of 0.8 indicates the degree of influence of the encoding difference on the current priority. Substituting these values into the formula:
[0120] ;
[0121] Through this calculation, the object The current priority of is 14. This result shows that based on the current encoding difference, the priority order of the objects is adjusted to generate a priority update list.
[0122] Based on the priority update list, the current encoding strategy is adjusted. By extracting the priority information of each object in the current video frame, the encoding parameters of the object are reconfigured according to its priority. Specific operations include allocating more encoding resources to high-priority objects, adjusting the resolution, bit rate and frame rate of these objects, and giving priority to ensuring the clarity of their video quality. At the same time, for low-priority objects, the encoding resource allocation is reduced, mainly reducing their bit rate and resolution, ensuring more refined encoding processing of high-priority objects in the video frame under limited bandwidth conditions, and finally generating encoding optimization feedback results.
[0123] Convolutional neural network follows the formula:
[0124] ;
[0125] Computes the object feature map value, where is the output feature map value, is the weight of the convolution kernel, is the pixel value of the input image, is the adjustment parameter of edge feature strength, To control the weight coefficient of edge feature influence, is the texture complexity parameter of the object, To control the weight coefficient of texture complexity, is the bias value, is the size of the convolution kernel.
[0126] Execution process:
[0127] first, Still as the convolution kernel weight, it is used to control the importance of each input pixel in feature extraction. represents the pixel value in the input image frame, which represents the basic characteristics of the object. Secondly, the new parameters introduced As an adjustment parameter of edge feature strength, it represents the edge strength of object shape and contour, and is The combination of makes edge information occupy a larger proportion in feature extraction, and the parameters It is the weight coefficient that controls the influence of edge features on the final result. The value can change the sensitivity of the convolutional layer to edge features.
[0128] Then, Represents the texture complexity of the object surface, adjusts the feature map of the input image by the complexity of the texture information, and combines the weight coefficient To adjust the effect of texture complexity on the result, weight Controls the contribution of texture features to the overall mapping,
[0129] Finally, the entire expression is divided by , the square root form of texture complexity is added to make the influence of complex texture parts gradually decrease, balancing the feature extraction accuracy of complex objects and simple objects. Finally, the bias value Continue to balance the final output value to obtain the object feature mapping value.
[0130] Calculation process:
[0131] is the convolution kernel weight, which is assigned through convolution operation. The value range is between 0.1 and 1, depending on the training result of the weight. . Represents the pixel value of the input image. The pixel value range is 0 to 255. The pixel value is selected here. . It is the adjustment parameter of edge feature strength, which indicates the strength of the edge part in the image. The value range is 0 to 100. The edge strength is extracted by edge detection algorithm. Here we select . The weight coefficient of the edge feature influence controls the influence of the edge on the result. The selection range is 0.5 to 1.5. . is the texture complexity parameter of the object. The value range is extracted according to the texture complexity of the object. . is the weight coefficient of texture complexity, which controls the influence of texture on the overall result. The range is 0.3 to 0.8. . is the bias value, which is used to balance the feature map after convolution. . is the size of the convolution kernel, Represents 3 filters.
[0132] According to the parameter values set above, enter them into the formula for calculation:
[0133] ;
[0134] First, calculate the internal parameters:
[0135] ;
[0136] ;
[0137] Put this into the formula:
[0138] ;
[0139] Continue to calculate:
[0140] ;
[0141] Sum:
[0142] ;
[0143] Calculated feature map values . The results show that after the convolution kernel calculation, the extracted object feature map value is 34.01, which is related to multiple factors such as the pixel value, edge feature intensity, and texture complexity of the input image. It reflects the proportion and importance of object features in the image, and will be used for subsequent object classification or object detection processing.
[0144] The present invention provides a security monitoring method based on artificial intelligence, comprising the following steps:
[0145] Based on security monitoring video frames, the object information in the video frame is extracted, the shape, color and outline characteristics are identified, multiple object spatial characteristics are obtained in each frame, the relative position information of the object in the frame is analyzed, the categories of each object are judged, and the security level is calculated by comparing the category characteristics, and the target identification classification results and security level judgment results are generated;
[0146] Based on the target recognition and classification results and the security level determination results, the object motion trajectory in the video frame is extracted, the time series between the trajectory points is analyzed, the speed and path changes of the object in multiple frames are calculated, the motion characteristics of the object are determined, the interactive behavior between the objects is analyzed, abnormal motion is identified through trajectory changes, and the behavior feature analysis results are generated. According to the priority and motion state of the object, the proportion of the object in each video frame is calculated, the resolution and frame rate requirements are determined, and the encoding parameter adjustment results are generated;
[0147] Based on the coding parameter adjustment results, the background features in the video frame are extracted, the difference between the background and the motion area is calculated, the distribution areas of the static background and dynamic objects are identified, the coding requirements of each area are analyzed, the coding accuracy of the static background and dynamic objects is adjusted, and the scene coding adjustment results are generated. By comparing the encoded video data, the priority update frequency of objects between frames is calculated, and the coding optimization feedback results are generated.
[0148] It should be understood that, although each step in the flow chart of each embodiment of the present invention is shown in sequence according to the indication of the arrow, these steps are not necessarily performed in sequence according to the order indicated by the arrow. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be performed in other orders. Moreover, at least a portion of the steps in each embodiment may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these sub-steps or stages is not necessarily performed in sequence, but can be performed in turn or alternately with at least a portion of other steps or sub-steps or stages of other steps.
[0149] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0150] 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 security monitoring system based on artificial intelligence, characterized in that: The system comprises: The object recognition module extracts spatial information from the input security monitoring video frames, extracts spatial features of multiple objects in each frame by identifying changes in shape, color and contour, analyzes and identifies relative position information, determines the category of each object, generates target recognition classification results, and assigns a security level to each object by comparing category features, generating security level determination results; A behavior analysis module, based on the target recognition and classification results and the security level determination results, extracts the motion trajectories in multiple video frames, performs time series analysis of the trajectory points, calculates the speed and path change amplitude of the object, determines the motion characteristics and interaction status between the objects, analyzes and identifies abnormal trajectory deviations, and generates behavior feature analysis results; A coding adjustment module, based on the behavior feature analysis result, calculates the proportion of objects in each frame by extracting the priority and motion state of the objects, determines the resolution and frame rate requirements, allocates the bit rate according to the object distribution and importance, adjusts the parameters of the intra-frame image coding, and generates a coding parameter adjustment result; A scene perception module, based on the coding parameter adjustment result, extracts background features in the frame, analyzes the difference between the background and the motion area, calculates the distribution of static and dynamic areas, identifies the distribution areas of the static parts and moving objects in the video frame, determines the coding requirements of the background area, adjusts the coding accuracy of each area, and generates a scene coding adjustment result; A feedback correction module, based on the scene coding adjustment result, extracts the coded video data, compares the inter-frame difference and object distribution characteristics of the real-time video, analyzes the change between the current coding and the past coding, calculates the real-time object priority update frequency, continuously analyzes the change trend of the object, adjusts the priority list, and generates coding optimization feedback results; The behavior analysis module includes: A trajectory extraction submodule, based on the target recognition and classification results and the security level determination results, extracts the position changes of the object in multiple frames, records the movement path of the object by analyzing the displacement information of the object frame by frame, and generates a set of object movement trajectories; A motion feature analysis submodule calculates the object's motion speed and direction based on the object's motion trajectory set, performs path length analysis, and generates motion feature analysis data by determining changes in the object's motion trajectory and analyzing the object's motion state. The trajectory deviation judgment submodule compares the path of the normal trajectory based on the motion feature analysis data, identifies the abnormal deviation, marks the abnormal trajectory, determines the location of the abnormal deviation, and obtains the behavior feature analysis result; The scene perception module comprises: A background feature extraction submodule extracts the static background part in the video frame based on the encoding parameter adjustment result, identifies the features of the static area in the background by comparing the background area with the motion area, and generates background area feature data; The dynamic area recognition submodule recognizes the dynamic object area in the video frame based on the background area feature data, determines the proportion of each area by comparing the distribution of the dynamic area and the static area, and generates dynamic area distribution data; The coding precision adjustment submodule adjusts the coding precision of the static background and dynamic object regions respectively based on the dynamic region distribution data, optimizes the coding strategy through the precision of each region, and generates a scene coding adjustment result.
2. The artificial intelligence-based security monitoring system according to claim 1, characterized in that: The target recognition classification result includes the type, size and location information of the object, the security level determination result includes high risk, medium risk and low risk levels, the behavior feature analysis result includes the target's movement speed, movement direction and path deviation data, the encoding parameter adjustment result includes the adjusted resolution, frame rate and bit rate allocation, the scene encoding adjustment result includes low-precision encoding of static background areas, high-precision encoding of dynamic object areas and medium-precision encoding of moving edge areas, and the encoding optimization feedback result includes an object priority list, real-time encoding parameter updates and past encoding comparison data.
3. The artificial intelligence-based security monitoring system according to claim 1, characterized in that: The object recognition module comprises: The spatial feature extraction submodule extracts the shape, color and contour features of each object based on the surveillance video frames, analyzes the inter-frame features through the convolutional neural network, compares the object morphology frame by frame, and marks the location information to generate the object spatial feature set; The relative position analysis submodule extracts the coordinate information of multiple objects based on the object space feature set, calculates the relative positions between the objects, determines the spatial relationship between the objects by comparing the distance changes between the objects, and generates the relative position information of the objects; The category judgment submodule classifies the object category based on the relative position information of the object and combines the spatial features. By comparing the feature set of each object, the category to which it belongs is identified, and the object is classified and labeled according to the category features of the object to generate the target recognition classification result and the security level determination result.
4. The artificial intelligence-based security monitoring system according to claim 1, characterized in that: The coding adjustment module comprises: A priority extraction submodule, based on the behavior feature analysis results, extracts the motion state and safety level of the object, determines the priority order of the object, calculates the importance of the object in the video frame, and generates an object priority list; A bit rate allocation submodule calculates the bandwidth required for each object based on the object priority list, allocates the bit rate according to the priority of the object through dynamic allocation of the bit rate, and generates bit rate allocation data; The intra-frame coding adjustment submodule adjusts the image coding in the video frame based on the bit rate allocation data, adjusts the intra-frame coding accuracy according to the bit rate requirement of each object, optimizes the image clarity, and generates a coding parameter adjustment result.
5. The artificial intelligence-based security monitoring system according to claim 1, characterized in that: The feedback correction module comprises: A coding data comparison submodule extracts coding data of a video frame based on the scene coding adjustment result, and calculates a coding difference between the coding data of a current frame and past coding data by comparing the coding data of the current frame and past coding data, thereby generating coding difference data; A priority update submodule, based on the encoded difference data, adjusts the priority list of the object, updates the priority order in combination with the motion change and distribution of the current object, and generates a priority update list; The strategy adjustment submodule adjusts the current encoding strategy based on the priority update list, reconfigures encoding parameters through current priority information, optimizes encoding allocation between frames, and generates encoding optimization feedback results.
6. The artificial intelligence-based security monitoring system according to claim 3 is characterized in that: The convolutional neural network follows the formula: ; Computes the object feature map value, where is the output feature map value, is the weight of the convolution kernel, is the pixel value of the input image, is the adjustment parameter of edge feature strength, To control the weight coefficient of edge feature influence, is the texture complexity parameter of the object, To control the weight coefficient of texture complexity, is the bias value, is the size of the convolution kernel.
7. A security monitoring method based on artificial intelligence, characterized in that: The artificial intelligence-based security monitoring system according to any one of claims 1 to 6 comprises the following steps: Based on the security monitoring video frame, extract the object information in the video frame, identify the shape, color and contour features, obtain the spatial features of multiple objects in each frame, analyze the relative position information of the objects in the frame, determine the category of each object, calculate the security level by comparing the category features, and generate the target recognition classification result and security level determination result; Based on the target recognition classification results and the security level determination results, the object motion trajectory in the video frame is extracted, the time series between the trajectory points is analyzed, the speed and path changes of the object in multiple frames are calculated, the motion characteristics of the object are determined, the interactive behavior between the objects is analyzed, abnormal motion is identified through trajectory changes, and the behavior feature analysis results are generated. According to the priority and motion state of the object, the proportion of the object in each video frame is calculated, the resolution and frame rate requirements are determined, and the encoding parameter adjustment results are generated; Based on the encoding parameter adjustment result, background features in the video frame are extracted, the difference between the background and the motion area is calculated, the distribution area of the static background and the dynamic object is identified, the encoding requirements of each area are analyzed, the encoding accuracy of the static background and the dynamic object is adjusted, and the scene encoding adjustment result is generated. By comparing the encoded video data, the priority update frequency of the objects between frames is calculated, and the encoding optimization feedback result is generated.
Citation Information
Patent Citations
AI intelligent monitoring management platform
CN118314518A
Edge calculation optimization method and system of intelligent video monitoring system
CN118552882A
Obstacle analysis and object color intelligent identification system
CN118587219A
Video encoding and decoding method, apparatus and computer device
US20220394283A1
