A method, device, electronic device and medium for processing false data
By extracting and comparing the abnormal events detected by the abnormal event detection model, the problem of high false reporting rate is solved, the accuracy and recall rate of detection are improved, and the real-time detection is ensured.
Patent Information
- Application Number
- CN202411621394.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-14
- Publication Date
- 2025-02-25
- Estimated Expiration
- 2044-11-14
AI Technical Summary
In the detection of abnormal events, the prior art causes frequent false reports due to factors such as light, imaging, and target characteristics, which reduces the recall rate of actual abnormal events. Frequent update of detection models will affect the real-time and accuracy of detection.
By extracting the abnormal events detected by the abnormal event detection model, determining the abnormal event characteristics, and comparing them with the preset false reporting event feature library, the actual detection results of the abnormal event are determined based on the comparison results, thereby Filter false reports.
Without optimizing the established abnormal event detection model, the accuracy of abnormal event detection is improved, the false reporting rate is reduced, the recall rate of actual abnormal events is improved, and the real-time detection is ensured.
Smart Images

Figure 00000000_0000_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of false data processing, and in particular to a false data processing method, device, electronic equipment and medium. Background Art
[0002] At present, all industries have the task of detecting abnormal events in specific scenarios, such as people falling, strangers entering, workers on construction sites not wearing helmets, fires in chemical parks, and road traffic accidents. In the process of detecting the above abnormal events through computer vision technology, due to the influence of specific scenarios such as light, imaging, target feature diversity and other interference factors, false reports often occur, reducing the recall rate of actual abnormal events. False reports refer to the situation where normal events are mistakenly detected as abnormal events. Abnormal events require users to perform closed-loop processing. Taking a business system with 1,000 video analysis as an example, assuming that each video has 10 false reports for 24 hours a day, the user must perform at least 10,000 abnormal events in a closed loop every day. Assuming that each event business closed loop takes 10 seconds, it will take at least 27 more hours, which is a serious waste of manpower.
[0003] The current solution to reduce the false alarm rate is to continuously update and iterate the abnormal event detection model to achieve the purpose of reducing the false alarm rate. This solution will result in low availability of the abnormal event detection model and cannot be applied to abnormal event detection in various business scenarios. If frequent iterative optimization is performed, it is difficult to ensure the real-time performance of abnormal event detection, and it is difficult to balance the accuracy and real-time performance of abnormal event detection. Summary of the invention
[0004] The embodiments of the present application provide a false report data processing method, device, electronic device and medium to improve the accuracy of abnormal event detection without optimizing the established abnormal event detection model.
[0005] According to one aspect of the present application, a method for processing false data is provided, the method comprising:
[0006] If an abnormal event is detected during abnormal event detection of an image based on the abnormal event detection model, feature extraction is performed on the image area corresponding to the abnormal event to determine the abnormal event feature;
[0007] Comparing the abnormal event features with the false alarm event features in a preset feature library for similarity; wherein the preset feature library is determined based on the features of false alarm events determined in the historical abnormal event detection process;
[0008] According to the similarity comparison result between the false alarm event feature and the abnormal event feature, the actual detection result of the abnormal event is determined.
[0009] According to one aspect of the present application, a false reporting data processing device is provided, the device comprising:
[0010] An abnormal event feature extraction module is used to extract features from an image area corresponding to the abnormal event to determine abnormal event features if an abnormal event is detected during abnormal event detection based on an abnormal event detection model;
[0011] A similarity comparison module is used to compare the characteristics of the abnormal event with the characteristics of false alarm events in a preset feature library; wherein the preset feature library is determined based on the characteristics of false alarm events determined in the historical abnormal event detection process;
[0012] The actual detection result determination module is used to determine the actual detection result of the abnormal event according to the similarity comparison result between the false alarm event feature and the abnormal event feature.
[0013] According to another aspect of the present application, an electronic device is provided, the electronic device comprising:
[0014] at least one processor; and
[0015] A memory connected to at least one processor for data processing; wherein,
[0016] The memory stores a computer program that can be executed by at least one processor, and the computer program is executed by at least one processor so that the at least one processor can execute the false data processing method of any embodiment of the present application.
[0017] According to another aspect of the present application, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the false data processing method of any embodiment of the present application when executed.
[0018] The technical solution of the embodiment of the present application is that if an abnormal event is detected in the process of abnormal event detection of an image based on an abnormal event detection model, feature extraction is performed on the image area corresponding to the abnormal event to determine the abnormal event feature; the abnormal event feature is compared with the false alarm event feature in the preset feature library for similarity; wherein the preset feature library is determined based on the features that are determined as false alarm events in the historical abnormal event detection process; and the actual detection result of the abnormal event is determined based on the similarity comparison result between the false alarm event feature and the abnormal event feature. The above scheme determines the preset feature library based on the features that are determined as false alarm events in the historical abnormal event detection process, and filters the abnormal events based on the comparison between the false alarm event features in the preset feature library and the abnormal event features, and accurately determines the actual abnormal events and removes the false alarm events without iteratively upgrading the established abnormal event detection model, thereby reducing the false alarm rate and improving the recall rate of the actual abnormal events.
[0019] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present application, nor is it intended to limit the scope of the present application. Other features of the present application will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0021] Figure 1 A flowchart of a method for processing false data provided in an embodiment of the present application;
[0022] Figure 2 A flowchart of a method for processing false data provided by another embodiment of the present application;
[0023] Figure 3 A schematic diagram of the spatial distribution of feature clusters and abnormal event features provided in another embodiment of the present application;
[0024] Figure 4 A flowchart of a false data processing method provided in another embodiment of the present application;
[0025] Figure 5 A flowchart of a specific implementation method provided for an embodiment of the present application;
[0026] Figure 6 Schematic diagram of the process flow of determining the similarity threshold between feature clusters in an embodiment of the present application;
[0027] Figure 7 A schematic diagram of the structure of a false data processing device provided in an embodiment of the present application;
[0028] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0029] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.
[0030] It should be noted that the terms "first", "second", "third", "fourth", "actual", "preset", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0031] Figure 1 A flowchart of a false alarm data processing method provided in an embodiment of the present application, the embodiment of the present application can be applied to the case of detecting images. Typically, it can be applied to the case of detecting abnormal events in images. The method can be executed by a false alarm data processing device, which can be implemented in the form of hardware and / or software, and the false alarm data processing device can be configured in an electronic device, which can be an image collector, or a server, terminal, etc. that receives images collected by the image collector. Figure 1 As shown, the method includes:
[0032] S110: If an abnormal event is detected during abnormal event detection on an image based on an abnormal event detection model, feature extraction is performed on an image region corresponding to the abnormal event to determine features of the abnormal event.
[0033] Among them, the abnormal event detection model is a model that has been trained in advance, which is used to detect images and determine the abnormal events contained therein. In an embodiment of the present application, the abnormal event detection model can be reused, that is, no iterative optimization is required. The image can be an image collected in real time by an image collector, or it can be a historical image. The process of abnormal event detection is: input the image into the abnormal event detection model to detect abnormal events appearing in the image. Abnormal events can be events set according to actual scenarios and business needs. For example, in a home with an elderly person, the abnormal event can be set as a person falling down. On a construction site, the abnormal event can be set as a worker not wearing a safety helmet. In a chemical park, the abnormal event can be set as a fire, etc. The image area corresponding to the abnormal event can be the image area where the subject where the abnormal event occurred and the environment within a preset range are located.
[0034] Exemplarily, if an abnormal event is detected by the abnormal event detection model during abnormal event detection of an image, the abnormal event may be an actual abnormal event or a false alarm. Feature extraction is performed on the image area corresponding to the abnormal event as the abnormal event feature. The abnormal event feature can be expressed in the form of a feature vector, and the dimension is not limited. It can be set in combination with the actual business accuracy requirements and the computing power of the electronic device, for example, it can be set to 256 dimensions.
[0035] S120, performing a similarity comparison between the abnormal event feature and the false alarm event feature in a preset feature library; wherein the preset feature library is determined based on the features determined as false alarm events in the historical abnormal event detection process.
[0036] The historical abnormal event detection process is the abnormal event detection process before the current time. In the historical abnormal event detection process, the abnormal event detection model detects abnormal events. Generally, abnormal events will be checked again by the user to confirm whether they are actual abnormal events, and false alarm events will also be determined. A preset feature library can be determined based on the characteristics of false alarm events, and all false alarm event features in the preset feature library are the characteristics of false alarm events.
[0037] Exemplarily, the abnormal event features of the abnormal event detected by the abnormal event detection model can be compared with the false report event features in the preset feature library for similarity, so as to determine whether the abnormal event features are similar to the false report event features, and then determine whether the abnormal event is a false report event, and further automatically judge the abnormal event, thereby effectively reducing the user's workload.
[0038] In the embodiment of the present application, the method of similarity comparison is not limited and can be selected according to actual conditions, for example, the Euclidean distance method, the Manhattan distance method, the cosine similarity method, the Pearson correlation coefficient method, etc. can be selected.
[0039] S130: Determine an actual detection result of the abnormal event according to a similarity comparison result between the false alarm event feature and the abnormal event feature.
[0040] Exemplarily, there may be actual abnormal events or false reports among abnormal events, and the actual detection results of abnormal events can be determined based on the similarity comparison results between the features of false reports and the features of abnormal events. In general, the same features should exist in the image areas corresponding to events of the same type. For example, there is fire in the image areas corresponding to fire events, and there are posture features of falling in the image areas corresponding to the time when people fall. By reverse reasoning, it can be determined whether the events are of the same type based on the similarity of the features. If the similarity between the features of false reports and the features of abnormal events is greater than a pre-set similarity threshold, it can be determined that the abnormal event is a false report, thereby accurately and automatically removing the false report from the abnormal events, avoiding the user from analyzing it again and wasting manpower.
[0041] The technical solution of the embodiment of the present application is that if an abnormal event is detected in the process of abnormal event detection of an image based on an abnormal event detection model, feature extraction is performed on the image area corresponding to the abnormal event to determine the abnormal event feature; the abnormal event feature is compared with the false alarm event feature in the preset feature library for similarity; wherein the preset feature library is determined based on the features that are determined as false alarm events in the historical abnormal event detection process; and the actual detection result of the abnormal event is determined based on the similarity comparison result between the false alarm event feature and the abnormal event feature. The above scheme determines the preset feature library based on the features that are determined as false alarm events in the historical abnormal event detection process, and filters the abnormal events based on the comparison between the false alarm event features in the preset feature library and the abnormal event features, and accurately determines the actual abnormal events and removes the false alarm events without iteratively upgrading the established abnormal event detection model, thereby reducing the false alarm rate and improving the recall rate of the actual abnormal events.
[0042] Figure 2 This is a flowchart of a false data processing method provided by another embodiment of the present application. The present embodiment is optimized based on the above embodiment. For solutions not described in detail in the present embodiment, please refer to the above embodiment. Figure 2 As shown, the method of the embodiment of the present application specifically includes the following steps:
[0043] S210: If an abnormal event is detected during abnormal event detection on an image based on an abnormal event detection model, feature extraction is performed on an image region corresponding to the abnormal event to determine features of the abnormal event.
[0044] S220, performing a similarity comparison between the abnormal event feature and the false alarm event feature in a preset feature library; wherein the preset feature library is determined based on the features determined as false alarm events in the historical abnormal event detection process.
[0045] S230: If the similarity between the false alarm event feature and the abnormal event feature is greater than or equal to the intra-feature cluster similarity threshold of the feature cluster to which the false alarm event feature belongs, determine that the abnormal event is a false alarm event.
[0046] Wherein, the similarity threshold value within the feature cluster is determined according to the distribution characteristics of each false report event feature in the preset feature library, and the false report event features can be clustered, and similar false report event features can be classified into a feature cluster. For each feature cluster, the minimum similarity between the false report event features within the cluster can be determined, and the minimum value of the minimum similarity of each feature cluster is used as the similarity threshold value within the feature cluster. Alternatively, in the process of clustering similar false report event features, the radius is used as a constraint condition, that is, the radius of each feature cluster is consistent, and the minimum similarity between the false report event features within the cluster is consistent, and the minimum similarity is used as the similarity threshold value within the feature cluster. Exemplarily, the minimum similarity between the false report event features within the cluster can be determined according to the diameter of the cluster, and the similarity between the false report event feature and the abnormal event feature also needs to be expressed by distance. For example, the reciprocal of the distance between the false report event feature and the abnormal event feature is used as the similarity, and the reciprocal of the diameter of the cluster is used as the minimum similarity between the false report event features within the cluster. If the similarity between the false alarm event feature and the abnormal event feature is greater than or equal to the similarity threshold within the feature cluster, that is, the distance between the false alarm event feature and the abnormal event feature is less than the diameter of the cluster, then the abnormal event is determined to be a false alarm event. The above scheme can automatically filter out false alarm events in abnormal events based on the comparison of the similarity between the false alarm event feature and the abnormal event feature and the similarity threshold within the feature cluster, avoiding the waste of manpower by users and increasing unnecessary manpower consumption.
[0047] In an embodiment of the present application, in the process of searching whether there is a false alarm event feature in a preset feature library whose similarity with the abnormal event feature is greater than or equal to the similarity threshold within the feature cluster, the preset feature library can be traversed. For a feature cluster, if there is a false alarm event feature and an abnormal event feature whose similarity is greater than or equal to the similarity threshold within the feature cluster, the false alarm event features in other feature clusters can be traversed. Among all the false alarm event features whose similarity with the abnormal event feature is greater than or equal to the similarity threshold within the feature cluster, the false alarm event feature with the greatest similarity is used as the false alarm event feature that is closest to the abnormal time feature.
[0048] It should be noted that the above is only an example of an implementation method of expressing similarity in terms of distance. Similarity can also be expressed in other forms, and the corresponding similarity threshold within the feature cluster also changes accordingly. The similarity between abnormal event features and false alarm event features remains consistent with the representation of the similarity threshold within the feature cluster.
[0049] The preset feature library may include false alarm event features, corresponding alarm types, and confidence levels. The alarm type and confidence level are output when the abnormal event detection model detects the false alarm event as an abnormal event. Accordingly, when the abnormal event features are compared with the false alarm event features for similarity, the false alarm event features of the false alarm events that are consistent with the alarm type of the abnormal event can be selected from the preset feature library for comparison, so as to quickly lock in possible similar false alarm events and improve the comparison efficiency.
[0050] In the embodiment of the present application, since the similarity between the false report event feature and the abnormal event feature is greater than or equal to the similarity threshold within the feature cluster, that is, the false report event feature is extremely similar to the abnormal event feature, and the false report event feature is sufficient to screen out false report events in the abnormal events that belong to the same cluster as the false report event feature, the false report event feature is representative, and there is no need to add the abnormal event feature to the preset feature library, so that the preset feature library contains comprehensive false report event features while remaining concise, saving storage space, and reducing the pressure of similarity comparison.
[0051] In the embodiment of the present application, the process of determining the similarity threshold within the feature cluster includes:
[0052] Clustering the false alarm event features in the preset feature library to determine an initial similarity threshold within the feature cluster;
[0053] If the number of false alarm event features in the preset feature library increases to a first preset number, increasing the similarity threshold within the feature cluster;
[0054] If the number of false alarm event features in the preset feature library is reduced to a second preset number, the similarity threshold within the feature cluster is reduced.
[0055] For example, the false alarm event features in the preset feature library can be clustered to obtain feature clusters, such as Figure 3In the feature clusters 1 and 2, the dots contained therein represent the false report event features, and r represents the diameter of feature cluster 1. The minimum similarity between the false report event features within the feature cluster is used as the initial similarity threshold within the feature cluster. For feature cluster 1, the reciprocal of the diameter can be used as the similarity threshold within the feature cluster. If, with the execution of the false report data processing method, the false report event features in the preset feature library gradually increase to a first preset number, the similarity threshold within the feature cluster can be reduced, that is, the cluster radius of the clustering constraint condition is increased to reduce the number of feature clusters and reduce the pressure of comparison with the similarity threshold within the feature cluster. If the number of false report event features in the preset feature library is reduced to a second preset number, the similarity threshold within the feature cluster is increased, that is, the cluster radius of the clustering constraint condition is reduced to increase the number of feature clusters for fine-grained comparison.
[0056] S240: If the similarities between all false alarm event features in the preset feature library and the abnormal event feature are less than the intra-feature cluster similarity threshold of the feature cluster to which the false alarm event feature belongs, determine the actual detection result of the abnormal event according to the judgment result of the user.
[0057] Exemplarily, the false report event features in the preset feature library are traversed, and the false report event features are compared with the abnormal event features for similarity. If the similarity between the false report event features and the abnormal event features is less than the similarity threshold within the feature cluster of the feature cluster to which the false report event features belong, it is impossible to directly determine that the abnormal event is a false report event, and it is necessary to leave it to the user to continue to judge. The user's judgment result shall prevail in the end, and the actual detection result of the abnormal event shall be determined based on the user's judgment result, and the abnormal event shall be judged as an actual abnormal event or a false report event.
[0058] In the embodiment of the present application, after determining the actual detection result of the abnormal event according to the judgment result of the user, the method further includes:
[0059] If it is determined according to the judgment result of the user that the actual detection result of the abnormal event is a false alarm event, the similarity between the abnormal event feature and the false alarm event feature is compared with the similarity threshold between feature clusters;
[0060] The preset feature library is updated according to the comparison result of the similarity and the similarity threshold between feature clusters.
[0061] Exemplarily, if the abnormal event is determined to be a false alarm event based on the judgment result of the user, then based on the similarity between the abnormal event features and the false alarm event features, and the comparison result with the similarity threshold between feature clusters, it can be determined how to update the preset feature library. For example, the abnormal event features can be directly added to the preset feature library as new false alarm event features, or the abnormal event features can be used as new false alarm event features to replace the original false alarm event features. By updating the preset feature library, the comprehensiveness and richness of the preset feature library can be improved, and the filtering performance of false alarm events can be improved. Among them, the inter-cluster similarity threshold can reflect the similarity between different feature clusters in the preset feature library. For example, the minimum value of the inverse of the distance between different clusters can be used as the similarity threshold between feature clusters. Exemplarily, Figure 3 As shown, th is the distance between feature cluster 1 and feature cluster 2. If the reciprocal of the distance is the minimum value among the reciprocals of the distances between adjacent clusters, the reciprocal of the distance can be used as the similarity threshold between feature clusters.
[0062] In the embodiment of the present application, the preset feature library is updated according to the comparison result of the similarity and the similarity threshold between feature clusters, including:
[0063] Determine the maximum similarity between the abnormal event feature and the false report event feature, and use the false report event feature corresponding to the maximum similarity as the target false report event feature;
[0064] If the maximum similarity is less than or equal to the similarity threshold between feature clusters, the abnormal event feature is added to the preset feature library as a new false alarm event feature;
[0065] If the maximum similarity is greater than the similarity threshold between feature clusters, the first confidence corresponding to the abnormal event feature is compared with the second confidence of the false alarm event corresponding to the target false alarm event feature; wherein the first confidence is the confidence corresponding to when the abnormal event detection model detects the abnormal event; the second confidence is the confidence corresponding to when the abnormal event detection model detects the false alarm event corresponding to the target false alarm event feature as an abnormal event;
[0066] The preset feature library is updated according to a comparison result of the first confidence level and the second confidence level.
[0067] Exemplarily, in the process of updating the preset feature library based on the abnormal event feature, the maximum similarity between the false event feature and the abnormal event feature in the preset feature library is determined, and the false event feature corresponding to the maximum similarity is used as the target false event feature. The minimum value of the reciprocal of the distance between different clusters can be used as the feature cluster similarity threshold. If the maximum similarity is less than or equal to the feature cluster similarity threshold, it means that the inter-cluster similarity between the abnormal event feature and the target false event feature is low, and they are not features belonging to the same cluster. The abnormal event feature can be directly added to the preset feature library as a new false event feature. If the maximum similarity is greater than the feature cluster similarity threshold, it means that the inter-cluster similarity between the abnormal event feature and the target false event feature is high, and they may be features belonging to the same type of false events. One can be selected and retained in the preset feature library to simplify the preset feature library. In the process of selecting one to retain, the first confidence of the abnormal event feature and the second confidence of the target false event feature can be compared, and the retained features can be selected according to the first confidence and the second confidence. The first confidence level corresponding to the abnormal event feature is the confidence level corresponding to the output when the abnormal event detection model detects an abnormal event. The false alarm event feature is a feature that is detected as an abnormal event by the abnormal event detection model in the historical abnormal event detection process and then judged as a false alarm event by the user. The false alarm event feature with the greatest similarity to the abnormal event feature is the target false alarm event feature. The second confidence level corresponding to the target false alarm event feature is the confidence level corresponding to the abnormal event detection model when the false alarm event corresponding to the target false alarm event feature is detected as an abnormal event. The above scheme can add abnormal event features that are significantly different from the false alarm event features in the preset feature library to the preset feature library, enrich and supplement the preset feature library, and replace and update the false alarm event features in the preset feature library by comparing the first confidence level and the second confidence level, so as to optimize the false alarm event features and keep them concise.
[0068] In an embodiment of the present application, updating the preset feature library according to the comparison result of the first confidence level and the second confidence level includes:
[0069] If the first confidence level is less than the second confidence level, adding the abnormal event feature as a new false alarm event feature to the preset feature library;
[0070] If the first confidence level is greater than or equal to the second confidence level, the abnormal event feature is added to the preset feature library as a new false alarm event feature and marked as a first candidate feature, and the target false alarm event feature is marked as a second candidate feature;
[0071] If the number of times subsequent abnormal events are determined to be false alarms by similarity comparison with the first candidate feature within a preset time is greater than the number of times subsequent abnormal events are determined to be false alarms by similarity comparison with the second candidate feature, the first candidate feature replaces the second candidate feature.
[0072] Exemplarily, if the first confidence of the abnormal event feature is less than the second confidence of the target false alarm event feature, it is considered that the credibility of the target false alarm event feature in the current preset feature library is relatively high, so it is still retained without replacement, and in order to detect the abnormal event corresponding to the abnormal event feature as a false alarm in the future, the abnormal event feature is directly added to the preset feature library as a new false alarm event feature. Since the abnormal event feature has not been included in the preset feature library as a filtering condition for false alarm events, if it is not added to the preset feature library, when the abnormal event feature appears again in the future, it is still impossible to detect the abnormal event feature as a false alarm event through the preset feature library, so it is necessary to add it to the preset feature library as a supplement. If the first confidence is greater than or equal to the second confidence, it means that the abnormal event detection model has a higher credibility for detecting the abnormal event feature as an abnormal event, the abnormal event feature is easier to detect, and is a more obvious and representative feature, reflecting that the abnormal event feature is closer to the center of the feature cluster to which the target false alarm event feature belongs, and it can be considered to replace the target false alarm event feature with the abnormal event feature. In order to improve the reliability of feature replacement, the abnormal event feature can be first added to the preset feature library as a new false alarm event feature, marked as the first candidate feature, and the target false alarm event feature can be marked as the second candidate feature. The number of times the subsequent abnormal event is determined to be a false alarm event by similarity comparison with the first candidate feature within the preset time is counted, and the number of times the subsequent abnormal event is determined to be a false alarm event by similarity comparison with the second candidate feature is counted. Specifically, if the similarity between the subsequent abnormal event feature of the subsequent abnormal event and the first candidate feature is greater than the similarity threshold within the feature cluster, the subsequent abnormal event is judged to be a false alarm event, then the first number is counted plus one, if the similarity between the subsequent abnormal event feature of the subsequent abnormal event and the second candidate feature is greater than the similarity threshold within the feature cluster, the subsequent abnormal event is judged to be a false alarm event, then the second number is counted plus one, if the first number within the preset time is greater than the second number, it means that the first candidate feature is more referenceable, then the first candidate feature replaces the second candidate feature, that is, the newly added abnormal event feature is retained, the target false alarm event feature is deleted, and the feature with stronger false alarm event screening performance is retained to maintain the reliability and simplicity of the preset feature library.
[0073] In the embodiment of the present application, the process of determining the similarity threshold between feature clusters includes:
[0074] Constructing an event sample library, processing false report data on the event sample library according to the false report data processing method, and determining the event recall rate;
[0075] According to the comparison result between the event recall rate and the preset recall rate, the similarity threshold between feature clusters is adjusted and iterated until the event recall rate is consistent with the preset recall rate, thereby obtaining the adjusted similarity threshold between feature clusters; wherein the event includes an abnormal event or a false alarm event.
[0076] A historical abnormal event sample library can be constructed based on the non-false historical abnormal events detected in the historical false data processing process, or a historical false event sample library can be constructed based on the detected historical false events. The false data processing process is the entire process included in the above embodiment, such as the entire process of S210-S240, that is, including the abnormal event detection process and the subsequent false event detection process. After the event sample library is constructed, the event sample library is subjected to false data processing according to the false data processing method to determine the event recall rate. Since the event sample library contains only a single type of event samples, the recall rate is theoretically 100%, that is, all event samples can be correctly detected. According to the actual application scenario requirements, a preset recall rate, such as 95%, can be set, and this can be used as a constraint condition to adjust the feature similarity threshold iteratively until the event recall rate is equal to the preset recall rate, and the feature cluster similarity threshold at this time is used as the final feature cluster similarity threshold. The above scheme can effectively ensure the recall rate of abnormal events by adaptively adjusting the feature cluster similarity threshold, and avoid the situation where the recall rate of abnormal events is affected by the inappropriate feature cluster similarity threshold.
[0077] In the embodiment of the present application, the preset recall rate includes a first preset recall rate or a second preset recall rate;
[0078] According to the comparison result of the recall rate and the preset recall rate, the similarity threshold between feature clusters is adjusted iteratively, including:
[0079] If the recall rate of the abnormal event is less than the first preset recall rate, reducing the similarity threshold between feature clusters;
[0080] If the recall rate of the abnormal event is greater than the first preset recall rate, increasing the similarity threshold between feature clusters; or,
[0081] If the recall rate of the false alarm events is less than the second preset recall rate, increasing the similarity threshold between the feature clusters;
[0082] If the recall rate of the false alarm events is greater than the second preset recall rate, the similarity threshold between feature clusters is reduced.
[0083] Among them, the recall rate of abnormal events is the ratio of the number of actual abnormal events to the number of abnormal events detected by the abnormal event detection model. The first preset recall rate is the recall rate of abnormal events that the user can accept, which is less than or equal to the recall rate of actual abnormal events, reflecting the threshold value obtained by the user in balancing the loss of the recall rate of actual abnormal events by the preset feature library and the ability to filter false events. The recall rate of false events is the ratio of the number of events determined to be false events to the number of events detected as abnormal events by the abnormal event detection model. The second preset recall rate is the recall rate of false events that the user can accept, which is less than or equal to the recall rate of false events, reflecting the threshold value obtained by the user in balancing the loss of the recall rate of false events by the preset feature library and the ability to filter false events. Exemplarily, the process of iteratively adjusting the similarity threshold between feature clusters according to the event recall rate is as follows: if the recall rate of abnormal events is less than the first preset recall rate, the similarity threshold between feature clusters is reduced to adaptively increase the recall rate of abnormal events; if the recall rate of abnormal events is less than the first preset recall rate, the similarity threshold between feature clusters is reduced to adaptively reduce the recall rate of abnormal events. Alternatively, if the recall rate of false alarm events is less than the second preset recall rate, the similarity threshold between feature clusters is increased to adaptively increase the recall rate of false alarm events; if the recall rate of false alarm events is greater than the second preset recall rate, the similarity threshold between feature clusters is reduced to adaptively reduce the recall rate of false alarm events. The above scheme can adaptively adjust the similarity threshold between feature clusters to ensure an appropriate event recall rate.
[0084] For example, in the first case, the sample library contains 100 actual abnormal events and 0 false alarm events, and the actual abnormal event recall rate is theoretically 100%. In the process of traversing the current preset feature library and comparing with the similarity threshold between feature clusters, if it is determined that there are false alarm events, for example, 10 events in the sample library are determined to be false alarm events, then the number of actual abnormal events is determined to be 90, and the actual abnormal event recall rate is 90%, which is lower than the first preset recall rate of 95%, which does not meet the requirements. Since the scheme for determining whether to add abnormal event features to the preset feature library is that if the maximum similarity between the abnormal event feature and the false alarm feature is less than or equal to the similarity threshold between feature clusters, the abnormal event feature is directly added to the preset feature library as a new false alarm feature. When the recall rate is lower than the first recall rate, the similarity threshold between feature clusters should be adaptively reduced to reduce the number of false features directly added to the feature library through the above scheme, so as to indirectly make more abnormal features that fail to be compared with the feature library be judged as actual abnormal events. If 3 events in the sample library are judged to be false events, the number of actual abnormal events judged to be 97, and the recall rate of actual abnormal events is 97%, which is higher than the first preset recall rate of 95%, reflecting that the screening ratio of false features does not meet the requirements. In this case, the similarity threshold between feature clusters should be adaptively increased, and the number of false features directly added to the feature library through the above scheme should be increased, so as to indirectly make fewer abnormal features that successfully compare with the feature library be judged as actual abnormal events, so as to ensure that the preset feature library can achieve a certain screening ratio for false events.
[0085] In the second case, the sample library contains 100 false events and 0 actual abnormal events, and the false event recall rate is theoretically 100%. In the process of traversing the current preset feature library and comparing with the similarity threshold between feature clusters, if it is determined that there are false events, for example, 90 events in the sample library are judged to be false events, then the number of false events is 90, and the recall rate of false events is 90%, which is lower than the second preset recall rate of 95%, which does not meet the requirements. Since the scheme for determining whether to add abnormal event features to the preset feature library is that if the maximum similarity between the abnormal event feature and the false event feature is less than or equal to the similarity threshold between feature clusters, the abnormal event feature is directly added to the preset feature library as a new false event feature. If the recall rate is lower than the second preset recall rate threshold, the similarity threshold between feature clusters should be adaptively increased to increase the number of false features directly added to the feature library through the above scheme, so as to indirectly make more abnormal features successfully compared with the feature library and be judged as false events. If 97 events in the sample library are judged to be false reports, the number of false reports is 97, and the recall rate of false reports is 97%, which is higher than the second preset recall rate of 95%, reflecting that the screening ratio of actual abnormal events does not meet the requirements. In this case, the similarity threshold between feature clusters should be adaptively reduced to reduce the number of false reports directly added to the feature library through the above scheme, so as to indirectly make more abnormal features that fail to match the feature library be judged as actual abnormal events, so as to ensure that the preset feature library can screen actual events to a certain ratio.
[0086] The embodiment of the present application provides a false report data processing method. If an abnormal event is detected in the process of detecting abnormal events on an image based on an abnormal event detection model, feature extraction is performed on the image area corresponding to the abnormal event to determine the abnormal event feature; the abnormal event feature is compared with the false report event feature in the preset feature library for similarity; wherein the preset feature library is determined based on the features that are determined to be false reports in the historical abnormal event detection process. If there is a false report event feature and the abnormal event feature has a similarity greater than or equal to the similarity threshold within the feature cluster, the abnormal event is determined to be a false report event; if the similarity of all false report event features in the preset feature library and the abnormal event feature is less than the similarity threshold within the feature cluster, the actual detection result of the abnormal event is determined according to the user's judgment result. The above scheme can automatically filter out false reports in abnormal events through the similarity threshold within the feature cluster, detect abnormal event features through the feature law within the abnormal event feature cluster, accurately determine whether the abnormal event feature is similar to the characteristic in the preset feature library, and then accurately determine whether the abnormal event is a false report event.
[0087] Figure 4This is a flowchart of a false data processing method provided by another embodiment of the present application. The present embodiment is optimized based on the above embodiment. For solutions not described in detail in the present embodiment, please refer to the above embodiment. Figure 4 As shown, the method of the embodiment of the present application specifically includes the following steps:
[0088] S310: Determine an application scenario for false data processing, and determine image samples corresponding to the application scenario.
[0089] For example, the application scenario for the current false data processing may be determined, such as personnel fall detection, worker not wearing a helmet detection, fire detection, etc. The image samples corresponding to the application scenario are determined. For example, for the application scenario of personnel fall detection, image samples containing various postures of personnel are determined. For the application scenario of fire detection, image samples containing fire are determined.
[0090] S320. According to the application scenario, the corresponding image samples are input into the feature extraction backbone network for training, and the cross entropy loss value and the triplet loss value are calculated.
[0091] For example, for an application scenario, the image sample corresponding to the application scenario can be input into the feature extraction backbone network for training, and the cross entropy loss value and the triplet loss value can be calculated based on the sample image features output by the backbone network and the actual fine-grained features of the image sample.
[0092] S330, iterating based on the cross entropy loss value and the triplet loss value until an iteration condition is met, thereby obtaining a feature extraction model corresponding to the application scenario.
[0093] Exemplarily, the triplet loss attempts to learn a feature space so that the reference samples (Anchor) of the same category are closer to the positive samples (Positive) in the space, and the reference samples of different categories are farther from the negative samples (Negative). The network model finally obtained can learn better subtle features and can distinguish details well. The cross entropy loss is the difference between the probability of category distribution predicted by the neural network and the probability of actual category distribution. The smaller the cross entropy, the better. Iteration is performed using the cross entropy loss value and the triplet loss value as constraints. If the loss value does not meet the preset loss value requirement, the model parameters are optimized to process the image sample again to reduce the loss value until the preset loss value requirement is met. The backbone network can learn more fine-grained features and improve the accuracy of feature extraction. In the embodiment of the present application, the above scheme can be used to train different feature extraction models for different application scenarios. The feature extraction model is completely trained according to the image sample corresponding to the application scenario, and has more common details. Therefore, it can extract more fine-grained features to make the subsequent similarity comparison based on the preset feature library more accurate.
[0094] S340: If an abnormal event is detected during abnormal event detection on an image based on the abnormal event detection model, feature extraction is performed on an image region corresponding to the abnormal event based on a feature extraction model to determine features of the abnormal event.
[0095] S350, performing a similarity comparison between the abnormal event feature and the false alarm event feature in a preset feature library; wherein the preset feature library is determined based on the false alarm event features determined as false alarm events in the historical abnormal event detection process.
[0096] S360: Determine an actual detection result of the abnormal event according to a similarity comparison result between the false alarm event feature and the abnormal event feature.
[0097] The embodiment of the present application provides a method for processing false data, which determines the application scenario of false data processing and determines the image samples corresponding to the application scenario; for the application scenario, the corresponding image samples are input into the feature extraction backbone network for training, and the cross entropy loss value and the triplet loss value are calculated; it is iterated based on the cross entropy loss value and the triplet loss value until the iteration condition is met to obtain the feature extraction model corresponding to the application scenario. The above scheme can adaptively train the corresponding feature extraction model according to the image samples corresponding to the application scenario for different application scenarios, so as to learn the finer-grained features in the image samples belonging to the application scenario, so as to extract the fine-grained features of abnormal events and improve the accuracy of the subsequent similarity comparison with the false event features. In addition, it is iterated in combination with the cross entropy loss value and the triplet loss value, so that the feature extraction model can more clearly define the relationship between features and improve the accuracy of the feature extraction model.
[0098] Figure 5 A flowchart of a specific implementation method provided in an embodiment of the present application is as follows: Figure 5 As shown, the specific implementation method can be:
[0099] Abnormal event detection is performed on the image based on the abnormal event detection model. If an abnormal event (A) is detected with a confidence level (w1), feature extraction is performed on the image area corresponding to the abnormal event based on the feature extraction model corresponding to the application scenario to determine the abnormal event feature (X1).
[0100] Traverse the false alarm event features in the preset feature library. During the traversal process, for the currently traversed false alarm event features, calculate the similarity (l) between the abnormal event features and the false alarm event features (Lx).
[0101] If the similarity is greater than or equal to the similarity threshold (r) within the feature cluster, the abnormal event is determined to be a false alarm event.
[0102] If the similarity is less than the similarity threshold (r) within the feature cluster, it is left to the user to determine whether the abnormal event is a false alarm;
[0103] If the user determines that the abnormal event is not a false alarm, the abnormal event is determined to be an actual abnormal event.
[0104] If the user determines that the abnormal event is a false alarm event, the maximum similarity between the abnormal event feature and the false alarm event feature is determined, and the corresponding false alarm event feature is the target false alarm event feature.
[0105] If the maximum similarity is less than or equal to the similarity threshold (th) between feature clusters, the abnormal event feature is added to the preset feature library as a new false alarm event feature.
[0106] If the similarity is greater than the similarity threshold between feature clusters, the first confidence (w1) of the abnormal event feature is compared with the second confidence (w) of the false alarm event feature.
[0107] If the first confidence level is less than the second confidence level, the abnormal event feature is added to the preset feature library as a new false alarm event feature.
[0108] If the first confidence is greater than or equal to the second confidence, the abnormal event feature is added to the preset feature library as a new false alarm event feature and marked as a first candidate feature, and the target false alarm event feature is marked as a second candidate feature.
[0109] If the number of times subsequent abnormal events are determined to be false alarms by similarity comparison with the first candidate feature within a preset time is greater than the number of times subsequent abnormal events are determined to be false alarms by similarity comparison with the second candidate feature, the first candidate feature replaces the second candidate feature.
[0110] Figure 6 FIG. 1 is a flow chart of the process of determining the similarity threshold between feature clusters in the embodiment of the present application. Figure 6 As shown, the process of determining the similarity threshold between feature clusters includes: (taking the construction of an abnormal event sample library as an example, the process of constructing a false report event sample library to determine the similarity threshold between feature clusters is similar. The historical abnormal event sample library can be constructed based on actual historical abnormal events, or the historical false report event sample library can be constructed based on historical false report events, or both sample libraries can be used for iteration)
[0111] Set the initial similarity threshold between feature clusters corresponding to the preset feature library.
[0112] Build a sample library of abnormal events.
[0113] According to the false data processing method, Figure 5 The complete process in the above code is to process false report data of abnormal event sample library and determine the event recall rate.
[0114] If the recall rate of the abnormal event is less than the first preset recall rate, the similarity threshold between feature clusters is reduced.
[0115] If the recall rate of the abnormal event is greater than the first preset recall rate, the similarity threshold between feature clusters is increased.
[0116] If the recall rate of the abnormal event is consistent with the preset recall rate, the iteration is stopped and the current similarity threshold between feature clusters is used as the final similarity threshold between feature clusters.
[0117] Figure 7This is a schematic diagram of the structure of a false data processing device provided in an embodiment of the present application. The device can execute the false data processing method provided in any embodiment of the present application and has the corresponding functional modules and beneficial effects of the execution method. Figure 7 As shown, the device comprises:
[0118] The abnormal event feature extraction module 410 is used to extract features from the image area corresponding to the abnormal event to determine the abnormal event features if an abnormal event is detected during abnormal event detection based on the abnormal event detection model.
[0119] A similarity comparison module 420 is used to compare the abnormal event features with the false alarm event features in a preset feature library; wherein the preset feature library is determined based on the features determined as false alarm events in the historical abnormal event detection process;
[0120] The actual detection result determination module 430 is used to determine the actual detection result of the abnormal event according to the similarity comparison result between the false alarm event feature and the abnormal event feature.
[0121] In the embodiment of the present application, the similarity comparison module 420 determines the actual detection result of the abnormal event according to the similarity comparison result between the false alarm event feature and the abnormal event feature, including:
[0122] If the similarity between the false alarm event feature and the abnormal event feature is greater than or equal to the similarity threshold within the feature cluster, then the abnormal event is determined to be a false alarm event;
[0123] If the similarities between all false alarm event features in the preset feature library and the abnormal event features are less than the similarity threshold within the feature cluster, the actual detection result of the abnormal event is determined according to the judgment result of the user.
[0124] In the embodiment of the present application, after determining the actual detection result of the abnormal event according to the judgment result of the user, the device further includes:
[0125] A comparison module, for comparing the similarity between the abnormal event feature and the false alarm feature with a similarity threshold between feature clusters if the actual detection result of the abnormal event is determined to be a false alarm event according to the judgment result of the user;
[0126] The updating module is used to update the preset feature library according to the comparison result of the similarity and the similarity threshold between feature clusters.
[0127] In the embodiment of the present application, the updating module updates the preset feature library according to the comparison result of the similarity and the similarity threshold between feature clusters, including:
[0128] Determine the maximum similarity between the abnormal event feature and the false report event feature, and use the false report event feature corresponding to the maximum similarity as the target false report event feature;
[0129] If the maximum similarity is less than or equal to the similarity threshold between feature clusters, the abnormal event feature is added to the preset feature library as a new false alarm event feature;
[0130] If the maximum similarity is greater than the similarity threshold between feature clusters, the first confidence corresponding to the abnormal event feature is compared with the second confidence of the false alarm event corresponding to the target false alarm event feature; wherein the first confidence is the confidence corresponding to when the abnormal event detection model detects the abnormal event; the second confidence is the confidence corresponding to when the abnormal event detection model detects the false alarm event corresponding to the target false alarm event feature as an abnormal event;
[0131] The preset feature library is updated according to a comparison result of the first confidence level and the second confidence level.
[0132] In the embodiment of the present application, the updating module updates the preset feature library according to the comparison result of the first confidence level and the second confidence level, including:
[0133] If the first confidence level is less than the second confidence level, adding the abnormal event feature as a new false alarm event feature to the preset feature library;
[0134] If the first confidence level is greater than or equal to the second confidence level, the abnormal event feature is added to the preset feature library as a new false alarm event feature and marked as a first candidate feature, and the target false alarm event feature is marked as a second candidate feature;
[0135] If the number of times subsequent abnormal events are determined to be false alarms by similarity comparison with the first candidate feature within a preset time is greater than the number of times subsequent abnormal events are determined to be false alarms by similarity comparison with the second candidate feature, the first candidate feature replaces the second candidate feature.
[0136] In the embodiment of the present application, the device further includes:
[0137] A module for determining the recall rate of personal leave, used to construct an event sample library, process the false report data of the event sample library according to the false report data processing method, and determine the event recall rate;
[0138] The iteration module is used to iteratively adjust the similarity threshold between feature clusters according to the comparison result between the event recall rate and the preset recall rate, until the event recall rate is consistent with the preset recall rate, and obtain the adjusted similarity threshold between feature clusters; wherein the event includes an abnormal event or a false report event.
[0139] In the embodiment of the present application, the preset recall rate includes a first preset recall rate or a second preset recall rate;
[0140] The iteration module iteratively adjusts the similarity threshold between feature clusters according to the comparison result of the recall rate and the preset recall rate, including:
[0141] If the recall rate of the abnormal event is less than the first preset recall rate, reducing the similarity threshold between feature clusters;
[0142] If the recall rate of the abnormal event is greater than the first preset recall rate, increasing the similarity threshold between feature clusters; or,
[0143] If the recall rate of the false alarm events is less than the second preset recall rate, increasing the similarity threshold between the feature clusters;
[0144] If the recall rate of the false alarm events is greater than the second preset recall rate, the similarity threshold between feature clusters is reduced.
[0145] In the embodiment of the present application, the device further includes:
[0146] An initial parameter determination module is used to cluster the false alarm event features in the preset feature library and determine an initial similarity threshold within the feature cluster;
[0147] A first adjustment module, configured to increase the similarity threshold within the feature cluster if the number of false alarm event features in the preset feature library increases to a first preset number;
[0148] The second adjustment module is used to reduce the similarity threshold within the feature cluster if the number of false alarm event features in the preset feature library is reduced to a second preset number.
[0149] In the embodiment of the present application, the device further includes:
[0150] An image sample determination module, used to determine an application scenario for false data processing and to determine an image sample corresponding to the application scenario;
[0151] A loss value determination module is used to input the corresponding image samples into the feature extraction backbone network for training according to the application scenario, and calculate the cross entropy loss value and the triplet loss value;
[0152] A feature extraction model determination module is used to iterate based on the cross entropy loss value and the triplet loss value until an iteration condition is met to obtain a feature extraction model corresponding to the application scenario.
[0153] A false data processing device provided in an embodiment of the present application can execute a false data processing method provided in any embodiment of the present application, and has functional modules and beneficial effects corresponding to the execution method.
[0154] Figure 8 A schematic diagram of an electronic device 10 that can be used to implement an embodiment of the present application is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices (such as helmets, glasses, watches, etc.) and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present application described and / or required herein.
[0155] like Figure 8 As shown, the electronic device 10 includes at least one processor 11, and a memory connected to the data processing of the at least one processor 11, such as a read-only memory (ROM) 12, a random access memory (RAM) 13, etc., wherein the memory stores a computer program that can be executed by at least one processor, and the processor 11 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 12 or the computer program loaded from the storage unit 18 to the random access memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the electronic device 10 can also be stored. The processor 11, the ROM 12, and the RAM 13 are connected to each other through a bus 14. The input / output (I / O) interface 15 is also connected to the bus 14.
[0156] A number of components in the electronic device 10 are connected to the I / O interface 15, including: an input unit 16, such as a keyboard, a mouse, etc.; an output unit 17, such as various types of displays, speakers, etc.; a storage unit 18, such as a disk, an optical disk, etc.; and a data processing unit 19, such as a network card, a modem, a wireless data processing transceiver, etc. The data processing unit 19 allows the electronic device 10 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0157] The processor 11 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The processor 11 executes the various methods and processes described above, such as the false data processing method.
[0158] In some embodiments, the false data processing method can be implemented as a computer program, which is tangibly contained in a computer-readable storage medium, such as a storage unit 18. In some embodiments, part or all of the computer program can be loaded and / or installed on the electronic device 10 via the ROM 12 and / or the data processing unit 19. When the computer program is loaded into the RAM 13 and executed by the processor 11, one or more steps of the false data processing method described above can be performed. Alternatively, in other embodiments, the processor 11 can be configured to perform the false data processing method in any other appropriate manner (for example, by means of firmware).
[0159] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0160] The computer programs for implementing the methods of the present application may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer or other programmable data processing device, so that when the computer program is executed by the processor, the functions / operations specified in the flow chart and / or block diagram are implemented. The computer program may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.
[0161] In the context of the present application, a computer-readable storage medium may be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, device, or equipment. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or equipment, or any suitable combination of the foregoing. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0162] To provide interaction with a user, the systems and techniques described herein may be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or trackball) through which the user can provide input to the electronic device. Other types of devices may also be used to provide interaction with the user; for example, the feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form (including acoustic input, voice input, or tactile input).
[0163] The systems and techniques described herein may be implemented in a computing system that includes a backend component (e.g., as a data server), or a computing system that includes a middleware component (e.g., an application server), or a computing system that includes a frontend component (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system may be interconnected by digital data processing (e.g., a data processing network) in any form or medium. Examples of data processing networks include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.
[0164] A computing system may include a client and a server. The client and the server are generally remote from each other and usually interact through a data processing network. The client and server relationship is generated by computer programs running on the respective computers and having a client-server relationship with each other. The server may be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system to solve the defects of difficult management and weak business scalability in traditional physical hosts and VPS services.
[0165] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this application can be executed in parallel, sequentially or in different orders, as long as the information expected by the technical solution of this application can be achieved, and this document is not limited here.
[0166] The above specific implementations do not constitute a limitation on the protection scope of this application. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of this application should be included in the protection scope of this application.
Claims
1. A method for processing false data, characterized in that: The method comprises: If an abnormal event is detected during abnormal event detection of an image based on the abnormal event detection model, feature extraction is performed on the image area corresponding to the abnormal event to determine the abnormal event feature; Comparing the abnormal event features with the false alarm event features in a preset feature library for similarity; wherein the preset feature library is determined based on the features of false alarm events determined in the historical abnormal event detection process; Determining the actual detection result of the abnormal event according to the similarity comparison result between the false alarm event feature and the abnormal event feature; Determining the actual detection result of the abnormal event according to the similarity comparison result between the false report event feature and the abnormal event feature, including: if the similarity between all false report event features in the preset feature library and the abnormal event feature is less than the intra-feature cluster similarity threshold of the feature cluster to which the false report event feature belongs, determining the actual detection result of the abnormal event according to the user's judgment result; wherein the intra-feature cluster similarity threshold is the minimum value of the minimum similarities between the false report event features within each feature cluster; the feature cluster is the cluster to which similar false report event features obtained by clustering false report event features belong; After determining the actual detection result of the abnormal event according to the judgment result of the user, the method further includes: If it is determined according to the judgment result of the user that the actual detection result of the abnormal event is a false alarm event, the similarity between the abnormal event feature and the false alarm event feature is compared with the similarity threshold between feature clusters; wherein the similarity between feature clusters reflects the similarity between different feature clusters; The preset feature library is updated according to the comparison result of the similarity and the similarity threshold between feature clusters.
2. The method according to claim 1, characterized in that Determining the actual detection result of the abnormal event according to the similarity comparison result between the false alarm event feature and the abnormal event feature includes: If the similarity between the false alarm event feature and the abnormal event feature is greater than or equal to the intra-feature cluster similarity threshold of the feature cluster to which the false alarm event feature belongs, the abnormal event is determined to be a false alarm event.
3. The method according to claim 1, characterized in that The preset feature library is updated according to the comparison result of the similarity and the similarity threshold between feature clusters, including: Determine the maximum similarity between the abnormal event feature and the false report event feature, and use the false report event feature corresponding to the maximum similarity as the target false report event feature; If the maximum similarity is less than or equal to the similarity threshold between feature clusters, the abnormal event feature is added to the preset feature library as a new false alarm event feature; If the maximum similarity is greater than the similarity threshold between feature clusters, the first confidence corresponding to the abnormal event feature is compared with the second confidence of the false alarm event corresponding to the target false alarm event feature; wherein the first confidence is the confidence corresponding to when the abnormal event detection model detects the abnormal event; the second confidence is the confidence corresponding to when the abnormal event detection model detects the false alarm event corresponding to the target false alarm event feature as an abnormal event; The preset feature library is updated according to a comparison result of the first confidence level and the second confidence level.
4. The method according to claim 3, characterized in that Updating the preset feature library according to the comparison result of the first confidence level and the second confidence level includes: If the first confidence level is less than the second confidence level, adding the abnormal event feature as a new false alarm event feature to the preset feature library; If the first confidence level is greater than or equal to the second confidence level, the abnormal event feature is added to the preset feature library as a new false alarm event feature and marked as a first candidate feature, and the target false alarm event feature is marked as a second candidate feature; If the number of times subsequent abnormal events are determined to be false alarms by similarity comparison with the first candidate feature within a preset time is greater than the number of times subsequent abnormal events are determined to be false alarms by similarity comparison with the second candidate feature, the first candidate feature replaces the second candidate feature.
5. The method according to claim 1, characterized in that The process of determining the similarity threshold between feature clusters includes: Constructing an event sample library, processing false report data on the event sample library according to the false report data processing method, and determining the event recall rate; According to the comparison result between the event recall rate and the preset recall rate, the similarity threshold between feature clusters is adjusted and iterated until the event recall rate is consistent with the preset recall rate, thereby obtaining the adjusted similarity threshold between feature clusters; wherein the event includes an abnormal event or a false report event.
6. The method according to claim 1, characterized in that The process of constructing the feature extraction model used to extract features from the image area corresponding to the abnormal event includes: Determining an application scenario for false data processing, and determining image samples corresponding to the application scenario; According to the application scenario, the corresponding image samples are input into the feature extraction backbone network for training, and the cross entropy loss value and the triplet loss value are calculated; Iteration is performed based on the cross entropy loss value and the triplet loss value until an iteration condition is met, thereby obtaining a feature extraction model corresponding to the application scenario.
7. A false data processing device, characterized in that: The device comprises: An abnormal event feature extraction module is used to extract features from an image area corresponding to the abnormal event to determine abnormal event features if an abnormal event is detected during abnormal event detection based on an abnormal event detection model; A similarity comparison module is used to compare the characteristics of the abnormal event with the characteristics of false alarm events in a preset feature library; wherein the preset feature library is determined based on the characteristics of false alarm events determined in the historical abnormal event detection process; An actual detection result determination module, used to determine the actual detection result of the abnormal event according to the similarity comparison result between the false alarm event feature and the abnormal event feature; The similarity comparison module determines the actual detection result of the abnormal event according to the similarity comparison result between the false report event feature and the abnormal event feature, including: if the similarity between all false report event features in the preset feature library and the abnormal event feature is less than the similarity threshold within the feature cluster, then the actual detection result of the abnormal event is determined according to the judgment result of the user; wherein the similarity threshold within the feature cluster is the minimum value of the minimum similarities between the false report event features within each feature cluster; the feature cluster is the cluster to which similar false report event features obtained by clustering the false report event features belong; After determining the actual detection result of the abnormal event according to the judgment result of the user, the device further includes: A comparison module, for comparing the similarity between the abnormal event feature and the false alarm feature with a similarity threshold between feature clusters if the actual detection result of the abnormal event is determined to be a false alarm event according to the judgment result of the user; wherein the similarity between feature clusters reflects the similarity between different feature clusters; The updating module is used to update the preset feature library according to the comparison result of the similarity and the similarity threshold between feature clusters.
8. An electronic device, characterized in that: The electronic device comprises: at least one processor; and A memory connected to the at least one processor for data processing; wherein, The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the false data processing method according to any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the false data processing method according to any one of claims 1 to 6 when executed.
Citation Information
Patent Citations
Target detection method and device, equipment and medium
CN117809241A