Pan-tilt automatic focusing method combining 3DGS map and target object model

By combining 3DGS maps and target object models, real-time acquisition and matching of environmental point cloud data are performed to calculate the real-time coordinates and attitude of the gimbal. This solves the accuracy and efficiency problems of traditional gimbal autofocus methods in complex environments, achieving efficient and accurate autofocus.

CN121888093APending Publication Date: 2026-04-17GUANGZHOU UNIPOWER COMP
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
GUANGZHOU UNIPOWER COMP
Filing Date
2026-02-12
Publication Date
2026-04-17

AI Technical Summary

Technical Problem

Traditional gimbal autofocus methods have low focusing accuracy and efficiency in complex environments and cannot accurately obtain the relative position and attitude relationship between the target object and the gimbal.

Method used

By combining 3DGS maps and target object models, a 3DGS map of the target area is constructed, a target object model is created, and the initial position coordinates of the carrier are given. Environmental point cloud data is collected in real time and feature matching is performed to calculate the real-time coordinates and attitude of the gimbal and achieve automatic focusing.

Benefits of technology

Maintain high-precision focusing in complex environments, respond quickly to environmental changes, improve focusing efficiency and accuracy, and ensure clear image acquisition of the target object.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121888093A_ABST
    Figure CN121888093A_ABST
Patent Text Reader

Abstract

The invention discloses an automatic pan-tilt focusing method combining a 3DGS map and a target object model, through a target area 3DGS map constructed based on a 3DGS technology, three-dimensional space information such as terrains and buildings can be accurately presented, in a complex environment, a stable and accurate reference basis is provided for automatic pan-tilt focusing, the method is not influenced by real-time environment change, and the automatic pan-tilt focusing method is suitable for automatic pan-tilt focusing. High precision can be kept, and reduction of focusing precision due to environmental interference is avoided; meanwhile, environment point cloud data collected in real time are matched with 3DGS map features, coordinates and postures of a holder in a radar coordinate system can be obtained in real time, dynamic changes of the environment are considered, positioning and focusing parameters can be rapidly adjusted, and the focusing efficiency is improved; besides, a target object model is created in the 3DGS map, the initial position coordinates of the carrier are given, the relative position and attitude relation between the target object and the holder can be accurately calculated in combination with the real-time information of the holder, the three-dimensional space information of the target object is effectively utilized, and the focusing accuracy is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of gimbal autofocus technology, and in particular to a gimbal autofocus method that combines a 3DGS map and a target object model. Background Technology

[0002] In many fields such as photogrammetry, security monitoring, and drone inspection, gimbal autofocus technology is crucial for accurately acquiring clear images of target objects. With the continuous development of technology, how to achieve efficient and accurate gimbal autofocus has become a hot and difficult research issue in related fields.

[0003] Traditional gimbal autofocus methods often rely on single sensor data or simple positioning techniques. For example, some methods rely solely on the focusing algorithm of optical sensors, adjusting the gimbal's focal length by detecting image sharpness indicators such as contrast and sharpness. This method can be effective when the target object's position is relatively fixed and the environment changes little. However, in complex environments, such as when the target object moves or when there are obstructions or interference in the surrounding environment, the focusing accuracy and efficiency will drop significantly.

[0004] Other methods combine positioning technologies such as the Global Positioning System (GPS). These traditional methods often lack effective use of the three-dimensional spatial information of the target object and cannot accurately obtain the relative position and attitude relationship between the target object and the gimbal, thus limiting the accuracy of focusing. Summary of the Invention

[0005] In view of this, the present invention proposes a gimbal autofocus method that combines 3DGS maps and target object models, which can effectively solve the defects of existing technologies, such as a significant decrease in focusing accuracy and efficiency in complex environments, and the inability to accurately obtain the relative position and attitude relationship between the target object and the gimbal.

[0006] The technical solution of this invention is implemented as follows:

[0007] A gimbal autofocus method combining 3DGS maps and target object models, specifically including:

[0008] Constructing a 3DGS map of the target area based on 3DGS technology;

[0009] Create a model of the target object in the constructed 3DGS map, and give the initial position coordinates of the carrier;

[0010] Real-time acquisition of environmental point cloud data around the carrier;

[0011] Based on the initial position coordinates of the carrier, feature matching is performed between the real-time environmental point cloud data around the carrier and the 3DGS map to obtain the real-time coordinates and attitude of the gimbal in the radar coordinate system.

[0012] Based on the real-time coordinates and attitude of the gimbal in the radar coordinate system, the target object is located and an automatic focusing operation is performed.

[0013] As a further optional embodiment of the gimbal autofocus method combining a 3DGS map and a target object model, the step of creating a target object model in the constructed 3DGS map and providing the initial position coordinates of the carrier specifically includes:

[0014] Add target object models to specified locations in the constructed 3DGS map based on a graphical interface;

[0015] Set attribute parameters for each target object model;

[0016] Mark the initial position of the carrier in the constructed 3DGS map and record its corresponding coordinate information.

[0017] As a further optional solution to the gimbal autofocus method combining 3DGS maps and target object models, the step of performing feature matching between real-time environmental point cloud data around the vehicle and the 3DGS map based on the initial position coordinates of the vehicle to obtain the real-time coordinates and attitude of the gimbal in the radar coordinate system specifically includes:

[0018] The real-time environmental point cloud data around the carrier is matched with the 3DGS map for features, and the SLAM algorithm is used to calculate the position change of the carrier in the 3DGS map.

[0019] By combining the initial position coordinates and position change information of the carrier, the current real-time position of the carrier is determined, and then the real-time coordinates and attitude of the gimbal are obtained.

[0020] As a further optional solution to the gimbal autofocus method combining 3DGS maps and target object models, the step of locating the target object and performing autofocus based on the real-time coordinates and attitude of the gimbal in the radar coordinate system specifically includes:

[0021] Based on the real-time coordinates and attitude of the gimbal in the radar coordinate system, and combined with the rigid body structure parameters of the gimbal and the radar, the real-time coordinates and quaternion orientation of the gimbal in the global coordinate system are calculated.

[0022] Based on the real-time coordinates of the gimbal in the global coordinate system, the three-dimensional coordinates of the target object are transformed to the gimbal coordinate system;

[0023] Based on the three-dimensional coordinates of the target object in the gimbal coordinate system, calculate the horizontal and vertical tilt angles of the target object relative to the gimbal camera;

[0024] Perform corner transformation analysis on the target object and calculate the final zoom level of the gimbal;

[0025] The calculated horizontal and vertical tilt angles are converted into pan / tilt angular coordinates for gimbal control, and the final zoom factor is converted into optical zoom control parameters. Commands are then executed through the gimbal drive interface to achieve autofocus.

[0026] As a further optional solution to the gimbal autofocus method combining 3DGS maps and target object models, the step of transforming the three-dimensional coordinates of the target object to the gimbal coordinate system based on the real-time coordinates of the gimbal in the global coordinate system specifically includes:

[0027] Obtain the real-time coordinates of the gimbal in the global coordinate system and the three-dimensional coordinates of the target object;

[0028] The transformation relationship between the global coordinate system and the gimbal coordinate system is determined. The transformation relationship is defined by the real-time coordinates of the gimbal in the global coordinate system and the position of the origin of the gimbal coordinate system in the global coordinate system.

[0029] Using the aforementioned transformation relationship, the three-dimensional coordinates of the target object are transformed from the global coordinate system to the gimbal coordinate system through a coordinate transformation algorithm.

[0030] As a further optional solution to the gimbal autofocus method combining 3DGS maps and target object models, the three-dimensional coordinates of the target object in the gimbal coordinate system, and the calculation of the horizontal and vertical tilt angles of the target object relative to the gimbal camera, specifically include:

[0031] Obtain the three-dimensional coordinates of the target object in the gimbal coordinate system;

[0032] Determine the coordinates of the optical center of the gimbal camera in the gimbal coordinate system;

[0033] A local coordinate system is established with the optical center position of the PTZ camera as the origin;

[0034] The direction vector of the target object relative to the gimbal camera is obtained by the difference between the three-dimensional coordinates of the target object in the gimbal coordinate system and the optical center coordinates of the gimbal camera.

[0035] Using trigonometric functions and combining the components of the direction vector in the horizontal and vertical directions, the horizontal and vertical deflection angles of the target object relative to the gimbal camera are calculated respectively.

[0036] As a further optional solution to the gimbal autofocus method combining 3DGS maps and target object models, the step of performing corner transformation analysis on the target object and calculating the final zoom level of the gimbal specifically includes:

[0037] Extract the coordinates of multiple corner points of the target object from the initial image;

[0038] Simulate different magnifications of the gimbal camera to obtain images of the target object at each magnification.

[0039] Extract the corner coordinates of the target object from images at various magnification levels;

[0040] By analyzing the variation of corner coordinates with magnification, and combining this with the optical parameters of the gimbal camera, the final magnification of the gimbal is determined.

[0041] A gimbal autofocus system combining a 3DGS map and a target object model, comprising:

[0042] The map building module is used to build 3DGS maps of the target area based on 3DGS technology.

[0043] The model creation and localization module is used to create target object models in the constructed 3DGS map and provide the initial position coordinates of the carrier.

[0044] The data acquisition module is used to collect point cloud data of the environment around the carrier in real time;

[0045] The feature matching module is used to perform feature matching between the real-time environmental point cloud data around the carrier and the 3DGS map based on the initial position coordinates of the carrier, so as to obtain the real-time coordinates and attitude of the gimbal in the radar coordinate system.

[0046] The autofocus module is used to locate the target object and perform autofocus operation based on the real-time coordinates and attitude of the gimbal in the radar coordinate system.

[0047] A computing device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the computer program, implements the steps of any of the above-described gimbal autofocus method combining a 3DGS map and a target object model.

[0048] A computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of any of the above-described gimbal autofocus method combining a 3DGS map and a target object model.

[0049] The beneficial effects of this invention are: by constructing a 3DGS map of the target area based on 3DGS technology, the three-dimensional spatial information of the target area can be accurately presented, including terrain, buildings, etc. In complex environments, such as in the presence of obstructions or interference, the map provides a stable and accurate reference benchmark for gimbal autofocus. Unlike traditional methods that rely on single sensor data or simple positioning techniques, 3DGS maps remain unaffected by real-time environmental changes, maintaining high accuracy and effectively avoiding the problem of decreased focusing accuracy due to environmental interference. Simultaneously, real-time acquisition of environmental point cloud data around the carrier and feature matching with the 3DGS map allows for real-time acquisition of the gimbal's coordinates and attitude in the radar coordinate system. This process fully considers dynamic environmental changes; even if the target object moves or the surrounding environment changes, real-time data updates and matching can quickly and accurately adjust the gimbal's positioning and focusing parameters. Compared to traditional methods where focusing efficiency is significantly reduced in complex environments, this method can quickly respond to environmental changes and significantly improve focusing efficiency. Secondly, creating a target object model within the constructed 3DGS map, and providing the carrier's initial position coordinates, clarifies the target object's position and shape in three-dimensional space. By combining the real-time gimbal coordinates and attitude obtained through feature matching of real-time environmental point cloud data with the 3DGS map, and the target object model, the relative position and attitude relationship between the target object and the gimbal can be accurately calculated, achieving effective utilization of the target object's three-dimensional spatial information and improving focusing accuracy. Attached Figure Description

[0050] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the 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.

[0051] Figure 1 This is a flowchart illustrating a gimbal autofocus method combining a 3DGS map and a target object model according to the present invention.

[0052] Figure 2 This is a schematic diagram of the composition of a gimbal autofocus system that combines a 3DGS map and a target object model according to the present invention.

[0053] Figure 3 This is a schematic diagram of the composition of a computing device according to the present invention. Detailed Implementation

[0054] The technical solutions in the embodiments of the present invention will be clearly and completely described below. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0055] refer to Figures 1 to 3 A gimbal autofocus method combining 3DGS maps and target object models, specifically including:

[0056] A 3DGS map of the target area is constructed based on 3DGS technology. This map contains high-precision geometric structure and realistic texture information to provide a three-dimensional spatial representation of the environment. The specific steps include:

[0057] The target area is scanned from all angles using a 3DGS scanning device to obtain high-precision geometric structure data and realistic texture data of the target area.

[0058] The scanned data is preprocessed, including data cleaning, noise reduction, and registration.

[0059] The 3DGS modeling software is used to generate a 3DGS map containing real-world information from the preprocessed data.

[0060] Specifically, using 3DGS scanning equipment to perform a full-range scan of the target area can acquire high-precision geometric structure data and realistic texture data. Compared with traditional measurement methods, 3DGS scanning equipment can acquire a large amount of dense point cloud data in a short time, accurately recording the geometric information such as terrain undulations and building outlines of the target area, as well as texture information such as the color and material of object surfaces, laying a solid data foundation for building high-precision maps. At the same time, full-range scanning ensures comprehensive coverage of the target area. Whether it is a complex urban street or a natural terrain area, relevant information can be completely acquired, avoiding information omissions caused by limitations in scanning angle or range. This allows the generated 3DGS map to realistically and comprehensively reflect the actual situation of the target area.

[0061] Secondly, preprocessing operations such as cleaning, denoising, and registration are performed on the scanned data, which effectively improves data quality. Data cleaning removes invalid data caused by equipment errors, environmental interference, and other factors; denoising smooths the data and reduces the impact of noise on subsequent modeling; registration precisely aligns and merges data obtained from different scanning locations, ensuring data consistency and coherence, thereby improving data usability and reliability and providing a guarantee for generating high-quality 3DGS maps. Using 3DGS modeling software, the preprocessed data is used to generate 3DGS maps containing real-world information, which can quickly and accurately convert point cloud data into realistic 3D models, greatly improving the efficiency and accuracy of map generation. At the same time, the maps can be further edited and optimized to meet the needs of different application scenarios.

[0062] Create a model of the target object within the constructed 3DGS map, and provide the initial position coordinates of the carrier, specifically including:

[0063] Add target object models to specified locations in the constructed 3DGS map based on a graphical interface;

[0064] Set attribute parameters for each target object model;

[0065] Mark the initial position of the carrier in the constructed 3DGS map and record its corresponding coordinate information.

[0066] Specifically, adding target object models to a pre-constructed 3DGS map and accurately building them according to their actual shape and size can clearly define the target object's precise location and form in three-dimensional space. This is crucial for equipment monitoring and asset management in complex environments such as industrial parks and urban building complexes. Managers can intuitively understand the distribution and positional relationships of target objects, avoiding management chaos caused by inaccurate location information. Recording the initial position coordinates of the carrier provides a reliable benchmark for subsequent calculations and analyses based on that location. In applications such as gimbal autofocus, accurate initial position information helps to accurately calculate the real-time position and attitude of the gimbal, thereby improving the positioning accuracy of the target object and ensuring the accuracy of autofocus.

[0067] By creating target object models and setting attribute parameters in 3DGS maps, key equipment or areas requiring monitoring can be quickly identified and located. Combined with PTZ autofocus technology, high-definition images of target objects can be acquired in real time, reducing the time spent on manual search and target location and greatly improving monitoring efficiency. Setting attribute parameters such as name, model, and number for target object models facilitates information management of equipment and other assets. The location and status of equipment can be queried in real time, enabling dynamic tracking and management of assets and improving the level and efficiency of asset management.

[0068] Based on accurate target object position and carrier initial position information, combined with feature matching of real-time environmental point cloud data and 3DGS map, the real-time coordinates and attitude of the gimbal can be calculated more accurately, thereby achieving precise positioning and autofocus of the target object. Even when the target object moves or the environment changes, the focus parameters can be quickly adjusted to ensure the clarity of the captured image.

[0069] The radar sensors on the carrier collect point cloud data of the environment around the carrier in real time.

[0070] Specifically, radar sensors can transmit signals at high frequencies and receive reflected waves, thereby quickly and accurately acquiring three-dimensional point cloud data of the environment surrounding the carrier. This data includes information such as the distance and angle between objects in the environment and the carrier, which can accurately depict the shape, size, and position of surrounding objects, providing detailed environmental information for the system. By continuously acquiring environmental point cloud data around the carrier and performing feature matching with a pre-built high-precision map (such as a 3DGS map), the carrier's position and attitude in the map can be determined in real time. This real-time dynamic positioning method has high accuracy and update frequency, which can meet the carrier's real-time needs for position information during movement. For example, in applications such as drone aerial photography and robot inspection, it ensures that the carrier can fly or move accurately along a predetermined route. In the gimbal autofocus system, the real-time acquired environmental point cloud data combined with the 3DGS map and the target object model helps to locate the target object more accurately. By analyzing the feature information of the target object in the point cloud data, the position and orientation of the target object relative to the gimbal can be determined, providing a precise positioning basis for autofocus and improving the accuracy and efficiency of focusing.

[0071] Based on the initial position coordinates of the carrier, feature matching is performed between the real-time environmental point cloud data around the carrier and the 3DGS map to obtain the real-time coordinates and attitude of the gimbal in the radar coordinate system, specifically including:

[0072] The real-time environmental point cloud data around the carrier is matched with the 3DGS map for features, and the SLAM algorithm is used to calculate the position change of the carrier in the 3DGS map.

[0073] By combining the initial position coordinates and position change information of the carrier, the current real-time position of the carrier is determined, and then the real-time coordinates and attitude of the gimbal are obtained.

[0074] Specifically, the SLAM (Simultaneous Localization and Mapping) algorithm is used to perform feature matching between real-time environmental point cloud data around the vehicle and a 3DGS map to calculate the vehicle's position change on the map. This fully utilizes the rich feature information in the point cloud data and the high precision of the 3DGS map. The SLAM algorithm can accurately match and calculate a large number of point cloud feature points, thus obtaining a high-precision result of the vehicle's position change. Compared with traditional positioning methods, this greatly improves the accuracy of positioning. By combining the vehicle's initial position coordinates and position change information, the current real-time position of the vehicle is determined, thereby obtaining the real-time coordinates and attitude of the gimbal. This multi-information fusion method further ensures the accuracy of the result. High-precision gimbal coordinates and attitude information are crucial for subsequent gimbal-based operations, such as autofocus and target tracking, ensuring the accuracy and reliability of these operations.

[0075] The SLAM algorithm is highly efficient in feature matching and position calculation, and can quickly process large amounts of real-time environmental point cloud data and output the position change information of the carrier in a timely manner. This enables the system to obtain the coordinates and attitude of the gimbal in real time, which meets the application scenarios with high real-time requirements, such as UAV flight control and robot real-time navigation, and ensures that the system can quickly respond to environmental changes and perform corresponding operations.

[0076] Based on the real-time coordinates and attitude of the gimbal in the radar coordinate system, the target object is located and an automatic focusing operation is performed, specifically including:

[0077] Based on the real-time coordinates and attitude of the gimbal in the radar coordinate system, and combined with the rigid body structure parameters of the gimbal and the radar, the real-time coordinates and quaternion orientation of the gimbal in the global coordinate system are calculated.

[0078] Based on the real-time coordinates of the gimbal in the global coordinate system, the three-dimensional coordinates of the target object are transformed to the gimbal coordinate system;

[0079] Based on the three-dimensional coordinates of the target object in the gimbal coordinate system, calculate the horizontal and vertical tilt angles of the target object relative to the gimbal camera;

[0080] Perform corner transformation analysis on the target object and calculate the final zoom level of the gimbal;

[0081] The calculated horizontal and vertical tilt angles are converted into pan / tilt angular coordinates for gimbal control, and the final zoom factor is converted into optical zoom control parameters. Commands are then executed through the gimbal drive interface to achieve autofocus.

[0082] Specifically, by combining the rigid body structural parameters of the gimbal and radar, the real-time coordinates and attitude of the gimbal in the radar coordinate system are converted into real-time coordinates and quaternion orientation in the global coordinate system. Based on this, the three-dimensional coordinates of the target object are then converted to the gimbal coordinate system. This precise conversion between multiple coordinate systems fully considers the installation relationship between the gimbal and radar and the characteristics of different coordinate systems, and can accurately determine the position of the target object relative to the gimbal camera. Corner transformation analysis of the target object can describe the spatial characteristics of the target object in the gimbal coordinate system in more detail. By calculating the horizontal and vertical deflection angles of the target object relative to the gimbal camera, the orientation information of the target object is further refined, enabling the gimbal to point more accurately at the target object and improving the accuracy of target object positioning.

[0083] Based on the calculated horizontal and vertical tilt angles and the final zoom level, these are quickly converted into pan / tilt angle coordinates for gimbal control and zoom control parameters for optical zoom. Commands are then executed via the gimbal drive interface. This series of calculations and command executions can be completed in a short time, achieving rapid autofocus, reducing focusing time, improving monitoring or shooting efficiency, and enabling timely capture of clear images of the target object. The real-time coordinates and attitude information of the gimbal in the radar coordinate system are dynamically updated, reflecting real-time changes in the gimbal's state. Combined with real-time environmental information collected by the radar sensor (implicitly embedded in the accurate acquisition of real-time coordinates and attitude), this technical solution can adapt to the movement of the target object and dynamic changes in the surrounding environment. For example, when the target object moves, the gimbal's pointing and focus parameters can be adjusted promptly based on the new coordinates and attitude information to ensure clear imaging of the target object at all times.

[0084] It should be noted that the pan / tilt angle coordinates are parameters used to describe the rotation angle of the gimbal in the horizontal and vertical directions. By precisely controlling these two angles, the camera mounted on the gimbal can rotate left and right in the horizontal direction and tilt up and down in the vertical direction, thereby pointing the camera at the target object to be observed or photographed, and realizing monitoring and shooting from different directions. Secondly, the zoom control parameter is used to control the optical zoom of the camera. Optical zoom changes the focal length of the lens by changing the optical structure of the lens inside the camera, such as moving the position of the lens group, thereby achieving the effect of magnifying or reducing the captured image without reducing the image resolution.

[0085] In some embodiments, the step of transforming the three-dimensional coordinates of the target object to the gimbal coordinate system based on the real-time coordinates of the gimbal in the global coordinate system specifically includes:

[0086] Obtain the real-time coordinates of the gimbal in the global coordinate system and the three-dimensional coordinates of the target object;

[0087] The transformation relationship between the global coordinate system and the gimbal coordinate system is determined. The transformation relationship is defined by the real-time coordinates of the gimbal in the global coordinate system and the position of the origin of the gimbal coordinate system in the global coordinate system.

[0088] Using the aforementioned transformation relationship, the three-dimensional coordinates of the target object are transformed from the global coordinate system to the gimbal coordinate system through a coordinate transformation algorithm. The coordinate transformation algorithm is based on the principle of homogeneous coordinate transformation and uses a rotation matrix and a translation vector to transform and calculate the coordinates of the target object.

[0089] Specifically, by acquiring the real-time coordinates of the gimbal in the global coordinate system and the three-dimensional coordinates of the target object, and determining the transformation relationship between the two coordinate systems, a coordinate transformation algorithm based on the homogeneous coordinate transformation principle (using rotation matrix and translation vector) can accurately transform the coordinates of the target object into the gimbal coordinate system. This allows the gimbal to accurately know the position of the target object relative to itself, thereby accurately pointing the camera at the target object, greatly improving the positioning accuracy of the target object and ensuring the accuracy of monitoring or shooting. Since the real-time coordinates of the gimbal in the global coordinate system are used, this solution can adapt to the dynamic changes of the gimbal's movement and rotation in real time. No matter what position or attitude the gimbal is in, it can calculate the coordinates of the target object in the gimbal coordinate system in a timely and accurate manner, ensuring that the gimbal can always accurately track and point at the target object.

[0090] The coordinate transformation algorithm based on the principle of homogeneous coordinate transformation uses rotation matrix and translation vector for calculation. It features high computational efficiency and good stability. In monitoring and shooting scenarios with high real-time requirements, it can quickly complete coordinate transformation calculations and provide accurate target object position information for PTZ control in a timely manner, ensuring real-time response capability.

[0091] In some embodiments, the three-dimensional coordinates of the target object in the gimbal coordinate system, and the calculation of the horizontal and vertical tilt angles of the target object relative to the gimbal camera, specifically include:

[0092] Obtain the three-dimensional coordinates of the target object in the gimbal coordinate system;

[0093] Determine the coordinates of the optical center of the gimbal camera in the gimbal coordinate system;

[0094] A local coordinate system is established with the optical center position of the PTZ camera as the origin;

[0095] The direction vector of the target object relative to the gimbal camera is obtained by the difference between the three-dimensional coordinates of the target object in the gimbal coordinate system and the optical center coordinates of the gimbal camera.

[0096] Using trigonometric functions and combining the components of the direction vector in the horizontal and vertical directions, the horizontal and vertical deflection angles of the target object relative to the gimbal camera are calculated respectively.

[0097] Specifically, by obtaining the three-dimensional coordinates of the target object in the pan-tilt coordinate system, the optical center position of the pan-tilt camera is determined and a local coordinate system is established. Then, the direction vector is obtained based on the difference between the two coordinates. Finally, the horizontal and vertical deflection angles are calculated using trigonometric functions. This series of steps can accurately determine the direction of the target object relative to the pan-tilt camera, enabling the pan-tilt to accurately aim the camera at the target object, greatly improving the accuracy of target positioning and ensuring that the monitored or captured images can clearly capture the target. Establishing a local coordinate system with the optical center position of the pan-tilt camera as the origin reduces the accumulation of errors that may be caused by absolute coordinate measurements. During the calculation process, vector operations and angle calculations are performed based on the relative position relationship, making the final deflection angle result more reliable and able to more realistically reflect the directional relationship between the target object and the camera.

[0098] The calculated horizontal and vertical deflection angles provide precise command parameters for the motion control of the gimbal. Based on this angle information, the gimbal can make precise rotation adjustments in the horizontal and vertical directions, enabling rapid tracking and continuous monitoring of the target object. Regardless of whether the target object is stationary or moving, the gimbal can adjust its attitude in a timely manner according to the changes in the deflection angle to maintain alignment with the target object. This technical solution can adapt to the target object in different positions and various motion states. For target objects of different distances and heights, the rotation angle of the gimbal can be determined by calculating the corresponding deflection angle. When the target object moves, the changes in the deflection angle are calculated in real time, enabling the gimbal to dynamically track the target, exhibiting strong adaptability and flexibility.

[0099] The deflection angle is calculated by using trigonometric functions combined with direction vector components. The algorithm is relatively simple and has a small computational load. In real-time monitoring systems, it can complete the calculation and output the deflection angle result in a short time, meeting the system's real-time requirements and ensuring that the PTZ can respond and adjust its attitude in a timely manner.

[0100] In some embodiments, performing corner transformation analysis on the target object and calculating the final zoom level of the gimbal specifically includes:

[0101] Extract the coordinates of multiple corner points of the target object from the initial image;

[0102] Simulate different magnifications of the gimbal camera to obtain images of the target object at each magnification.

[0103] Extract the corner coordinates of the target object from images at various magnification levels;

[0104] By analyzing the variation of corner coordinates with magnification, and combining this with the optical parameters of the gimbal camera, the final magnification of the gimbal is determined.

[0105] Specifically, by extracting the coordinates of multiple corner points of the target object in the initial image and simulating different zoom levels on the gimbal camera, the image and corner coordinates of the target object at each zoom level are obtained. Analyzing the variation of corner coordinates with zoom level and combining this with the camera's optical parameters allows for precise calculation of the final zoom level of the gimbal. This enables the gimbal to accurately adjust the zoom level based on the actual situation of the target object, ensuring that the target object is presented at an appropriate size in the image for easy observation and identification. Regardless of the distance of the target object from the gimbal or its size, the optimal zoom level can be found through corner transformation analysis. For smaller, distant targets, the zoom level can be increased to make them clearly visible; for larger, closer targets, the zoom level can be appropriately decreased to obtain a wider field of view, improving adaptability to different targets.

[0106] Precise zoom calculations ensure that the target object occupies an appropriate proportion in the image, avoiding problems such as the target object being too small and unclear due to insufficient zoom, or the image being blurry and the field of view being narrow due to excessive zoom. This ensures that the image of the target object is clear and rich in detail, improving the accuracy of observation and recognition. An appropriate zoom can also make the overall composition of the image more reasonable, highlight the target object, reduce the interference of irrelevant information in the surroundings, and improve the visual effect and information transmission efficiency of the image.

[0107] A gimbal autofocus system combining a 3DGS map and a target object model, comprising:

[0108] The map building module is used to build 3DGS maps of the target area based on 3DGS technology.

[0109] The model creation and localization module is used to create target object models in the constructed 3DGS map and provide the initial position coordinates of the carrier.

[0110] The data acquisition module is used to collect point cloud data of the environment around the carrier in real time;

[0111] The feature matching module is used to perform feature matching between the real-time environmental point cloud data around the carrier and the 3DGS map based on the initial position coordinates of the carrier, so as to obtain the real-time coordinates and attitude of the gimbal in the radar coordinate system.

[0112] The autofocus module is used to locate the target object and perform autofocus operation based on the real-time coordinates and attitude of the gimbal in the radar coordinate system.

[0113] A computing device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the computer program, implements the steps of any of the above-described gimbal autofocus method combining a 3DGS map and a target object model.

[0114] A computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of any of the above-described gimbal autofocus method combining a 3DGS map and a target object model.

[0115] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A gimbal autofocus method combining 3DGS maps and target object models, characterized in that, Specifically, it includes: Constructing a 3DGS map of the target area based on 3DGS technology; Create a model of the target object in the constructed 3DGS map, and give the initial position coordinates of the carrier; Real-time acquisition of environmental point cloud data around the carrier; Based on the initial position coordinates of the carrier, feature matching is performed between the real-time environmental point cloud data around the carrier and the 3DGS map to obtain the real-time coordinates and attitude of the gimbal in the radar coordinate system. Based on the real-time coordinates and attitude of the gimbal in the radar coordinate system, the target object is located and an automatic focusing operation is performed.

2. The gimbal autofocus method combining 3DGS map and target object model according to claim 1, characterized in that, The step of creating a target object model in the constructed 3DGS map and providing the initial position coordinates of the carrier specifically includes: Add target object models to specified locations in the constructed 3DGS map based on a graphical interface; Set attribute parameters for each target object model; Mark the initial position of the carrier in the constructed 3DGS map and record its corresponding coordinate information.

3. The gimbal autofocus method combining 3DGS map and target object model according to claim 2, characterized in that, The method based on the initial position coordinates of the carrier involves feature matching of the real-time environmental point cloud data around the carrier with the 3DGS map to obtain the real-time coordinates and attitude of the gimbal in the radar coordinate system, specifically including: The real-time environmental point cloud data around the carrier is matched with the 3DGS map for features, and the SLAM algorithm is used to calculate the position change of the carrier in the 3DGS map. By combining the initial position coordinates and position change information of the carrier, the current real-time position of the carrier is determined, and then the real-time coordinates and attitude of the gimbal are obtained.

4. The gimbal autofocus method combining 3DGS map and target object model according to claim 3, characterized in that, The process of locating the target object and performing automatic focusing based on the real-time coordinates and attitude of the gimbal in the radar coordinate system specifically includes: Based on the real-time coordinates and attitude of the gimbal in the radar coordinate system, and combined with the rigid body structure parameters of the gimbal and the radar, the real-time coordinates and quaternion orientation of the gimbal in the global coordinate system are calculated. Based on the real-time coordinates of the gimbal in the global coordinate system, the three-dimensional coordinates of the target object are transformed to the gimbal coordinate system; Based on the three-dimensional coordinates of the target object in the gimbal coordinate system, calculate the horizontal and vertical tilt angles of the target object relative to the gimbal camera; Perform corner transformation analysis on the target object and calculate the final zoom level of the gimbal; The calculated horizontal and vertical tilt angles are converted into pan / tilt angular coordinates for gimbal control, and the final zoom factor is converted into zoom control parameters for optical zoom. Commands are then executed through the gimbal drive interface to achieve autofocus.

5. The gimbal autofocus method combining 3DGS map and target object model according to claim 4, characterized in that, The process of transforming the three-dimensional coordinates of the target object to the gimbal coordinate system based on the real-time coordinates of the gimbal in the global coordinate system specifically includes: Obtain the real-time coordinates of the gimbal in the global coordinate system and the three-dimensional coordinates of the target object; The transformation relationship between the global coordinate system and the gimbal coordinate system is determined. The transformation relationship is defined by the real-time coordinates of the gimbal in the global coordinate system and the position of the origin of the gimbal coordinate system in the global coordinate system. Using the aforementioned transformation relationship, the three-dimensional coordinates of the target object are transformed from the global coordinate system to the gimbal coordinate system through a coordinate transformation algorithm.

6. The gimbal autofocus method combining 3DGS map and target object model according to claim 5, characterized in that, The three-dimensional coordinates of the target object in the gimbal coordinate system are calculated, and the horizontal and vertical tilt angles of the target object relative to the gimbal camera are calculated, specifically including: Obtain the three-dimensional coordinates of the target object in the gimbal coordinate system; Determine the coordinates of the optical center of the gimbal camera in the gimbal coordinate system; A local coordinate system is established with the optical center position of the PTZ camera as the origin; The direction vector of the target object relative to the gimbal camera is obtained by the difference between the three-dimensional coordinates of the target object in the gimbal coordinate system and the optical center coordinates of the gimbal camera. Using trigonometric functions and combining the components of the direction vector in the horizontal and vertical directions, the horizontal and vertical deflection angles of the target object relative to the gimbal camera are calculated respectively.

7. The gimbal autofocus method combining 3DGS map and target object model according to claim 6, characterized in that, The step of performing corner transformation analysis on the target object and calculating the final zoom level of the gimbal specifically includes: Extract the coordinates of multiple corner points of the target object from the initial image; Simulate different magnifications of the gimbal camera to obtain images of the target object at each magnification. Extract the corner coordinates of the target object from images at various magnification levels; By analyzing the variation of corner coordinates with magnification, and combining this with the optical parameters of the gimbal camera, the final magnification of the gimbal is determined.

8. A gimbal autofocus system combining a 3DGS map and a target object model, characterized in that, include: The map building module is used to build 3DGS maps of the target area based on 3DGS technology. The model creation and localization module is used to create target object models in the constructed 3DGS map and provide the initial position coordinates of the carrier. The data acquisition module is used to collect point cloud data of the environment around the carrier in real time; The feature matching module is used to perform feature matching between the real-time environmental point cloud data around the carrier and the 3DGS map based on the initial position coordinates of the carrier, so as to obtain the real-time coordinates and attitude of the gimbal in the radar coordinate system. The autofocus module is used to locate the target object and perform autofocus operation based on the real-time coordinates and attitude of the gimbal in the radar coordinate system.

9. A computing device, characterized in that, The device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the computer program, implements the steps of the gimbal autofocus method combining a 3DGS map and a target object model as described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, The storage medium stores a computer program, which, when executed by a processor, implements the steps of the gimbal autofocus method combining a 3DGS map and a target object model as described in any one of claims 1-7.