Law enforcement place management supervision method and system based on deep learning

By applying deep learning-based computer vision technology in law enforcement sites, real-time monitoring of behaviors in law enforcement sites and identification and early warning of violations, the problems of insufficient transparency and irregular management in the existing technology are solved, and the transparency and legality of law enforcement management are improved.

CN119888622AActive Publication Date: 2025-04-25CHINA UNIV OF PETROLEUM (EAST CHINA)

Patent Information

Application Number
CN202510049371.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-13
Publication Date
2025-04-25
Estimated Expiration
2045-01-13

AI Technical Summary

Technical Problem

The supervision and management of existing law enforcement sites are inadequate transparency, irregular management, aging of monitoring equipment and low manual supervision efficiency, making it difficult to achieve real-time and accurate analysis of the behavior of law enforcement sites.

Method used

Adopt deep learning-based law enforcement site management and supervision methods and systems, and through computer vision technology and deep learning models, real-time monitoring of law enforcement sites, identification and early warning of violations are achieved. Specific plans include collecting law enforcement process data, using the improved Dense-MobileFaceNet network for face recognition, and using the improved YOLOv7-tiny network for target recognition and abnormal behavior recognition.

Benefits of technology

It improves the transparency and legality of law enforcement management, realizes intelligent monitoring and real-time early warning of the behavior of personnel in the law enforcement venues, and ensures the standardization and safety of the law enforcement process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119888622A_ABST
    Figure CN119888622A_ABST
Patent Text Reader

Abstract

The invention relates to a law enforcement place management supervision method and system based on deep learning. The method comprises the following steps: collecting law enforcement process data in a law enforcement place; based on the law enforcement process data, performing face recognition by using a face recognition model; wherein the face recognition model is constructed on the basis of an improved Dense-Mobile FaceNet network, and the face recognition model is constructed on the basis of the improved Dense-Mobile FaceNet network; performing target recognition on the data after face recognition by using a target recognition model, and recognizing an abnormal behavior in a law enforcement process; wherein the target identification model is constructed on the basis of an improved YOLOv7-tiny network. According to the invention, real-time monitoring, illegal behavior identification and early warning in a law enforcement place can be realized, and transparency and legality of law enforcement management are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer vision technology, and in particular to a method and system for managing and supervising law enforcement sites based on deep learning. Background Art

[0002] The supervision and management of existing law enforcement sites usually rely on manual inspections and video surveillance. However, due to the aging of monitoring equipment and low efficiency of manual supervision, the law enforcement process has problems such as lack of transparency and irregular management. Traditional supervision methods make it difficult to conduct real-time and accurate analysis of the behavior of the entire law enforcement site and fail to detect violations in a timely manner. To solve this problem, the introduction of deep learning technology can greatly improve the efficiency and accuracy of supervision and reduce the errors of manual supervision. Summary of the invention

[0003] The purpose of the present invention is to provide a method and system for the management and supervision of law enforcement sites based on deep learning, so as to solve the problems existing in the above-mentioned prior art. With the help of computer vision technology and deep learning models, real-time monitoring, identification and early warning of violations in law enforcement sites can be achieved, thereby improving the transparency and legality of law enforcement management.

[0004] In the first aspect, to achieve the above-mentioned object, the present invention provides the following solutions:

[0005] The management and supervision method of law enforcement sites based on deep learning includes:

[0006] Collect law enforcement process data in law enforcement venues;

[0007] Based on the law enforcement process data, face recognition is performed using a face recognition model; wherein the face recognition model is constructed based on an improved Dense-MobileFaceNet network;

[0008] The target recognition model is used to perform target recognition on the data after face recognition to identify abnormal behaviors in the law enforcement process; wherein the target recognition model is built based on the improved YOLOv7-tiny network.

[0009] Optionally, collecting law enforcement process data in the law enforcement venue includes:

[0010] Collect video data of the law enforcement process in law enforcement venues;

[0011] Separate key frames from video data, automatically generate samples, use deep convolutional neural networks to preprocess video frames, and extract high-quality image data;

[0012] The low-light enhancement algorithm based on deep learning extracts the semantic feature areas in the image through the semantic segmentation model and performs local contrast adjustment.

[0013] Optionally, improving the Dense-MobileFaceNet network includes:

[0014] The CycleGAN network is added as a modality conversion module to the input of the Dense-MobileFaceNet network, and the input infrared image is processed into a visible light image before being input into the Dense-MobileFaceNet network for recognition. CycleGAN is trained using a dual-light face dataset.

[0015] The ArcFace loss function is used in the training process of the Dense-MobileFaceNet network.

[0016] Optionally, improve the YOLOv7-tiny network by:

[0017] An enhanced pyramid segmentation attention mechanism is added after the ELAN layers of different scales in the backbone network of the YOLOv7-tiny network;

[0018] The enhanced pyramid segmentation attention mechanism is added again to the Neck part of the YOLOv7-tiny network to strengthen the feature network;

[0019] The processing process of the enhanced pyramid segmentation attention mechanism is:

[0020] Z i =SEWeight(F i ),i=0,1,2,…,S-1,

[0021]

[0022] Out=Cat([Y 0 , Y 1 , …, Y S-1 ]),

[0023] Among them, Z i The weight vector representing the feature map channel attention, att i It represents the normalized weighting process of Softmax on the channel attention feature weight, Out is the feature map obtained by the final output, SEWeight(F i ) indicates that the Squeeze-and-Excitation (SE) attention module is used to perform channel-level weighted processing on the feature Fi, i indicates the index of the feature map Fi, i.e., the i-th feature map, Softmax(Z i) represents the application of the Softmax function to the vector Zi. The Softmax function is usually used to convert a vector into a probability distribution so that each element in the vector is between 0 and 1, and the sum of all elements is 1. i represents the channel weight vector of the i-th feature map Fi calculated by the SE attention module, S represents the number of groups into which the input feature map X is split by the SPC (Split Pyramid Convolution) module, and Y S-1 Represents the last feature map after the attention mechanism is processed. Cat() represents the concatenation operation of the feature map, which merges multiple feature maps into a new feature map along a certain dimension (usually the channel dimension).

[0024] During the training process of the YOLOv7-tiny network, SIoU Loss is used as the positioning loss function of the YOLOv7-tiny network.

[0025] Optionally, identifying abnormal behavior during law enforcement includes:

[0026] Based on the recognition result of the target recognition model, the violation index is calculated using a preset violation index calculation model;

[0027] According to the violation index, different levels of warning push are carried out;

[0028] The violation index calculation model is:

[0029]

[0030] Among them, S i represents the severity score of the behavior, Fi represents the behavior frequency factor, and W i represents the identity weight of the person, T i Represents the time weight factor, R represents the site risk correction value, n represents the total types of illegal and irregular behavior, and i represents a certain type of illegal and irregular behavior.

[0031] In the second aspect, to achieve the above-mentioned purpose, the present invention also provides the following scheme:

[0032] A law enforcement site management and supervision system based on deep learning, the system comprising: a data acquisition module, a data processing module, a face recognition module, a target recognition module, a report generation module, a confidentiality transmission module and an edge computing module;

[0033] The data collection module is used to collect law enforcement process data in the law enforcement site;

[0034] The data processing module is used to perform data enhancement processing on the law enforcement process data;

[0035] The face recognition module is used to perform face recognition on the enhanced law enforcement process data using a face recognition model; wherein the face recognition model is constructed based on an improved Dense-MobileFaceNet network;

[0036] The target recognition module is used to use the target recognition model to perform target recognition on the data after face recognition and identify abnormal behavior in the law enforcement process; wherein the target recognition model is constructed based on the improved YOLOv7-tiny network;

[0037] The report generation module is used to generate a report on the identified abnormal behavior;

[0038] The transmission module is used to encrypt data transmission between modules by adopting single sign-on and a transmission mechanism based on hash-salted encryption;

[0039] The edge computing module is used to adopt edge computing methods for the data acquisition module, data processing module, face recognition module, and target recognition module.

[0040] Optionally, the data processing module:

[0041] Separate key frames from video data, automatically generate samples, use deep convolutional neural networks to preprocess video frames, and extract high-quality image data;

[0042] The low-light enhancement algorithm based on deep learning extracts the semantic feature areas in the image through the semantic segmentation model and performs local contrast adjustment.

[0043] Optionally, improving the Dense-MobileFaceNet network includes:

[0044] The CycleGAN network is added as a modality conversion module to the input of the Dense-MobileFaceNet network, and the input infrared image is processed into a visible light image before being input into the Dense-MobileFaceNet network for recognition. CycleGAN is trained using a dual-light face dataset.

[0045] The ArcFace loss function is used in the training process of the Dense-MobileFaceNet network.

[0046] Optionally, improve the YOLOv7-tiny network by:

[0047] An enhanced pyramid segmentation attention mechanism is added after the ELAN layers of different scales in the backbone network of the YOLOv7-tiny network;

[0048] The enhanced pyramid segmentation attention mechanism is added again to the Neck part of the YOLOv7-tiny network to strengthen the feature network;

[0049] The processing process of the enhanced pyramid segmentation attention mechanism is:

[0050] Z i =SEWeight(F i ),i=0,1,2,…,S-1,

[0051]

[0052] Out=Cat([Y 0 , Y 1 , …, Y S-1 ]),

[0053] Among them, Z i The weight vector representing the feature map channel attention, att i It represents the normalized weighting process of Softmax on the channel attention feature weight, Out is the feature map obtained by the final output, SEWeight(F i ) indicates that the Squeeze-and-Excitation (SE) attention module is used to perform channel-level weighted processing on the feature Fi, i indicates the index of the feature map Fi, i.e., the i-th feature map, Softmax(Z i ) represents the application of the Softmax function to the vector Zi. The Softmax function is usually used to convert a vector into a probability distribution so that each element in the vector is between 0 and 1, and the sum of all elements is 1. i represents the channel weight vector of the i-th feature map Fi calculated by the SE attention module, S represents the number of groups into which the input feature map X is split by the SPC (Split Pyramid Convolution) module, and Y S-1 Represents the last feature map after the attention mechanism is processed. Cat() represents the concatenation operation of the feature map, which merges multiple feature maps into a new feature map along a certain dimension (usually the channel dimension).

[0054] During the training process of the YOLOv7-tiny network, SIoU Loss is used as the positioning loss function of the YOLOv7-tiny network.

[0055] Optionally, identifying abnormal behavior during law enforcement includes:

[0056] Based on the recognition result of the target recognition model, the violation index is calculated using a preset violation index calculation model;

[0057] The violation index calculation model is:

[0058]

[0059] Among them, S i Indicates the severity score of the behavior, F i represents the behavior frequency factor, W i represents the identity weight of the person, T i Represents the time weight factor, R represents the site risk correction value, n represents the total types of illegal and irregular behavior, and i represents a certain type of illegal and irregular behavior.

[0060] In a third aspect, the present invention further provides: an electronic device comprising a memory and a processor, wherein the memory stores a computer program that can be run on the processor, and when the processor executes the computer program, it implements the steps of the method described in the first aspect or any possible implementation method of the first aspect.

[0061] In a fourth aspect, the present invention further provides: a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method described in the first aspect or any possible implementation of the first aspect are implemented.

[0062] The beneficial effects of the present invention are:

[0063] The present invention first collects the law enforcement process data in the law enforcement site; secondly, based on the law enforcement process data, the face recognition model is used to perform face recognition; then the target recognition model is used to perform target recognition on the data after face recognition to identify abnormal behaviors in the law enforcement process. The present invention realizes intelligent monitoring and real-time early warning of the behavior of personnel in the law enforcement site through image preprocessing technology and deep learning models. The system can identify and monitor behaviors such as not wearing police uniforms, illegal use of mobile phones, illegal smoking, etc., to ensure the standardization and legality of the law enforcement process. BRIEF DESCRIPTION OF THE DRAWINGS

[0064] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0065] Figure 1 This is a flow chart of a method for managing and supervising law enforcement sites based on deep learning according to an embodiment of the present invention. DETAILED DESCRIPTION

[0066] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0067] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.

[0068] like Figure 1 As shown, this embodiment proposes a law enforcement site management and supervision method based on deep learning, including:

[0069] Collect law enforcement process data in law enforcement venues;

[0070] Based on the law enforcement process data, face recognition is performed using a face recognition model; the face recognition model is built based on an improved Dense-MobileFaceNet network;

[0071] The target recognition model is used to perform target recognition on the data after face recognition to identify abnormal behaviors in the law enforcement process; the target recognition model is built based on the improved YOLOv7-tiny network.

[0072] Furthermore, the law enforcement process data collected in the law enforcement venue includes:

[0073] Collect video data of the law enforcement process in law enforcement venues;

[0074] Separate key frames from video data, automatically generate samples, use deep convolutional neural networks to preprocess video frames, and extract high-quality image data;

[0075] The low-light enhancement algorithm based on deep learning extracts the semantic feature areas in the image through the semantic segmentation model and performs local contrast adjustment.

[0076] Specifically, in this embodiment, the data acquisition business usually covers two core links: human-involved collection and automated collection technology. The human-involved collection link involves directly capturing raw visual data through manual photography, and then applying precise annotations to these data through manual means to ensure the quality of the data and the accuracy of the labels. On the other hand, automated collection relies on the initial weights of the pre-trained model to perform intelligent data screening and preprocessing operations, significantly improving the efficiency and scale of data processing. The data collection process is as follows: Figure 1 shown.

[0077] The image processing in this embodiment is as follows:

[0078] The collected images are preprocessed using an image enhancement algorithm under non-uniform lighting conditions. A deep learning-based image enhancement model is used to improve the image quality under low illumination and enhance image details through semantic-guided image enhancement technology, thereby improving the accuracy of subsequent recognition modules.

[0079] Sample generation and frame extraction: Separate key frames from the video stream, automatically generate samples, use deep convolutional neural networks to perform preliminary processing on video frames, and extract high-quality images for model training and real-time monitoring.

[0080] Image enhancement technology: A low-light enhancement algorithm based on deep learning extracts semantic feature areas in the image through a semantic segmentation model and performs local contrast adjustment to ensure image clarity in low-light environments.

[0081] Further improvements to the Dense-MobileFaceNet network include:

[0082] The CycleGAN network is added as a modality conversion module to the input of the Dense-MobileFaceNet network, and the input infrared image is processed into a visible light image before being input into the Dense-MobileFaceNet network for recognition. CycleGAN is trained using a dual-light face dataset.

[0083] The ArcFace loss function is used in the training process of the Dense-MobileFaceNet network.

[0084] Specifically, in this embodiment, an improved Dense-MobileFaceNet network is used for face recognition, which particularly optimizes the recognition capability of small targets and blurred faces, and supports face detection under infrared imaging.

[0085] Fuzzy small target face detection: By introducing the lightweight Dense-MobileFaceNet network, the computing power consumption is reduced while the accuracy of face recognition is improved. The system combines the ArcFace loss function to accurately distinguish different people and reduce misjudgment.

[0086] Infrared imaging recognition: CycleGAN is used to generate an adversarial network to convert infrared imaging into visible light images, and then the improved MobileFaceNet model is used for face recognition, solving the problem of difficult recognition in low-light environments at night.

[0087] Specifically, in this embodiment, recognizing a face through a face recognition model includes:

[0088] Police information entry: Clearly record the key information fields of police officers, including the police officer’s name, gender, ID number, contact information and other important information, and then establish a complete and reliable information database.

[0089] The facial images of police officers are collected by combining cameras with Python scripts to ensure that the camera's resolution and shooting conditions meet the requirements of face detection and recognition to ensure image quality and accuracy. During the implementation process, an efficient and stable facial image acquisition system is developed by calling the camera's API or using the OpenCV library in Python to ensure that the collected facial images can be reliably matched and recognized in the subsequent face recognition process.

[0090] Shooting conditions: (a) The background of the picture must be pure white and the lighting conditions must be good. (b) The person must be bareheaded and dressed properly. (c) If the person does not wear glasses, only 8 photos are required. (d) If the person wears glasses, two groups of photos are required (a total of 16 photos with and without glasses). (e) The person's facial features must be clearly visible. File upload instructions: One folder per person, named after the police officer's name.

[0091] Data correction: Use a variety of face detection technologies, such as the classic Haar cascade detector and deep learning-based face detection algorithms, to cope with different scenarios and situations, to ensure that faces are accurately located in images captured by the camera. These technologies can accurately locate the position of the face in the image, providing accurate basic information for subsequent processing steps.

[0092] After completing face detection, this embodiment will align the detected faces to ensure that the facial features are in a consistent position and scale in the image. By locating key points such as eyes and nose, the faces are fine-tuned to make their position and size in the image consistent, thereby providing more accurate data for subsequent face recognition and analysis.

[0093] By integrating different detection and alignment technologies, a complete face information processing process is established to provide reliable face recognition and feature extraction functions for the police information management system.

[0094] Facial feature extraction: Using an efficient facial feature extraction algorithm, the aligned facial images are converted into a set of unique numerical feature vectors. These feature vectors will reflect the key features of the face in different dimensions, such as contour, texture, structure, etc., thereby converting the complex information of the face into a data representation that can be understood by the machine.

[0095] By converting facial images into feature vectors, efficient extraction and comparison of facial features can be achieved. This numerical representation can reduce the dimension of the data, improve computing efficiency, and reduce storage and transmission costs, and serves as the core data for subsequent comparison and recognition tasks.

[0096] Police information labeling: Detailed data labeling is performed on the extracted characteristic police face data, and specific label information is added to each face image to accurately mark the police information to which it belongs. During the labeling process, a name, work number or other unique identifier is added to each image to ensure that each face is associated with a specific police information.

[0097] Establish a sample library: The extracted facial feature vectors are closely combined with the corresponding police information and stored in a special sample library. You can choose to use the CSV (comma separated value) file format for storage. In this sample library, each row will contain a facial feature vector and the corresponding police information, such as name, work number, etc. Such a structure will provide an orderly and easy-to-manage data storage method for subsequent face recognition and query tasks.

[0098] Sample library division: In order to effectively train, adjust and evaluate the model, the sample library is reasonably divided into three parts according to appropriate proportions: training set, validation set and test set.

[0099] The training set occupies the majority of the sample library and is used for model training. By iteratively optimizing the training set, the model will learn the association between the facial feature vector and the corresponding police information, thereby improving the accuracy and reliability of recognition.

[0100] The validation set will be used to adjust the model's hyperparameters, such as learning rate, batch size, etc. By testing and comparing on the validation set, the best hyperparameter combination can be selected to improve the performance and generalization ability of the model.

[0101] The test set will be used to comprehensively evaluate the performance of the model. At this stage, the model is tested using samples on the test set to evaluate its accuracy and effectiveness in practical applications. By evaluating the performance on the test set, this embodiment can determine whether the model has achieved the expected performance level and whether it can demonstrate robustness in different situations.

[0102] This division of the sample library will provide orderly data support for model training and evaluation, ensuring that model training, adjustment and evaluation can be carried out in a targeted manner.

[0103] The face recognition process is shown below.

[0104] (1) Loading the dataset

[0105] Use PyTorch's Dataset and DataLoader to load and preprocess data, and split it into training sets and validation sets.

[0106] (2) Normalization

[0107] Normalize image pixel values ​​to the interval [0,1] or [1,1].

[0108] (3) Model building

[0109] (a) Load the Dense-MobileFaceNet model:

[0110] Use the Dense-MobileFaceNet model introduced by the team, and add a custom fully connected layer based on this model to adapt to specific classification tasks. Initialize the model parameters to ensure that the model is in a suitable state before starting training.

[0111] (b) Define the ArcFace loss function:

[0112] Customize the ArcFace loss function, including the constraints of the angle boundaries. Select the appropriate optimization algorithm and learning rate, and configure the optimizer to adjust the model parameters to minimize the loss function.

[0113] (4) Training model

[0114] The training model phase is the most important part of the entire process, which involves multiple iterations of optimizing the model parameters to make it fit the training data better. Operations in this phase include:

[0115] Iterative training: The model is trained multiple times using the data in the training set, and each iteration is called an epoch.

[0116] Calculate loss: In each epoch, calculate the loss between the current model's prediction of the training data and the true label.

[0117] Backpropagation and optimization: Based on the gradient of the loss function, the model parameters are updated using the backpropagation algorithm to optimize the model to reduce the loss.

[0118] Monitor the training process: Track the loss changes and model performance during training so that you can adjust hyperparameters and model structure in a timely manner.

[0119] (5) Save the best model:

[0120] The best model weights are saved during training.

[0121] Through the above steps, this embodiment uses PyTorch and Dense-MobileFaceNet to train the face recognition model, and uses the ArcFace loss function to improve the model's discrimination ability. This process ensures that the model can efficiently and accurately identify the faces of police officers in the Public Security Bureau and is suitable for actual application scenarios.

[0122] Further improvements to the YOLOv7-tiny network include:

[0123] An enhanced pyramid segmentation attention mechanism is added after the ELAN layers of different scales in the backbone network of the YOLOv7-tiny network;

[0124] The enhanced pyramid segmentation attention mechanism is added again to the Neck part of the YOLOv7-tiny network to strengthen the feature network;

[0125] During the training process of the YOLOv7-tiny network, SIoU Loss is used as the positioning loss function of the YOLOv7-tiny network.

[0126] Specifically, in this embodiment, target recognition is performed based on an improved version of the YOLOv7-tiny algorithm, which can quickly identify specific targets such as police uniforms and perform behavior detection.

[0127] Police uniform recognition: The system improves its ability to recognize details by introducing an enhanced pyramid segmentation attention mechanism, and can monitor in real time whether the police are dressed in standard attire, such as whether they are wearing police numbers, armbands, etc.

[0128] Violation detection: Through posture estimation and target recognition, the system can monitor changes in people's posture, such as whether law enforcement officers use mobile phones, smoke, and engage in other inappropriate behaviors during the investigation.

[0129] Specifically, in this embodiment, the target recognition process includes:

[0130] 1. Sample library sample project, the process is as follows:

[0131] (1) Data cleaning

[0132] Ensure the accuracy and completeness of the data, adopt a series of effective data processing strategies, and deal with missing values, outliers, and erroneous values ​​in the data.

[0133] For missing values, appropriate methods are used to fill or interpolate to ensure data integrity. By analyzing the characteristics of the data, appropriate filling methods are selected, or interpolation is performed through model prediction to maintain data accuracy and continuity.

[0134] For outliers, anomaly detection and processing will be performed. Through statistical analysis or machine learning methods, possible outliers are identified and verified and corrected according to actual conditions. Outliers may be caused by data entry errors or other abnormal situations. Appropriate strategies such as correcting, deleting or marking outliers are adopted to ensure the reliability and authenticity of the data.

[0135] Perform data validation and logic checks on erroneous values ​​to ensure the internal consistency and correctness of the data. By establishing data validation rules, illogical data can be excluded and corrected or checked in a timely manner to reduce the impact of data errors and ensure the credibility and accuracy of the data.

[0136] (2) Feature Engineering

[0137] To meet the needs of face recognition, joint interrogation, and clothing judgment, a series of targeted feature engineering steps are performed to optimize model performance and generalization capabilities.

[0138] First, feature selection screens out features that have a significant impact on face recognition, joint interrogation, and clothing judgment. By analyzing the requirements of different tasks, features closely related to the tasks are selected, and redundant or irrelevant features are eliminated to streamline the data and improve the efficiency of the model.

[0139] Secondly, feature transformation is performed to map the original features to a more meaningful representation space, which involves dimensionality reduction techniques such as principal component analysis (PCA) or linear discriminant analysis (LDA) to reduce feature dimensions and extract main information. Through feature transformation, data noise can be reduced, model stability can be enhanced, and performance can be improved.

[0140] Finally, feature extraction is performed according to the needs of different tasks to extract higher-level abstract features from the data in order to capture more discriminative features, thereby improving the generalization ability and performance of the model.

[0141] (3) Data Integration

[0142] Different data from various police stations will be collected, including relevant data such as face recognition, joint interrogation and clothing judgment. These data are scattered in different databases, folders or systems. Using data integration tools and technologies, they will be integrated in an orderly manner to facilitate subsequent analysis and modeling work.

[0143] 2. Joint interrogation warning

[0144] The interrogation process is an important part of law enforcement and case handling. Its standardization and fairness are directly related to the trial results and judicial credibility of the case. This system uses artificial intelligence technology to conduct all-round supervision of the interrogation process to ensure the legality and standardization of the interrogation.

[0145] 1. Single police officer inquiries about violations

[0146] (a) Face Detection

[0147] Face detection is performed on frame images captured from the video stream in order to accurately identify and locate all faces in the image. In the frame image, the face detection algorithm is applied to find the position of the face and obtain the coordinate information of the face in the image, including the coordinates of the upper left and lower right corners of the face. The coordinate information can determine the position and size of the face in the image.

[0148] (b) Face matching

[0149] Use the constructed sample library data to perform face comparison to determine the identity of the recognized face. By comparing the similarity scores, find the facial features in the sample library that are most similar to the recognized facial features to determine their possible identities. If the similarity score reaches the set threshold, it can be determined that the recognized face matches the facial information of a police officer, thereby determining their identity.

[0150] (c) Face counting

[0151] After completing the face detection, the number of faces detected is counted, and based on the number, it is determined whether there are at least two faces. If there are less than two faces for more than 10 minutes, it is determined to be a violation of the single police questioning.

[0152] 2. Timeout violation

[0153] This process is relatively simple. The system sets a counter for each round of interrogation according to the preset interrogation time limit to automatically monitor the interrogation duration. When the interrogation time exceeds the preset time, the system will automatically record and issue an early warning to remind the police to end the interrogation in time to avoid excessive questioning that may cause physical and mental harm to the suspect.

[0154] 3. Warning of non-compliance by law enforcement entities

[0155] 1. Judging the police uniform

[0156] (1) Introduction to YOLOv7 algorithm

[0157] The YOLOv7 target detection algorithm was launched by the v4 author in July 2022. It is a very novel and excellent detector. Compared with the previous YOLO series, it uses an efficient aggregation network, that is, the EAN module that appears in the network structure, which effectively enhances the network learning ability. On the other hand, YOLOv7 uses re-parameterized convolution to accelerate the network while ensuring model performance. At the same time, adjustments are also made in the auxiliary head detection, extracting the shallow features of the head network as the auxiliary head and the deep network as the guide head. Finally, YOLOv7 combines the common advantages of YOL0v5 and YOLOX and adopts a dynamic label allocation strategy.

[0158] The YOLOv7-tiny network model structure is divided into four parts: Input, Backbone, Neck and Head. The input part uses mosaic data enhancement and adaptive anchor frame calculation to preprocess the input image; the Backbone part is composed of several CBS blocks, ELAN layers and MP layers. The CBS block is composed of Conv layer, BN layer and SiLU function, and the ELAN layer is composed of multiple CBS modules. The MP layer is composed of CBS blocks and Maxpool respectively; the Neck part uses SPPCSPC and PAN structures to fuse the features of each layer to detect targets of different scales. The structural connection is composed of CBS module, MP layer, SPPCSPC module and ELAN+. The SPPCSPC module connects Backbone and Neck, which is composed of multiple CBS modules and 3 Maxpools. The difference between ELAN+ and ELAN is only the number of outputs selected during the connection process of the CBS module. The head part uses REP layer and CBM block. The grid structure of REP module is different during training and inference, and the CBM module is composed of Conv layer, BN layer and Sigmoid number. In the head layer stage, the output image is passed through 3 REP layers and CBM layers to output 3 prediction results of different scales.

[0159] (2) Attention Mechanism - EPSANet Block Module

[0160] The attention mechanism focuses on the important position of the target: thus obtaining its key information. This method plays a huge role in the field of deep learning. PSA pyramid split attention is a more efficient dual attention mechanism. For the input features, the PSA attention mechanism first splits them through the SPC module. SPC divides the input tensor X into S groups, each of which is named X 0 -X s-1 Then, all the features extracted from the S groups are concatenated to extract the target information in each channel feature map. The extraction process is shown in equations (1) to (3):

[0161] F i =Conv(K i ×K i , G i )(X) i=0,1,2,...S-1, (1)

[0162]

[0163] F=Cat([F 0 , F 1 , ..., F s-1 ]), (3)

[0164] Where: k is the size of the multi-scale convolution kernel, G is the size of the group, and F is the feature map obtained after splicing.

[0165] After SPC splitting, the feature map F is obtained, which is passed through the SE attention module to identify the key areas of each channel feature, and further obtain the feature weights of these channels. Finally, the Softmax normalization weight is used to weight each group of feature weights to further obtain the final output. The entire principle process is shown in equations (4) to (6):

[0166] Z i =SEWeight(F i ), i=0, 1, 2,…, S-1, (4)

[0167]

[0168] Out=Cat([Y 0 , Y 1 , …, Y S-1 ]), (6)

[0169] Where: Z i Represents the weight vector of the feature map channel attention, att i It represents the normalized weighting process of Softmax on the weight of the channel attention feature, and Out is the feature map obtained by the final output. Based on the PSA attention mechanism, combined with the classic residual network model Resnet, the 3x3 convolution of the BottleNeck part of its module is replaced with the PSA module, thus forming a new EPSABlock. The EPSA module is based on the idea of ​​channel attention and has the ability to extract features of different scales, and is flexible and efficient.

[0170] In order to accurately detect police uniform targets of various sizes in a complex background environment of the Public Security Bureau and improve the accuracy of police uniform recognition, the improvement strategy of this embodiment is to add an EPSA Block after the ELAN layer of different scales in the backbone network of the YOLOv7-tiny network model to optimize the network structure and accurately identify three types of targets of near, medium and far sizes. Then, EPSA Block is added again to the Neck part of the enhanced feature network to improve the network's ability to perceive feature maps, thereby improving the detection effect of YOLOv7-tiny for helmet wearing.

[0171] (3) Loss Function

[0172] The YOLOv7-tiny loss function includes three parts: confidence prediction loss, category loss, and positioning loss. Our team does not change the first two loss functions of YOLOv7-tiny, and still uses the meta-cross entropy loss function in the original network. For positioning loss, the original YOLOv7-tiny uses CIoU Loss, that is:

[0173]

[0174] Where: is the penalty term, b and b gt Represents B and B gt The center point, ρ 2 is the Euclidean distance, c is the distance between B and B gt The diagonal distance of the minimum outer rectangle of the prediction box, α is a positive balance parameter, and v represents the consistency with the aspect ratio of the prediction box. For parameters α and v, there are:

[0175]

[0176] Where: w and w gt Indicates the width of B and G, h and h gt Indicates the height of B and G.

[0177] Compared with CIoU Loss, SIoU Loss not only takes into account geometric parameters such as overlapping area, center point distance and aspect ratio, but more importantly, based on the above, SIoU Loss also considers angle parameters and the vector angle between the required regressions, redefining the penalty index. Therefore, this embodiment uses SIoULoss as the positioning loss function of YOLOv7-tiny:

[0178]

[0179] Since this loss also takes the direction box angle into consideration, the prediction box regression becomes stable, while also speeding up the convergence speed and optimizing the regression effect.

[0180] Specifically, in this embodiment, identifying abnormal behavior during law enforcement includes:

[0181] Based on the recognition result of the target recognition model, the violation index is calculated using a preset violation index calculation model;

[0182] According to the violation index, different levels of warning push are carried out.

[0183] In this embodiment, a violation index calculation model is preset as follows:

[0184]

[0185] Among them, S i represents the severity score of the behavior, Fi represents the behavior frequency factor, and W i represents the identity weight of the person, T i Represents the time weight factor, R represents the site risk correction value, n represents the total types of illegal and irregular behavior, and i represents a certain type of illegal and irregular behavior.

[0186] Severity score of the violation Si:

[0187] Define the behavior type and corresponding score:

[0188] Set multiple types of illegal and irregular behaviors i = {1, 2, ..., n}, and give each behavior a severity score based on its impact on the fairness and security of law enforcement.

[0189] For example: interrogation timeout: S = 10, unauthorized entry into key areas: S = 7, absence from duty: S = 5, illegal smoking: S = 3 Dynamic adjustment score: Consider the situation when the behavior occurs and add dynamic adjustment factors. For example:

[0190] If the behavior occurs in a high-risk area (such as an interrogation room): the score is increased by 20%.

[0191] formula:

[0192] S i =Base score, (1+adjustment factor).

[0193] Frequency factor Fi

[0194] The behavior frequency factor measures the frequency of a certain type of behavior during a specific monitoring period. The specific calculation method is as follows:

[0195]

[0196] Specific rules:

[0197] Low Frequency Behavior: Set the Lowest Frequency Factor to 1.

[0198] High-frequency behavior: The frequency factor increases linearly with the number of times, but an upper limit Fmax is set to avoid excessive weight.

[0199] Example:

[0200] If a behavior occurs 5 times within 8 hours:

[0201]

[0202] Personnel identity weight Wi

[0203] In law enforcement venues, the impact of different people's behaviors may be different, so the person identity weight is introduced. The weight setting reference is as follows:

[0204] Law enforcement officers: Weight W = 2 (their behavior directly affects the fairness of law enforcement).

[0205] Subject of law enforcement: Weight W = 1.5 (behavior may lead to law enforcement risks).

[0206] Third party (such as guardian, etc.): weight W=1.

[0207] If the identity of the personnel is sensitive (such as law enforcement officers on duty or on special missions), additional adjustment factors may be added:

[0208] W i = basic weight × (1 + identity adjustment coefficient)

[0209] Example:

[0210] If a law enforcement officer violates discipline during a sensitive period, the weight will be adjusted to:

[0211] W = 2 × (1 + 0.3) = 2.6

[0212] 5. Site risk correction value R

[0213] According to the specific functions and risk levels of the law enforcement sites, set the correction value RRR and correct the violation index. The risk levels are divided into three levels: low, medium and high:

[0214] Low-risk places (such as ordinary office areas): R=0.

[0215] Medium-risk places (such as interrogation rooms): R=5.

[0216] High-risk places (such as gun vaults): R=10.

[0217] Specific corrections:

[0218] R = risk factor × number of regional events

[0219] Time weight factor Ti

[0220] The time period during which law enforcement occurs has a significant impact on the risk of violation. For example, nighttime law enforcement or shift change periods are more likely to result in management loopholes, so a time weight Ti is added to reflect time risk.

[0221] Weight rules:

[0222] High-risk time period (such as 0:00-6:00 in the morning): T = 2.0.

[0223] Medium-risk time period (such as after-work hours 18:00-23:59): T=1.5.

[0224] Low-risk time period (such as daytime working hours 6:00-18:00): T = 1.0.

[0225] Dynamic adjustment mechanism:

[0226] For some special periods, risk weights can be adjusted dynamically. For example:

[0227] Approaching shift change time (e.g. within 15 minutes): weighting increases by 10%.

[0228] Major holidays or special law enforcement mission times: weight increased by 20%.

[0229] formula:

[0230] T i = basic weight × (1 + adjustment coefficient)

[0231] Threshold determination of violation index

[0232] Set thresholds based on the violation index results to determine whether there is a risk of violation at the law enforcement site:

[0233] Violation index <T1: Risk is controllable and no warning is required.

[0234] T1≤Violation Index<T2: The risk is high and warning is required.

[0235] Violation index ≥ T2: serious violation, requiring immediate action.

[0236] Example thresholds:

[0237] T1=20 (low risk).

[0238] T2=50 (high risk).

[0239] Early warning mechanism

[0240] If the violation index exceeds T2, the system generates a red warning signal and pushes it to the management personnel.

[0241] If the index is between T1 and T2, a yellow warning signal is generated, prompting a directional inspection.

[0242] This implementation also proposes a law enforcement venue management and supervision system based on deep learning, including: data collection module, data processing module, face recognition module, target recognition module, report generation module, confidentiality transmission module and edge computing module;

[0243] A data collection module is used to collect law enforcement process data in law enforcement sites;

[0244] A data processing module is used to perform data enhancement processing on law enforcement process data;

[0245] The face recognition module is used to perform face recognition on the enhanced law enforcement process data using the face recognition model; wherein the face recognition model is constructed based on the improved Dense-MobileFaceNet network;

[0246] The target recognition module is used to use the target recognition model to perform target recognition on the data after face recognition and identify abnormal behaviors in the law enforcement process; the target recognition model is built based on the improved YOLOv7-tiny network;

[0247] A report generation module is used to generate reports on identified abnormal behaviors;

[0248] The confidentiality transmission module is used to encrypt data transmission between modules using single sign-on and a transmission mechanism based on hash-salted encryption;

[0249] The edge computing module is used to adopt edge computing methods for the data acquisition module, data processing module, face recognition module, and target recognition module.

[0250] Furthermore, the data processing module:

[0251] Separate key frames from video data, automatically generate samples, use deep convolutional neural networks to preprocess video frames, and extract high-quality image data;

[0252] The low-light enhancement algorithm based on deep learning extracts the semantic feature areas in the image through the semantic segmentation model and performs local contrast adjustment.

[0253] Further improvements to the Dense-MobileFaceNet network include:

[0254] The CycleGAN network is added as a modality conversion module to the input of the Dense-MobileFaceNet network, and the input infrared image is processed into a visible light image before being input into the Dense-MobileFaceNet network for recognition. CycleGAN is trained using a dual-light face dataset.

[0255] The ArcFace loss function is used in the training process of the Dense-MobileFaceNet network.

[0256] Further improvements to the YOLOv7-tiny network include:

[0257] An enhanced pyramid segmentation attention mechanism is added after the ELAN layers of different scales in the backbone network of the YOLOv7-tiny network;

[0258] The enhanced pyramid segmentation attention mechanism is added again to the Neck part of the YOLOv7-tiny network to strengthen the feature network;

[0259] The processing process of the enhanced pyramid segmentation attention mechanism is:

[0260] Z i =SEWeight(F i ),i=0,1,2,…,S-1,

[0261]

[0262] Out=Cat([Y 0 , Y 1 , …, Y S-1 ]),

[0263] Among them, Z i The weight vector representing the feature map channel attention, att i It represents the normalized weighting process of Softmax on the channel attention feature weight, Out is the feature map obtained by the final output, SEWeight(F i ) indicates that the Squeeze-and-Excitation (SE) attention module is used to perform channel-level weighted processing on the feature Fi, i indicates the index of the feature map Fi, i.e., the i-th feature map, Softmax(Z i ) represents the application of the Softmax function to the vector Zi. The Softmax function is usually used to convert a vector into a probability distribution so that each element in the vector is between 0 and 1, and the sum of all elements is 1. i represents the channel weight vector of the i-th feature map Fi calculated by the SE attention module, S represents the number of groups into which the input feature map X is split by the SPC (Split Pyramid Convolution) module, and Y S-1 Represents the last feature map after the attention mechanism is processed. Cat() represents the concatenation operation of the feature map, which merges multiple feature maps into a new feature map along a certain dimension (usually the channel dimension).

[0264] During the training process of the YOLOv7-tiny network, SIoU Loss is used as the positioning loss function of the YOLOv7-tiny network.

[0265] Specifically, in this embodiment, identifying abnormal behavior during law enforcement includes:

[0266] Based on the recognition result of the target recognition model, the violation index is calculated using the preset violation index calculation model.

[0267] In this embodiment, a violation index calculation model is preset as follows:

[0268]

[0269] Among them, S i Indicates the severity score of the behavior, F i represents the behavior frequency factor, W i represents the identity weight of the person, T i Represents the time weight factor, R represents the site risk correction value, n represents the total types of illegal and irregular behavior, and i represents a certain type of illegal and irregular behavior.

[0270] Specifically, in this embodiment, the confidentiality transmission module includes:

[0271] Single Sign-On:

[0272] Considering the actual usage scenario of the public security inspection system, this embodiment introduces the CAS system in SSO. The defense barrier of the system entrance is strengthened through the centralized identity authentication process, effectively limiting the potential channels of unauthorized access.

[0273] CAS is an open source single sign-on solution that provides a central server for authentication and a set of client libraries. When a user first accesses any system, CAS redirects the user to the central server for authentication and generates a ticket (TGT) granted by the identity service, which is stored in the user's browser cookie. When the user accesses other systems, CAS checks the TGT in the user's cookie. If there is a valid TGT, CAS generates a service ticket (ST) and redirects the user back to the system. The system sends the ST to CAS for verification again. After confirmation, the user can access the system.

[0274] Hash-based salt encryption algorithm:

[0275] Solution Implementation

[0276] Taking into account the actual performance of the public security inspection system database, this embodiment proposes to use the hash algorithm PBKDF2 combined with the salting method to encrypt the key information of the database. PBKDF2 (Password-based Key Derivation Function 2) can be regarded as an advanced version of the hash salt encryption algorithm, especially in scenarios involving password storage and verification. PBKDF2 increases the complexity of calculating the hash value by using a random salt value and a configurable number of iterations, thereby improving security. The following is a method that introduces the combination of the hash algorithm PBKDF2 and the salt information summary model in the public security inspection system database.

[0277] The transmission mechanisms using single sign-on and hash-based salt encryption include:

[0278] 1. User authentication phase

[0279] User requests access: A user attempts to access a protected service or application.

[0280] Redirect to authentication server: If the user is not logged in, the service redirects the user to the authentication server for authentication.

[0281] Submit credentials: The user enters information such as username and password on the authentication page.

[0282] Credentials processing:

[0283] After receiving the user's credentials, the authentication server will first hash the password using a salting algorithm, that is, add a randomly generated string (salt) to the original password value, and then encrypt the result using a secure hash algorithm (such as SHA-256).

[0284] Doing so can increase the difficulty of password cracking. Even if the database is leaked, it will be difficult for attackers to reverse the original password from the hash value.

[0285] 2. Authentication and session establishment phase

[0286] Verify credentials: The authentication server compares the salted hash value with the user's password hash value stored in the database to verify the validity of the credentials.

[0287] Create a session: Once the authentication is successful, the authentication server will create a unique session identifier (Session ID) for the user and may generate a security token (Token).

[0288] Return to user: The authentication server returns the Session ID or Token to the user, usually through a secure transport layer protocol (such as HTTPS) to ensure the security of the transmission process.

[0289] User access to resources: The user uses the obtained Session ID or Token to request access to the original target service or application again. At this time, the service will check the validity of this identifier or token to decide whether to allow access.

[0290] 3. Subsequent request processing

[0291] Session maintenance: For subsequent requests, users no longer need to re-enter their passwords, but can directly use SessionID or Token for authentication.

[0292] Periodic updates: To improve security, the Session ID or Token may be updated periodically to reduce the risk of long-term use of the same credentials.

[0293] Experimental analysis

[0294] During the model operation, the salt value is used as the key information of the model to complete the initialization of the random algorithm and as filler data. Since the salt value is relatively confidential, it is unrealistic to attempt to obtain the final summary information by brute force cracking the digest algorithm identification ciphertext, because on the one hand, the cost of enumerating each digest algorithm for calculation is not worth the cost compared with the value of the information to be obtained, and on the other hand, even if the attacker happens to encounter the algorithm identification plaintext during the enumeration process, due to the different lengths of the algorithm identification and the salt value, the attacker will not be able to encounter the corresponding salt value and cannot correctly complete the subsequent steps.

[0295] The functions of the salted information summary model mainly include two parts: ① calculating the information summary; ② verifying the information summary.

[0296] ① Calculate information summary

[0297] The following experiment is conducted using a password in the public security inspection system database as an example.

[0298] Perform a circular left shift algorithm to identify the index position of the input string content. For example, if the input string strop is: 0x1032547698badcfe efcdab89 67452301, then the corresponding target string destop after strop<<<8 is: 0x32547698badcfeef cdab896745230110;

[0299] Two strings of the same length are added modulo 28 by byte. For example, if the string strop1 is 0x1032547698badcfe efcdab89 67452301 and strop2 is 0x 32547698badcfeef cdab896745230110, then the target string destop corresponding to strop1+strop2 is 0x 4286ca0e 5296daedbc7834f0 ac682411.

[0300] Concatenate two strings of arbitrary lengths, for example, strop||strop2, which means adding strop2 to the end of strop1, that is, merging strop1 and strop2 to obtain the target string;

[0301] The fold XOR operation is used to XOR the string strop of length (even number) according to the i-th byte and the length-1-i-th byte, and the result is saved in the i-th byte, where i is: 0, 1, 2, ..., (length / 2)-1. In this way, the distribution uniformity and diffusion effect of the basic digest algorithm can be used to optimize the padding data.

[0302] ②Verification information summary

[0303] Filling number ciphertext xor1: fill the ciphertext ciphertype output by the encryption algorithm, the filling data comes from the preprocessing of Salt Value, the length of xor1 after filling is the same as the digest length of the currently randomly selected basic digest algorithm. For example, if the currently selected digest algorithm is MD5, the length of xor1 after filling is 16Bytes, that is, 128bits; Filling number ciphertext xor2: fill the ciphertext ciphertype output by the encryption algorithm, the filling data comes from the preprocessing of SaltValue, the length of xor2 after filling is: Lvsalt, that is, Lend-Lbasic.

[0304] Preprocessing: Generate padding data using Salt as the data source. If the length of the padding data is less than or equal to the length of the data source, the padding data comes directly from the data source. If the length of the padding data is greater than the length of the data source, necessary incremental processing such as XOR and circular left shift is required on the source data when the data source is reused to enhance the randomness of the padding data.

[0305] The above experiments combined with practical experience can prove that the hash algorithm combined with the salt encryption strategy is feasible and superior for encrypting data in the public security inspection system database.

[0306] ③ Application of PBKDF2 algorithm

[0307] Initialization parameters, based on the original password provided by the user, are expressed in the form of a byte string, denoted as P. A random byte string is the salt value, which is used to increase the password strength and prevent rainbow table attacks. C: is the number of iterations, which is used to control the computational overhead of the algorithm and is usually set higher to increase the difficulty of cracking. Where dkLen: is the expected length of the key, in bytes.

[0308] Calculate the subkey: For each i from 1 to dkLen / HMAC output length + 1, calculate the subkey F(i), where F(i) is defined as follows:

[0309] F(i)=HMAC_hash(P,S||INT(i))

[0310] Where HMAC_hash is an HMAC using the selected hash function (such as SHA-256), S||INT(i) represents the concatenation of the salt value S with the binary representation of the integer i, and INT(i) is the integer i converted to a fixed-length byte string.

[0311] Iterative hashing, when calculating F(i), an iterative hashing process is used:

[0312]

[0313] Among them, U_1=HMAC_hash(P,S||INT(i)), for j from 2 to c, U_j=HMAC_hash(P,U_(j-1))

[0314] Combine the subkeys and concatenate all calculated subkeys F(i) to form a large byte string. If dkLen exceeds the HMAC output length * n, additional subkeys are required, that is, increase the value of i and repeat steps 2 and 3 until the dkLen requirement is met.

[0315] Adjust the key length. If the final byte string length exceeds dkLen, truncate the extra bytes. If it is less than dkLen, continue to generate more subkeys until the required length is reached. The final output key is the required byte string.

[0316] On this basis, this embodiment can perform additional processing before the final output, for example, a circular left shift operation can be performed on the final key to increase the randomness of the key; the byte-by-byte addition modulus operation can add the final key to another random sequence byte by byte, taking the modulus to keep it within the byte range; the folding XOR operation can XOR the first half of the final key with the second half to increase the entropy of the key. Finally, string concatenation can be performed. If multiple related keys are required, the results of PBKDF2 can be concatenated with different suffixes, and then PBKDF2 or other hash functions can be applied.

[0317] Specifically, the edge computing module in this embodiment includes:

[0318] Application Practice

[0319] Edge-Enhanced Cloud Computing (EECC) refers to a computing model that combines the capabilities of cloud computing with the advantages of edge computing. EECC pushes computing and data processing capabilities to the "edge" of the network, that is, devices or small data centers that are closer to data sources and users, while the cloud platform is responsible for non-real-time large-scale data analysis, long-term storage, and complex computing tasks.

[0320] In the law enforcement site management and supervision system, since the system model is deployed on the end side, the end side device can analyze the video stream in real time, detect abnormal behavior, and trigger an alarm immediately. At the same time, more complex video analysis or historical data mining is performed on the cloud platform to facilitate more in-depth data processing and long-term storage. This architecture not only improves efficiency, but also optimizes resource allocation and achieves a higher level of intelligence and automation.

[0321] (1) Edge computing

[0322] In order to solve the problems of high data response latency and unstable data transmission caused by the large span of law enforcement sites, the law enforcement site management and supervision system performs edge computing on edge devices in law enforcement sites in different jurisdictions, that is, deploys corresponding model algorithms, and then realizes end-side data analysis and processing, which can greatly alleviate the resource allocation pressure of the central cloud server and improve the performance and stability of the system.

[0323] ①Sample image acquisition

[0324] Edge computing requires real-time acquisition of sample images captured by law enforcement surveillance as input data. To meet the specific requirements of sample image processing, it is necessary to investigate and analyze different application scenarios before deploying the edge monitoring system, determine the characteristics and requirements of the current scene samples, and then install a suitable monitoring system and image acquisition protocol. To meet the sample usage requirements of the law enforcement site management and supervision system, high-performance network monitoring or IP monitoring should be used as the data source in the law enforcement site.

[0325] ②Sample image processing

[0326] To ensure the accuracy and effectiveness of sample collection, it is necessary to analyze and process the sample images collected by monitoring and convert them into effective data information. The sample images are monitored and identified by the algorithm model deployed on the end-side device and processed into sample data, which not only facilitates the operation of the edge model, but also ensures the real-time and accuracy requirements of the recognition results, and enhances the robustness of the system.

[0327] ③Recognition results are synchronized with the cloud

[0328] After the end-side system completes the monitoring sample image processing, it needs to upload the data information to the central cloud server. Data transmission must avoid bandwidth pressure caused by large amounts of data congestion and ensure the security, correctness and integrity of the data. Therefore, reliable network protocols such as MQTT are selected for data transmission.

[0329] ④Model upgrade and update

[0330] In order to adapt to the specific needs of different application scenarios and continuously optimize performance, the models deployed on the edge side need to be regularly upgraded and updated. By pushing the updated system model to the cloud platform, the cloud platform will automatically push the OTA model to the edge side device, and the edge side device will automatically update and upgrade the model. This process ensures that the model can continuously learn new knowledge, adapt to environmental changes, and correct previous errors, thereby achieving better inspection results and higher accuracy.

[0331] ⑤ Equipment status cloud reporting

[0332] To maintain system stability, administrators regularly report the health status of edge devices to the cloud, including hardware working conditions, model execution status, and abnormal event records, to help cloud administrators monitor in real time, respond quickly to abnormalities, and ensure smooth operation of the system.

[0333] (2) Cloud Platform Computing

[0334] Due to the limitations of the edge devices in the law enforcement sites, it is impossible to provide deeper large-scale data analysis and data storage functions. Therefore, the data processed by the edge computing platform on the edge devices needs to be synchronized to the cloud platform for further processing and analysis. The cloud platform computing module mainly provides functions such as sample data intelligent analysis, data sharing and synchronization services, and completes tasks such as video intelligent analysis model training, security log mining and big data analysis, video sample annotation and generation, global monitoring and edge node management, etc., making full use of the powerful computing power and storage resources of the cloud platform, while saving bandwidth, improving data security and privacy, and improving the response speed of the law enforcement system management and supervision system.

[0335] ① Intelligent sample analysis

[0336] The central cloud mainly performs tasks such as model training, model upgrade and maintenance, data storage and analysis, sample annotation and generation, information mining and analysis, and edge node scheduling. The cloud administrator has the right to view the results of target detection, including information such as generated sample data, and implement sample annotation and generation based on training samples in the cloud.

[0337] ②Data sharing and synchronization services

[0338] With the help of the distributed storage architecture of cloud servers, the cloud platform can provide storage space for massive data and store a large amount of key data in the law enforcement system; perform complex big data analysis and processing through machine learning algorithms and high-performance computing resources; and ensure data security and reliability through multiple data replication strategies and audit logs.

[0339] ③Functional services

[0340] The system can realize functions such as node management, component management, service management and resource regulation. Administrators can view detailed information and operation status of resources such as edge computing devices and model training devices.

[0341] This embodiment uses image preprocessing technology and deep learning models to achieve intelligent monitoring and real-time warning of personnel behavior in law enforcement sites. The system can identify and monitor behaviors such as not wearing police uniforms, using mobile phones illegally, and smoking illegally, ensuring the standardization and legality of the law enforcement process.

[0342] Full-process law enforcement supervision: The law enforcement site management and supervision system is used to achieve unified supervision of the entire process of case filing and handling. The system can automatically record and store videos and related data of the entire law enforcement process, provide traceability and transparency, and enhance the credibility of law enforcement.

[0343] Identification and analysis of illegal behaviors: Based on structured active skeleton posture estimation technology, the system can identify various illegal behaviors with high accuracy and generate detailed behavior reports. Through data analysis, the system can provide statistical analysis reports of illegal behaviors and provide a basis for improvement for law enforcement agencies.

[0344] Efficient management and security assurance: Establish a face recognition vector library and visual model sample training to ensure the accuracy of law enforcement personnel identity verification and behavior monitoring. The system reduces the pressure of manual inspections, improves supervision efficiency, and ensures the safety and standardized use of law enforcement sites through automated monitoring and early warning.

[0345] These business goals are to solve the current regulatory problems in law enforcement and case handling through intelligent and digital means, improve the standardization and transparency of the law enforcement process, and effectively enhance the image and credibility of the public security team. In the context of increasingly stringent requirements for standardized law enforcement, it provides strong technical support and guarantees to ensure the compliance and legality of law enforcement activities.

[0346] The embodiments described above are only descriptions of the preferred embodiments of the present invention and are not intended to limit the scope of the present invention. Without departing from the design spirit of the present invention, various modifications and improvements made to the technical solutions of the present invention by ordinary technicians in this field should all fall within the protection scope determined by the claims of the present invention.

Claims

1. A method for managing and supervising law enforcement sites based on deep learning, characterized in that: include: Collect law enforcement process data in law enforcement venues; Based on the law enforcement process data, face recognition is performed using a face recognition model; wherein the face recognition model is constructed based on an improved Dense-MobileFaceNet network; The target recognition model is used to perform target recognition on the data after face recognition to identify abnormal behaviors in the law enforcement process; wherein the target recognition model is built based on the improved YOLOv7-tiny network.

2. According to the deep learning-based law enforcement site management and supervision method of claim 1, it is characterized in that: The law enforcement process data collected in the law enforcement venue includes: Collect video data of the law enforcement process in law enforcement venues; Separate key frames from video data, automatically generate samples, use deep convolutional neural networks to preprocess video frames, and extract high-quality image data; The low-light enhancement algorithm based on deep learning extracts the semantic feature areas in the image through the semantic segmentation model and performs local contrast adjustment.

3. The method for managing and supervising law enforcement sites based on deep learning according to claim 1 is characterized in that: Improvements to the Dense-MobileFaceNet network include: The CycleGAN network is added as a modality conversion module to the input of the Dense-MobileFaceNet network, and the input infrared image is processed into a visible light image before being input into the Dense-MobileFaceNet network for recognition. CycleGAN is trained using a dual-light face dataset. The ArcFace loss function is used in the training process of the Dense-MobileFaceNet network.

4. The method for managing and supervising law enforcement sites based on deep learning according to claim 1 is characterized in that: Improvements to the YOLOv7-tiny network include: An enhanced pyramid segmentation attention mechanism is added after the ELAN layers of different scales in the backbone network of the YOLOv7-tiny network; The enhanced pyramid segmentation attention mechanism is added again to the Neck part of the YOLOv7-tiny network to strengthen the feature network; The processing process of the enhanced pyramid segmentation attention mechanism is: Z i =SEWeight(F i ),i=0,1,2,…,S-1, Out=Cat([Y0,Y1,…,Y s-1 ]), Among them, Z i The weight vector representing the feature map channel attention, att i represents the normalized weighting process of Softmax on the channel attention feature weight, 0ut is the feature map obtained by the final output, SEWeight(F i ) indicates that the SE attention module is used to perform channel-level weighted processing on the feature Fi, i indicates the index of the feature map Fi, i.e., the i-th feature map, Softmax(Z i ) represents the application of Softmax function to vector Zi, Z i represents the channel weight vector of the i-th feature map Fi calculated by the SE attention module, S represents the number of groups into which the input feature map X is split by the SPC module, and Y s-1 It represents the last feature map after being processed by the attention mechanism, and Cat() represents the concatenation operation of the feature map; During the training process of the YOLOv7-tiny network, SIoU Loss is used as the positioning loss function of the YOLOv7-tiny network.

5. The method for managing and supervising law enforcement sites based on deep learning according to claim 1 is characterized in that: Identifying abnormal behavior during law enforcement includes: Based on the recognition result of the target recognition model, the violation index is calculated using a preset violation index calculation model; According to the violation index, different levels of warning push are carried out; The violation index calculation model is: Among them, S i Indicates the severity score of the behavior, F i represents the behavior frequency factor, W i represents the identity weight of the person, T i Represents the time weight factor, R represents the site risk correction value, n represents the total types of illegal and irregular behavior, and i represents a certain type of illegal and irregular behavior.

6. The law enforcement site management and supervision system based on deep learning is characterized by: Used to implement the deep learning-based law enforcement site management and supervision method as described in any one of claims 1 to 5, the system includes: a data acquisition module, a data processing module, a face recognition module, a target recognition module, a report generation module, a confidentiality transmission module and an edge computing module; The data collection module is used to collect law enforcement process data in the law enforcement site; The data processing module is used to perform data enhancement processing on the law enforcement process data; The face recognition module is used to perform face recognition on the enhanced law enforcement process data using a face recognition model; wherein the face recognition model is constructed based on an improved Dense-MobileFaceNet network; The target recognition module is used to use the target recognition model to perform target recognition on the data after face recognition and identify abnormal behavior in the law enforcement process; wherein the target recognition model is constructed based on the improved YOLOv7-tiny network; The report generation module is used to generate a report on the identified abnormal behavior; The confidentiality transmission module is used to encrypt data transmission between modules by adopting single sign-on and a transmission mechanism based on hash-salted encryption; The edge computing module is used to adopt edge computing methods for the data acquisition module, data processing module, face recognition module, and target recognition module.

7. The deep learning-based law enforcement site management and supervision system according to claim 6 is characterized in that: The data processing module: Separate key frames from video data, automatically generate samples, use deep convolutional neural networks to preprocess video frames, and extract high-quality image data; The low-light enhancement algorithm based on deep learning extracts the semantic feature areas in the image through the semantic segmentation model and performs local contrast adjustment.

8. The deep learning-based law enforcement site management and supervision system according to claim 6 is characterized in that: Improvements to the Dense-MobileFaceNet network include: The CycleGAN network is added as a modality conversion module to the input of the Dense-MobileFaceNet network, and the input infrared image is processed into a visible light image before being input into the Dense-MobileFaceNet network for recognition. CycleGAN is trained using a dual-light face dataset. The ArcFace loss function is used in the training process of the Dense-MobileFaceNet network.

9. The deep learning-based law enforcement site management and supervision system according to claim 6 is characterized in that: Improvements to the YOLOv7-tiny network include: An enhanced pyramid segmentation attention mechanism is added after the ELAN layers of different scales in the backbone network of the YOLOv7-tiny network; The enhanced pyramid segmentation attention mechanism is added again to the Neck part of the YOLOv7-tiny network to strengthen the feature network; The processing process of the enhanced pyramid segmentation attention mechanism is: Z i =SEWeight(F i ),i=0,1,2,…,S-1, Out=Cat([Y0,Y1,…,Y S-1 ]), Among them, Z i The weight vector representing the feature map channel attention, att i represents the normalized weighting process of Softmax on the channel attention feature weight, 0ut is the feature map obtained by the final output, SEWeight(F i ) indicates that the SE attention module is used to perform channel-level weighted processing on the feature Fi, i indicates the index of the feature map Fi, i.e., the i-th feature map, Softmax(Z i ) represents the application of Softmax function to vector Zi, Z i represents the channel weight vector of the i-th feature map Fi calculated by the SE attention module, S represents the number of groups into which the input feature map X is split by the SPC module, and Y S-1 It represents the last feature map after being processed by the attention mechanism, and Cat() represents the concatenation operation of the feature map; During the training process of the YOLOv7-tiny network, SIoU Loss is used as the positioning loss function of the YOLOv7-tiny network.

10. The deep learning-based law enforcement site management and supervision system according to claim 6 is characterized in that: Identifying abnormal behavior during law enforcement includes: Based on the recognition result of the target recognition model, the violation index is calculated using a preset violation index calculation model; The violation index calculation model is: Among them, S i Indicates the severity score of the behavior, F i represents the behavior frequency factor, W i represents the identity weight of the person, T i Represents the time weight factor, R represents the site risk correction value, n represents the total types of illegal and irregular behavior, and i represents a certain type of illegal and irregular behavior.

Citation Information

Patent Citations

  • A method for using robot to identify road traffic law enforcement behavior and to provide standardized assistance

    CN110059675A

  • Multi-mode security monitoring method based on deep learning image processing

    CN112733819A

  • Intelligent identification method for unsafe behaviors of oil and gas laboratory

    CN114120405A

  • Non-paired face-to-face expression editing method based on adversarial generation

    CN116152891A

  • Construction site entrance face recognition method based on improved MobileFaceNet

    CN117831093A

Cited By

  • Control method and device based on image-text identification recognition

    CN120599591A