A Cascaded Detection Method for Dynamic Allocation of Video Surveillance Computing Power Driven by Prior Knowledge

CN122090244APending Publication Date: 2026-05-26NAT ENERGY (SHANDONG) NEW ENERGY CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511971987.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-25
Publication Date
2026-05-26

Smart Images

  • Figure CN122090244A_ABST
    Figure CN122090244A_ABST
Patent Text Reader

Abstract

This invention discloses a cascaded detection method for dynamic allocation of computing power in video surveillance based on prior knowledge, specifically including the following steps: S1, data acquisition and generation of domain of interest; S2, dynamic allocation of computing power; S3, cascaded detection; S4, alarm evidence collection and feedback. This invention relates to the field of intelligent video analysis and resource scheduling technology. This cascaded detection method for dynamic allocation of computing power in video surveillance based on prior knowledge generates domains of interest based on task text and divides camera channels into active / dormant states accordingly. This reduces the inference frequency in non-interested periods and areas, thereby reducing ineffective computing power usage. Through two-level cascaded inference of "full-image human body localization + fine recognition within the ROI," it can reduce interference from complex backgrounds in wide-angle scenes and improve the accuracy of identifying the violation attributes of small targets. Through the export of evidence fragments from a circular cache and the return of manual confirmation, alarm evidence retention can be achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent video analysis and resource scheduling technology, specifically a method for dynamic allocation and cascade detection of video surveillance computing power based on prior knowledge. Background Technology

[0002] With the rapid development of the new energy industry, wind farms, photovoltaic power stations, and other production sites have deployed massive amounts of video surveillance equipment (typically reaching thousands of channels). To achieve end-to-end safety management, enterprises urgently need to introduce artificial intelligence technology to automatically identify violations. However, existing video AI analysis systems face serious pain points:

[0003] The contradiction between computing resources and monitoring scale (computing bottleneck): Existing AI systems typically adopt a "full access, polling analysis" model. To achieve real-time analysis of thousands of cameras, an extremely expensive GPU computing cluster is required, resulting in excessively high construction costs; if low-frequency polling (such as analyzing once per minute) is used, it is very easy to miss short-lived violations.

[0004] Low accuracy in small target detection (algorithm bottleneck): In wide-angle surveillance footage, key violation features (such as cigarettes, safety rope hooks, and not wearing goggles) account for a very small percentage of the image (often less than 1%), and the background is extremely complex (such as interference from photovoltaic panels and wind turbine towers). Directly using general target detection algorithms to infer from large images results in extremely high false negative and false positive rates.

[0005] Lack of business context (logic bottleneck): Purely visual algorithms cannot understand business logic. For example, the presence of personnel in an area outside of working hours may be considered normal patrol, while not wearing work clothes during working hours is a violation. This lack of prior business knowledge leads to a large number of invalid alarms generated by the system.

[0006] Therefore, there is an urgent need for a technical solution that can combine operational information (prior knowledge), dynamically allocate valuable computing resources, and effectively improve the detection accuracy of small targets. Summary of the Invention

[0007] (a) Technical problems to be solved

[0008] To address the shortcomings of existing technologies, this invention provides a cascaded detection method for dynamic allocation of computing power in video surveillance based on prior knowledge. By mapping the time window, work location, and work type obtained from parsing the task text to the domain of interest of the monitoring system, the camera channels are divided into active / dormant sections, and differentiated streaming and inference strategies are adopted to improve the analysis density of key work areas and work periods under limited computing power. At the same time, through two-level cascaded inference of "full-image human body localization + ROI fine recognition", the recognition effect of minor violations in wide-angle scenes is improved. When an alarm is triggered, the preceding and following segments are exported from the circular cache for evidence collection, and the manual confirmation results are fed back for subsequent optimization.

[0009] (II) Technical Solution

[0010] To achieve the above objectives, the present invention provides the following technical solution: a cascaded detection method for dynamic allocation of computing power in video surveillance based on prior knowledge, specifically including the following steps:

[0011] S1. Data Acquisition and Domain of Interest Generation: Acquire task text data and video surveillance system location topology data, perform semantic parsing on the task text, extract at least the task time window, task location and task type, and map the task location to a set of camera channels based on the location topology data to generate a domain of interest.

[0012] S2. Dynamic allocation of computing power: During operation, the node status of each camera channel is dynamically determined based on the current time and the domain of interest, including at least active nodes and dormant nodes. Different stream extraction frequencies and different combinations of inference models are used for active nodes and dormant nodes respectively to schedule computing resources.

[0013] S3, Cascaded Detection: Perform two-level cascaded inference on the video stream of active nodes. The first-level model performs full-image human target detection on the video frames to obtain human bounding boxes. Based on the human bounding boxes, a region of interest (ROI) is constructed, and the ROI is input into the second-level model to output the violation attribute recognition result.

[0014] S4. Alarm Evidence Collection and Feedback: When the violation attribute identification result meets the alarm conditions, an alarm message is output, and a video clip containing a preset duration before and after the alarm time is exported from the cache. The alarm message is pushed to the client for confirmation, and the sample library or alarm strategy is updated based on the confirmation result.

[0015] Preferably, the domain of interest in step S1 includes: time mapping, spatial mapping, and event mapping;

[0016] The time mapping involves parsing the start and end times of the work plan from the work schedule to determine the time window for high-frequency analysis.

[0017] The spatial mapping involves extracting location entities from the work location description and retrieving the corresponding set of camera channels from the video location ledger through synonym normalization and fuzzy matching.

[0018] The event mapping involves extracting the job type or risk label from the job content and matching it with an algorithm template based on preset rules or a model configuration table. The algorithm template includes at least a first-level human detection model and one or more second-level violation attribute recognition models.

[0019] Preferably, the alarm conditions in step S4 include at least: the confidence level of the secondary model output exceeds a preset threshold and the same violation attribute meets the consistency condition in multiple consecutive frames.

[0020] Preferably, determining the node status in step S2 includes: when the current time is within the time window of the domain of interest and the camera channel belongs to the set of camera channels, the camera channel is determined as an active node; otherwise, it is determined as a dormant node.

[0021] Active nodes use a first flow rate and load both the primary and secondary models, while dormant nodes use a second flow rate lower than the first flow rate and load only the primary model, or only trigger the loading of the secondary model when intrusion is detected.

[0022] Preferably, the dynamic allocation strategy in step S2 includes:

[0023] For dormant nodes that are in the non-interested time window or do not belong to the interested camera channel set, a lower streaming frequency than that of active nodes is used, and only the first-level human detection is performed, or the second-level violation attribute recognition is triggered when a person is detected.

[0024] For active nodes that are within the time window of the domain of interest and belong to the set of camera channels in the domain of interest, a higher streaming frequency is adopted than that of dormant nodes, and first-level human detection and second-level violation attribute recognition matching with algorithm template are performed. When computing resources are tight, the frequency of dormant nodes is reduced or paused based on the priority of the domain of interest to ensure the latency of active nodes.

[0025] Preferably, the execution of the secondary model in step S3 satisfies at least one triggering condition: the human body bounding box size is within a preset range, the confidence level of the primary model is higher than a threshold, the current algorithm template contains the corresponding violation attribute, or the same human target appears in multiple consecutive frames.

[0026] Preferably, the two-level cascaded reasoning in step S3 includes:

[0027] Level 1 detection: Perform full-image human target detection on the original video frames and output human bounding boxes;

[0028] Adaptive cropping: Expand the human body bounding box by a preset ratio to generate a Region of Interest (ROI), and scale the ROI to the input scale of the secondary model;

[0029] Secondary identification: Input the ROI into the violation attribute identification model and output the identification results of violations such as smoking, using a mobile phone, not wearing a helmet or goggles, and not wearing a seat belt or safety rope.

[0030] Preferably, the cache in step S4 is a circular cache, which caches video streams or video segments according to camera channels. When exporting video segments, the video content from X seconds before the alarm time to Y seconds after the alarm time is exported, based on the alarm time.

[0031] The preset evidence collection time is no less than 10 seconds, and the ring cache is at least partially built in the server memory. When the memory usage reaches the threshold, the earlier video segments will be eliminated or transferred to the disk or object storage.

[0032] Preferably, the confirmation result in step S4 includes at least one of three categories: valid alarm, false alarm, and indeterminate; the confirmation result is associated with the operation type, camera channel, violation attribute category, and time window for subsequent threshold optimization, sample screening, or model update.

[0033] Preferably, in step S3, the ROI is obtained by expanding the human bounding box by an outward expansion ratio. The outward expansion ratio is adaptively determined based on the size of the human bounding box and the target motion amplitude, and the ROI is scaled to the input scale of the secondary model.

[0034] (III) Beneficial Effects

[0035] This invention provides a cascaded detection method for dynamic allocation of computing power in video surveillance based on prior knowledge. Compared with existing technologies, it has the following advantages: This method generates a region of interest based on the task text and divides camera channels into active and dormant states accordingly, reducing the inference frequency in non-interested periods and areas, thereby reducing the waste of computing power. Through two-level cascaded inference of "full-image human body localization + fine recognition within the ROI", it can reduce interference from complex backgrounds in wide-angle scenes and improve the accuracy of identifying the violation attributes of small targets. Through the export of evidence fragments from the circular cache and the return of manual confirmation, it can achieve the retention of alarm evidence and provide data support for subsequent threshold calibration, strategy optimization, or model updates. Attached Figure Description

[0036] Figure 1 This is a flowchart of a method for dynamic allocation of video surveillance computing power and cascaded detection based on prior knowledge provided in an embodiment of the present invention. Figure 2 This is a schematic diagram of the dynamic scheduling logic of computing resources based on the job time window and camera channel set provided in an embodiment of the present invention; Figure 3 This is a schematic diagram of the management process for memory ring buffer and event forensics provided in an embodiment of the present invention.

[0037] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0038] Please see Figure 1-3 This invention provides two technical solutions: a cascaded detection method for dynamic allocation of computing power in video surveillance based on prior knowledge, specifically including the following embodiments: Example 1: A cascaded detection method for dynamic allocation of computing power in video surveillance based on prior knowledge, specifically including the following steps: S1. Data Acquisition and Domain of Interest Generation: Acquire task text data and video surveillance system location topology data, perform semantic parsing on the task text, extract at least the task time window, task location and task type, and map the task location to a set of camera channels based on the location topology data to generate a domain of interest. S2. Dynamic allocation of computing power: During operation, the node status of each camera channel is dynamically determined based on the current time and the domain of interest, including at least active nodes and dormant nodes. Different stream extraction frequencies and different combinations of inference models are used for active nodes and dormant nodes respectively to schedule computing resources. S3, Cascaded Detection: Perform two-level cascaded inference on the video stream of active nodes. The first-level model performs full-image human target detection on the video frames to obtain human bounding boxes. Based on the human bounding boxes, a region of interest (ROI) is constructed, and the ROI is input into the second-level model to output the violation attribute recognition result. S4. Alarm Evidence Collection and Feedback: When the violation attribute identification result meets the alarm conditions, an alarm message is output, and a video clip containing a preset duration before and after the alarm time is exported from the cache. The alarm message is pushed to the client for confirmation, and the sample library or alarm strategy is updated based on the confirmation result.

[0039] In this embodiment of the invention, the domain of interest in step S1 includes: time mapping, spatial mapping, and event mapping; The time mapping involves parsing the start and end times of the work plan from the work schedule to determine the time window for high-frequency analysis. The spatial mapping involves extracting location entities from the work location description and retrieving the corresponding set of camera channels from the video location ledger through synonym normalization and fuzzy matching. The event mapping involves extracting the job type or risk label from the job content and matching it with an algorithm template based on preset rules or a model configuration table. The algorithm template includes at least a first-level human detection model and one or more second-level violation attribute recognition models. Detailed Implementation

[0040] In this embodiment of the invention, the alarm conditions in step S4 include at least: the confidence level of the secondary model output exceeds a preset threshold and the same violation attribute meets the consistency condition in multiple consecutive frames.

[0041] In this embodiment of the invention, determining the node status in step S2 includes: when the current time is within the time window of the domain of interest and the camera channel belongs to the set of camera channels, the camera channel is determined as an active node; otherwise, it is determined as a dormant node. Active nodes use a first flow rate and load both the primary and secondary models, while dormant nodes use a second flow rate lower than the first flow rate and load only the primary model, or only trigger the loading of the secondary model when intrusion is detected.

[0042] In this embodiment of the invention, the dynamic allocation strategy in step S2 includes: For dormant nodes that are in the non-interested time window or do not belong to the interested camera channel set, a lower streaming frequency than that of active nodes is used, and only the first-level human detection is performed, or the second-level violation attribute recognition is triggered when a person is detected. For active nodes that are within the time window of the domain of interest and belong to the set of camera channels in the domain of interest, a higher streaming frequency is adopted than that of dormant nodes, and first-level human detection and second-level violation attribute recognition matching with algorithm template are performed. When computing resources are tight, the frequency of dormant nodes is reduced or paused based on the priority of the domain of interest to ensure the latency of active nodes.

[0043] In this embodiment of the invention, the execution of the secondary model in step S3 satisfies at least one triggering condition: the human body bounding box size is within a preset range, the confidence level of the primary model is higher than a threshold, the current algorithm template contains the corresponding violation attribute, or the same human target appears in multiple consecutive frames.

[0044] In this embodiment of the invention, the two-level cascaded reasoning in step S3 includes: Level 1 detection: Perform full-image human target detection on the original video frames and output human bounding boxes; Adaptive cropping: Expand the human body bounding box by a preset ratio to generate a Region of Interest (ROI), and scale the ROI to the input scale of the secondary model; Secondary identification: Input the ROI into the violation attribute identification model and output the identification results of violations such as smoking, using a mobile phone, not wearing a helmet or goggles, and not wearing a seat belt or safety rope.

[0045] In this embodiment of the invention, the cache in step S4 is a circular cache, which caches video streams or video segments according to camera channels. When exporting video segments, the video content from X seconds before the alarm time to Y seconds after the alarm time is exported, based on the alarm time. The preset evidence collection time is no less than 10 seconds, and the ring cache is at least partially built in the server memory. When the memory usage reaches the threshold, the earlier video segments will be eliminated or transferred to the disk or object storage.

[0046] In this embodiment of the invention, the confirmation result in step S4 includes at least one of three categories: valid alarm, false alarm, and indeterminate. The confirmation result is associated with the operation type, camera channel, violation attribute category, and time window and stored for subsequent threshold optimization, sample screening, or model update.

[0047] In this embodiment of the invention, in step S3, the ROI is obtained by expanding the human bounding box by an outward expansion ratio. The outward expansion ratio is adaptively determined based on the size of the human bounding box and the target motion amplitude, and the ROI is scaled to the input scale of the secondary model.

[0048] Example 2: A cascaded detection method for dynamic allocation of computing power in video surveillance based on prior knowledge, comprising the following steps: S1. Prior knowledge generation and semantic mapping steps based on unstructured text parsing: This step is executed on the management backend of the intelligent analysis platform. The system obtains unstructured text data (such as work orders and work plans) through API interfaces or file import methods, and also obtains the location ledger and equipment topology data of the video surveillance system.

[0049] S1 includes at least: (1) Element extraction: Semantic parsing is performed on the unstructured text data to extract the time element T, spatial element L and event element V of the task, forming a prior knowledge tuple {T, L, V}; where T represents the task time window, L represents the task location information, and V represents the task type or risk label information.

[0050] (2) Spatial mapping: Based on the location ledger and equipment topology data, spatial elements L are mapped to a set of camera channels C={c1, c2, ..., cn}. The spatial mapping can be implemented using synonym normalization, fuzzy matching, or rule-based matching.

[0051] (3) Algorithm configuration: Based on the event element V, the algorithm template A is obtained by matching from the preset algorithm configuration table. The algorithm template A includes at least a first-level human body detection model and one or more second-level violation attribute recognition models.

[0052] In a preferred embodiment, the domain of interest can be represented as K={T, C, A}, where T is the time window, C is the set of camera channels, and A is the algorithm template.

[0053] S2. Steps for dynamic allocation and resource scheduling of computing power based on prior knowledge: This step dynamically groups the camera channels based on the interest domain generated by S1, and configures the streaming frequency and / or inference link accordingly (see appendix). Figure 2 The system's built-in scheduler calculates the channel status value S(ci,t) based on the current time t and the camera channel ci, for example, using the following binary determination method: S(ci,t)=1 when t∈T and ci∈C; otherwise S(ci,t)=0.

[0054] Where S(ci,t)=1 corresponds to the active node channel, and S(ci,t)=0 corresponds to the dormant node channel.

[0055] (1) Active node channel: When S(ci,t)=1, the scheduler allocates higher analysis resources to this channel, uses fhigh, and loads the cascaded detection link corresponding to algorithm template A.

[0056] (2) Dormant node channel: When S(ci,t)=0, the scheduler allocates lower analysis resources to this channel, uses flow, and loads only the first-level human detection link, or triggers the execution of the second-level violation attribute recognition after detecting the presence of a person.

[0057] In a preferred embodiment, flow can be 0.1 frames per second and fhigh can be 4 frames per second; however, the present invention is not limited thereto, and the frequency can be configured according to the server computing power, number of channels and latency requirements.

[0058] S3. Violation detection steps based on two-level cascaded visual reasoning: To improve the recognition of minor violations in large-scale scenarios, this invention employs a two-level cascaded detection architecture for active node channels, including: (1) First-level human body localization: The first target detection model is used to detect the original image I_org to obtain the human body candidate box B_person=[x, y, w, h].

[0059] (2) Adaptive ROI construction and preprocessing: Based on the human body candidate boxes, construct the region of interest (ROI), and expand the candidate boxes to retain key wearable features. The expansion method can be expressed as: ROI=[x−p, y−p, w+2p, h+2p]; Where p is the expansion amount. In a preferred embodiment, p can be max(w, h) × 20%. When the ROI exceeds the original image boundary, the excess portion can be cropped or padded with pixels. The ROI image is then scaled to the input scale required by the secondary model.

[0060] (3) Fine-grained identification of secondary violation attributes: The ROI image is input into the secondary violation attribute identification model, and the confidence score Pj corresponding to the violation category is output (e.g., not wearing a helmet, not wearing a seat belt / safety rope, smoking, not wearing goggles, etc.). In one embodiment, a composite violation score can be calculated: Cv = ∑j(Wj·Pj); Where Wj is the weight of the j-th type of violation attribute, and Pj is the corresponding confidence level. When Cv exceeds the preset threshold, a violation is determined to have occurred, and logical verification can be performed in conjunction with the work type or risk label obtained in step S1 to reduce false alarms.

[0061] In a preferred embodiment, the first target detection model is a lightweight target detection model, and the second violation attribute recognition model is a model optimized and trained for local / small target features of the human body; however, the present invention is not limited to a specific network structure or model name.

[0062] S4. Memory Circular Buffer Forensics and Closed-Loop Feedback Steps: This step is used to quickly obtain high-fidelity evidence data when an alarm is triggered (see appendix). Figure 3 ).

[0063] (1) Memory Ring Buffer: The H.264 / H.265 video streams of active node channels are buffered using a memory ring buffer to achieve cyclic writing by channel or by task. The buffer capacity can be estimated as follows: BufferSize = Number of channels × Bitrate × Pre-buffering duration.

[0064] (2) Event evidence collection: When S3 triggers a violation alarm, the system exports the video clip from X seconds before the alarm time to Y seconds after the alarm time from the ring cache and writes it into persistent storage. At the same time, it generates index information for retrieval and playback, where X+Y is not less than the preset evidence collection time.

[0065] In a preferred embodiment, the preset evidence collection time is 10 seconds, and X and Y satisfy X+Y=10 seconds, for example, X=5 seconds, Y=5 seconds, or X=8 seconds, Y=2 seconds.

[0066] (3) Strategy push and optimization: According to the preset push strategy, the alarm information (including text, screenshots and evidence video links) is sent to the management terminal; the manual confirmation results (valid / invalid) are associated with the alarm samples and stored for threshold calibration, scheduling strategy optimization or model update.

[0067] Compared with existing technologies, this invention generates a domain of interest by mapping the job text information with the camera location topology, and groups and differentiates channels based on the domain of interest, thereby reducing the computational resource consumption of non-interested areas and ensuring the timeliness of analysis of the interest areas; at the same time, it adopts two-level cascaded inference to perform fine recognition within the human ROI, improves the recognition effect of small target violation attributes, and combines cached evidence collection to achieve rapid retention of alarm evidence.

[0068] Furthermore, any content not described in detail in this specification is existing technology known to those skilled in the art.

[0069] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus.

[0070] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

Claims

1. A video surveillance computing power dynamic allocation cascade detection method based on prior knowledge, characterized in that: Specifically, the following steps are included: S1. Data Acquisition and Domain of Interest Generation: Acquire task text data and video surveillance system location topology data, perform semantic parsing on the task text, extract at least the task time window, task location and task type, and map the task location to a set of camera channels based on the location topology data to generate a domain of interest. S2. Dynamic allocation of computing power: During operation, the node status of each camera channel is dynamically determined based on the current time and the domain of interest, including at least active nodes and dormant nodes. Different stream extraction frequencies and different combinations of inference models are used for active nodes and dormant nodes respectively to schedule computing resources. S3, Cascaded Detection: Perform two-level cascaded inference on the video stream of active nodes. The first-level model performs full-image human target detection on the video frames to obtain human bounding boxes. Based on the human bounding boxes, a region of interest (ROI) is constructed, and the ROI is input into the second-level model to output the violation attribute recognition result. S4. Alarm Evidence Collection and Feedback: When the violation attribute identification result meets the alarm conditions, an alarm message is output, and a video clip containing a preset duration before and after the alarm time is exported from the cache. The alarm message is pushed to the client for confirmation, and the sample library or alarm strategy is updated based on the confirmation result.

2. The video surveillance computing power dynamic allocation cascade detection method based on prior knowledge-driven approach according to claim 1, characterized in that: The domains of interest in step S1 include: time mapping, spatial mapping, and event mapping; The time mapping involves parsing the start and end times of the work plan from the work schedule to determine the time window for high-frequency analysis. The spatial mapping involves extracting location entities from the work location description and retrieving the corresponding set of camera channels from the video location ledger through synonym normalization and fuzzy matching. The event mapping involves extracting the job type or risk label from the job content and matching it with an algorithm template based on preset rules or a model configuration table. The algorithm template includes at least a first-level human detection model and one or more second-level violation attribute recognition models.

3. The video surveillance computing power dynamic allocation cascade detection method based on prior knowledge-driven method according to claim 1, characterized in that: The alarm conditions in step S4 include at least: the confidence level of the secondary model output exceeds a preset threshold and the same violation attribute meets the consistency condition in multiple consecutive frames.

4. The video surveillance computing power dynamic allocation cascade detection method based on prior knowledge-driven method according to claim 1, characterized in that: Determining the node status in step S2 includes: when the current time is within the time window of the domain of interest and the camera channel belongs to the set of camera channels, the camera channel is determined to be an active node; otherwise, it is determined to be a dormant node. Active nodes use a first flow rate and load both the primary and secondary models, while dormant nodes use a second flow rate lower than the first flow rate and load only the primary model, or only trigger the loading of the secondary model when intrusion is detected.

5. The video surveillance computing power dynamic allocation cascade detection method based on prior knowledge-driven approach according to claim 1, characterized in that: The dynamic allocation strategy in step S2 includes: For dormant nodes that are in the non-interested time window or do not belong to the interested camera channel set, a lower streaming frequency than that of active nodes is used, and only the first-level human detection is performed, or the second-level violation attribute recognition is triggered when a person is detected. For active nodes that are within the time window of the domain of interest and belong to the set of camera channels in the domain of interest, a higher streaming frequency is adopted than that of dormant nodes, and first-level human detection and second-level violation attribute recognition matching with algorithm template are performed. When computing resources are tight, the frequency of dormant nodes is reduced or paused based on the priority of the domain of interest to ensure the latency of active nodes.

6. The video surveillance computing power dynamic allocation cascade detection method based on prior knowledge-driven method according to claim 1, characterized in that: In step S3, the execution of the secondary model satisfies at least one triggering condition: the human body bounding box size is within a preset range, the confidence level of the primary model is higher than a threshold, the current algorithm template contains the corresponding violation attribute, or the same human target appears in multiple consecutive frames.

7. The video surveillance computing power dynamic allocation cascade detection method based on prior knowledge-driven method according to claim 1, characterized in that: The two-level cascaded reasoning in step S3 includes: Level 1 detection: Perform full-image human target detection on the original video frames and output human bounding boxes; Adaptive cropping: Expand the human body bounding box by a preset ratio to generate a Region of Interest (ROI), and scale the ROI to the input scale of the secondary model; Secondary identification: Input the ROI into the violation attribute identification model and output the identification results of violations such as smoking, using a mobile phone, not wearing a helmet or goggles, and not wearing a seat belt or safety rope.

8. The video surveillance computing power dynamic allocation cascade detection method based on prior knowledge-driven method according to claim 1, characterized in that: In step S4, the cache is a circular cache, and the video stream or video segments are cached separately according to the camera channel. When exporting video segments, the alarm time is traced back to the most recent key frame, and the video content from X seconds before the alarm time to Y seconds after the alarm time is exported, where X+Y is not less than the preset evidence collection time. The preset evidence collection time is no less than 10 seconds, and the ring cache is at least partially built in the server memory. When the memory usage reaches the threshold, the earlier video segments will be eliminated or transferred to the disk or object storage.

9. The video surveillance computing power dynamic allocation cascade detection method based on prior knowledge-driven method according to claim 1, characterized in that: The confirmation result in step S4 includes at least one of three categories: valid alarm, false alarm, and indeterminate. The confirmation result is associated with the operation type, camera channel, violation attribute category, and time window and stored for subsequent threshold optimization, sample screening, or model update.

10. The video surveillance computing power dynamic allocation cascade detection method based on prior knowledge-driven method according to claim 1, characterized in that: In step S3, the ROI is obtained by expanding the human bounding box by an outward expansion ratio. The outward expansion ratio is adaptively determined based on the size of the human bounding box and the target motion amplitude, and the ROI is scaled to the input scale of the secondary model.