A video detection method, device and system
By performing more comprehensive detection on video clips in the monitoring system, identifying and sending information about secondary events, the problem of incomplete alarm information in existing technologies is solved, and more detailed monitoring information is provided.
Patent Information
- Application Number
- CN202211127529.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-16
- Publication Date
- 2025-12-09
- Estimated Expiration
- 2042-09-16
AI Technical Summary
In existing surveillance systems, when cameras detect a moving target and send an alarm message to the user equipment, they cannot specifically identify the target, resulting in incomplete alarm information.
By receiving the first and second video sub-segments from the video clip, detecting whether there is a movement event, determining whether there is a second event in the second video sub-segment, and sending corresponding messages to the user equipment, more comprehensive monitoring information is provided.
It improves the comprehensiveness and accuracy of video detection, enabling users to obtain more detailed monitoring information and enhancing the user experience.
Smart Images

Figure CN115641528B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the computer technical field, and particularly relates to a video detection method, device and system. BACKGROUND
[0002] A monitoring system generally comprises a camera and a server. The camera can detect whether a moving target exists in video data in real time, and if the moving target exists, an alarm message is sent to a user device, and a user is prompted that a moving target exists in a monitoring area. The camera also sends the video data to the server, and the server stores the video data.
[0003] In the current monitoring system, the camera sends an alarm message to the user device as soon as a moving target is detected, and the camera does not specifically identify what the moving target is, which also makes the alarm information received by the user through the user device not comprehensive enough. SUMMARY
[0004] The present application provides a video detection method, device and system, which are used for improving the comprehensiveness of video detection.
[0005] In a first aspect, an embodiment of the present application provides a video detection method, comprising: receiving a video segment from an acquisition device, the video segment comprising a first video sub-segment and a second video sub-segment, and the video sub-segment comprising a plurality of video frames; determining that the first video sub-segment has a first event, the first event being used to indicate that a first target in the first video sub-segment has movement; if the second video sub-segment has the first event, determining whether the second video sub-segment has a second event, the second event being used to indicate that a second target in the second video sub-segment has movement; and if the second video sub-segment has the second event, sending a first message to a user device, the first message being used to indicate that the second video sub-segment has the second event.
[0006] In the embodiment of the present application, according to the received video segment, the first video sub-segment and the second video sub-segment in the video segment are detected respectively, and the video segment can be detected more comprehensively. Moreover, the video detection device can send the first message to the user device after determining the second event according to the second video sub-segment, so as to remind the user that the second target has movement in the second video sub-segment, and the user can obtain more comprehensive monitoring information, which is beneficial to improving the experience of the user.
[0007] In a possible implementation, the method further includes: determining, in the plurality of video frames in the first video sub-clip, image regions corresponding to the first target; determining information of the first target according to the determined plurality of image regions, the information of the first target including a trajectory of the first target; and determining that the first event exists in the first video sub-clip according to the trajectory of the first target.
[0008] In this implementation, the trajectory of the first target in the plurality of video frames is determined by comparing the image regions corresponding to the first target in the plurality of video frames, and then whether the first target moves is determined according to the trajectory of the first target in the plurality of video frames. Since more video frames are combined to determine whether the first target moves, the accuracy of detecting the first event is improved.
[0009] In a possible implementation, the method further includes: if the second target in the second video sub-clip moves and the second target is not the same as the first target, determining that the second event exists in the second video sub-clip; and if the second target in the second video sub-clip does not move, and / or the second target is the same as the first target, determining that the second event does not exist in the second video sub-clip.
[0010] In this implementation, whether the second target is the same as the first target or whether the second target moves can be determined, and then whether the second event exists in the second video sub-clip is determined, thereby avoiding repeated detection of the same target or repeated detection of a stationary target, and the accuracy of detecting that the second event exists in the second video sub-clip is improved.
[0011] In a possible implementation, the method further includes: if an overlapping area of an image region of the second target in one video frame in the second video sub-clip and an image region of the second target in another video frame in the second video sub-clip is greater than a preset threshold, determining that the second target in the second video sub-clip does not move.
[0012] In this implementation, whether the second target moves is determined according to the size of the overlapping area between the image region of the second target in one video frame and the image region of the second target in another video frame, thereby avoiding that the second target is determined as a moving target while the second target is actually a target that moves in a small fixed range in the video frame.
[0013] In a possible implementation, the method further includes: if a distance between relative positions of the second target in any two video frames in the second video sub-clip is less than a preset distance, determining that the second target in the second video sub-clip does not move.
[0014] In this embodiment, the second target with a distance between relative positions in any two video frames less than a preset distance can be determined as a static target, avoiding a small moving distance and causing the user equipment to frequently send a prompt message.
[0015] In a possible implementation, the information of the first target includes a category of the first target; and the method further includes: sending a second message to the user equipment, the second message being used to instruct the user equipment to add information of the category of the first target in information of the target with movement indicated by a third message in the first video sub-clip, the third message being received by the user equipment from the collection device.
[0016] In this embodiment, the information of the category of the first target in the first video sub-clip can also be determined, and then the second message can be sent to the user equipment, so that the user equipment adds the information of the category of the first target in the third message, and the user can more clearly determine that the target with movement in the first video sub-clip is the first target, which is beneficial to improving the user experience.
[0017] In a possible implementation, the second video sub-clip is separated from the first video sub-clip by a preset time length on a time axis of the video clip.
[0018] In this embodiment, the second video sub-clip is separated from the first video sub-clip by a preset time length, so that each video frame in the video clip does not need to be detected, the video clip is detected by the method of separating by a preset time length, the event detection omission can be avoided, and the efficiency and comprehensiveness of the video clip detection can be improved.
[0019] In a possible implementation, the method further includes: receiving a fourth message from the collection device, the fourth message being used to indicate that the first video sub-clip has a target with movement.
[0020] In this embodiment, the fourth message is received from the collection device, so that the target with movement in the first video sub-clip can be directly determined according to the fourth message, the first video sub-clip is directly detected, and the first target is determined, without detecting the target with movement in the entire video clip, which is beneficial to improving the efficiency of the video clip detection.
[0021] In a second aspect, the embodiments of the present application provide a video detection device, comprising: a storage module, configured to receive a video clip from a collection device, wherein the video clip comprises a first video sub-clip and a second video sub-clip, and the video sub-clip comprises a plurality of video frames; and a processing module, configured to determine that the first video sub-clip contains a first event, wherein the first event is used to indicate that a first target in the first video sub-clip moves; if the second video sub-clip contains the first event, determine whether the second video sub-clip contains a second event, wherein the second event is used to indicate that a second target in the second video sub-clip moves; and if the second video sub-clip contains the second event, send a first message to a user device, wherein the first message is used to indicate that the second video sub-clip contains the second event.
[0022] In a possible implementation, the processing module is further configured to: determine, in the plurality of video frames in the first video sub-clip, image regions corresponding to the first target; determine information of the first target according to the determined plurality of image regions, wherein the information of the first target comprises a trajectory of the first target; and determine that the first video sub-clip contains the first event according to the trajectory of the first target.
[0023] In a possible implementation, the processing module is further configured to: if the second target in the second video sub-clip moves, and the second target is not the same as the first target, determine that the second video sub-clip contains the second event; and if the second target in the second video sub-clip does not move, and / or the second target is the same as the first target, determine that the second video sub-clip does not contain the second event.
[0024] In a possible implementation, the processing module is further configured to: if an overlapping area of an image region of the second target in one video frame in the second video sub-clip and an image region of the second target in another video frame in the second video sub-clip is greater than a preset threshold, determine that the second target in the second video sub-clip does not move.
[0025] In a possible implementation, the processing module is further configured to: if a distance between relative positions of the second target in any two video frames in the second video sub-clip is less than a preset distance, determine that the second target in the second video sub-clip does not move.
[0026] In a possible implementation, the information of the first target includes a category of the first target; and the processing module is further configured to send a second message to the user equipment, where the second message is used to instruct the user equipment to add information of the category of the first target into information of the first target existing in the first video sub-clip indicated by a third message, and the third message is received by the user equipment from the collection device.
[0027] In a possible implementation, the second video sub-clip is separated from the first video sub-clip by a preset time length on a time axis of the video clip.
[0028] In a possible implementation, the storage module is further configured to receive a fourth message from the collection device, where the fourth message is used to indicate that the first video sub-clip exists a moving target.
[0029] In a third aspect, an embodiment of the present application provides a video detection system, including a collection device and a video detection device, where the collection device is configured to send a video clip to the video detection device, the video clip including a first video sub-clip and a second video sub-clip, and the video sub-clip including a plurality of video frames; and the video detection device is configured to implement the functions of the video detection device in any of the methods in the second aspect.
[0030] In a possible implementation, the video detection system further includes a user equipment; where the collection device is further configured to send a third message to the user equipment, where the third message is used to indicate that the first video sub-clip exists a moving target; and the user equipment is configured to receive the third message from the collection device.
[0031] In a possible implementation, the video detection device is further configured to send a second message to the user equipment, where the second message is used to instruct the user equipment to add information of the category of the first target into information of the first target existing in the first video sub-clip indicated by a third message; and the user equipment is further configured to receive the second message from the video detection device, and add information of the category of the first target into the third message according to the second message.
[0032] In a fourth aspect, an embodiment of the present application provides a video detection device, including at least one processor, and a memory connected with the at least one processor in communication; where the memory stores instructions executable by the at least one processor, and the at least one processor implements the method in any of the first aspect by executing the instructions stored in the memory.
[0033] Fifthly, this application provides a computer-readable storage medium storing computer instructions that, when executed on a computer, cause the computer to perform any of the methods described in the first aspect.
[0034] The beneficial effects of aspects two through five can be found in the discussion of aspect one above, and will not be listed here again. Attached Figure Description
[0035] Figure 1 This is a schematic diagram illustrating an application scenario of a video detection method applicable to the embodiments of this application;
[0036] Figure 2 This is a schematic diagram of the structure of a video detection system provided in an embodiment of this application;
[0037] Figure 3 A flowchart illustrating a video detection method provided in this application embodiment. Figure 1 ;
[0038] Figure 4 A schematic diagram of a video clip provided in an embodiment of this application;
[0039] Figure 5 A schematic diagram of a method for determining the movement of a second target provided in an embodiment of this application. Figure 1 ;
[0040] Figure 6 A schematic diagram of a method for determining the movement of a second target provided in an embodiment of this application. Figure 2 ;
[0041] Figure 7 A flowchart illustrating a video detection method provided in this application embodiment. Figure 2 ;
[0042] Figure 8 A schematic diagram of the structure of a video detection device provided in this application embodiment. Figure 1 ;
[0043] Figure 9 A schematic diagram of the structure of a video detection device provided in this application embodiment. Figure 2 . Detailed Implementation
[0044] To better understand the technical solutions provided in this application, a detailed description will be given below in conjunction with the accompanying drawings and specific implementation methods.
[0045] Please refer to Figure 1 This is an application scenario diagram of a video detection method provided in an embodiment of this application. Alternatively, Figure 1It can be understood as a structural schematic diagram of a video detection system. As shown in Figure 1 The scene includes a collection device 101, a video detection device 102 and a user device 103. Among them, the collection device 101, the video detection device 102 and the user device 103 can communicate with each other in wired or wireless mode.
[0046] The collection device 101 refers to a device with video collection function, for example, a video camera or a camera. The video camera is, for example, a pan-tilt-zoom camera, a gun camera or a spherical camera. The camera is, for example, a panoramic camera. The video detection device 102 refers to a device with video detection function, for example, a server or a terminal device. The terminal device is, for example, a smart phone, a personal computer (PC), a tablet, a notebook computer or a palm computer, etc. The user device 103 is, for example, a terminal device.
[0047] The interaction between the above devices will be described below.
[0048] For example, the collection device 101 collects video data, sends a message to the user device 103, and sends the video data to the video detection device 102. After receiving the video data, the video detection device 102 detects the video data. The specific process of detection will be described below.
[0049] Please refer to Figure 2 , a structural schematic diagram of a video detection system provided by the embodiment of the present application, wherein, Figure 2 The video detection system shown in Figure 1 The application scenario shown in can be applied. As shown in Figure 2 The video detection system 200 includes a collection device 210, a video detection device 220 and a user device 230. Any two of the collection device 210, the video detection device 220 and the user device 230 can communicate with each other. The collection device 210 is, for example, the collection device 101 shown in Figure 1 The video detection device 220 is, for example, the video detection device 102 shown in Figure 1 The user device 230 is, for example, the user device 103 shown in Figure 1
[0050] Among them, the collection device 210 is used to collect video clips and send the video clips to the video detection device 220. The video detection device 220 is used to receive the video clips from the collection device 210 and detect the video clips. The specific process of detection will be described below. The user device 230 is used to receive the message of the collection device 210 or the video detection device 220 to display for the user to view.
[0051] In a possible implementation, with continuous reference to Figure 2 The video detection device 220 can provide, but is not limited to, a video storage service 221 and a video detection service 222. One service can be understood as one process in the video detection device. The video storage service 221 can be used to receive and store video clips, and the video storage service 221 can be implemented by cloud storage and / or a database, for example, a remote dictionary server (Redis) database. The video detection service 222 is used to detect the video clips received by the video storage service. The specific process of detecting the video clips by the video detection service 222 will be described in detail below. The video detection service 222 can use an artificial intelligence (AI) detection method to process the video clips.
[0052] Please refer to Figure 3 for a flowchart of a video detection method provided by an embodiment of the present application. Figure 3 The embodiments shown can be applied to Figure 1 the application scenarios shown, and can also be applied to Figure 2 the video detection system shown. Figure 3 The collection device involved in the embodiments shown is, for example, Figure 1 the collection device 101 shown, Figure 3 The video detection device involved in the embodiments shown is, for example, Figure 1 the video detection device 102 shown, Figure 3 The user device involved in the embodiments shown is, for example, Figure 1 the user device 103 shown. Alternatively, Figure 3 The collection device involved in the embodiments shown is, for example, Figure 2 the collection device 210 shown, Figure 3 The video detection device involved in the embodiments shown is, for example, Figure 2 the video detection device 220 shown, Figure 3 The user device involved in the embodiments shown is, for example, Figure 2 the user device 230 shown.
[0053] Among them, Figure 3 The video detection device is taken as an execution subject for introduction.
[0054] S301, the video detection device receives a video clip from a collection device, the video clip includes a first video sub-clip and a second video sub-clip, and each video sub-clip includes a plurality of video frames. In the present application, “a plurality of” means greater than or equal to 2.
[0055] For example, the collection device collects the video clip at intervals of a first preset time length, and sends the video clip to the video detection device. Alternatively, the collection device determines that the video clip contains a moving target, and sends the video clip to the video detection device. Optionally, the collection device can also send a fourth message to the video detection device. The fourth message is used to indicate that the first video sub-clip contains a moving target.
[0056] As an example, if the collection device detects that the first video sub-clip in the video clip contains a moving target, the collection device can also send a third message to the user device. The third message is used to indicate that the first video sub-clip contains a moving target.
[0057] The video clip includes a first video sub-clip and a second video sub-clip, and the first video sub-clip and the second video sub-clip are separated by a second preset time length on the time axis of the video clip. The second preset time length can be preconfigured by the user in the video detection device, or determined by the video detection device itself. For example, the second preset time length is 10 seconds. Optionally, the second preset time length can be represented by the number of frames, for example, the second preset time length can be represented by 10 frames.
[0058] Please refer to Figure 4 , a schematic diagram of a video clip provided by an embodiment of the present application. As shown in Figure 4 , the video clip includes 38 video frames, or the video clip includes a plurality of video sub-clips, including video sub-clip A, video sub-clip B, video sub-clip C, and video sub-clip D. For example, video sub-clip A is the 0th to 6th frame of the video clip, video sub-clip B is the 16th to 18th frame of the video clip, video sub-clip C is the 20th to 26th frame of the video clip, and video sub-clip D is the 36th to 38th frame of the video clip. In addition, the video clip also includes other video sub-clips, which are not limited by the present application.
[0059] Optionally, S301 can be performed by a video storage service in the video detection device, such as Figure 2 the video storage service 221 in
[0060] S302, the video detection device determines that the first video sub-clip contains a first event, and the first event indicates that the first target in the first video sub-clip is moving.
[0061] The video detection device determining that the video sub-clip contains an event can be understood as the video detection device detecting that the first video sub-clip contains a moving target.
[0062] The video detection device determining that the first video sub-clip contains a first event can be determined in two cases. The two cases are described below.
[0063] In the first case, the video detection device receives the fourth message from the collection device, and identifies the first video sub-clip, and determines that the first event exists in the first video sub-clip.
[0064] Specifically, when the video detection device receives the video clip, the video detection device receives the fourth message from the collection device, and determines that the first video sub-clip in the video clip contains a moving target according to the fourth message. The video detection device extracts a certain number of video frames from the first video sub-clip, or directly detects all video frames in the first video sub-clip. The video frames detected by the video detection device can be intra-coded picture (I).
[0065] For example, the video detection device detects all video frames in the first video sub-clip, and determines the image region corresponding to the moving target, i.e., the image region corresponding to the first target, in each video frame in the first video sub-clip, determines the position information of each image region in each video frame, and determines the information of the first target. The information of the first target includes the trajectory of the first target and the category of the first target. The trajectory of the first target can be determined according to the coordinates of the image region corresponding to the first target in the video frame. For example, the video detection device determines the coordinates of the image region corresponding to the first target in each video frame, and determines the trajectory of the first target according to the change of the coordinates of the image region corresponding to the first target in each video frame. The category of the first target can be, for example, a person, a vehicle, a pet, or the like.
[0066] The video detection device can determine that the first event exists in the first video sub-clip according to the trajectory of the first target.
[0067] Please continue to refer to Figure 4 The video detection device receives the video clip, the fifth message and the sixth message from the collection device. The fifth message indicates that the moving target exists at the 0th frame of the video clip, and the sixth message indicates that the moving target exists at the 22nd frame. Then, the video detection device detects the video sub-clip A and the video sub-clip C respectively, and determines that the video sub-clip A contains event 1 and the video sub-clip C contains event 2. The content of the video detection device determining that the video sub-clip A contains event 1 can refer to the content discussed above for determining that the first event exists in the first video sub-clip, which will not be described here.
[0068] The video detection device can detect the event 2 from the last frame of the occurrence time of the event 2, that is, the 20th frame in the video clip. The video detection device determines the 0th-20th frames in the video clip as the occurrence time of the event 1, or the occurrence time of the event 1 is the first two video frames from the first video frame indicated by the fifth message to the video frame indicated by the sixth message. Therefore, when detecting the event 2, the video detection device determines the 20th-26th frames in the video clip as the video sub-clip C, detects the video sub-clip C, and determines that the video sub-clip C contains the event 2. The specific process of determining that the video sub-clip C contains the event 2 can be understood with reference to the content described above for determining that the first video sub-clip contains the first event, which will not be repeated here.
[0069] In the second case, the video detection device directly identifies the first video sub-clip to determine that the first video sub-clip contains the first event. In this case, after receiving the video clip from the collection device, the video detection device cannot directly determine whether there is a moving target in the video clip. Therefore, the video detection device can directly identify the first video sub-clip to determine whether there is a moving target in the first video sub-clip, thereby avoiding not accurately identifying the moving target in the video clip.
[0070] If the video detection device determines that the first video sub-clip contains the first event in either of the first case and the second case, the video detection device sends a second message to the user device. The second message includes information about the category of the first target, and the second message is used to instruct the user device to add the information about the category of the first target to the information about the moving target in the first video sub-clip indicated by a third message, and the third message is received by the user device from the collection device.
[0071] S303, if the second video sub-clip contains the first event, determining whether the second video sub-clip contains a second event, the second event indicating that a second target in the second video sub-clip moves.
[0072] The video detection device determines that the second video sub-clip contains the first event, which can also be understood as that the first video sub-clip and the second video sub-clip are both within the occurrence time of the first event. The specific content of the occurrence time of the first event can be understood with reference to the content described above for the occurrence time of the event 1, which will not be repeated here.
[0073] After detecting the first video sub-clip, the video detection device detects the second video sub-clip after a second preset time interval. The specific method of determining whether the second target moves in the second video sub-clip can be understood with reference to the content described above for the movement of the first target in the first video sub-clip, which will not be repeated here.
[0074] Optionally, the video detection device determines whether the second target moves or not according to the coincidence of the image regions corresponding to the second target in any two video frames in the second video sub-clip. Specifically, two methods can be used, which are described as follows.
[0075] In the first method, the video detection device determines whether the second target in the second video sub-clip moves or not according to the distance between the relative positions of the second target in any two video frames in the second video sub-clip.
[0076] Specifically, any two video frames containing the second target in the second video sub-clip are extracted. For the convenience of description, the first video frame corresponding to the second target is referred to as the first video frame, and the second video frame corresponding to the second target is referred to as the second video frame. The video detection device establishes a coordinate axis with any point of the image of the first video frame, determines the coordinates of the image region corresponding to the second target in the first video frame in the coordinate axis, including the coordinates of the four vertices of the image region and the center coordinates of the image region. Moreover, the video detection device determines the coordinates of the image region corresponding to the second target in the second video frame in the coordinate axis, including the coordinates of the four vertices of the image region and the center coordinates of the image region.
[0077] The video detection device determines whether the second target in the second video sub-clip moves or not according to the distance between the relative positions of the image region in the first video frame and the image region in the second video frame of the second target. If the distance is less than a preset distance, it is determined that the second target does not move. If the distance is greater than the preset distance, it is determined that the second target moves. The preset distance can be pre-configured in the video detection device.
[0078] Please refer to Figure 5 for a schematic diagram for determining the movement of the second target. As shown in Figure 5 , the coordinates of the four vertices of the image region corresponding to the second target in the first video frame are (x1, y1), (x1, y2), (x2, y1), and (x2, y2), and the center coordinates are (x5, y5). The coordinates of the four vertices of the image region corresponding to the second target in the second video frame are (x3, y3), (x3, y4), (x4, y3), and (x4, y4), and the center coordinates are (x6, y6). Based on the above coordinates, if the video detection device determines that the absolute value of the coordinate difference of the center point of the image region corresponding to the second target is less than half of the difference value of the vertex coordinates of the two image regions, it is determined that the second target does not move.
[0079] A calculation formula for determining that the second target does not move according to the above coordinates is as follows.
[0080] |x5-x6| < (|x2-x1| + |x4-x3|) / 2
[0081] |y5-y6| < (|y2-y1| + |y4-y3|) / 2
[0082] The second method, the video detection device can also determine whether the second target moves according to the overlapping area.
[0083] Specifically, the video detection device determines the area of the image region corresponding to the second target in the first video frame, the area of the image region corresponding to the second target in the second video frame, and the overlapping area of the image region corresponding to the second target in the first video frame and the image region corresponding to the second target in the second video frame. If the video detection device determines that the overlapping area is greater than a preset threshold, it is determined that the second target does not move, or that the second target is a stationary target.
[0084] Please refer to Figure 6 , the schematic diagram for determining the movement of the second target provided by the embodiments of the present application. As shown in Figure 6 , the video detection device determines that the area of the image region corresponding to the second target in the first video frame is S1, the area of the image region corresponding to the second target in the second video frame is S2, and the overlapping area of the image region corresponding to the second target in the first video frame and the image region corresponding to the second target in the second video frame is S3. For example, the preset threshold can be half of the sum of the area of the image region corresponding to the second target in the first video frame and the area of the image region corresponding to the second target in the second video frame, and then the video detection device determines the movement of the second target according to the overlapping area according to the following formula.
[0085] S3 > (S1 + S2) ÷ 2
[0086] It should be noted that the above two methods (the first method and the second method) can not only be used to detect whether the second target moves, but also be used to determine whether each target in the video segment is a stationary target.
[0087] If the video detection device can determine that the second target in the second video sub-segment moves according to the above two methods (the first method and the second method), it is determined whether the first target and the second target are the same target.
[0088] Specifically, the video detection device selects a video frame including the first target in the first video sub-clip and a video frame including the second target in the second video sub-clip, and detects the similarity between the image region of the first target and the image region of the second target. If the video detection device determines that the similarity between the first target and the second target is less than the first threshold, it is determined that the first target and the second target are not the same target. If the video detection device determines that the similarity between the first target and the second target is greater than the first threshold, it is determined that the first target and the second target are the same target.
[0089] If the video detection device determines that the first target and the second target are not the same target, it is determined that the second event exists in the second video sub-clip. If the video detection device determines that the first target and the second target are the same target, it is determined that the second event does not exist in the second video sub-clip.
[0090] In a possible implementation, if the video detection device determines that the second target in the second video sub-clip does not move or that the second target does not exist, it is determined that the second event does not exist in the second video sub-clip.
[0091] S304, if the second video sub-clip has the second event, the first message is sent to the user equipment, and the first message is used to indicate that the second video sub-clip has the second event.
[0092] The video detection device determines that the second video sub-clip has the second event, and sends the first message to the user equipment, and the first message is used to indicate that the second video sub-clip has the second event.
[0093] Wherein, S302-S304 can be executed by a video detection service in the video detection device, and the video detection service is, for example, Figure 2 The video detection service 222 shown in the figure.
[0094] It should be noted that the first video sub-clip and the second video sub-clip are taken as examples in the embodiments of the present application, but actually the video clip can also include other video sub-clips, and the processing mode of other sub-clips can refer to the process of the video detection method discussed above, which will not be repeated here.
[0095] It should be noted that the first video sub-clip and the second video sub-clip are taken as examples in the embodiments of the present application, but actually the first video sub-clip and the second video sub-clip can also include other moving targets, and the processing mode of other moving targets can refer to the process of the video detection method discussed above, which will not be repeated here.
[0096] Please refer to Figure 7 for a flowchart of a video detection method provided by the embodiments of the present application. The following will be described in combination withFigure 7 A video detection method provided by an embodiment of the present application is exemplified. In the embodiment of the present application, a video detection device is taken as an execution subject for introduction.
[0097] S701, the video detection device receives a video segment from a collection device.
[0098] The content of the video segment can refer to the content discussed above, which is not repeated here.
[0099] S702, the video detection device determines whether the video segment has a moving target.
[0100] If it is determined that the video segment has a moving target, S703 is performed, that is, the video detection device detects a first video sub-segment to determine a first target. If it is determined that the video segment does not have a moving target, S705 is performed, that is, it is determined whether the video segment reaches a second preset time length. If the video detection device receives a fourth message, it is determined that the video segment has a moving target. The specific content of the fourth message can refer to the content discussed above, which is not repeated here.
[0101] If the video detection device determines that the video segment reaches the second preset time length, S706 is performed, that is, the second video sub-segment is detected to determine a second target at an interval of the second preset time length. If the video detection device determines that the video segment does not reach the second preset time length, the detection is ended, or it is understood that the video segment is not detected at an interval of the second preset time length.
[0102] If the video detection device determines the first target or the second target, S704 is performed, that is, it is determined whether the target is a stationary target, wherein the target can include the first target and / or the second target. If the video detection device determines that the target is not a stationary target, S707 is performed, that is, a message is sent to a user device. If the video detection device determines that the target is a stationary target, the detection is ended, or it is understood that the detection of the first target or the second target is stopped. The determination of whether the first target or the second target is a stationary target can refer to the content discussed above for determining whether the first target and the second target are moving, which is not repeated here.
[0103] Please refer to Figure 8 A structural schematic diagram of a video detection device provided by an embodiment of the present application is shown in FIG. 8. As shown in FIG. 8, the video detection device 800 includes a storage module 801 and a processing module 802. Figure 8
[0104] Exemplarily, the storage module 801 is configured to receive a video segment from a collection device, wherein the video segment includes a first video sub-segment and a second video sub-segment, and the video sub-segment includes a plurality of video frames.
[0105] The processing module 802 is configured to determine that the first video sub-clip has a first event, the first event being used to indicate that a first target in the first video sub-clip has movement, determine whether the second video sub-clip has a second event if the second video sub-clip has the first event, the second event being used to indicate that a second target in the second video sub-clip has movement, and send a first message to the user device if the second video sub-clip has the second event, the first message being used to indicate that the second video sub-clip has the second event.
[0106] In a possible implementation, the processing module 802 is further configured to determine, in a plurality of video frames in the first video sub-clip, image regions corresponding to the first target, determine information of the first target according to the determined plurality of image regions, the information of the first target including a trajectory of the first target, and determine that the first video sub-clip has the first event according to the trajectory of the first target.
[0107] In a possible implementation, the processing module 802 is further configured to determine that the second video sub-clip has the second event if the second target in the second video sub-clip has movement and the second target and the first target are not the same target, and determine that the second video sub-clip does not have the second event if the second target in the second video sub-clip does not have movement and / or the second target and the first target are the same target.
[0108] In a possible implementation, the processing module 802 is further configured to determine that the second target in the second video sub-clip does not have movement if an overlapping area of an image region of the second target in one video frame in the second video sub-clip and an image region of the second target in another video frame in the second video sub-clip is greater than a preset threshold.
[0109] In a possible implementation, the processing module 802 is further configured to determine that the second target in the second video sub-clip does not have movement if a distance between relative positions of the second target in any two video frames in the second video sub-clip is less than a preset distance.
[0110] In a possible implementation, the information of the first target includes a category of the first target, and the processing module 802 is further configured to send, to the user device, a second message, the second message being used to instruct the user device to add information of the category of the first target to information of a target having movement indicated by a third message, the third message being received by the user device from the collection device.
[0111] In a possible implementation, the second video sub-clip is separated from the first video sub-clip by a preset time length in a time axis of the video clip.
[0112] In one possible implementation, the storage module 801 is further configured to receive a fourth message from the acquisition device, the fourth message indicating that a moving target exists in the first video sub-segment.
[0113] As an example, the video detection device 800 provided in this application embodiment can implement the functions of any of the video detection devices described above. Specifically, the storage module 801 can implement the functions of the video storage service 221 described above, and the processing module 802 can implement the functions of the video detection service 222 described above.
[0114] Please refer to Figure 9 This is a schematic diagram of the structure of the video detection device provided in an embodiment of this application. Figure 9 As shown, the video detection device 900 includes at least one processor 902 and a memory 901 communicatively connected to the at least one processor 902; wherein, the memory 901 stores instructions that can be executed by the at least one processor 902, and the at least one processor 902 implements the video detection method as described in any of the preceding descriptions by executing the instructions stored in the memory 901.
[0115] As an example, the video detection device 900 provided in this application embodiment can realize the functions of any of the video detection devices described above.
[0116] This application provides a video detection system. The video detection system includes a video detection device and a capture device. Optionally, the video detection system also includes a user device. A schematic diagram of the video detection system can be found above. Figure 2 The diagram shown is a structural schematic.
[0117] Among them, the video detection equipment can implement any of the video detection methods mentioned above, and can also implement the functions of any of the video detection devices mentioned above. The user equipment can implement the functions of any of the user equipment mentioned above. The acquisition equipment can implement the functions of any of the acquisition devices mentioned above.
[0118] This application provides a computer-readable storage medium storing computer instructions that, when executed on a computer, cause the computer to perform the video detection method described in any of the preceding claims.
[0119] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0120] The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart block or blocks. Figure 1 one or more flow or blocks Figure 1 means for functionally implementing the steps in one or more flow or blocks
[0121] These computer program instructions can also be stored in a computer- readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instructions which implement the function specified in the flowchart block or blocks. Figure 1 one or more flow or blocks Figure 1 means for functionally implementing the steps in one or more flow or blocks
[0122] The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart block or blocks. Figure 1 one or more flow or blocks Figure 1 means for functionally implementing the steps in one or more flow or blocks
[0123] Obviously, numerous modifications and variations of the present application are possible in light of the above teachings. It is therefore to be understood that within the scope of the appended claims and their equivalents, the application can be practiced otherwise than as specifically described.
Claims
1. A video detection method, characterized in that, include: Receive video segments from the acquisition device, the video segments including a first video sub-segment and a second video sub-segment, the video sub-segment including multiple video frames; A first event is determined to exist in the first video sub-segment, and the first event is used to indicate that the first target in the first video sub-segment has moved; If the second video segment contains the first event, then it is determined whether the second video segment contains a second event. The second event indicates that the second target in the second video segment has moved. Determining whether the second video segment contains a second event includes: if the second target in the second video segment has moved, and the second target and the first target are not the same target, then it is determined that the second video segment contains a second event; if the second target in the second video segment has not moved, and / or the first target and the second target are the same target, then it is determined that the second video segment does not contain a second event. If the second video segment contains the second event, a first message is sent to the user equipment, the first message indicating that the second video segment contains the second event.
2. The method according to claim 1, characterized in that, Determining the existence of a first event in the first video segment includes: In multiple video frames within the first video sub-segment, the image region corresponding to the first target is determined; Based on the identified multiple image regions, information about the first target is determined, including the trajectory of the first target. Based on the trajectory of the first target, it is determined that the first video segment contains the first event.
3. The method according to claim 1, characterized in that, The method further includes: If the overlapping area of the image region of the second target in one video frame of the second video sub-segment and the image region of the second target in another video frame of the second video sub-segment is greater than a preset threshold, then it is determined that the second target in the second video sub-segment has not moved.
4. The method according to claim 1, characterized in that, The method further includes: If the distance between the relative positions of the second target in any two video frames of the second video sub-segment is less than a preset distance, then it is determined that the second target in the second video sub-segment has not moved.
5. The method according to claim 2, characterized in that, The information of the first target includes the category of the first target; the method further includes: A second message is sent to the user equipment, the second message being used to instruct the user equipment to add information about the category of the first target to the information about the first video sub-segment containing a moving target indicated by the third message, the third message being received by the user equipment from the acquisition device.
6. The method according to any one of claims 1-5, characterized in that, The second video segment and the first video segment are spaced apart by a preset duration on the timeline of the video segment.
7. The method according to any one of claims 1-5, characterized in that, The method further includes: A fourth message is received from the acquisition device, the fourth message indicating that there is a moving target in the first video sub-segment.
8. A video inspection device, characterized in that, include: A storage module is used to receive video segments from an acquisition device, the video segments including a first video sub-segment and a second video sub-segment, the video sub-segment including multiple video frames; The processing module is configured to determine whether a first event exists in the first video sub-segment, the first event indicating that a first target in the first video sub-segment has moved; if the first event exists in the second video sub-segment, then determine whether a second event exists in the second video sub-segment, the second event indicating that a second target in the second video sub-segment has moved; and if the second event exists in the second video sub-segment, then send a first message to the user equipment, the first message indicating that the second event exists in the second video sub-segment. The determination of whether the second video segment has a second event includes: if the second target in the second video segment moves and the second target and the first target are not the same target, then the second video segment has a second event; if the second target in the second video segment does not move, and / or the first target and the second target are the same target, then the second video segment does not have a second event.
9. The device according to claim 8, characterized in that, The second video segment and the first video segment are spaced apart by a preset duration on the timeline of the video segment.
10. A video detection system, characterized in that, The video detection system includes acquisition equipment and video detection equipment, wherein: The acquisition device is used to send video segments to the video detection device. The video segments include a first video sub-segment and a second video sub-segment, and the video sub-segment includes multiple video frames. The video detection device is configured to receive the video segment from the acquisition device, determine that a first event exists in the first video sub-segment, the first event indicating that a first target in the first video sub-segment has moved, and if the first event exists in the second video sub-segment, determine whether a second event exists in the second video sub-segment, the second event indicating that a second target in the second video sub-segment has moved, and if the second event exists in the second video sub-segment, send a first message to the user equipment, the first message indicating that the second event exists in the second video sub-segment. The determination of whether the second video segment has a second event includes: if the second target in the second video segment moves and the second target and the first target are not the same target, then the second video segment has a second event; if the second target in the second video segment does not move, and / or the first target and the second target are the same target, then the second video segment does not have a second event.
11. The system according to claim 10, characterized in that, The video detection system also includes user equipment; wherein: The acquisition device is also used to send a third message to the user equipment, the third message being used to indicate that there is a moving target in the first video sub-segment; The user equipment is used to receive the third message from the acquisition device.
12. The system according to claim 10 or 11, characterized in that, The video detection device is further configured to send a second message to the user equipment, the second message being configured to instruct the user equipment to add information about the category of the first target to the information about the presence of a moving target in the first video sub-segment indicated by the third message; The user equipment is further configured to receive the second message from the video detection device, and, based on the second message, add information about the category of the first target to the third message.
13. A video inspection device, characterized in that, include: At least one processor, and A memory that is communicatively connected to the at least one processor; The memory stores instructions that can be executed by the at least one processor, and the at least one processor implements the method as described in any one of claims 1-7 by executing the instructions stored in the memory.
14. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that, when executed on a computer, cause the computer to perform the method as described in any one of claims 1-7.
Citation Information
Patent Citations
Intelligent video monitoring system based on three-dimensional virtual scene
CN102036054A
Alarm method and device
CN105336074A