Target tracking method, device and computer system
By predicting the scale change trend of the target and adjusting the number of scaling search areas, the problems of large calculation volume and low accuracy caused by scale transformation in the prior art are solved, and more efficient and accurate target tracking is achieved.
Patent Information
- Application Number
- CN201910865797.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2019-09-12
- Publication Date
- 2025-01-07
- Estimated Expiration
- 2039-09-12
AI Technical Summary
In the prior art, in visual target tracking, the scale transformation problem leads to huge calculations, making it difficult to quickly and accurately predict the scale changes of the target, affecting the tracking accuracy.
By predicting the target's scale change trend relative to the previous frame in the current frame, the number of scaling search areas for the opposite trend is reduced, and a larger weight factor is assigned to the sample groups in the same scaling direction as the change trend to improve Accuracy of match.
It reduces the time complexity of target tracking, improves tracking accuracy and accuracy, and reduces the complexity brought by ROI of invalid scales.
Smart Images

Figure CN112489077B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of target tracking technology, and in particular to a target tracking method, device and computer system. Background Art
[0002] Visual object tracking is an important research direction in computer vision and has a wide range of applications, such as video surveillance, human-computer interaction (for example, interactive games based on gestures and facial expressions), unmanned driving, etc.
[0003] The visual target (single target) tracking task is to predict the size and position of the target in the subsequent frames given the target size and position of the initial frame of a certain image sequence. This basic task process can be divided into the following framework: input the initial target frame, generate many candidate frames in the next frame, extract the features of these candidate frames, and then score these candidate frames. Finally, find the candidate frame with the highest score among these scores as the predicted target, or fuse multiple prediction values to obtain a better predicted target.
[0004] Visual motion target tracking is a very challenging task, because for moving targets, the moving scenes are very complex and often change, or the targets themselves are constantly changing. So how to identify and track the constantly changing targets in complex scenes becomes a challenging task.
[0005] Among them, scale variation is the phenomenon of the scale change of the target from far to near or from near to far during the movement process. This makes predicting the size of the target box one of the challenges in target tracking. How to quickly and accurately predict the scale variation coefficient of the target directly affects the tracking accuracy. The usual practice in the prior art is: when the motion model generates candidate samples, a large number of candidate boxes of different scales are generated, or target tracking is performed on multiple targets of different scales to generate multiple prediction results, and the best one is selected as the final prediction target.
[0006] However, in the process of solving the above-mentioned scale transformation problem, the existing technology has problems such as huge amount of calculation. Therefore, how to solve the scale transformation problem with less calculation amount in the target tracking process has become a technical problem that needs to be solved by those skilled in the art. Summary of the invention
[0007] The present application provides a target tracking method, device and computer system, which can reduce the time complexity of target tracking.
[0008] This application provides the following solutions:
[0009] A target tracking method, comprising:
[0010] In the process of tracking the target in the image sequence, the scale change trend of the target in the current frame relative to the previous frame is predicted;
[0011] When generating a zoom search area for the current frame, the number of zoom search areas corresponding to the opposite trend is reduced according to the prediction result.
[0012] A target tracking method, comprising:
[0013] In the process of tracking the target in the image sequence, the scale change trend of the target in the current frame relative to the previous frame is predicted;
[0014] Obtaining maximum matching degree information for a plurality of sample groups respectively, wherein the plurality of sample groups include sample groups obtained by performing cyclic shifts respectively according to a plurality of scaling search areas, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0015] According to the prediction result, a larger weight factor is assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend, so as to determine the best matching degree.
[0016] A target tracking method in a traffic scene, comprising:
[0017] Obtaining an image sequence captured by a camera equipped with roadside equipment;
[0018] In the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the moving direction information of the target in the multiple frames of images in which tracking has been completed;
[0019] When generating a zoom search area for the current frame, the number of zoom search areas corresponding to the opposite trend is reduced according to the prediction result.
[0020] A target tracking method in a traffic scene, comprising:
[0021] Obtaining an image sequence captured by a camera equipped with roadside equipment;
[0022] In the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the moving direction information of the target in the multiple frames of images in which tracking has been completed;
[0023] Obtaining maximum matching degree information for a plurality of sample groups respectively, wherein the plurality of sample groups include sample groups obtained by performing cyclic shifts respectively according to a plurality of scaling search areas, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0024] According to the prediction result, a larger weight factor is assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend, so as to determine the best matching degree.
[0025] A target tracking method in a human-computer interaction scenario, comprising:
[0026] Obtaining the image sequence collected by the terminal device in real time during the human-computer interaction process;
[0027] In the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images in which tracking has been completed;
[0028] When generating a zoom search area for the current frame, the number of zoom search areas corresponding to the opposite trend is reduced according to the prediction result.
[0029] A target tracking method in a human-computer interaction scenario, comprising:
[0030] Obtaining the image sequence collected by the terminal device in real time during the human-computer interaction process;
[0031] In the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images in which tracking has been completed;
[0032] Obtaining maximum matching degree information for a plurality of sample groups respectively, wherein the plurality of sample groups include sample groups obtained by performing cyclic shifts respectively according to a plurality of scaling search areas, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0033] According to the prediction result, a larger weight factor is assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend, so as to determine the best matching degree.
[0034] A target tracking device, comprising:
[0035] A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame during target tracking of the image sequence;
[0036] The zoom search area quantity control unit is used to reduce the quantity of the zoom search areas corresponding to the opposite trend according to the prediction result when generating the zoom search areas for the current frame.
[0037] A target tracking device, comprising:
[0038] A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame during target tracking of the image sequence;
[0039] an intra-group maximum matching degree obtaining unit, configured to obtain maximum matching degree information for a plurality of sample groups, respectively, wherein the plurality of sample groups include sample groups obtained by cyclically shifting a plurality of scaling search areas, respectively, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0040] The weight factor allocation unit is used to allocate a larger weight factor to the sample group corresponding to the zoom search area in the same zoom direction as the change trend according to the prediction result, so as to determine the best matching degree.
[0041] A target tracking device in a traffic scene, comprising:
[0042] A first image sequence obtaining unit is used to obtain an image sequence collected by a camera equipped by the roadside equipment;
[0043] A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame according to the vertical motion direction information of the target in the multiple frames of images that have completed tracking, during the process of tracking the target in the image sequence;
[0044] The zoom search area quantity control unit is used to reduce the quantity of the zoom search areas corresponding to the opposite trend according to the prediction result when generating the zoom search areas for the current frame.
[0045] A target tracking device in a traffic scene, comprising:
[0046] A first image sequence obtaining unit is used to obtain an image sequence collected by a camera equipped by the roadside equipment;
[0047] A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame according to the vertical motion direction information of the target in the multiple frames of images that have completed tracking, during the process of tracking the target in the image sequence;
[0048] an intra-group maximum matching degree obtaining unit, configured to obtain maximum matching degree information for a plurality of sample groups, respectively, wherein the plurality of sample groups include sample groups obtained by cyclically shifting a plurality of scaling search areas, respectively, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0049] The weight factor allocation unit is used to allocate a larger weight factor to the sample group corresponding to the zoom search area in the same zoom direction as the change trend according to the prediction result, so as to determine the best matching degree.
[0050] A target tracking device in a human-computer interaction scene, comprising:
[0051] The second image sequence obtaining unit is used to obtain an image sequence collected in real time by the terminal device during the human-computer interaction process;
[0052] A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images that have completed tracking during the target tracking process of the image sequence;
[0053] The zoom search area quantity control unit is used to reduce the quantity of the zoom search areas corresponding to the opposite trend according to the prediction result when generating the zoom search areas for the current frame.
[0054] A target tracking device in a human-computer interaction scene, comprising:
[0055] The second image sequence obtaining unit is used to obtain an image sequence collected in real time by the terminal device during the human-computer interaction process;
[0056] A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images that have completed tracking during the target tracking process of the image sequence;
[0057] an intra-group maximum matching degree obtaining unit, configured to obtain maximum matching degree information for a plurality of sample groups, respectively, wherein the plurality of sample groups include sample groups obtained by cyclically shifting a plurality of scaling search areas, respectively, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0058] The weight factor allocation unit is used to allocate a larger weight factor to the sample group corresponding to the zoom search area in the same zoom direction as the change trend according to the prediction result, so as to determine the best matching degree.
[0059] A computer system comprising:
[0060] one or more processors; and
[0061] A memory associated with the one or more processors, the memory being used to store program instructions, wherein when the program instructions are read and executed by the one or more processors, the following operations are performed:
[0062] In the process of tracking the target in the image sequence, the scale change trend of the target in the current frame relative to the previous frame is predicted;
[0063] When generating a zoom search area for the current frame, the number of zoom search areas corresponding to the opposite trend is reduced according to the prediction result.
[0064] A computer system comprising:
[0065] one or more processors; and
[0066] A memory associated with the one or more processors, the memory being used to store program instructions, wherein when the program instructions are read and executed by the one or more processors, the following operations are performed:
[0067] In the process of tracking the target in the image sequence, the scale change trend of the target in the current frame relative to the previous frame is predicted;
[0068] Obtaining maximum matching degree information for a plurality of sample groups respectively, wherein the plurality of sample groups include sample groups obtained by performing cyclic shifts respectively according to a plurality of scaling search areas, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0069] According to the prediction result, a larger weight factor is assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend, so as to determine the best matching degree.
[0070] According to the specific embodiments provided in this application, this application discloses the following technical effects:
[0071] Through the embodiments of the present application, in the process of tracking a target in an image sequence, the scale change trend of the target in the current frame relative to the previous frame can be predicted, and when generating a scaling search area for the current frame, the number of scaling search areas corresponding to the opposite trend can be reduced according to the prediction result. In this way, by reducing the scaledROI of invalid scale, the number of feature extractions and the number of detections in the target frame detection step can be reduced, thereby reducing the time complexity of tracking.
[0072] In addition, by predicting the scale change trend of the target, and then assigning a larger weight factor to the sample group corresponding to the scale search area in the same scale direction as the change trend according to the prediction result, the sample group with greater confidence can obtain a higher weight. Therefore, the best matching degree information finally obtained is more accurate, which is conducive to improving the accuracy of target tracking.
[0073] Of course, any product implementing the present application does not necessarily need to achieve all of the advantages described above at the same time. BRIEF DESCRIPTION OF THE DRAWINGS
[0074] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0075] Figure 1 is a schematic diagram of determining a basic search area in the current frame;
[0076] Figure 2 is a schematic diagram of determining a zoom search area in the current frame;
[0077] Figure 3-1 , 3-2 It is a schematic diagram of generating basic samples and offset samples based on different search areas;
[0078] Figure 4 It is a schematic diagram of the system architecture provided by the embodiment of the present application;
[0079] Figure 5 is a flow chart of the first method provided in an embodiment of the present application;
[0080] Figure 6 is a flow chart of the second method provided in an embodiment of the present application;
[0081] Figure 7 is a flowchart of the third method provided in an embodiment of the present application;
[0082] Figure 8 is a flowchart of the fourth method provided in an embodiment of the present application;
[0083] Fig. 9 is a flowchart of the fifth method provided in an embodiment of the present application;
[0084] Fig.10 is a flowchart of the sixth method provided in an embodiment of the present application;
[0085] Fig.11 is a schematic diagram of a first device provided in an embodiment of the present application;
[0086] Fig.12 is a schematic diagram of a second device provided in an embodiment of the present application;
[0087] Fig.13 is a schematic diagram of a third device provided in an embodiment of the present application;
[0088] Fig.14 is a schematic diagram of a fourth device provided in an embodiment of the present application;
[0089] Fig.15 is a schematic diagram of a fifth device provided in an embodiment of the present application;
[0090] Fig.16 is a schematic diagram of a sixth device provided in an embodiment of the present application;
[0091] Fig.17 It is a schematic diagram of a computer system provided in an embodiment of the present application. DETAILED DESCRIPTION
[0092] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application belong to the scope of protection of this application.
[0093] For ease of understanding, the following first briefly introduces the target tracking algorithm in the prior art.
[0094] Visual object tracking algorithms can be divided into generative methods and discriminative methods according to whether the observation model is a generative model or a discriminative model. Among them, discriminative methods represented by correlation filters and deep learning have achieved satisfactory results.
[0095] Correlation filtering originates from the field of signal processing. Correlation is used to indicate the similarity between two signals. Convolution is usually used to represent correlation operations. The basic idea of the tracking method based on correlation filtering is to find a filter template and perform a convolution operation on the image of the next frame with the filter template. The area with the largest response is the predicted target.
[0096] The embodiment of the present application is an improvement on the target tracking algorithm based on correlation filtering.
[0097] Among them, correlation filtering is introduced in the field of target tracking. By generating several samples in a certain area of the current frame, the sample with the greatest correlation with the filter template is selected from the samples as the tracking result of the current frame. The specific steps mainly include:
[0098] 1. Determine the search region (aka, ROI) in the current frame.
[0099] First, the premise for determining the search area in the current frame is that the position and size of the target's bounding rectangle (referred to as the "target frame") have been determined in the previous frame of the current frame. Figure 1 As shown in the figure, the position and size of the target frame in the previous frame are shown. In the current frame, first, a target frame of the same size can be drawn in the current frame according to the position of the target frame in the previous frame. In addition, since the position and size of the target in the current frame may change, the search area can be expanded. Specifically, an area centered on the target frame position and larger than the target frame size (for example, 2.5 times the target frame size) can be recorded as the based ROI.
[0100] Then, in the case of scale transformation, in order to cover targets of different scales, we can expand and shrink the based ROI to generate a series of search areas larger and smaller than the based ROI, which are recorded as scaled ROI.
[0101] For example, the size of the based ROI is M×N, and K (K is usually an even number, such as 2) scaled ROIs are generated according to the proportional coefficient s (s is a number greater than 1.0, such as 1.05). Its size is (s i M)x(s i N), where i is the ROI number and its value is When i is less than 0, the scale factor s is greater than 1.0, and the scaled ROI generated is smaller than the based ROI, which is recorded as the smaller scaled ROI. At this time, for the smaller scaled ROI, there are fewer pixels framed in the search area, so the proportion of the target in the scaled ROI is greater than the proportion of the target in the based ROI. In particular, if ROIs of different scales are scaled to the same size, the smaller scaled ROI can cover the case where the target scale becomes larger. Similarly, the larger scaled ROI (the scaled ROI generated when i is greater than 0) can cover the case where the target scale becomes smaller.
[0102] In summary, for target box detection, because we need to cover different scales of the target, we need to generate basedROI and several scaledROIs at the same time. For example, for Figure 1 Based on the ROI shown in the figure, the specific scaled ROIs generated can be as follows Figure 2 shown.
[0103] 2. Extract features of the current target.
[0104] After processing the color information in the search area of the current target, the features representing the current ROI can be obtained. For example, the ROI is scaled to a specified template size while keeping the aspect ratio unchanged to obtain a template image (a template can be generated based on the features of the target obtained by marking or other means in the first frame, and the template can be updated in the subsequent tracking process). When the ROI size is larger than the template size, the template image can be obtained by downsampling the ROI image.
[0105] 3. Object detection.
[0106] As shown in step 1, in the current frame, the target position of the previous frame can be used to generate a based ROI and several scaled ROIs. For the i-th ROI, the detection result of the ROI (including the maximum matching degree y max and the corresponding sample x max ):
[0107] a. After performing certain feature extraction based on the color information in the ROI, a detection base sample can be obtained. The based ROI and each scaled ROI generated in step 1 can be used as a base sample.
[0108] b. Generate a series of shifted samples by circularly shifting the feature vector of the base sample in the feature space. In other words, it is equivalent to circularly shifting the pixels in the sample based on the base sample. During the shifting process, the position of the target in the sample will change, but the size will remain unchanged. In other words, assuming that the base sample is regarded as a one-bit array, and the original pixel order is (1, 2, 3, 4, 5), it will become (5, 1, 2, 3, 4) after one circular shift, and (4, 5, 1, 2, 3) after two circular shifts, and so on. For example, in Figure 2 When the based ROI shown in the figure is the corresponding basic sample, each offset sample can be as follows Figure 3-1 As shown; if Figure 2 As shown in the figure, one of the largerscaled ROIs is used as the base sample, and each offset sample can be Figure 3-2 In short, if a total of Figure 2 As shown in the figure, there are one based ROI and four scaled ROIs, so a total of five groups of samples can be obtained. Assuming that each group of samples includes one basic sample and four offset samples, a total of 25 samples can be obtained.
[0109] Next, we can use the existing classifier to classify (match) all samples and get the value with the maximum matching degree (y max,i ) and the corresponding sample (x max,i ).
[0110] Specifically, we can first follow the above steps to obtain the maximum matching degree of each sample and the corresponding sample group, that is, K is the number of scaled ROIs and is generally an even number. i is 0, which indicates the detection result of the basic sample.
[0111] Then, we can filter out the y values of all ROIs according to certain rules. max The best match in best ) and the corresponding sample (i.e. x best ), the corresponding ROI is recorded as best ROI. Specifically, firstly, the maximum matching degree y in each sample group can be determined max Then, the maximum matching degree y obtained from each sample group is max Among them, select the best matching degree y best .
[0112] Among them, the maximum matching degree y obtained from each sample group max Select y best Alternatively, since the confidence of the base sample is usually higher than that of the offset sample, a weight factor can be added to firstly calculate the y obtained in each sample group. max Adjust and then compare the sample groups. max Multiply by different weight factors (denoted as weighting factor), then compare and select the maximum value as y best ,Right now where k i Represents y max,i Specifically, when i is not 0, k i =0.9, when i is 0, k i =1.0.
[0113] That is to say, in the prior art, in each group of samples, only the weight factor corresponding to the basic sample is 1, and the weight factors corresponding to the other offset samples are all 0.9, thereby reflecting the difference in confidence between the basic sample and the offset sample.
[0114] Get y best and x best Later, the position and scale of the target in the current frame can be obtained as follows:
[0115] By sample x best The offset of the target in the current frame relative to the center point of the best ROI is calculated relative to the offset of the basic sample obtained based on the best ROI, and this position is recorded as the target tracking position.
[0116] By changing the scale of the best ROI relative to the based ROI, we can get the change of the current frame target scale relative to the previous frame target scale. For example, if the size of the based ROI is M×N, the size of the best ROI is (s k M)x(s k N), where s is the scale factor when generating the scaled ROI, and k is the sequence number of the best ROI in the scaled ROI. If k is 0, it means that the based ROI is the best ROI. If the size of the target in the previous frame is m×n, the size of the target in the current frame is (m / s k )x(n / s k ).
[0117] From the above introduction to the tracking algorithm process based on correlation filtering, it can be seen that in the algorithm, the generation of based ROI and scaled ROI, and how to filter out the best ROI are very important steps in solving the problem of multi-scale targets. Regarding the generation and screening of ROI, the tracking algorithms in the prior art have at least the following problems:
[0118] 1. There are invalid scale ROIs in the generated scaled ROIs. In the current tracking algorithm, the number of larger scaled ROIs and smaller scaled ROIs is the same. In some cases, ROIs of certain scales are invalid. For example, if the relative distance between the target and the camera increases, the scale of the target in the image will decrease in the current frame relative to the previous frame. At this time, the ROI that covers the trend of the target becoming larger (i.e., the smaller scaled ROI) is an invalid scale ROI. However, when detecting the target frame, each ROI must perform feature extraction and apply a classifier for classification detection. Therefore, invalid scale ROIs will increase the time complexity of tracking.
[0119] 2. When screening for the best match (i.e. y best ), after obtaining the maximum matching degree in each sample group through the classifier, the maximum matching degree of the smaller scaled ROI and the larger scaled ROI (i.e., y best) all use the same weight factor. But in fact, the distance between the target and the camera increases or decreases in a certain direction, that is, the scale change trend of the target from the previous frame to the current frame is actually certain. Therefore, one of the smaller scaled ROI and the larger scaled ROI must have a higher credibility. In the prior art, since it is not known in advance which direction of the scaled ROI is more credible, the same weight factor can only be assigned to the sample group generated based on the smaller scaled ROI and the larger scaled ROI. However, this may result in screening out the wrong y best , which may lead to insufficient accuracy in target tracking.
[0120] In the embodiment of the present application, a corresponding solution is provided mainly for the above-mentioned problem. In this solution, considering that the scale change trend of the target in each frame image has a certain continuity, the target scale change trend information of the current frame relative to the previous frame can be predicted based on some prior information (the position and scale change of the target in each frame image that has been detected in the tracking history, or some configuration files of the camera itself, etc.). In this way, when the search area scaled ROI is generated by scaling the image, the number of scaled ROIs corresponding to the opposite trend can be reduced according to the predicted scale change trend information. For example, when it is judged that the target scale becomes larger, the number of larger scaled ROIs in the scaled ROI is reduced, and when it is judged that the target scale becomes smaller, the number of smallerscaled ROIs in the scaled ROI is reduced. In this way, the complexity of the tracking time caused by the ROI of invalid scale can be reduced.
[0121] In addition, when screening for the best match (i.e. y best ), a larger weight factor can also be assigned to the sample group corresponding to the scaled search area scaled ROI with the same change trend according to the predicted target change trend information, which is beneficial to improve the accuracy of target tracking.
[0122] In practical applications, the solution provided by the embodiments of the present application can be used in a variety of specific application scenarios. For example, in a traffic scenario, a camera device installed on a roadside device collects an image sequence, and then a target in the image sequence needs to be tracked. The solution provided by the embodiments of the present application can be used to reduce the time complexity of the algorithm and improve the tracking accuracy. Figure 4As shown, in this scenario, a specific target tracking program / module can be provided, and the method provided in the embodiment of the present application can be implemented in the program / module. The program / module can be run in a cloud server, and the specific camera device 401 can be installed on the roadside device 402, and images of targets 403 such as vehicles on the road and the surrounding environment can be collected. The collected image sequence can be uploaded to the cloud server, and the specific image sequence can be tracked in the cloud server. Of course, the target tracking solution provided in the embodiment of the present application can also be applied to other application scenarios, including human-computer interaction, unmanned driving, and so on.
[0123] The specific technical solutions provided in the embodiments of the present application are described in detail below.
[0124] Embodiment 1
[0125] First, this embodiment 1 provides a target tracking method from the perspective of the server-side target tracking program / module, see Figure 5 , the method may specifically include:
[0126] S501: in the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame;
[0127] In the embodiment of the present application, "target" refers to the object to be tracked. For the first frame in the image sequence, a bounding rectangle of the target, i.e., a target frame, can be drawn by manual marking or the like. Afterwards, the specific target tracking process is to mark the target frame of the target in each subsequent image frame by tracking the position and size of the target in each frame.
[0128] In an embodiment of the present application, when tracking the current frame, the change trend of the scale of the target in the current frame relative to the previous frame can be predicted. Among them, the so-called scale of the target in the current frame, that is, the number of pixels occupied by the target in the current frame. Since the total size of each frame image is the same, the more pixels a certain target occupies in a certain image frame, the larger its scale. In addition, if the number of pixels occupied by the same target in the previous frame is different from the number of pixels occupied in the current frame, for example, the number increases, then the scale of the target in the current frame tends to increase relative to the previous frame, and vice versa.
[0129] Of course, since the number of pixels occupied by the specific target in the current frame cannot be known before the tracking result of the current frame is obtained, in the embodiment of the present application, a certain method can be used to predict the change trend of the scale of the target in the current frame relative to the previous frame.
[0130] For example, in one implementation, since the scale change trend of the same target between different frames is usually continuous, that is, if the scale of the target is gradually increasing in the previous frames, the target in the current frame is usually also gradually increasing relative to the previous frame, and so on. Therefore, it can be implemented by using the historical tracking results as prior information for prediction.
[0131] Specifically, the scale change trend can be predicted based on the change of the position and / or size of the target in the multiple frames of images that have been tracked. For example, when the camera captures the image sequence from a bird's-eye view, the scale change trend can be predicted based on the position change of the target in the multiple frames of images that have been tracked. If the target moves toward the bottom of the image, it can be determined that the scale of the target has a tendency to increase, and if the target moves toward the top of the image, it can be determined that the scale of the target has a tendency to decrease.
[0132] Alternatively, when the camera captures the image sequence with parallel viewing angles, the scale change trend can be predicted based on the size change of the target in the multiple frames of images that have completed tracking. For example, if the target gradually becomes larger in the images that have completed tracking as shown in the figure, the scale of the target tends to become larger; if the target gradually becomes smaller in the images that have completed tracking, the scale of the target tends to become smaller, and so on.
[0133] Alternatively, in a specific traffic scene, the image sequence includes: an image sequence captured by a camera installed on a roadside device in the traffic scene; at this time, since the target's vertical movement direction does not change from the time it enters the camera's field of view to the time it begins to leave the camera's field of view, the target's vertical movement direction can be determined based on the position of the target in the multiple frames of images that have completed tracking; then, based on the vertical movement direction, determine whether the target enters or leaves the camera's field of view, and then determine the scale change trend of the target based on the situation of entering or leaving the camera's field of view. For example, if it enters the camera's field of view, the scale of the target will gradually increase, and if it leaves the camera's field of view, the scale of the target will gradually decrease, and so on.
[0134] In another implementation, the change trend of the scale can also be predicted based on the configuration file information of the camera. That is to say, in some specific scenes, the camera may have some specific configurations. For example, in a traffic scene, a camera at a certain angle may only shoot targets in the direction of the oncoming vehicle, while cameras at other angles may only shoot targets in the direction of the outgoing vehicle, and so on. All this information will be written in the camera's configuration file. Therefore, the change trend of the scale can be predicted based on the configuration information in the configuration file that only shoots in the direction of the vehicle coming or going. For example, if a camera only shoots in the direction of the vehicle coming, the scale of the target in the current frame will generally tend to be larger than that in the previous frame; and if it only shoots in the direction of the vehicle going, the scale of the target in the current frame will generally tend to be smaller than that in the previous frame, and so on.
[0135] In summary, there are many ways to predict the scale change trend of the target in the current frame relative to the previous frame.
[0136] S502: When generating a zoom search area for the current frame, reduce the number of zoom search areas corresponding to the opposite trend according to the prediction result.
[0137] After predicting the specific scale change trend, when generating the scaling search area for the current frame, the number of scaling search areas corresponding to the opposite trend can be reduced according to the prediction result. That is, when determining the search area in step 1 of the algorithm flow, the number of larger scaled ROI and smaller scaled ROI is no longer the same, but the number of ROIs in one direction is reduced.
[0138] For example, when it is determined that the target scale becomes larger, the number of larger scaled ROIs in the scaled ROI is reduced. Specifically, if the size of the based ROI is M×N, a scaled ROI of size (s i M)x(s i N), where K is a number set in advance, for example, K=4, at this time, the number of largerscaled ROIs is reduced from K / 2 to 1.
[0139] Alternatively, based on the prior information that the target scale will increase, only a few smaller scaledROIs can be generated, and the number of larger scaled ROIs with the opposite trend can be reduced to 0. For example, if the size of the based ROI is M×N, and a scaled ROI is generated according to the scale factor s (usually s>1.0), only a few smaller scaledROIs of size (si M)x(s i N), ROI, where K is a preset number, such as K=4.
[0140] Similarly, based on the prior information that the target scale will become smaller, only a few larger scaledROIs can be generated, while the number of smaller scaled ROIs with the opposite trend can be reduced to 0. For example, if the size of the based ROI is M×N, and scaled ROIs are generated according to the scale factor s (usually s>1.0), only a few larger scaledROIs of size (s i M)x(s i N), ROI, where K is a preset number, such as K=4.
[0141] Of course, if the change trend of the target scale cannot be determined, the same number of smaller scaled ROIs and larger scaled ROIs can be generated. For example, if the size of the based ROI is M×N, the scaled ROI is generated according to the scale factor s (usually s>1.0), and the generated size is (s i M)x(s i N), ROI, where K is a preset number, such as K=4.
[0142] After generating the ROI, each ROI needs to be cyclically shifted to generate a sample group, and then matched with the template features respectively. Therefore, by reducing the scaled ROI with invalid scale, the number of feature extractions and the number of detections in the target box detection step can be reduced, thereby reducing the time complexity of tracking.
[0143] It should be noted that the specific target tracking algorithm can have a variety of different application scenarios, for example, it can include traffic scenarios, monitoring scenarios, human-computer interaction scenarios, and so on. The requirements for security may be different in different application scenarios. For example, in traffic scenarios and monitoring scenarios, the requirements for security are relatively high, while in human-computer interaction scenarios, they are usually for entertainment and other purposes, so the requirements for security are relatively low. In an embodiment of the present application, the accuracy of the target tracking algorithm can also be adjusted according to the different security requirements of different scenarios in which the target tracking is located. For example, for scenarios with higher security requirements, the algorithm accuracy can be improved to improve the accuracy of target tracking, and so on.
[0144] Embodiment 2
[0145] This second embodiment also provides a target tracking method from the perspective of the target tracking program or module in the server. Figure 6 , the method may specifically include:
[0146] S601: in the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame;
[0147] The specific implementation of step S601 may be the same as step S501 in the first embodiment, and thus, the same may be referred to and will not be described in detail here.
[0148] S602: Obtain maximum matching degree information for a plurality of sample groups respectively, wherein the plurality of sample groups include sample groups obtained by performing cyclic shifts respectively according to a plurality of scaling search areas, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0149] As shown in steps 2 and 3 of the target tracking algorithm based on correlation filtering described above, after determining the search area (including a basic search area based ROI and multiple scaled search areas scaled ROI) in the current frame, feature extraction and target frame detection can be performed. Among them, when performing target frame detection, first, a sample group can be generated for each search area, each sample group includes a basic sample and multiple offset samples; then, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively. Next, the matching degrees corresponding to each sample are compared within each sample group to obtain the maximum matching degree within the sample group. In this way, the respective maximum matching degrees can be compared between different sample groups to obtain the best matching degree. The offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best ROI is used to calculate the offset of the target relative to the center point of the best ROI in the current frame, and this position can be recorded as the target tracking position.
[0150] S603: According to the prediction result, a larger weight factor is assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend, so as to determine the best matching degree.
[0151] When comparing the respective maximum matching degrees between different sample groups, in order to make the maximum matching degrees between different sample groups more comparable, a weight factor may be first assigned according to the confidence of each sample group, and the maximum matching degree may be multiplied by the corresponding weight factor before the comparison is performed. However, as mentioned above, in the prior art, the same weight factor is assigned to the sample groups generated based on the smaller scaled ROI and the larger scaled ROI.
[0152] In the embodiment of the present application, since the scale change trend of the target in the current frame relative to the previous frame is predicted, a more suitable weight factor can be assigned to each sample group based on this prior information. Specifically, since the specific scale change trend has been predicted, the sample group corresponding to the scaling search area in the same scaling direction as the change trend will have a higher confidence, and therefore, a larger weight factor can be assigned. Correspondingly, the sample group corresponding to the scaling search area in the scaling direction opposite to the change trend will have a lower confidence, and therefore, a smaller weight factor can be assigned. In other words, the larger weight factor described in the embodiment of the present application refers to the weight factor but the weight factor assigned to the sample group corresponding to the scaling search area in the scaling direction opposite to the change trend.
[0153] For example, the weight factor of the maximum matching degree assigned to the sample group corresponding to the larger scale ROI is a, and the weight factor of the maximum matching degree assigned to the sample group corresponding to the smaller scale ROI is b. When it is determined that the target scale has a tendency to increase, b is greater than a. Among them, a and b are two numbers designed reasonably, ensuring that they are neither too large to affect the stability of the target scale, nor too small to cause the target scale to basically remain unchanged. For example, a = 0.9 and b = 0.95 can be taken.
[0154] In addition, to ensure the stability of the scales of various process targets, the weight factor corresponding to the based ROI (denoted as basedfactor) should be greater than the weight factor corresponding to the bigger scaled ROI (denoted as biggerfactor) and the weight factor corresponding to the smaller scaled ROI (denoted as smallerfactor). For example, the based factor is 1.0, and the bigger factor and maller factor are less than 1.0. Then, on this basis, the difference in size between the biggerfactor and maller factor is reflected.
[0155] Specifically, based on the prior information that the target scale will increase, the weighting factor corresponding to the smaller scaled ROI is larger than the weighting factor of the larger scaled ROI. i =0.95, when i=0, k i =1.0, for example, when i>0, k i =0.9.
[0156] Based on the prior information that the target scale will be smaller, the weighting factor corresponding to the larger scaled ROI is larger than the weighting factor of the smaller scaled ROI. For example, when i>0, k i =0.95, when i=0, k i =1.0, for example, when i<0, k i =0.9.
[0157] If the change trend of the target scale cannot be determined, the weighting factor corresponding to the smaller scaled ROI can be equal to the weighting factor of the larger scaled ROI. For example, when i<0 or i>0, k i =0.9, when i=0, k i =1.0.
[0158] After assigning weight factors to each sample group, the maximum matching degree corresponding to the specific sample group can be adjusted by the weight factors, and then the maximum matching degrees are compared among multiple sample groups to obtain the best matching degree. The sample corresponding to the best matching degree can be used to determine the position and size of the specific target in the current frame.
[0159] In short, by predicting the scale change trend of the target, and then assigning a larger weight factor to the sample group corresponding to the scale search area in the same scale direction as the change trend according to the prediction result, the sample group with greater confidence can obtain a higher weight. Therefore, the best matching degree information finally obtained is more accurate, which is conducive to improving the accuracy of target tracking.
[0160] Embodiment 3
[0161] The third embodiment combines the specific technical solution provided in the first embodiment with the traffic scene, and provides a method for tracking a target in a traffic scene. Figure 7 , the method may specifically include:
[0162] S701: Obtaining an image sequence captured by a camera equipped with a roadside device;
[0163] Roadside equipment can be pre-deployed on one or both sides of the road. Cameras can be installed on them to collect image sequences of the road and the surrounding environment. The collected results can be submitted to the cloud server, which will track the target based on the specific image sequence.
[0164] S702: in the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the vertical motion direction information of the target in the multiple frames of images in which tracking has been completed;
[0165] Since the image sequence is collected by the camera installed on the roadside equipment, and is mainly shot from a bird's-eye view, the scale change trend of the target in the current frame relative to the previous frame can be predicted directly based on the vertical movement direction information of the target in the multiple frames of images that have completed tracking. For example, if the target moves downward in the vertical direction of the image, the target scale tends to increase, otherwise, if the target moves upward in the vertical direction of the image, the target scale tends to decrease.
[0166] S703: When generating a zoom search area for the current frame, reduce the number of zoom search areas corresponding to the opposite trend according to the prediction result.
[0167] If the movement direction in the vertical direction is downward, the scale change trend is increasing; if the movement direction in the vertical direction is upward, the scale change trend is decreasing.
[0168] It should be noted that in this traffic scenario, real-time target tracking processing can usually be performed based on the image sequence collected in real time, so the requirements for hardware and computing resources are usually relatively high. In fact, the complexity of target tracking may be different for different situations. Therefore, if the computing resources used are used to process target tracking in various situations, it may cause a certain degree of computing resource waste. For example, in the case of traffic congestion, there are many cars on the road, and the number of targets that need to be tracked may also be relatively large, and because the image is relatively messy, the complexity of tracking will also be higher; while in the case of smooth traffic, there are few cars on the road, and the number and complexity of targets that need to be tracked will also decrease accordingly. In addition, for some sections of the road, the road conditions may show the characteristics of changing over time. For example, during some peak traffic flow periods, there are more vehicles on the road, and correspondingly, the complexity of target tracking is higher, while during non-peak hours, the complexity is reduced, and so on. Therefore, in an optional embodiment of the present application, the computing resources allocated to the target tracking algorithm can also be dynamically adjusted during the target tracking process. For example, in one way, the computing resources used for target tracking can be dynamically allocated according to the number of targets that need to be tracked in the image sequence. Or, in another way, computing resources for target tracking may be dynamically allocated according to whether the acquisition time of the image sequence belongs to the peak traffic flow period, etc.
[0169] Embodiment 4
[0170] This fourth embodiment combines the specific technical solution provided in the second embodiment with the traffic scene, and provides a method for tracking a target in a traffic scene. Figure 8 , the method may specifically include:
[0171] S801: Obtaining an image sequence collected by a camera equipped with a roadside device;
[0172] S802: in the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the vertical motion direction information of the target in the multiple frames of images in which tracking has been completed;
[0173] S803: Obtain maximum matching degree information for a plurality of sample groups respectively, wherein the plurality of sample groups include sample groups obtained by performing cyclic shifts respectively according to a plurality of scaling search areas, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0174] S804: According to the prediction result, a larger weight factor is assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend, so as to determine the best matching degree.
[0175] Embodiment 5
[0176] The fifth embodiment combines the specific technical solution provided in the first embodiment with the human-computer interaction scenario, and provides a target tracking method in the human-computer interaction scenario. Fig. 9 , the method may specifically include:
[0177] S901: Obtaining an image sequence collected in real time by a terminal device during a human-computer interaction process;
[0178] Specifically, human-computer interaction may include interaction by collecting and tracking specific target images, and the specific targets include gesture images or face images, etc. For example, interactive materials are provided by tracking gestures of a certain shape, etc. Therefore, this tracking of the target is based on the target tracking of the image sequence collected in real time. The specific target tracking program or module can be directly run in the client of the terminal device, and of course, it can also be run in the server. At this time, real-time data transmission can be performed between the client and the server.
[0179] S902: in the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images in which tracking has been completed;
[0180] Since the camera usually shoots the target from a parallel perspective during the process of collecting gestures or facial images in human-computer interaction, the scale change trend of the target in the current frame relative to the previous frame can be predicted based on the size change information of the target in the multiple frames of images that have been tracked.
[0181] S903: When generating a zoom search area for the current frame, reduce the number of zoom search areas corresponding to the opposite trend according to the prediction result.
[0182] Embodiment 6
[0183] This sixth embodiment combines the specific technical solution provided in the first embodiment with the human-computer interaction scenario, and provides a target tracking method in the human-computer interaction scenario. Fig.10 , the method may specifically include:
[0184] S1001: Obtaining an image sequence collected in real time by a terminal device during a human-computer interaction process;
[0185] S1002: in the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images in which tracking has been completed;
[0186] S1003: Obtain maximum matching degree information for a plurality of sample groups respectively, wherein the plurality of sample groups include sample groups obtained by performing cyclic shifts respectively according to a plurality of zoom search areas, wherein the zoom search areas include a plurality of zoom search areas in different zoom directions;
[0187] S1004: According to the prediction result, a larger weight factor is assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend, so as to determine the best matching degree.
[0188] For the parts not described in detail in the above-mentioned embodiments 3 to 6, please refer to the records in the above-mentioned embodiments 1 and 2, and will not be repeated here.
[0189] Corresponding to the first embodiment, the present application embodiment also provides a target tracking device, see Fig.11 , the device may include:
[0190] The scale change trend prediction unit 1101 is used to predict the scale change trend of the target in the current frame relative to the previous frame during the process of tracking the target in the image sequence;
[0191] The zoom search area quantity control unit 1102 is used to reduce the quantity of the zoom search areas corresponding to the opposite trend according to the prediction result when generating the zoom search areas for the current frame.
[0192] The scale change trend prediction unit may be specifically used for:
[0193] The change trend of the scale is predicted according to the change of the position and / or size of the target in the multiple frames of images that have completed tracking.
[0194] Specifically, when the camera obtains the image sequence by shooting from a bird's-eye view, if the target moves toward the bottom of the image, the scale of the target tends to increase, and if the target moves toward the top of the image, the scale of the target tends to decrease.
[0195] Wherein, the image sequence includes: an image sequence captured by a camera installed on a roadside device in a traffic scene;
[0196] The scale change trend prediction unit can be specifically used for:
[0197] Determining the moving direction of the target in the vertical direction of the image according to the position of the target in the multiple frames of images in which tracking has been completed;
[0198] According to the moving direction in the vertical direction, it is determined whether the target enters or leaves the camera field of view, and according to the situation of entering or leaving the camera field of view, the scale change trend of the target is determined.
[0199] In addition, the scale change trend prediction unit can also be used for:
[0200] According to the configuration file information of the camera, the change trend of the scale is predicted.
[0201] Specifically, in a traffic scene, according to the configuration information in the camera configuration file that only the vehicle's oncoming direction or the vehicle's outgoing direction is photographed, the change trend of the scale is predicted.
[0202] The scaling search area quantity control unit may be specifically used for:
[0203] Only zoom search areas corresponding to the same trend are generated.
[0204] In addition, the zoom search area quantity control unit can also be used for:
[0205] If the prediction of the scale change trend fails, the number of scaled search areas of the same and opposite trends are equal.
[0206] In practical applications, the device may also include:
[0207] The precision adjustment unit is used to adjust the precision of the target tracking algorithm according to different safety requirements of different scenarios in which the target is tracked.
[0208] Corresponding to the second embodiment, the present application embodiment also provides a target tracking device, see Fig.12 , the device may include:
[0209] The scale change trend prediction unit 1201 is used to predict the scale change trend of the target in the current frame relative to the previous frame during the process of tracking the target in the image sequence;
[0210] The intra-group maximum matching degree obtaining unit 1202 is used to obtain maximum matching degree information for a plurality of sample groups, respectively, wherein the plurality of sample groups include sample groups obtained by performing cyclic shifts according to a plurality of scaling search areas, respectively, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0211] The weight factor allocation unit 1203 is used to allocate a larger weight factor to the sample group corresponding to the zoom search area in the same zoom direction as the change trend according to the prediction result, so as to determine the best matching degree.
[0212] The larger weight factor is larger than the weight factor allocated to the sample group corresponding to the zoom search area in the zoom direction opposite to the change trend.
[0213] The weight factors assigned to the sample groups corresponding to the zoom search area are all smaller than the weight factors assigned to the sample groups corresponding to the basic search area.
[0214] The weight factor allocation unit may also be used for:
[0215] If the scale change trend prediction fails, the weight factors assigned to the sample groups corresponding to the scaling search areas of the same and opposite trends are equal.
[0216] Corresponding to the third embodiment, the present application embodiment also provides a target tracking device in a traffic scene, see Fig.13 , the device may include:
[0217] The first image sequence obtaining unit 1301 is used to obtain an image sequence collected by a camera equipped by a roadside device;
[0218] The scale change trend prediction unit 1302 is used to predict the scale change trend of the target in the current frame relative to the previous frame according to the vertical motion direction information of the target in the multiple frames of images that have completed tracking during the target tracking process of the image sequence;
[0219] The zoom search area quantity control unit 1303 is used to reduce the quantity of the zoom search areas corresponding to the opposite trend according to the prediction result when generating the zoom search areas for the current frame.
[0220] If the movement direction in the vertical direction is downward, the scale change trend is increasing; if the movement direction in the vertical direction is upward, the scale change trend is decreasing.
[0221] In a specific implementation, the device may further include:
[0222] The first computing resource allocation unit is used to dynamically allocate computing resources for target tracking according to the number of targets to be tracked in the image sequence.
[0223] Alternatively, the first computing resource allocation unit is used to dynamically allocate computing resources for target tracking according to whether the acquisition time of the image sequence belongs to the peak period of traffic flow.
[0224] Corresponding to the fourth embodiment, the present application embodiment also provides a target tracking device in a traffic scene, see Fig.14 , the device may include:
[0225] The first image sequence obtaining unit 1401 is used to obtain an image sequence collected by a camera equipped by a roadside device;
[0226] The scale change trend prediction unit 1402 is used to predict the scale change trend of the target in the current frame relative to the previous frame according to the vertical motion direction information of the target in the multiple frames of images that have completed tracking during the target tracking process of the image sequence;
[0227] The intra-group maximum matching degree obtaining unit 1403 is used to obtain maximum matching degree information for a plurality of sample groups, respectively, wherein the plurality of sample groups include sample groups obtained by performing cyclic shifts according to a plurality of scaling search areas, respectively, wherein the scaling search areas include scaling search areas in a plurality of different scaling directions;
[0228] The weight factor allocation unit 1404 is used to allocate a larger weight factor to the sample group corresponding to the zoom search area in the same zoom direction as the change trend according to the prediction result, so as to determine the best matching degree.
[0229] Corresponding to the fifth embodiment, the present application embodiment also provides a target tracking device in a human-computer interaction scenario, see Fig.15 , the device may include:
[0230] The second image sequence obtaining unit 1501 is used to obtain an image sequence collected in real time by the terminal device during the human-computer interaction process;
[0231] The scale change trend prediction unit 1502 is used to predict the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images that have completed tracking during the target tracking process of the image sequence;
[0232] The zoom search area quantity control unit 1503 is used to reduce the quantity of the zoom search areas corresponding to the opposite trend according to the prediction result when generating the zoom search areas for the current frame.
[0233] The human-computer interaction includes interaction by collecting and tracking specific target images, and the specific targets include gesture images or face images.
[0234] Corresponding to the sixth embodiment, the present application embodiment also provides a target tracking device in a human-computer interaction scenario, see Fig.16 , the device may include:
[0235] The second image sequence obtaining unit 1601 is used to obtain an image sequence collected in real time by the terminal device during the human-computer interaction process;
[0236] The scale change trend prediction unit 1602 is used to predict the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images that have completed tracking during the target tracking process of the image sequence;
[0237] The intra-group maximum matching degree obtaining unit 1603 is used to obtain maximum matching degree information for a plurality of sample groups, respectively, wherein the plurality of sample groups include sample groups obtained by performing cyclic shifts according to a plurality of scaling search areas, respectively, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0238] The weight factor allocation unit 1604 is used to allocate a larger weight factor to the sample group corresponding to the zoom search area in the same zoom direction as the change trend according to the prediction result, so as to determine the best matching degree.
[0239] In addition, the present application also provides a computer system, including:
[0240] one or more processors; and
[0241] A memory associated with the one or more processors, the memory being used to store program instructions, wherein when the program instructions are read and executed by the one or more processors, the following operations are performed:
[0242] In the process of tracking the target in the image sequence, the scale change trend of the target in the current frame relative to the previous frame is predicted;
[0243] When generating a zoom search area for the current frame, the number of zoom search areas corresponding to the opposite trend is reduced according to the prediction result.
[0244] and another computer system comprising:
[0245] one or more processors; and
[0246] A memory associated with the one or more processors, the memory being used to store program instructions, wherein when the program instructions are read and executed by the one or more processors, the following operations are performed:
[0247] In the process of tracking the target in the image sequence, the scale change trend of the target in the current frame relative to the previous frame is predicted;
[0248] Obtaining maximum matching degree information for a plurality of sample groups respectively, wherein the plurality of sample groups include sample groups obtained by performing cyclic shifts respectively according to a plurality of scaling search areas, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions;
[0249] According to the prediction result, a larger weight factor is assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend, so as to determine the best matching degree.
[0250] in, Fig.17 The computer system architecture is shown as an example, which may include a processor 1710, a video display adapter 1711, a disk drive 1712, an input / output interface 1713, a network interface 1714, and a memory 1720. The processor 1710, the video display adapter 1711, the disk drive 1712, the input / output interface 1713, the network interface 1714, and the memory 1720 may be communicatively connected via a communication bus 1730.
[0251] Among them, the processor 1710 can be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), or one or more integrated circuits, etc., to execute relevant programs to implement the technical solution provided in this application.
[0252] The memory 1720 can be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage device, dynamic storage device, etc. The memory 1720 can store an operating system 1721 for controlling the operation of the electronic device 1700, and a basic input and output system (BIOS) for controlling the low-level operation of the electronic device 1700. In addition, a web browser 1723, a data storage management system 1724, and a target tracking processing system 1725, etc. can also be stored. The above-mentioned target tracking processing system 1725 can be an application program that specifically implements the aforementioned steps in the embodiment of the present application. In short, when the technical solution provided by the present application is implemented by software or firmware, the relevant program code is stored in the memory 1720 and is called and executed by the processor 1710.
[0253] The input / output interface 1713 is used to connect the input / output module to realize information input and output. The input / output module can be configured in the device as a component (not shown in the figure), or it can be externally connected to the device to provide corresponding functions. The input device may include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output device may include a display, a speaker, a vibrator, an indicator light, etc.
[0254] The network interface 1714 is used to connect to a communication module (not shown) to realize communication interaction between the device and other devices. The communication module can realize communication through a wired mode (such as USB, network cable, etc.) or a wireless mode (such as mobile network, WIFI, Bluetooth, etc.).
[0255] The bus 1730 comprises a pathway for transmitting information between the various components of the device (eg, the processor 1710, the video display adapter 1711, the disk drive 1712, the input / output interface 1713, the network interface 1714, and the memory 1720).
[0256] In addition, the electronic device 1700 can also obtain information on specific collection conditions from the virtual resource object collection condition information database 1741 for use in condition judgment, etc.
[0257] It should be noted that, although the above device only shows a processor 1710, a video display adapter 1711, a disk drive 1712, an input / output interface 1713, a network interface 1714, a memory 1720, a bus 1730, etc., in the specific implementation process, the device may also include other components necessary for normal operation. In addition, it can be understood by those skilled in the art that the above device may also only include components necessary for implementing the solution of the present application, and does not necessarily include all the components shown in the figure.
[0258] It can be known from the description of the above implementation methods that those skilled in the art can clearly understand that the present application can be implemented by means of software plus a necessary general hardware platform. Based on such an understanding, the technical solution of the present application can be essentially or partly contributed to the prior art in the form of a software product, which can be stored in a storage medium such as ROM / RAM, a magnetic disk, an optical disk, etc., and includes several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in the various embodiments of the present application or certain parts of the embodiments.
[0259] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can refer to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system or system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can refer to the partial description of the method embodiment. The system and system embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without creative work.
[0260] The above is a detailed introduction to the present application. The principles and implementation methods of the present application are described in detail using specific examples. The description of the above embodiments is only used to help understand the method and core idea of the present application. At the same time, for those skilled in the art, according to the idea of the present application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting the present application.
Claims
1. A target tracking method, characterized in that: include: In the process of tracking the target in the image sequence, the scale change trend of the target in the current frame relative to the previous frame is predicted; Performing cyclic shifts on multiple zoom search areas generated in the current frame to obtain multiple sample groups, when generating multiple zoom search areas in different zoom directions for the current frame, reducing the number of zoom search areas corresponding to opposite trends according to the prediction result, and assigning weight factors to the sample groups according to the prediction result, wherein a first weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with the same change trend is greater than a second weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with a different change trend, and both the first weight factor and the second weight factor are less than a weight factor assigned to a sample group corresponding to a base search area, so as to determine the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
2. The method according to claim 1, characterized in that The predicting of the scale change trend of the target in the current frame relative to the previous frame includes: The change trend of the scale is predicted according to the change of the position and / or size of the target in the multiple frames of images that have completed tracking.
3. The method according to claim 2, characterized in that The predicting of the change trend of the scale according to the change of the position and / or size of the target in the multiple frames of images that have completed tracking includes: When the camera obtains the image sequence by shooting from a bird's-eye view, if the target moves toward the bottom of the image, the scale of the target tends to become larger, and if the target moves toward the top of the image, the scale of the target tends to become smaller.
4. The method according to claim 2, characterized in that: The image sequence includes: an image sequence captured by a camera installed on a roadside device in a traffic scene; The predicting of the change trend of the scale according to the position change of the target in the multiple frames of images that have completed tracking includes: Determining the moving direction of the target in the vertical direction of the image according to the position of the target in the multiple frames of images in which tracking has been completed; According to the moving direction in the vertical direction, it is determined whether the target enters or leaves the camera field of view, and according to the situation of entering or leaving the camera field of view, the scale change trend of the target is determined.
5. The method according to claim 1, characterized in that The predicting of the scale change trend of the target in the current frame relative to the previous frame includes: According to the configuration file information of the camera, the change trend of the scale is predicted.
6. The method according to claim 5, characterized in that The predicting the change trend of the scale according to the configuration file information of the camera includes: In a traffic scene, according to configuration information in the camera configuration file that only the vehicle is photographed in the direction of the vehicle coming or the direction of the vehicle going, the change trend of the scale is predicted.
7. The method according to any one of claims 1 to 6, characterized in that: The reducing the number of zoom search areas corresponding to the opposite trend comprises: Only zoom search areas corresponding to the same trend are generated.
8. The method according to any one of claims 1 to 6, characterized in that: Also includes: If the prediction of the scale change trend fails, the number of scaled search areas of the same and opposite trends are equal.
9. The method according to any one of claims 1 to 6, characterized in that: Also includes: Adjust the accuracy of the target tracking algorithm according to the different security requirements of different target tracking scenarios.
10. A target tracking method, characterized in that: include: In the process of tracking the target in the image sequence, the scale change trend of the target in the current frame relative to the previous frame is predicted; Obtaining maximum matching degree information for a plurality of sample groups respectively, the plurality of sample groups comprising sample groups obtained by cyclically shifting a plurality of scaling search areas generated in a current frame respectively, the scaling search areas comprising a plurality of scaling search areas in different scaling directions; Assigning weight factors to the sample groups according to the prediction results, wherein a first weight factor assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend is greater than a second weight factor assigned to the sample group corresponding to the zoom search area in the different zoom direction from the change trend, and both the first weight factor and the second weight factor are less than a weight factor assigned to the sample group corresponding to the base search area, for determining the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
11. The method according to claim 10, characterized in that Also includes: If the scale change trend prediction fails, the weight factors assigned to the sample groups corresponding to the scaling search areas of the same and opposite trends are equal.
12. A target tracking method in a traffic scene, characterized in that: include: Obtaining an image sequence captured by a camera equipped with roadside equipment; In the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the moving direction information of the target in the multiple frames of images in which tracking has been completed; Performing cyclic shifts on multiple zoom search areas generated in the current frame to obtain multiple sample groups, when generating multiple zoom search areas in different zoom directions for the current frame, reducing the number of zoom search areas corresponding to opposite trends according to the prediction result, and assigning weight factors to the sample groups according to the prediction result, wherein a first weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with the same change trend is greater than a second weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with a different change trend, and both the first weight factor and the second weight factor are less than a weight factor assigned to a sample group corresponding to a base search area, so as to determine the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
13. The method according to claim 12, characterized in that If the movement direction in the vertical direction is downward, the scale change trend is increasing; if the movement direction in the vertical direction is upward, the scale change trend is decreasing.
14. The method according to claim 12, characterized in that Also includes: Computational resources for target tracking are dynamically allocated according to the number of targets to be tracked in the image sequence.
15. The method according to claim 12, characterized in that Also includes: Computational resources for target tracking are dynamically allocated according to whether the acquisition time of the image sequence belongs to the peak traffic flow period.
16. A target tracking method in a traffic scene, characterized in that: include: Obtaining an image sequence captured by a camera equipped with roadside equipment; In the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the moving direction information of the target in the multiple frames of images in which tracking has been completed; Obtaining maximum matching degree information for a plurality of sample groups respectively, the plurality of sample groups comprising sample groups obtained by cyclically shifting a plurality of scaling search areas generated in a current frame respectively, the scaling search areas comprising a plurality of scaling search areas in different scaling directions; Assigning weight factors to the sample groups according to the prediction results, wherein a first weight factor assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend is greater than a second weight factor assigned to the sample group corresponding to the zoom search area in the different zoom direction from the change trend, and both the first weight factor and the second weight factor are less than a weight factor assigned to the sample group corresponding to the base search area, for determining the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
17. A target tracking method in a human-computer interaction scenario, characterized in that: include: Obtaining the image sequence collected by the terminal device in real time during the human-computer interaction process; In the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images in which tracking has been completed; Performing cyclic shifts on multiple zoom search areas generated in the current frame to obtain multiple sample groups, when generating multiple zoom search areas in different zoom directions for the current frame, reducing the number of zoom search areas corresponding to opposite trends according to the prediction result, and assigning weight factors to the sample groups according to the prediction result, wherein a first weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with the same change trend is greater than a second weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with a different change trend, and both the first weight factor and the second weight factor are less than a weight factor assigned to a sample group corresponding to a base search area, so as to determine the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
18. The method according to claim 17, characterized in that The human-computer interaction includes interaction performed by collecting and tracking specific target images, where the specific targets include gesture images or face images.
19. A target tracking method in a human-computer interaction scenario, characterized in that: include: Obtaining the image sequence collected by the terminal device in real time during the human-computer interaction process; In the process of tracking the target in the image sequence, predicting the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images in which tracking has been completed; Obtaining maximum matching degree information for a plurality of sample groups respectively, the plurality of sample groups comprising sample groups obtained by cyclically shifting a plurality of scaling search areas generated in a current frame respectively, the scaling search areas comprising a plurality of scaling search areas in different scaling directions; Assigning weight factors to the sample groups according to the prediction results, wherein a first weight factor assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend is greater than a second weight factor assigned to the sample group corresponding to the zoom search area in the different zoom direction from the change trend, and both the first weight factor and the second weight factor are less than a weight factor assigned to the sample group corresponding to the base search area, for determining the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
20. A target tracking device, characterized in that: include: A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame during target tracking of the image sequence; A control unit for the number of zoom search areas, configured to obtain multiple sample groups by performing cyclic shifts respectively according to multiple zoom search areas generated in the current frame, and when generating multiple zoom search areas in different zoom directions for the current frame, reduce the number of zoom search areas corresponding to opposite trends according to the prediction result, and assign weight factors to the sample groups according to the prediction result, wherein a first weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with the same change trend is greater than a second weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with a different change trend, and both the first weight factor and the second weight factor are less than a weight factor assigned to a sample group corresponding to a basic search area, so as to determine the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
21. A target tracking device, characterized in that: include: A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame during target tracking of the image sequence; an intra-group maximum matching degree obtaining unit, configured to obtain maximum matching degree information for a plurality of sample groups, respectively, wherein the plurality of sample groups include sample groups obtained by cyclically shifting a plurality of scaling search areas generated in a current frame, respectively, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions; a weight factor allocation unit, configured to allocate weight factors to the sample groups according to the prediction results, wherein a first weight factor allocated to the sample group corresponding to the zoom search area in the same zoom direction as the change trend is greater than a second weight factor allocated to the sample group corresponding to the zoom search area in the different zoom direction from the change trend, and both the first weight factor and the second weight factor are less than a weight factor allocated to the sample group corresponding to the base search area, so as to determine the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
22. A target tracking device in a traffic scene, characterized in that: include: A first image sequence obtaining unit is used to obtain an image sequence collected by a camera equipped by the roadside equipment; A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame according to the vertical motion direction information of the target in the multiple frames of images that have completed tracking, during the process of tracking the target in the image sequence; A control unit for the number of zoom search areas, configured to obtain multiple sample groups by performing cyclic shifts respectively according to multiple zoom search areas generated in the current frame, and when generating multiple zoom search areas in different zoom directions for the current frame, reduce the number of zoom search areas corresponding to opposite trends according to the prediction result, and assign weight factors to the sample groups according to the prediction result, wherein a first weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with the same change trend is greater than a second weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with a different change trend, and both the first weight factor and the second weight factor are less than a weight factor assigned to a sample group corresponding to a basic search area, so as to determine the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
23. A target tracking device in a traffic scene, characterized in that: include: A first image sequence obtaining unit is used to obtain an image sequence collected by a camera equipped by the roadside equipment; A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame according to the vertical motion direction information of the target in the multiple frames of images that have completed tracking, during the process of tracking the target in the image sequence; an intra-group maximum matching degree obtaining unit, configured to obtain maximum matching degree information for a plurality of sample groups, respectively, wherein the plurality of sample groups include sample groups obtained by cyclically shifting a plurality of scaling search areas generated in a current frame, respectively, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions; a weight factor allocation unit, configured to allocate weight factors to the sample groups according to the prediction results, wherein a first weight factor allocated to the sample group corresponding to the zoom search area in the same zoom direction as the change trend is greater than a second weight factor allocated to the sample group corresponding to the zoom search area in the different zoom direction from the change trend, and both the first weight factor and the second weight factor are less than a weight factor allocated to the sample group corresponding to the base search area, so as to determine the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
24. A target tracking device in a human-computer interaction scene, characterized in that: include: The second image sequence obtaining unit is used to obtain an image sequence collected in real time by the terminal device during the human-computer interaction process; A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images that have completed tracking during the target tracking process of the image sequence; A control unit for the number of zoom search areas, configured to obtain multiple sample groups by performing cyclic shifts respectively according to multiple zoom search areas generated in the current frame, and when generating multiple zoom search areas in different zoom directions for the current frame, reduce the number of zoom search areas corresponding to opposite trends according to the prediction result, and assign weight factors to the sample groups according to the prediction result, wherein a first weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with the same change trend is greater than a second weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with a different change trend, and both the first weight factor and the second weight factor are less than a weight factor assigned to a sample group corresponding to a basic search area, so as to determine the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
25. A target tracking device in a human-computer interaction scene, characterized in that: include: The second image sequence obtaining unit is used to obtain an image sequence collected in real time by the terminal device during the human-computer interaction process; A scale change trend prediction unit, used to predict the scale change trend of the target in the current frame relative to the previous frame according to the size change information of the target in the multiple frames of images that have completed tracking during the target tracking process of the image sequence; an intra-group maximum matching degree obtaining unit, configured to obtain maximum matching degree information for a plurality of sample groups, respectively, wherein the plurality of sample groups include sample groups obtained by cyclically shifting a plurality of scaling search areas generated in a current frame, respectively, wherein the scaling search areas include a plurality of scaling search areas in different scaling directions; a weight factor allocation unit, configured to allocate weight factors to the sample groups according to the prediction results, wherein a first weight factor allocated to the sample group corresponding to the zoom search area in the same zoom direction as the change trend is greater than a second weight factor allocated to the sample group corresponding to the zoom search area in the different zoom direction from the change trend, and both the first weight factor and the second weight factor are less than a weight factor allocated to the sample group corresponding to the base search area, so as to determine the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
26. A computer system, characterized in that: include: one or more processors; as well as A memory associated with the one or more processors, the memory being used to store program instructions, wherein when the program instructions are read and executed by the one or more processors, the following operations are performed: In the process of tracking the target in the image sequence, the scale change trend of the target in the current frame relative to the previous frame is predicted; Performing cyclic shifts on multiple zoom search areas generated in the current frame to obtain multiple sample groups, when generating multiple zoom search areas in different zoom directions for the current frame, reducing the number of zoom search areas corresponding to opposite trends according to the prediction result, and assigning weight factors to the sample groups according to the prediction result, wherein a first weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with the same change trend is greater than a second weight factor assigned to a sample group corresponding to a zoom search area in a zoom direction with a different change trend, and both the first weight factor and the second weight factor are less than a weight factor assigned to a sample group corresponding to a base search area, so as to determine the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
27. A computer system, characterized in that: include: one or more processors; as well as A memory associated with the one or more processors, the memory being used to store program instructions, wherein when the program instructions are read and executed by the one or more processors, the following operations are performed: In the process of tracking the target in the image sequence, the scale change trend of the target in the current frame relative to the previous frame is predicted; Obtaining maximum matching degree information for a plurality of sample groups respectively, the plurality of sample groups comprising sample groups obtained by cyclically shifting a plurality of scaling search areas generated in a current frame respectively, the scaling search areas comprising a plurality of scaling search areas in different scaling directions; Assigning weight factors to the sample groups according to the prediction results, wherein a first weight factor assigned to the sample group corresponding to the zoom search area in the same zoom direction as the change trend is greater than a second weight factor assigned to the sample group corresponding to the zoom search area in the different zoom direction from the change trend, and both the first weight factor and the second weight factor are less than a weight factor assigned to the sample group corresponding to the base search area, for determining the best matching degree; Among them, when performing target frame detection, a sample group is generated for each search area, each sample group includes a basic sample and multiple offset samples, feature extraction is performed for each sample in each sample group, and the feature matching degree between each sample feature and the template feature is calculated respectively; within each sample group, the matching degrees corresponding to each sample are compared to obtain the maximum matching degree within the sample group, and the respective maximum matching degrees are compared between different sample groups to obtain the best matching degree, and according to the offset of the sample corresponding to the best matching degree relative to the basic sample obtained based on the best matching search area, the offset of the target in the current frame relative to the center point of the best matching search area is calculated, and the target tracking position is determined.
Citation Information
Patent Citations
Vision sensor based aircraft detection device and method using dynamic programming and camshift algorithm
KR1020120107698A