Method, device, equipment and readable storage medium for judging malicious occlusion of scenes
By obtaining and calculating the key pixel point information of the monitoring scene, we can determine whether the scene is maliciously obstructed, and solve the problem of detection difficulties in complex scenes in the prior art, and achieve fast and accurate malicious occlusion recognition.
Patent Information
- Application Number
- CN202210448105.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-04-26
- Publication Date
- 2025-05-06
- Estimated Expiration
- 2042-04-26
AI Technical Summary
The prior art cannot quickly and with high precision to detect malicious occlusion in complex scenarios, and the computing resources are consumed very much, which cannot meet the real-time monitoring needs.
By obtaining the coordinate matrix of the monitoring scene, including the coordinate information of the key pixel points, calculate the pixel matrix of each frame, and determine whether the key pixel points are foreground points, thereby determining whether the scene is maliciously blocked.
It realizes fast and effective malicious occlusion recognition in complex scenarios, reduces computing resource consumption, meets real-time monitoring needs, and reduces false alarms.
Smart Images

Figure CN114758300B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of image recognition, and in particular to a method, device, equipment and readable storage medium for determining malicious occlusion of a scene. Background Art
[0002] In the existing technology, the frame difference method and the grayscale histogram-based method are mainly used to detect whether the scene is occluded or switched, but they cannot meet the requirements of fast and high-precision monitoring in complex scenes. In addition, as the clarity of cameras continues to improve, the image-based differential matrix will calculate the difference of each pixel in the image to detect switching or occlusion, which will consume a lot of time and resources and cannot meet real-time requirements. Therefore, it is necessary to find a fast and effective identification method for scene switching and malicious occlusion in complex scenes to meet security needs. Summary of the invention
[0003] The purpose of the present invention is to provide a method, device, equipment and readable storage medium for determining malicious occlusion of a scene, so as to improve the above-mentioned problem.
[0004] In order to achieve the above objectives, the present application provides the following technical solutions:
[0005] On the one hand, an embodiment of the present application provides a method for determining malicious occlusion of a scene, the method comprising:
[0006] Acquire a coordinate matrix, wherein the coordinate matrix includes coordinate information of at least one key pixel point included in a first frame of a monitoring scene, wherein the key pixel point includes a pixel point whose pixel value will change significantly when moved in any direction in the monitoring scene;
[0007] Obtaining a pixel matrix of each frame of the monitoring scene according to the coordinate matrix, wherein the pixel matrix includes pixel values of key pixel points corresponding to each coordinate information in the coordinate matrix in the current frame;
[0008] According to the pixel matrix of the first frame and the pixel matrix of the current frame, determining whether the key pixel point in the current frame is a foreground point, wherein the foreground point is a key pixel point that is blocked in the current frame;
[0009] According to the judgment result of whether the key pixel point in the current frame is a foreground point, a judgment result of whether the monitored scene is maliciously blocked is obtained.
[0010] In a second aspect, an embodiment of the present application provides a device for determining malicious occlusion of a scene, the device comprising:
[0011] An acquisition module, used to acquire a coordinate matrix, wherein the coordinate matrix includes coordinate information of at least one key pixel point included in a first frame of a monitoring scene, wherein the key pixel point includes a pixel point whose pixel value will change significantly when moved in any direction in the monitoring scene;
[0012] A conversion module, used to obtain a pixel matrix of each frame of the monitoring scene according to the coordinate matrix, wherein the pixel matrix includes pixel values of key pixel points corresponding to each coordinate information in the coordinate matrix in the current frame;
[0013] A first judgment module, used to judge whether a key pixel point in the current frame is a foreground point according to the pixel matrix of the first frame and the pixel matrix of the current frame, wherein the foreground point is a key pixel point that is blocked in the current frame;
[0014] The second judgment module is used to obtain a judgment result of whether the monitored scene is maliciously blocked according to a judgment result of whether the key pixel point in the current frame is a foreground point.
[0015] In a third aspect, an embodiment of the present application provides a device for judging malicious occlusion of a scene, the device comprising a memory and a processor. The memory is used to store a computer program; the processor is used to implement the steps of the method for judging malicious occlusion of a scene when executing the computer program.
[0016] In a fourth aspect, an embodiment of the present application provides a readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the method for determining malicious occlusion of the above-mentioned scene are implemented.
[0017] The beneficial effects of the present invention are:
[0018] 1. Based on the above defects, the present invention determines whether the key pixel is blocked according to the difference between the pixel value of the key pixel in the sample set of the first frame and the pixel value of the neighborhood point of the key pixel and the pixel value of the corresponding key pixel in other frames except the first frame, so as to infer whether the key pixel in each frame is blocked. By extracting the key pixel in the monitoring scene to participate in the calculation, a fast and effective judgment method is provided for judging malicious occlusion of the scene;
[0019] 2. The present invention will send an alarm message after determining that the camera monitoring scene is maliciously blocked or the camera is artificially rotated. When the alarm message is received, the camera algorithm will be reset. In daily monitoring, the camera algorithm will also be automatically reset at regular intervals, effectively avoiding the impact of light changes on monitoring accuracy and causing false alarms. It provides a stable, reliable and high-precision judgment method for judging malicious occlusion of the scene. This method can be widely used in various daily monitoring scenarios to ensure daily security needs.
[0020] Other features and advantages of the present invention will be described in the following description, and partly become apparent from the description, or be understood by implementing the embodiments of the present invention. The purpose and other advantages of the present invention can be realized and obtained by the structures particularly pointed out in the written description, claims, and drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments are briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without creative work.
[0022] Figure 1 The figure is a flow chart of a method for determining malicious occlusion of a scene according to an embodiment of the present invention.
[0023] Figure 2 Schematic diagram of the structure of a device for determining malicious occlusion of a scene according to an embodiment of the present invention.
[0024] Figure 3 It is a schematic diagram of the structure of a device for determining malicious occlusion of a scene described in an embodiment of the present invention. DETAILED DESCRIPTION
[0025] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions 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, rather than all of the embodiments. The components of the embodiments of the present invention generally described and shown in the drawings here can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the claimed invention, but merely represents selected embodiments of the present invention. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0026] It should be noted that similar reference numerals and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in the subsequent drawings. At the same time, in the description of the present invention, the terms "first", "second", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance.
[0027] Example 1
[0028] like Figure 1 As shown, this embodiment provides a method for determining malicious occlusion of a scene, the method comprising step S1, step S2, step S3 and step S4.
[0029] Step S1, obtaining a coordinate matrix, wherein the coordinate matrix includes coordinate information of at least one key pixel point included in a first frame of a monitoring scene, wherein the key pixel point includes a pixel point whose pixel value will change significantly when moved in any direction in the monitoring scene;
[0030] Step S2, obtaining a pixel matrix of each frame of the monitoring scene according to the coordinate matrix, wherein the pixel matrix includes pixel values of key pixels corresponding to each coordinate information in the coordinate matrix in the current frame;
[0031] Step S3, judging whether a key pixel point in the current frame is a foreground point according to the pixel matrix of the first frame and the pixel matrix of the current frame, wherein the foreground point is a key pixel point that is blocked in the current frame;
[0032] Step S4: According to the judgment result of whether the key pixel point in the current frame is a foreground point, a judgment result of whether the monitored scene is maliciously blocked is obtained.
[0033] At present, in complex scenes, the frame difference method, grayscale histogram-based detection algorithms, etc., all pixels in the image need to participate in the calculation, which increases the calculation time. At the same time, the existing technology adopts the method of double background extraction and double foreground, and the original background has not been updated. This leads to a great impact on the detection accuracy as the light changes, and false alarms occur.
[0034] Therefore, this embodiment extracts the key pixel points of the first frame in the scene to be monitored, converts the coordinate information of the key pixel points into a coordinate matrix, obtains the pixel matrix of the first frame and other frames except the first frame through the coordinate matrix conversion of the first frame, and determines whether the key pixel points in the pixel matrix are occluded points by calculating the difference between the pixel values of the key pixel points in the sample set of the first frame and the pixel values of the neighborhood points of the key pixel points and the pixel values of the key pixel points in the pixel matrices of other frames except the first frame. When the key pixel points are determined to be occluded points in multiple consecutive frames, it can be determined that the key pixel points are maliciously occluded points. By calculating the number of key pixel points in a frame that are maliciously occluded points, it can be determined whether the single frame is For frames that are maliciously blocked by humans, when multiple consecutive frames are judged to be maliciously blocked frames, it can be determined whether the monitoring scene is maliciously blocked or the camera is rotated manually. When it is determined that the monitoring scene is maliciously blocked or the camera is rotated manually, an alarm message will be sent, and the algorithm will be automatically reset after sending the alarm message. In addition, a monitoring cycle will be set under daily monitoring. The algorithm will be automatically reset after the camera has worked for a monitoring cycle to avoid the impact of light changes on monitoring accuracy, thereby causing false alarms. The monitoring cycle is related to the light intensity and light change frequency of the specific monitoring scene. The higher the light intensity and the faster the light change frequency, the shorter the monitoring cycle length and the higher the frequency of resetting the algorithm.
[0035] According to the above features, this embodiment can quickly and accurately determine whether the current monitoring scene is maliciously blocked or whether the camera is artificially rotated. It provides a fast, reliable and high-precision judgment method for whether the monitoring scene is maliciously blocked and whether the surveillance camera is artificially rotated. This method can be widely used in various daily monitoring scenes to ensure daily security needs.
[0036] In a specific implementation of the present disclosure, the step S1 may further include step S11 and step S12.
[0037] Step S11, extracting coordinate information of at least one key pixel included in the first frame according to a key pixel detection model, wherein the key pixel detection model is used to extract coordinate information of key pixels in the monitoring scene;
[0038] Step S12: Send the coordinate information of the key pixel point to a first function to obtain the coordinate matrix.
[0039] In this embodiment, the coordinate information of multiple key pixels included in the first frame of the monitoring scene is extracted by a key pixel detection model. The detection algorithm used by the key pixel detection model is:
[0040] K(x,y)=Shi-Tomasi(img t ,n)t=0
[0041] S t =imgt(K(x,y))t=0
[0042] Wherein, img is the monitoring scene, n is the number of key pixels, and n can take different values according to different monitoring scenes. S is the pixel matrix of key pixels obtained according to the coordinate information of key pixel points in the monitoring scene. The coordinate information is converted into a coordinate matrix to participate in the calculation. By reducing the number of pixels involved in the calculation, the calculation speed is greatly improved, and the speed of judging whether the monitoring scene is maliciously blocked or the camera is artificially rotated is improved, thereby ensuring the demand for real-time alarm.
[0043] In a specific implementation of the present disclosure, the step S3 may further include step S31, step S32 and step S33.
[0044] Step S31, constructing at least one sample set according to the pixel matrix of the first frame, wherein the sample set includes the pixel value of one of the key pixels in the pixel matrix of the first frame and the pixel values of the neighboring points of the key pixel;
[0045] Step S32: subtract the pixel value of the key pixel point of the current frame from the sample set corresponding to the key pixel point in the first frame to obtain first information, wherein the first information includes the difference between the pixel value of the key pixel point of the current frame and the pixel value of the key pixel point included in the sample set corresponding to the key pixel point in the first frame and the pixel value of the neighboring point of the key pixel point;
[0046] Step S33, judging whether the key pixel point is a foreground point according to the number of pixel value differences included in the first information that are greater than a first threshold, wherein the first threshold includes a threshold for judging whether the pixel value of the key pixel point of the current frame is close to the pixel value of the key pixel point included in the sample set corresponding to the key pixel point and the pixel value of the neighborhood point of the key pixel point.
[0047] In this embodiment, pixel matrices of the first frame and other frames except the first frame are obtained through the coordinate matrix of the first frame, and a sample set is established according to the pixel matrix of the first frame, wherein the set of sample sets is:
[0048] M i (x,y)={S t (y|y∈NG(x))},t=0,i∈(0,n]
[0049] Where M i(x, y) is the set of key pixel points (x, y) in the first frame monitoring scene, S t (x, y) is the pixel matrix corresponding to the coordinates of the key pixel points in the coordinate matrix, n is the number of key pixel points, NG is the neighborhood point of the key pixel point in the monitoring scene, where the sample set of the first key pixel point (x1, y1) is:
[0050] M1(x1,y1)={S1(x1,y1), v11(x1,y1), v12(x1,y1),...v1N(x1,y1)}
[0051] Where S1(x1, y1) is the pixel value corresponding to the first key pixel (x1, y1), {v11(x1, y1), v12(x1, y1), ...v1N(x1, y1)} is the pixel value corresponding to the neighborhood point of the first key pixel (x1, y1). For example, starting from the second frame, the pixel matrix S2 of the second frame can be updated according to the coordinate matrix of the first frame, and the pixel value in the pixel matrix S2 is subtracted from the M1(x, y) of the key pixel to obtain D2(x, y). The specific calculation formula is:
[0052] D2(x,y)=S2i(x,y)-M1i(x,y)
[0053] Wherein, D2(x,y) is the difference between the key pixel point (x,y) and all the sample values in the sample set of the key pixel point (x,y) in the first frame. The difference included in D2(x,y) is compared with the first threshold value, and the difference in D2(x,y) that satisfies the first threshold value is recorded as d2(x,y). According to the number in the set of d2(x,y), it can be determined whether the key pixel point is a foreground point. By calculating in sequence, it can be determined whether each key pixel point in the third frame, the fourth frame and all subsequent frames is a foreground point. In addition, the more sample values collected in the sample set, that is, the more neighborhood points of the key pixel point are extracted and collected, the higher the detection accuracy.
[0054] In a specific implementation of the present disclosure, the step S4 may further include step S41, step S42 and step S43.
[0055] Step S41: judging whether the key pixel point is a malicious occlusion point according to whether the key pixel point is the foreground point for multiple consecutive frames, wherein the malicious occlusion point is a point that is occluded in multiple consecutive frames;
[0056] Step S42: judging whether the current frame is a maliciously occluded frame according to the number of malicious occlusion points included in the current frame;
[0057] Step S43: determining whether the monitored scene is maliciously blocked according to whether a plurality of consecutive frames of the monitored scene are maliciously blocked frames.
[0058] In this embodiment, a second frame number and a fourth threshold are set, and the second frame number is initialized to determine whether the monitored scene is maliciously obscured for multiple consecutive frames. If a frame is a maliciously obscured frame, the second frame number is increased by one; if a frame is not a maliciously obscured frame, the second frame number is reset. When the second frame number is greater than the fourth threshold, it can be determined that the monitored scene is maliciously obscured or the camera is rotated manually, and then an alarm message is sent. After sending the alarm message, the algorithm is reset.
[0059] In a specific implementation of the present disclosure, the step S41 may further include step S411, step S412 and step S413.
[0060] Step S411, establishing and initializing the first frame number;
[0061] Step S412, determining whether the key pixel point is the foreground point in a plurality of consecutive frames, wherein if the key pixel point in a frame is the foreground point, the first frame number is increased by one, and if not, the first frame number is decreased by one;
[0062] Step S413: Determine whether the key pixel point is the malicious occlusion point by comparing the first frame number with a second threshold value, wherein the second threshold value includes a minimum frame number for determining that the key pixel point is the malicious occlusion point.
[0063] In this embodiment, it is determined whether a key pixel point is a foreground point in multiple consecutive frames. If so, the key pixel point is determined to be a maliciously occluded pixel point. If not, it means that the key pixel point may be some large objects entering the monitoring scene, causing some key pixels to be temporarily occluded. It is an accidental occlusion and not a key pixel point that is maliciously occluded in multiple consecutive frames. Therefore, a larger second threshold is set. When the first frame number is greater than the second threshold, the key pixel point is determined to be a maliciously occluded point. It can effectively distinguish whether the key pixel point is due to a large object temporarily entering the monitoring scene or being maliciously occluded or the camera is manually turned. Setting a larger second threshold is also conducive to solving the problem of false alarms caused by large objects entering the monitoring scene, effectively reducing the probability of false alarms.
[0064] In a specific implementation of the present disclosure, the step S42 may further include step S421 and step S422.
[0065] Step S421, calculating the number of key pixel points included in the current frame determined as malicious occlusion points, and obtaining a calculation result;
[0066] Step S422: Determine whether the current frame is the maliciously occluded frame by comparing the calculation result with a third threshold, wherein the third threshold includes the minimum number of malicious occlusion points for determining that the current frame is the maliciously occluded frame.
[0067] In this embodiment, the total number of malicious occlusion points in each frame can be obtained by calculation. When the total number of malicious occlusion points is greater than half of the total number of extracted key pixel points, that is, the area of the malicious occlusion points is greater than half of the area of the key pixel points, the frame can be judged as a maliciously occluded frame.
[0068] Example 2
[0069] like Figure 2 As shown, this embodiment provides a device for determining malicious occlusion of a scene, and the device includes an acquisition module 901 , a conversion module 902 , a first determination module 903 , and a second determination module 904 .
[0070] The acquisition module 901 is used to acquire a coordinate matrix, wherein the coordinate matrix includes coordinate information of at least one key pixel point included in the first frame of the monitoring scene, and the key pixel point includes a pixel point whose pixel value will change significantly when moving in any direction in the monitoring scene;
[0071] The conversion module 902 is used to obtain a pixel matrix of each frame of the detection scene according to the coordinate matrix, wherein the pixel matrix includes pixel values of key pixels corresponding to each coordinate information in the coordinate matrix in the current frame;
[0072] The first judgment module 903 is used to judge whether the key pixel point in the current frame is a foreground point according to the pixel matrix of the first frame and the pixel matrix of the current frame, and the foreground point is the key pixel point that is blocked in the current frame;
[0073] The second judgment module 904 is used to obtain a judgment result of whether the monitored scene is maliciously blocked according to a judgment result of whether the key pixel point in the current frame is a foreground point.
[0074] The device in this embodiment can realize the function of quickly and accurately judging whether the current monitoring scene is maliciously blocked or whether the camera is rotated. It provides a fast, reliable and high-precision judgment device for whether the camera monitoring scene is maliciously blocked and whether the surveillance camera is artificially rotated. This device can be widely used in various daily monitoring scenes to ensure daily security needs.
[0075] In a specific implementation of the present disclosure, the acquisition module 901 includes an extraction unit 9011 and a conversion unit 9012 .
[0076] The extraction unit 9011 is used to extract the coordinate information of at least one key pixel included in the first frame according to a key pixel detection model, wherein the key pixel detection model is used to extract the coordinate information of the key pixel in the monitoring scene;
[0077] The conversion unit 9012 is used to send the coordinate information of the key pixel point to the first function to obtain the coordinate matrix.
[0078] In a specific implementation of the present disclosure, the first judgment module 903 includes a first construction unit 9031 , a first calculation unit 9032 and a first judgment unit 9033 .
[0079] The first construction unit 9031 is used to construct at least one sample set according to the pixel matrix of the first frame, wherein the sample set includes a pixel value of one of the key pixels and pixel values of neighboring points of the key pixel in the pixel matrix of the first frame;
[0080] The first calculation unit 9032 is used to perform a subtraction between the pixel value of the key pixel point of the current frame and the sample set corresponding to the key pixel point in the first frame to obtain first information, wherein the first information includes the difference between the pixel value of the key pixel point of the current frame and the pixel value of the key pixel point included in the sample set corresponding to the key pixel point in the first frame and the pixel value of the neighboring point of the key pixel point;
[0081] The first judgment unit 9033 is used to judge whether the key pixel point is a foreground point based on the number of pixel value differences included in the first information that are greater than a first threshold, and the first threshold includes a threshold for judging whether the pixel value of the key pixel point of the current frame is close to the pixel value of the key pixel point included in the sample set corresponding to the key pixel point and the pixel value of the neighborhood point of the key pixel point.
[0082] In a specific implementation of the present disclosure, the second judgment module 904 includes a second judgment unit 9041 , a third judgment unit 9042 and a fourth judgment unit 9043 .
[0083] The second judgment unit 9041 is used to judge whether the key pixel point is a malicious occlusion point according to whether the key pixel point is the foreground point for multiple consecutive frames, and the malicious occlusion point is a point that is occluded in multiple consecutive frames;
[0084] The third judging unit 9042 is used to judge whether the current frame is a maliciously occluded frame according to the number of malicious occlusion points included in the current frame;
[0085] The fourth judgment unit 9043 is used to judge whether the monitored scene is maliciously blocked according to whether a plurality of consecutive frames of the monitored scene are maliciously blocked frames.
[0086] In a specific implementation of the present disclosure, the second judgment unit 9041 includes a second construction unit 90411 , a first sub-judgment unit 90412 , and a second sub-judgment unit 90413 .
[0087] The second construction unit 90411 is used to establish and initialize a first frame number;
[0088] The first sub-judgment unit 90412 is used to judge whether the key pixel point is the foreground point in a plurality of consecutive frames, wherein if the key pixel point in a frame is the foreground point, the first frame number is increased by one, and if not, the first frame number is decreased by one;
[0089] The second sub-judgment unit 90413 is used to judge whether the key pixel point is the malicious occlusion point by comparing the first frame number with a second threshold, and the second threshold includes the minimum frame number for judging the key pixel point as the malicious occlusion point.
[0090] In a specific implementation of the present disclosure, the third judgment unit 9042 includes a second calculation unit 90421 and a third sub-judgment unit 90422 .
[0091] The second calculation unit 90421 is used to calculate the number of key pixel points included in the current frame determined as malicious occlusion points, and obtain a calculation result;
[0092] The third sub-judgment unit 90422 is used to determine whether the current frame is the maliciously occluded frame based on comparing the calculation result with the third threshold, and the third threshold includes the minimum number of malicious occlusion points for determining that the current frame is the maliciously occluded frame.
[0093] It should be noted that, regarding the device in the above embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment of the method, and will not be elaborated here.
[0094] Example 3
[0095] Corresponding to the above method embodiment, the embodiment of the present disclosure further provides a device for judging malicious occlusion of a scene. The device for judging malicious occlusion of a scene described below and the method for judging malicious occlusion of a scene described above can refer to each other.
[0096] Figure 3 FIG. 8 is a block diagram of a device 800 for determining whether a scene is maliciously blocked according to an exemplary embodiment. Figure 3 As shown, the scene malicious occlusion judgment device 800 may include: a processor 801, a memory 802. The scene malicious occlusion judgment device 800 may also include one or more of a multimedia component 803, an input / output (I / O) interface 804, and a communication component 805.
[0097] The processor 801 is used to control the overall operation of the scene malicious occlusion judgment device 800 to complete all or part of the steps in the above-mentioned scene malicious occlusion judgment method. The memory 402 is used to store various types of data to support the operation of the scene malicious occlusion judgment device 800, and these data may include, for example, instructions for any application or method used to operate on the scene malicious occlusion judgment device 800, and application-related data, such as contact data, sent and received messages, pictures, audio, video, etc. The memory 802 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, disk or optical disk. The multimedia component 803 may include a screen and an audio component. The screen may be, for example, a touch screen, and the audio component is used to output and / or input audio signals. For example, the audio component may include a microphone for receiving external audio signals. The received audio signal may be further stored in the memory 802 or sent via the communication component 805. The audio component also includes at least one speaker for outputting audio signals. The I / O interface 804 provides an interface between the processor 801 and other interface modules, and the above-mentioned other interface modules can be keyboards, mice, buttons, etc. These buttons can be virtual buttons or physical buttons. The communication component 805 is used for wired or wireless communication between the judgment device 800 of malicious occlusion of the scene and other devices. Wireless communication, such as Wi-Fi, Bluetooth, Near Field Communication (NFC), 2G, 3G or 4G, or a combination of one or more of them, so the corresponding communication component 805 can include: Wi-Fi module, Bluetooth module, NFC module.
[0098] In an exemplary embodiment, the scene malicious occlusion judgment device 800 can be implemented by one or more application specific integrated circuits (Application Specific Integrated Circuit, referred to as ASIC), digital signal processors (Digital Signal Processor, referred to as DSP), digital signal processing devices (Digital Signal Processing Device, referred to as DSPD), programmable logic devices (Programmable Logic Device, referred to as PLD), field programmable gate arrays (Field Programmable Gate Array, referred to as FPGA), controllers, microcontrollers, microprocessors or other electronic components to execute the above-mentioned scene malicious occlusion judgment method.
[0099] In another exemplary embodiment, a computer-readable storage medium including program instructions is also provided, and when the program instructions are executed by a processor, the steps of the above-mentioned method for determining malicious occlusion of a scene are implemented. For example, the computer-readable storage medium may be the above-mentioned memory 802 including program instructions, and the above-mentioned program instructions may be executed by the processor 801 of the scene malicious occlusion determination device 800 to complete the above-mentioned method for determining malicious occlusion of a scene.
[0100] Corresponding to the above method embodiment, the embodiment of the present disclosure further provides a readable storage medium. The readable storage medium described below and the method for determining malicious occlusion of a scene described above can refer to each other.
[0101] Example 4
[0102] A readable storage medium stores a computer program, which, when executed by a processor, implements the steps of the method for determining malicious occlusion of a scene in the above method embodiment.
[0103] The readable storage medium may specifically be a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, or other readable storage medium that can store program codes.
[0104] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
[0105] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art can easily think of changes or substitutions within the technical scope disclosed by the present invention, which should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.
Claims
1. A method for determining malicious occlusion of a scene, characterized in that: include: Acquire a coordinate matrix, wherein the coordinate matrix includes coordinate information of at least one key pixel point included in a first frame of a monitoring scene, wherein the key pixel point includes a pixel point whose pixel value will change significantly when moved in any direction in the monitoring scene; Obtaining a pixel matrix of each frame of the monitoring scene according to the coordinate matrix, wherein the pixel matrix includes pixel values of key pixel points corresponding to each coordinate information in the coordinate matrix in the current frame; According to the pixel matrix of the first frame and the pixel matrix of the current frame, determining whether the key pixel point in the current frame is a foreground point, wherein the foreground point is a key pixel point that is blocked in the current frame; According to the judgment result of whether the key pixel point in the current frame is a foreground point, a judgment result of whether the monitored scene is maliciously blocked is obtained.
2. The method for determining malicious occlusion of a scene according to claim 1, characterized in that: The obtaining of the coordinate matrix comprises: Extracting coordinate information of at least one of the key pixels included in the first frame according to a key pixel detection model, wherein the key pixel detection model is used to extract coordinate information of the key pixels in the monitoring scene; The coordinate information of the key pixel point is sent to a first function to obtain the coordinate matrix.
3. The method for determining malicious scene occlusion according to claim 1, characterized in that: The determining, based on the pixel matrix of the first frame and the pixel matrix of the current frame, whether the key pixel point in the current frame is a foreground point includes: constructing at least one sample set according to the pixel matrix of the first frame, the sample set including a pixel value of one of the key pixels and pixel values of neighboring points of the key pixel in the pixel matrix of the first frame; Subtracting a pixel value of a key pixel point of the current frame from a sample set corresponding to the key pixel point in the first frame to obtain first information, wherein the first information includes a difference between the pixel value of the key pixel point of the current frame and the pixel value of the key pixel point included in the sample set corresponding to the key pixel point in the first frame and the pixel value of a neighboring point of the key pixel point; Whether the key pixel point is a foreground point is determined based on the number of pixel value differences included in the first information that are greater than a first threshold, wherein the first threshold includes a threshold for determining whether the pixel value of the key pixel point of the current frame is close to the pixel value of the key pixel point included in the sample set corresponding to the key pixel point and the pixel value of the neighborhood point of the key pixel point.
4. The method for determining malicious scene occlusion according to claim 1, characterized in that: The step of obtaining a judgment result of whether the monitored scene is maliciously blocked according to a judgment result of whether the key pixel point in the current frame is a foreground point includes: Determine whether the key pixel point is a malicious occlusion point according to whether the key pixel point is the foreground point for multiple consecutive frames, and the malicious occlusion point is a point that is occluded in multiple consecutive frames; Determining whether the current frame is a maliciously occluded frame according to the number of malicious occlusion points included in the current frame; Whether the monitored scene is maliciously obscured is determined according to whether a plurality of consecutive frames of the monitored scene are maliciously obscured frames.
5. A device for judging malicious scene occlusion, characterized in that: include: An acquisition module, used to acquire a coordinate matrix, wherein the coordinate matrix includes coordinate information of at least one key pixel point included in a first frame of a monitoring scene, wherein the key pixel point includes a pixel point whose pixel value will change significantly when moved in any direction in the monitoring scene; A conversion module, used to obtain a pixel matrix of each frame of the monitoring scene according to the coordinate matrix, wherein the pixel matrix includes pixel values of key pixel points corresponding to each coordinate information in the coordinate matrix in the current frame; A first judgment module, used to judge whether a key pixel point in the current frame is a foreground point according to the pixel matrix of the first frame and the pixel matrix of the current frame, wherein the foreground point is a key pixel point that is blocked in the current frame; The second judgment module is used to obtain a judgment result of whether the monitored scene is maliciously blocked according to a judgment result of whether the key pixel point in the current frame is a foreground point.
6. The device for determining malicious scene occlusion according to claim 5, characterized in that: The acquisition module comprises: An extraction unit, configured to extract coordinate information of at least one of the key pixels included in the first frame according to a key pixel detection model, wherein the key pixel detection model is configured to extract coordinate information of the key pixels in the monitoring scene; A conversion unit is used to send the coordinate information of the key pixel point to a first function to obtain the coordinate matrix.
7. The device for determining malicious scene occlusion according to claim 5, characterized in that: The first judgment module includes: A first construction unit, configured to construct at least one sample set according to the pixel matrix of the first frame, wherein the sample set includes a pixel value of one of the key pixels and pixel values of neighboring points of the key pixel in the pixel matrix of the first frame; a calculation unit, configured to obtain first information by subtracting a pixel value of a key pixel point of the current frame from a sample set corresponding to the key pixel point in the first frame, wherein the first information includes a difference between a pixel value of the key pixel point of the current frame and a pixel value of a key pixel point and a pixel value of a neighboring point of the key pixel point included in the sample set corresponding to the key pixel point in the first frame; A first judgment unit is used to judge whether the key pixel point is a foreground point according to the number of pixel value differences included in the first information that are greater than a first threshold, wherein the first threshold includes a threshold for judging whether the pixel value of the key pixel point of the current frame is close to the pixel value of the key pixel point included in the sample set corresponding to the key pixel point and the pixel value of the neighborhood point of the key pixel point.
8. The device for determining malicious scene occlusion according to claim 5, characterized in that: The second judgment module includes: A second judgment unit is used to judge whether the key pixel point is a malicious occlusion point according to whether the key pixel point is the foreground point for multiple consecutive frames, and the malicious occlusion point is a point that is occluded in multiple consecutive frames; A third judging unit, configured to judge whether the current frame is a maliciously obscured frame according to the number of maliciously obscured points included in the current frame; The fourth judgment unit is used to judge whether the monitored scene is maliciously blocked according to whether a plurality of consecutive frames of the monitored scene are maliciously blocked frames.
9. A device for judging malicious scene occlusion, characterized in that: include: Memory for storing computer programs; A processor, used to implement the steps of the method for determining malicious occlusion of a scene as described in any one of claims 1 to 4 when executing the computer program.
10. A readable storage medium, characterized in that: The readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method for determining malicious occlusion of a scene as described in any one of claims 1 to 4 are implemented.
Citation Information
Patent Citations
Image foreground extracting method and device
CN106780544A
Efficient satellite image self-correcting multi-target tracking method
CN110264492A