CN109685827B - Target detection and tracking method based on DSP - Google Patents
Target detection and tracking method based on DSP Download PDFInfo
- Publication number
- CN109685827B CN109685827B CN201811453586.1A CN201811453586A CN109685827B CN 109685827 B CN109685827 B CN 109685827B CN 201811453586 A CN201811453586 A CN 201811453586A CN 109685827 B CN109685827 B CN 109685827B
- Authority
- CN
- China
- Prior art keywords
- target
- image
- pixel
- wave gate
- template
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/20—Analysis of motion
- G06T7/246—Analysis of motion using feature-based methods, e.g. the tracking of corners or segments
- G06T7/251—Analysis of motion using feature-based methods, e.g. the tracking of corners or segments involving models
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/187—Segmentation; Edge detection involving region growing; involving region merging; involving connected component labelling
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/70—Arrangements for image or video recognition or understanding using pattern recognition or machine learning
- G06V10/74—Image or video pattern matching; Proximity measures in feature spaces
- G06V10/75—Organisation of the matching processes, e.g. simultaneous or sequential comparisons of image or video features; Coarse-fine approaches, e.g. multi-scale approaches; using context analysis; Selection of dictionaries
- G06V10/751—Comparing pixel values or logical combinations thereof, or feature values having positional relevance, e.g. template matching
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/10—Image acquisition modality
- G06T2207/10016—Video; Image sequence
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20024—Filtering details
Landscapes
- Engineering & Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Theoretical Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Physics & Mathematics (AREA)
- Multimedia (AREA)
- Evolutionary Computation (AREA)
- General Health & Medical Sciences (AREA)
- Medical Informatics (AREA)
- Software Systems (AREA)
- Databases & Information Systems (AREA)
- Computing Systems (AREA)
- Artificial Intelligence (AREA)
- Health & Medical Sciences (AREA)
- Image Analysis (AREA)
Abstract
The invention discloses a target detection and tracking method based on DSP, which comprises the following steps: firstly, initializing a wave gate and the size of a background around the wave gate, and setting the position of the wave gate in an image to enable the wave gate to contain a target to be tracked; then, carrying out binarization and filtering processing on the image in the wave gate; then marking the connected domain and determining a target template; then acquiring the position of the target in the next frame of image according to the positions of the targets in the two continuous frames of images; and finally, solving a correlation coefficient between the target and the target template in the next frame of image, and judging whether to continue tracking or stop tracking. The target detection and tracking method has low operation complexity, amplifies the correlation between the target template and the target in the image, ensures the stability of image tracking, has high tracking precision and good real-time property, and can meet the requirement of an image tracking system on the tracking method.
Description
Technical Field
The invention belongs to the technology of image real-time processing and tracking control, in particular to a target detection and tracking method based on a DSP.
Background
Object detection and tracking is a fundamental and important task in applications in the digital video processing and computer vision fields. In some fields with better development prospects, target detection and tracking technologies are needed for robot control, motion-based identification, vision-based control, augmented reality, video scene monitoring and navigation guidance. In the field of computer vision, target detection and tracking are still a highly popular research field. The research focus is also developed towards the industrial application direction with small real-time computation amount by simply pursuing high-precision and high-stability simulation analysis, and the difficulty that how to reduce the requirement on hardware on the premise of meeting the performance index as much as possible is the practical target detection and the research direction tracking. In order to reduce the requirement on hardware, chinese patent CN201010121006.6 proposes a target detection and tracking method based on DSP and a digital image processing system, but the method has a large computation amount and poor versatility and real-time performance, and is difficult to be applied well in the video image processing system using multi-core DSP as the main hardware platform. The method for detecting and tracking the target has the advantages of high precision, low operation complexity and good practicability and is of great significance.
Disclosure of Invention
The invention aims to provide a target detection and tracking method which is low in calculation amount, easy to realize and capable of meeting the requirement of a high-real-time system.
The technical solution for realizing the purpose of the invention is as follows: a target detection and tracking method based on DSP includes the following steps:
step 1, collecting a first frame image in a video;
step 2, initializing the size of a wave gate according to the collected first frame image, then initializing the size of a background around the wave gate according to the size of the wave gate, setting the position of the wave gate in the first frame image to enable the wave gate to contain a target to be tracked, and counting gray level histograms of the wave gate and the background around the wave gate;
step 3, determining a binarization threshold value according to the gray level histogram, and performing binarization processing on the intra-wave gate image according to the threshold value;
step 4, filtering the image in the wave gate after the binarization processing;
step 5, marking each region of the filtered wave gate internal image by using a neighborhood marking algorithm to obtain a plurality of connected regions;
step 6, counting the sizes of all the communicated areas in the step 5, and performing descending order on the sizes of the communicated areas to obtain the minimum external rectangle of the maximum communicated area, and taking the minimum external rectangle as a target template;
step 7, acquiring the center of the maximum communication area, namely the position of the target in the first frame image, then acquiring the position of the target in the second frame image according to the center, and updating the target template;
step 8, acquiring the position of the target in the next frame of image according to the positions of the targets in the two continuous frames of images;
step 9, obtaining a correlation coefficient between the target in the next frame of image and the target template, and judging whether to repeat the step 8 to continue tracking or stop tracking according to the correlation coefficient; if the correlation coefficient Q is larger than or equal to the preset threshold value p, repeating the step 8 to continue tracking; otherwise, increasing the failure times n by 1, judging the relation between n and a failure time preset threshold q, if n is larger than or equal to q, stopping tracking, otherwise, enlarging the size of the wave gate by taking the pixel level as a unit, and repeating the step 8 to continue tracking.
Compared with the prior art, the invention has the following remarkable advantages: 1) the matching efficiency is improved by adopting the diamond search algorithm, and the operation amount can be reduced on the premise of ensuring the search effect; 2) in the invention, the value of the updated weight of the target template is associated with the correlation coefficient, thereby avoiding updating error information into the target template when the tracking effect is poor and ensuring the stability of subsequent image tracking; 3) in the invention, the correlation coefficient is obtained by a mean-time method, and the correlation between the target template and the target in the image is amplified while the calculation amount is reduced.
The present invention will be described in further detail below with reference to the accompanying drawings.
Drawings
FIG. 1 is a flow chart of a DSP-based target detection and tracking method according to the present invention.
Fig. 2 is a schematic diagram of a target to be detected and tracked in a frame image according to an embodiment of the present invention.
Fig. 3 is a schematic diagram of a search template used by using a diamond search algorithm according to an embodiment of the present invention, where fig. 3(a) is a 5 × 5 diamond search template, and fig. 3(b) is a 3 × 3 diamond search template.
Fig. 4 is a schematic diagram illustrating a target tracking result in a frame image according to an embodiment of the present invention.
Detailed Description
Referring to fig. 1, the present invention provides a target detecting and tracking method based on DSP, which includes the following steps:
step 1, collecting a first frame image in a video.
And 2, initializing the size of a wave gate according to the acquired first frame image, then initializing the size of a background around the wave gate according to the size of the wave gate, setting the position of the wave gate in the first frame image to enable the wave gate to contain the target to be tracked, and counting gray level histograms of the wave gate and the background around the wave gate.
Further, initializing the size of the wave gate according to the acquired first frame image, specifically: initializing the size of a wave gate according to the size of the first frame image and the size of a target to be tracked in the image, assuming that the size of the acquired image is w × h, the size of the minimum circumscribed rectangle of the target to be tracked is x × y, and the size of the wave gate is w '× h', wherein x is more than w 'and less than w', and y is more than h 'and less than h';
further, the size of the background around the wave gate is determined according to the size of the wave gate, and the method specifically comprises the following steps: the boundary of the wave gate is extended by a few pixels.
And 3, determining a binarization threshold value according to the gray level histogram, and performing binarization processing on the intra-wave gate image according to the threshold value.
Further, determining a binarization threshold according to the gray level histogram, specifically: and taking the gray value corresponding to the valley between two peaks representing the target to be tracked and the background thereof in the gray histogram as a binary threshold value.
And 4, filtering the binarized image in the wave gate.
Further, the filtering process specifically adopts an on operation process.
And 5, marking each region of the filtered wave gate internal image by using a neighborhood marking algorithm to obtain a plurality of connected regions.
Further, each region of the image in the filtered wave gate is marked by using a neighborhood marking algorithm, wherein the neighborhood marking algorithm specifically comprises the following steps:
pixel-by-pixel scanning is carried out on the filtered image in the wave gate from left to right and from top to bottom until all pixels of the image in the wave gate are scanned, and if the value of the currently scanned pixel is 0, the image is directly moved to the next pixel; if the currently scanned pixel value is 1, marking according to the left pixel and the upper pixel of the current pixel, where the size of the marking value increases with the appearance of a new connected domain, specifically including the following 4 cases:
(1) the pixel values of the left side and the upper side are both 0, which indicates that the currently scanned pixel is the boundary of a new connected domain, and a new mark value is given to the currently scanned pixel;
(2) if only one pixel value of 1 exists in the left side pixel value and the upper side pixel value, the marking value which is the same as the marking value of the pixel with the pixel value of 1 is given to the current scanned pixel;
(3) if the left and upper pixel values are both 1 and the marking values are the same, giving the marking value of the current scanned pixel which is the same as the marking value;
(4) if the left and upper pixel values are both 1 but the flag values are different, the flag value assigned to the currently scanned pixel is the smallest flag value among the flag values.
And 6, counting the sizes of all the connected regions in the step 5, performing descending order arrangement on the sizes of the connected regions, acquiring the minimum external rectangle of the maximum connected region, and taking the minimum external rectangle as a target template.
And 7, acquiring the center of the maximum communication area, namely the position of the target in the first frame image, then acquiring the position of the target in the second frame image according to the center, and updating the target template.
Further, the position of the target in the second frame image is obtained according to the center of the maximum connected region, specifically:
step 7-1, moving the center of the wave gate to the center of the maximum communication area;
and 7-2, matching the intra-wave gate image with the target template through a template matching algorithm to obtain the position of the target in the second frame image.
Further, the template matching algorithm in step 7-2 specifically adopts a diamond search algorithm.
Further, updating the target template specifically includes:
suppose T k Target template, T, for template matching for the kth frame image k+1 For the updated target template used for template matching of the (k + 1) th frame image, the formula for updating the target template is as follows:
in the formula, M k For passing the template in the k frame imageTarget template T which is obtained by matching algorithm and takes target position as center and template size as coverage range k The best match, α is the update weight, c max Correlation coefficient, τ, output for template matching t The threshold value for updating the set target template is obtained by the formula when the correlation coefficient c is higher than the threshold value max Greater than a threshold τ t And if not, the target template is updated, and otherwise, the target template is kept unchanged.
And 8, acquiring the position of the target in the next frame of image according to the positions of the targets in the two continuous frames of images.
Further, the position of the target in the next frame of image is obtained according to the positions of the target in the two consecutive frames of images, which specifically comprises:
step 8-1, processing the positions of the targets in two continuous frames of images by using a least square method, thereby obtaining the area of the target in the next frame of image;
and 8-2, moving the wave gate to the center of the region, and performing template matching on the image in the wave gate and the updated target template to obtain the position of the target in the current frame image.
And 9, obtaining a correlation coefficient between the target in the next frame of image and the target template, and judging whether to repeat the step 8 to continue tracking or stop tracking according to the correlation coefficient.
Further, step 9 obtains a correlation coefficient between the target in the next frame of image and the target template, and determines whether to repeat step 8 to continue tracking or stop tracking according to the correlation coefficient, specifically:
step 9-1, taking the position of the target in the next frame of image in the step 8 as a center, and intercepting an area with the same size as the target template as the target in the next frame of image;
step 9-2, a correlation coefficient Q between the target in the next frame of image and the target template is obtained, and the formula is as follows:
in the formula, x i In the target templateThe gray value of the i-th pixel,is the pixel gray level mean, y, of the target template i Is the gray value of the ith pixel in the object in the image,is the pixel gray level mean of the target in the image;
9-3, judging the relation between the correlation coefficient Q and a preset threshold value p, and if Q is more than or equal to p, repeating the step 8 to continue tracking; otherwise, increasing the failure times n by 1, and executing the step 9-4; wherein the initial value of the failure times n is 0;
and 9-4, judging the relation between n and a preset threshold q of failure times, stopping tracking if n is more than or equal to q, otherwise, enlarging the size of a wave gate by taking the pixel level as a unit, and repeating the step 8 to continue tracking.
Examples
With reference to fig. 1, the target detection and tracking method based on DSP of the present invention includes the following steps:
1. initializing the size of the wave gate and the size of the background around the wave gate
The size of the wave gate is determined by the size of the acquired image and the size of the target, and the main requirement is that the wave gate can completely mark the position of the target. As shown in fig. 2, a certain frame of image collected in this embodiment has a size of 1600 pixels by 900 pixels, a target size in the image is 80 pixels by 60 pixels, a size of a gate is set to 120 pixels by 120 pixels, and a size of a background around the gate is set to 120 pixels by 30 pixels.
2. Determining a binarization threshold
And (4) counting the wave gates and the gray level histograms of the backgrounds around the wave gates to obtain a histogram with bimodal distribution, and selecting the gray level 20 corresponding to the valleys between the wave gates as a binarization threshold.
3. Binary wave gate internal image
And (3) carrying out binarization processing on the intra-wave gate image according to the determined binarization threshold value as follows:
wherein f (x, y) is the original gray value of the pixel in the wave gate, f T (x, y) is the gray value of the pixel inside the wave gate after processing.
4. Filtering the binarized image in the gate
And adopting an open operation process, specifically, scanning each pixel in the image by using a structural element with the size of 3 × 3, and performing AND on each pixel in the structural element and the pixel covered by the pixel, wherein if the pixel is 0, and otherwise, the pixel is 1. And scanning each pixel in the image by using the structural elements with the size of 3 multiplied by 3, and AND-ing each pixel in the structural elements and the pixels covered by the structural elements, wherein if the structural elements are all 1, the pixel is 1, and otherwise, the pixel is 0.
5. Marking each region of the filtered images in the wave gate by using a neighborhood marking algorithm to obtain a plurality of connected regions;
6. counting the sizes of all marked connected regions, and performing descending order arrangement on the sizes of the connected regions to obtain a circumscribed rectangle of the largest connected region, wherein the circumscribed rectangle is used as a target template;
7. and acquiring the center of the maximum connected region, namely the position of the target in the first frame image, and acquiring the position of the target in the second frame image according to the center by adopting a diamond search algorithm. The specific operation is as follows:
and taking the template image and the target image as output, finding the optimal area where the target is located by using a large diamond search algorithm, taking the position as the central position of small diamond search, and finding the accurate position of the target by using a small diamond search algorithm. The search template used by the large diamond search algorithm is a 5 × 5 size template, the search template used by the small diamond search algorithm is a 3 × 3 size template, and the large diamond search template and the small diamond search template are shown in fig. 3. The diamond search algorithm repeatedly uses the diamond search template to search until the point with the minimum search error appears in the center of the template, and the obtained point with the minimum search error is the best matching point.
8. Target template updating method
Wherein T is k Target template, T, for template matching for the kth frame image k+1 Target template for template matching of updated image of frame k +1, M k A target template T which is obtained by a template matching algorithm in the kth frame image and takes the target position as the center and the size of the template as the coverage range k The best match. Alpha is the update weight, c max In this embodiment, α is 0.1c for the correlation coefficient of the template matching output max ,τ t To set the threshold value for updating the target template, τ in this embodiment t 0.75, when the correlation coefficient c max Greater than a threshold τ t And if not, the target template is updated, and otherwise, the target template is kept unchanged.
9. Acquiring the position of the target in the next frame of image according to the positions of the targets in the two continuous frames of images;
and calculating the area of the target in the next frame of image by using the positions of the target in the first two frames of images and adopting a least square method. The least squares formulation is as follows:
y=ax+b
wherein a is the slope of the fitted curve, b is the intercept of the fitted curve, x is the pixel coordinate in the horizontal direction of the target, y is the pixel coordinate in the vertical direction of the target,is the pixel coordinate mean value of the horizontal direction of the target in the first two frames,is the pixel coordinate mean value in the vertical direction of the target.
10. And moving the wave gate to the center of the area where the target is located, and performing template matching on the image in the wave gate and the updated target template of the previous frame to obtain the position of the target in the image of the current frame.
11. Calculating a correlation coefficient between the target in the image and the target template by the formula:
in the formula, x i Is the gray value of the ith pixel in the target template,is the pixel gray level mean, y, of the target template i Is the gray value of the ith pixel in the object in the image,is the pixel gray level mean of the target in the image; correlation coefficient Q E [ -1,1 [ ]]And the larger Q, the higher the correlation.
12. Judging the relation between the correlation coefficient and the set threshold
In this embodiment, a preset threshold p of a correlation coefficient is set to 0.75, a preset threshold Q of failure times is set to 50, a relationship between the correlation coefficient Q and the preset threshold p is judged, if Q is greater than or equal to p, a failure count is cleared, tracking is continued, and a target tracking result is shown in fig. 4; if Q is less than p, the failure count n is increased by 1, the relation between n and a failure time preset threshold Q is judged, if n is more than or equal to Q, tracking is stopped, if n is less than Q, the wave gate is expanded to 180 pixels by 180 pixels, and tracking is continued.
The target detection and tracking method based on the DSP has low operation complexity, amplifies the correlation between the target template and the target in the image, ensures the stability of image tracking, has high tracking precision and good real-time performance, and can meet the requirement of an image tracking system on the tracking method.
Claims (10)
1. A target detection and tracking method based on DSP is characterized by comprising the following steps:
step 1, collecting a first frame image in a video;
step 2, initializing the size of a wave gate according to the collected first frame image, then initializing the size of a background around the wave gate according to the size of the wave gate, setting the position of the wave gate in the first frame image to enable the wave gate to contain a target to be tracked, and counting gray level histograms of the wave gate and the background around the wave gate;
step 3, determining a binarization threshold value according to the gray level histogram, and performing binarization processing on the intra-wave gate image according to the threshold value;
step 4, filtering the image in the wave gate after the binarization processing;
step 5, marking each region of the filtered wave gate internal image by using a neighborhood marking algorithm to obtain a plurality of connected regions;
step 6, counting the sizes of all the communicated areas in the step 5, and performing descending order on the sizes of the communicated areas to obtain the minimum external rectangle of the maximum communicated area, and taking the minimum external rectangle as a target template;
step 7, acquiring the center of the maximum communication area, namely the position of the target in the first frame of image, then acquiring the position of the target in the second frame of image according to the center, and updating the target template;
step 8, acquiring the position of the target in the next frame of image according to the positions of the targets in the two continuous frames of images;
step 9, obtaining a correlation coefficient between the target in the next frame of image and the target template, and judging whether to repeat the step 8 to continue tracking or stop tracking according to the correlation coefficient; if the correlation coefficient Q is larger than or equal to the preset threshold value p, repeating the step 8 to continue tracking; otherwise, increasing the failure times n by 1, judging the relation between n and a failure time preset threshold q, if n is larger than or equal to q, stopping tracking, otherwise, enlarging the size of the wave gate by taking the pixel level as a unit, and repeating the step 8 to continue tracking.
2. The DSP-based target detecting and tracking method of claim 1, wherein in step 1:
the initializing of the size of the wave gate according to the acquired first frame image specifically comprises: initializing the size of a wave gate according to the size of the first frame image and the size of an object to be tracked in the image,
assuming that the size of the acquired image is w x h, the size of the minimum external rectangle of the target to be tracked is x y, and the size of a wave gate is w '× h', wherein x is more than w 'and less than or equal to w, and y is more than h' and less than or equal to h;
the method is characterized in that the size of the background around the wave gate is determined according to the size of the wave gate, and specifically comprises the following steps: the boundary of the gate is extended by a few pixels.
3. The DSP-based target detecting and tracking method according to claim 1 or 2, wherein the determining the binarized threshold value according to the histogram of gray scale in step 3 is specifically: and taking the gray value corresponding to the valley between two peaks representing the target to be tracked and the background thereof in the gray histogram as a binary threshold value.
4. The DSP-based object detection and tracking method according to claim 3, wherein the filtering process in step 4 is specifically an on-operation process.
5. The DSP-based target detecting and tracking method of claim 1, wherein step 5 comprises labeling each region of the image within the filtered wave gate with a neighborhood labeling algorithm, wherein the neighborhood labeling algorithm specifically is:
pixel-by-pixel scanning is carried out on the filtered image in the wave gate from left to right and from top to bottom until all pixels of the image in the wave gate are scanned, and if the value of the currently scanned pixel is 0, the image is directly moved to the next pixel; if the currently scanned pixel value is 1, marking according to the left pixel and the upper pixel of the current pixel, where the size of the marking value increases with the appearance of a new connected domain, specifically including the following 4 cases:
(1) the pixel values of the left side and the upper side are both 0, which indicates that the currently scanned pixel is the boundary of a new connected domain, and a new mark value is given to the currently scanned pixel;
(2) if only one pixel value of the left side pixel value and the upper side pixel value is 1, giving a mark value which is the same as the mark value of the pixel with the pixel value of 1 to the currently scanned pixel;
(3) if the left side pixel value and the upper side pixel value are both 1 and the marking values are the same, giving the marking value which is the same as the marking value to the currently scanned pixel;
(4) if the left and upper pixel values are both 1 but the flag values are different, the flag value assigned to the currently scanned pixel is the smallest of the flag values.
6. The DSP-based target detecting and tracking method according to claim 1, wherein the step 7 of obtaining the position of the target in the second frame image according to the center of the maximum connected area specifically comprises:
7-1, moving the center of the wave gate to the center of the maximum communication area;
and 7-2, matching the images in the wave gate with the target template through a template matching algorithm to obtain the position of the target in the second frame of image.
7. The DSP-based target detection and tracking method according to claim 6, wherein the template matching algorithm in step 7-2 specifically employs a diamond search algorithm.
8. The DSP-based target detecting and tracking method of claim 7, wherein the step 7 of updating the target template specifically comprises:
suppose T k Target template for template matching for the k frame image, T k+1 For the updated target template used for template matching of the (k + 1) th frame image, the formula for updating the target template is as follows:
in the formula, M k A target template T which is obtained by a template matching algorithm in the kth frame image and takes a target position as a center and the size of the template as a coverage range k Is the best match, alpha is the update weight, c max Correlation coefficient, τ, output for template matching t The threshold value for updating the set target template is obtained by the formula when the correlation coefficient c is higher than the threshold value max Greater than a threshold τ t And if not, the target template is updated, and otherwise, the target template is kept unchanged.
9. The DSP-based target detecting and tracking method according to claim 1, wherein the step 8 of obtaining the position of the target in the next frame of image according to the positions of the targets in the two consecutive frames of images specifically comprises:
step 8-1, processing the positions of the targets in two continuous frames of images by using a least square method, thereby obtaining the area of the target in the next frame of image;
and 8-2, moving the wave gate to the center of the area, and performing template matching on the image in the wave gate and the updated target template to obtain the position of the target in the current frame image.
10. The DSP-based target detecting and tracking method according to claim 1, wherein the step 9 of obtaining a correlation coefficient between the target in the next frame image and the target template, and determining whether to repeat the step 8 to continue tracking or stop tracking according to the correlation coefficient specifically comprises:
step 9-1, taking the position of the target in the next frame of image in the step 8 as a center, and intercepting an area with the same size as the target template as the target in the next frame of image;
step 9-2, calculating a correlation coefficient Q between the target in the next frame of image and the target template, wherein the formula is as follows:
in the formula, x i Is the gray value of the ith pixel in the target template,is the pixel gray level mean, y, of the target template i Is the gray value of the ith pixel in the object in the image,is the pixel gray level mean of the target in the image;
9-3, judging the relation between the correlation coefficient Q and a preset threshold value p, and if Q is more than or equal to p, repeating the step 8 to continue tracking; otherwise, increasing the failure times n by 1, and executing the step 9-4; wherein the initial value of the failure times n is 0;
and 9-4, judging the relation between n and a preset threshold q of failure times, stopping tracking if n is more than or equal to q, otherwise, enlarging the size of a wave gate by taking the pixel level as a unit, and repeating the step 8 to continue tracking.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811453586.1A CN109685827B (en) | 2018-11-30 | 2018-11-30 | Target detection and tracking method based on DSP |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811453586.1A CN109685827B (en) | 2018-11-30 | 2018-11-30 | Target detection and tracking method based on DSP |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109685827A CN109685827A (en) | 2019-04-26 |
CN109685827B true CN109685827B (en) | 2022-09-06 |
Family
ID=66185165
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811453586.1A Active CN109685827B (en) | 2018-11-30 | 2018-11-30 | Target detection and tracking method based on DSP |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109685827B (en) |
Families Citing this family (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110543809A (en) * | 2019-06-24 | 2019-12-06 | 台州宏达电力建设有限公司 | Electric power operation site risk supervision intrusion video identification method |
CN111145218B (en) * | 2019-12-30 | 2023-04-07 | 华南理工大学 | Mini-LED chip precision positioning method based on YOLO algorithm |
CN110930428B (en) * | 2020-02-19 | 2020-08-14 | 成都纵横大鹏无人机科技有限公司 | Target tracking method and device, electronic equipment and storage medium |
CN112199972A (en) * | 2020-10-28 | 2021-01-08 | 普联技术有限公司 | Method for identifying positioning point |
CN118120222A (en) * | 2022-09-29 | 2024-05-31 | 京东方科技集团股份有限公司 | Method, system and electronic device for detecting camera interference |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102831617A (en) * | 2012-07-17 | 2012-12-19 | 聊城大学 | Method and system for detecting and tracking moving object |
CN106296725A (en) * | 2015-06-12 | 2017-01-04 | 富泰华工业(深圳)有限公司 | Moving target detects and tracking and object detecting device in real time |
-
2018
- 2018-11-30 CN CN201811453586.1A patent/CN109685827B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102831617A (en) * | 2012-07-17 | 2012-12-19 | 聊城大学 | Method and system for detecting and tracking moving object |
CN106296725A (en) * | 2015-06-12 | 2017-01-04 | 富泰华工业(深圳)有限公司 | Moving target detects and tracking and object detecting device in real time |
Also Published As
Publication number | Publication date |
---|---|
CN109685827A (en) | 2019-04-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109685827B (en) | Target detection and tracking method based on DSP | |
WO2021196294A1 (en) | Cross-video person location tracking method and system, and device | |
CN102184550B (en) | Mobile platform ground movement object detection method | |
CN109726717B (en) | Vehicle comprehensive information detection system | |
CN104217427B (en) | Lane line localization method in a kind of Traffic Surveillance Video | |
CN109949340A (en) | Target scale adaptive tracking method based on OpenCV | |
CN111444778B (en) | Lane line detection method | |
CN109086724B (en) | Accelerated human face detection method and storage medium | |
CN102096821A (en) | Number plate identification method under strong interference environment on basis of complex network theory | |
CN107480603B (en) | Synchronous mapping and object segmentation method based on SLAM and depth camera | |
CN104036523A (en) | Improved mean shift target tracking method based on surf features | |
CN105160649A (en) | Multi-target tracking method and system based on kernel function unsupervised clustering | |
TW202121331A (en) | Object recognition system based on machine learning and method thereof | |
CN113763427B (en) | Multi-target tracking method based on coarse-to-fine shielding processing | |
CN104715251A (en) | Salient object detection method based on histogram linear fitting | |
CN103714547A (en) | Image registration method combined with edge regions and cross-correlation | |
CN111415374A (en) | KVM system and method for monitoring and managing scenic spot pedestrian flow | |
CN109146918A (en) | A kind of adaptive related objective localization method based on piecemeal | |
CN113077494A (en) | Road surface obstacle intelligent recognition equipment based on vehicle orbit | |
CN107045630B (en) | RGBD-based pedestrian detection and identity recognition method and system | |
CN113989308B (en) | Polygonal target segmentation method based on Hough transformation and template matching | |
Hernández et al. | Lane marking detection using image features and line fitting model | |
CN101908150B (en) | Human body detection method | |
CN114333023A (en) | Face gait multi-mode weighting fusion identity recognition method and system based on angle estimation | |
Wang et al. | Lane detection algorithm based on density clustering and RANSAC |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |