State monitoring method, device, equipment and medium
Through deep learning algorithms and video data feature extraction, the problem of low accuracy in fire equipment status monitoring is solved, real-time, automatic fire equipment status monitoring and early warning are achieved, adapting to environmental changes, reducing costs and improving accuracy.
Patent Information
- Application Number
- CN202410797555.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-19
- Publication Date
- 2024-09-17
AI Technical Summary
Existing fire equipment status monitoring methods have low accuracy of monitoring results, and automatic monitoring methods rely on remote viewing and additional hardware modules, which are costly and difficult to adapt to changes in the environment and target appearance.
By determining the preset initial image frames and equipment images, extracting overall features and regional features, calculating similarities, and combining with deep learning algorithms, a fire equipment status abnormality monitoring method based on camera video data is designed to achieve real-time and automatic status monitoring. and early warning to adapt to environmental changes.
It improves the accuracy and stability of fire equipment status monitoring, reduces costs, adapts to changes in the environment and target appearance in real monitoring scenarios, realizes adaptive dynamic update templates, and improves the generalization ability and accuracy of the method.
Smart Images

Figure CN118658099A
Abstract
Description
Technical Field
[0001] The present application relates to the field of image processing, and in particular to a state monitoring method, device, equipment and medium. Background Art
[0002] In modern society, fire safety has become an important part of the public safety system. Firefighting equipment is a key tool for preventing fires, suppressing fires, evacuating people and rescuing trapped people. It has a high application value to effectively monitor the status of firefighting equipment and issue early warnings of abnormal situations in a timely manner.
[0003] At present, most fire equipment status monitoring still uses manual regular inspection methods, while the automatic monitoring method is mostly remote viewing by the management platform through fixed cameras.
[0004] However, the existing condition monitoring methods have the problem that the monitoring results are not accurate enough. Summary of the invention
[0005] The present application provides a condition monitoring method, device, equipment and medium to solve the problem of low accuracy of monitoring results in existing condition monitoring methods.
[0006] In a first aspect, the present application provides a state monitoring method, the method comprising:
[0007] Determining a preset initial image frame, an initial equipment image in the initial image frame, a preset number of continuous image frames, and equipment images in the image frames;
[0008] Determine initial overall features of an initial image frame and initial regional features of an initial device image, overall features of an image frame and regional features of a device image;
[0009] Determine the average similarity of the overall features, the average similarity of the regional features, and the standard similarity corresponding to all image frames according to the overall features and the initial overall features, the regional features and the initial regional features;
[0010] Determine the initial state of the equipment to be monitored based on the average similarity of overall characteristics, the average similarity of regional characteristics, and the standard similarity;
[0011] According to the image continuous sequence of the image frames, the initial state of the target quantity is determined, and according to the initial state of the target quantity, the target state of the equipment to be monitored is determined.
[0012] In the embodiment of the present application, before determining the preset initial image frame, the initial equipment image in the initial image frame, the preset number of continuous image frames, and the equipment image in the image frame, the method further includes:
[0013] Acquire continuous image frames to be detected;
[0014] Determine the portrait image and the equipment image in the image frame according to the preset target detection model;
[0015] Determine the image overlap between the portrait image and the equipment image, and compare the image overlap with a preset image overlap to obtain a comparison result;
[0016] If the comparison result shows that the image overlap is lower than the preset image overlap, it is determined that no image occlusion occurs in the image frame, and the image frame is determined to be the target image frame;
[0017] According to the target image frame, a preset number of continuous image frames is determined.
[0018] In the embodiment of the present application, the average similarity of the overall features, the average similarity of the regional features, and the standard similarity corresponding to all image frames are determined according to the overall features and the initial overall features, the regional features and the initial regional features, including:
[0019] Determine the similarity between the overall feature and the initial overall feature to obtain the overall feature similarity;
[0020] Determine feature similarity between the regional feature and the initial regional feature, and determine the regional feature similarity;
[0021] According to the overall feature similarity and the regional feature similarity, the overall feature average similarity, the regional feature average similarity and the standard similarity are determined.
[0022] In the embodiment of the present application, the overall feature average similarity, the regional feature average similarity, and the standard similarity are determined according to the overall feature similarity and the regional feature similarity, including:
[0023] Determining a preset weight corresponding to each image frame according to the image sequential order of the image frames;
[0024] According to the overall feature similarities corresponding to the image frames and the preset weights, the weighted sum of the overall feature similarities corresponding to all the image frames is determined to obtain the overall feature average similarity;
[0025] According to the regional feature similarities corresponding to the image frames and the preset weights, the weighted sum of the regional feature similarities corresponding to all the image frames is determined to obtain the average regional feature similarity;
[0026] The similarity between all overall feature similarities and regional feature similarities is determined to obtain a standard similarity.
[0027] In the embodiment of the present application, the initial state of the equipment to be monitored is determined according to the average similarity of the overall features, the average similarity of the regional features, and the standard similarity, including:
[0028] Determine a first threshold range, a second threshold range, and a third threshold range according to a preset first similarity, a second similarity, and a third similarity, wherein the third similarity is greater than the second similarity, the second similarity is greater than the first similarity, the first threshold range is a similarity range less than the first similarity, the second threshold range is a similarity range greater than the first similarity and less than the second similarity, and the third threshold range is a range greater than the third similarity;
[0029] Determine the threshold range corresponding to the average similarity of the overall features;
[0030] If the overall feature average similarity corresponds to the first threshold range, the initial state is determined to be an abnormal state;
[0031] If the overall feature average similarity corresponds to the second threshold range, then the regional feature average similarity is compared with a preset regional feature average similarity threshold to obtain a comparison result;
[0032] If the comparison result is that the average similarity of regional features is greater than the preset average similarity threshold of regional features, the initial state is determined to be an abnormal state;
[0033] If the comparison result is that the average similarity of the regional features is not greater than the preset average similarity threshold of the regional features, the initial state is determined to be a pending state;
[0034] If the overall feature average similarity corresponds to the third threshold range, then the standard similarity is compared with a preset standard similarity threshold;
[0035] If the standard similarity is greater than a preset standard similarity threshold, the initial state is determined to be a normal state;
[0036] If the standard similarity is not greater than a preset standard similarity threshold, the initial state is determined to be a pending state.
[0037] In the embodiment of the present application, the initial state of the target quantity is determined according to the image sequence of the image frame, and the target state of the equipment to be monitored is determined according to the initial state of the target quantity, including:
[0038] determining an image sequential order of the image frames;
[0039] Determine the next continuous image frame according to the image sequence, and delete the first image frame of the preset number of continuous image frames to obtain an updated preset number of continuous image frames;
[0040] According to the updated preset number of continuous image frames, repeatedly performing the steps of determining the initial overall features of the initial image frame and the initial regional features of the initial equipment image, the overall features of the image frame and the regional features of the equipment image, and determining the initial state of the equipment to be monitored according to the average similarity of the overall features, the average similarity of the regional features, and the standard similarity, until the initial states of the target number are determined;
[0041] Based on the initial state of the target quantity, the target state is determined.
[0042] In the embodiment of the present application, the target state is determined according to the initial state of the target quantity, including:
[0043] Determine the initial state of the target quantity;
[0044] If the initial states of the target quantity are all normal states, then the target state is determined to be a normal state;
[0045] If the initial states of the target quantity are all abnormal states, then the target state is determined to be an abnormal state;
[0046] If the initial state of the target quantity includes a normal state and an abnormal state, the target state is determined to be a pending state.
[0047] In a second aspect, the present application provides a state monitoring device, the device comprising:
[0048] An image determination module, used to determine a preset initial image frame, an initial equipment image in the initial image frame, a preset number of continuous image frames, and equipment images in the image frames;
[0049] A feature determination module, used to determine the initial overall feature of the initial image frame and the initial regional feature of the initial equipment image, the overall feature of the image frame and the regional feature of the equipment image;
[0050] A similarity determination module is used to determine the average similarity of overall features, the average similarity of regional features, and the standard similarity corresponding to all image frames based on the overall features and the initial overall features, the regional features and the initial regional features;
[0051] An initial state determination module, used to determine the initial state of the equipment to be monitored based on the average similarity of overall features, the average similarity of regional features, and the standard similarity;
[0052] The target state determination module is used to determine the initial state of the target quantity according to the image continuous sequence of the image frames, and determine the target state of the equipment to be monitored according to the initial state of the target quantity.
[0053] In a third aspect, the present application provides a computer device, comprising: a processor, and a memory communicatively connected to the processor;
[0054] Memory stores computer-executable instructions;
[0055] The processor executes the computer-executable instructions stored in the memory to implement the method of the present application.
[0056] In a fourth aspect, the present application provides a computer-readable storage medium, in which program code is stored, and when the program code is executed by a processor, it is used to implement the method of the present application.
[0057] The state monitoring method, device, equipment and medium provided by the present application determine a preset initial image frame, an initial equipment image in the initial image frame, a preset number of continuous image frames, and equipment images in the image frames; determine the initial overall features of the initial image frame and the initial regional features of the initial equipment image, the overall features of the image frame and the regional features of the equipment image; determine the average similarity of the overall features, the average similarity of the regional features, and the standard similarity corresponding to all image frames based on the overall features and the initial overall features, the regional features and the initial regional features; determine the initial state of the equipment to be monitored based on the average similarity of the overall features, the average similarity of the regional features, and the standard similarity; determine the initial state of the target number based on the image continuous order of the image frames, and determine the target state of the equipment to be monitored based on the initial state of the target number.
[0058] In this way, by using only camera video data, an effective deep learning vision algorithm can be designed to monitor the status of different types of fire-fighting equipment in real time and automatically warn; a method for monitoring the abnormal status of fire-fighting equipment suitable for real monitoring scenarios can be designed; there is no need to spend a lot of effort to collect gallery template images in advance, which greatly improves the ease of use of the method; using video as input and considering the target characteristics in continuous time, the stability and robustness of the method are improved; in response to the problem of constantly changing environment and target appearance in monitoring scenarios, a method for adaptive dynamic updating of templates is designed to improve the generalization ability of the method; and feature extraction and similarity calculation methods based entirely on deep learning are used to improve accuracy. BRIEF DESCRIPTION OF THE DRAWINGS
[0059] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0060] Figure 1 A flow chart of a state monitoring method provided in an embodiment of the present application;
[0061] Figure 2 A flow chart of another state monitoring method provided in an embodiment of the present application;
[0062] Figure 3A practical application flow chart of a condition monitoring method provided in an embodiment of the present application;
[0063] Figure 4 A system diagram of a condition monitoring method provided in an embodiment of the present application;
[0064] Figure 5 A schematic diagram of the structure of a state monitoring device provided in an embodiment of the present application;
[0065] Figure 6 This is a structural block diagram of a device for executing a condition monitoring method according to an embodiment of the present application.
[0066] The above-mentioned drawings have shown clear embodiments of the present application, which will be described in more detail below; these drawings and textual descriptions are not intended to limit the scope of the concept of the present application in any way, but to illustrate the concept of the present application to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION
[0067] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are merely examples of devices and methods consistent with some aspects of the present application as detailed in the appended claims.
[0068] Status monitoring is to monitor the real-time status of the equipment to determine whether the equipment is abnormal, wherein the equipment may be fire-fighting equipment or other types of equipment, which is not limited in this embodiment.
[0069] The overall feature is the image feature corresponding to the overall image of the image frame, which can also be understood as the global feature of the image frame, and is used to characterize the overall attribute characteristics of the image, such as color features, texture features, and shape features, such as intensity histograms, etc. Since it is a low-level visual feature at the pixel level, the global feature has the characteristics of good invariance, simple calculation, and intuitive representation.
[0070] Regional features are image features corresponding to specific areas in an image frame, such as features corresponding to equipment areas. They can also be understood as local features in an image frame, features extracted from local areas of an image, including edges, corners, lines, curves, and areas with special attributes. Common local features include two types of descriptions: corner points and regions. Local image features are rich in number, have low correlation between features, and will not affect the detection and matching of other features due to the disappearance of some features in the case of occlusion.
[0071] In the prior art, in the current existing status monitoring methods, some camera image data is only transmitted to the management platform for remote viewing, and no effective automatic recognition is performed; the positioning function and the status monitoring function both use additional hardware modules, which are relatively costly; the maintenance module is not highly compatible with different types of fire-fighting equipment, and the promotion cost is high; some images in the gallery need to be collected in advance, and the quality of the gallery directly affects the similarity calculation results, and the maintenance cost of the gallery is high; it is mainly suitable for situations where the target occupies the main body in the image; the input is 2 images, and the situation of video as input is not considered; in real monitoring application scenarios, it is not considered that the appearance of the environment and objects in the image changes over time.
[0072] In order to solve the above problems, an embodiment of the present application provides a status monitoring method, which can provide a fire equipment status abnormality monitoring method based on fixed camera video data, and automatically, efficiently and stably identify abnormal situations such as loss, misappropriation, damage, and obstruction of fire-fighting equipment in the camera monitoring area by performing feature extraction and similarity calculation on the acquired video image data.
[0073] The technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.
[0074] Figure 1 A flow chart of a state monitoring method provided in an embodiment of the present application. Figure 1 As shown, the condition monitoring method may include the following steps:
[0075] S110: Determine a preset initial image frame, an initial equipment image in the initial image frame, a preset number of continuous image frames, and equipment images in the image frames.
[0076] The preset initial image frame is a pre-set image frame used for comparison with the real-time state of the equipment. The equipment state in the initial image frame is a normal state. The initial image frame can also be understood as a template image frame.
[0077] The initial equipment image is the image corresponding to the equipment to be monitored in the initial image frame, and the equipment in the initial equipment image is the equipment in a normal state; determining the image corresponding to the equipment to be monitored can be performed by image detection through a target detection model, and the target detection model is used to obtain the target image in the image, such as the equipment image and the portrait image. The target detection model can be a yolov8 model, and other commonly used target detectors such as yolov5, SSD, CenterNet, ViT and other convolution-based or Transformer-based models can also be selected.
[0078] The preset quantity is a pre-set quantity, which can be set by the user or determined by other means.
[0079] The continuous image frames are image frames whose image sequence is continuous. The continuous image frames can be obtained by collecting video data of the equipment status in the real scene offline through a camera.
[0080] Based on this, by determining a preset initial image frame, an initial equipment image in the initial image frame, a preset number of continuous image frames, and an equipment image in the image frame, image feature extraction is performed subsequently to obtain image features, and further determine feature similarity, so as to determine the status of the equipment based on the feature similarity.
[0081] S120: Determine initial overall features of the initial image frame and initial regional features of the initial equipment image, overall features of the image frame and regional features of the equipment image.
[0082] Among them, the overall feature is the global feature corresponding to the image frame, and the regional feature is the local feature corresponding to the equipment image; the overall feature and the regional feature can be determined by a preset feature extraction model, such as removing the last fully connected layer of the classification model ResNet50 to obtain an image feature extractor, and the output of the last convolutional layer in the image feature extractor is the feature vector of the input image with a dimension of 2048.
[0083] Based on this, by extracting features from the initial image frame, initial equipment image, image frame, and equipment image, the initial overall features, initial regional features, overall features, and regional features are determined so as to subsequently determine the feature similarity and determine the status of the equipment based on the feature similarity.
[0084] S130 , determining the average similarity of the overall features, the average similarity of the regional features, and the standard similarity corresponding to all the image frames according to the overall features and the initial overall features, the regional features and the initial regional features.
[0085] Among them, the average similarity of overall features can be understood as the degree of continuous change of features between the overall features and the initial overall features, which is used to characterize the continuous change in the overall features between the current image frame and the initial image frame, so that the degree of change of the image in the time period corresponding to all image frames can be determined based on the average similarity of overall features between all image frames and the initial image frame; in actual monitoring scenarios, the appearance of the environment and the target will change, which belongs to the normal range of image changes. Therefore, by determining the average similarity of overall features, the normal range of changes in the image frame can be dynamically determined, so as to accurately determine the actual change state of the monitored equipment in the environment corresponding to the image frame.
[0086] The average similarity of regional features is the degree of continuous change of features between the regional features and the initial regional features, and is used to characterize the continuous change in regional features between the current image frame and the initial image frame.
[0087] The standard similarity is used to characterize the consistency of changes in the global features of the image and the local features of the equipment over time. That is, the larger the standard similarity, the closer the changes in the fire-fighting equipment are to the global changes over time.
[0088] Based on this, by determining the average similarity of the overall features, the average similarity of the regional features, and the standard similarity, it is possible to subsequently determine whether the change between the image frame and the initial image frame is within the preset normal image change range, thereby determining whether the status of the current monitored equipment is normal.
[0089] S140, determining the initial state of the equipment to be monitored according to the overall feature average similarity, the regional feature average similarity, and the standard similarity.
[0090] Among them, the initial state is the state of the monitored equipment in the continuous image frames. For example, the continuous image frames correspond to time A to time B, and the initial state is the state of the monitored equipment from time A to time B. The initial state can be divided into normal state, abnormal state and pending state.
[0091] Based on this, the degree of change of the environment corresponding to the image frame and the degree of change of the equipment to be monitored can be determined through the overall feature average similarity, regional feature average similarity, and standard similarity, so as to determine whether the state of the equipment to be monitored is normal by comparing whether the degree of change of the two is within the preset normal change range, thereby realizing the monitoring of the equipment status.
[0092] S150, determining an initial state of the target quantity according to the image sequence of the image frames, and determining a target state of the equipment to be monitored according to the initial state of the target quantity.
[0093] The continuous sequence of images is the time sequence of image frames.
[0094] The target quantity is a preset quantity. By determining the initial state of the target quantity, the equipment state of the equipment to be monitored is comprehensively determined to improve the accuracy of state determination; the target state is the current state of the determined equipment to be monitored.
[0095] Based on this, the image frames in the subsequent order are obtained through the continuous sequence of the image frames, and based on these image frames, the state of the equipment to be monitored in the time period corresponding to the image frames is further determined, so as to comprehensively determine the target state of the equipment based on the initial state of the target quantity.
[0096] Based on the feasible implementation of S110 described above, the present application further provides a process of screening image frames by determining whether there is image occlusion of a person or equipment in the acquired image frames:
[0097] Acquire continuous image frames to be detected;
[0098] According to a preset target detection model, determine the portrait image and the equipment image in the image frame;
[0099] Determine the image overlap between the portrait image and the equipment image, and compare the image overlap with a preset image overlap to obtain a comparison result;
[0100] If the comparison result shows that the image overlap is lower than the preset image overlap, it is determined that no image occlusion occurs in the image frame, and the image frame is determined to be the target image frame;
[0101] According to the target image frame, a preset number of continuous image frames is determined.
[0102] Among them, the preset target detection model is used to obtain target images in the image, such as equipment images and portrait images.
[0103] Image overlap (Intersection over Union, IoU) is a standard for measuring the accuracy of detecting corresponding objects in a specific data set; the preset image overlap is a pre-set value used to compare whether the overlap between the face image and the equipment image exceeds a threshold, which can be set to 0.2. For example, if the image overlap between the face image and the equipment image is greater than 0.2, it is considered that image overlap occurs between the face image and the equipment image in the current image frame, which will affect the subsequent determination of the equipment status, and the image frame needs to be deleted.
[0104] Based on this, by determining the image overlap between the face image and the equipment image in each acquired image frame, it is determined whether there is image overlap in the image frame, so as to determine whether the image frame needs to be deleted to avoid affecting the subsequent determination of the equipment status in the image frame.
[0105] Based on the feasible implementation of S130 above, the present application further provides a process of determining the average similarity of overall features, the average similarity of regional features, and the standard similarity by determining the similarity between features:
[0106] Determine the similarity between the overall feature and the initial overall feature to obtain the overall feature similarity;
[0107] Determine feature similarity between the regional feature and the initial regional feature, and determine the regional feature similarity;
[0108] According to the overall feature similarity and the regional feature similarity, the overall feature average similarity, the regional feature average similarity and the standard similarity are determined.
[0109] Among them, the similarity can be the cosine similarity between features, which is used to determine the degree of similarity between features, so as to characterize the overall features and regional features corresponding to the current image frame, and the feature changes that occur relative to the initial overall features and initial regional features in the initial image frame, so as to subsequently determine the state changes of the monitored equipment in the real-time image frame compared with the initial image frame based on the feature changes, that is, the average similarity of the overall features, the average similarity of the regional features, and the standard similarity, so as to determine whether the state of the monitored equipment is normal based on the state changes of such equipment.
[0110] Based on this, by determining the cosine similarity between the overall feature and the initial overall feature, and the cosine similarity between the regional feature and the initial regional feature, the corresponding overall feature similarity and regional feature similarity are obtained, so as to further determine the overall feature average similarity, regional feature average similarity, and standard similarity.
[0111] Based on the feasible implementation of S130 above, the present application further provides a process of weighting the overall feature similarity and the regional feature similarity of the image frame by determining the preset weights corresponding to the image frame, and determining the overall feature average similarity and the regional feature average similarity by weighting:
[0112] Determining a preset weight corresponding to each image frame according to the image sequential order of the image frames;
[0113] According to the overall feature similarities corresponding to the image frames and the preset weights, the weighted sum of the overall feature similarities corresponding to all the image frames is determined to obtain the overall feature average similarity;
[0114] According to the regional feature similarities corresponding to the image frames and the preset weights, the weighted sum of the regional feature similarities corresponding to all the image frames is determined to obtain the average regional feature similarity;
[0115] The similarity between all overall feature similarities and regional feature similarities is determined to obtain a standard similarity.
[0116] The preset weight is a pre-set weight value corresponding to each image frame, and the weight value corresponding to the image frame closer to the current real time may be larger.
[0117] The standard similarity is the cosine similarity between the overall feature similarity and the regional feature similarity.
[0118] Based on this, by determining the preset weights corresponding to the image frames, the overall feature similarity and the regional feature similarity of the image frames are weightedly calculated to obtain the corresponding overall feature average similarity and regional feature average similarity, and the standard similarity is determined based on the cosine similarity between the overall feature similarity and the regional feature similarity, so that the change in the state of the monitored equipment compared to the initial image frame can be determined based on the overall feature average similarity, the regional feature average similarity, and the standard similarity, and further determine whether the change is within the normal change range, that is, determine whether the state of the monitored equipment is normal.
[0119] Based on the feasible implementation of S160 above, the present application further provides a process of determining the initial state of the equipment to be monitored according to the comparison results by comparing the preset threshold ranges corresponding to the average similarity of the overall features, the average similarity of the regional features, and the standard similarity:
[0120] Determine a first threshold range, a second threshold range, and a third threshold range according to a preset first similarity, a second similarity, and a third similarity, wherein the third similarity is greater than the second similarity, the second similarity is greater than the first similarity, the first threshold range is a similarity range less than the first similarity, the second threshold range is a similarity range greater than the first similarity and less than the second similarity, and the third threshold range is a range greater than the third similarity;
[0121] Determine the threshold range corresponding to the average similarity of the overall features;
[0122] If the overall feature average similarity corresponds to the first threshold range, the initial state is determined to be an abnormal state;
[0123] If the overall feature average similarity corresponds to the second threshold range, then the regional feature average similarity is compared with a preset regional feature average similarity threshold to obtain a comparison result;
[0124] If the comparison result is that the average similarity of regional features is greater than the preset average similarity threshold of regional features, the initial state is determined to be an abnormal state;
[0125] If the comparison result is that the average similarity of the regional features is not greater than the preset average similarity threshold of the regional features, the initial state is determined to be a pending state;
[0126] If the overall feature average similarity corresponds to the third threshold range, then the standard similarity is compared with a preset standard similarity threshold;
[0127] If the standard similarity is greater than a preset standard similarity threshold, the initial state is determined to be a normal state;
[0128] If the standard similarity is not greater than a preset standard similarity threshold, the initial state is determined to be a pending state.
[0129] Among them, the preset first similarity, second similarity, and third similarity can be understood as three pre-set similarity values, which are used to determine the threshold range corresponding to the overall feature average similarity. For example, the first similarity can be 0.3, the second similarity can be 0.6, and the third similarity can be 0.95. In this way, the corresponding threshold range is that if the overall feature average similarity is less than 0.3, it corresponds to the first threshold range; if the overall feature average similarity is greater than 0.3 and less than 0.6, it corresponds to the second threshold range; if the overall feature average similarity is greater than 0.95, it corresponds to the third threshold range.
[0130] The preset regional feature average similarity threshold is a pre-set similarity threshold, which is used to determine the range corresponding to the regional feature average similarity, thereby determining the state of the equipment to be monitored corresponding to the current image frame; for example, the preset regional feature average similarity threshold may be 0.93, then if the overall feature average similarity corresponds to the second threshold range, at this time if the regional feature average similarity is greater than 0.93, then the state of the equipment to be monitored is an abnormal state, if the regional feature average similarity is not greater than 0.93, then the state of the equipment to be monitored is a pending state.
[0131] The preset standard similarity threshold is a pre-set similarity threshold used to determine the similarity of the overall changes of the equipment and the environment corresponding to the image frame over time, so as to determine whether the changes of the current monitored equipment compared to the initial monitored equipment and the changes of the current environment compared to the initial environment are within the normal range of changes, that is, in real monitoring application scenarios, over time, the appearance of the environment and objects in the image frame will change, which is within the normal range of changes. The standard similarity represents the similarity between the changes of the monitored equipment and the changes of the image environment. By comparing the threshold range corresponding to the standard similarity, it can be determined whether the similarity between the changes of the monitored equipment and the changes of the image environment is within the normal range, so as to determine whether the changes of the monitored equipment are normal changes compared with the changes in the environment. The larger the standard similarity, the closer the changes of the fire-fighting equipment are to the global change rules over time.
[0132] The normal state means that the equipment status of the monitored equipment is normal and no alarm or other processing is required. The real-time image frame can be updated to the template image frame so that the acquired image frame and the template image frame can be compared subsequently. The abnormal state means that the equipment is abnormal and needs to be processed. The pending state means that the current equipment status is pending. At this time, no alarm is required and the template image frame is not updated. Instead, the acquired image frame and the initial image frame are compared continuously.
[0133] Based on this, by determining the threshold ranges corresponding to the overall feature average similarity, the regional feature average similarity, and the standard similarity, the equipment state corresponding to the current monitored equipment is determined.
[0134] In this embodiment, in order to effectively improve the accuracy of the monitoring results, the overall features and initial overall features of the image frame and the initial image frame, the initial regional features and regional features corresponding to the monitored equipment can be determined, thereby determining the overall feature similarity based on the overall features and the initial overall features, and determining the regional feature similarity based on the regional features and the initial regional features, so as to further determine the preset weights corresponding to the image frames, perform weighted calculation on the overall feature similarity, obtain the overall feature average similarity, and determine the regional feature average similarity and the standard similarity, so as to determine the initial state of the monitored equipment in the time period corresponding to these image frames.
[0135] In this way, taking video as input and considering the target features in continuous time, the stability and robustness of the method are improved; in view of the problem of constantly changing environment and target appearance in monitoring scenes, a method of adaptive dynamic updating of templates is designed to improve the generalization ability of the method; and the feature extraction and similarity calculation methods based entirely on deep learning are used to improve the accuracy.
[0136] Figure 2 A flow chart of another state monitoring method provided in an embodiment of the present application. Figure 2 As shown, the condition monitoring method may include the following steps:
[0137] S210: Determine a preset initial image frame, an initial equipment image in the initial image frame, a preset number of continuous image frames, and equipment images in the image frames.
[0138] S220: Determine initial overall features of the initial image frame and initial regional features of the initial equipment image, overall features of the image frame and regional features of the equipment image.
[0139] S230 , determining the average similarity of the overall features, the average similarity of the regional features, and the standard similarity corresponding to all the image frames according to the overall features and the initial overall features, the regional features and the initial regional features.
[0140] S240: Determine the initial state of the equipment to be monitored according to the average similarity of the overall characteristics, the average similarity of the regional characteristics, and the standard similarity.
[0141] In this embodiment, the specific implementation of step S210 to step S240 can refer to the content of the above-mentioned embodiment, which will not be repeated here.
[0142] S250: Determine the image continuity order of the image frames.
[0143] The continuous sequence of images is the time sequence of image frames.
[0144] Based on this, the image sequence is determined so that the next continuous image frame can be determined according to the image sequence.
[0145] S260: Determine the next continuous image frame according to the image sequence, and delete the first image frame of the preset number of continuous image frames to obtain an updated preset number of continuous image frames.
[0146] Among them, the next continuous image frame is the next image frame continuous with the last current real-time image frame in the sequence of the preset number of image frames currently acquired; the first image frame in the preset number of continuous image frames is the image frame with the first image sequence. In this way, it can be understood that the preset number of continuous image frames are updated, so as to continue to perform feature extraction and similarity calculation on subsequent image frames, so as to determine the equipment status corresponding to the monitored equipment in the subsequent image frames.
[0147] Based on this, a preset number of continuous image frames are updated in a continuous image sequence, so that the corresponding equipment status can be determined according to the updated image frames later.
[0148] S270, based on the updated preset number of continuous image frames, repeatedly executing the steps of determining the initial overall features of the initial image frame and the initial regional features of the initial equipment image, the overall features of the image frame and the regional features of the equipment image, and determining the initial state of the equipment to be monitored based on the average similarity of the overall features, the average similarity of the regional features, and the standard similarity, until the target number of initial states are determined.
[0149] Based on this, the step of determining the equipment status of the equipment to be monitored corresponding to the image frames is repeatedly performed through the updated preset number of continuous image frames, so as to obtain the target number of initial states.
[0150] S280: Determine the target state according to the initial state of the target quantity.
[0151] Based on this, the target state corresponding to the equipment to be monitored is determined by comprehensively determining the initial state of the target quantity, so as to improve the accuracy of state determination.
[0152] Based on the feasible implementation of S280 described above, the present application further provides a process of determining the target state of the equipment to be monitored by determining the specific state corresponding to the initial state of the target quantity:
[0153] Determine the initial state of the target quantity;
[0154] If the initial states of the target quantity are all normal states, then the target state is determined to be a normal state;
[0155] If the initial states of the target quantity are all abnormal states, then the target state is determined to be an abnormal state;
[0156] If the initial state of the target quantity includes a normal state and an abnormal state, the target state is determined to be a pending state.
[0157] Based on this, the target state of the equipment is determined by the actual state corresponding to the initial state of the target quantity.
[0158] Figure 3 The following is a flowchart of a practical application of a condition monitoring method provided in an embodiment of the present application. Figure 3 As shown, the equipment status of the equipment to be monitored is determined by acquiring the latest frame image and performing feature extraction and similarity comparison with the template frame image.
[0159] Figure 4 A system diagram of a condition monitoring method provided in an embodiment of the present application. Figure 4 As shown in the figure, the fire-fighting equipment status abnormality monitoring algorithm runs on the end-side processor, and the network camera is the only source of monitoring data. When the monitoring algorithm identifies an abnormal state, it automatically triggers the on-site sound and light alarm, and sends the abnormal information to the remote administrator to maintain and restore the fire-fighting equipment in time.
[0160] In this embodiment, in order to achieve the purpose of comprehensively determining the target state of the equipment based on the equipment state of multiple consecutive image frames, thereby improving the accuracy of state determination, the images of a preset number of consecutive image frames can be updated in a continuous image sequence, and then the step of determining the initial state of the equipment is repeated based on the updated continuous image frames, so as to determine the corresponding target state based on the initial state of the target number.
[0161] In this way, only camera video data is used to automatically identify abnormal conditions of fire-fighting equipment, including loss, damage, occlusion, misappropriation, etc.; an adaptive weighted method is designed to calculate the average similarity of global images and local images in continuous time periods; the template image used for comparison can be adaptively and automatically updated, without the need for tedious and unstable manual creation and updating of templates; a deep learning feature extraction model is used to extract global features and local features, and a method for analyzing global feature changes and local feature changes is designed to ensure the accuracy and timeliness of automatic template updates.
[0162] Figure 5 Schematic diagram of the structure of a state monitoring device 500 provided in an embodiment of the present application. Figure 5 As shown, the state monitoring device 500 includes: an image determination module 510 , a feature determination module 520 , a similarity determination module 530 , an initial state determination module 540 , and a target state determination module 550 .
[0163] The image determination module 510 is used to determine a preset initial image frame, an initial equipment image in the initial image frame, a preset number of continuous image frames, and equipment images in the image frames;
[0164] The feature determination module 520 is used to determine the initial overall feature of the initial image frame and the initial regional feature of the initial equipment image, the overall feature of the image frame and the regional feature of the equipment image;
[0165] A similarity determination module 530 is used to determine the average similarity of overall features, the average similarity of regional features, and the standard similarity corresponding to all image frames according to the overall features and the initial overall features, the regional features and the initial regional features;
[0166] The initial state determination module 540 is used to determine the initial state of the equipment to be monitored according to the overall feature average similarity, the regional feature average similarity, and the standard similarity;
[0167] The target state determination module 550 is used to determine the initial state of the target quantity according to the image sequence of the image frames, and determine the target state of the equipment to be monitored according to the initial state of the target quantity.
[0168] In the embodiment of the present application, the state monitoring device 500 may also be specifically used for:
[0169] Acquire continuous image frames to be detected;
[0170] According to a preset target detection model, determine the portrait image and the equipment image in the image frame;
[0171] Determine the image overlap between the portrait image and the equipment image, and compare the image overlap with a preset image overlap to obtain a comparison result;
[0172] If the comparison result shows that the image overlap is lower than the preset image overlap, it is determined that no image occlusion occurs in the image frame, and the image frame is determined to be the target image frame;
[0173] According to the target image frame, a preset number of continuous image frames is determined.
[0174] In the embodiment of the present application, the similarity determination module 530 may also be specifically used for:
[0175] Determine the similarity between the overall feature and the initial overall feature to obtain the overall feature similarity;
[0176] Determine feature similarity between the regional feature and the initial regional feature, and determine the regional feature similarity;
[0177] According to the overall feature similarity and the regional feature similarity, the overall feature average similarity, the regional feature average similarity and the standard similarity are determined.
[0178] In the embodiment of the present application, the similarity determination module 530 may also be specifically used for:
[0179] Determining a preset weight corresponding to each image frame according to the image sequential order of the image frames;
[0180] According to the overall feature similarities corresponding to the image frames and the preset weights, the weighted sum of the overall feature similarities corresponding to all the image frames is determined to obtain the overall feature average similarity;
[0181] According to the regional feature similarities corresponding to the image frames and the preset weights, the weighted sum of the regional feature similarities corresponding to all the image frames is determined to obtain the average regional feature similarity;
[0182] The similarity between all overall feature similarities and regional feature similarities is determined to obtain a standard similarity.
[0183] In the embodiment of the present application, the initial state determination module 540 may also be specifically used for:
[0184] Determine a first threshold range, a second threshold range, and a third threshold range according to a preset first similarity, a second similarity, and a third similarity, wherein the third similarity is greater than the second similarity, the second similarity is greater than the first similarity, the first threshold range is a similarity range less than the first similarity, the second threshold range is a similarity range greater than the first similarity and less than the second similarity, and the third threshold range is a range greater than the third similarity;
[0185] Determine the threshold range corresponding to the average similarity of the overall features;
[0186] If the overall feature average similarity corresponds to the first threshold range, the initial state is determined to be an abnormal state;
[0187] If the overall feature average similarity corresponds to the second threshold range, then the regional feature average similarity is compared with a preset regional feature average similarity threshold to obtain a comparison result;
[0188] If the comparison result is that the average similarity of regional features is greater than the preset average similarity threshold of regional features, the initial state is determined to be an abnormal state;
[0189] If the comparison result is that the average similarity of the regional features is not greater than the preset average similarity threshold of the regional features, the initial state is determined to be a pending state;
[0190] If the overall feature average similarity corresponds to the third threshold range, then the standard similarity is compared with a preset standard similarity threshold;
[0191] If the standard similarity is greater than a preset standard similarity threshold, the initial state is determined to be a normal state;
[0192] If the standard similarity is not greater than a preset standard similarity threshold, the initial state is determined to be a pending state.
[0193] In the embodiment of the present application, the target state determination module 550 may also be specifically used for:
[0194] determining an image sequential order of the image frames;
[0195] Determine the next continuous image frame according to the image sequence, and delete the first image frame of the preset number of continuous image frames to obtain an updated preset number of continuous image frames;
[0196] According to the updated preset number of continuous image frames, repeatedly performing the steps of determining the initial overall features of the initial image frame and the initial regional features of the initial equipment image, the overall features of the image frame and the regional features of the equipment image, and determining the initial state of the equipment to be monitored according to the average similarity of the overall features, the average similarity of the regional features, and the standard similarity, until the initial states of the target number are determined;
[0197] Based on the initial state of the target quantity, the target state is determined.
[0198] In the embodiment of the present application, the target state module 550 may also be specifically used for:
[0199] Determine the initial state of the target quantity;
[0200] If the initial states of the target quantity are all normal states, then the target state is determined to be a normal state;
[0201] If the initial states of the target quantity are all abnormal states, then the target state is determined to be an abnormal state;
[0202] If the initial state of the target quantity includes a normal state and an abnormal state, the target state is determined to be a pending state.
[0203] Figure 6 This is a schematic diagram of the structure of the device provided in the embodiment of the present application. Figure 6 As shown, the device 600 includes:
[0204] The device 600 may include a processor 601 with one or more processing cores, a memory 602 with one or more computer-readable storage media, a communication component 603 and other components. The processor 601 , the memory 602 and the communication component 603 are connected via a bus 604 .
[0205] In a specific implementation process, at least one processor 601 executes the computer execution instructions stored in the memory 602, so that at least one processor 601 executes the above state monitoring method.
[0206] The specific implementation process of the processor 601 can be found in the above method embodiment, and its implementation principle and technical effect are similar, so this embodiment will not be repeated here.
[0207] In the above Figure 6 In the illustrated embodiment, it should be understood that the processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), etc. A general-purpose processor may be a microprocessor or any conventional processor. The steps of the method disclosed in the present application may be directly implemented as being executed by a hardware processor, or may be executed by a combination of hardware and software modules in the processor.
[0208] The memory may include a high-speed memory (Random Access Memory, RAM), and may also include a non-volatile memory (Non-volatile Memory, NVM), such as at least one disk memory.
[0209] The bus may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, the bus in the drawings of the present application is not limited to only one bus or one type of bus.
[0210] In some embodiments, a computer program product is also proposed, including a computer program or instructions, which implement the steps in any of the above-mentioned condition monitoring methods when executed by a processor.
[0211] The specific implementation of the above operations can be found in the previous embodiments, which will not be described in detail here.
[0212] A person of ordinary skill in the art will appreciate that all or part of the steps in the various methods of the above embodiments may be completed by instructions, or by controlling related hardware through instructions. The instructions may be stored in a computer-readable storage medium and loaded and executed by a processor.
[0213] To this end, an embodiment of the present application provides a computer-readable storage medium, in which multiple program codes are stored. The program codes can be loaded by a processor to execute the steps in any one of the state monitoring methods provided in the embodiments of the present application.
[0214] The storage medium may include: a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.
[0215] According to one aspect of the present application, a computer program product or a computer program is provided. The computer program product or the computer program comprises computer instructions stored in a computer-readable storage medium.
[0216] Since the instructions stored in the storage medium can execute the steps in any one of the state monitoring methods provided in the embodiments of the present application, the beneficial effects that can be achieved by any one of the state monitoring methods provided in the embodiments of the present application can be achieved. Please refer to the previous embodiments for details and will not be repeated here.
[0217] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the invention disclosed herein. The present application is intended to cover any modification, use or adaptation of the present application, which follows the general principles of the present application and includes common knowledge or customary techniques in the art that are not disclosed in the present application. The specification and examples are intended to be exemplary only, and the true scope and spirit of the present application are indicated by the following claims.
[0218] It should be understood that the present application is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.
Claims
1. A condition monitoring method, characterized in that: The method comprises: Determining a preset initial image frame, an initial equipment image in the initial image frame, a preset number of continuous image frames, and equipment images in the image frames; Determining initial overall features of the initial image frame and initial regional features of the initial equipment image, overall features of the image frame and regional features of the equipment image; Determine the average similarity of the overall features, the average similarity of the regional features, and the standard similarity corresponding to all the image frames according to the overall features and the initial overall features, the regional features and the initial regional features; Determining the initial state of the equipment to be monitored according to the overall feature average similarity, the regional feature average similarity, and the standard similarity; The initial state of the target quantity is determined according to the image continuous sequence of the image frames, and the target state of the equipment to be monitored is determined according to the initial state of the target quantity.
2. The method according to claim 1, characterized in that Before determining a preset initial image frame, an initial equipment image in the initial image frame, a preset number of continuous image frames, and equipment images in the image frames, the method further includes: Acquire continuous image frames to be detected; Determine the portrait image and the equipment image in the image frame according to a preset target detection model; Determining an image overlap between the portrait image and the equipment image, and comparing the image overlap with a preset image overlap to obtain a comparison result; If the comparison result is that the image overlap is lower than the preset image overlap, it is determined that no image occlusion occurs in the image frame, and the image frame is determined to be a target image frame; The preset number of continuous image frames is determined according to the target image frame.
3. The method according to claim 1, characterized in that: Determining the average similarity of the overall features, the average similarity of the regional features, and the standard similarity corresponding to all the image frames according to the overall features and the initial overall features, the regional features and the initial regional features, comprises: Determine the similarity between the overall feature and the initial overall feature to obtain the overall feature similarity; Determine the feature similarity between the regional feature and the initial regional feature, and determine the regional feature similarity; The overall feature average similarity, the regional feature average similarity, and the standard similarity are determined according to the overall feature similarity and the regional feature similarity.
4. The method according to claim 3, characterized in that The determining, according to the overall feature similarity and the regional feature similarity, the overall feature average similarity, the regional feature average similarity, and the standard similarity comprises: Determining a preset weight corresponding to each of the image frames according to the image sequence of the image frames; Determine the weighted sum of the overall feature similarities corresponding to all the image frames according to the overall feature similarities corresponding to the image frames and the preset weights, and obtain the overall feature average similarity; Determine the weight sum of the regional feature similarities corresponding to all the image frames according to the regional feature similarities corresponding to the image frames and the preset weights, and obtain the regional feature average similarity; The similarity between all the overall feature similarities and the regional feature similarities is determined to obtain the standard similarity.
5. The method according to claim 1, characterized in that The determining the initial state of the equipment to be monitored according to the overall feature average similarity, the regional feature average similarity, and the standard similarity includes: Determine a first threshold range, a second threshold range, and a third threshold range according to a preset first similarity, a second similarity, and a third similarity, wherein the third similarity is greater than the second similarity, the second similarity is greater than the first similarity, the first threshold range is a similarity range smaller than the first similarity, the second threshold range is a similarity range greater than the first similarity and smaller than the second similarity, and the third threshold range is a range greater than the third similarity; Determine a threshold range corresponding to the average similarity of the overall features; If the overall feature average similarity corresponds to the first threshold range, determining that the initial state is an abnormal state; If the overall feature average similarity corresponds to the second threshold range, comparing the regional feature average similarity with a preset regional feature average similarity threshold to obtain a comparison result; If the comparison result is that the average similarity of the regional features is greater than the preset average similarity threshold of the regional features, determining that the initial state is the abnormal state; If the comparison result is that the average similarity of the regional features is not greater than the preset average similarity threshold of the regional features, determining that the initial state is the pending state; If the overall feature average similarity corresponds to the third threshold range, comparing the standard similarity with a preset standard similarity threshold; If the standard similarity is greater than the preset standard similarity threshold, determining that the initial state is a normal state; If the standard similarity is not greater than the preset standard similarity threshold, the initial state is determined to be the pending state.
6. The method according to claim 1, characterized in that The step of determining the initial state of the target quantity according to the image sequence of the image frames, and determining the target state of the equipment to be monitored according to the initial state of the target quantity, comprises: Determining an image sequence of the image frames; Determine the next continuous image frame according to the image continuous sequence, and delete the first image frame in the preset number of continuous image frames to obtain the updated preset number of continuous image frames; According to the updated preset number of continuous image frames, repeatedly performing the steps of determining the initial overall features of the initial image frame and the initial regional features of the initial equipment image, the overall features of the image frame and the regional features of the equipment image, to determining the initial state of the equipment to be monitored according to the average similarity of the overall features, the average similarity of the regional features, and the standard similarity, until the initial states of the target number are determined; The target state is determined based on the initial state of the target quantity.
7. The method according to claim 6, characterized in that The step of determining the target state according to the initial state of the target quantity includes: determining said initial state of said target quantity; If the initial states of the target quantity are all normal states, determining that the target state is a normal state; If the initial states of the target quantity are all abnormal states, determining that the target state is an abnormal state; If the initial state of the target quantity includes the normal state and the abnormal state, the target state is determined to be a pending state.
8. A condition monitoring device, characterized in that: The device comprises: An image determination module, used to determine a preset initial image frame, an initial equipment image in the initial image frame, a preset number of continuous image frames, and equipment images in the image frames; A feature determination module, used to determine the initial overall feature of the initial image frame and the initial regional feature of the initial equipment image, the overall feature of the image frame and the regional feature of the equipment image; A similarity determination module, used for determining the average similarity of the overall features, the average similarity of the regional features, and the standard similarity corresponding to all the image frames according to the overall features and the initial overall features, the regional features and the initial regional features; An initial state determination module, used to determine the initial state of the equipment to be monitored according to the overall feature average similarity, the regional feature average similarity, and the standard similarity; The target state determination module is used to determine the initial state of the target quantity according to the image continuous sequence of the image frames, and determine the target state of the equipment to be monitored according to the initial state of the target quantity.
9. A device, characterized in that: include: one or more processors; Memory; One or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to execute the method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores program code, which can be called by a processor to execute the method according to any one of claims 1 to 7.
