Disclosure of Invention
The embodiment of the application provides a video monitoring method and a video monitoring device, which are used for controlling a first camera to track a target object when the target object has a launching behavior, and controlling a second camera to track the target object when the target object leaves an area which can be shot by the first camera, so that the monitoring of the target object can be finished to the greatest extent under the condition of less cameras.
In a first aspect, an embodiment of the present application provides a video monitoring method, where the method is applied to a monitoring device, and the monitoring device monitors an environment around a water body through a plurality of cameras, and the method includes:
when a target object is detected in a shooting area of a first camera in the plurality of cameras, performing behavior recognition on the behavior of the target object to obtain a behavior recognition result;
if the existence of the launching behavior of the target object is determined according to the behavior identification result, the first camera is controlled to track the target object so that the target object is positioned in the shooting area of the first camera, the launching behavior is used for representing the behavior made when entering the water body from the surrounding environment of the water body,
when the target object leaves the first area, the second camera is controlled to track the target object so that the target object is located in a shooting area of the second camera, and the first area is an area which can be shot by the first camera.
It can be seen that in the embodiment of the present application, when a target object is detected in a shooting area of a first camera in a plurality of cameras, behavior recognition is performed on the target object, so as to obtain a behavior recognition result; if the existence of the launching behavior of the target object is determined according to the behavior identification result, the first camera is controlled to track the target object so that the target object is located in a shooting area of the first camera; and when the target object leaves the region which can be shot by the first camera, controlling the second camera to track the target object. By adopting the method, the monitoring of the target object can be finished to the greatest extent under the condition of less cameras, so that the position and the behavior of the target object can be conveniently pre-warned.
In a possible embodiment, the behavior recognition result includes a moving direction of the target object, and before controlling the second camera to track the target object, the method further includes: acquiring position information of a plurality of cameras; and determining a second camera from the cameras according to the moving direction of the target object and the position information of the cameras.
In the embodiment of the application, the second camera is determined by adopting the method, so that the target object quickly enters the monitoring field of view of the video monitoring system after leaving the region which can be shot by the first camera.
In one possible embodiment, determining the second camera from the plurality of cameras according to the moving direction of the target object and the position information of the plurality of cameras includes: acquiring map information of a water body and surrounding environment of the water body; determining a movable area corresponding to the target object according to the map information; determining a first moving area of the target object according to the moving direction of the target object and the movable area corresponding to the target object; determining a plurality of third cameras in the plurality of cameras according to the first moving area of the target object and the position information of the plurality of cameras, wherein the plurality of third cameras are cameras with overlapping areas which can be shot in the plurality of cameras and the first moving area; and determining the camera closest to the target object in the plurality of third cameras as a second camera.
In the embodiment of the application, the movable area of the target object is determined by acquiring map information of the water body and the surrounding environment of the water body, the first movable area is determined according to the moving direction and the movable area, the plurality of third cameras are determined according to the first movable area and the position information of the plurality of cameras, and the camera closest to the target object in the plurality of third cameras is determined to be the second camera. By adopting the method, the camera corresponding to the shooting area where the target object enters earliest is determined to be the second camera, so that fewer visual field blind areas exist in the tracking process of the target object, and the target object can be conveniently pre-warned.
In a possible embodiment, the behavior recognition result includes a moving speed of the target object, and the method further includes: when a corresponding tracking object exists in a shooting area of the second camera, determining a first time when the tracking object leaves the second area, wherein the second area is an area which can be shot by the second camera; determining a second time for transferring the second camera from the first shooting area to the second shooting area, wherein the first shooting area is an area shot by the second camera when the tracking object leaves the second area, and the second shooting area is an area shot by the second camera when the time for entering the area shot by the second camera after the target object leaves the first area is shortest; calculating the sum of the first time and the second time to obtain a third time; determining a second moving area according to the first moving area and the position information of the cameras, wherein the second moving area is an area where the target object moves from the first area to the second area; determining a fourth time according to the second moving area of the target object and the moving speed of the target object, wherein the fourth time is the time taken by the target object to move from the first area to the second area; if the third time is longer than the fourth time, determining a fourth camera in the plurality of third cameras, and determining that the fourth camera is a new second camera, wherein the fourth camera is a camera closest to the target object except the second camera in the plurality of third cameras.
In the embodiment of the application, the third time is obtained by calculating the sum of the first time when the tracking object leaves the second area and the second time when the second camera is transferred from the first shooting area to the second shooting area, the size relation between the third time and the fourth time when the target object is moved from the first area to the second area is compared, when the third time is larger than the fourth time, the camera closest to the target object except the second camera in the cameras is determined to be the fourth camera, and the fourth camera is determined to be a new second camera. By adopting the method, the tracking cameras corresponding to different tracking objects can be reasonably distributed under the condition that a plurality of tracking objects exist.
In one possible embodiment, the method further comprises: when a corresponding tracking object exists in a shooting area of the second camera, determining a first water falling danger level corresponding to the tracking object, wherein the first water falling danger level is used for representing the probability that the tracking object enters the water body from the surrounding environment of the water body; determining a second water falling risk level corresponding to the target object, wherein the second water falling risk level is used for representing the probability of the target object entering the water body from the surrounding environment of the water body; if the first water falling danger level is greater than or equal to the second water falling danger level, determining a fourth camera of the plurality of third cameras, determining the fourth camera as a new second camera, and determining the fourth camera as a camera closest to the first camera except the second camera of the plurality of third cameras.
In the embodiment of the application, by adopting the method, the tracking cameras corresponding to different tracking objects can be reasonably distributed under the condition that a plurality of tracking objects exist.
In a possible embodiment, the behavior recognition result further includes a moving speed of the target object, and the method further includes: if the first water falling danger level is smaller than the second water falling danger level, determining a second moving area of the target object according to the first moving area of the target object and the position information of the cameras, wherein the second moving area is an area in which the target object moves from the first area to the second area, and the second area is an area in which the second camera can shoot; determining a fourth time of the target object according to the second moving area of the target object and the moving speed of the target object, wherein the fourth time is the time taken by the target object to move from the first area to the second area; and controlling the second camera to track the tracking object according to the fifth time, and transferring the tracking object to the second shooting area by a third shooting area after the fifth time, wherein the third shooting area is an area shot by the second camera to the tracking object, the second shooting area is an area shot by the second camera when the time of the target object leaving from the first area and entering the area shot by the second camera is shortest, and the difference value between the fourth time and the fifth time is larger than the time taken by the second camera to transfer from the third shooting area to the second shooting area.
In the embodiment of the application, when the first water falling danger level is smaller than the second water falling danger level, determining a fourth time spent by the target object moving from the first area to the second area according to a second moving area between the first area and the second area and the moving speed of the target object, controlling the second camera to track the tracking object according to the fifth time, and transferring the third shooting area to the second shooting area after the fifth time, so that the difference between the fourth time and the fifth time is larger than the time spent by the second camera transferring from the third shooting area to the second shooting area. By adopting the method, the tracking of the target object can be ensured, and the tracking of the tracked object can be completed to the greatest extent.
In one possible embodiment, determining the fourth time of the target object according to the second movement region of the target object and the movement speed of the target object includes: determining at least one first ground class of an area in which the target object moves in the first area; determining at least one second ground category for a second movement region; matching the at least one second ground category with the at least one first ground category; if the matching is successful, determining at least one third ground category which is successfully matched in the at least one second ground category; determining a first moving time corresponding to a fourth moving area according to the moving speed of the target object in the third moving area, wherein the third moving area is an area corresponding to at least one third ground category in the first area, and the fourth moving area is an area corresponding to at least one third ground category in the first moving area; determining a second movement time corresponding to a fifth movement region according to the movement speed of the target object in the first region, wherein the fifth movement region is a region except the fourth movement region in the first movement region; the fourth time is determined based on the first movement time and the second movement time.
In the embodiment of the application, the accuracy of determining the fourth time can be improved by adopting the method, so that the second camera can conveniently adjust and control the shooting angle.
In a second aspect, an embodiment of the present application provides a video monitoring device, where the video monitoring device is applied to a monitoring device, and the monitoring device implements monitoring on surrounding environments of a water body through a plurality of cameras, and the video monitoring device includes:
the processing unit is used for carrying out behavior recognition on the behavior of the target object when the target object is detected in the shooting area of the first camera in the plurality of cameras, so as to obtain a behavior recognition result;
if the determining unit determines that the target object has a launching behavior according to the behavior recognition result, the control unit is used for controlling the first camera to track the target object so that the target object is positioned in a shooting area of the first camera, the launching behavior is used for representing the behavior made when the target object enters the water body from the surrounding environment of the water body,
and the control unit is also used for controlling the second camera to track the target object when the target object leaves the first area so as to enable the target object to be located in a shooting area of the second camera, wherein the first area is an area which can be shot by the first camera.
In a third aspect, an embodiment of the present application provides an electronic device, where the device includes a processor, a memory, and a communication interface, where the processor, the memory, and the communication interface are connected to each other and perform communication therebetween, the memory stores executable program code, the communication interface is used for performing wireless communication, and the processor is used to retrieve the executable program code stored in the memory and perform, for example, some or all of the steps described in any of the methods of the first aspect.
In a fourth aspect, embodiments of the present application provide a computer readable storage medium having stored therein electronic data which, when executed by a processor, is adapted to carry out the electronic data to carry out some or all of the steps described in the first aspect of the embodiments of the present application.
In a fifth aspect, embodiments of the present application provide a computer program product, wherein the computer program product comprises a non-transitory computer readable storage medium storing a computer program operable to cause a computer to perform some or all of the steps described in the first aspect of the embodiments of the present application. The computer program product may be a software installation package.
Detailed Description
In order that those skilled in the art will better understand the present application, a technical solution in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
The terms first, second and the like in the description and in the claims and in the above-described figures are used for distinguishing between different objects and not necessarily for describing a sequential or chronological order. Furthermore, the terms "comprise" and "have," as well as any variations thereof, are intended to cover a non-exclusive inclusion. For example, a process, method, system, article, or apparatus that comprises a list of steps is not limited to the elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment may be included in at least one embodiment of the application. The appearances of such phrases in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those of skill in the art will explicitly and implicitly appreciate that the embodiments described herein may be combined with other embodiments.
Referring to fig. 1, fig. 1 is a schematic structural diagram of a video monitoring system according to an embodiment of the application, and as shown in fig. 1, the video monitoring system 100 includes a plurality of cameras 101 and a monitoring device 102. The cameras 101 are used for monitoring a target object and collecting video data about the target object; the monitoring device 102 is used for controlling shooting angles of the cameras 101 to track a target object. In addition to this, a main camera and other cameras than the main camera may be present in the plurality of cameras 101, and the main camera may integrate functions of the monitoring device 102, that is, control shooting angles of the other cameras to track the target object,
Based on this, the embodiment of the application provides a video monitoring method, and the embodiment of the application is described in detail below with reference to the accompanying drawings.
Referring to fig. 2, fig. 2 is a flow chart of a video monitoring method provided by an embodiment of the present application, where the video monitoring method is applied to a monitoring device, and the monitoring device monitors the surrounding environment of a water body through a plurality of cameras, as shown in fig. 2, and the method includes the following steps:
in step 201, when a target object is detected in a shooting area of a first camera of the plurality of cameras, behavior recognition is performed on behaviors of the target object, and a behavior recognition result is obtained.
Wherein the identification of the target object may be based on a neural network algorithm. The method specifically may be to identify the target object in the shooting area of the first camera based on a target detection algorithm (e.g., YOLO algorithm), and identify the behavior of the target object based on a behavior identification algorithm (e.g., three-dimensional convolutional neural network algorithm). The shooting area of the first camera is an area of the surrounding environment of the water body corresponding to the shot image under the current shooting angle of the first camera.
Step 202, if it is determined that the target object has a launch behavior according to the behavior recognition result, controlling the first camera to track the target object so that the target object is located in a shooting area of the first camera.
Wherein the launch behavior is used to characterize the behavior that is made when entering the body of water from the surrounding environment of the body of water. For example, actions taken by pedestrians from the surrounding of the body of water before entering the body of water include, but are not limited to, a sloughing action, a warming action, a launch action. The control of the first camera to track the target object means that in the moving process of the target object, the target object is located in the shooting area of the first camera by controlling the shooting angle of the first camera.
In step 203, when the target object leaves the first area, the second camera is controlled to track the target object, so that the target object is located in the shooting area of the second camera.
The first area is an area that can be photographed by the first camera, in other words, the first area is a set of all areas that can be photographed by the first camera by controlling a photographing angle of the first camera, and the photographing angle includes a lateral angle and a longitudinal angle.
Referring to fig. 3, fig. 3 is a schematic structural diagram of a shooting area of a camera according to an embodiment of the present application, as shown in fig. 3, fig. 3 includes a camera 300, the camera shown in the drawing is a side view in a camera plan view, and when a longitudinal angle of the camera 300 is controlled to move to a lowest angle, the shooting area of the camera 300 is 301; when the longitudinal angle of the camera 300 is controlled to move to the highest angle, the photographing area of the camera 300 is 303; when the longitudinal angle of the camera 300 is controlled to move between the lowest angle and the highest angle, the photographing area of the camera 300 is 302, and it can be seen that the area that the camera 300 can photograph is 310. It is known that the movement of the camera in the lateral direction is similar to the movement of the camera in the longitudinal direction, and will not be described in detail here.
In a possible embodiment, the behavior recognition result includes a moving direction of the target object, and before controlling the second camera to track the target object, the method further includes: acquiring position information of a plurality of cameras; and determining a second camera from the cameras according to the moving direction of the target object and the position information of the cameras.
The position information of the cameras further comprises information of areas which can be shot by the cameras, when the first camera tracks the target object, the moving direction of the target object is determined according to the position change condition of the target object, and the second camera is determined from the cameras according to the moving direction of the target object and the position information of the cameras, so that the target object quickly enters a monitoring field of view of the video monitoring system after leaving the areas which can be shot by the first camera.
In one possible embodiment, determining the second camera from the plurality of cameras according to the moving direction of the target object and the position information of the plurality of cameras includes: acquiring map information of a water body and surrounding environment of the water body; determining a movable area corresponding to the target object according to the map information; determining a first moving area of the target object according to the moving direction of the target object and the movable area corresponding to the target object; determining a plurality of third cameras in the plurality of cameras according to the first moving area of the target object and the position information of the plurality of cameras, wherein the plurality of third cameras are cameras with overlapping areas which can be shot in the plurality of cameras and the first moving area; and determining the camera closest to the target object in the plurality of third cameras as a second camera.
The movable area of the target object is an area where the pointer can move to the target object in the surrounding environment of the water body. For example, if the target object is a pedestrian, the movable area thereof may include a flat ground, stairs, or the like; however, if the target object is a vehicle, the movable area may include a flat ground, but may not include stairs. The area where the target object may move, i.e., the first moving area, may be determined according to the movable area of the target object and the moving direction of the target object. According to the first moving area and the position information of the plurality of cameras, it can be determined that the area which can be shot by the plurality of cameras is overlapped with the first moving area, namely, the third camera can be one or a plurality of cameras. In other words, the target object may appear in an area that can be photographed by the third camera during the movement according to the movement direction of the target object. After the plurality of third cameras are determined, determining the camera closest to the target object in the plurality of third cameras as the second camera, namely, the target object can enter the area shot by the second camera earliest in the moving process.
In the embodiment of the application, the movable area of the target object is determined by acquiring map information of the water body and the surrounding environment of the water body, the first movable area is determined according to the moving direction and the movable area, the plurality of third cameras are determined according to the first movable area and the position information of the plurality of cameras, and the camera closest to the target object in the plurality of third cameras is determined to be the second camera. By adopting the method, the camera corresponding to the shooting area where the target object enters earliest is determined to be the second camera, so that fewer visual field blind areas exist in the tracking process of the target object, and the target object can be conveniently pre-warned.
In a possible embodiment, the behavior recognition result includes a moving speed of the target object, and the method further includes: when a corresponding tracking object exists in a shooting area of the second camera, determining a first time when the tracking object leaves the second area, wherein the second area is an area which can be shot by the second camera; determining a second time for transferring the second camera from the first shooting area to the second shooting area, wherein the first shooting area is an area shot by the second camera when the tracking object leaves the second area, and the second shooting area is an area shot by the second camera when the time for entering the area shot by the second camera after the target object leaves the first area is shortest; calculating the sum of the first time and the second time to obtain a third time; determining a second moving area according to the first moving area and the position information of the cameras, wherein the second moving area is an area where the target object moves from the first area to the second area; determining a fourth time according to the second moving area of the target object and the moving speed of the target object, wherein the fourth time is the time taken by the target object to move from the first area to the second area; if the third time is longer than the fourth time, determining a fourth camera in the plurality of third cameras, and determining that the fourth camera is a new second camera, wherein the fourth camera is a camera closest to the target object except the second camera in the plurality of third cameras.
The tracking object refers to an object with a launch behavior in a shooting area of the second camera or other cameras. The time when the tracking object leaves the second area is determined by the second camera according to the position change condition of the tracking object. The first photographing region and the second photographing region refer to different photographing regions determined by controlling photographing angles of the second camera, including a lateral angle and a longitudinal angle.
If the second shooting area corresponds to the second shooting angle, the second camera can shoot the target object earlier than other shooting angles under the second shooting angle; in other words, when the target object just enters the second area, the second camera can shoot the target object at the second shooting angle, but the second camera cannot shoot the target object at other shooting angles except the second shooting angle. Similarly, if the first shooting angle corresponds to the first shooting area, the second camera can shoot the tracking object later than other shooting angles under the second shooting angle; in other words, when the tracking object just leaves the second area, the second camera can shoot the tracking object at the first shooting angle, but the second camera cannot shoot the tracking object at other shooting angles except the first shooting angle.
According to the sum of the first time when the tracking object leaves the second area and the second time when the second camera is transferred from the first shooting area to the second shooting area, the third time when the second camera finishes tracking the tracking object and starts tracking the target object can be determined; in other words, the third time is a preparation time before the second camera tracks the target object. The second moving area refers to an area which needs to be moved before the target object enters the second area after leaving the first area, and the fourth time which needs to be spent before the target object enters the second area can be determined according to the second moving area and the moving speed of the target object.
If the third time is less than or equal to the fourth time, the second camera may transfer the photographing region to the second photographing region when the target object enters the second region. If the third time is longer than the fourth time, the second camera cannot transfer the shooting area to the second camera when the target object enters the second area, namely the second camera cannot shoot the target object at the first time; while the second camera may still be taking a photograph of the tracked object. In order to ensure tracking efficiency of the target object, it is necessary to determine a fourth camera closest to the target object among the plurality of third cameras except the second camera, and determine the fourth camera as a new second camera.
In the embodiment of the application, the third time is obtained by calculating the sum of the first time when the tracking object leaves the second area and the second time when the second camera is transferred from the first shooting area to the second shooting area, the size relation between the third time and the fourth time when the target object is moved from the first area to the second area is compared, when the third time is larger than the fourth time, the camera closest to the target object except the second camera in the cameras is determined to be the fourth camera, and the fourth camera is determined to be a new second camera. By adopting the method, the tracking cameras corresponding to different tracking objects can be reasonably distributed under the condition that a plurality of tracking objects exist.
In addition, in one possible embodiment, the method further comprises: when a corresponding tracking object exists in a shooting area of the second camera, determining a first water falling danger level corresponding to the tracking object, wherein the first water falling danger level is used for representing the probability that the tracking object enters the water body from the surrounding environment of the water body; determining a second water falling risk level corresponding to the target object, wherein the second water falling risk level is used for representing the probability of the target object entering the water body from the surrounding environment of the water body; if the first water falling danger level is greater than or equal to the second water falling danger level, determining a fourth camera of the plurality of third cameras, determining the fourth camera as a new second camera, and determining the fourth camera as a camera closest to the first camera except the second camera of the plurality of third cameras.
When the shooting area of the second camera has a corresponding tracking object, if other cameras have corresponding tracking objects at the moment, redundant cameras cannot be distributed to track the target object. At this time, the distribution can be performed according to the falling-into-water danger levels of different tracking objects, that is, the priority of tracking the tracking object with the high falling-into-water danger level is higher than the priority of tracking the tracking object with the low falling-into-water danger level. The water falling danger level is used for representing the probability that the tracking object enters the water body from the surrounding environment of the water body, and the higher the water falling danger level is, the higher the probability that the tracking object enters the water body from the surrounding environment of the water body is. If the first water falling risk level corresponding to the tracking object is greater than or equal to the second water falling risk level corresponding to the target object, that is, the probability of the tracking object entering the water is greater than or equal to the probability of the target object entering the water, the second camera should track the tracking object. Therefore, it is necessary to determine a fourth camera closest to the target object among the plurality of third cameras, in addition to the second camera, and determine the fourth camera as a new second camera.
In the embodiment of the application, by adopting the method, the tracking cameras corresponding to different tracking objects can be reasonably distributed under the condition that a plurality of tracking objects exist.
In a possible embodiment, the behavior recognition result further includes a moving speed of the target object, and the method further includes: if the first water falling danger level is smaller than the second water falling danger level, determining a second moving area of the target object according to the first moving area of the target object and the position information of the cameras, wherein the second moving area is an area in which the target object moves from the first area to the second area, and the second area is an area in which the second camera can shoot; determining a fourth time of the target object according to the second moving area of the target object and the moving speed of the target object, wherein the fourth time is the time taken by the target object to move from the first area to the second area; and controlling the second camera to track the tracking object according to the fifth time, and transferring the tracking object to the second shooting area by a third shooting area after the fifth time, wherein the third shooting area is an area shot by the second camera to the tracking object, the second shooting area is an area shot by the second camera when the time of the target object leaving from the first area and entering the area shot by the second camera is shortest, and the difference value between the fourth time and the fifth time is larger than the time taken by the second camera to transfer from the third shooting area to the second shooting area.
When the first water falling risk level corresponding to the tracking object is smaller than the second water falling risk level corresponding to the target object, the second camera needs to be separated from tracking the tracking object so as to track the target object, but before the target object enters the second area, the second camera needs to track the tracking object to the greatest extent. Therefore, the present embodiment determines the fourth time for the target object to move from the first area to the second area according to the moving speed of the target object and the second moving area between the target object to move from the first area to the second area. After the second camera is controlled to track the tracking object for a fifth time, the shooting area of the second camera is transferred from the third shooting area to the second shooting area.
Similarly, the third shooting area and the second shooting area refer to areas shot by the second camera under the corresponding shooting angles, and the areas shot by the second camera under the second shooting angles are second shooting areas; the third photographing region is a region photographed by the second camera when tracking the tracking object at the third photographing angle. If the time taken for the second camera to adjust from the third photographing angle to the second photographing angle is the sixth time, the sum between the sixth time and the fifth time needs to be smaller than the fourth time, so that the second camera has adjusted the photographing angle to the second photographing angle before the target object enters the second region.
In the embodiment of the application, when the first water falling danger level is smaller than the second water falling danger level, determining a fourth time spent by the target object moving from the first area to the second area according to a second moving area between the first area and the second area and the moving speed of the target object, controlling the second camera to track the tracking object according to the fifth time, and transferring the third shooting area to the second shooting area after the fifth time, so that the difference between the fourth time and the fifth time is larger than the time spent by the second camera transferring from the third shooting area to the second shooting area. By adopting the method, the tracking of the target object can be ensured, and the tracking of the tracked object can be completed to the greatest extent.
In one possible embodiment, determining the fourth time of the target object according to the second movement region of the target object and the movement speed of the target object includes: determining at least one first ground class of an area in which the target object moves in the first area; determining at least one second ground category for a second movement region; matching the at least one second ground category with the at least one first ground category; if the matching is successful, determining at least one third ground category which is successfully matched in the at least one second ground category; determining a first moving time corresponding to a fourth moving area according to the moving speed of the target object in the third moving area, wherein the third moving area is an area corresponding to at least one third ground category in the first area, and the fourth moving area is an area corresponding to at least one third ground category in the first moving area; determining a second movement time corresponding to a fifth movement region according to the movement speed of the target object in the first region, wherein the fifth movement region is a region except the fourth movement region in the first movement region; the fourth time is determined based on the first movement time and the second movement time.
The ground category may refer to a composition structure and a topography structure of the ground in the moving area. Illustratively, the constituent structures may include grass, earth, rock, etc.; the topography may include flats, bumps, inclinations, etc., where inclination may be used to represent stairs or a floor having a slope; thus, the ground category may include (grass, flat), (earthy inclined), etc. The moving speeds of the target object corresponding to different floors are different, and the moving speeds corresponding to different floors can even be excessively different.
The present embodiment determines at least one second ground category in the second moving area and at least one first ground category of the area in which the target object moves in the first area. And matching the at least one second ground category with the at least one first ground category. After the at least one third ground category successfully matched is determined, determining the moving time of the moving area corresponding to the at least one third ground category in the second moving area according to the moving speed of the moving area corresponding to the at least one third ground category in the first area; determining the moving time of the second moving area except the moving area corresponding to at least one third ground category according to the average speed of the target object in the first area; finally, a fourth time is determined according to the two times. For example, if the at least one first ground category comprises (grass, concave-convex), (rock, inclined), the at least one second ground category comprises (grass, flat), (rock, inclined), at which point it may be determined that the matching was successful in the at least one third ground category is (rock, inclined).
In the embodiment of the application, the accuracy of determining the fourth time can be improved by adopting the method, so that the second camera can conveniently adjust and control the shooting angle.
It can be seen that in the embodiment of the present application, when a target object is detected in a shooting area of a first camera in a plurality of cameras, behavior recognition is performed on the target object, so as to obtain a behavior recognition result; if the existence of the launching behavior of the target object is determined according to the behavior identification result, the first camera is controlled to track the target object so that the target object is located in a shooting area of the first camera; and when the target object leaves the region which can be shot by the first camera, controlling the second camera to track the target object. By adopting the method, the monitoring of the target object can be finished to the greatest extent under the condition of less cameras, so that the position and the behavior of the target object can be conveniently pre-warned.
In accordance with the above-mentioned embodiment, referring to fig. 4a, fig. 4a is a functional unit block diagram of a video monitoring device according to an embodiment of the present application, where the functional unit block diagram is applied to a monitoring device, and the monitoring device monitors the surrounding environment of a water body through a plurality of cameras, as shown in fig. 4a, the video monitoring device 40 includes:
A processing unit 401, configured to perform behavior recognition on a behavior of a target object when the target object is detected in a shooting area of a first camera of the plurality of cameras, so as to obtain a behavior recognition result;
if the determining unit 402 determines that the target object has a launch behavior according to the behavior recognition result, the control unit 403 is configured to control the first camera to track the target object, so that the target object is located in a shooting area of the first camera, the launch behavior is used to characterize a behavior made when entering the water body from a surrounding environment of the water body,
the control unit 403 is further configured to control the second camera to track the target object when the target object leaves the first area, so that the target object is located in a shooting area of the second camera, where the first area is an area that the first camera can shoot.
In a possible embodiment, the behavior recognition result includes a moving direction of the target object, and before the control unit 403 is configured to control the second camera to track the target object, the control unit is further configured to: acquiring position information of a plurality of cameras; and determining a second camera from the cameras according to the moving direction of the target object and the position information of the cameras.
In a possible embodiment, the determining unit 402 is configured to determine, from the plurality of cameras, the second camera according to the moving direction of the target object and the position information of the plurality of cameras, including: acquiring map information of a water body and surrounding environment of the water body; determining a movable area corresponding to the target object according to the map information; determining a first moving area of the target object according to the moving direction of the target object and the movable area corresponding to the target object; determining a plurality of third cameras in the plurality of cameras according to the first moving area of the target object and the position information of the plurality of cameras, wherein the plurality of third cameras are cameras with overlapping areas which can be shot in the plurality of cameras and the first moving area; and determining the camera closest to the target object in the plurality of third cameras as a second camera.
In a possible embodiment, the behavior recognition result includes a moving speed of the target object, and the determining unit 402 is further configured to: when a corresponding tracking object exists in a shooting area of the second camera, determining a first time when the tracking object leaves the second area, wherein the second area is an area which can be shot by the second camera; determining a second time for transferring the second camera from the first shooting area to the second shooting area, wherein the first shooting area is an area shot by the second camera when the tracking object leaves the second area, and the second shooting area is an area shot by the second camera when the time for entering the area shot by the second camera after the target object leaves the first area is shortest; calculating the sum of the first time and the second time to obtain a third time; determining a second moving area according to the first moving area and the position information of the cameras, wherein the second moving area is an area where the target object moves from the first area to the second area; determining a fourth time according to the second moving area of the target object and the moving speed of the target object, wherein the fourth time is the time taken by the target object to move from the first area to the second area; if the third time is longer than the fourth time, determining a fourth camera in the plurality of third cameras, and determining that the fourth camera is a new second camera, wherein the fourth camera is a camera closest to the target object except the second camera in the plurality of third cameras.
In a possible embodiment, the determining unit 402 is further configured to: when a corresponding tracking object exists in a shooting area of the second camera, determining a first water falling danger level corresponding to the tracking object, wherein the first water falling danger level is used for representing the probability that the tracking object enters the water body from the surrounding environment of the water body; determining a second water falling risk level corresponding to the target object, wherein the second water falling risk level is used for representing the probability of the target object entering the water body from the surrounding environment of the water body; if the first water falling danger level is greater than or equal to the second water falling danger level, determining a fourth camera of the plurality of third cameras, determining the fourth camera as a new second camera, and determining the fourth camera as a camera closest to the first camera except the second camera of the plurality of third cameras.
In a possible embodiment, the behavior recognition result further includes a movement speed of the target object, and the determining unit 402 is further configured to: if the first water falling danger level is smaller than the second water falling danger level, determining a second moving area of the target object according to the first moving area of the target object and the position information of the cameras, wherein the second moving area is an area in which the target object moves from the first area to the second area, and the second area is an area in which the second camera can shoot; determining a fourth time of the target object according to the second moving area of the target object and the moving speed of the target object, wherein the fourth time is the time taken by the target object to move from the first area to the second area; and controlling the second camera to track the tracking object according to the fifth time, and transferring the tracking object to the second shooting area by a third shooting area after the fifth time, wherein the third shooting area is an area shot by the second camera to the tracking object, the second shooting area is an area shot by the second camera when the time of the target object leaving from the first area and entering the area shot by the second camera is shortest, and the difference value between the fourth time and the fifth time is larger than the time taken by the second camera to transfer from the third shooting area to the second shooting area.
In a possible embodiment, the determining unit 402 is configured to determine a fourth time of the target object according to the second moving area of the target object and the moving speed of the target object, including: determining at least one first ground class of an area in which the target object moves in the first area; determining at least one second ground category for a second movement region; matching the at least one second ground category with the at least one first ground category; if the matching is successful, determining at least one third ground category which is successfully matched in the at least one second ground category; determining a first moving time corresponding to a fourth moving area according to the moving speed of the target object in the third moving area, wherein the third moving area is an area corresponding to at least one third ground category in the first area, and the fourth moving area is an area corresponding to at least one third ground category in the first moving area; determining a second movement time corresponding to a fifth movement region according to the movement speed of the target object in the first region, wherein the fifth movement region is a region except the fourth movement region in the first movement region; the fourth time is determined based on the first movement time and the second movement time.
It can be understood that, since the method embodiment and the apparatus embodiment are different presentation forms of the same technical concept, the content of the method embodiment portion in the present application should be synchronously adapted to the apparatus embodiment portion, which is not described herein.
In the case of using integrated units, as shown in fig. 4b, fig. 4b is a functional unit block diagram of another video monitoring apparatus according to an embodiment of the present application. In fig. 4b, the video monitoring apparatus 41 includes: a processing module 412 and a communication module 411. The processing module 412 is used to control and manage the actions of the video surveillance device, e.g., the steps of the processing unit 401, the determining unit 402, and the control unit 403, and/or other processes for performing the techniques described herein. The communication module 411 is used to support interaction between the video surveillance apparatus and other devices. As shown in fig. 4b, the video monitoring device 41 may further comprise a storage module 413, the storage module 413 being configured to store program code and data of the video monitoring device.
The processing module 412 may be a processor or controller, such as a central processing unit (Central Processing Unit, CPU), a general purpose processor, a digital signal processor (Digital Signal Processor, DSP), an ASIC, an FPGA or other programmable logic device, a transistor logic device, a hardware component, or any combination thereof. Which may implement or perform the various exemplary logic blocks, modules and circuits described in connection with this disclosure. A processor may also be a combination that performs computing functions, e.g., including one or more microprocessors, a combination of a DSP and a microprocessor, and so forth. The communication module 411 may be a transceiver, an RF circuit, or a communication interface, etc. The memory module 413 may be a memory.
All relevant contents of each scenario related to the above method embodiment may be cited to the functional description of the corresponding functional module, which is not described herein. The video monitoring device 41 may perform the video monitoring method shown in fig. 2.
The above embodiments may be implemented in whole or in part by software, hardware, firmware, or any other combination. When implemented in software, the above-described embodiments may be implemented in whole or in part in the form of a computer program product. The computer program product comprises one or more computer instructions or computer programs. When the computer instructions or computer program are loaded or executed on a computer, the processes or functions in accordance with embodiments of the present application are produced in whole or in part. The computer may be a general purpose computer, a special purpose computer, a computer network, or other programmable apparatus. The computer instructions may be stored in or transmitted from one computer-readable storage medium to another, for example, by wired or wireless means from one website site, computer, server, or data center. Computer readable storage media can be any available media that can be accessed by a computer or data storage devices, such as servers, data centers, etc. that contain one or more collections of available media. The usable medium may be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium. The semiconductor medium may be a solid state disk.
Fig. 5 is a block diagram of an electronic device according to an embodiment of the present application. As shown in fig. 5, the electronic device 500 may include one or more of the following components: a processor 501, a memory 502 coupled to the processor 501, wherein the memory 502 may store one or more computer programs that may be configured to implement the methods as described in the embodiments above when executed by the one or more processors 501. The electronic device 500 may be the above-mentioned monitoring device.
The processor 501 may include one or more processing cores. The processor 501 utilizes various interfaces and lines to connect various portions of the overall electronic device 500, perform various functions of the electronic device 500, and process data by executing or executing instructions, programs, code sets, or instruction sets stored in the memory 502, and invoking data stored in the memory 502. Alternatively, the processor 501 may be implemented in at least one hardware form of digital signal processing (Digital Signal Processing, DSP), field-Programmable gate array (FPGA), programmable Logic Array (PLA). The processor 501 may integrate one or a combination of several of a central processing unit (CentralProcessing Unit, CPU), an image processor (Graphics Processing Unit, GPU), and a modem, etc. It will be appreciated that the modem may not be integrated into the processor 501 and may be implemented solely by a single communication chip.
The Memory 502 may include a random access Memory (Random Access Memory, RAM) or a Read-Only Memory (ROM). Memory 502 may be used to store instructions, programs, code sets, or instruction sets. The memory 502 may include a stored program area and a stored data area, wherein the stored program area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playing function, an image playing function, etc.), instructions for implementing the various method embodiments described above, and the like. The storage data area may also store data created by the electronic device 500 in use, and the like.
It is to be appreciated that the electronic device 500 may include more or fewer structural elements than those described in the above-described block diagrams, including, for example, a power module, physical key, wiFi (Wireless Fidelity ) module, speaker, bluetooth module, sensor, etc., without limitation.
An embodiment of the present application provides a computer readable storage medium, where the computer readable storage medium stores program data that, when executed by a processor, is configured to perform part or all of the steps of any one of the video monitoring methods described in the above method embodiments.
Embodiments of the present application also provide a computer program product comprising a non-transitory computer readable storage medium storing a computer program operable to cause a computer to perform part or all of the steps of any one of the video surveillance methods described in the method embodiments above. The computer program product may be a software installation package.
It should be noted that, for simplicity of description, the method embodiments of any one of the video monitoring methods are described as a series of combinations of actions, but it should be understood by those skilled in the art that the present application is not limited by the order of actions described, as some steps may be performed in other orders or simultaneously according to the present application. Further, those skilled in the art will appreciate that the embodiments described in the specification are presently preferred embodiments, and that the acts are not necessarily required for the present application.
Although the application is described herein in connection with various embodiments, other variations to the disclosed embodiments can be understood and effected by those skilled in the art in practicing the claimed application, from a study of the drawings, the disclosure, and the appended claims. In the claims, the word "comprising" does not exclude other elements or steps, and the "a" or "an" does not exclude a plurality. The mere fact that certain measures are recited in mutually different dependent claims does not indicate that a combination of these measures cannot be used to advantage.
Those of ordinary skill in the art will appreciate that all or a portion of the steps in the various method embodiments of any of the video surveillance methods described above may be performed by a program that instructs associated hardware, and that the program may be stored in a computer readable memory, which may include: flash disk, read-Only Memory (ROM), random access Memory (Random Access Memory, RAM), magnetic disk or optical disk.
The foregoing describes embodiments of the present application in detail, and specific examples are applied to illustrate the principles and embodiments of a video monitoring method and apparatus of the present application, where the foregoing embodiments are only used to help understand the method and core idea of the present application; meanwhile, as for those skilled in the art, according to the idea of a video monitoring method and apparatus of the present application, there are variations in the specific embodiments and application ranges, and in summary, the disclosure should not be construed as limiting the present application.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, hardware products, and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may 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 instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may 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 flow or flows and/or block diagram block or blocks.
It will be appreciated that any product of the processing method of the flowcharts described in connection with the method embodiments of a video surveillance method according to the application, such as the terminals of the flowcharts described above and the computer program products, falls within the scope of the relevant product described in connection with the application.
It will be apparent to those skilled in the art that various modifications and variations can be made in a video monitoring method and apparatus provided herein without departing from the spirit and scope of the application. Thus, it is intended that the present application also include such modifications and alterations insofar as they come within the scope of the appended claims or the equivalents thereof.