Video shooting control method and system, computer equipment and storage medium
By combining fixed gain, historical error gain, and morphological structure similarity calculation methods in video shooting technology, the external motion mechanism of the shooting equipment is adjusted to solve the problem of stability and speed consistency and close-range control stability in the existing technology. problem, achieving improved picture stability and fluency.
Patent Information
- Application Number
- CN202111576090.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-21
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2041-12-21
AI Technical Summary
The existing technology cannot maintain stability in a small range and maintain rapidity in a large range, and cannot cope with control stability problems in close-range shooting and control stability problems when the target shape changes rapidly.
Fixed gain processing is performed by obtaining the offset in the video image, and the historical error gain is determined based on the absolute value of the offset of the first N frames. The morphological structure similarity is calculated by combining the previous K frames of video images obtained at preset frames to determine the continuity of the structure. Gain, ultimately adjusting the external motion mechanism of the shooting device.
It has improved the stability, fluency and reliability of shooting images in a wide range of application scenarios, and solved the problems of small-scale stability and large-scale rapidity consistency, close-range control stability and control stability when the target shape changes rapidly. .
Smart Images

Figure CN114245016B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present invention relate to the field of video shooting technology, and in particular to a video shooting control method and system, a computer device and a storage medium. Background Art
[0002] In the process of continuous tracking and shooting of the shooting target, the continuity, smoothness and stability of the camera movement are very important performances, otherwise the shooting picture will be jittery, discontinuous or dizzy. In a wide range of video shooting activities, such as video calls, video conferencing, online teaching and other applications, people have put forward higher requirements for the video shooting picture: 1. When the shooting target has a small range of movement, or it is just a change in shape rather than actual displacement, the stability of the shooting picture should be prioritized to avoid obvious movement in the picture; 2. When the shooting target moves obviously, it should be able to adjust quickly and track in real time, on the one hand to avoid the target from being out of the picture, on the other hand, the shooting picture needs to ensure smoothness and be able to quickly track the shooting target; 3. The current technology uses a fixed gain control method, and the error of the shooting target picture is multiplied by a fixed gain, and then converted into the control speed or angle of the external motion mechanism (such as the gimbal).
[0003] However, the fixed gain control method based on the existing technology cannot achieve consistency between stability in a small range and rapidity in a large range, nor can it cope with the control stability problem under close-range shooting, and cannot cope with the control stability problem when the shape of the shooting target changes rapidly. How to solve the above problems is a technical problem that we urgently need to solve. Summary of the invention
[0004] The present invention provides a video shooting control method and system, a computer device and a storage medium, so as to comprehensively improve the stability, fluency and reliability of shooting picture control in a wide range of application scenarios.
[0005] In a first aspect, an embodiment of the present invention provides a video shooting control method, the video shooting control method comprising:
[0006] Obtaining an offset of a current position of a shooting target in a video image from a target position, and performing fixed gain processing on the offset using a fixed gain controller;
[0007] Determine a historical error gain according to the maximum absolute value of the offset of the target captured in the previous N frames, and use the historical error gain to perform gain processing on the offset after fixed gain processing;
[0008] Acquire the first K frames of video images at intervals of preset frames, calculate the morphological structure similarity between two adjacent frames of the acquired K frames of video images, determine the structural continuity gain according to the morphological structure similarity, and use the structural continuity gain to perform gain processing on the offset after the historical error gain processing;
[0009] The external motion mechanism of the shooting device is adjusted according to the offset after the structure continuous gain processing.
[0010] The determining of the historical error gain according to the maximum absolute value of the offset of the target shot in the previous N frames, and performing gain processing on the offset after fixed gain processing by using the historical error gain comprises:
[0011] Normalize the offsets of the shooting targets of the first N frames respectively;
[0012] Obtain the maximum absolute value of the offset of the photographed target after normalization;
[0013] Gain processing is performed on the offset after fixed gain processing according to the maximum value.
[0014] The step of calculating the morphological structure similarity between two adjacent frames based on the current frame and the acquired first K frames of video images, and determining the structural continuous gain based on the morphological structure similarity includes:
[0015] Calculate the morphological structure similarity between two adjacent frames based on the current frame and the acquired previous K frames of video images;
[0016] Calculate the average of all morphological structural similarities;
[0017] A structural continuous gain is determined based on the average value.
[0018] Wherein, determining the structural continuous gain according to the average value comprises:
[0019] performing a minimum amplitude limiting process on the average value; and / or performing a nonlinear transformation process on the average value; and / or performing a filtering process on the average value;
[0020] The processed result is used as the structural continuous gain.
[0021] Wherein, acquiring the first K frames of video images at intervals of preset frames comprises:
[0022] The preset interval of the preset frames is preset as G frames;
[0023] Acquire the previous G-th frame, the previous 2*G-th frame, ..., and the previous K*G-th frame of video images.
[0024] In a second aspect, an embodiment of the present invention further provides a video shooting control system, the video shooting control system comprising:
[0025] A fixed gain module is used to obtain an offset between the current position of the shooting target in the video image and the target position, and to perform fixed gain processing on the offset using a fixed gain controller;
[0026] A historical error gain module, used to determine a historical error gain according to the maximum absolute value of the offset of the target shot in the previous N frames, and use the historical error gain to perform gain processing on the offset after fixed gain processing;
[0027] A structural continuous gain module is used to obtain the previous K frames of video images at intervals of preset frames, calculate the morphological structure similarity between two adjacent frames according to the current frame and the obtained previous K frames of video images, determine the structural continuous gain according to the morphological structure similarity, and use the structural continuous gain to perform gain processing on the offset after the historical error gain processing;
[0028] The adjustment module is used to adjust the external motion mechanism of the shooting device according to the offset after the structural continuous gain processing.
[0029] Wherein, the historical error gain module is specifically used for:
[0030] Normalize the offsets of the shooting targets of the first N frames respectively;
[0031] Obtain the maximum absolute value of the offset of the photographed target after normalization;
[0032] Gain processing is performed on the offset after fixed gain processing according to the maximum value.
[0033] Wherein, the structured continuous gain module is specifically used for:
[0034] Calculate the morphological structure similarity between two adjacent frames based on the current frame and the acquired previous K frames of video images;
[0035] Calculate the average of all morphological structural similarities;
[0036] A structural continuous gain is determined based on the average value.
[0037] In a third aspect, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the above-mentioned video shooting control method when executing the program.
[0038] In a fourth aspect, a computer-readable storage medium is provided, on which a computer program is stored, characterized in that when the program is executed by a processor, the above-mentioned video shooting control method is implemented.
[0039] The video shooting control method provided by the present invention determines the historical error gain according to the maximum absolute value of the offset of the shooting target of the previous N frames after the traditional fixed gain processing, and uses the historical error gain to perform gain processing on the offset after the fixed gain processing; and obtains the previous K frames of video images at intervals of preset frames, calculates the morphological structure similarity between two adjacent frames of the obtained K frames of video images, determines the structural continuous gain according to the morphological structure similarity, and uses the structural continuous gain to perform gain processing on the offset after the historical error gain processing; finally, the external motion mechanism of the shooting device is adjusted according to the offset after the structural continuous gain processing, so as to solve the problem that the stability in a small range and the rapidity in a large range cannot be consistent, the control stability problem under close-range shooting cannot be coped with, and the control stability problem when the target morphology changes rapidly, and realizes the comprehensive improvement of the stability, fluency and reliability of the shooting picture control in a wide range of application scenarios. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] Figure 1 This is a method flow chart of a video shooting control method provided in Embodiment 1 of the present invention.
[0041] Figure 2 This is a sub-method flow chart of a video shooting control method provided in Embodiment 1 of the present invention.
[0042] Figure 3 This is another sub-method flow chart of a video shooting control method provided in the first embodiment of the present invention.
[0043] Figure 4 This is a structural block diagram of a video shooting control system provided by Embodiment 2 of the present invention.
[0044] Figure 5 It is a structural block diagram of a computer device provided in Embodiment 3 of the present invention. DETAILED DESCRIPTION
[0045] The present invention will be further described in detail below in conjunction with the accompanying drawings and embodiments. It is to be understood that the specific embodiments described herein are only used to explain the present invention, rather than to limit the present invention. It should also be noted that, for ease of description, only parts related to the present invention, rather than all structures, are shown in the accompanying drawings.
[0046] Embodiment 1
[0047] Figure 1 This is a flow chart of a video shooting control method provided in Embodiment 1 of the present invention. This embodiment is applicable to target tracking shooting. The method can be performed by a camera with a pan / tilt head, and specifically includes the following steps:
[0048] Step 110: Obtain an offset between the current position of the captured target in the video image and the target position, and use a fixed gain controller to perform fixed gain processing on the offset.
[0049] This embodiment first uses a fixed gain controller to perform fixed gain processing on the offset, which is a prior art and will not be described here. However, the fixed gain processing in the prior art cannot achieve consistency between stability in a small range and rapidity in a large range, nor can it cope with the control stability problem under close-range shooting, and cannot cope with the control stability problem when the target shape changes rapidly. Therefore, on this basis, this embodiment continues to perform further operations on the offset after the fixed gain processing.
[0050] Step S120 , determining a historical error gain according to the maximum absolute value of the offset of the target shot in the previous N frames, and performing gain processing on the offset after fixed gain processing by using the historical error gain.
[0051] This embodiment determines the historical error gain according to the maximum offset among the absolute values of the offsets of the shooting targets in the previous N frames, and then uses the historical error gain to perform gain processing on the offset after the fixed gain processing. This means that if the offset of the shooting target is relatively small within a period of time, the historical error gain will also be very small, and the system's control over the motion mechanism of the shooting device will tend to be "inert", that is, the movement amplitude and speed of the shooting device will be slowed down, and the picture will be more stable; when the offset of the shooting target is relatively large, the historical error gain will also increase, and the system's control over the motion mechanism of the shooting device will tend to be "agile", that is, the movement amplitude and speed of the camera will be increased, so as to achieve rapid tracking of the shooting target.
[0052] In some embodiments, Figure 2 As shown, step S120, determining the historical error gain according to the maximum absolute value of the offset of the target shot in the previous N frames, and performing gain processing on the offset after fixed gain processing by using the historical error gain includes steps S121 to S123, and the specific contents are as follows:
[0053] Step S121, normalize the offsets of the shooting targets of the first N frames respectively.
[0054] Step S122: Obtain the maximum absolute value of the offset of the photographed target after normalization.
[0055] Step S123: Perform gain processing on the offset after fixed gain processing by using the historical error gain determined according to the maximum value.
[0056] Assume that the normalized offsets of the objects captured in the first N frames are: i}={e-1 , e -2 , ..., e -N},e i ∈(-0.5, +0.5), i=1,2,…,N; where, e -1 represents the normalized result of the offset of the target shot in the first frame before, e -2 represents the normalized result of the offset of the target captured in the second frame before, ..., e -N Represents the normalized result of the offset of the target shot in the previous N frames; then the historical error gain α is determined according to the maximum absolute value of the offset HEGA , α HEGA =k HEGA ·max{|e _i |}, i = 1, 2, ..., N; where k HEGA is the gain of the corresponding regulator, is a constant, as an example, k HEGA is 2, k HEGA It can also be adjusted according to actual conditions. HEGA The offset after fixed gain processing is processed. When the shooting target moves in a small range, the system will quickly reduce the movement speed of the external motion mechanism of the shooting device, thereby reducing the movement speed of the shooting device to achieve the stability of the picture; and when the shooting target moves in a large range, the response speed of the external motion mechanism of the shooting device can be improved without delay, thereby increasing the movement speed of the shooting device to achieve rapid tracking of the shooting target, meeting the user's requirements for stability and rapid responsiveness.
[0057] It should be noted that N is equivalent to a memory parameter of the corresponding regulator. In some embodiments, the value range of N is the number of shooting frames corresponding to the camera within 0.5s to 1s. This can avoid the situation where the system tends to use the current real-time error to adjust the gain due to the short memory time, resulting in deterioration of system performance; it can also avoid the situation where the shooting target is prone to have a long memory time after rapid movement due to the long memory time, which increases the inertia of the system and leads to deterioration of gain performance.
[0058] Step S130, obtaining the previous K frames of video images at preset intervals, calculating the morphological structure similarity between two adjacent frames based on the current frame and the obtained previous K frames of video images, determining the structural continuity gain based on the morphological structure similarity, and using the structural continuity gain to perform gain processing on the offset after the historical error gain processing.
[0059] The historical error gain still has certain defects. It is completely dependent on the initial deviation of the target. When the target moves violently or is close to the target, the target only changes in shape but not in position. This may cause the actual value of the target's offset to be larger, that is, the historical error gain will also increase. The faster tracking speed will make the picture shake more violently, making the user feel dizzy. In order to solve this problem, this embodiment adds a structural continuous gain process, which can significantly reduce the morphological structure similarity of the target when the shape of the target changes violently, so that the structural continuous gain is attenuated, so that the control speed of the external motion mechanism of the shooting device is slowed down, and the stability of the picture is enhanced.
[0060] Preferably, this embodiment obtains a limb vector feature map of the photographed target from a portrait pose estimation network (assuming the channel is C), and then crops and scales the feature map to a fixed size in the bounding box position of the photographed target to obtain a morphological structure feature map; for two adjacent frames of video images, a correlation calculation is performed between two identical channels to obtain correlation values of C channels of the morphological structure feature map corresponding to the two adjacent frames of video images, and finally average pooling is performed to obtain the final morphological structure similarity of the two adjacent frames of video images.
[0061] The video shooting control method provided by the present invention determines the historical error gain according to the maximum absolute value of the offset of the shooting target of the previous N frames after the traditional fixed gain processing, and uses the historical error gain to perform gain processing on the offset after the fixed gain processing; and obtains the previous K frames of video images at intervals of preset frames, calculates the morphological structure similarity between two adjacent frames of the obtained K frames of video images, determines the structural continuous gain according to the morphological structure similarity, and uses the structural continuous gain to perform gain processing on the offset after the historical error gain processing; finally, the external motion mechanism of the shooting device is adjusted according to the offset after the structural continuous gain processing, so as to solve the problem that the stability in a small range and the rapidity in a large range cannot be consistent, the control stability problem under close-range shooting cannot be dealt with, and the control stability problem when the shooting target morphology changes rapidly can not be dealt with, and realizes the comprehensive improvement of the stability, fluency and reliability of the shooting picture control in a wide range of application scenarios.
[0062] In some embodiments, Figure 3 As shown, step S130, obtaining the previous K frames of video images at intervals of preset frames, calculating the morphological structure similarity between two adjacent frames according to the current frame and the obtained previous K frames of video images, and determining the structural continuous gain according to the morphological structure similarity includes steps S131 to S134, and the specific contents are as follows:
[0063] Step S131, obtaining the first K frames of video images at preset frame intervals.
[0064] Specifically, in some embodiments, step S131, acquiring the first K frames of video images at intervals of preset frames, includes:
[0065] The preset interval of the preset frames is preset as G frames;
[0066] Acquire the previous G-th frame, the previous 2*G-th frame, ..., and the previous K*G-th frame of video images.
[0067] In this embodiment, the offset of the current position of the shooting target in the video image from the target position is obtained every G frames, which can reduce the subsequent calculation burden of the system. In some embodiments, K=1-5, and G can be set according to actual needs, representing the memory between two frames, and it is not easy to be too small or too large. Generally, G takes the number of frames of 0.5 seconds to 1 second.
[0068] Step S132: Calculate the morphological structure similarity between two adjacent frames based on the current frame and the acquired previous K frames of video images.
[0069] Step S133: Calculate the average value of all morphological structure similarities.
[0070] Step S134: determine the structural continuous gain according to the average value.
[0071] The structural continuity gain describes the impact of the morphological change of the photographed target on the gain. If the morphological consistency of the photographed target is good, the structural continuity gain can be considered to be a constant with a gain of 1, that is, the system control speed does not change; if the morphology of the photographed target is in the process of drastic changes, or due to adverse effects such as occlusion, the morphological structure similarity of the photographed target will decrease significantly, so that the structural continuity gain will attenuate, which can slow down the system control speed, thereby achieving the purpose of enhancing the stability of the picture.
[0072] In some embodiments, step S134, determining the structural continuous gain according to the average value specifically includes:
[0073] performing a minimum amplitude limiting process on the average value; and / or performing a nonlinear transformation process on the average value; and / or performing a filtering process on the average value;
[0074] The processed result is used as the structural continuous gain.
[0075] This embodiment performs minimum amplitude limitation processing on the average value to prevent the structural continuous gain from being too small, which causes the system control speed to become too slow; performs nonlinear transformation processing on the average value to adjust the characteristics of the structural continuous gain, which is beneficial to improving the continuity of the gain change; and performs filtering processing on the average value to further enhance the continuity of the gain change. A common low-pass filter or an adaptive Kalman-like filter can be used, thereby further enhancing the stability, smoothness and reliability of the image.
[0076] Step S140: adjusting the external motion mechanism of the shooting device according to the offset after the structural continuous gain processing.
[0077] In this embodiment, the external motion mechanism of the shooting device includes but is not limited to components such as a gimbal, a motor, and a robotic arm that can control the movement of the lens. This embodiment adjusts the external motion mechanism of the shooting device according to the offset after the structural continuous gain processing, thereby solving the problem of being unable to achieve consistency between stability in a small range and rapidity in a large range, the problem of being unable to cope with control stability problems under close-range shooting, and the problem of being unable to cope with control stability problems when the target shape changes rapidly, thereby achieving comprehensive improvement in the stability, smoothness, and reliability of shooting picture control in a wide range of application scenarios.
[0078] In this embodiment, the video image after fixed gain processing is determined according to the maximum value of the absolute value of the offset of the shooting target in the previous N frames. After the historical error gain processing, the morphological structure similarity between two adjacent frames is calculated according to the current frame and the previous K frames of video images obtained, and the structural continuity gain is determined according to the morphological structure similarity. Using the technical solution provided by this embodiment, if the offset of the shooting target is relatively small in the past period of time, the historical error gain will also be very small, and the system's control of the external motion mechanism of the shooting device will tend to be "inert", that is, the movement amplitude and speed of the shooting device will be slowed down, and the picture will be more stable; when the offset of the shooting target is relatively large, the historical error gain will also increase, and the system's control of the external motion mechanism of the shooting device will tend to be "agile", that is, the movement amplitude and speed of the shooting device will increase, and the shooting target will be quickly tracked; after the historical error gain processing, by adding the structural continuity gain processing, when the morphology of the shooting target changes dramatically, the morphological structure similarity of the shooting target will significantly decrease, so that the structural continuity gain is attenuated, so that the control speed of the shooting device is slowed down, and the stability of the picture is enhanced.
[0079] Embodiment 2
[0080] Figure 4This is a structural block diagram of a video shooting control system provided by the second embodiment of the present invention. The video shooting control system provided by the embodiment of the present invention can execute the video shooting control method provided by any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method. Figure 4 The video shooting control system provided by the embodiment of the present invention includes a fixed gain module 41, a historical error gain module 42, a structure continuous gain module 43 and a parameter adjustment module 44, and the specific contents are as follows:
[0081] The fixed gain module 41 is used to obtain the offset between the current position of the shooting target in the video image and the target position, and perform fixed gain processing on the offset by using a fixed gain controller.
[0082] The historical error gain module 42 is used to determine the historical error gain according to the maximum absolute value of the offset of the target shot in the previous N frames, and use the historical error gain to perform gain processing on the offset after fixed gain processing.
[0083] The structural continuous gain module 43 is used to obtain the previous K frames of video images at preset frame intervals, calculate the morphological structure similarity between two adjacent frames based on the current frame and the obtained previous K frames of video images, determine the structural continuous gain based on the morphological structure similarity, and use the structural continuous gain to perform gain processing on the offset after historical error gain processing.
[0084] In some embodiments, acquiring the first K frames of video images at intervals of preset frames includes:
[0085] The preset interval of the preset frames is preset as G frames;
[0086] Acquire the previous G-th frame, the previous 2*G-th frame, ..., and the previous K*G-th frame of video images.
[0087] The adjustment module 44 is used to adjust the external motion mechanism of the shooting device according to the offset after the structural continuous gain processing.
[0088] In some embodiments, the historical error gain module 42 is specifically used to:
[0089] Normalize the offsets of the shooting targets of the first N frames respectively;
[0090] Obtain the maximum absolute value of the offset of the photographed target after normalization;
[0091] Gain processing is performed on the offset after fixed gain processing according to the maximum value.
[0092] In some embodiments, the structured continuous gain module 43 is specifically used for:
[0093] Calculate the morphological structure similarity between two adjacent frames based on the current frame and the acquired previous K frames of video images;
[0094] Calculate the average of all morphological structural similarities;
[0095] A structural continuous gain is determined based on the average value.
[0096] In some embodiments, determining the structural continuous gain according to the average value specifically includes:
[0097] performing a minimum amplitude limiting process on the average value; and / or performing a nonlinear transformation process on the average value; and / or performing a filtering process on the average value;
[0098] The processed result is used as the structural continuous gain.
[0099] This embodiment determines the historical error gain of the video image after fixed gain processing according to the maximum value of the absolute value of the offset of the shooting target in the previous N frames. After the historical error gain processing, the morphological structure similarity between two adjacent frames is calculated according to the current frame and the previous K frames of video images obtained, and the structural continuity gain is determined according to the morphological structure similarity. This implementation solves the problem of being unable to reach consistency between small-range stability and large-range rapidity, the problem of being unable to cope with the control stability problem under close-range shooting, and the problem of being unable to cope with the control stability problem when the shooting target morphology changes rapidly, and achieves comprehensive improvement of the stability, smoothness and reliability of shooting picture control in a wide range of application scenarios.
[0100] Embodiment 3
[0101] Figure 5 A schematic diagram of the structure of a computer device provided in Embodiment 3 of the present invention is shown in FIG. Figure 5 As shown, the computer device includes a memory 100 and a processor 200. The number of the processors 200 in the computer device may be one or more. Figure 5 A processor 200 is taken as an example; the memory 100 and the processor 200 in the device can be connected via a bus or other means. Figure 5 The example of connecting through bus is taken in the following.
[0102] The memory 100, as a computer-readable storage medium, can be used to store software programs, computer executable programs and modules, such as program instructions / modules corresponding to the video shooting control method in the embodiment of the present invention (for example, the fixed gain module 41, the historical error gain module 42, the structural continuous gain module 43 and the adjustment module 44 in the video shooting control system). The processor 200 executes various functional applications and data processing of the device / terminal / device by running the software programs, instructions and modules stored in the memory 100, that is, realizes the above-mentioned video shooting control method.
[0103] The processor 200 is used to run the computer program stored in the memory 100 to implement the following steps:
[0104] Obtaining an offset of a current position of a shooting target in a video image from a target position, and performing fixed gain processing on the offset using a fixed gain controller;
[0105] Determine the historical error gain according to the maximum absolute value of the offset of the target shot in the previous N frames, and use the historical error gain to perform gain processing on the offset after fixed gain processing;
[0106] Acquire the previous K frames of video images at intervals of preset frames, calculate the morphological structure similarity between two adjacent frames according to the current frame and the acquired previous K frames of video images, determine the structural continuity gain according to the morphological structure similarity, and use the structural continuity gain to perform gain processing on the offset after the historical error gain processing;
[0107] The external motion mechanism of the shooting device is adjusted according to the offset after the structure continuous gain processing.
[0108] In one embodiment, a computer device provided by an embodiment of the present invention, whose computer program is not limited to the above method operations, can also execute related operations in the video shooting control method provided by any embodiment of the present invention.
[0109] The memory 100 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system and at least one application required for a function; the data storage area may store data created according to the use of the terminal, etc. In addition, the memory 100 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some instances, the memory 100 may further include a memory remotely arranged relative to the processor 200, and these remote memories may be connected to the device / terminal / device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0110] Embodiment 4
[0111] Embodiment 4 of the present invention further provides a computer-readable storage medium. A computer program is stored thereon, the computer program includes program instructions, and when the program instructions are executed by a processor, a video shooting control method is implemented, the video shooting control method includes: obtaining an offset of a current position of a shooting target from a target position in a video image, and performing fixed gain processing on the offset using a fixed gain controller;
[0112] Determine a historical error gain according to the maximum absolute value of the offset of the target captured in the previous N frames, and use the historical error gain to perform gain processing on the offset after fixed gain processing;
[0113] Acquire the previous K frames of video images at intervals of preset frames, calculate the morphological structure similarity between two adjacent frames according to the current frame and the acquired previous K frames of video images, determine the structural continuity gain according to the morphological structure similarity, and use the structural continuity gain to perform gain processing on the offset after the historical error gain processing;
[0114] The external motion mechanism of the shooting device is adjusted according to the offset after the structure continuous gain processing.
[0115] Of course, the storage medium containing computer executable instructions provided by an embodiment of the present invention, whose computer executable instructions are not limited to the above method operations, can also execute related operations in the video shooting control method provided by any embodiment of the present invention.
[0116] Through the above description of the implementation methods, the technicians in the relevant field can clearly understand that the present invention can be implemented by means of software and necessary general hardware, and of course it can also be implemented by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as a computer floppy disk, read-only memory (ROM), random access memory (RAM), flash memory (FLASH), hard disk or optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, device, or network device, etc.) to execute the methods described in each embodiment of the present invention.
[0117] It is worth noting that in the embodiment of the above-mentioned multi-person tracking device, the various units and modules included are only divided according to functional logic, but are not limited to the above-mentioned division, as long as the corresponding functions can be achieved; in addition, the specific names of the functional units are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of the present invention.
[0118] Note that the above are only preferred embodiments of the present invention and the technical principles used. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and that various obvious changes, readjustments and substitutions can be made by those skilled in the art without departing from the scope of protection of the present invention. Therefore, although the present invention has been described in more detail through the above embodiments, the present invention is not limited to the above embodiments, and may include more other equivalent embodiments without departing from the concept of the present invention, and the scope of the present invention is determined by the scope of the appended claims.
Claims
1. A video shooting control method, characterized in that: The video shooting control method comprises: Obtaining an offset of a current position of a shooting target in a video image from a target position, and performing fixed gain processing on the offset using a fixed gain controller; Determine a historical error gain according to the maximum absolute value of the offset of the target captured in the previous N frames, and use the historical error gain to perform gain processing on the offset after fixed gain processing; Acquire the previous K frames of video images at intervals of preset frames, calculate the morphological structure similarity between two adjacent frames according to the current frame and the acquired previous K frames of video images, calculate the average value of all morphological structure similarities, determine the structural continuous gain according to the average value, and use the structural continuous gain to perform gain processing on the offset after the historical error gain processing; The external motion mechanism of the shooting device is adjusted according to the offset after the structure continuous gain processing.
2. The video shooting control method according to claim 1, characterized in that: Determining the historical error gain according to the maximum absolute value of the offset of the target shot in the previous N frames, and performing gain processing on the offset after fixed gain processing by using the historical error gain includes: Normalize the offsets of the shooting targets of the first N frames respectively; Obtain the maximum absolute value of the offset of the photographed target after normalization; Gain processing is performed on the offset after fixed gain processing according to the maximum value.
3. The video shooting control method according to claim 1, characterized in that: Determining the structural continuous gain according to the average value comprises: performing a minimum amplitude limiting process on the average value; and / or performing a nonlinear transformation process on the average value; and / or performing a filtering process on the average value; The processed result is used as the structural continuous gain.
4. The video shooting control method according to claim 1, characterized in that: The step of acquiring the first K frames of video images at intervals of preset frames comprises: The preset interval of the preset frames is preset as G frames; Acquire the previous G-th frame, the previous 2*G-th frame, ..., and the previous K*G-th frame of video images.
5. A video shooting control system, characterized in that: The video capture control system includes: A fixed gain module is used to obtain an offset between the current position of the shooting target in the video image and the target position, and to perform fixed gain processing on the offset using a fixed gain controller; A historical error gain module, used to determine a historical error gain according to the maximum absolute value of the offset of the target shot in the previous N frames, and use the historical error gain to perform gain processing on the offset after fixed gain processing; A structural continuous gain module is used to obtain the previous K frames of video images at intervals of preset frames, calculate the morphological structure similarity between two adjacent frames according to the current frame and the obtained previous K frames of video images, calculate the average value of all morphological structure similarities, determine the structural continuous gain according to the average value, and use the structural continuous gain to perform gain processing on the offset after the historical error gain processing; The adjustment module is used to adjust the external motion mechanism of the shooting device according to the offset after the structural continuous gain processing.
6. The video shooting control system according to claim 5, characterized in that: The historical error gain module is specifically used for: Normalize the offsets of the shooting targets of the first N frames respectively; Obtain the maximum absolute value of the offset of the photographed target after normalization; Gain processing is performed on the offset after fixed gain processing according to the maximum value.
7. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the video shooting control method as described in any one of claims 1-4 is implemented.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the video shooting control method as described in any one of claims 1 to 4 is implemented.
Citation Information
Patent Citations
Single lens image dynamic identification-based camera automatic tracking system and method
CN107452021A
Target tracking method based on moving head camera
CN111242984A
