Calibration method, device and equipment of pan-tilt rotation capability and medium

By using an automatic image calibration method to determine the gimbal rotation capability, the debugging difficulties caused by different gimbal structures were solved, and efficient and accurate gimbal control was achieved.

CN116681771BActive Publication Date: 2026-04-28ZHEJIANG UNIVIEW TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ZHEJIANG UNIVIEW TECH CO LTD
Filing Date
2022-10-08
Publication Date
2026-04-28

AI Technical Summary

Technical Problem

Different gimbal structures and motors result in varying rotation capabilities, leading to a large workload, low efficiency, and high labor costs in debugging. Furthermore, existing control protocols cannot meet the requirements for precise control and have poor applicability.

Method used

The gimbal's rotation capability is determined using an automatic image calibration method, including determining the rotation range or angular velocity capability, and the gimbal's rotation capability is determined using feature point position information.

Benefits of technology

It reduced the workload and labor costs of debugging, improved the efficiency and accuracy of PTZ control, and achieved precise control.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116681771B_ABST
    Figure CN116681771B_ABST
Patent Text Reader

Abstract

Embodiments of the application disclose a gimbal rotation capability calibration method, device, equipment and medium. The method comprises: determining a corresponding gimbal rotation control strategy according to the type of the rotation capability to be calibrated; wherein the type of the rotation capability to be calibrated comprises a rotation range or an angular velocity capability; controlling the gimbal rotation according to the gimbal rotation control strategy, and determining the position information of a feature point in an image to be calibrated in the rotation process; and determining the rotation capability to be calibrated of the gimbal based on the position change information of the feature point in the rotation process. The technical solution can quickly and accurately determine the gimbal rotation capability through automatic calibration of the image, reduces the debugging workload and labor cost, improves the efficiency and accuracy of gimbal control, and helps to realize accurate gimbal control.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of gimbal control technology, and in particular to a method, apparatus, device, and medium for calibrating the rotation capability of a gimbal. Background Technology

[0002] In security surveillance cameras, the integrated camera module is the core component of high-speed PTZ cameras or pan-tilt-zoom cameras. The integrated camera module mainly consists of a DSP (Digital Signal Processing) chip, a sensor, and a lens; it is the brain of the entire camera. Some pan-tilt-zoom camera manufacturers purchase the camera module, or the pan-tilt motor and dome housing, and then assemble them into high-speed PTZ cameras or pan-tilt-zoom cameras.

[0003] Automatic tracking, telephoto speed limiting, and motion capture functions in cameras are generally implemented by the camera module's DSP chip. In automatic tracking, the camera module precisely controls the gimbal's acceleration and deceleration frame-by-frame based on the target's motion trajectory to achieve rapid target tracking. In telephoto speed limiting, the camera module can control different angular velocities at different focal lengths. In motion capture, the camera module needs to obtain the precise time it takes for the gimbal to rotate from position A to position B. Therefore, the camera module needs to obtain the gimbal's rotation range, angular velocity, and angular acceleration, and then adjust the gimbal rotation control strategy based on the gimbal's rotation capabilities to improve gimbal control performance.

[0004] However, different gimbal structures and motors result in varying gimbal rotation capabilities. For example, changes in gimbal weight lead to changes in angular velocity and angular acceleration (due to gravity, the upward and downward angular accelerations differ). After a change in gimbal structure, the entire unit's rotation range, angular velocity, and angular acceleration all need to be remeasured, resulting in a large workload for debugging, low efficiency, high labor costs, and poor reusability.

[0005] Furthermore, the most widely used gimbal control protocol in the industry is the PELCO protocol. This protocol can only provide fuzzy speed control commands in tiered levels and lacks feedback, failing to meet the needs of precise gimbal control. Existing solutions typically employ proprietary protocols or modified PELCO protocols for precise gimbal control. However, in practical applications, it is necessary for the mechanism manufacturer and the gimbal manufacturer to adapt their protocols and achieve seamless integration. Specifically, the mechanism needs to match the gimbal's rotational capabilities, while the gimbal needs to match the mechanism's proprietary protocol and control strategy. However, different manufacturers use different proprietary protocols, making it difficult to require all manufacturers to develop according to the mechanism's defined proprietary protocol. Moreover, some manufacturers only adapt to the native PELCO protocol (standard PELCO protocol), leading to difficulties in interoperability and thus poor applicability. Summary of the Invention

[0006] This invention provides a method, apparatus, device, and medium for calibrating the rotation capability of a gimbal. It can quickly and accurately determine the rotation capability of the gimbal through automatic image calibration, reducing the workload and labor costs of debugging, improving the efficiency and quality of gimbal control, and helping to achieve precise gimbal control.

[0007] According to one aspect of the present invention, a method for calibrating the rotation capability of a gimbal is provided, the method comprising:

[0008] The corresponding gimbal rotation control strategy is determined based on the type of rotation capability to be calibrated; wherein, the type of rotation capability to be calibrated includes rotation range or angular velocity capability;

[0009] The gimbal rotation is controlled according to the gimbal rotation control strategy, and the position information of feature points in the image to be calibrated is determined during the rotation process.

[0010] The gimbal's rotation capability to be calibrated is determined based on the changes in the position of feature points during the rotation process.

[0011] According to another aspect of the present invention, a calibration device for gimbal rotation capability is provided, comprising:

[0012] The gimbal rotation control strategy determination module is used to determine the corresponding gimbal rotation control strategy based on the type of rotation capability to be calibrated; wherein, the type of rotation capability to be calibrated includes rotation range or angular velocity capability;

[0013] The feature point location information determination module is used to control the gimbal rotation according to the gimbal rotation control strategy and determine the feature point location information in the image to be calibrated during the rotation process.

[0014] The module for determining the rotation capability to be calibrated is used to determine the rotation capability to be calibrated of the gimbal based on the information on the change in the position of feature points during the rotation process.

[0015] According to another aspect of the present invention, a calibration electronic device for gimbal rotation capability is provided, the electronic device comprising:

[0016] At least one processor; and

[0017] A memory communicatively connected to the at least one processor; wherein,

[0018] The memory stores a computer program that can be executed by the at least one processor, which enables the at least one processor to perform the gimbal rotation capability calibration method according to any embodiment of the present invention.

[0019] According to another aspect of the present invention, a computer-readable storage medium is provided, the computer-readable storage medium storing computer instructions for causing a processor to execute and implement the gimbal rotation capability calibration method according to any embodiment of the present invention.

[0020] The technical solution of this invention determines the corresponding gimbal rotation control strategy based on the type of rotation capability to be calibrated. The type of rotation capability to be calibrated includes rotation range or angular velocity capability. The gimbal is controlled to rotate according to the gimbal rotation control strategy, and the position information of feature points in the image to be calibrated during the rotation process is determined. The gimbal's rotation capability to be calibrated is determined based on the changes in the position of these feature points during the rotation process. This technical solution can quickly and accurately determine the gimbal rotation capability through automatic image calibration, reducing debugging workload and labor costs, improving the efficiency and accuracy of gimbal control, and contributing to precise gimbal control.

[0021] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of the present invention, nor is it intended to limit the scope of the invention. Other features of the invention will become readily apparent from the following description. Attached Figure Description

[0022] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0023] Figure 1 This is a flowchart of a method for calibrating the rotation capability of a gimbal according to Embodiment 1 of the present invention;

[0024] Figure 2 This is a schematic diagram of a gimbal rotation control strategy based on angular velocity capability according to Embodiment 1 of the present invention;

[0025] Figure 3A This is a schematic diagram of feature point position selection for an image to be calibrated according to Embodiment 1 of the present invention;

[0026] Figure 3B This is a schematic diagram of the positional relationship of feature points in an image to be calibrated, provided in Embodiment 1 of the present invention.

[0027] Figure 4 This is a schematic diagram of the working mechanism image field of view provided according to Embodiment 1 of the present invention;

[0028] Figure 5This is a flowchart of a method for calibrating the rotation capability of a gimbal according to Embodiment 2 of the present invention;

[0029] Figure 6 This is a flowchart of a method for calibrating the rotation capability of a gimbal according to Embodiment 3 of the present invention;

[0030] Figure 7 This is a schematic diagram of the structure of a gimbal rotation capability calibration device provided in Embodiment 4 of the present invention;

[0031] Figure 8 This is a schematic diagram of the structure of an electronic device that implements a method for calibrating the rotation capability of a gimbal according to an embodiment of the present invention. Detailed Implementation

[0032] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.

[0033] It should be noted that the terms "first," "second," "target," etc., used in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0034] Example 1

[0035] Figure 1 This is a flowchart of a method for calibrating the rotation capability of a gimbal according to Embodiment 1 of the present invention. This embodiment is applicable to situations requiring rapid and accurate calibration of the gimbal's rotation capability. The method can be executed by a gimbal rotation capability calibration device, which can be implemented in hardware and / or software. This gimbal rotation capability calibration device can be configured in an electronic device with data processing capabilities. For example... Figure 1 As shown, the method includes:

[0036] S110, determine the corresponding gimbal rotation control strategy according to the type of rotation capability to be calibrated; wherein, the type of rotation capability to be calibrated includes rotation range or angular velocity capability.

[0037] The rotational capability to be calibrated refers to the gimbal rotational capability awaiting calibration. The type of rotational capability to be calibrated can include rotation range or angular velocity capability. Specifically, the rotation range can include horizontal rotation range and vertical rotation range. Angular velocity capability can include angular velocity and angular acceleration. Angular velocity can include horizontal angular velocity and vertical angular velocity; angular acceleration can include horizontal angular acceleration and vertical angular acceleration. The gimbal rotation control strategy refers to the control method used to control the gimbal rotation. For example, the gimbal rotation control strategy can include both horizontal and vertical rotation methods.

[0038] In this embodiment, before determining the corresponding gimbal rotation control strategy according to the type of rotation capability to be calibrated, the gimbal debugging environment can be prepared first. For example, the preparation process is as follows: (1) Select a complex outdoor environment for calibration and ensure sufficient lighting. (2) Adjust the frame rate of the camera mechanism to the highest and the encoding bit rate to the maximum to ensure the clarity of image acquisition. (3) Adjust the exposure mode of the camera mechanism to shutter priority mode and limit the shutter speed to a small shutter speed, such as 1 / 250 second or smaller. After adjusting the exposure parameters of the camera mechanism, each frame of image can be clearly presented when the gimbal rotates quickly. (4) Know the image resolution of the camera mechanism and the horizontal and vertical field of view of each focal length. (5) After the whole machine is installed horizontally, manually control the gimbal and adjust the monitoring field of view of the camera mechanism to be parallel to the horizontal plane.

[0039] After preparing the gimbal debugging environment, adjust the camera mechanism to the widest angle focal length and slowly rotate the gimbal horizontally to the left. During the gimbal rotation, the camera mechanism analyzes the image quality of each frame in real time. Based on whether the image continuously changes, it determines whether the horizontal direction supports continuous 360-degree rotation of the gimbal. For example, this can be determined by comparing the similarity between adjacent frames. If the similarity between two adjacent frames is greater than a preset similarity threshold (e.g., 99%), it can be considered that there are duplicate images, indicating that the horizontal direction does not support continuous 360-degree rotation of the gimbal. If no adjacent frames have a similarity greater than the preset similarity threshold, it can be considered that there are no duplicate images, indicating that the horizontal direction supports continuous 360-degree rotation of the gimbal.

[0040] When the monitoring field of view is large, the pan-tilt unit (PTZ) rotates at a slow speed. In this case, the difference between two adjacent frames may be very small, potentially leading to the misjudgment that the PTZ is stationary. To avoid this, the similarity between adjacent frames can be compared based on a preset frame interval to determine whether the PTZ supports continuous 360-degree rotation in the horizontal direction. The preset frame interval refers to a pre-defined interval between two adjacent frames. Specifically, during PTZ rotation, images are acquired at preset frame intervals (e.g., 10 frames), and the similarity between adjacent frames is compared. If the similarity between two adjacent frames at the preset frame interval is greater than a preset similarity threshold (e.g., 99%), it is considered that duplicate images exist, indicating that the PTZ does not support continuous 360-degree rotation in the horizontal direction. If no similarity between two adjacent frames at the preset frame interval exceeds the preset similarity threshold, it is considered that no duplicate images exist, indicating that the PTZ supports continuous 360-degree rotation in the horizontal direction.

[0041] In this embodiment, the corresponding gimbal rotation control strategy can be determined according to the type of rotation capability to be calibrated. For example, if the type of rotation capability to be calibrated is horizontal rotation range, and the gimbal can support continuous 360-degree horizontal rotation, then the gimbal rotation control strategy can be determined to control the gimbal to rotate continuously horizontally by 360 degrees. If the type of rotation capability to be calibrated is horizontal rotation range, but does not support continuous 360-degree horizontal rotation, then the gimbal rotation control strategy can be determined to control the gimbal to rotate from the leftmost to the rightmost position within the supported horizontal rotation range. If the type of rotation capability to be calibrated is angular velocity capability, then the gimbal rotation control strategy can be determined to control the gimbal to rotate horizontally in three stages: acceleration, constant speed, and deceleration.

[0042] Figure 2 This is a schematic diagram of a gimbal rotation control strategy based on angular velocity capability provided in Embodiment 1 of the present invention. Figure 2 As shown, the gimbal rotation control strategy based on angular velocity capability goes through three stages in sequence: acceleration, constant speed, and deceleration. The rectangles represent images acquired during the gimbal rotation process.

[0043] S120 controls the gimbal rotation according to the gimbal rotation control strategy and determines the feature point position information in the image to be calibrated during the rotation process.

[0044] The image to be calibrated can be an image acquired by a pan-tilt-zoom (PTZ) camera used for feature point calibration. A feature point can be a stationary landmark in the image to be calibrated that possesses distinct image recognition features. For example, a feature point could be a building (e.g., a house) with a distinct color characteristic. Feature point location information can be used to characterize the position of the feature point in the image to be calibrated.

[0045] In this embodiment, the gimbal is controlled to rotate according to a gimbal rotation control strategy, while simultaneously determining the feature point position information in the image to be calibrated during the rotation process. The feature point position in the image to be calibrated can be set according to the type of rotation capability being calibrated; this embodiment does not impose any limitations on this. For example, if the type of rotation capability to be calibrated is horizontal rotation range, the feature point position can be set at the center of the image, or it can be set on the horizontal central axis of the image, located on the left (e.g., left edge) or right (e.g., right edge) of the image. If the type of rotation capability to be calibrated is vertical rotation range, the feature point position can be set on the vertical central axis of the image, located on the upper (e.g., upper edge) or lower (e.g., lower edge) of the image. If the type of rotation capability to be calibrated is angular velocity capability, the feature point position can be set at the center of the image. The number of pixels contained in the feature point is also not limited; it can be a strip-shaped region containing all or part of the edge, or an irregular region containing an easily identifiable object.

[0046] In this embodiment, if the gimbal does not support continuous horizontal rotation of 360 degrees and the gimbal cannot rotate to the left at a certain position, then that position can be used as image scene 1; if the gimbal supports continuous horizontal rotation of 360 degrees, then a random position can be selected as image scene 1. Figure 3A This is a schematic diagram illustrating the selection of feature point positions in an image to be calibrated, as provided in Embodiment 1 of the present invention. Figure 3B This is a schematic diagram illustrating the positional relationship of feature points in an image to be calibrated, provided in Embodiment 1 of the present invention. For example, taking the horizontal rotation of a gimbal as an example... Figure 3A and Figure 3B As shown, in image scene 1, image feature point 0 and image feature point 1 are selected. Feature point 0 and feature point 1 are on the horizontal central axis of the image, with feature point 0 at the left edge of the image and feature point 1 at the right edge of the image.

[0047] The camera mechanism controls the gimbal to slowly rotate horizontally to the right until feature point 1 stops at the left edge of the image. This scene is designated as image scene 2. Feature point 2 is selected within image scene 2, where it lies on the horizontal central axis of the image and is located at the right edge. This process of selecting image scenes and feature points is repeated, selecting image scene N and feature point n, until further rightward rotation is impossible (360-degree horizontal rotation is not supported), or until feature point 0 reappears in the image (360-degree horizontal rotation is supported).

[0048] S130 determines the gimbal's rotation capability to be calibrated based on the changes in the position of feature points during the rotation process.

[0049] The feature point position change information can refer to the change information of the feature point position information. In this embodiment, after determining the feature point position information in the image to be calibrated during the rotation process, the feature point position change information during the rotation process can be determined based on the feature point position information at different sampling times, and then the gimbal's rotation capability to be calibrated can be determined based on the feature point position change information.

[0050] Based on the above example, after determining the image feature points, a horizontal coordinate system is established with the center point of image scene 1 as point O and rightward rotation as positive. The horizontal coordinates of image feature points 0, 1, 2…n are calculated based on the horizontal field of view of the mechanism and the pixel coordinates of the image feature points in the image. Then, based on the conversion relationship between pixel position and field of view, the horizontal rotation range can be determined according to the horizontal coordinates of the image feature points.

[0051] Figure 4 This is a schematic diagram of the field of view of a movement image provided in Embodiment 1 of the present invention. Figure 4 As shown, A and E are the outermost pixels of the movement image, and the angle between AOE is the horizontal field of view of the movement. When the horizontal motor rotates, the angle by which the image center point rotates from A to E is equal to the angle of the horizontal field of view. Assume the image resolution is L×W (i.e., L pixels horizontally and W pixels vertically), the horizontal field of view is T degrees, and point A is the 0th pixel from left to right, point B is the bth pixel from left to right, point C is the L / 2th pixel from left to right, point D is the dth pixel from left to right, and point E is the Lth pixel from left to right. Ignoring image distortion, the conversion relationship between pixel position and field of view can be expressed as: For example, if the horizontal angle difference between A and C is x AC The formula can be obtained as follows: If the horizontal angle difference between B and C is x BC The formula can be obtained as follows:

[0052] The technical solution of this invention determines the corresponding gimbal rotation control strategy based on the type of rotation capability to be calibrated. The type of rotation capability to be calibrated includes rotation range or angular velocity capability. The gimbal is controlled to rotate according to the gimbal rotation control strategy, and the position information of feature points in the image to be calibrated during the rotation process is determined. The gimbal's rotation capability to be calibrated is determined based on the changes in the position of these feature points during the rotation process. This technical solution can quickly and accurately determine the gimbal rotation capability through automatic image calibration, reducing debugging workload and labor costs, improving the efficiency and accuracy of gimbal control, and contributing to precise gimbal control.

[0053] Example 2

[0054] Figure 5This is a flowchart of a method for calibrating the rotation capability of a gimbal according to Embodiment 2 of the present invention. This embodiment is based on the above embodiment and optimized. Specifically, the optimization is as follows: the rotation range includes a horizontal rotation range, and the gimbal rotation control strategy corresponding to the horizontal rotation range is horizontal rotation; accordingly, the gimbal is controlled to rotate according to the gimbal rotation control strategy, and the feature point position information in the image to be calibrated during the rotation process is determined, including: determining the left feature point position information and the right feature point position information in the initial image to be calibrated at the initial position of the gimbal; controlling the gimbal to rotate horizontally to the right, and determining the image corresponding to the right feature point of the current image to be calibrated when it is rotated to the left edge area of ​​the screen as the next frame image to be calibrated, and determining the center point position information and the right feature point position information in the next frame image to be calibrated; continuing to control the gimbal to rotate until the image screen repeats, and determining the corresponding image as the final image to be calibrated; determining the horizontal rotation range of the gimbal based on the change information of the center point position information of the initial image to be calibrated and the final image to be calibrated.

[0055] like Figure 5 As shown, the method in this embodiment specifically includes the following steps:

[0056] S210, determine the corresponding gimbal rotation control strategy according to the type of rotation capability to be calibrated; wherein, the type of rotation capability to be calibrated includes horizontal rotation range; the gimbal rotation control strategy corresponding to the horizontal rotation range is horizontal rotation.

[0057] S220, determine the position information of the left and right feature points in the initial image to be calibrated at the initial position of the gimbal.

[0058] The initial position of the gimbal can be set according to the actual situation. For example, if 360-degree horizontal rotation of the gimbal is not supported, the initial position can be set to the leftmost position where the gimbal can rotate; if 360-degree horizontal rotation is supported, the initial position can be set to any position. The initial image to be calibrated can refer to the image acquired at the initial position of the gimbal, which can be understood as the first frame image waiting to be calibrated. The left feature point position information and the right feature point position information can be used to characterize the positions of feature points located on the left and right sides of the image, respectively.

[0059] In this embodiment, optionally, before determining the position information of the left and right feature points in the initial image to be calibrated at the initial position of the gimbal, the method further includes: determining the center point of the initial image to be calibrated as the reference origin; correspondingly, the steps for determining the position information of the left, right, and center points in the image to be calibrated are as follows: The position information of the left and right feature points in the initial image to be calibrated is determined according to the following formula:

[0060]

[0061] Where x0 is the position information of the left feature point in the initial image to be calibrated, x1 is the position information of the right feature point in the initial image to be calibrated, p1 is the pixel position of the left feature point in the initial image to be calibrated, q1 is the pixel position of the right feature point in the initial image to be calibrated, T is the current horizontal field of view, and L is the current horizontal resolution of the image.

[0062] like Figure 3B As shown, the center point of the initial image to be calibrated can be used as the horizontal origin (reference origin), and the rightward rotation can be taken as the positive direction to establish a horizontal coordinate system. Based on this horizontal coordinate system, the position information of the left and right feature points in the initial image to be calibrated can be determined. Assume the image resolution of the initial image to be calibrated is L×W (i.e., the current horizontal resolution is L pixels, and the current vertical resolution is W pixels), and the current horizontal field of view is T degrees. Assume that through image recognition, the pixel position of image feature point 0 (the left feature point in the initial image to be calibrated) is obtained as the p1th horizontal pixel from left to right, where 0 ≤ p1 < L / 2; and the pixel position of image feature point 1 (the right feature point in the initial image to be calibrated) is the q1th horizontal pixel from left to right, where L / 2 < q1 ≤ L.

[0063] Therefore, the horizontal coordinate of image feature point 0 (i.e., the position information of the left feature point in the initial image to be calibrated) can be obtained as follows: This value is negative. When continuous 360-degree horizontal rotation is supported, it can be converted to a positive value by adding 360 degrees. The horizontal coordinates of image feature point 1 (i.e., the position information of the right feature point in the initial image to be calibrated) are:

[0064] S230, control the gimbal to rotate horizontally to the right, and determine the image corresponding to the right feature point of the current image to be calibrated to the left edge area of ​​the screen as the next frame image to be calibrated, and determine the center point position information and right feature point position information in the next frame image to be calibrated.

[0065] Here, the current image to be calibrated can refer to the image currently awaiting calibration. The next frame image to be calibrated can refer to the frame following the current image. Specifically, the next frame image to be calibrated refers to the image corresponding to the right feature point of the current image to be calibrated when it rotates to the left edge region of the image. The specific size of the left edge region can be determined based on whether a new right feature point appears in the next frame image to be calibrated; however, in this embodiment of the invention, the specific range of the left edge region is not limited. The image center point position information can be used to describe the position of the image center point.

[0066] In this embodiment, after determining the position information of the left feature point and the right feature point in the initial image to be calibrated at the initial position of the gimbal, the gimbal is controlled to rotate horizontally to the right. The image corresponding to the right feature point of the current image to be calibrated when it is rotated to the left edge area of ​​the screen is determined as the next frame image to be calibrated, and then the position information of the center point and the right feature point in the next frame image to be calibrated are determined.

[0067] In this embodiment, optionally, the position information of the right feature point and the position information of the center point in the next frame of the image to be calibrated are determined according to the following formula:

[0068]

[0069] Where, x 中心点n x represents the center point location information in the nth frame of the image to be calibrated. n Here, pn represents the position of the right feature point in the nth frame of the image to be calibrated, pn represents the pixel position of the left feature point in the nth frame of the image to be calibrated, qn represents the pixel position of the right feature point in the nth frame of the image to be calibrated, and x represents the position of the right feature point in the nth frame of the image to be calibrated. n-1 This refers to the location information of the right feature point in the (n-1)th frame of the image to be calibrated.

[0070] like Figure 3B As shown, in image scene 2, the left feature point of the next frame to be calibrated is the right feature point of the initial image to be calibrated. Assume that through image recognition, the pixel position of image feature point 1 (the left feature point of the next frame to be calibrated) in the image is the p2th pixel horizontally from left to right, where 0 ≤ p2 < L / 2; the pixel position of image feature point 2 (the right feature point of the next frame to be calibrated) in the image is the q2th pixel horizontally from left to right, where L / 2 < q2 ≤ L. Given that the horizontal coordinate of image feature point 1 is x1, the horizontal coordinate of the center point of image scene 2 can be determined as x1. Meanwhile, the horizontal coordinate of image feature point 2 is By analogy, the horizontal coordinates of the center point of image scene N can be obtained as follows: The horizontal coordinate of image feature point n is

[0071] S240, continue to control the gimbal to rotate until the image repeats, and determine the corresponding image as the final image to be calibrated.

[0072] The final image to be calibrated can refer to the last frame of image awaiting calibration. Optionally, the pan-tilt unit can continue to rotate until the image repeats, and the corresponding image is determined as the final image to be calibrated. This includes: continuing to control the pan-tilt unit to rotate, determining the image change information of adjacent frames, and the image change information between the acquired image and the initial image to be calibrated; if the images of adjacent frames have not changed, the repeated image is determined as the final image to be calibrated; if the acquired image is the same as the initial image to be calibrated, the initial image to be calibrated is determined as the final image to be calibrated.

[0073] In this embodiment, the gimbal continues to rotate. The image change information of adjacent frames is determined based on the differences between the acquired images, and the image change information between the acquired image and the initial image to be calibrated is also determined. If the images of adjacent frames do not change, it indicates that the gimbal has rotated to a certain limit and cannot move further, meaning it does not support 360-degree horizontal rotation. In this case, the repeated image can be determined as the final image to be calibrated. If the acquired image is the same as the initial image to be calibrated, it indicates that the gimbal has returned to its initial position after horizontal rotation, meaning it supports 360-degree horizontal rotation. In this case, the initial image to be calibrated can be determined as the final image to be calibrated.

[0074] This solution, through such settings, can quickly and accurately determine the final image to be calibrated, which helps to improve the efficiency and accuracy of determining the horizontal rotation range of the gimbal.

[0075] S250 determines the horizontal rotation range of the gimbal based on the change in the center point position information of the initial and final images to be calibrated.

[0076] The center point position information can be used to characterize the center point position of the image. The center point position change information can be used to describe the changes in the image center point position. In this embodiment, if 360-degree horizontal rotation of the gimbal is supported, the horizontal rotation range of the gimbal can be determined to be 360 ​​degrees; if 360-degree horizontal rotation of the gimbal is not supported, assuming the initial center point position information of the image to be calibrated is 0, the final center point position information of the image to be calibrated is x. 中心点N At this point, the horizontal rotation range of the gimbal can be determined to be 0-x. 中心点N .

[0077] The technical solution of this invention involves determining the position information of the left and right feature points in the initial image to be calibrated at the initial position of the gimbal; controlling the gimbal to rotate horizontally to the right, and determining the image corresponding to the right feature point of the current image to be calibrated when it is rotated to the left edge of the screen as the next frame to be calibrated, and determining the position information of the center point and the right feature point in the next frame to be calibrated; continuing to control the gimbal to rotate until the image repeats, and determining the corresponding image as the final image to be calibrated; determining the horizontal rotation range of the gimbal based on the change in the center point position information of the initial and final images to be calibrated. This technical solution can quickly and accurately determine the horizontal rotation range of the gimbal based on the change in the center point position information of the initial and final images to be calibrated, reducing debugging workload and labor costs, improving the efficiency and accuracy of gimbal horizontal control, and helping to achieve precise horizontal control of the gimbal.

[0078] In this embodiment, optionally, before determining the position information of the left feature point and the position information of the right feature point in the initial image to be calibrated at the initial position of the gimbal, the method further includes: controlling the gimbal to rotate horizontally to the left until the image repeats, determining the corresponding position as the initial position of the gimbal, and the corresponding image as the initial image to be calibrated.

[0079] In this embodiment, before determining the position information of the left and right feature points in the initial image to be calibrated at the initial position of the gimbal, the gimbal is first controlled to rotate horizontally to the left until the image repeats. The position where the image repeats is determined as the initial position of the gimbal, and the repeated image at the initial position of the gimbal is determined as the initial image to be calibrated.

[0080] This solution allows for the rapid determination of the initial position of the gimbal and the initial image to be calibrated, enabling the subsequent rapid determination of the gimbal's horizontal rotation range based on the initial image.

[0081] In this embodiment, optionally, the type of rotation capability to be calibrated includes vertical rotation range, and the gimbal rotation control strategy corresponding to the vertical rotation range is vertical rotation. Accordingly, the gimbal is controlled to rotate according to the gimbal rotation control strategy, and the feature point position information in the image to be calibrated during the rotation process is determined, including: determining the upper feature point position information and lower feature point position information in the initial image to be calibrated at the initial position of the gimbal; controlling the gimbal to rotate vertically downwards, and determining the image corresponding to the lower feature point in the image frame when it is rotated to the upper side of the image frame as the next frame to be calibrated, and determining the center point position information and lower feature point position information in the next frame to be calibrated; continuing to control the gimbal to rotate until the image frame is repeated, and determining the corresponding next frame to be calibrated as the final image to be calibrated; determining the vertical rotation range of the gimbal based on the change information of the center point position information of the initial image to be calibrated and the final image to be calibrated.

[0082] In this embodiment, the vertical rotation range of the gimbal can be obtained by referring to the process for determining the horizontal rotation range described above, so as to calibrate the vertical rotation capability of the gimbal. The implementation method of the vertical rotation range is similar to that of the horizontal rotation range, and will not be repeated here.

[0083] This solution, through this configuration, can quickly and accurately determine the vertical rotation range of the gimbal based on the changes in the center point position information of the initial and final images to be calibrated. This reduces the workload and labor costs of debugging, improves the efficiency and accuracy of vertical control of the gimbal, and helps to achieve precise control of the gimbal in the vertical direction.

[0084] Example 3

[0085] Figure 6 This is a flowchart of a method for calibrating the rotation capability of a gimbal according to Embodiment 3 of the present invention. This embodiment is an optimization based on the above embodiment. The specific optimization is as follows: Angular velocity capability includes horizontal angular velocity and horizontal angular acceleration corresponding to preset speed levels; the gimbal rotation control strategy corresponding to the angular velocity capability is to control the gimbal from rest to uniform rotation based on the preset speed level, and then from uniform rotation back to rest; correspondingly, the gimbal rotation is controlled according to the gimbal rotation control strategy, and the feature point position information in the image to be calibrated during the rotation process is determined, including: determining the left and right feature point position information in the initial image to be calibrated at the initial position of the gimbal; the gimbal is controlled to rotate horizontally to the right based on the preset speed level, and the image corresponding to the right feature point of the current image to be calibrated when it is rotated to the left edge area of ​​the screen is determined as the next frame to be calibrated, and the center point position information and right feature point position information in the next frame to be calibrated are determined; the gimbal rotation is controlled based on the preset speed level until the center point position difference of the preset number of adjacent frames to be calibrated is the same, the gimbal is determined to enter the uniform rotation stage, and the center point position difference is determined as the target center point position difference; finally, the gimbal is controlled to stop rotating based on the gimbal rotation control strategy.

[0086] like Figure 6 As shown, the method in this embodiment specifically includes the following steps:

[0087] S310, determine the corresponding gimbal rotation control strategy according to the type of rotation capability to be calibrated; wherein, the type of rotation capability to be calibrated includes angular velocity capability; angular velocity capability includes horizontal angular velocity and horizontal angular acceleration corresponding to a preset speed level; the gimbal rotation control strategy corresponding to the angular velocity capability is to control the gimbal from stationary to uniform rotation based on the preset speed level, and then from uniform rotation back to stationary.

[0088] Here, the preset speed level refers to a pre-defined speed level. For example, based on the PELCO control protocol, fuzzy speeds of 0x00-0x3F levels can be preset, and the gimbal can be controlled to rotate left, right, up, and down using control commands corresponding to different preset speed levels. In this embodiment, the type of rotation capability to be calibrated includes angular velocity capability. The gimbal rotation control strategy corresponding to angular velocity capability is to control the gimbal from rest to uniform rotation based on the preset speed level, and then from uniform rotation back to rest, such as... Figure 2 As shown. The angular velocity capability includes the horizontal angular velocity and horizontal angular acceleration corresponding to the preset speed level.

[0089] S320, determine the position information of the left and right feature points in the initial image to be calibrated at the initial position of the gimbal.

[0090] S330 controls the gimbal to rotate horizontally to the right based on a preset speed level. When the right feature point of the current image to be calibrated is rotated to the left edge of the screen, the corresponding image is determined as the next frame to be calibrated. The center point position information and the right feature point position information in the next frame to be calibrated are also determined.

[0091] In this embodiment, the mechanism controls the gimbal to return to image scene 1 and controls the gimbal to continuously rotate to the right at the minimum speed level. During the gimbal rotation, the mechanism analyzes the image effect of each frame in real time. Referring to the implementation process of S230 in Embodiment 2 above, the next frame to be calibrated is determined, as well as the center point position information and right feature point position information in the next frame to be calibrated. For example, in the M-th frame image, if feature point m is determined to exist through image recognition, and the pixel position of feature point m in the image is the z-th pixel horizontally from left to right, then the horizontal coordinate of the center point of the M-th frame image is...

[0092] S340, continue to control the gimbal to rotate based on the preset speed level until the center point position difference of the preset number of adjacent frames to be calibrated images is the same, determine that the gimbal has entered the uniform speed rotation stage, and determine the center point position difference as the target center point position difference.

[0093] The center point position difference can be used to characterize the difference between the center point positions of adjacent frames of the image to be calibrated. The target center point position difference can refer to the center point position difference corresponding to the gimbal's uniform rotation phase. In this embodiment, after obtaining the center point position of each frame of the image to be calibrated, the center point position difference between adjacent frames of the image to be calibrated, i.e., ΔX, is calculated. M =X 中心点M -X 中心点M-1 When the center point position difference ΔX occurs in two or more consecutive frames. MWhen the values ​​are equal, it can be determined that the gimbal has completed acceleration and entered the uniform rotation stage. At this time, the difference in the center point position can be determined as the difference in the target center point position.

[0094] S350, finally, controls the gimbal to stop rotating based on the gimbal rotation control strategy.

[0095] In this embodiment, after the gimbal rotates at a constant speed for a period of time, the mechanism controls the gimbal to stop rotating based on the gimbal rotation control strategy. It should be noted that for gimbals that do not support continuous 360-degree horizontal rotation, during the gimbal control process, it is necessary to avoid the gimbal moving to the far right and hitting the wall, otherwise it will affect the calculation of angular velocity or angular acceleration.

[0096] S360 determines the gimbal's rotation capability to be calibrated based on the changes in the position of feature points during the rotation process.

[0097] In this embodiment, after determining the feature point position change information during the rotation process, the angular velocity capability of the gimbal can be determined based on this feature point position change information. Optionally, determining the gimbal's rotation capability to be calibrated based on the feature point position change information during the rotation process includes: determining the first number of image acquisition frames during the process of the gimbal rotating horizontally to the right based on a preset speed level, and the second number of image acquisition frames during the process of the gimbal rotating horizontally to the right from the uniform speed stage to the standstill; determining the horizontal angular velocity based on the target center point position difference and a preset image acquisition frame rate; determining the horizontal angular acceleration during the acceleration process based on the horizontal angular velocity and the first number of image acquisition frames; and determining the horizontal angular acceleration during the deceleration process based on the horizontal angular velocity and the second number of image acquisition frames.

[0098] The first image acquisition frame count can refer to the number of image frames acquired during the process of the gimbal transitioning from a stationary state to a state of constant rotation. The second image acquisition frame count can refer to the number of image frames acquired during the process of the gimbal transitioning from a state of constant rotation to a stationary state. The preset image acquisition frame rate can refer to a pre-set image acquisition speed. It can be understood that a higher preset image acquisition frame rate indicates a faster image acquisition speed, resulting in more image frames acquired within the same time frame.

[0099] In this embodiment, the horizontal angular velocity and horizontal angular acceleration can be determined based on the target center point position difference and the preset image acquisition frame rate. For example, assume the target center point position difference is ΔX. M If the preset image acquisition frame rate is v, then the horizontal angular velocity can be determined as ω = ΔX. M×v. Furthermore, based on the preset image acquisition frame rate, the acquisition time for each image frame can be determined as s = 1 / v. Further, the horizontal angular acceleration during acceleration can be determined based on the horizontal angular velocity and the number of the first image acquisition frames, and the horizontal angular acceleration during deceleration can be determined based on the horizontal angular velocity and the number of the second image acquisition frames. For example, assuming the number of the first and second image acquisition frames are m1 and m2 respectively, the horizontal angular acceleration during acceleration can be expressed as... The horizontal angular acceleration during deceleration can be expressed as:

[0100] The gimbal is controlled by the mechanism to return to image scene 1, and the preset speed level is increased in minimum increments. Based on the updated preset speed level, the gimbal is controlled to continuously rotate to the right. This process of determining angular velocity and angular acceleration is repeated until all preset speed levels are calibrated. Thus, the correspondence between the preset speed levels and the actual angular velocity capability of the gimbal can be determined, as exemplified in the table below:

[0101] Table 1. Correspondence between preset speed levels and actual angular velocity capabilities of the gimbal.

[0102] Preset speed level 0x01 0x02 0x03 … 0x63 Actual horizontal angular velocity a1 a2 a3 … a99 Actual horizontal angular acceleration (positive) b1 b2 b3 … b99 Actual horizontal angular acceleration (negative) -c1 -c2 -c3 … -c99

[0103] This solution, through such settings, can quickly and accurately determine the horizontal angular velocity, the horizontal angular acceleration during acceleration, and the horizontal angular acceleration during deceleration, thereby achieving precise calibration of the gimbal's angular velocity capability.

[0104] The technical solution of this invention determines the position information of the left and right feature points in the initial image to be calibrated at the initial position of the gimbal; controls the gimbal to rotate horizontally to the right based on a preset speed level, and determines the image corresponding to the right feature point of the current image to be calibrated when it rotates to the left edge of the screen as the next frame to be calibrated, and determines the position information of the center point and the right feature point in the next frame to be calibrated; continues to control the gimbal to rotate based on the preset speed level until the center point position difference of a preset number of adjacent frames to be calibrated is the same, determines that the gimbal has entered a uniform rotation stage, and determines the center point position difference as the target center point position difference; finally, controls the gimbal to stop rotating based on the gimbal rotation control strategy. This technical solution can quickly and accurately determine the horizontal angular velocity capability of the gimbal based on the target center point position difference of adjacent frames to be calibrated, reducing the debugging workload and labor costs, improving the efficiency and accuracy of gimbal horizontal control, and helping to achieve precise control of the horizontal angular velocity capability of the gimbal.

[0105] In this embodiment, optionally, the angular velocity capability includes the vertical angular velocity and vertical angular acceleration corresponding to a preset speed level; the gimbal rotation control strategy corresponding to the angular velocity capability is to control the gimbal from rest to uniform rotation based on the preset speed level, and then from uniform rotation back to rest; correspondingly, the gimbal rotation is controlled according to the gimbal rotation control strategy, and the feature point position information in the image to be calibrated during the rotation process is determined, including: determining the upper feature point position information and lower feature point position information in the initial image to be calibrated at the initial position of the gimbal; controlling the gimbal to rotate horizontally downward based on the preset speed level, determining the image corresponding to the lower feature point in the image when it rotates to the upper side of the image as the next frame to be calibrated, and determining the center point position information and lower feature point position information in the next frame to be calibrated; continuing to control the gimbal to rotate based on the preset speed level until the center point position difference of a preset number of adjacent frames to be calibrated is the same, determining that the gimbal has entered the uniform rotation stage; finally, controlling the gimbal to stop rotating back to rest based on the gimbal rotation control strategy.

[0106] In this embodiment, the horizontal angular velocity capability of the gimbal can be obtained by referring to the above-described process for determining the horizontal angular velocity capability, namely, the vertical angular velocity, the vertical angular acceleration during acceleration, and the vertical angular acceleration during deceleration, so as to calibrate the gimbal's angular velocity capability in the vertical direction. The implementation method for the vertical angular velocity capability is similar to that for the horizontal angular velocity capability, and will not be repeated here. It should be noted that due to the influence of gravity, the vertical upward and vertical downward angular accelerations are different, therefore they need to be calibrated separately.

[0107] This solution, through this configuration, can quickly and accurately determine the vertical angular velocity capability of the gimbal based on the position difference of the target center point in adjacent frames of the image to be calibrated. This reduces the workload and labor costs of debugging, improves the efficiency and accuracy of the gimbal's vertical control, and helps to achieve precise control of the gimbal's vertical angular velocity capability.

[0108] Example 4

[0109] Figure 7 This is a schematic diagram of a gimbal rotation capability calibration device provided in Embodiment 4 of the present invention. This device can execute the gimbal rotation capability calibration method provided in any embodiment of the present invention, and possesses the corresponding functional modules and beneficial effects of the method. For example... Figure 7 As shown, the device includes:

[0110] The gimbal rotation control strategy determination module 410 is used to determine the corresponding gimbal rotation control strategy according to the type of rotation capability to be calibrated; wherein, the type of rotation capability to be calibrated includes rotation range or angular velocity capability;

[0111] The feature point location information determination module 420 is used to control the gimbal rotation according to the gimbal rotation control strategy and determine the feature point location information in the image to be calibrated during the rotation process.

[0112] The module 430 for determining the rotation capability to be calibrated is used to determine the rotation capability to be calibrated of the gimbal based on the information on the change in the position of feature points during the rotation process.

[0113] Optionally, the rotation range includes a horizontal rotation range, and the gimbal rotation control strategy corresponding to the horizontal rotation range is horizontal rotation;

[0114] Accordingly, the feature point location information determination module 420 includes:

[0115] The initial feature point location information determination unit is used to determine the left and right feature point location information in the initial image to be calibrated at the initial position of the gimbal.

[0116] The next frame feature point position information determination unit is used to control the gimbal to rotate horizontally to the right, determine the image corresponding to the right feature point of the current image to be calibrated when it is rotated to the left edge area of ​​the screen as the next frame image to be calibrated, and determine the center point position information and right feature point position information in the next frame image to be calibrated.

[0117] The final image to be calibrated determination unit is used to continue controlling the gimbal to rotate until the image is repeated, and to determine the corresponding image as the final image to be calibrated;

[0118] The gimbal horizontal rotation range determination unit is used to determine the horizontal rotation range of the gimbal based on the change information of the center point position information of the initial image to be calibrated and the final image to be calibrated.

[0119] Optionally, the final image to be calibrated determination unit is specifically used for:

[0120] Continue to control the pan-tilt unit to rotate, determine the image change information of adjacent frames, and the image change information between the acquired image and the initial image to be calibrated;

[0121] If the images of adjacent frames do not change, then the repeated image is determined to be the final image to be calibrated;

[0122] If the acquired image is the same as the initial image to be calibrated, then the initial image to be calibrated is determined to be the final image to be calibrated.

[0123] Optionally, the angular velocity capability includes the horizontal angular velocity and horizontal angular acceleration corresponding to the preset speed level; the gimbal rotation control strategy corresponding to the angular velocity capability is to control the gimbal from stationary to uniform rotation based on the preset speed level, and then from uniform rotation back to stationary.

[0124] Accordingly, the feature point location information determination module 420 is used for:

[0125] Determine the position information of the left and right feature points in the initial image to be calibrated at the initial position of the gimbal;

[0126] Based on a preset speed level, the gimbal is controlled to rotate horizontally to the right. When the right feature point of the current image to be calibrated is rotated to the left edge of the screen, the corresponding image is determined as the next frame image to be calibrated. The center point position information and the right feature point position information in the next frame image to be calibrated are also determined.

[0127] Continue to control the gimbal to rotate based on the preset speed level until the center point position difference of the preset number of adjacent frames of images to be calibrated is the same. Determine that the gimbal has entered the uniform speed rotation stage, and determine that the center point position difference is the target center point position difference.

[0128] Finally, the gimbal rotation control strategy was used to stop the gimbal rotation.

[0129] Optionally, the rotational capability determination module 430 to be calibrated is used for:

[0130] Determine the number of first image acquisition frames during the process of the gimbal rotating horizontally to the right based on a preset speed level, and the number of second image acquisition frames during the process of the gimbal rotating horizontally to the right.

[0131] The horizontal angular velocity is determined based on the position difference of the target center point and the preset image acquisition frame rate;

[0132] The horizontal angular acceleration during the acceleration process is determined based on the horizontal angular velocity and the number of frames acquired in the first image acquisition.

[0133] The horizontal angular acceleration during deceleration is determined based on the horizontal angular velocity and the number of frames acquired in the second image acquisition process.

[0134] Optionally, the feature point location information determination module 420 further includes:

[0135] The reference origin determination unit is used to determine the center point of the initial image to be calibrated as the reference origin before determining the position information of the left feature point and the position information of the right feature point in the initial image to be calibrated at the initial position of the gimbal.

[0136] Accordingly, the steps for determining the position information of the left feature point, the right feature point, and the center point in the image to be calibrated are as follows:

[0137] The position information of the left and right feature points in the initial image to be calibrated is determined according to the following formula:

[0138]

[0139] Where x0 is the position information of the left feature point in the initial image to be calibrated, x1 is the position information of the right feature point in the initial image to be calibrated, p1 is the pixel position of the left feature point in the initial image to be calibrated, q1 is the pixel position of the right feature point in the initial image to be calibrated, T is the current horizontal field of view, and L is the current horizontal resolution of the image.

[0140] The position information of the right feature point and the center point in the next frame of the image to be calibrated are determined according to the following formula:

[0141]

[0142] Where, x 中心点n x represents the center point location information in the nth frame of the image to be calibrated. n Here, pn represents the position of the right feature point in the nth frame of the image to be calibrated, pn represents the pixel position of the left feature point in the nth frame of the image to be calibrated, qn represents the pixel position of the right feature point in the nth frame of the image to be calibrated, and x represents the position of the right feature point in the nth frame of the image to be calibrated. n-1 This refers to the location information of the right feature point in the (n-1)th frame of the image to be calibrated.

[0143] Optionally, the feature point location information determination module 420 further includes:

[0144] The gimbal initial position determination unit is used to control the gimbal to rotate horizontally to the left until the image repeats before determining the position information of the left feature point and the right feature point in the initial image to be calibrated at the initial position of the gimbal. The corresponding position is then determined as the initial position of the gimbal and the corresponding image is the initial image to be calibrated.

[0145] The gimbal rotation capability calibration device provided in this embodiment of the invention can execute the gimbal rotation capability calibration method provided in any embodiment of the invention, and has the corresponding functional modules and beneficial effects of the method.

[0146] Example 5

[0147] Figure 8A schematic diagram of an electronic device 10 that can be used to implement embodiments of the present invention is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices (e.g., helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the invention described and / or claimed herein.

[0148] like Figure 8 As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12 or a random access memory (RAM) 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the ROM 12 or loaded from storage unit 18 into the RAM 13. The RAM 13 may also store various programs and data required for the operation of the electronic device 10. The processor 11, ROM 12, and RAM 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.

[0149] Multiple components in electronic device 10 are connected to I / O interface 15, including: input unit 16, such as keyboard, mouse, etc.; output unit 17, such as various types of displays, speakers, etc.; storage unit 18, such as disk, optical disk, etc.; and communication unit 19, such as network card, modem, wireless transceiver, etc. Communication unit 19 allows electronic device 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0150] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as the calibration method for gimbal rotation capability.

[0151] In some embodiments, the gimbal rotation capability calibration method may be implemented as a computer program tangibly contained in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed on electronic device 10 via ROM 12 and / or communication unit 19. When the computer program is loaded into RAM 13 and executed by processor 11, one or more steps of the gimbal rotation capability calibration method described above may be performed. Alternatively, in other embodiments, processor 11 may be configured to perform the gimbal rotation capability calibration method by any other suitable means (e.g., by means of firmware).

[0152] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.

[0153] Computer programs used to implement the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be performed. The computer programs may be executed entirely on a machine, partially on a machine, or as a standalone software package, partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0154] In the context of this invention, a computer-readable storage medium can be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus, or device. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination thereof. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.

[0155] To provide interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the electronic device. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).

[0156] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or computing systems that include middleware components (e.g., application servers), or computing systems that include frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.

[0157] A computing system can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and VPS services, such as high management difficulty and weak business scalability.

[0158] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this invention can be achieved, and no limitation is imposed herein.

[0159] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this invention should be included within the scope of protection of this invention.

Claims

1. A method for calibrating the rotation capability of a gimbal, characterized in that, include: The corresponding gimbal rotation control strategy is determined based on the type of rotation capability to be calibrated; wherein, the type of rotation capability to be calibrated includes rotation range or angular velocity capability; the angular velocity capability includes the horizontal angular velocity and horizontal angular acceleration corresponding to a preset speed level; The gimbal rotation is controlled according to the gimbal rotation control strategy, and the position information of feature points in the image to be calibrated is determined during the rotation process. The gimbal's rotation capability to be calibrated is determined based on the changes in the position of feature points during the rotation process. The rotation range includes a horizontal rotation range, and the gimbal rotation control strategy corresponding to the horizontal rotation range is horizontal rotation. Accordingly, the gimbal is rotated according to the aforementioned gimbal rotation control strategy, and the position information of feature points in the image to be calibrated during the rotation process is determined, including: Determine the position information of the left and right feature points in the initial image to be calibrated at the initial position of the gimbal; Control the gimbal to rotate horizontally to the right, and when the right feature point of the current image to be calibrated is rotated to the left edge area of ​​the screen, the image corresponding to this is determined as the next frame image to be calibrated, and the center point position information and right feature point position information in the next frame image to be calibrated are determined. Continue to control the gimbal to rotate until the image repeats, and determine the corresponding image as the final image to be calibrated; The horizontal rotation range of the gimbal is determined based on the change in the center point position information of the initial image to be calibrated and the final image to be calibrated.

2. The method according to claim 1, characterized in that, Continue controlling the gimbal to rotate until the image repeats, and determine the corresponding image as the final image to be calibrated, including: Continue to control the pan-tilt unit to rotate, determine the image change information of adjacent frames, and the image change information between the acquired image and the initial image to be calibrated; If the images of adjacent frames do not change, then the repeated image is determined to be the final image to be calibrated; If the acquired image is the same as the initial image to be calibrated, then the initial image to be calibrated is determined to be the final image to be calibrated.

3. The method according to claim 1, characterized in that, The gimbal rotation control strategy corresponding to the angular velocity capability is to control the gimbal from stationary to uniform rotation based on a preset speed level, and then from uniform rotation back to stationary. Accordingly, the gimbal is rotated according to the aforementioned gimbal rotation control strategy, and the position information of feature points in the image to be calibrated during the rotation process is determined, including: Determine the position information of the left and right feature points in the initial image to be calibrated at the initial position of the gimbal; Based on a preset speed level, the gimbal is controlled to rotate horizontally to the right. When the right feature point of the current image to be calibrated is rotated to the left edge of the screen, the corresponding image is determined as the next frame image to be calibrated. The center point position information and the right feature point position information in the next frame image to be calibrated are also determined. Continue to control the gimbal to rotate based on the preset speed level until the center point position difference of the preset number of adjacent frames of images to be calibrated is the same. Determine that the gimbal has entered the uniform speed rotation stage, and determine that the center point position difference is the target center point position difference. Finally, the gimbal rotation control strategy was used to stop the gimbal rotation.

4. The method according to claim 3, characterized in that, The gimbal's rotation capability to be calibrated is determined based on the changes in the position of feature points during the rotation process, including: Determine the number of first image acquisition frames during the process of the gimbal rotating horizontally to the right based on a preset speed level, and the number of second image acquisition frames during the process of the gimbal rotating horizontally to the right. The horizontal angular velocity is determined based on the position difference of the target center point and the preset image acquisition frame rate; The horizontal angular acceleration during the acceleration process is determined based on the horizontal angular velocity and the number of frames acquired in the first image acquisition. The horizontal angular acceleration during deceleration is determined based on the horizontal angular velocity and the number of frames acquired in the second image acquisition process.

5. The method according to claim 1 or 3, characterized in that, Before determining the position information of the left and right feature points in the initial image to be calibrated at the initial position of the gimbal, the method further includes: The center point of the initial image to be calibrated is determined as the reference origin; Accordingly, the steps for determining the position information of the left feature point, the right feature point, and the center point in the image to be calibrated are as follows: The position information of the left and right feature points in the initial image to be calibrated is determined according to the following formula: ; ; in, The left feature point position information in the initial image to be calibrated. The location information of the right feature point in the initial image to be calibrated. This represents the pixel position of the left feature point in the initial image to be calibrated. This represents the pixel position of the right feature point in the initial image to be calibrated. The current horizontal field of view. The current horizontal resolution of the image; The position information of the right feature point and the position information of the center point in the next frame of the image to be calibrated are determined according to the following formula: ; ; in, This provides the center point location information for the nth frame of the image to be calibrated. This provides the location information of the right feature point in the nth frame of the image to be calibrated. Let be the pixel position of the left feature point in the nth frame of the image to be calibrated. Let be the pixel position of the right feature point in the nth frame of the image to be calibrated. For the first The location information of the right feature point in the frame to be calibrated.

6. The method according to claim 1 or 3, characterized in that, Before determining the position information of the left and right feature points in the initial image to be calibrated at the initial position of the gimbal, the following steps are also included: Control the gimbal to rotate horizontally to the left until the image repeats, determine the corresponding position as the initial position of the gimbal, and the corresponding image as the initial image to be calibrated.

7. A calibration device for the rotation capability of a gimbal, characterized in that, The device includes: The gimbal rotation control strategy determination module is used to determine the corresponding gimbal rotation control strategy based on the type of rotation capability to be calibrated; wherein, the type of rotation capability to be calibrated includes rotation range or angular velocity capability; the angular velocity capability includes horizontal angular velocity and horizontal angular acceleration corresponding to a preset speed level; The feature point location information determination module is used to control the gimbal rotation according to the gimbal rotation control strategy and determine the feature point location information in the image to be calibrated during the rotation process. The module for determining the rotation capability to be calibrated is used to determine the rotation capability to be calibrated of the gimbal based on the information on the change in the position of feature points during the rotation process. The rotation range includes a horizontal rotation range, and the gimbal rotation control strategy corresponding to the horizontal rotation range is horizontal rotation. Accordingly, the feature point location information determination module includes: The initial feature point location information determination unit is used to determine the left and right feature point location information in the initial image to be calibrated at the initial position of the gimbal. The next frame feature point position information determination unit is used to control the gimbal to rotate horizontally to the right, determine the image corresponding to the right feature point of the current image to be calibrated when it is rotated to the left edge area of ​​the screen as the next frame image to be calibrated, and determine the center point position information and right feature point position information in the next frame image to be calibrated. The final image to be calibrated determination unit is used to continue controlling the gimbal to rotate until the image is repeated, and to determine the corresponding image as the final image to be calibrated; The gimbal horizontal rotation range determination unit is used to determine the horizontal rotation range of the gimbal based on the change information of the center point position information of the initial image to be calibrated and the final image to be calibrated.

8. An electronic device for calibrating the rotation capability of a gimbal, characterized in that, The electronic device includes: At least one processor; and A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the calibration method for the gimbal rotation capability according to any one of claims 1-6.

9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that, when executed by a processor, implement the calibration method for the gimbal rotation capability according to any one of claims 1-6.

Citation Information

Patent Citations

  • Holder fault detection method and device, computer equipment and storage medium

    CN111381579A

  • Pan-tilt target tracking control method and device, pan-tilt control equipment and storage medium

    CN113160317A