Abnormality detection method and device, computer equipment and storage medium

By using image information and object detection models in the intelligent central control system to identify and respond to indoor abnormal situations, the problem that existing systems cannot accurately identify abnormal situations is solved, and safety and detection accuracy are improved.

CN120032232APending Publication Date: 2025-05-23GREE ELECTRIC APPLIANCE INC OF ZHUHAI +1
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411925852.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-25
Publication Date
2025-05-23

AI Technical Summary

Technical Problem

The existing intelligent central control system cannot accurately identify indoor abnormal situations, such as fires, dangerous behaviors of children or the elderly, and intrusions by strangers, resulting in greater safety risks.

Method used

By obtaining image information of the target area, determining the scene type, and selecting the corresponding object detection model according to the scene type for abnormality detection. Specifically, it includes: stranger detection model, elderly or children's activity detection model and fire detection model.

Benefits of technology

It improves the accuracy of abnormal situation detection, can quickly identify multiple abnormal situations and automatically take response measures, providing comprehensive security protection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120032232A_ABST
    Figure CN120032232A_ABST
Patent Text Reader

Abstract

The embodiment of the invention relates to an anomaly detection method and device, computer equipment and a storage medium. The method comprises the following steps: acquiring image information in a target area; determining a scene type contained in the image information; determining a target detection model corresponding to the target area according to the scene type; and detecting an abnormal condition in the target area according to the target detection model. Therefore, the corresponding detection model can be determined through different scene types for abnormal condition detection, and the accuracy of abnormal condition detection is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present invention relate to the technical field of indoor abnormal situation detection, and in particular to an abnormality detection method, device, computer equipment and storage medium. Background Art

[0002] With the rapid development of smart home technology, smart central control, as an important part of home intelligent management, has gradually been given more functions. Traditional smart central control systems are mainly used to control home appliances, but their functions are relatively single and cannot meet users' higher demands for security and intelligence.

[0003] Users may encounter abnormal situations at home, such as fire, danger to children or the elderly, or intrusion by strangers. The existing central control system cannot accurately identify the situations occurring indoors, posing a great safety hazard. Therefore, how to improve the accuracy of abnormal situation identification has become an urgent problem to be solved. Summary of the invention

[0004] In view of this, in order to solve the above technical problems or part of the technical problems, the embodiments of the present invention provide an anomaly detection method, an apparatus, a computer device and a storage medium.

[0005] In a first aspect, an embodiment of the present invention provides an anomaly detection method, comprising:

[0006] Acquire image information in the target area;

[0007] Determining the scene type contained in the image information;

[0008] Determining a target detection model corresponding to the target area according to the scene type;

[0009] Anomalies in the target area are detected according to the target detection model.

[0010] In a possible implementation manner, determining the scene type contained in the image information includes:

[0011] When the image information contains an object, obtaining identity information of the object;

[0012] When the identity information includes an unfamiliar object and the identity information does not include a non-unfamiliar object, determining that the scene type is a first scene;

[0013] The determining, according to the scene type, a target detection model corresponding to the target area includes:

[0014] It is determined that the target detection model corresponding to the first scene is a first model, and the first model is used to detect abnormal behavior of unfamiliar objects.

[0015] In a possible implementation manner, determining the scene type contained in the image information includes:

[0016] When the identity information includes a non-strange object, obtaining age information corresponding to the non-strange object;

[0017] When the age information is within a preset age range, determining the scene type to be a second scene;

[0018] The determining, according to the scene type, a target detection model corresponding to the target area includes:

[0019] Determine that the target detection model corresponding to the second scene is a second model, and the second model is used to detect dangerous behaviors of objects within a preset age range.

[0020] In a possible implementation manner, determining the scene type contained in the image information includes:

[0021] When the image information contains a preset fire feature, determining the scene type is a third scene;

[0022] The determining, according to the scene type, a target detection model corresponding to the target area includes:

[0023] It is determined that the target detection model corresponding to the third scene is a third model, and the third model is used to detect whether a fire occurs in the target area.

[0024] In a possible implementation, the method further includes:

[0025] When the first model detects that an unfamiliar object in the target area performs a preset abnormal behavior, an alarm operation is triggered;

[0026] Or, when a non-strange object within a preset age range is detected by the second model and performs a preset dangerous behavior, an alarm operation is triggered;

[0027] Or, when a fire is detected in the target area through the third model, an alarm operation is triggered.

[0028] In a possible implementation manner, before acquiring image information within the target area, the method further includes:

[0029] Acquire multiple abnormal behavior images as training sets and input them into a first initial model for training until the model converges to obtain a trained first model;

[0030] A plurality of dangerous behaviors corresponding to the first age range and a plurality of dangerous behavior images corresponding to the second age range are obtained as training sets and input into a second initial model for training until the model converges to obtain a trained second model;

[0031] A plurality of fire images are obtained as training sets and input into the third initial model for training until the model converges to obtain a trained third model.

[0032] In a possible implementation, the method further includes:

[0033] When the target area includes two or more scene types at the same time, the scene priority corresponding to each scene type is obtained, and the scene priority is: the third scene is greater than the second scene and greater than the first scene;

[0034] When an abnormal situation in the target area is detected by two or more target detection models, an alarm operation is triggered according to the scene priority.

[0035] In a second aspect, an embodiment of the present invention provides an abnormality detection device, including:

[0036] An acquisition module, used for acquiring image information in a target area;

[0037] A determination module, used to determine the scene type contained in the image information;

[0038] The determination module is further used to determine the target detection model corresponding to the target area according to the scene type;

[0039] A detection module is used to detect abnormal conditions in the target area according to the target detection model.

[0040] In a third aspect, an embodiment of the present invention provides a computer device, comprising: a processor and a memory, wherein the processor is used to execute an anomaly detection program stored in the memory to implement the anomaly detection method described in any one of the first aspects above.

[0041] In a fourth aspect, an embodiment of the present invention provides a storage medium, wherein the storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the anomaly detection method described in any one of the first aspects above.

[0042] The abnormality detection solution provided by the embodiment of the present invention obtains image information in the target area; determines the scene type contained in the image information; determines the target detection model corresponding to the target area according to the scene type; and detects abnormalities in the target area according to the target detection model. In this way, the corresponding detection model can be determined according to different scene types to perform abnormality detection, thereby improving the accuracy of abnormality detection. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] Figure 1 A flowchart of an anomaly detection method provided by an embodiment of the present invention;

[0044] Figure 2 A flowchart of another anomaly detection method provided by an embodiment of the present invention;

[0045] Figure 3 A schematic diagram of the structure of an abnormality detection device provided by an embodiment of the present invention;

[0046] Figure 4 A schematic diagram of the structure of a computer device provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0047] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are 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.

[0048] To facilitate understanding of the embodiments of the present invention, specific embodiments will be further explained below in conjunction with the accompanying drawings. The embodiments do not constitute a limitation on the embodiments of the present invention.

[0049] Figure 1 A flowchart of an abnormality detection method provided by an embodiment of the present invention is shown in FIG. Figure 1 As shown, the method specifically includes:

[0050] S11, acquiring image information in the target area.

[0051] The anomaly detection method provided in an embodiment of the present invention is applied to a computer device, which may include but is not limited to: an intelligent central control system, a smart home device, a server, a desktop computer, etc. This embodiment is described with the computer device as an intelligent central control system, and specifically determines the corresponding detection model to perform abnormal situation detection by identifying different scene types in the current target area.

[0052] In this embodiment, the target area refers to a specific area indoors, such as a living room, a bedroom or a kitchen, for collecting image information. The central control system can integrate an image acquisition device (such as a camera) and a processing module to obtain and analyze the image information in the target area. At the same time, based on deep learning technologies (such as convolutional neural network, CNN), the collected image information can be analyzed.

[0053] Specifically, the intelligent central control system obtains the image information of the target area in real time through the camera installed in the target area. The collected image information may include but is not limited to: environmental status (such as light change), human activities (such as personnel position, posture), specific objects (such as children, the elderly, pets, dangerous goods).

[0054] S12. Determine the scene type included in the image information.

[0055] In this embodiment, the scene type may include: the object present is a stranger, the object present is within a preset age range, there is a fire hazard in the target area, etc.

[0056] The system inputs the image into the image processing module. Through face recognition technology, the face of the object in the image is compared with the registered user database in the local or cloud. If no match is found, it is determined as a stranger. Using human features (such as age estimation model) or registered information, it is judged whether the target object in the image is an elderly person or a child within the preset age range. Based on features such as smoke and open fire in the image, potential hazards are identified through a fire detection algorithm.

[0057] S13. Determine the target detection model corresponding to the target area according to the scene type.

[0058] In this embodiment, multiple monitoring models are pre-trained to detect abnormal situations under different scene types. According to the identified scene type, the target detection model corresponding to the scene type is selected from the pre-constructed detection model library. Each scene type corresponds to a monitoring model:

[0059] If the scene type is the presence of a stranger, a stranger detection model is selected. If the scene type is the presence of an elderly person or a child, an elderly or child activity detection model is selected. If the scene type is the presence of a fire hazard, a fire detection model is selected. If there are multiple scene types at the same time, multiple target detection models can be determined simultaneously.

[0060] S14. Detect the abnormal situation in the target area according to the target detection model.

[0061] In this embodiment, after determining the target detection model, the target detection model corresponding to the scene is applied to the current image information to detect the abnormal situation in the target area, including:

[0062] The stranger detection model is used to detect whether the stranger's behavior is abnormal (for example, taking or searching for items in the target area); the elderly or children's activity detection model is used to detect whether the elderly have dangerous actions such as falling, whether the children are close to the dangerous area, etc.; the fire detection model is used to detect whether there is smoke, open flames or other fire conditions. The corresponding processing operations are performed according to the detected abnormal conditions: when the stranger's behavior is abnormal, an alarm is triggered, a notification is sent to the user, and surveillance recording is started; when the elderly or children exhibit dangerous behavior, voice prompts are given or reminders are sent to the user to prevent danger from occurring. When a fire is detected, the fire alarm device is triggered or the relevant department is notified.

[0063] At the same time, the system will store the detected anomalies and related image data for subsequent analysis and model optimization; if false positives or negatives occur in the detection, the user can provide feedback information to further improve the accuracy of the target detection model.

[0064] In one possible implementation, the central control system software is developed in advance to realize the connection control and management of the equipment, complete the deployment of the algorithm, configure the user interface and convenient operation mode. At the same time, it ensures smooth communication and requires real-time display of image problems and warnings.

[0065] The anomaly detection method provided by the embodiment of the present invention obtains image information within the target area; determines the scene type contained in the image information; determines the target detection model corresponding to the target area according to the scene type; and detects abnormal conditions within the target area according to the target detection model. In this way, the detection model can be dynamically switched for different scene types to ensure the accuracy and efficiency of target detection. Each target detection model is pre-trained and optimized for a specific scenario, and can accurately identify abnormal conditions and reduce false alarms. The system can quickly identify a variety of abnormal conditions and automatically take response measures to provide users with all-round security protection. The efficiency and accuracy of anomaly detection are significantly improved, providing important support for the security management function of the intelligent central control system.

[0066] Figure 2 A flowchart of another anomaly detection method provided by an embodiment of the present invention is shown as follows: Figure 2 As shown, the method specifically includes:

[0067] S21, obtaining a plurality of abnormal behavior images as training sets and inputting them into a first initial model for training until the model converges to obtain a trained first model;

[0068] S22, obtaining multiple dangerous behaviors corresponding to the first age range and multiple dangerous behavior images corresponding to the second age range as training sets and inputting them into a second initial model for training until the model converges to obtain a trained second model;

[0069] S23, obtaining a plurality of fire images as training sets and inputting them into a third initial model for training until the model converges to obtain a trained third model.

[0070] In this embodiment, a deep learning model is selected for training. A suitable deep learning model can be selected according to the characteristics of the task and the size of the data set, such as a convolutional neural network (CNN), a recurrent neural network (RNN), a long short-term memory network (LSTM), a Transformer, a YOLOv8 and other different models, and the model is determined according to the best use scenario of the model to complete the task. Use a large-scale image data set for self-supervised learning to train the initial model. During the training process, a GPU or other high-performance computing device can be used to improve the training efficiency. Monitor indicators such as the loss function and accuracy during the training process to ensure the effectiveness of the model training. Model fine-tuning and optimization: Use the image data set of the target task to fine-tune the pre-trained model. During the fine-tuning process, the hyperparameters of the model such as the number of layers and learning rate can be adjusted as needed.

[0071] In this embodiment, the YOLOv8 model with the best current effect can be selected for training, and then the model can be optimized according to the current object to be detected, and YOLOv8 is selected as the basic target detection model. The reasons include: YOLOv8 has efficient detection performance and low computing cost; it has strong detection capabilities for small targets and is suitable for the recognition of small targets such as children's behavior and smoke.

[0072] Different images are obtained in advance as training sets for different models, including: obtaining a variety of abnormal behavior images as training sets, such as strangers taking items in the target area, etc. Collecting specific dangerous behavior images of the first age range (such as children) and the second age range (such as the elderly) as training sets. Obtain fire-related images including smoke, open flames, small flames, etc. as training sets.

[0073] To meet the detection requirements of small target objects and specific risky actions, the structure of the YOLOv8 model is optimized, including adding a detection head and adjusting the training process. Specifically:

[0074] 1. Collect and annotate images containing unauthorized behaviors or specific abnormal behaviors, and input them into the first initial model as training data for training, so as to obtain a trained first model for detecting abnormal behaviors of strangers;

[0075] 2. For different age ranges (such as children and the elderly), collect and annotate images of specific dangerous behaviors, which are used to train the second initial model, and obtain the trained second model for age-related dangerous behavior detection;

[0076] 3. Collect fire-related images such as open flames and smoke, input them into the third initial model for training, and obtain the trained third model for fire detection.

[0077] According to the characteristics of the current target to be detected (such as small targets, complex backgrounds, etc.), the structure of the YOLOv8 model is optimized, including: detection head optimization, adding a detection head specifically for detecting small targets, expanding the receptive field, and improving the detection ability of small targets; the training process is simplified, and the learning rate, data enhancement strategy and loss function weight during training are adjusted to enable the model to focus on small targets and key risk actions more efficiently.

[0078] S24, acquiring image information in the target area.

[0079] In this embodiment, similar to step S11, the specific Figure 1 For the sake of brevity, the relevant content will not be elaborated here.

[0080] S25. When the image information contains an object, obtain the identity information of the object; when the identity information contains an unfamiliar object and the identity information does not contain a non-unfamiliar object, determine that the scene type is a first scene. Determine that the target detection model corresponding to the first scene is a first model, and the first model is used to detect abnormal behavior of unfamiliar objects.

[0081] S26: When the first model detects that an unfamiliar object in the target area performs a preset abnormal behavior, an alarm operation is triggered.

[0082] In this embodiment, when the image information contains an object (human body), the system analyzes the object in the image information through the identity recognition module, extracts the identity information of the object, and compares the identity information with the registered non-strange object database (such as family members or authorized personnel) to determine whether the current object is a strange object or a non-strange object.

[0083] If the identity information in the image information only contains strange objects and does not contain any non-strange objects, the scene type is determined to be the first scene. According to the first scene type, select the first model from the target detection model library; the first model is a detection model specifically for the abnormal behaviors of strange objects and is pre-trained through an abnormal behavior data set. Continuously obtain the image information or video information of the target area, input the obtained information into the first model, and detect whether there are any abnormal behaviors of the strange objects. Abnormal behaviors include, but are not limited to: unauthorized access, long-term stay, attempt to activate the device, take items, rummage through items, etc. If an abnormal behavior is detected, send an alarm notification to the user's mobile phone; activate the alarm device (such as an audible and visual alarm) in the target area; start the surveillance video to record the process of the abnormal behavior, etc. At the same time, the system stores the abnormal behavior and related image data for subsequent analysis; the user can provide feedback on the abnormal behavior to further optimize the detection accuracy of the first model.

[0084] In a possible implementation, when both strange objects and non-strange objects exist in the target area, it indicates that the strange objects are brought into the target area by the non-strange objects and no danger will occur, and the steps of abnormal behavior recognition may not be executed.

[0085] S27. When the identity information contains non-strange objects, obtain the age information corresponding to the non-strange objects; when the age information is within a preset age range, determine the scene type to be the second scene; determine the target detection model corresponding to the second scene to be the second model, and the second model is used to detect the dangerous behaviors of objects within the preset age range.

[0086] S28. When it is detected through the second model that a non-strange object within the preset age range performs a preset dangerous behavior, trigger an alarm operation.

[0087] In this embodiment, if the identity information contains non-strange objects, the corresponding age information is further extracted. If the age information of the non-strange object is within a preset age range (such as children or the elderly), the scene type is determined to be the second scene; otherwise, continue to monitor other scene types. The age information can be pre-entered in the database for different objects, and the corresponding age information can be determined from the database after the object identity is determined. According to the second scene type, select the second model from the target detection model library; the second model is a detection model specifically for the dangerous behaviors of objects within the preset age range and is pre-trained through a dangerous behavior data set. Input the image information into the second model to detect whether the non-strange objects within the preset age range perform dangerous behaviors; dangerous behaviors include, but are not limited to: children approaching kitchen stoves, electrical appliances or other dangerous areas; the elderly falling, not moving for a long time, etc.

[0088] When dangerous behavior is detected through the second model, the alarm operation is triggered: sending an alarm notification to the user's mobile phone; activating the sound and light alarm device in the area; recording the relevant video or image data of the dangerous behavior. The system stores the detection results and alarm records for subsequent behavior analysis and model optimization; users can provide feedback on the alarm results to further improve the detection performance of the second model.

[0089] S29. When the image information contains preset fire features, determine that the scene type is a third scene; determine that the target detection model corresponding to the third scene is a third model, and the third model is used to detect whether a fire occurs in the target area.

[0090] S30: When a fire is detected in the target area through the third model, an alarm operation is triggered.

[0091] In this embodiment, the system analyzes the image information through the fire feature recognition module to determine whether it contains preset fire features: appearance features such as smoke and flame shape; brightness and color features of the fire; (optionally) combining infrared images to determine the temperature changes in the target area, when the temperature difference between multiple areas is large, it is determined that there is a fire feature, or when the temperature of a certain area is greater than the preset temperature threshold, it is determined that there is a fire feature, or when smoke is obtained by the smoke sensor, it is determined that there is a fire feature.

[0092] If the image information contains at least one fire feature, the scene type is determined to be the third scene; if no fire feature is detected, the monitoring and processing of other scenes will continue. According to the third scene type, a third model is selected from the target detection model library; the third model is trained with a fire-related image data set (including smoke, open flames, flames, etc.) and is used to further determine the fire situation. The image information is input into the third model to detect whether a fire occurs in the target area; the fire judgment criteria include but are not limited to: the range and concentration of smoke diffusion; the duration and size of the flame; whether the highlight area meets the preset highlight area of ​​the fire image.

[0093] If the third model confirms that a fire has occurred in the target area, the alarm operation is triggered: a fire alarm is sent to the user's mobile phone or home smart system; the sound and light alarm devices in the area are activated; the surveillance video is started to record the fire situation; the fire protection system is linked to send a fire alarm to the property or fire department. The system stores fire-related images and detection results for subsequent analysis and verification; users can provide feedback on the accuracy of the fire alarm to further optimize the performance of the third model.

[0094] In one possible implementation, when the target area includes two or more scene types at the same time, the scene priority corresponding to each scene type is obtained; when an abnormal situation in the target area is detected by two or more target detection models, an alarm operation is triggered according to the scene priority.

[0095] In this embodiment, when multiple scene types are detected at the same time, the scene priority of each scene type is obtained. Arrange the scene types in order of priority: the third scene> the second scene> the first scene; give priority to scene types with higher priorities and their corresponding anomaly detection tasks. Select the target detection model according to the scene priority and perform the detection: if the third scene is detected, the third model is preferentially called to detect fire-related abnormalities; if the third scene is not detected, the second model is sequentially called to detect dangerous behaviors of objects within a preset age range; if the second scene is not detected, the first model is called to detect abnormal behaviors of unfamiliar objects. If an abnormality in the target area is detected by the target detection model, an alarm operation is triggered according to the priority to avoid repeated alarms; if multiple target detection models detect an abnormality at the same time, an alarm can be issued at the same time, or according to the priority, and the abnormalities with higher priorities are displayed preferentially in the alarm content, and other abnormal situation information is recorded for user reference.

[0096] The anomaly detection method provided by the embodiment of the present invention accurately identifies abnormal situations in the target area by combining multiple scene types and target detection models. Multi-scene anomalies are processed according to scene priority to ensure that high-risk events (such as fire) are responded to first and improve alarm efficiency. Comprehensive management of multi-scene anomalies is achieved to avoid duplicate alarms, reduce interference, and fully record abnormal information. Through intelligent detection and alarm mechanisms, human intervention is reduced, fully automated monitoring and safety assurance are achieved, and the practicality and reliability of the system are improved.

[0097] Figure 3 A schematic diagram of the structure of an abnormality detection device provided by an embodiment of the present invention is shown in FIG. Figure 3 As shown, the device specifically includes:

[0098] An acquisition module 31 is used to acquire image information in a target area;

[0099] A determination module 32, configured to determine the scene type contained in the image information;

[0100] The determination module is further used to determine the target detection model corresponding to the target area according to the scene type;

[0101] The detection module 33 is used to detect abnormal conditions in the target area according to the target detection model.

[0102] In a possible implementation manner, the acquisition module is specifically configured to acquire identity information of an object when the image information contains the object;

[0103] The determination module is specifically configured to determine that the scene type is the first scene when the identity information includes an unfamiliar object and the identity information does not include a non-unfamiliar object;

[0104] It is determined that the target detection model corresponding to the first scene is a first model, and the first model is used to detect abnormal behavior of unfamiliar objects.

[0105] In a possible implementation manner, the acquisition module is specifically configured to acquire age information corresponding to a non-strange object when the identity information includes a non-strange object;

[0106] The determination module is specifically configured to determine that the scene type is the second scene when the age information is within a preset age range;

[0107] Determine that the target detection model corresponding to the second scene is a second model, and the second model is used to detect dangerous behaviors of objects within a preset age range.

[0108] In a possible implementation manner, the determination module is specifically configured to determine that the scene type is a third scene when the image information contains a preset fire feature;

[0109] It is determined that the target detection model corresponding to the third scene is a third model, and the third model is used to detect whether a fire occurs in the target area.

[0110] In a possible implementation, the alarm module 34 is configured to trigger an alarm operation when the first model detects that an unfamiliar object in the target area performs a preset abnormal behavior;

[0111] Or, when a non-strange object within a preset age range is detected by the second model and performs a preset dangerous behavior, an alarm operation is triggered;

[0112] Or, when a fire is detected in the target area through the third model, an alarm operation is triggered.

[0113] In a possible implementation, the training module 35 is used to obtain a plurality of abnormal behavior images as training sets and input them into a first initial model for training until the model converges to obtain a trained first model;

[0114] A plurality of dangerous behaviors corresponding to the first age range and a plurality of dangerous behavior images corresponding to the second age range are obtained as training sets and input into a second initial model for training until the model converges to obtain a trained second model;

[0115] A plurality of fire images are obtained as training sets and input into the third initial model for training until the model converges to obtain a trained third model.

[0116] In a possible implementation manner, the acquisition module is further used to acquire a scene priority corresponding to each scene type when the target area includes two or more scene types at the same time, and the scene priority is: the third scene is greater than the second scene and greater than the first scene;

[0117] The alarm module is also used to trigger an alarm operation according to the scene priority when an abnormal situation in the target area is detected by two or more target detection models.

[0118] The abnormality detection device provided in this embodiment can be as follows Figure 3 The device shown in FIG. 1 can perform the following steps: Figure 1-2 All steps of the anomaly detection method in Figure 1-2 For details, please refer to Figure 1-2 For the sake of brevity, the relevant description is not repeated here.

[0119] Figure 4 A schematic diagram of the structure of a computer device provided by an embodiment of the present invention, Figure 4 The computer device 400 shown includes: at least one processor 401, a memory 402, at least one network interface 404 and other user interfaces 403. The various components in the computer device 400 are coupled together via a bus system 405. It is understood that the bus system 405 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 405 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, the bus system 405 is not shown in FIG. Figure 4 Various buses are labeled as bus system 405 .

[0120] The user interface 403 may include a display, a keyboard, or a pointing device (eg, a mouse, a trackball, a touch pad, or a touch screen).

[0121] It can be understood that the memory 402 in the embodiment of the present invention can be a volatile memory or a non-volatile memory, or can include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory can be a random access memory (RAM), which is used as an external cache. By way of example but not limitation, many forms of RAM are available, such as static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct RAM bus random access memory (DRRAM). The memory 402 described herein is intended to include, but is not limited to, these and any other suitable types of memory.

[0122] In some implementations, the memory 402 stores the following elements, executable units or data structures, or a subset thereof, or an extended set thereof: an operating system 4021 and application programs 4022 .

[0123] The operating system 4021 includes various system programs, such as a framework layer, a core library layer, a driver layer, etc., which are used to implement various basic services and process hardware-based tasks. The application 4022 includes various application programs, such as a media player (Media Player), a browser (Browser), etc., which are used to implement various application services. The program for implementing the method of the embodiment of the present invention can be included in the application 4022.

[0124] In the embodiment of the present invention, by calling the program or instruction stored in the memory 402, specifically, the program or instruction stored in the application 4022, the processor 401 is used to execute the method steps provided by each method embodiment, for example, including:

[0125] Acquire image information in the target area;

[0126] Determining the scene type contained in the image information;

[0127] Determining a target detection model corresponding to the target area according to the scene type;

[0128] Anomalies in the target area are detected according to the target detection model.

[0129] In a possible implementation, when the image information includes an object, obtaining identity information of the object;

[0130] When the identity information includes an unfamiliar object and the identity information does not include a non-unfamiliar object, determining that the scene type is a first scene;

[0131] The determining, according to the scene type, a target detection model corresponding to the target area includes:

[0132] It is determined that the target detection model corresponding to the first scene is a first model, and the first model is used to detect abnormal behavior of unfamiliar objects.

[0133] In a possible implementation manner, when the identity information includes a non-strange object, obtaining age information corresponding to the non-strange object;

[0134] When the age information is within a preset age range, determining the scene type to be a second scene;

[0135] The determining, according to the scene type, a target detection model corresponding to the target area includes:

[0136] Determine that the target detection model corresponding to the second scene is a second model, and the second model is used to detect dangerous behaviors of objects within a preset age range.

[0137] In a possible implementation, when the image information includes a preset fire feature, determining the scene type as a third scene;

[0138] The determining, according to the scene type, a target detection model corresponding to the target area includes:

[0139] It is determined that the target detection model corresponding to the third scene is a third model, and the third model is used to detect whether a fire occurs in the target area.

[0140] In a possible implementation, when the first model detects that an unfamiliar object in the target area performs a preset abnormal behavior, an alarm operation is triggered;

[0141] Or, when a non-strange object within a preset age range is detected by the second model and performs a preset dangerous behavior, an alarm operation is triggered;

[0142] Or, when a fire is detected in the target area through the third model, an alarm operation is triggered.

[0143] In a possible implementation, a plurality of abnormal behavior images are obtained as training sets and input into a first initial model for training until the model converges to obtain a trained first model;

[0144] A plurality of dangerous behaviors corresponding to the first age range and a plurality of dangerous behavior images corresponding to the second age range are obtained as training sets and input into a second initial model for training until the model converges to obtain a trained second model;

[0145] A plurality of fire images are obtained as training sets and input into the third initial model for training until the model converges to obtain a trained third model.

[0146] In a possible implementation manner, when the target area includes two or more scene types at the same time, the scene priority corresponding to each scene type is obtained, and the scene priority is: the third scene is greater than the second scene and greater than the first scene;

[0147] When an abnormal situation in the target area is detected by two or more target detection models, an alarm operation is triggered according to the scene priority.

[0148] The method disclosed in the above embodiment of the present invention can be applied to the processor 401, or implemented by the processor 401. The processor 401 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit in the processor 401 or the instruction in the form of software. The above processor 401 can be a general processor, a digital signal processor (Digital Signal Processor, DSP), an application specific integrated circuit (Application Specific Integrated Circuit, ASIC), a field programmable gate array (Field Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present invention can be implemented or executed. The general processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in the embodiment of the present invention can be directly embodied as a hardware decoding processor to execute, or the hardware and software units in the decoding processor can be executed. The software unit can be located in a mature storage medium in the field such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory 402, and the processor 401 reads the information in the memory 402 and completes the steps of the above method in combination with its hardware.

[0149] It is understood that the embodiments described herein may be implemented in hardware, software, firmware, middleware, microcode, or a combination thereof. For hardware implementation, the processing unit may be implemented in one or more application specific integrated circuits (ASIC), digital signal processors (DSP), digital signal processing devices (DSPDevice, DSPD), programmable logic devices (PLD), field programmable gate arrays (FPGA), general purpose processors, controllers, microcontrollers, microprocessors, other electronic units for performing the functions described in the present application, or a combination thereof.

[0150] For software implementation, the technology described herein can be implemented by a unit that performs the functions described herein. The software code can be stored in a memory and executed by a processor. The memory can be implemented in the processor or outside the processor.

[0151] The computer device provided in this embodiment may be Figure 4 The computer device shown in , can execute Figure 1-2 All steps of the anomaly detection method in Figure 1-2 For details, please refer to Figure 1-2 For the sake of brevity, the relevant description is not repeated here.

[0152] The embodiment of the present invention also provides a storage medium (computer-readable storage medium). The storage medium here stores one or more programs. The storage medium may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a read-only memory, a flash memory, a hard disk or a solid-state drive; the memory may also include a combination of the above-mentioned types of memory.

[0153] When one or more programs in the storage medium can be executed by one or more processors, the above-mentioned abnormality detection method executed on the device side can be implemented.

[0154] The processor is used to execute the abnormality detection program stored in the memory to implement the following steps of the abnormality detection method performed on the device side:

[0155] Acquire image information in the target area;

[0156] Determining the scene type contained in the image information;

[0157] Determining a target detection model corresponding to the target area according to the scene type;

[0158] Anomalies in the target area are detected according to the target detection model.

[0159] In a possible implementation, when the image information includes an object, obtaining identity information of the object;

[0160] When the identity information includes an unfamiliar object and the identity information does not include a non-unfamiliar object, determining that the scene type is a first scene;

[0161] The determining, according to the scene type, a target detection model corresponding to the target area includes:

[0162] It is determined that the target detection model corresponding to the first scene is a first model, and the first model is used to detect abnormal behavior of unfamiliar objects.

[0163] In a possible implementation manner, when the identity information includes a non-strange object, obtaining age information corresponding to the non-strange object;

[0164] When the age information is within a preset age range, determining the scene type to be a second scene;

[0165] The determining, according to the scene type, a target detection model corresponding to the target area includes:

[0166] Determine that the target detection model corresponding to the second scene is a second model, and the second model is used to detect dangerous behaviors of objects within a preset age range.

[0167] In a possible implementation, when the image information includes a preset fire feature, determining the scene type as a third scene;

[0168] The determining, according to the scene type, a target detection model corresponding to the target area includes:

[0169] It is determined that the target detection model corresponding to the third scene is a third model, and the third model is used to detect whether a fire occurs in the target area.

[0170] In a possible implementation, when the first model detects that an unfamiliar object in the target area performs a preset abnormal behavior, an alarm operation is triggered;

[0171] Or, when a non-strange object within a preset age range is detected by the second model and performs a preset dangerous behavior, an alarm operation is triggered;

[0172] Or, when a fire is detected in the target area through the third model, an alarm operation is triggered.

[0173] In a possible implementation, a plurality of abnormal behavior images are obtained as training sets and input into a first initial model for training until the model converges to obtain a trained first model;

[0174] A plurality of dangerous behaviors corresponding to the first age range and a plurality of dangerous behavior images corresponding to the second age range are obtained as training sets and input into a second initial model for training until the model converges to obtain a trained second model;

[0175] A plurality of fire images are obtained as training sets and input into the third initial model for training until the model converges to obtain a trained third model.

[0176] In a possible implementation manner, when the target area includes two or more scene types at the same time, the scene priority corresponding to each scene type is obtained, and the scene priority is: the third scene is greater than the second scene and greater than the first scene;

[0177] When an abnormal situation in the target area is detected by two or more target detection models, an alarm operation is triggered according to the scene priority.

[0178] The professionals should further realize that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented by electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to the function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0179] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.

[0180] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.

Claims

1. An anomaly detection method, characterized in that: include: Acquire image information in the target area; Determining the scene type contained in the image information; Determining a target detection model corresponding to the target area according to the scene type; Anomalies in the target area are detected according to the target detection model.

2. The method according to claim 1, characterized in that: The determining the scene type contained in the image information includes: When the image information contains an object, obtaining identity information of the object; When the identity information includes an unfamiliar object and the identity information does not include a non-unfamiliar object, determining that the scene type is a first scene; The determining, according to the scene type, a target detection model corresponding to the target area includes: It is determined that the target detection model corresponding to the first scene is a first model, and the first model is used to detect abnormal behavior of unfamiliar objects.

3. The method according to claim 2, characterized in that The determining the scene type contained in the image information includes: When the identity information includes a non-strange object, obtaining age information corresponding to the non-strange object; When the age information is within a preset age range, determining the scene type to be a second scene; The determining, according to the scene type, a target detection model corresponding to the target area includes: Determine that the target detection model corresponding to the second scene is a second model, and the second model is used to detect dangerous behaviors of objects within a preset age range.

4. The method according to claim 3, characterized in that The determining the scene type contained in the image information includes: When the image information contains a preset fire feature, determining the scene type is a third scene; The determining, according to the scene type, a target detection model corresponding to the target area includes: It is determined that the target detection model corresponding to the third scene is a third model, and the third model is used to detect whether a fire occurs in the target area.

5. The method according to claim 4, characterized in that The method further comprises: When the first model detects that an unfamiliar object in the target area performs a preset abnormal behavior, an alarm operation is triggered; Or, when a non-strange object within a preset age range is detected by the second model and performs a preset dangerous behavior, an alarm operation is triggered; Or, when a fire is detected in the target area through the third model, an alarm operation is triggered.

6. The method according to claim 5, characterized in that Before acquiring the image information within the target area, the method further includes: Acquire multiple abnormal behavior images as training sets and input them into a first initial model for training until the model converges to obtain a trained first model; A plurality of dangerous behaviors corresponding to the first age range and a plurality of dangerous behavior images corresponding to the second age range are obtained as training sets and input into a second initial model for training until the model converges to obtain a trained second model; A plurality of fire images are obtained as training sets and input into the third initial model for training until the model converges to obtain a trained third model.

7. The method according to claim 6, characterized in that The method further comprises: When the target area includes two or more scene types at the same time, the scene priority corresponding to each scene type is obtained, and the scene priority is: the third scene is greater than the second scene and greater than the first scene; When an abnormal situation in the target area is detected by two or more target detection models, an alarm operation is triggered according to the scene priority.

8. An abnormality detection device, characterized in that: include: An acquisition module, used for acquiring image information in a target area; A determination module, used to determine the scene type contained in the image information; The determination module is further used to determine the target detection model corresponding to the target area according to the scene type; A detection module is used to detect abnormal conditions in the target area according to the target detection model.

9. A computer device, characterized in that: include: A processor and a memory, wherein the processor is used to execute an abnormality detection program stored in the memory to implement the abnormality detection method according to any one of claims 1 to 7.

10. A storage medium, characterized in that: The storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the abnormality detection method according to any one of claims 1 to 7.

Citation Information

Cited By

  • Production safety inspection method and device, electronic equipment and storage medium

    CN122200288A