Target tracking method and device

By automatically determining and adjusting the tracking frame of the drone, the problem of inaccurate manual tracking frames is solved, and the accuracy and efficiency of drone target tracking are improved.

CN111798482BActive Publication Date: 2024-10-15ZHEJIANG DAHUA TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202010547661.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-06-16
Publication Date
2024-10-15
Estimated Expiration
2040-06-16

AI Technical Summary

Technical Problem

Existing drones need to manually draw the tracking frame of the target when tracking a target, resulting in increased user workload and reduced tracking accuracy.

Method used

Obtain the current frame image through the drone, determine the target detection frame, and adjust the drone position according to the detection frame to achieve automatic tracking, determine whether the target is lost and remind you to reselect, and use the preset algorithm and Kalman filter prediction algorithm to update the tracking box.

Benefits of technology

It reduces the user's manual operation workload, improves the drone's tracking accuracy of targets, and avoids poor tracking results caused by inaccurate manual operations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN111798482B_ABST
    Figure CN111798482B_ABST
Patent Text Reader

Abstract

The present invention discloses a target tracking method and device, which obtains a current frame image including a target through a drone, determines a detection frame corresponding to the target in the current frame image, determines a tracking frame of the target according to the detection frame corresponding to the determined target, and when a first target to be tracked is determined from the targets, adjusts the position of the drone according to the tracking frame of the first target so that the drone tracks the first target. In this way, the tracking frame of the target can be automatically determined, which solves the problem of the user manually drawing the tracking frame of the target, reduces the workload of the user, and avoids the problem of poor tracking effect of the drone on the target due to inaccurate manual drawing of the tracking frame by the user, thereby improving the accuracy of the drone's tracking of the target.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image processing technology, and in particular to a target tracking method and device. Background Art

[0002] With the continuous development of science and technology, drone target tracking technology has been widely used in the field. Therefore, users have higher and higher requirements for the reliability of drone target tracking.

[0003] However, in current technology, when a drone tracks a target, it is necessary to manually draw a tracking frame of the target so that the drone can track the target. Therefore, not only does it increase the workload of the user, but it may also reduce the accuracy of the drone's target tracking due to the inaccurate tracking frame manually drawn by the user.

[0004] Based on this, how to improve the accuracy of target tracking by UAVs is a technical problem that needs to be solved urgently by technical personnel in this field. Summary of the invention

[0005] The embodiment of the present invention provides a target tracking method and device, which are used to improve the accuracy of target tracking by a drone.

[0006] In a first aspect, an embodiment of the present invention provides a target tracking method, comprising:

[0007] When a current frame image including a target is acquired by the drone, a detection frame corresponding to the target in the current frame image is determined;

[0008] Determining a tracking frame of the target according to the determined detection frame corresponding to the target;

[0009] When a first target to be tracked is determined from the targets, the position of the drone is adjusted according to the tracking frame of the first target so that the drone tracks the first target.

[0010] Optionally, in the embodiment of the present invention, after determining the first target to be tracked from the targets, the method further includes:

[0011] When it is determined that the tracking of the first target is lost, a reminder message is generated to select a target to be tracked again from the targets.

[0012] Optionally, in the embodiment of the present invention, the determining whether the tracking of the first target is lost specifically includes:

[0013] Accumulating the confidence of the first target from the first frame image to the current frame image to obtain a parameter confidence;

[0014] Determining whether the reference confidence level is less than a first preset value;

[0015] If yes, it is determined that the first target tracking is lost;

[0016] If not, it is determined that the first target is not tracked and lost.

[0017] Optionally, in the embodiment of the present invention, determining whether the first target is lost in tracking specifically includes:

[0018] Determine whether the position of the tracking frame of the first target in N consecutively acquired image frames has not changed, and N is greater than or equal to a second preset value;

[0019] If yes, it is determined that the first target tracking is lost;

[0020] If not, it is determined that the first target is not tracked and lost.

[0021] Optionally, in the embodiment of the present invention, the drone includes a photographing device, and adjusting the position of the drone according to the tracking frame of the first target specifically includes:

[0022] Align the center position of the photographing field of view of the photographing device in the drone with the tracking frame of the first target.

[0023] Optionally, in the embodiment of the present invention, after determining the tracking frame of the target according to the determined detection frame corresponding to the target, and before adjusting the position of the drone according to the tracking frame of the first target, the method further includes:

[0024] The determined tracking frame of the target is updated according to a preset matching algorithm.

[0025] Optionally, in the embodiment of the present invention, before performing target recognition processing on the current frame image, the method further includes:

[0026] Perform image enhancement processing on the acquired current frame image.

[0027] Optionally, in the embodiment of the present invention, before determining the tracking frame of the target according to the determined detection frame corresponding to the target, the method further includes:

[0028] Screening the determined target;

[0029] The determined detection frame corresponding to the target is screened.

[0030] In a second aspect, an embodiment of the present invention further provides a target tracking device, including:

[0031] A memory for storing program instructions;

[0032] The processor is used to call the program instructions stored in the memory and execute according to the obtained program:

[0033] When a current frame image including a target is acquired by the drone, a detection frame corresponding to the target in the current frame image is determined;

[0034] Determining a tracking frame of the target according to the determined detection frame corresponding to the target;

[0035] When a first target to be tracked is determined from the targets, the position of the drone is adjusted according to the tracking frame of the first target so that the drone tracks the first target.

[0036] In a third aspect, an embodiment of the present invention provides a computer-readable non-volatile storage medium storing computer-executable instructions, wherein the computer-executable instructions are used to enable a computer to execute the above-mentioned target tracking method.

[0037] The beneficial effects of the present invention are as follows:

[0038] The embodiment of the present invention provides a target tracking method and device, which obtains a current frame image including a target through a drone, determines a detection frame corresponding to the target in the current frame image, determines a tracking frame of the target based on the detection frame corresponding to the determined target, and when a first target to be tracked is determined from the targets, adjusts the position of the drone based on the tracking frame of the first target so that the drone tracks the first target. In this way, the tracking frame of the target can be automatically determined, which solves the problem of the user manually drawing the tracking frame of the target, reduces the workload of the user, and avoids the problem of poor tracking effect of the drone on the target due to inaccurate manual drawing of the tracking frame by the user, thereby improving the accuracy of the drone's tracking of the target. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] Figure 1 A flow chart of a target tracking method provided in an embodiment of the present invention;

[0040] Figure 2 A flowchart of a second target tracking method provided in an embodiment of the present invention;

[0041] Figure 3 A flowchart of a third target tracking method provided in an embodiment of the present invention;

[0042] Figure 4 A flowchart of a method for updating a tracking frame provided in an embodiment of the present invention;

[0043] Figure 5 A flowchart of a method in Example 1 provided in an embodiment of the present invention;

[0044] Figure 6A schematic diagram of the structure of a target tracking device provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0045] The following will be combined with the accompanying drawings to describe in detail the specific implementation of a target tracking method and device provided by an embodiment of the present invention. It should be noted that the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.

[0046] The embodiment of the present invention provides a target tracking method, such as Figure 1 As shown, it may include:

[0047] S101, when a current frame image including a target is acquired by a drone, determining a detection frame corresponding to the target in the current frame image;

[0048] Among them, the current frame image acquired by the drone may include one target, or may include multiple targets, which is not limited here.

[0049] It should be noted that the drone can acquire images in real time (or at a certain period) and perform target recognition processing on the acquired images to determine whether the image contains the target; therefore, the recognition results may be in the following two situations:

[0050] The first case: the image includes the target;

[0051] The second case: the image does not include the target.

[0052] Therefore, according to the recognition result, if it is determined that the captured image does not include the target, the image can be discarded; if it is determined that the captured image includes the target, the image can continue to be recognized to determine the detection box corresponding to the target in the image.

[0053] Among them, the drone can collect the current frame image through the camera device, and can perform target recognition on the collected current frame image according to the YOLO model (or deep learning technology), so as to determine the types of targets such as pedestrians, motor vehicles, and non-motor vehicles, as well as detection frames such as pedestrian frames, motor vehicle frames, and non-motor vehicle frames.

[0054] Furthermore, the specific target recognition process can be implemented using existing technologies and will not be described in detail here.

[0055] To clarify, target types may include but are not limited to pedestrians, motor vehicles, and non-motor vehicles.

[0056] S102, determining a tracking frame of the target according to the detection frame corresponding to the determined target;

[0057] The specific implementation of step S102 may include:

[0058] Determine whether the current frame image is an initial frame image;

[0059] If yes, determine the target tracking frame by using the detection frame of the target included in the current frame image;

[0060] If not, the tracking frame of the current frame image is determined according to the tracking frame of the previous frame image according to the Kalman filter prediction algorithm.

[0061] It should be noted that the specific implementation process of determining the tracking frame of the current frame image according to the tracking frame of the previous frame image according to the Kalman filter prediction algorithm can be implemented using existing technologies and is not limited here.

[0062] S103: When a first target to be tracked is determined from the targets, the position of the drone is adjusted according to the tracking frame of the first target, so that the drone tracks the first target.

[0063] The method of determining the first target may include:

[0064] Method 1: The user selects a first target from the targets.

[0065] Method 2: Determine a first target through a preset algorithm.

[0066] In this way, the target tracking frame can be automatically determined, which solves the problem of users manually drawing the target tracking frame, reduces the user's workload, and avoids the problem of poor target tracking effect of the drone due to inaccurate tracking frame manually drawn by the user, thereby improving the accuracy of drone tracking of the target.

[0067] It should be noted that the implementation process of the above steps S101 to S103 can be understood as the following:

[0068] like Figure 2 shown.

[0069] S201, real-time transmission of images;

[0070] S202, target detection;

[0071] S203, determining multiple targets;

[0072] S204, selecting a first target;

[0073] S205, determine whether the first target being tracked is lost; if so, execute step S203; if not, execute step S206;

[0074] S206. Continue tracking the first target.

[0075] Therefore, the drone can acquire images in real time and perform target detection on the acquired images; then, for images including targets, if the image includes multiple targets, the tracking frames corresponding to each target can be determined respectively, and then when the first target is selected from the multiple targets, single target tracking is implemented for the first target. If the tracking of the first target is lost, a target can be selected again from the multiple targets and tracked.

[0076] In actual situations, when a drone tracks a target, it may be affected by the environment, occlusion by other targets, and intersection with other targets, which may cause the drone to lose its tracking target.

[0077] Therefore, in a specific implementation, in an embodiment of the present invention, after determining the first target to be tracked from the targets, the method further includes:

[0078] When it is determined that the tracking of the first target is lost, a reminder message is generated to select a target to be tracked again from the targets.

[0079] If the first target is determined by the user, then when it is determined that the tracking of the first target is lost, the generated reminder information can be displayed to the user, and the user can be reminded that the tracking of the first target has been lost, and the user can select the target to be tracked again from the determined targets;

[0080] If the first target is determined by a preset algorithm, then when it is determined that the tracking of the first target is lost, the generated reminder information can remind the determination module used to determine the first target that the tracking of the first target has been lost, so that the determination module can re-determine the target to be tracked from the determined targets.

[0081] In summary, by determining the first target in different ways, the objects receiving the reminder information (respectively: the user and the determination module) are different.

[0082] In this way, when the first target tracking is lost, the user can be reminded or the confirmation module can be informed that the first target tracking has been lost. This situation is more in line with the actual situation and also avoids the problem of the drone tracking other wrong targets (targets that the user does not need) due to target loss.

[0083] Specifically, when performing target tracking, the following processes may be included:

[0084] like Figure 3 shown.

[0085] S301, determining a first target in an acquired current frame image and a tracking frame corresponding to the first target;

[0086] S302, single target tracking algorithm;

[0087] Among them, the single target tracking algorithm can be understood as:

[0088] After determining the tracking frame of the first target, the tracking frame is passed into the single target tracking algorithm module to achieve tracking of the first target, and the single target tracking algorithm module can use deep convolutional network technology to achieve target tracking.

[0089] S303, determining a tracking frame corresponding to the first target in a subsequent frame image;

[0090] Among them, this step can be understood as:

[0091] For the target to be tracked (i.e., the first target mentioned in the above content), the single target tracking algorithm module only needs to input the current frame image and the tracking frame corresponding to the first target. Then, for the subsequent frame images (such as the next frame image), if target tracking is to be achieved, the subsequent frame images can be input into the single target tracking algorithm module, so that the corresponding tracking frame of the first target in the subsequent frame images can be automatically determined.

[0092] S304, the drone gimbal camera control module controls the position of the camera in the drone;

[0093] Among them, when controlling the position of the camera in the drone, it can be set to:

[0094] Control the center of the camera to approach or align with the tracking frame of the first target.

[0095] S305, determine whether the first target is lost; if not, execute step S302; if so, the process ends.

[0096] In this way, through the above process, single target tracking can be achieved, thereby realizing the tracking of the target by the drone.

[0097] Specifically, in the embodiment of the present invention, when determining whether the first target is lost in tracking, the following method may be used:

[0098] Method 1:

[0099] Optionally, in the embodiment of the present invention, determining whether the first target is lost in tracking specifically includes:

[0100] Accumulating the confidence of the first target from the first frame image to the current frame image to obtain a parameter confidence;

[0101] If so, it is determined that the first target tracking is lost;

[0102] If not, it is determined that the first target is not tracked and lost.

[0103] It should be noted that, for determining the confidence of the target, the confidence of the target can be determined simultaneously in the above step S101 but is not limited to it. As long as the confidence of the target is determined before the confidence is required for calculation, the time for determining the confidence of the target is not limited here.

[0104] The confidence level can also be called reliability. The higher the confidence level corresponding to a target, the smaller the possibility of the target being lost; the lower the confidence level corresponding to a target, the greater the possibility of the target being lost.

[0105] For example, taking the first frame image, the second frame image, and the third frame image as examples, the confidence of the first target in the first frame image is 0.3, the confidence of the first target in the second frame image is 0.5, and the confidence of the first target in the third frame image is 0.4, and the first preset value can be 0.7.

[0106] The confidence of the first target in the first frame, the second frame, and the third frame is accumulated to obtain the parameter confidence, that is, 0.3+0.5+0.4=0.8, so the parameter confidence is 0.8.

[0107] Because the reference confidence level 0.8 is greater than the first preset value 0.7, it can be determined that the first target is not tracked and lost.

[0108] It should be noted that the first preset value can be set according to the actual situation required by the user, and is not specifically limited here, so as to improve the flexibility of the design.

[0109] In this way, through the above simple calculation method, not only the processing load of the drone is reduced, but also it can be accurately determined whether the first target is lost, thereby reducing the complexity of the drone tracking target and having strong practicality.

[0110] Method 2:

[0111] Optionally, in the embodiment of the present invention, determining whether the first target is lost in tracking specifically includes:

[0112] Determine whether the position of the tracking frame of the first target in N consecutively acquired image frames has not changed, and N is greater than or equal to a second preset value;

[0113] If so, it is determined that the first target tracking is lost;

[0114] If not, it is determined that the first target is not tracked and lost.

[0115] For example, 5 frames of images and a second preset value of 4 are used as an example for description. The 5 frames of images are respectively a first frame of image, a second frame of image, a third frame of image, a fourth frame of image, and a fifth frame of image.

[0116] If the position of the tracking frame of the first target in the first frame, the second frame, the third frame, the fourth frame, and the fifth frame does not change, and 5 is greater than 4, it means that the tracking of the first target is lost, where target loss can be understood as the target being completely blocked or the distance between the target and the drone is too far;

[0117] That is to say, if the position of the tracking frame of the first target does not change in 4 consecutive frames or more in the 1st frame image, the 2nd frame image, the 3rd frame image, the 4th frame image, and the 5th frame image, it means that the tracking of the first target is lost; if the position of the tracking frame of the first target does not change in 4 consecutive frames or more, it can be said that the tracking of the first target is not lost.

[0118] It should be noted that the second preset value can be set according to the actual situation required by the user and is not specifically limited here.

[0119] In this way, by judging whether the first target is lost according to the position of the tracking frame, it can be determined whether the first target is lost in tracking. This method is simple and practical, and also reduces the complexity of the drone tracking target.

[0120] Of course, in actual situations, when determining whether the first target is lost in tracking, the above-mentioned method 1 or method 2 can be selected according to the actual situation to meet the needs of different application scenarios and improve the flexibility of the design.

[0121] In a specific implementation, in an embodiment of the present invention, the drone includes a photographing device, and adjusting the position of the drone according to the tracking frame of the first target specifically includes:

[0122] Align the center of the camera field of view of the camera in the drone with the tracking frame of the first target.

[0123] The flight angles of the rotors of the drone can be adjusted according to the tracking frame of the first target, so that the center position of the photographing field of view of the photographing device in the drone is always maintained near the tracking frame of the first target.

[0124] It should be noted that when adjusting the position of the drone, not only the flight angles of the drone's rotors can be adjusted, but also the orientation of the drone's camera device can be adjusted. As long as the center position of the camera's field of view can be aligned with the tracking frame of the first target, there is no limitation here.

[0125] In this way, the drone can accurately track the tracking frame of the target by adjusting the photographing field of view of the photographing device, avoiding the problem of target loss, enabling the drone to stably track the target, and also facilitating subsequent judgment of whether the first target is lost based on the position of the tracking frame of the first target.

[0126] In a specific implementation, in an embodiment of the present invention, after determining the tracking frame of the target according to the detection frame corresponding to the determined target, and before adjusting the position of the drone according to the tracking frame of the first target, the method further includes:

[0127] According to the preset matching algorithm, the tracking frame of the determined target is updated.

[0128] Among them, the cost matrix of the target detection frame and tracking frame can be determined based on the Mahalanobis distance of the appearance information, and the detection frame and the tracking frame can be matched one by one through cascade matching and IOU matching, and then the tracking frame is updated according to the matched detection frame.

[0129] For example, detection frame A is paired with tracking frame A one-to-one, and detection frame B is paired with tracking frame B one-to-one. Then detection frame A replaces tracking frame A to update tracking frame A; detection frame B replaces tracking frame B to update tracking frame B.

[0130] Specifically, the update process of the target tracking frame may include:

[0131] like Figure 4 shown.

[0132] S401, when determining the confidence and detection frame corresponding to the target in the current frame image, screening the confidence of the target and the detection frame corresponding to the target;

[0133] The specific screening process can be found in the following content.

[0134] S402, determine whether the current frame image is an initial frame image; if so, execute step S403; if not, execute step S404;

[0135] S403, using the detection frame to initialize the tracking frame; executing step S405;

[0136] Among them, using the detection frame to initialize the tracking frame can be understood as:

[0137] The detection frame of the target included in the current frame image is determined as the tracking frame of the target.

[0138] S404, using Kalman filter algorithm to predict the tracking frame;

[0139] Wherein, step S404 may specifically be:

[0140] The Kalman filter prediction algorithm is used to determine the tracking frame of the current frame image based on the tracking frame of the previous frame image.

[0141] S405, executing the cascade matching algorithm;

[0142] S406, executing the IOU matching algorithm;

[0143] S407: Update the tracking frame.

[0144] Among them, steps S405-S407 can be understood as follows:

[0145] According to the cascade matching algorithm and the IOU matching algorithm, the determined detection frame and the determined tracking frame are matched, and the tracking frame is updated according to the matched detection frame.

[0146] In this way, through cascade matching and IOU matching, the tracking frame corresponding to the detection frame can be accurately determined. Therefore, the tracking frame can be accurately replaced according to the detection frame, reducing errors that occur when updating the tracking frame (for example, the detection frame A in the above content replaces the tracking frame B, or the detection frame B replaces the tracking frame A), thereby improving the accuracy of drone target tracking.

[0147] In a specific implementation, in an embodiment of the present invention, before performing target recognition processing on the current frame image, the method further includes:

[0148] Perform image enhancement processing on the acquired current frame image.

[0149] The purpose of performing image enhancement processing on the acquired current frame image is to filter out the targets required by the user and to filter out irrelevant targets.

[0150] It should be noted that the current frame image may also be preprocessed, wherein the purpose of the preprocessing is the same as that of the above-mentioned image enhancement processing, and the repetitive parts are not repeated here.

[0151] Furthermore, filtering out the target required by the user from the current frame image is not limited to the above method, and any method known to those skilled in the art for filtering out the target required by the user may also be used, which is not limited here.

[0152] In this way, after the image enhancement processing is performed on the current frame image, the interference in the current frame image can be removed, that is, the invalid targets can be removed, which is helpful to screen out the targets required by the user from the current frame image.

[0153] In a specific implementation, in an embodiment of the present invention, before determining a tracking frame of the target according to the detection frame corresponding to the determined target, the method further includes:

[0154] Screening the identified targets;

[0155] The detection frame corresponding to the determined target is screened.

[0156] Among them, for the screening process of the target, the target can be screened according to the confidence of the target.

[0157] When the confidence of the target is less than a third preset value, removing the target;

[0158] When the confidence level of the target is greater than a third preset value, the target is retained.

[0159] It should be noted that the third preset value can be set according to the actual situation required by the user and is not specifically limited here to improve the flexibility of the design.

[0160] Furthermore, the screening process of the detection frame corresponding to the target can be performed according to the NMS algorithm.

[0161] To illustrate, there can be N detection boxes corresponding to the target, where N is an integer greater than or equal to 1, each target box includes the target (it can also be understood as: each target box detects the target and selects the target), and the N detection boxes are screened based on the NMS algorithm, that is, the detection box of the best target position is screened out from the N detection boxes.

[0162] The following is a detailed explanation of the screening of detection boxes based on the NMS algorithm.

[0163] For example, 6 detection frames are taken as an example for explanation.

[0164] Arrange the six detection boxes according to the category classification probability, from small to large probability A, B, C, D, E, F;

[0165] Starting from the maximum probability F, determine whether the overlap rate between A to E and F is greater than a fourth preset value;

[0166] Assuming that the overlap ratio of B and D with F is greater than a fourth preset value, then B and D are removed, while F is retained;

[0167] From A, C, and E, select E with the highest probability, and determine the overlap between E and A and C respectively;

[0168] Assuming that the overlap between A and C is greater than a fifth preset value, A and C are removed while E is retained.

[0169] In summary, the filtered detection frames are E and F, that is, the detection frames that are finally retained are E and F.

[0170] It should be noted that the number of detection boxes screened by the NMS algorithm is determined based on actual conditions and is not limited here to meet the needs of different scenarios.

[0171] Furthermore, the fourth and fifth preset values ​​may be set according to the actual situation required by the user and are not specifically limited here, thereby improving the flexibility of the design.

[0172] In this way, according to the screened targets and target frames, the drone can accurately track the targets and improve the accuracy of the drone's target tracking.

[0173] The target tracking method provided by the embodiment of the present invention is described below with reference to a specific embodiment.

[0174] Embodiment 1: Take the i-th frame image as an example for explanation. Figure 5 shown.

[0175] S501, obtaining the i-th frame image through the drone, and performing target recognition processing on the i-th frame image;

[0176] S502, determining the category of the target included in the i-th frame image, the confidence of the target, and the detection frame corresponding to the target;

[0177] S503, screening the targets according to their confidence levels;

[0178] S504, based on the NMS algorithm, screening the detection frame corresponding to the target;

[0179] S505, determining a tracking frame of the target according to the detection frame corresponding to the filtered target;

[0180] S506: According to the cascade matching algorithm and the IOU matching algorithm, the screened detection frame and the determined tracking frame are matched, and the tracking frame is updated according to the matched detection frame;

[0181] S507, the user selects a first target to be tracked from the determined targets;

[0182] S508, determining whether the first target is lost; if so, executing step S509; if not, executing step S510;

[0183] S509, reminding the user to select a target to be tracked again from the determined targets; executing step S508;

[0184] S510: Align the center position of the photographing field of view of the photographing device in the drone with the updated tracking frame corresponding to the first target.

[0185] It should be noted that after adjusting the position of the drone, the drone can continue to acquire the (i+1)th frame of image, and then repeat the above steps S501 to S510.

[0186] Based on the same inventive concept, an embodiment of the present invention provides a target tracking device, the structure of which is as follows: Figure 6 As shown, including:

[0187] Memory 601, used for storing program instructions;

[0188] The processor 602 is used to call the program instructions stored in the memory 601 and execute according to the obtained program:

[0189] When a current frame image including a target is acquired by the drone, a detection frame corresponding to the target in the current frame image is determined;

[0190] Determine the tracking frame of the target according to the detection frame corresponding to the determined target;

[0191] When a first target to be tracked is determined from the targets, the position of the drone is adjusted according to the tracking frame of the first target so that the drone tracks the first target.

[0192] Optionally, in this embodiment of the present invention, the processor 602 is further configured to:

[0193] After a first target to be tracked is determined from the targets, when it is determined that the tracking of the first target is lost, a reminder message for selecting a target to be tracked again from the targets is generated.

[0194] Optionally, in this embodiment of the present invention, the processor 602 is specifically configured to:

[0195] Accumulating the confidence of the first target from the first frame image to the current frame image to obtain a parameter confidence;

[0196] Determining whether the reference confidence is less than a first preset value;

[0197] If so, it is determined that the first target tracking is lost;

[0198] If not, it is determined that the first target is not tracked and lost.

[0199] Optionally, in this embodiment of the present invention, the processor 602 is specifically configured to:

[0200] Determine whether the position of the tracking frame of the first target in N consecutively acquired image frames has not changed, and N is greater than or equal to a second preset value;

[0201] If so, it is determined that the first target tracking is lost;

[0202] If not, it is determined that the first target is not tracked and lost.

[0203] Optionally, in this embodiment of the present invention, the processor 602 is specifically configured to:

[0204] Align the center of the camera field of view of the camera in the drone with the tracking frame of the first target.

[0205] Optionally, in this embodiment of the present invention, the processor 602 is further configured to:

[0206] After determining the tracking frame of the target according to the detection frame corresponding to the determined target, and before adjusting the position of the drone according to the tracking frame of the first target, the tracking frame of the determined target is updated according to a preset matching algorithm.

[0207] Optionally, in this embodiment of the present invention, the processor 602 is further configured to:

[0208] Before performing target recognition processing on the current frame image, image enhancement processing is performed on the acquired current frame image.

[0209] Optionally, in this embodiment of the present invention, the processor 602 is further configured to:

[0210] Before determining the tracking frame of the target according to the detection frame corresponding to the determined target, the determined target is screened;

[0211] The detection frame corresponding to the determined target is screened.

[0212] Based on the same inventive concept, an embodiment of the present invention provides a computer-readable non-volatile storage medium, which stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the above-mentioned target tracking method.

[0213] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device, so that the instructions executed by the processor of the computer or other programmable data processing device can implement one or more processes and / or blocks in the flowchart. Figure 1 A function specified in one or more boxes.

[0214] These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable memory produce a product including the instructions, which are implemented in the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0215] These computer program instructions may also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, whereby the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in one or more processes in the flowchart and / or one or more boxes in the block diagram.

[0216] Although the preferred embodiments of the present invention have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the present invention.

[0217] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.

Claims

1. A target tracking method, It is characterized in that include: When a current frame image including a target is acquired by the drone, a detection frame corresponding to the target in the current frame image is determined; Determine a tracking frame of a current frame image corresponding to the target according to a tracking frame of a previous frame image corresponding to the target; According to a preset matching algorithm, each detection frame is matched with each tracking frame, and the corresponding tracking frame is updated according to the matched detection frame to obtain the latest tracking frame corresponding to the target in the current frame image; wherein, if the current frame image is the first frame image, the detection frame corresponding to the target is used as the latest tracking frame; When a first target to be tracked is determined from the targets and it is determined that the first target is not tracked and lost, adjusting the position of the drone according to the latest tracking frame of the first target so that the drone tracks the first target; Wherein, when one of the following conditions is met, it is determined that the first target tracking is lost: Accumulating the confidence of the first target from the first frame image to the current frame image to obtain a reference confidence, where the reference confidence is less than a first preset value; The position of the latest tracking frame of the first target in the N consecutively acquired image frames does not change, and N is greater than or equal to a second preset value; Before determining the tracking frame of the current frame image corresponding to the target according to the tracking frame of the previous frame image corresponding to the target, the method further includes: Screening the target according to the determined confidence level of the target; The determined detection frame corresponding to the target is screened.

2. The method according to claim 1, It is characterized in that When it is determined that the tracking of the first target is lost, a reminder message is generated to select a target to be tracked again from the targets.

3. The method according to claim 1, It is characterized in that The drone includes a camera, and adjusting the position of the drone according to the latest tracking frame of the first target specifically includes: The center position of the photographing field of view of the photographing device in the drone is aligned with the latest tracking frame of the first target.

4. The method according to claim 1, It is characterized in that Before performing target recognition processing on the current frame image, the method further includes: Perform image enhancement processing on the acquired current frame image.

5. A target tracking device, It is characterized in that include: A memory for storing program instructions; The processor is used to call the program instructions stored in the memory and execute according to the obtained program: When a current frame image including a target is acquired by the drone, a detection frame corresponding to the target in the current frame image is determined; Determine a tracking frame of a current frame image corresponding to the target according to a tracking frame of a previous frame image corresponding to the target; According to a preset matching algorithm, each detection frame is matched with each tracking frame, and the corresponding tracking frame is updated according to the matched detection frame to obtain the latest tracking frame corresponding to the target in the current frame image; wherein, if the current frame image is the first frame image, the detection frame corresponding to the target is used as the latest tracking frame; When a first target to be tracked is determined from the targets, and when it is determined that the first target is not tracked and lost, adjusting the position of the drone according to the latest tracking frame of the first target, so that the drone tracks the first target; Wherein, when one of the following conditions is met, it is determined that the first target tracking is lost: Accumulating the confidence of the first target from the first frame image to the current frame image to obtain a reference confidence, where the reference confidence is less than a first preset value; The position of the latest tracking frame of the first target in the N consecutively acquired image frames does not change, and N is greater than or equal to a second preset value; Before determining the tracking frame of the current frame image corresponding to the target according to the tracking frame of the previous frame image corresponding to the target, the processor is further used to: Screening the target according to the determined confidence level of the target; The determined detection frame corresponding to the target is screened.

6. A computer-readable non-volatile storage medium, It is characterized in that The computer-readable non-volatile storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the target tracking method described in any one of claims 1-4.