A pan-tilt machine tracking method and system based on mobile detection and neural network
Patent Information
- Application Number
- CN202411252013.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-09
- Publication Date
- 2026-10-30
- Estimated Expiration
- 2044-09-09
AI Technical Summary
[0003]人工智能不断发展的今天,安防领域相关追踪技术已经取得了显著的进步,但在实际应用时仍面临挑战
[0035](1)在追踪识别阶段采用基于卷积神经网络的识别模型对采集到的图像数据进行人物识别得到含有人物的图像帧,提高了对人物识别的准确性。
Smart Images

Figure CN119006527B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of trajectory tracking technology, specifically relating to a gimbal tracking method and system based on motion detection and neural networks. Background Technology
[0002] Tracking technology is a crucial task for sensor and machine vision technologies, especially in the increasingly prevalent and important fields of home and security. On the one hand, with the continuous advancement of IoT technology and the expansion of its application areas, the application scenarios of tracking technology will continue to expand; on the other hand, with the increasing maturity of artificial intelligence and security fields, and the continuous upgrading of consumer demands, the tracking technology used in PTZ cameras will play an even more important role.
[0003] With the continuous development of artificial intelligence, tracking technologies in the security field have made significant progress, but challenges still exist in practical applications. For example, while deep learning-based algorithms offer high accuracy, they are computationally intensive and lack real-time performance; traditional image processing methods, while offering good real-time performance, have limited accuracy. Therefore, there is still room for improvement in PTZ tracking technology. Summary of the Invention
[0004] To address the aforementioned problems in the existing technology, this invention provides a gimbal tracking method based on motion detection and neural networks.
[0005] The objective of this invention can be achieved through the following technical solutions:
[0006] S1: Acquire statistical image data of motion detection through a gimbal, perform frame segmentation on the statistical image data to obtain an image frame sequence, add timestamps to the image frame sequence to obtain a time-series image frame sequence, calculate a motion frame set based on the time-series image frame sequence using a motion recognition model, and calculate a recognition frame set based on the time-series image frame sequence using a recognition model.
[0007] S2: Based on the motion frame set and the recognition frame set, a target motion frame set is calculated using a elimination model; based on the target motion frame set, a motion macroblock set is calculated using a motion extraction model; based on the target motion frame set, a target person is calculated using a person extraction model.
[0008] S3: Obtain a reference coordinate set based on the motion macroblock set, obtain target coordinates based on the target character, and traverse and filter the reference coordinate set based on the target coordinates to obtain the target macroblock set;
[0009] S4: The gimbal acquires real-time image frames, calculates a measured macroblock set based on the motion extraction model using the real-time image frames, calculates a shifted macroblock set using a matching algorithm based on the target macroblock set and the measured macroblock set, calculates a rotation angle using a rotation angle model based on the target macroblock set and the shifted macroblock set, and the smart terminal generates an adaptive signal based on the rotation angle to control the gimbal for tracking.
[0010] As a preferred embodiment of the present invention, the motion recognition model preprocesses the temporal image frame sequence sequentially to obtain a preprocessed image sequence, then converts the preprocessed image sequence to grayscale to obtain a grayscale image sequence, calculates the grayscale value of each grayscale image based on the grayscale image sequence and color channel weights, calculates the grayscale difference between two consecutive grayscale images based on the grayscale value, compares the grayscale difference with a preset threshold to obtain a changed frame, and sets each of the changed frames to obtain the motion frame set.
[0011] Specifically, the recognition model is based on a convolutional neural network and is used to determine whether a person appears in the time-series image frame sequence. The specific calculation steps are as follows:
[0012] S301: Preprocess the time-series image frame sequence to obtain a preprocessed image sequence, the preprocessing including image grayscale conversion, noise reduction, and image enhancement;
[0013] S302: Feature data is obtained by performing feature extraction based on the preprocessed image sequence, the feature data including shape features and texture features;
[0014] S303: Dimensionality reduction is performed on the feature data to obtain dimensionality-reduced features. The dimensionality reduction process includes average normalization, standardization, zero-component analysis, and dimensionality reduction calculation.
[0015] S304: Based on the dimensionality reduction features, the recognition result is calculated by a classifier, and the recognition frame set is obtained by labeling the time-series image frame sequence based on the recognition result.
[0016] Specifically, the elimination model first obtains misjudgment results from the motion frame set using a light-sensitive diagnostic algorithm, then eliminates the motion frame set based on the misjudgment results to obtain a purified frame set, and finally iterates through and filters the purified frame set based on the timestamps of the identified frame set to obtain the target motion frame set. The calculation formula for the light-sensitive diagnostic algorithm is as follows:
[0017]
[0018] Where x and y are pixel coordinates, A is the image region, S(x, y, t) is the gray value of pixel (x, y) at time t, a is the time difference, c is the adjustment coefficient, b is the number of pixels in the detection region, and N is the preset threshold.
[0019] Specifically, the motion extraction model obtains a grayscale frame set by converting the target frame set to grayscale, divides the grayscale frame set into macroblocks according to a preset macroblock width to obtain a segmented frame set, calculates the grayscale value difference between two consecutive frames based on the segmented frame set, compares the grayscale value difference with a preset threshold to obtain a motion macroblock determination result, marks the macroblocks based on the motion macroblock determination result to obtain motion macroblocks, and sets adjacent motion macroblocks to obtain the motion macroblock set.
[0020] Specifically, the person extraction model is based on a recognition model. The recognition model calculates a person recognition result set based on the target motion frame set, obtains the coordinate domain of the person recognition result set, compares the coordinate domain with a preset coordinate frame threshold to obtain a comparison result, and filters the person recognition result set based on the comparison result to obtain the target person.
[0021] Specifically, the rotation angle includes a horizontal rotation angle and a vertical rotation angle. The rotation angle model determines the motion direction of the gimbal by calculating the coordinate difference between the target macroblock group and the measured macroblock group. The horizontal rotation angle and the vertical rotation angle are calculated based on the coordinates of the measured macroblock group. The formula for calculating the horizontal rotation angle is:
[0022]
[0023] Where, θ x θx0 is the horizontal rotation angle, x is the measured x-coordinate of the macroblock group, w is the screen width, and θx0 is the horizontal field of view.
[0024] The formula for calculating the vertical rotation angle is:
[0025]
[0026] Where, θ y θy0 is the horizontal rotation angle, y is the measured ordinate of the macroblock group, h is the screen height, and θy0 is the vertical field of view angle.
[0027] A gimbal tracking system based on motion detection and neural networks includes: an image acquisition module, an extraction module, a comparison module, and a tracking module.
[0028] The image acquisition module is used to acquire statistical image data of motion detection through a gimbal, perform frame segmentation processing on the statistical image data to obtain an image frame sequence, add timestamps to the image frame sequence to obtain a time-series image frame sequence, calculate a motion frame set based on the time-series image frame sequence through a motion recognition model, and calculate a recognition frame set based on the time-series image frame sequence through a recognition model.
[0029] The extraction module is used to calculate a target motion frame set based on the motion frame set and the identified frame set using a elimination model, to calculate a motion macroblock set based on the target motion frame set using a motion extraction model, and to calculate a target person based on the target motion frame set using a person extraction model.
[0030] The comparison module is used to obtain a reference coordinate set based on the motion macroblock set, obtain target coordinates based on the target person, and traverse and filter the reference coordinate set based on the target coordinates to obtain the target macroblock set.
[0031] The tracking module is used to acquire real-time image frames through the gimbal, calculate a measured macroblock set based on the real-time image frames using the motion extraction model, calculate a shifted macroblock set based on the target macroblock set and the measured macroblock set using a matching algorithm, calculate a rotation angle based on the target macroblock set and the shifted macroblock set using a rotation angle model, and generate an adaptive signal based on the rotation angle to control the gimbal to perform tracking.
[0032] An electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that the processor, when executing the program, implements the gimbal tracking method based on motion detection and neural networks as described above.
[0033] A storage medium containing computer-executable instructions, characterized in that the computer-executable instructions, when executed by a computer processor, are used to perform the gimbal tracking method based on motion detection and neural networks as described above.
[0034] The beneficial effects of this invention are as follows:
[0035] (1) In the tracking and recognition stage, a recognition model based on convolutional neural networks is used to perform human recognition on the collected image data to obtain image frames containing human figures, which improves the accuracy of human figure recognition.
[0036] (2) In the tracking stage, the target person is obtained based on the person extraction model, and the target macroblock group is obtained by traversing the reference coordinate set based on the coordinates of the target person. Real-time tracking is performed based on the target macroblock group through motion vector search, which solves the problems of poor real-time performance and large computational load caused by using deep learning methods in the tracking stage.
[0037] (3) During tracking, the combination of three compensation methods—central area compensation, reverse rotation compensation, and edge compensation—can more accurately adapt to the characteristics of motor rotation, thereby improving the accuracy and efficiency of tracking. Attached Figure Description
[0038] To facilitate understanding by those skilled in the art, the present invention will be further described below with reference to the accompanying drawings.
[0039] Figure 1 This is a schematic flowchart of the method of the present invention. Detailed Implementation
[0040] To further illustrate the technical means and effects of the present invention in achieving its intended purpose, the following detailed description of the specific implementation methods, structures, features, and effects of the present invention, in conjunction with the accompanying drawings and preferred embodiments, is provided.
[0041] Please see Figure 1 A gimbal tracking method based on motion detection and neural networks
[0042] S1: Acquire statistical image data of motion detection through a gimbal, perform frame segmentation on the statistical image data to obtain an image frame sequence, add timestamps to the image frame sequence to obtain a time-series image frame sequence, calculate a motion frame set based on the time-series image frame sequence using a motion recognition model, and calculate a recognition frame set based on the time-series image frame sequence using a recognition model; the recognition frame set is an image frame sequence containing person recognition results.
[0043] S2: Based on the motion frame set and the recognition frame set, a target motion frame set is calculated using a culling model; based on the target motion frame set, a motion macroblock set is calculated using a motion extraction model; based on the target motion frame set, a target person is calculated using a person extraction model; the motion macroblock set is composed of adjacent motion macroblocks and is used to represent moving objects.
[0044] S3: Obtain a reference coordinate set based on the motion macroblock group set, obtain target coordinates based on the target person, and traverse and filter the reference coordinate set based on the target coordinates to obtain a target macroblock group; the reference coordinate set consists of the center point coordinates of each motion macroblock group, and the target coordinates are the center point coordinates of the target person.
[0045] S4: The gimbal acquires real-time image frames, calculates a measured macroblock set based on the motion extraction model using the real-time image frames, calculates a shifted macroblock set using a matching algorithm based on the target macroblock set and the measured macroblock set, calculates a rotation angle using a rotation angle model based on the target macroblock set and the shifted macroblock set, and the smart terminal generates an adaptive signal based on the rotation angle to control the gimbal for tracking.
[0046] In this embodiment, the matching algorithm obtains the shifted macroblock group in the next frame by searching the measured macroblock group set through motion vectors based on the target macroblock group in the previous frame. The matching algorithm calculation formula is as follows:
[0047]
[0048] Where (x, y) are the coordinates of the target macroblock group, MCF is the matching cost function, A is the allowed motion vector search range, and (x1, y1) are the coordinates of the shifted macroblock group.
[0049] Specifically, the motion recognition model preprocesses the temporal image frame sequence sequentially to obtain a preprocessed image sequence, then converts the preprocessed image sequence to grayscale to obtain a grayscale image sequence. Based on the grayscale image sequence and color channel weights, it calculates the grayscale value of each grayscale image. Based on the grayscale value, it calculates the grayscale difference between two consecutive grayscale images, compares the grayscale difference with a preset threshold to obtain a changed frame, and sets each of the changed frames to obtain the motion frame set. The preprocessing includes noise reduction and contrast enhancement.
[0050] Specifically, the recognition model is based on a convolutional neural network and is used to determine whether a person appears in the time-series image frame sequence. The specific calculation steps are as follows:
[0051] S301: Preprocess the time-series image frame sequence to obtain a preprocessed image sequence, the preprocessing including image grayscale conversion, noise reduction, and image enhancement;
[0052] S302: Feature data is obtained by performing feature extraction based on the preprocessed image sequence, the feature data including shape features and texture features;
[0053] S303: Dimensionality reduction is performed on the feature data to obtain dimensionality-reduced features. The dimensionality reduction process includes average normalization, standardization, zero-component analysis, and dimensionality reduction calculation.
[0054] S304: Based on the dimensionality reduction features, the recognition result is calculated by a classifier, and the recognition frame set is obtained by labeling the time-series image frame sequence based on the recognition result.
[0055] Specifically, the elimination model first obtains misjudgment results from the motion frame set using a light-sensitive diagnostic algorithm, then eliminates the motion frame set based on the misjudgment results to obtain a purified frame set, and finally iterates through and filters the purified frame set based on the timestamps of the identified frame set to obtain the target motion frame set. The calculation formula for the light-sensitive diagnostic algorithm is as follows:
[0056]
[0057] Where x and y are pixel coordinates, A is the image region, S(x, y, t) is the gray value of pixel (x, y) at time t, a is the time difference, c is the adjustment coefficient, b is the number of pixels in the detection region, and N is the preset threshold.
[0058] In this embodiment, the photosensitive diagnostic algorithm is used to remove the grayscale value changes of the same pixel points in two consecutive frames caused by changes in illumination, which could lead to motion misjudgment.
[0059] Specifically, the motion extraction model obtains a grayscale frame set by converting the target frame set to grayscale, divides the grayscale frame set into macroblocks according to a preset macroblock width to obtain a segmented frame set, calculates the grayscale value difference between two consecutive frames based on the segmented frame set, compares the grayscale value difference with a preset threshold to obtain a motion macroblock determination result, marks the macroblocks based on the motion macroblock determination result to obtain motion macroblocks, and sets adjacent motion macroblocks to obtain the motion macroblock set.
[0060] Specifically, the person extraction model is based on a recognition model. The recognition model calculates a person recognition result set based on the target motion frame set, obtains the coordinate domain of the person recognition result set, compares the coordinate domain with a preset coordinate frame threshold to obtain a comparison result, and filters the person recognition result set based on the comparison result to obtain the target person.
[0061] Specifically, the rotation angle includes a horizontal rotation angle and a vertical rotation angle. The rotation angle model determines the motion direction of the gimbal by calculating the coordinate difference between the target macroblock group and the measured macroblock group. The horizontal rotation angle and the vertical rotation angle are calculated based on the coordinates of the measured macroblock group. The formula for calculating the horizontal rotation angle is:
[0062]
[0063] Where, θ x θx0 is the horizontal rotation angle, x is the measured x-coordinate of the macroblock group, w is the screen width, and θx0 is the horizontal field of view.
[0064] The formula for calculating the vertical rotation angle is:
[0065]
[0066] Where, θ y θy0 is the horizontal rotation angle, y is the measured ordinate of the macroblock group, h is the screen height, and θy0 is the vertical field of view angle.
[0067] A gimbal tracking system based on motion detection and neural networks includes: an image acquisition module, an extraction module, a comparison module, and a tracking module.
[0068] The image acquisition module is used to acquire statistical image data of motion detection through a gimbal, perform frame segmentation processing on the statistical image data to obtain an image frame sequence, add timestamps to the image frame sequence to obtain a time-series image frame sequence, calculate a motion frame set based on the time-series image frame sequence through a motion recognition model, and calculate a recognition frame set based on the time-series image frame sequence through a recognition model.
[0069] The extraction module is used to calculate a target motion frame set based on the motion frame set and the identified frame set using a elimination model, to calculate a motion macroblock set based on the target motion frame set using a motion extraction model, and to calculate a target person based on the target motion frame set using a person extraction model.
[0070] The comparison module is used to obtain a reference coordinate set based on the motion macroblock set, obtain target coordinates based on the target person, and traverse and filter the reference coordinate set based on the target coordinates to obtain the target macroblock set.
[0071] The tracking module is used to acquire real-time image frames through the gimbal, calculate a measured macroblock set based on the real-time image frames using the motion extraction model, calculate a shifted macroblock set based on the target macroblock set and the measured macroblock set using a matching algorithm, calculate a rotation angle based on the target macroblock set and the shifted macroblock set using a rotation angle model, and generate an adaptive signal based on the rotation angle to control the gimbal to perform tracking.
[0072] In this embodiment, when the intelligent terminal generates an adaptive signal based on the rotation angle to control the gimbal to perform tracking, it needs to perform motion compensation based on the coordinates of the shift macroblock group to ensure that the tracking target is always in the center of the screen. The motion compensation includes center area compensation, reverse rotation compensation, and edge compensation.
[0073] The center area compensation is for image stabilization and improving user experience. When a moving object approaches the center of the screen, it is not necessary to adjust it precisely to the exact center macroblock of the screen. Instead, the adjustment is stopped once the object enters the center area. This can reduce unnecessary motor rotation and extend the life of the device while ensuring image stability.
[0074] The reverse rotation compensation is to address the fact that in some cases, the direction of a person's movement may be opposite to the direction the motor is planned to rotate. For example, when a person moves to the left in the frame, if the motor is also rotating to the left at the same time, the person may quickly leave the frame. To solve this problem, when the direction of a person's movement is detected to be opposite to the direction of the motor's rotation, the motor's rotation will be paused in this frame, and the adjustment will be made according to the new motion coordinates after one frame. This ensures that the person remains visible in the frame and improves the accuracy of tracking.
[0075] The edge compensation is used when the moving target moves too fast and the motor cannot keep up. In such cases, the moving target may remain at the edge of the screen and in the same direction as the motor. To address this, an edge compensation strategy is employed. When this scenario is detected, the algorithm speeds up the motor to ensure that the moving target remains in the center of the screen, thus providing a smoother and more stable tracking experience.
[0076] An electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that the processor, when executing the program, implements the gimbal tracking method based on motion detection and neural networks as described above.
[0077] A storage medium containing computer-executable instructions, characterized in that the computer-executable instructions, when executed by a computer processor, are used to perform the gimbal tracking method based on motion detection and neural networks as described above.
[0078] The computer storage medium of this invention can be any combination of one or more computer-readable media. A computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. Computer-readable storage media can be, for example, but not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatuses, or devices, or any combination thereof. More specific examples (a non-exhaustive list) of computer-readable storage media include: electrical connections having 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 fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In this document, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device.
[0079] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, capable of sending, propagating, or transmitting programs for use by or in connection with an instruction execution system, apparatus, or device.
[0080] The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to wireless, wired, optical fiber, RF, etc., or any suitable combination thereof. The computer program code for performing the operations of this invention can be written in one or more programming languages or a combination thereof, including object-oriented programming languages—such as Java, Smalltalk, and C++—and conventional procedural programming languages—such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer can be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0081] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention in any way. Although the present invention has been disclosed above with reference to preferred embodiments, it is not intended to limit the present invention. Any person skilled in the art can make some modifications or alterations to the above-disclosed technical content to create equivalent embodiments without departing from the scope of the present invention. Any simple modifications, equivalent changes and alterations made to the above embodiments based on the technical essence of the present invention without departing from the scope of the present invention shall still fall within the scope of the present invention.
Claims
1. A gimbal tracking method based on motion detection and neural networks, characterized in that, include: S1: Acquire statistical image data of motion detection through a gimbal, perform frame segmentation processing on the statistical image data to obtain an image frame sequence, add timestamps to the image frame sequence to obtain a time-series image frame sequence, calculate a motion frame set based on the time-series image frame sequence using a motion recognition model, and calculate a recognition frame set based on the time-series image frame sequence using a recognition model. S2: Based on the motion frame set and the recognition frame set, a target motion frame set is calculated using a elimination model; a motion macroblock set is calculated using a motion extraction model based on the target motion frame set; and a target person is calculated using a person extraction model based on the target motion frame set. S3: Obtain a reference coordinate set based on the motion macroblock set, obtain the target coordinates based on the target character, and traverse and filter the reference coordinate set based on the target coordinates to obtain the target macroblock set; S4: The gimbal acquires real-time image frames, calculates a measured macroblock set based on the motion extraction model using the real-time image frames, calculates a shifted macroblock set using a matching algorithm based on the target macroblock set and the measured macroblock set, calculates a rotation angle using a rotation angle model based on the target macroblock set and the shifted macroblock set, and the smart terminal generates an adaptive signal based on the rotation angle to control the gimbal for tracking.
2. The gimbal tracking method based on motion detection and neural networks according to claim 1, characterized in that, The motion recognition model preprocesses the temporal image frame sequence sequentially to obtain a preprocessed image sequence, then converts the preprocessed image sequence to grayscale to obtain a grayscale image sequence. Based on the grayscale image sequence and color channel weights, the grayscale value of each grayscale image is calculated. Based on the grayscale value, the grayscale difference between two consecutive grayscale images is calculated. The grayscale difference is compared with a preset threshold to obtain a changed frame. Each changed frame is then set together to obtain the motion frame set.
3. The gimbal tracking method based on motion detection and neural networks according to claim 1, characterized in that, The recognition model is based on a convolutional neural network and is used to determine whether a person appears in the time-series image frame sequence. The specific calculation steps are as follows: S301: Preprocess the time-series image frame sequence to obtain a preprocessed image sequence, the preprocessing including image grayscale conversion, noise reduction, and image enhancement; S302: Feature data is obtained by performing feature extraction based on the preprocessed image sequence, the feature data including shape features and texture features; S303: Dimensionality reduction is performed on the feature data to obtain dimensionality-reduced features. The dimensionality reduction process includes average normalization, standardization, zero-component analysis, and dimensionality reduction calculation. S304: Based on the dimensionality reduction features, the recognition result is calculated by a classifier, and the recognition frame set is obtained by calibrating the time-series image frame sequence based on the recognition result.
4. The gimbal tracking method based on motion detection and neural networks according to claim 1, characterized in that, The elimination model first obtains misjudgment results from the motion frame set using a light-sensitive diagnostic algorithm, then eliminates the motion frame set based on the misjudgment results to obtain a purified frame set. Finally, it iterates through and filters the purified frame set based on the timestamps of the identified frame sets to obtain the target motion frame set. The calculation formula for the light-sensitive diagnostic algorithm is as follows: , in, x, y These are the pixel coordinates. A For image region, S(x, y, t) for t time (x, y) The grayscale value of a pixel. a For the time difference, c For adjustment coefficients, b To determine the number of pixels within the detection area, N This is a preset threshold.
5. The gimbal tracking method based on motion detection and neural networks according to claim 1, characterized in that, The motion extraction model obtains a grayscale frame set by converting the target motion frame set to grayscale, divides the grayscale frame set into macroblocks according to a preset macroblock width to obtain a segmented frame set, calculates the grayscale value difference between two consecutive frames based on the segmented frame set, compares the grayscale value difference with a preset threshold to obtain a motion macroblock determination result, calibrates the macroblocks based on the motion macroblock determination result to obtain motion macroblocks, and sets adjacent motion macroblocks to obtain the motion macroblock set.
6. The gimbal tracking method based on motion detection and neural networks according to claim 1, characterized in that, The person extraction model is based on a recognition model. The recognition model calculates a person recognition result set based on the target motion frame set, obtains the coordinate domain of the person recognition result set, compares the coordinate domain with a preset coordinate frame threshold to obtain a comparison result, and filters the person recognition result set based on the comparison result to obtain the target person.
7. The gimbal tracking method based on motion detection and neural networks according to claim 1, characterized in that, The rotation angle includes a horizontal rotation angle and a vertical rotation angle. The rotation angle model determines the motion direction of the gimbal by calculating the coordinate difference between the target macroblock group and the measured macroblock group. The horizontal rotation angle and the vertical rotation angle are calculated based on the coordinates of the measured macroblock group. The formula for calculating the horizontal rotation angle is: , in, θ x The horizontal rotation angle, x For the measured x-coordinate of the macroblock group, w The width of the screen. θx 0 This refers to the horizontal field of view. The formula for calculating the vertical rotation angle is: , in, θ y The horizontal rotation angle, y The measured ordinate of the macroblock group. h The height of the image. θy 0 This is the vertical field of view angle.
8. A gimbal tracking system based on motion detection and neural networks, applying the gimbal tracking method based on motion detection and neural networks as described in claim 1, characterized in that, include: Image acquisition module, extraction module, comparison module, and tracking module; The image acquisition module is used to acquire statistical image data of motion detection through a gimbal, perform frame segmentation processing on the statistical image data to obtain an image frame sequence, add timestamps to the image frame sequence to obtain a time-series image frame sequence, calculate a motion frame set based on the time-series image frame sequence through a motion recognition model, and calculate a recognition frame set based on the time-series image frame sequence through a recognition model. The extraction module is used to calculate a target motion frame set based on the motion frame set and the identified frame set using a elimination model, to calculate a motion macroblock set based on the target motion frame set using a motion extraction model, and to calculate a target person based on the target motion frame set using a person extraction model. The comparison module is used to obtain a reference coordinate set based on the motion macroblock set, obtain target coordinates based on the target person, and traverse the reference coordinate set based on the target coordinates to obtain the target macroblock set. The tracking module is used to acquire real-time image frames through the gimbal, calculate a measured macroblock set based on the real-time image frames using the motion extraction model, calculate a shifted macroblock set based on the target macroblock set and the measured macroblock set using a matching algorithm, calculate a rotation angle based on the target macroblock set and the shifted macroblock set using a rotation angle model, and generate an adaptive signal based on the rotation angle to control the gimbal to perform tracking.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the gimbal tracking method based on motion detection and neural networks as described in any one of claims 1-7.
10. A storage medium containing computer-executable instructions, characterized in that, The computer-executable instructions, when executed by a computer processor, are used to perform the gimbal tracking method based on motion detection and neural networks as described in any one of claims 1-7.
Citation Information
Patent Citations
Method for intelligently tracking image on screen by camera
CN102932598A
Tracking shooting method, device and equipment of moving target and storage medium
CN117692755A