Target labeling quality inspection method, device, computer equipment and storage medium

By reading video frames, extracting front and rear frame images and calculating reference annotation results, it solves the problem of low efficiency of target annotation quality inspection in traditional technology, realizes automated annotation quality assessment, and improves the annotation accuracy and accuracy in multi-target tracking technology. efficiency.

CN112233171BActive Publication Date: 2024-09-20刘丽
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202010914973.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-09-03
Publication Date
2024-09-20
Estimated Expiration
2040-09-03

AI Technical Summary

Technical Problem

In multi-target tracking technology, traditional target annotation quality inspection is inefficient, especially when the amount of data is large, it is difficult to effectively measure the accuracy of the annotation results.

Method used

By reading the annotated video frames, querying multi-frame images of the same target, extracting the previous and next frame images, calculating the reference annotation results, and testing the annotation quality based on indicators such as the intersection ratio and reducing the reliance on manual naked eye observation.

Benefits of technology

It improves the efficiency of target annotation quality inspection, especially in scenarios with large amounts of data, and can automatically evaluate and measure the accuracy of annotation results, reducing manual errors.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112233171B
    Figure CN112233171B
Patent Text Reader

Abstract

The present application relates to a method, device, computer equipment and storage medium for inspecting the quality of target annotation. The method comprises: reading annotated video frames; querying the video frames to obtain multiple frames containing the same target, wherein the multiple frames include the actual annotation results of the same target, and the multiple frames are arranged in chronological order; extracting the previous frame image and the next frame image corresponding to the current frame image from the queried multiple frames according to the chronological order; calculating the reference annotation result of the target in the current frame image according to the actual annotation result of the target in the previous frame image and the actual annotation result of the target in the next frame image; and inspecting the annotation quality of the actual annotation result of the target in the current frame image according to the reference annotation result. The use of this method can improve processing efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of artificial intelligence technology, and in particular to a method, device, computer equipment and storage medium for inspecting target labeling quality. Background Art

[0002] With the development of artificial intelligence technology, multi-target tracking technology has emerged, which has important application scenarios in the fields of smart transportation, smart cities, etc. In order to promote the development of this field, the corresponding multi-target tracking dataset plays a great role, so it is necessary to manually calibrate the relevant data.

[0003] In traditional technology, the location of the target object is very important information in the labeling work. In order to ensure the accuracy of the target frame, the quality of the labeling results needs to be measured.

[0004] However, currently observation by naked eyes is a relatively reliable method, but it is inefficient for scenarios with particularly large amounts of data. Summary of the invention

[0005] Based on this, it is necessary to provide a target labeling quality inspection method, device, computer equipment and storage medium that can improve efficiency in response to the above technical problems.

[0006] A method for inspecting target labeling quality, the method comprising:

[0007] Read the annotated video frame;

[0008] Querying the video frame to obtain multiple frames of images containing the same object, wherein the multiple frames of images include actual annotation results of the same object, and the multiple frames of images are arranged in chronological order;

[0009] Extracting the previous frame image and the next frame image corresponding to the current frame image from the queried multiple frame images according to the time sequence;

[0010] Calculating a reference marking result of the target in the current frame image according to the actual marking result of the target in the previous frame image and the actual marking result of the target in the subsequent frame image;

[0011] The labeling quality of the actual labeling result of the target in the current frame image is checked according to the reference labeling result.

[0012] In one embodiment, the previous frame image and the subsequent frame image each include at least one frame; and the step of calculating a reference annotation result of the target in the current frame image according to an actual annotation result of the target in the previous frame image and an actual annotation result of the target in the subsequent frame image includes:

[0013] Respectively extract at least one frame in the preceding frame image and at least one frame in the succeeding frame image to form a plurality of detection pairs;

[0014] Obtaining respectively the actual labeling result of the target in each frame of the preceding frame image and the actual labeling result of the target in each frame of the succeeding frame image in each group of detection pairs;

[0015] Acquire, in time sequence, a first distance from each frame in the previous frame image to the current frame image, and a second distance from each frame in the subsequent frame image to the current frame image in each group of detection pairs;

[0016] Calculate the weight of each frame in each group of detection pairs according to the first distance and the second distance;

[0017] Calculate the initial labeling result of the target in the current frame image according to the weight and the actual labeling result of the target in each frame in each group of detection pairs;

[0018] The initial annotation results are fused to obtain a reference annotation result of the target in the current frame image.

[0019] In one embodiment, the step of calculating the weight of each frame in each detection pair according to the first distance and the second distance includes:

[0020] Calculate the total number of copies according to the first distance and the second distance;

[0021] Calculate the weight corresponding to each frame in the previous frame image according to the first distance from each frame in the previous frame image to the current frame image and the total number of copies;

[0022] The weight corresponding to each frame in the subsequent frame image is calculated based on the second distance from each frame in the subsequent frame image to the current frame image and the total number of copies.

[0023] In one embodiment, the step of verifying the quality of the actual annotation result of the target in the current frame image according to the reference annotation result includes:

[0024] Calculating an intersection-over-union ratio of the reference annotation result and the actual annotation result;

[0025] The quality of the actual labeling result of the target in the current frame image is measured according to the size of the intersection-over-union ratio.

[0026] In one embodiment, the method further comprises:

[0027] Acquire attribute information of the target in the preceding frame image and the succeeding frame image;

[0028] The labeling quality of the attribute information of the target in the current frame image is checked according to the attribute information.

[0029] In one embodiment, querying the video frame to obtain multiple frames of images containing the same object includes:

[0030] Read the video frames in sequence according to the time sequence of the video frames, and extract the target identifiers of the targets marked in the video frames;

[0031] The target identifiers are stored according to a sorting rule of the target identifiers, and a video frame containing a target corresponding to the same target identifier is associated with the stored target identifier;

[0032] According to the sorting rules of the target identifiers, verify whether the stored target identifiers are complete;

[0033] When the stored target identification is complete, the preceding frame image and the succeeding frame image corresponding to the current frame image are continuously extracted from the queried multiple frame images according to the time sequence, otherwise a prompt indicating a reading error is output.

[0034] In one embodiment, the target identifier is generated according to an incremental generation method, and the incremental generation method of the target identifier includes:

[0035] Receive input of new target confirmation instructions;

[0036] Acquire the maximum value of the historical target identifier according to the new target confirmation instruction, and increment the maximum value;

[0037] An association relationship between the annotation box corresponding to the new target and the incremented maximum value is established.

[0038] A target labeling quality detection device, the device comprising:

[0039] A reading module is used to read the annotated video frames;

[0040] A query module, used for querying the video frame to obtain multiple frames of images containing the same object, wherein the multiple frames of images include actual annotation results of the same object, and the multiple frames of images are arranged in chronological order;

[0041] An extraction module, used for extracting a previous frame image and a subsequent frame image corresponding to a current frame image from the queried multiple frame images according to a time sequence;

[0042] A reference annotation result generating module, used for calculating a reference annotation result of the target in the current frame image according to the actual annotation result of the target in the previous frame image and the actual annotation result of the target in the subsequent frame image;

[0043] The detection module is used to check the annotation quality of the actual annotation result of the target in the current frame image according to the reference annotation result.

[0044] A computer device comprises a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the above method when executing the computer program.

[0045] A computer-readable storage medium stores a computer program, which implements the steps of the above method when executed by a processor.

[0046] The above-mentioned target annotation quality inspection method, device, computer equipment and storage medium obtain a reference annotation result based on the actual annotation results of the previous frame image and the subsequent frame of the same target, and then detect the actual annotation result of the target in the current frame image based on the reference annotation result. It does not require manual observation of each target by the naked eye, which improves efficiency for scenes with particularly large amounts of data. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] Figure 1 A schematic diagram of a process of a target labeling quality detection method in an embodiment;

[0048] Figure 2 A schematic diagram of marking results in one embodiment;

[0049] Figure 3 for Figure 1 A flowchart of step S108 in the illustrated embodiment;

[0050] Figure 4 for Figure 1 A flowchart of step S104 in the illustrated embodiment;

[0051] Figure 5 is a structural block diagram of a target labeling quality detection device in an embodiment;

[0052] Figure 6 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0053] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0054] In one embodiment, Figure 1As shown, a method for inspecting target labeling quality is provided. This embodiment uses the method applied to a terminal as an example. It can be understood that the method can also be applied to a server, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:

[0055] S102: Read the annotated video frame.

[0056] Specifically, in the process of labeling multi-target tracking datasets, it is necessary to give the specific location of the same target (i.e., the same target ID) at different times, such as Figure 2 As shown in the figure, the three targets have different coordinate information at different times. The annotation needs to include the position information of the three targets at different times. In order to measure the annotation quality, the annotation results need to be given.

[0057] The results of the annotation of different objects in each video frame may include the position and size of the annotation box, wherein the position may be identified by the coordinates of the key points, and the size may be identified by the width and height. The annotation box may be a box of different shapes. When the annotation box is a rectangular box, the rectangular box may be uniquely determined by the coordinates of the upper left corner of the rectangular box (x, y) and the width and height (w, h) of the rectangular box.

[0058] S104: querying the video frame to obtain multiple frames of images containing the same object, the multiple frames of images include actual annotation results of the same object, and the multiple frames of images are arranged in chronological order.

[0059] Specifically, since the movement of a target at adjacent moments changes continuously, the video frame can be queried to obtain multiple frames of images corresponding to a target. For example, the first frame of the video frame is read in chronological order, the multiple targets included therein are read, and then a target group is established. A relationship is established between the first frame of the video frame and the target group, and then the next frame of the video frame is read, the multiple targets included therein are read, and if there is a target corresponding to the established target group, the video frame is assigned to the target group. If a new target appears, a new target group is created. If there is no target corresponding to the established target group, it means that the video frames corresponding to the established target group have all been selected.

[0060] It should be noted that in each target group, the video frames are arranged in chronological order. This is because the movement of a target at adjacent moments changes continuously. Therefore, the quality of the annotation results of each video frame is evaluated based on this characteristic. For this evaluation, the video frames need to be arranged in chronological order.

[0061] S106: extracting a previous frame image and a subsequent frame image corresponding to the current frame image from the queried multiple frame images according to the time sequence.

[0062] S108: Calculate a reference annotation result of the target in the current frame image according to the actual annotation result of the target in the previous frame image and the actual annotation result of the target in the subsequent frame image.

[0063] Specifically, the previous frame image refers to a video frame that is located before the current frame image in time sequence, and the subsequent frame image refers to a video frame that is located after the current frame image in time sequence.

[0064] In order to measure the accuracy of the target position annotation, a difference method is used for automatic evaluation, that is, the target position annotated before time t and after time t is used to verify the target position at time t. The assumption of this method is that the movement of a target at adjacent moments is continuously changing, so the position of the target at the intermediate moment can be obtained by the position difference of the adjacent frames. And in order to ensure the correctness, the previous frame image and the subsequent frame image of the current frame image are taken into account.

[0065] Specifically, the terminal obtains the actual annotation result of the target in the previous frame image and the actual annotation result of the target in the subsequent frame image, and then calculates the reference annotation result of the target in the current frame image based on the actual annotation result obtained. For example, assuming that the actual annotation result of the current frame image is (x1, y1, w1, h1), where the actual annotation result of the same target in the previous frame image is (x0, y0, w0, h0), and the actual annotation result of the same target in the subsequent frame image is (x2, y2, w2, h2), then the reference annotation result can be obtained based on the actual annotation result of the same target in the previous frame image being (x0, y0, w0, h0) and the actual annotation result of the same target in the subsequent frame image being (x2, y2, w2, h2), for example

[0066] S110: According to the reference annotation result, the annotation quality of the actual annotation result of the target in the current frame image is checked.

[0067] Specifically, the reference annotation result is matched with the actual annotation result of the target in the current frame image. If there is a high match, for example, the matching degree is greater than a preset value, the annotation result is highly credible. Otherwise, the annotation of one of the three frames of images is not accurate enough and needs to be re-annotated. Therefore, the terminal can annotate the three frames of images, for example, output them after annotating the problems, so that the user can check the three images and manually find the images with problems in the annotations for re-annotation.

[0068] The above-mentioned target annotation quality inspection method obtains a reference annotation result based on the previous frame image and the actual annotation results in the subsequent frame of the same target, and then detects the actual annotation result of the target in the current frame image based on the reference annotation result. It does not require manual observation one by one with the naked eye, which improves efficiency for scenes with particularly large amounts of data.

[0069] In one embodiment, see Figure 3 As shown, Figure 3 for Figure 1 The flowchart of step S108 in the illustrated embodiment, step S108, i.e., both the previous frame image and the subsequent frame image include at least one frame; according to the actual labeling result of the target in the previous frame image and the actual labeling result of the target in the subsequent frame image, calculating the reference labeling result of the target in the current frame image includes:

[0070] S302: extract at least one frame in the previous frame image and at least one frame in the subsequent frame image to form a plurality of detection pairs.

[0071] Specifically, in order to improve the accuracy of the detection results, that is, to improve the accuracy of the reference annotation results, the terminal generates reference annotation results through multiple groups of video frame images. Therefore, the terminal first extracts multiple frames of video from the video frames corresponding to the target to form multiple groups of detection pairs, and each group of detection pairs includes at least one frame in the previous frame image and one frame in the next frame image. For example, assuming that target A corresponds to 9 frames of video frames, the serial numbers are 1 to 9, where the 4th frame is the current frame image, the 1st to 3rd frames are the previous frame images, and the 5th to 9th frames are the next frame images. The terminal can extract at least one frame from the 1st to 3rd frames respectively, and then extract at least one frame from the 5th to 9th frames to form a group of detection pairs. In order to improve accuracy, the terminal can extract multiple groups of detection pairs.

[0072] S304: Obtaining respectively the actual labeling result of the target in each frame of the preceding frame image and the actual labeling result of the target in each frame of the succeeding frame image in each detection pair.

[0073] Specifically, this step is mainly to obtain the actual labeling result of each frame in each detection pair. Specifically, the terminal reads the labeling result of the target in the frame image according to the target identifier of the target.

[0074] S306: Obtaining, in time sequence, a first distance from each frame in the previous frame image to the current frame image, and a second distance from each frame in the subsequent frame image to the current frame image in each detection pair.

[0075] Specifically, the first distance and the second distance here may be distances between video frames. For example, the distance between the nth video frame and the mth video frame arranged in time sequence is mn, where m>n.

[0076] S308: Calculate the weight of each frame in each detection pair according to the first distance and the second distance.

[0077] Specifically, the weight is used to measure the importance of each frame of video in the detection pair when generating the reference annotation result. Optionally, the weight of each frame in each group of detection pairs is calculated according to the first distance and the second distance, including: calculating the total number of copies according to the first distance and the second distance; calculating the weight corresponding to each frame in the previous frame image according to the first distance and the total number of copies from each frame in the previous frame image to the current frame image; calculating the weight corresponding to each frame in the subsequent frame image according to the second distance and the total number of copies from each frame in the subsequent frame image to the current frame image. The total number of copies is the sum of the maximum value in the first distance and the maximum value in the second distance. For example, there are 2 frames of images in a group of detection pairs, one in the previous frame image and one in the subsequent frame image, and the distances from the previous frame image and the subsequent frame image to the current frame image are both 1, that is, the previous frame image and the subsequent frame image are adjacent to the current frame image, and the weights of the previous frame image and the subsequent frame image = 1 / (1+1) = 1 / 2.

[0078] S310: Calculate the initial labeling result of the target in the current frame image according to the weight and the actual labeling result of the target in each frame in each detection pair.

[0079] Specifically, the initial annotation result here refers to the actual annotation result generated according to the target of each frame in each detection pair. As shown above, the initial annotation result = weight * annotation result corresponding to the previous frame image + weight * annotation result corresponding to the next frame image.

[0080] S312: Fusing the initial annotation results to obtain a reference annotation result of the target in the current frame image.

[0081] Specifically, the reference annotation result is obtained by fusing the initial annotation results, for example, calculating the average value of all initial annotation results to obtain the corresponding reference annotation result.

[0082] In the above embodiment, a plurality of detection pairs are set for detection, and the results of the plurality of detection pairs are integrated to make the reference marking result more accurate.

[0083] In one of the embodiments, the annotation quality of the actual annotation result of the target in the current frame image is checked based on the reference annotation result, including: calculating the intersection-and-union ratio of the reference annotation result and the actual annotation result; and measuring the annotation quality of the actual annotation result of the target in the current frame image based on the size of the intersection-and-union ratio.

[0084] Specifically, the reference annotation result and the actual annotation result are both annotation boxes, so the terminal calculates the intersection-and-union ratio of the reference annotation result and the actual annotation result, that is, (the intersection of the reference annotation result and the actual annotation result) / (the union of the reference annotation result and the actual annotation result), and measures the annotation quality of the actual annotation result of the target in the current frame image according to the size of the intersection-and-union ratio. For example, the larger the intersection-and-union ratio, the higher the overlap between the reference annotation result and the actual annotation result, and the more credible the actual annotation result is. Otherwise, the actual annotation result is unreliable.

[0085] In the above embodiment, the processing is performed by using the intersection-over-union ratio, and the quality of the actual annotation result of the target in the current frame image is measured according to the size of the intersection-over-union ratio, which is simpler and more reliable.

[0086] In one of the embodiments, the above-mentioned target annotation quality inspection method further includes: acquiring attribute information of the target in the previous frame image and the subsequent frame image; and inspecting the annotation quality of the attribute information of the target in the current frame image according to the attribute information.

[0087] Specific attribute information refers to the attribute information of the target marked during the marking process, such as the color, texture and other information of the target. Since this information remains unchanged, the terminal can obtain the attribute information of the same target in the previous frame image and the subsequent frame image, and then determine whether the attribute information of the same target in the current frame image is the same as the attribute information of the same target in the previous frame image and the subsequent frame image. If they are the same, the marking quality is high, otherwise, the marking quality is low. Optionally, the terminal can also record the position and attributes of the target, and output the corresponding position and attribute marking quality results to guide the user. For example, if there is a problem with the position marking, the problem with the position marking is directly output, and the user only needs to check the problem of the position, without checking the problem of the attribute, thereby reducing the user's processing workload.

[0088] In one embodiment, see Figure 4 As shown, Figure 4 for Figure 1 The flowchart of step S104 in the illustrated embodiment, step S104, i.e. querying the video frame to obtain multiple frames of images containing the same object, includes:

[0089] S402: Read the video frames in sequence according to the time sequence of the video frames, and extract the target identifiers of the marked targets in the video frames.

[0090] Specifically, since the target identification is generated in an incremental manner, when the video frames are arranged in chronological order, the target identification is also acquired in an incremental manner without omission or reduction.

[0091] Among them, the target identification is generated according to the incremental generation method, and the incremental generation method of the target identification includes: receiving the input new target confirmation instruction; obtaining the maximum value of the historical target identification according to the new target confirmation instruction, and increasing the maximum value; establishing the association relationship between the annotation box corresponding to the new target and the maximum value after the increment. That is, in the process of annotation, when the user finds a new target, he clicks the target identification increment button to establish the target identification corresponding to the new target, for example, obtaining the maximum value of the historical target identification, and increasing the maximum value to obtain the new target identification, and establishing the association relationship between the annotation box corresponding to the new target and the maximum value after the increment. In this way, the user does not need to number, only needs to click once, which improves the processing efficiency. Since the annotation process is also carried out in the time sequence of the video frames, when reading, the video frames are read in sequence according to the time sequence of the video frames, and the target identification of the read target should also be incremental.

[0092] S404: Storing the target identifiers according to the sorting rule of the target identifiers, and associating the video frames containing the targets corresponding to the same target identifier with the stored target identifiers.

[0093] S406: Check whether the stored target identifiers are complete according to the sorting rule of the target identifiers.

[0094] Specifically, the terminal stores the target identifier read in the current frame in ascending order. If it is the same as the target identifier of the stored target group, the current frame is assigned to the corresponding target group. If it is different from the target identifier of the stored target group, a new target group is established and the current frame is assigned to the new target group.

[0095] The verification of whether the stored target identification is complete is to determine whether the target identification is found in an incremental manner. If there is a gap in the target identification, it means that there is a possibility that the marked target has not been read or stored, so the terminal can issue a prompt to remind the user that there is an undetected marking result.

[0096] S408: When the stored target identification is complete, continue to extract the previous frame image and the subsequent frame image corresponding to the current frame image from the queried multiple frame images according to the time sequence, otherwise output a prompt of a reading error.

[0097] Specifically, when the stored target identification is complete, the subsequent processing can be continued, that is, extracting the previous frame image and the subsequent frame image corresponding to the current frame image.

[0098] In practical application, when the terminal extracts the target identification, it first reads the first frame of video frame, reads the target identification of the target therein, and establishes a target group, wherein the target group corresponds to the target identification, and is also incremental. When there are 3 targets in the first frame of video, the corresponding target group is generated in an incremental manner, and then the next frame of video frame is read, and the multiple targets included therein are read. If there is a target corresponding to the established target group, the video frame is attributed to the target group. If a new target appears, a new target group is created. If there is no target corresponding to the established target group, the video frame corresponding to the established target group is selected to be completed. For example, there are 4 targets in the next frame, and 3 are the same as the original ones, and they are attributed to the corresponding target group. For the new target, first, its target identification can be verified to be in accordance with the incremental manner. If so, a new target group is established. If not, it indicates that a part of the marked result has been lost. In other embodiments, it can also be after a section of video processing is completed, and then the target identification is uniformly verified to be obtained in an incremental manner, that is, whether there is omission, if otherwise, the prompt of the read error is output.

[0099] In the above embodiment, the accuracy of reading the annotation result is verified by means of generating the target identifier, thereby ensuring the correctness of the read data and further ensuring the correctness of the subsequent annotation quality measurement.

[0100] It should be understood that although Figure 1 , Figure 3 and Figure 4 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, Figure 1 , Figure 3 and Figure 4 At least part of the steps may include multiple steps or multiple stages. These steps or stages are not necessarily performed at the same time, but can be performed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed in turn or alternately with other steps or at least part of the steps or stages in other steps.

[0101] In one embodiment, Figure 5 As shown, a target annotation quality inspection device is provided, comprising: a reading module 100, a query module 200, an extraction module 300, a reference annotation result generation module 400 and a detection module 500, wherein:

[0102] A reading module 100 is used to read the annotated video frame;

[0103] A query module 200 is used to query a video frame to obtain multiple frames of images containing the same object, wherein the multiple frames of images include actual annotation results of the same object, and the multiple frames of images are arranged in chronological order;

[0104] An extraction module 300 is used to extract a previous frame image and a subsequent frame image corresponding to a current frame image from the queried multiple frame images according to a time sequence;

[0105] A reference annotation result generating module 400 is used to calculate a reference annotation result of the target in the current frame image according to the actual annotation result of the target in the previous frame image and the actual annotation result of the target in the next frame image;

[0106] The detection module 500 is used to check the annotation quality of the actual annotation result of the target in the current frame image according to the reference annotation result.

[0107] In one embodiment, the previous frame image and the subsequent frame image each include at least one frame; the reference annotation result generation module 400 includes:

[0108] A detection pair generating unit, used for respectively extracting at least one frame in the previous frame image and at least one frame in the subsequent frame image to form a plurality of detection pairs;

[0109] A result acquisition unit, used to respectively acquire an actual labeling result of a target in each frame of a preceding frame image and an actual labeling result of a target in each frame of a succeeding frame image in each group of detection pairs;

[0110] A distance acquisition unit, used for respectively acquiring a first distance from each frame in the previous frame image to the current frame image, and a second distance from each frame in the subsequent frame image to the current frame image in each detection pair according to a time sequence;

[0111] A weight calculation unit, used to calculate the weight of each frame in each group of detection pairs according to the first distance and the second distance;

[0112] An initial annotation result calculation unit, used to calculate an initial annotation result of the target in the current frame image according to the weight and the actual annotation result of the target in each frame in each set of detection pairs;

[0113] The fusion unit is used to fuse the initial annotation results to obtain the reference annotation results of the target in the current frame image.

[0114] In one embodiment, the weight calculation unit includes:

[0115] A total number of copies calculating subunit, used to calculate the total number of copies according to the first distance and the second distance;

[0116] The weight calculation subunit is used to calculate the weight corresponding to each frame in the previous frame image according to the first distance from each frame in the previous frame image to the current frame image and the total number of copies; and to calculate the weight corresponding to each frame in the subsequent frame image according to the second distance from each frame in the subsequent frame image to the current frame image and the total number of copies.

[0117] In one embodiment, the inspection module includes:

[0118] An intersection-and-union ratio calculation unit, used to calculate the intersection-and-union ratio of the reference annotation result and the actual annotation result;

[0119] The verification unit is used to measure the quality of the actual annotation results of the target in the current frame image according to the size of the intersection-over-union ratio.

[0120] In one embodiment, the above-mentioned target labeling quality inspection device may further include:

[0121] An attribute information acquisition module, used to acquire attribute information of the target in the previous frame image and the subsequent frame image;

[0122] The above-mentioned inspection module is also used to inspect the annotation quality of the attribute information of the target in the current frame image according to the attribute information.

[0123] In one embodiment, the query module 200 includes:

[0124] A target identification extraction unit is used to read the video frames in sequence according to the time sequence of the video frames, and extract the target identification of the target marked in the video frame;

[0125] An associative storage unit, used to store the target identifiers according to the sorting rule of the target identifiers, and associate the video frames containing the targets corresponding to the same target identifier with the stored target identifiers;

[0126] The verification unit is used to verify whether the stored target identification is complete according to the sorting rules of the target identification; when the stored target identification is complete, the previous frame image and the subsequent frame image corresponding to the current frame image are extracted from the queried multiple frame images according to the time sequence, otherwise a read error prompt is output.

[0127] In one embodiment, the target identification is generated according to an incremental generation method; the target labeling quality inspection device may also include:

[0128] A receiving module, used for receiving an input new target confirmation instruction;

[0129] An incrementing module is used to obtain the maximum value of the historical target identifier according to the new target confirmation instruction, and increment the maximum value;

[0130] The association relationship establishment module is used to establish an association relationship between the annotation box corresponding to the new target and the incremented maximum value.

[0131] For the specific definition of the target labeling quality inspection device, please refer to the definition of the target labeling quality inspection method above, which will not be repeated here. Each module in the above-mentioned target labeling quality inspection device can be implemented in whole or in part by software, hardware and a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.

[0132] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Figure 6 As shown. The computer device includes a processor, a memory, a communication interface, a display screen and an input device connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be achieved through WIFI, an operator network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a target marking quality inspection method is implemented. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covered on the display screen, or a button, trackball or touchpad set on the computer device housing, or an external keyboard, touchpad or mouse, etc.

[0133] Those skilled in the art will understand that Figure 6 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0134] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the following steps when executing the computer program: reading a video frame that has been annotated; querying the video frame to obtain multiple frames of images containing the same target, wherein the multiple frames of images include actual annotation results of the same target, and the multiple frames of images are arranged in chronological order; extracting a previous frame image and a subsequent frame image corresponding to a current frame image from the queried multiple frames of images according to the chronological order; calculating a reference annotation result of the target in the current frame image according to the actual annotation result of the target in the previous frame image and the actual annotation result of the target in the subsequent frame image; and verifying the annotation quality of the actual annotation result of the target in the current frame image according to the reference annotation result.

[0135] In one embodiment, the previous frame image and the subsequent frame image involved when the processor executes the computer program both include at least one frame; the calculation of the reference annotation result of the target in the current frame image according to the actual annotation result of the target in the previous frame image and the actual annotation result of the target in the subsequent frame image implemented when the processor executes the computer program includes: extracting at least one frame in the previous frame image and at least one frame in the subsequent frame image to form multiple groups of detection pairs; respectively obtaining the actual annotation result of the target in each frame in the previous frame image and the actual annotation result of the target in each frame in the subsequent frame image in each group of detection pairs; respectively obtaining the first distance from each frame in the previous frame image to the current frame image and the second distance from each frame in the subsequent frame image to the current frame image in each group of detection pairs according to the time sequence; calculating the weight of each frame in each group of detection pairs according to the first distance and the second distance; calculating the initial annotation result of the target in the current frame image according to the weight and the actual annotation result of the target in each frame in each group of detection pairs; fusing the initial annotation results to obtain the reference annotation result of the target in the current frame image.

[0136] In one embodiment, the weight of each frame in each group of detection pairs is calculated based on the first distance and the second distance when the processor executes a computer program, including: calculating the total number of copies based on the first distance and the second distance; calculating the weight corresponding to each frame in the previous frame image based on the first distance from each frame in the previous frame image to the current frame image and the total number of copies; calculating the weight corresponding to each frame in the subsequent frame image based on the second distance from each frame in the subsequent frame image to the current frame image and the total number of copies.

[0137] In one embodiment, the processor executes a computer program to verify the quality of the actual annotation result of the target in the current frame image based on the reference annotation result, including: calculating the intersection-and-union ratio of the reference annotation result and the actual annotation result; and measuring the quality of the actual annotation result of the target in the current frame image according to the size of the intersection-and-union ratio.

[0138] In one embodiment, when the processor executes the computer program, the following steps are implemented: obtaining attribute information of the target in the previous frame image and the subsequent frame image; and checking the annotation quality of the attribute information of the target in the current frame image based on the attribute information.

[0139] In one embodiment, the query video frame implemented when the processor executes the computer program obtains multiple frame images containing the same target, including: reading the video frames in sequence according to the time sequence of the video frames, and extracting the target identifiers of the targets marked in the video frames; storing the target identifiers according to the sorting rules of the target identifiers, and associating the video frames containing the targets corresponding to the same target identifier with the stored target identifiers; checking whether the stored target identifiers are complete according to the sorting rules of the target identifiers; when the stored target identifiers are complete, continuing to extract the previous frame image and the next frame image corresponding to the current frame image from the queried multiple frame images according to the time sequence, otherwise outputting a prompt of a reading error.

[0140] In one embodiment, the target identifier involved when the processor executes a computer program is generated according to an incremental generation method. The incremental generation method of the target identifier implemented when the processor executes the computer program includes: receiving an input new target confirmation instruction; obtaining the maximum value of the historical target identifier according to the new target confirmation instruction, and incrementing the maximum value; establishing an association relationship between the annotation box corresponding to the new target and the incremented maximum value.

[0141] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented: reading a video frame that has been annotated; querying the video frame to obtain multiple frames of images containing the same target, the multiple frames of images include actual annotation results of the same target, and the multiple frames of images are arranged in chronological order; extracting the previous frame image and the subsequent frame image corresponding to the current frame image from the queried multiple frames of images according to the chronological order; calculating a reference annotation result of the target in the current frame image according to the actual annotation result of the target in the previous frame image and the actual annotation result of the target in the subsequent frame image; and verifying the annotation quality of the actual annotation result of the target in the current frame image according to the reference annotation result.

[0142] In one embodiment, the preceding frame image and the succeeding frame image involved in the execution of the computer program by the processor both include at least one frame; the steps implemented when the computer program is executed by the processor to calculate the reference annotation result of the target in the current frame image according to the actual annotation result of the target in the preceding frame image and the actual annotation result of the target in the succeeding frame image include: extracting at least one frame in the preceding frame image and at least one frame in the succeeding frame image to form a plurality of detection pairs respectively; obtaining the actual annotation result of the target in each frame in the preceding frame image and the actual annotation result of the target in each frame in the succeeding frame image in each detection pair respectively; obtaining the first distance from each frame in the preceding frame image to the current frame image and the second distance from each frame in the succeeding frame image to the current frame image in each detection pair according to the time sequence; calculating the weight of each frame in each detection pair according to the first distance and the second distance; calculating the initial annotation result of the target in the current frame image according to the weight and the actual annotation result of the target in each frame in each detection pair; fusing the initial annotation result to obtain the reference annotation result of the target in the current frame image.

[0143] In one embodiment, the computer program implemented when executed by the processor calculates the weight of each frame in each group of detection pairs based on the first distance and the second distance, including: calculating the total number of copies based on the first distance and the second distance; calculating the weight corresponding to each frame in the previous frame image based on the first distance from each frame in the previous frame image to the current frame image and the total number of copies; calculating the weight corresponding to each frame in the subsequent frame image based on the second distance from each frame in the subsequent frame image to the current frame image and the total number of copies.

[0144] In one embodiment, the computer program implemented when executed by the processor verifies the annotation quality of the actual annotation result of the target in the current frame image based on the reference annotation result, including: calculating the intersection-and-union ratio of the reference annotation result and the actual annotation result; and measuring the annotation quality of the actual annotation result of the target in the current frame image according to the size of the intersection-and-union ratio.

[0145] In one embodiment, when the computer program is executed by a processor, the following steps are implemented: obtaining attribute information of the target in the previous frame image and the subsequent frame image; and checking the annotation quality of the attribute information of the target in the current frame image based on the attribute information.

[0146] In one embodiment, the computer program implemented when being executed by a processor queries video frames to obtain multiple frames containing the same target, including: reading the video frames in sequence according to the time sequence of the video frames, and extracting the target identifiers of the targets marked in the video frames; storing the target identifiers according to the sorting rules of the target identifiers, and associating the video frames containing the targets corresponding to the same target identifier with the stored target identifiers; verifying whether the stored target identifiers are complete according to the sorting rules of the target identifiers; when the stored target identifiers are complete, continuing to extract the previous frame image and the next frame image corresponding to the current frame image from the queried multiple frames according to the time sequence, otherwise outputting a prompt of a reading error.

[0147] In one embodiment, the target identifier involved when the computer program is executed by the processor is generated according to an incremental generation method. The incremental generation method of the target identifier implemented when the computer program is executed by the processor includes: receiving an input new target confirmation instruction; obtaining the maximum value of the historical target identifier according to the new target confirmation instruction, and incrementing the maximum value; establishing an association relationship between the annotation box corresponding to the new target and the incremented maximum value.

[0148] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory or optical memory, etc. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).

[0149] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0150] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.

Claims

1. A method for inspecting target labeling quality, characterized in that: The method comprises: Read the annotated video frame; Querying the video frame to obtain multiple frames of images containing the same object, wherein the multiple frames of images include actual annotation results of the same object, and the multiple frames of images are arranged in chronological order; Extracting the previous frame image and the next frame image corresponding to the current frame image from the queried multiple frame images according to the time sequence; Calculating a reference marking result of the target in the current frame image according to the actual marking result of the target in the previous frame image and the actual marking result of the target in the subsequent frame image; According to the reference annotation result, checking the annotation quality of the actual annotation result of the target in the current frame image; The previous frame image and the subsequent frame image each include at least one frame; and the step of calculating a reference annotation result of the target in the current frame image according to an actual annotation result of the target in the previous frame image and an actual annotation result of the target in the subsequent frame image includes: Respectively extract at least one frame in the preceding frame image and at least one frame in the succeeding frame image to form a plurality of detection pairs; Obtaining respectively the actual labeling result of the target in each frame of the preceding frame image and the actual labeling result of the target in each frame of the succeeding frame image in each group of detection pairs; Acquire, in time sequence, a first distance from each frame in the previous frame image to the current frame image, and a second distance from each frame in the subsequent frame image to the current frame image in each group of detection pairs; Calculate the weight of each frame in each group of detection pairs according to the first distance and the second distance; Calculate the initial labeling result of the target in the current frame image according to the weight and the actual labeling result of the target in each frame in each group of detection pairs; The initial annotation results are fused to obtain a reference annotation result of the target in the current frame image.

2. The method according to claim 1, characterized in that The step of calculating the weight of each frame in each detection pair according to the first distance and the second distance includes: Calculate the total number of copies according to the first distance and the second distance; Calculate the weight corresponding to each frame in the previous frame image according to the first distance from each frame in the previous frame image to the current frame image and the total number of copies; The weight corresponding to each frame in the subsequent frame image is calculated based on the second distance from each frame in the subsequent frame image to the current frame image and the total number of copies.

3. The method according to claim 1 or 2, characterized in that: The step of checking the annotation quality of the actual annotation result of the target in the current frame image according to the reference annotation result includes: Calculating an intersection-over-union ratio of the reference annotation result and the actual annotation result; The quality of the actual labeling result of the target in the current frame image is measured according to the size of the intersection-over-union ratio.

4. The method according to claim 1 or 2, characterized in that: The method further comprises: Acquire attribute information of the target in the preceding frame image and the succeeding frame image; The labeling quality of the attribute information of the target in the current frame image is checked according to the attribute information.

5. The method according to claim 1 or 2, characterized in that: The querying of the video frame to obtain multiple frames of images containing the same object includes: Read the video frames in sequence according to the time sequence of the video frames, and extract the target identifiers of the targets marked in the video frames; The target identifiers are stored according to a sorting rule of the target identifiers, and a video frame containing a target corresponding to the same target identifier is associated with the stored target identifier; According to the sorting rules of the target identifiers, verify whether the stored target identifiers are complete; When the stored target identification is complete, the preceding frame image and the succeeding frame image corresponding to the current frame image are continuously extracted from the queried multiple frame images according to the time sequence, otherwise a prompt indicating a reading error is output.

6. The method according to claim 5, characterized in that The target identifier is generated according to an incremental generation method, and the incremental generation method of the target identifier includes: Receive input of new target confirmation instructions; Acquire the maximum value of the historical target identifier according to the new target confirmation instruction, and increment the maximum value; An association relationship between the annotation box corresponding to the new target and the incremented maximum value is established.

7. A target labeling quality detection device, characterized in that: The device comprises: A reading module is used to read the annotated video frames; A query module, used for querying the video frame to obtain multiple frames of images containing the same object, wherein the multiple frames of images include actual annotation results of the same object, and the multiple frames of images are arranged in chronological order; An extraction module, used for extracting a previous frame image and a subsequent frame image corresponding to a current frame image from the queried multiple frame images according to a time sequence; A reference annotation result generating module, used for calculating a reference annotation result of the target in the current frame image according to the actual annotation result of the target in the previous frame image and the actual annotation result of the target in the subsequent frame image; A detection module, used to check the annotation quality of the actual annotation result of the target in the current frame image according to the reference annotation result; The preceding frame image and the succeeding frame image each include at least one frame; the reference annotation result generating module includes: A detection pair generating unit, used for respectively extracting at least one frame in the preceding frame image and at least one frame in the succeeding frame image to form a plurality of detection pairs; A result acquisition unit, used to respectively acquire an actual labeling result of a target in each frame of a preceding frame image and an actual labeling result of a target in each frame of a succeeding frame image in each group of detection pairs; A distance acquisition unit, used for respectively acquiring a first distance from each frame in the previous frame image to the current frame image, and a second distance from each frame in the subsequent frame image to the current frame image in each detection pair according to a time sequence; A weight calculation unit, configured to calculate a weight of each frame in each detection pair according to the first distance and the second distance; An initial annotation result calculation unit, used to calculate an initial annotation result of the target in the current frame image according to the weight and the actual annotation result of the target in each frame in each detection pair; A fusion unit is used to fuse the initial annotation results to obtain a reference annotation result of the target in the current frame image.

8. The device according to claim 7, characterized in that The weight calculation unit comprises: A total number of copies calculating subunit, configured to calculate the total number of copies according to the first distance and the second distance; The weight calculation subunit is used to calculate the weight corresponding to each frame in the previous frame image according to the first distance from each frame in the previous frame image to the current frame image and the total number of copies; and to calculate the weight corresponding to each frame in the subsequent frame image according to the second distance from each frame in the subsequent frame image to the current frame image and the total number of copies.

9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.