Low-power-consumption bird tracking method and device
By combining the multi-dimensional feature space and dynamic update strategy of HOG and ASMS algorithms, the problems of background interference and target occlusion in bird tracking are solved, and the robustness and accuracy of tracking are improved, and suitable for low-performance hardware platforms.
Patent Information
- Application Number
- CN202411426122.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-14
- Publication Date
- 2024-11-12
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The prior art is susceptible to background interference in bird tracking, difficult to deal with target occlusion and rapid movement, and has limited ability to adapt to complex background changes, resulting in tracking offsets and target loss.
Combined with the HOG algorithm, the gradient direction histogram of the target area and the color histogram of the ASMS algorithm are extracted, and a multi-dimensional feature space is formed for target modeling and tracking, and the matching degree is calculated by dynamically updating the color histogram and normalized correlation coefficient method TM_CCOEFF, and optimized Tracking effects.
Improves the robustness and accuracy of bird tracking, can effectively handle image deformation and fast moving targets, reduces the possibility of target loss, and is suitable for low-performance hardware platforms.
Smart Images

Figure CN118941807A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to a bird tracking method, and in particular to a low-power-consumption bird tracking method and device. Background Art
[0002] The bird-repelling technology of power grids mainly stems from the bird interference problem faced by power systems. With the expansion of power grid coverage, it is becoming more and more common for birds to nest, roost and move on power facilities. However, this behavior can easily cause birds to touch the wires, causing accidents such as short circuits and tripping, which not only endangers the lives of birds, but also seriously affects the operational stability of the power grid. In addition, the accumulation of bird droppings and nesting materials can also damage equipment. In order to solve this problem, various bird-repelling measures are adopted, such as installing bird-repelling devices and using sound and light bird-repelling technology, to ensure the safe operation of the power grid and reduce power accidents caused by bird damage. At present, the price of bird-repelling equipment in the industry is expensive, and the bird-repelling business is difficult to be widely rolled out. If low-performance arm boards are considered, the commonly used algorithms do not have high-performance real-time tracking and striking performance, and the ability to disperse birds is weak, and it cannot effectively maintain the safety of the power grid for a long time.
[0003] Tracking low-performance arm-board moving targets has always been a difficult and hot issue in the field of machine vision research. There are many challenges and problems in the process of bird tracking using common algorithms, such as deformation of birds and excessive flying speed of birds.
[0004] The tracking algorithm of the kernel correlation filter algorithm KCF has the following disadvantages: First, it is easily affected by background interference: KCF only uses local image feature information to track the target. For scenes where the target and background features are similar (such as backgrounds with similar colors or textures), mistracking or drift problems may occur.
[0005] Secondly, KCF does not provide a good solution to the problem of handling when the target is occluded during the tracking process.
[0006] Third, the KCF tracking algorithm is a tracking algorithm for grayscale images and is not sensitive to color. Therefore, KCF does not have the ability to resist rotation and deformation.
[0007] The ASMS tracking algorithm based on the Meanshift algorithm also has the following problems: First, the ASMS algorithm performs poorly on fast-moving targets. When dealing with fast-moving targets, it may be difficult for the ASMS algorithm to update the model and view similarity in a timely manner, which can lead to tracking deviation or target loss.
[0008] Second, the ability to adapt to complex background changes is limited. Although ASMS is somewhat robust to background noise, its tracking effect may decline when the background changes rapidly and complexly, because the structural similarity modeling may not be able to fully adapt to the dynamically changing background.
[0009] Third, the initial target frame is highly dependent, and the ASMS algorithm relies on the accuracy of the initial target frame. If the initial target frame is inaccurate or the target is mislabeled, it may be difficult for the algorithm to track effectively. Summary of the invention
[0010] Purpose of the invention: In view of the above problems, the present invention proposes a low-power bird tracking method and device, which effectively improves the efficiency and accuracy of the tracking algorithm, solves the tracking offset and target loss problems caused by bird deformation and excessive flight speed, is suitable for low-power tracking of CPU, and can be easily deployed on low-performance boards to achieve bird tracking.
[0011] Technical solution: The technical solution adopted by the present invention is a low-power bird tracking method, including: using the HOG algorithm to extract features of the target area in the current frame; combining the features obtained by the HOG algorithm with the color histogram in the ASMS tracking algorithm to obtain a multidimensional feature space, and modeling and tracking the target in the multidimensional feature space; dynamically updating the color histogram during the target tracking process; during the target tracking process, calculating the template image template by combining the similarity calculated by the color information and the similarity calculated by the features obtained by the HOG algorithm; recording the template image template during the target tracking process, and judging whether the target is lost, if it is judged to be lost, calculating the matching degree between the template image and the subsequent frame image by the normalized correlation coefficient method TM_CCOEFF, and re-updating the template image to continue tracking if the matching degree meets the threshold.
[0012] The feature obtained by the HOG algorithm is a gradient direction histogram of the target area in the current frame.
[0013] The color histogram is dynamically updated during the target tracking process, and the update calculation formula is: , in, Indicates updated color histogram data, alpha indicates control of the current frame color histogram data The weight of beta is the weight of the color histogram data data[i] of the current template image of the tracked object. The formula represents the features of the tracked object that the tracker needs to continuously update, each time integrating the data of the current frame into the data in a weighted manner.
[0014] According to the shape stability of the tracking target and the speed of change of the tracking target, adjust the alpha value to optimize the tracking effect.
[0015] The template image template is calculated by combining the similarity calculated by the color information and the similarity calculated by the features obtained by the HOG algorithm, including: weighted summing the Bhattacharyya distance of the color histogram and the similarity score of the features obtained by the HOG algorithm, and selecting the template template according to the summation result.
[0016] The normalized correlation coefficient method TM_CCOEFF includes: calculating the mean of the product of the pixel values of the two images at a certain position, subtracting the product of the respective mean values of the pixel values of the two images at a certain position, and then normalizing.
[0017] The color histogram is a color histogram in an RGB space or a color histogram in an HSV space.
[0018] The present invention provides a low-power bird tracking device, comprising a memory, a processor and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the low-power bird tracking method is implemented.
[0019] The present invention provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the low-power consumption bird tracking method is implemented.
[0020] The present invention provides a computer program product, comprising a computer program and / or instructions, which implement the low-power bird tracking method when executed by a processor.
[0021] Beneficial effects: Compared with the prior art, the present invention has the following advantages: The present invention combines HOG features with color histograms (usually color histograms in HSV space) to form a multidimensional feature space, models and tracks targets in this new space, and dynamically updates the color histogram in the target tracking algorithm, thereby solving the tracking offset caused by image deformation during bird flight and improving robustness. The present invention not only uses color information to calculate similarity, but also combines HOG features to calculate the target similarity between two frames. The HOG algorithm obtains the gradient direction histogram of the target area in the current frame. The combination of the two provides texture and shape information of the target, and has better robustness to illumination changes and color changes. The present invention records the features of the template before loss, and calculates the matching degree by the normalized correlation coefficient method (cv::TM_CCOEFF) when it is determined that the target is lost, thereby solving the problem of target loss caused by the excessively fast flying speed of birds. The present invention can be applied to target tracking in various scenarios, including but not limited to power grid / farmland bird driving, high-altitude drone positioning, and various mobile target tracking. The invention can stably track targets with deformation and fast movement. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] Figure 1 It is a flow chart of the post-loss re-supplement strategy of the low-power bird tracking method described in the present invention. DETAILED DESCRIPTION
[0023] The technical solution of the present invention is further described below in conjunction with the accompanying drawings and embodiments.
[0024] The low-power bird tracking method of the present invention integrates the HOG (Histogram of Oriented Gradients) feature into the ASMS (Adaptive Scale Mean-Shift) algorithm, which can improve the robustness and accuracy of the tracking algorithm, especially when the texture features of the target are relatively complex or the color information changes greatly. Specifically, it includes: using the HOG algorithm to extract features of the target area in the current frame; combining the features obtained by the HOG algorithm with the color histogram in the ASMS tracking algorithm to obtain a multidimensional feature space, and modeling and tracking the target in the multidimensional feature space; dynamically updating the color histogram during the target tracking process; during the target tracking process, combining the similarity calculated by the color information and the similarity calculated by the features obtained by the HOG algorithm to calculate the template image template; during the target tracking process, the template image template is recorded and it is determined whether the target is lost. If it is determined to be lost, the matching degree between the template image and the subsequent frame image is calculated by the normalized correlation coefficient method TM_CCOEFF, and the template image is updated again to continue tracking if the matching degree meets the threshold.
[0025] The following are detailed descriptions: 1. HOG feature extraction.
[0026] The HOG algorithm is used to extract features from the target area in the current frame and obtain the gradient direction histogram. The features obtained by the HOG algorithm can provide texture and shape information of the target and have better robustness to changes in illumination and color.
[0027] 2. Feature combination.
[0028] The features obtained by the HOG algorithm are combined with the color histogram (usually the color histogram of RGB or HSV space) to form a multi-dimensional feature space. The target is modeled and tracked in this new space.
[0029] 3. Dynamically update the histogram weighted values.
[0030] Dynamically update the color histogram in the target tracking algorithm to adapt to changes in the target's appearance. When using the ASMS (Adaptive Scale Mean-Shift) tracking algorithm, the target may change its appearance over time, so a mechanism is needed to gradually update the model (i.e., histogram) to track appearance changes.
[0031] One of the update logic is: For each element of the current histogram data, perform an update: , in, Indicates updated color histogram data, alpha indicates control of the current frame color histogram data The weight of beta represents the weight of the color histogram data data[i] of the current template image of the tracked object. ,This update formula implements an exponentially weighted moving average (EWMA), where alpha controls the weight of new data hist and beta controls the weight of old data. Therefore, the alpha value can be adjusted to optimize the tracking effect according to the stability of tracking and the speed of target change.
[0032] When alpha is larger, it relies more on the new histogram data hist and has less weight on the original data, which helps to quickly adapt to new changes.
[0033] When alpha is small (such as close to 0), it mainly relies on the original histogram data and responds slowly to changes in new data.
[0034] 4. Target similarity calculation.
[0035] In the ASMS tracking process, not only the color information is used to calculate the similarity, but also the features obtained by the HOG algorithm are used to calculate the target similarity between the two frames. The Bhattacharyya distance (Bhattacharyya coefficient) of the color histogram and the similarity score of the features obtained by the HOG algorithm can be weighted and combined. The current weighting strategy is as follows: , factor is the weighted value set. The larger the weighted value, the more it tends to ASMS tracking, and the smaller the weighted value, the more it tends to hog feature tracking. Sim represents the similarity of the template image between the two frames, color represents the similarity of color information, and hog represents the similarity of HOG features.
[0036] 5. Strategy for re-supplement after loss.
[0037] Record the features of the template before the loss, because ASMS can effectively determine the tracking state. When the target is lost, the normalized correlation coefficient method (cv::TM_CCOEFF) is used to calculate the mean of the product of the pixel values of the template image and the source image at a certain position, subtract the product of their respective means, and then normalize. The larger the return value, the better the match. For details of this method, see the opencv matchTemplate function. The specific process is as follows Figure 1 shown.
[0038] In one embodiment, a low-power bird tracking device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the above-mentioned low-power bird tracking method when executing the computer program.
[0039] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the low-power bird tracking method described above is implemented.
[0040] In one embodiment, a computer program product is provided, comprising a computer program / instruction, which implements the low-power bird tracking method when executed by a processor.
[0041] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.
[0042] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0043] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0044] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
Claims
1. A low-power bird tracking method, characterized in that: include: Use the Histogram of Directed Gradients (HOG) algorithm to extract features from the target area in the current frame; The features obtained by the HOG algorithm are combined with the color histogram in the scale-adaptive meanshift algorithm ASMS tracking algorithm to obtain a multidimensional feature space, in which the target is modeled and tracked; the color histogram is dynamically updated during the target tracking process; In the target tracking process, the template image template is calculated by combining the similarity calculated by color information and the similarity calculated by features obtained by the HOG algorithm; During the target tracking process, the template image template is recorded and it is determined whether the target is lost. If it is lost, the normalized correlation coefficient method TM_CCOEFF is used to calculate the matching degree between the template image and the subsequent frame image. If the matching degree meets the threshold, the template image is updated again to continue tracking.
2. The low-power bird tracking method according to claim 1, characterized in that: The feature obtained by the HOG algorithm is a gradient direction histogram of the target area in the current frame.
3. The low-power bird tracking method according to claim 1, characterized in that: The color histogram is dynamically updated during the target tracking process, and the update calculation formula is: , in, represents the updated color histogram data, represents the color histogram data of the current frame, alpha represents the weight of controlling the color histogram data of the current frame, data[i] represents the color histogram data of the current template image of the tracked object, beta represents the weight of controlling the color histogram data of the current template image of the tracked object, .
4. The low-power bird tracking method according to claim 3, characterized in that: According to the shape stability of the tracking target and the speed of change of the tracking target, adjust the alpha value to optimize the tracking effect.
5. The low-power bird tracking method according to claim 1, characterized in that: The template image template is calculated by combining the similarity calculated by the color information and the similarity calculated by the features obtained by the HOG algorithm, including: weighted summing the Bhattacharyya distance of the color histogram and the similarity score of the features obtained by the HOG algorithm, and selecting the template template according to the summation result.
6. The low-power bird tracking method according to claim 1, characterized in that: The normalized correlation coefficient method TM_CCOEFF includes: calculating the mean of the product of the pixel values of the two images at a certain position, subtracting the product of the respective mean values of the pixel values of the two images at a certain position, and then normalizing.
7. The low-power bird tracking method according to claim 1, characterized in that: The color histogram is a color histogram in an RGB space or a color histogram in an HSV space.
8. A low-power bird tracking 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 computer program, the low-power bird tracking method according to any one of claims 1 to 7 is implemented.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the low-power bird tracking method according to any one of claims 1 to 7 is implemented.
10. A computer program product comprising a computer program and / or instructions, characterized in that: When the computer program and / or the instruction is executed by a processor, the low-power bird tracking method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Grey wolf optimization particle filter target tracking algorithm based on feature fusion
CN112184762A
Target detection and tracking method and target detection and tracking device
CN112949588A
Single-target vehicle tracking method based on aerial photography of unmanned aerial vehicle
CN114529584A
Anti-occlusion target tracking algorithm based on correlation filtering Staple algorithm
CN117934548A
