CN111400531B - Target labeling method, device, equipment and computer readable storage medium - Google Patents

Target labeling method, device, equipment and computer readable storage medium Download PDF

Info

Publication number
CN111400531B
CN111400531B CN202010179388.1A CN202010179388A CN111400531B CN 111400531 B CN111400531 B CN 111400531B CN 202010179388 A CN202010179388 A CN 202010179388A CN 111400531 B CN111400531 B CN 111400531B
Authority
CN
China
Prior art keywords
target
identification area
labeling
filtered
image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010179388.1A
Other languages
Chinese (zh)
Other versions
CN111400531A (en
Inventor
李坚铳
陈坤杰
霍达
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangzhou Weride Technology Co Ltd
Original Assignee
Guangzhou Weride Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangzhou Weride Technology Co Ltd filed Critical Guangzhou Weride Technology Co Ltd
Priority to CN202010179388.1A priority Critical patent/CN111400531B/en
Publication of CN111400531A publication Critical patent/CN111400531A/en
Application granted granted Critical
Publication of CN111400531B publication Critical patent/CN111400531B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/58Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually
    • G06F16/5866Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually using information manually generated, e.g. tags, keywords, comments, manually generated location and time information
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/53Querying
    • G06F16/535Filtering based on additional data, e.g. user or group profiles
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/55Clustering; Classification
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/58Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually
    • G06F16/583Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually using metadata automatically derived from the content
    • G06F16/5838Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually using metadata automatically derived from the content using colour

Abstract

The invention discloses a target labeling method, which comprises the following steps: acquiring an image to be marked, and identifying a first identification area and a second identification area in the image to be marked; labeling the first identification area and the second identification area to obtain a target to be filtered; filtering the target to be filtered based on a pre-constructed evaluation function to obtain a labeling target; the area of the first identification area is larger than the area of the second identification area. The invention also discloses a target labeling device, equipment and a computer readable storage medium. According to the method, the labeling object is divided into the first recognition area and the second recognition area, the first recognition area and the second recognition area are recognized and labeled, the labeling speed and the labeling accuracy are improved, and in order to further improve the labeling accuracy, the labeling result is filtered by adopting the evaluation function, so that the high-accuracy labeling object is obtained, and the intelligent labeling is realized.

Description

Target labeling method, device, equipment and computer readable storage medium
Technical Field
The present invention relates to the field of image recognition technology in automatic driving, and in particular, to a target labeling method, apparatus, device, and computer readable storage medium.
Background
The automatic driving automobile is an intelligent automobile which realizes unmanned driving through a computer system, and the computer can automatically and safely operate the motor vehicle under the condition of no active operation of any human being by means of cooperation of artificial intelligence, visual calculation and the like. In order to realize automatic driving of the vehicle, the vehicle needs to be trained deeply in advance, so that the traffic light can be automatically identified in the crossing driving process after the vehicle is trained, and the traffic rules are complied with in the automatic driving process.
In the training process, in order to enable the vehicle to correctly identify the traffic light, a large number of images marked with traffic light information are required to train the vehicle, and the traditional images marked with traffic light information are marked manually, so that in the training process, a long marking time is required, and the problems of easy marking errors, high labor cost and the like are caused due to the fact that a large number of manual marks are formed.
Disclosure of Invention
The invention mainly aims to provide a target labeling method, a device, equipment and a computer readable storage medium, aiming at improving labeling speed and labeling accuracy and realizing intelligent labeling.
In order to achieve the above object, the present invention provides a target labeling method, which includes the following steps:
acquiring an image to be marked, and identifying a first identification area and a second identification area in the image to be marked;
labeling the first identification area and the second identification area to obtain a target to be filtered;
filtering the target to be filtered based on a pre-constructed evaluation function to obtain a labeling target;
the area of the first identification area is larger than the area of the second identification area.
Preferably, the step of acquiring the image to be annotated and identifying the first identification area and the second identification area in the image to be annotated includes:
and identifying the image to be marked according to the first identification area and the second identification area in sequence.
Preferably, the step of filtering the target to be filtered based on the pre-constructed evaluation function to obtain the labeling target includes:
determining parameter information of the target to be filtered, and inputting the parameter information into a pre-constructed evaluation function to obtain an evaluation value;
and filtering the target to be filtered based on the evaluation value to obtain a labeling target.
Preferably, the parameter information at least comprises one or more of a front-back frame relation, a co-frame parallel relation, a containing relation and a scene information relation.
Preferably, the target to be filtered includes a current frame and a previous frame, and the step of determining parameter information of the target to be filtered and inputting the parameter information into a pre-constructed evaluation function to obtain an evaluation value includes:
based on the two frames of the targets to be filtered, determining a front-to-back frame relationship corresponding to the targets to be filtered;
and/or determining the same-frame parallel relation corresponding to the target to be filtered based on the current frame;
and/or determining the inclusion relation corresponding to the target to be filtered based on the current frame;
and/or determining a scene information relation corresponding to the target to be filtered based on the current frame;
and inputting the front-back frame relation, the same-frame parallel relation and/or the containing relation and/or the scene information relation into a pre-constructed evaluation function to obtain an evaluation value.
Preferably, the pre-constructing step of the evaluation function includes:
the method comprises the steps of collecting a training image set, wherein the training image set comprises a first image carrying a training target to be filtered and a second image carrying a training mark target, and the first image and the second image are the same image;
determining training parameter information of the first image, and sequentially determining weight values corresponding to the training parameter information based on preset intervals;
sequentially inputting the training parameter information and the weight value into an initial evaluation function to filter the first image, and comparing the filtering result with a second image to obtain a comparison result;
based on the comparison result, selecting an optimal weight value from the weight values;
and constructing an evaluation function based on the optimal weight value and the initial evaluation function.
Preferably, the step of labeling the first identification area and the second identification area to obtain the target to be filtered includes:
sequentially identifying the categories and colors of the first identification area and the second identification area;
and marking the first identification area and the second identification area based on the category and the color to obtain a target to be filtered.
In addition, in order to achieve the above object, the present invention further provides a target labeling device, including:
the acquisition module is used for acquiring an image to be marked and identifying a first identification area and a second identification area in the image to be marked;
the labeling module is used for labeling the first identification area and the second identification area to obtain a target to be filtered;
the filtering module is used for filtering the target to be filtered based on a pre-constructed evaluation function so as to obtain a labeling target;
the area of the first identification area is larger than the area of the second identification area.
Preferably, the acquiring module is further configured to:
and identifying the image to be marked according to the first identification area and the second identification area in sequence.
Preferably, the filtration module is further configured to:
determining parameter information of the target to be filtered, and inputting the parameter information into a pre-constructed evaluation function to obtain an evaluation value;
and filtering the target to be filtered based on the evaluation value to obtain a labeling target.
Preferably, the parameter information at least comprises one or more of a front-back frame relation, a co-frame parallel relation, a containing relation and a scene information relation.
Preferably, the filtration module is further configured to:
based on the two frames of the targets to be filtered, determining a front-to-back frame relationship corresponding to the targets to be filtered;
and/or determining the same-frame parallel relation corresponding to the target to be filtered based on the current frame;
and/or determining the inclusion relation corresponding to the target to be filtered based on the current frame;
and/or determining a scene information relation corresponding to the target to be filtered based on the current frame;
and inputting the front-back frame relation, the same-frame parallel relation and/or the containing relation and/or the scene information relation into a pre-constructed evaluation function to obtain an evaluation value.
Preferably, the target labeling device further comprises a construction module, wherein the construction module is used for:
the method comprises the steps of collecting a training image set, wherein the training image set comprises a first image carrying a training target to be filtered and a second image carrying a training mark target, and the first image and the second image are the same image;
determining training parameter information of the first image, and sequentially determining weight values corresponding to the training parameter information based on preset intervals;
sequentially inputting the training parameter information and the weight value into an initial evaluation function to filter the first image, and comparing the filtering result with a second image to obtain a comparison result;
based on the comparison result, selecting an optimal weight value from the weight values;
and constructing an evaluation function based on the optimal weight value and the initial evaluation function.
Preferably, the labeling module is further configured to:
sequentially identifying the categories and colors of the first identification area and the second identification area;
and marking the first identification area and the second identification area based on the category and the color to obtain a target to be filtered.
In addition, in order to achieve the above object, the present invention further provides a target labeling apparatus, including: the target labeling method comprises the steps of a memory, a processor and a target labeling program which is stored in the memory and can run on the processor, wherein the target labeling program realizes the target labeling method when being executed by the processor.
In addition, in order to achieve the above object, the present invention also provides a computer-readable storage medium having stored thereon a target labeling program which, when executed by a processor, implements the steps of the target labeling method as described above.
According to the target labeling method, an image to be labeled is obtained, and a first identification area and a second identification area in the image to be labeled are identified; labeling the first identification area and the second identification area to obtain a target to be filtered; filtering the target to be filtered based on a pre-constructed evaluation function to obtain a labeling target; the area of the first identification area is larger than the area of the second identification area. According to the method, the labeling object is divided into the first recognition area and the second recognition area, the first recognition area and the second recognition area are recognized and labeled, the labeling speed and the labeling accuracy are improved, and in order to further improve the labeling accuracy, the labeling result is filtered by adopting the evaluation function, so that the high-accuracy labeling object is obtained, and the intelligent labeling is realized.
Drawings
FIG. 1 is a schematic diagram of a device architecture of a hardware operating environment according to an embodiment of the present invention;
FIG. 2 is a flowchart of a first embodiment of the target labeling method of the present invention;
FIG. 3 is a schematic diagram illustrating the definition of a first identification area and a second identification area according to a first embodiment of the target labeling method of the present invention;
FIG. 4 is a flowchart illustrating the identification of a first identification area and a second identification area according to a first embodiment of the target labeling method of the present invention;
fig. 5 is a flowchart of a second embodiment of the target labeling method of the present invention.
The achievement of the objects, functional features and advantages of the present invention will be further described with reference to the accompanying drawings, in conjunction with the embodiments.
Detailed Description
It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the scope of the invention.
Referring to fig. 1, fig. 1 is a schematic device structure of a hardware running environment according to an embodiment of the present invention.
The device of the embodiment of the invention can be a mobile terminal such as a mobile phone, a fixed terminal such as a computer or a server.
As shown in fig. 1, the apparatus may include: a processor 1001, such as a CPU, a network interface 1004, a user interface 1003, a memory 1005, a communication bus 1002. Wherein the communication bus 1002 is used to enable connected communication between these components. The user interface 1003 may include a Display, an input unit such as a Keyboard (Keyboard), and the optional user interface 1003 may further include a standard wired interface, a wireless interface. The network interface 1004 may optionally include a standard wired interface, a wireless interface (e.g., WI-FI interface). The memory 1005 may be a high-speed RAM memory or a stable memory (non-volatile memory), such as a disk memory. The memory 1005 may also optionally be a storage device separate from the processor 1001 described above.
It will be appreciated by those skilled in the art that the device structure shown in fig. 1 is not limiting of the device and may include more or fewer components than shown, or may combine certain components, or a different arrangement of components.
As shown in fig. 1, an operation device, a network communication module, a user interface module, and a target labeling program may be included in a memory 1005 as a computer storage medium.
The operation device is a program for managing and controlling the device and the software resource, and supports the operation of a network communication module, a user interface module, a target marking program and other programs or software; the network communication module is used to manage and control the network interface 1002; the user interface module is used to manage and control the user interface 1003.
In the apparatus shown in fig. 1, the apparatus calls a target labeling program stored in a memory 1005 by a processor 1001 and performs operations in the respective embodiments of the target labeling method described below.
Based on the hardware structure, the embodiment of the target labeling method is provided.
Referring to fig. 2, fig. 2 is a flowchart of a first embodiment of a target labeling method according to the present invention, where the method includes:
step S10, an image to be marked is obtained, and a first identification area and a second identification area in the image to be marked are identified;
step S20, marking the first identification area and the second identification area to obtain a target to be filtered;
step S30, filtering the target to be filtered based on a pre-constructed evaluation function to obtain a labeling target;
the area of the first identification area is larger than the area of the second identification area.
When the image to be marked is marked, the marking object is divided into the first identification area and the second identification area, the first identification area and the second identification area are respectively identified and marked, so that a marking result, namely a target to be filtered, is obtained, marking speed and marking accuracy are improved, and the target to be filtered is filtered through the evaluation function, so that the high-precision marking target is obtained.
The following will explain each step in detail:
step S10, an image to be marked is obtained, and a first identification area and a second identification area in the image to be marked are identified.
In this embodiment, an image to be marked is obtained first, and a first recognition area and a second recognition area in the image to be marked are identified, that is, a marked object is divided into the first recognition area and the second recognition area in the image to be marked, as shown in fig. 3, in the traffic light recognition, an external rectangle of a traffic light is a large frame, that is, the first recognition area, and an external rectangle of a lighting state bulb or number is a small frame, that is, the second recognition area, and the area of the first recognition area is larger than the area of the second recognition area.
It can be understood that, in the implementation, the circumscribed rectangle of the vehicle can be defined as a large frame, and used as a first identification area, and the circumscribed rectangle of the vehicle lamp is defined as a small frame, and used as a second identification area; or, the external rectangle of the identity card is a large frame, the external rectangle of the head portrait on the identity card is a small frame as a first identification area, the external rectangle of the head portrait on the identity card is a second identification area, and the like, and the specific definition mode is set by using an actual labeling object, and in the following description, the labeling object is preferably taken as a red-green lamp identification for explanation.
Further, in an embodiment, step S10 includes:
and identifying the image to be marked according to the first identification area and the second identification area in sequence.
In an embodiment, when the image to be marked is identified, the first identification area and the second identification area can be identified in a multi-model combination mode, specifically, the multi-model combination at least comprises two models, and then the image to be marked is identified sequentially according to the sequence of identifying the first identification area and then identifying the second identification area.
The existing traffic light identification generally adopts single-model identification, the accuracy is insufficient to meet the labeling requirement, for example, a window is identified as a traffic light rectangular frame, but in the identification mode of the embodiment, the hiding rules of the first identification area and the second identification area are utilized: the first identification area and the second identification area have a containing relation, if an image to be marked is an image containing a traffic light, the marked object is a red-green light, the first identification area is a large circumscribed rectangular frame of the traffic light, the second identification area is a small circumscribed rectangular frame of a light bulb or a number in a lighting state, and the small frame is necessarily contained in the large frame at the moment.
And S20, marking the first identification area and the second identification area to obtain a target to be filtered.
In this embodiment, after the first identification area and the second identification area are identified, the first identification area and the second identification area are marked, that is, marking information of the first identification area and the second identification area, such as information of a circular red light, is marked in the first identification area and the second identification area, so that an object to be filtered, that is, a marking result, is obtained.
In one embodiment, step S20 includes:
step S21, sequentially identifying the categories and colors of the first identification area and the second identification area;
in an embodiment, the first identification area and the second identification area are identified sequentially, that is, the first identification area and the second identification area are identified sequentially, and specifically, the category and the color of the first identification area are identified sequentially, and the category and the color of the second identification area are identified sequentially, wherein the category includes a circle, a straight line, a left turn, a right turn, a turning around, a pedestrian lamp, etc., and the color includes a red color, a green color, a yellow color, etc.
Further, in another embodiment, referring to fig. 4, step S21 includes:
step S211, identifying the category and the color of the first identification area according to the first model;
step S222, identifying the category and color of the second identification area based on the relationship between the first identification area and the second identification area.
In another embodiment, in order to improve the recognition accuracy, after the first recognition area, that is, the large frame, is recognized based on the large frame, then, based on the large frame, the class and the color of the small frame are recognized, this is because the first recognition area includes the second recognition area, that is, the large frame includes the small frame, and the small frame is outside the small frame, therefore, based on the rule relation, when the small frame is recognized, the large frame is recognized first, then, based on the large frame, the small frame in the large frame is recognized, so that the accuracy is improved, if the small frame and the large frame are not included, the recognition is recognized as wrong, and the recognition is discarded, only if the recognized small frame satisfies the rule relation that the large frame includes the small frame, the recognition is considered to be correct, then, the class and the color of the small frame are recognized, and finally, the class and the color of the first recognition area, and the class and the color of the second recognition area are obtained, that is, in addition, in the recognition process, the current recognition information of the first recognition area and the second recognition area, such as the first recognition area, is recognized as a red lamp.
And S22, marking the first identification area and the second identification area based on the category and the color to obtain a target to be filtered.
The categories, colors or numbers and the like which are identified by the first identification area and the second identification area are marked in the first identification area and the second identification area, so that corresponding marking results are obtained, and the results obtained by respectively carrying out the first identification area identification and the second identification area identification on the same target can be the same or different due to errors of the identification models. However, the labeling result is not the final result at this time, and it can be understood that recognition errors, such as damaged traffic lights, are inevitably generated in the recognition process, and even if a large frame is recognized, recognition errors are generated due to the fact that no small frame exists, so that after the target to be filtered is obtained, the target to be filtered is filtered, and the object with the recognition errors is further removed, so that the labeling error rate is reduced.
And step S30, filtering the target to be filtered based on a pre-constructed evaluation function to obtain a labeling target.
In this embodiment, in order to further improve the labeling accuracy, reduce the labeling error rate caused by the recognition error, filter the target to be filtered through the pre-constructed evaluation function, and in the specific implementation, input the target to be filtered into the evaluation function, and further reject the erroneous data by the evaluation function, thereby obtaining the labeling target with high precision.
The evaluation function of the embodiment is equivalent to a filter, and error data which does not accord with the rule of the evaluation function is filtered, so that a high-precision labeling target is obtained.
The method comprises the steps of obtaining an image to be marked, and identifying a first identification area and a second identification area in the image to be marked; labeling the first identification area and the second identification area to obtain a target to be filtered; filtering the target to be filtered based on a pre-constructed evaluation function to obtain a labeling target; the area of the first identification area is larger than the area of the second identification area. According to the method, the labeling object is divided into the first recognition area and the second recognition area, the first recognition area and the second recognition area are recognized and labeled, the labeling speed and the labeling accuracy are improved, and in order to further improve the labeling accuracy, the labeling result is filtered by adopting the evaluation function, so that the high-accuracy labeling object is obtained, and the intelligent labeling is realized.
Further, based on the first embodiment of the target labeling method of the present invention, a second embodiment of the target labeling method of the present invention is provided.
The second embodiment of the target labeling method differs from the first embodiment of the target labeling method in that, referring to fig. 5, step S30 includes:
step S31, determining parameter information of the target to be filtered, and inputting the parameter information into a pre-constructed evaluation function to obtain an evaluation value;
in this embodiment, the evaluation function is equivalent to a filter, and the objects to be filtered which meet the rule of the evaluation function are left, and the objects to be filtered which do not meet the rule of the evaluation function are filtered, so that the high-precision labeling object is obtained.
In order to determine whether the object to be filtered meets the rule of the evaluation function, the parameter information of the object to be filtered needs to be determined first, so that the parameter information is input into the evaluation function to perform matching calculation, wherein the parameter information at least comprises one or more of a front frame relationship, a back frame relationship, a same-frame parallel relationship, a containing relationship and a scene information relationship.
In an embodiment, the object to be filtered includes a current frame and a previous frame, and step S31 includes:
based on the two frames of the targets to be filtered, determining a front-to-back frame relationship corresponding to the targets to be filtered;
and/or determining the same-frame parallel relation corresponding to the target to be filtered based on the current frame;
and/or determining the inclusion relation corresponding to the target to be filtered based on the current frame;
and/or determining a scene information relation corresponding to the target to be filtered based on the current frame;
and inputting the front-back frame relation, the same-frame parallel relation and/or the containing relation and/or the scene information relation into a pre-constructed evaluation function to obtain an evaluation value.
In an embodiment, the object to be filtered at least includes two frames, and a front-to-back frame relationship corresponding to the object to be filtered and/or a parallel relationship with the frames and/or a containing relationship and/or a scene information relationship are determined through the two frames of the object to be filtered.
For convenience of description, the traffic light is taken as an example for explanation of the labeled object:
first, for the relation of the front frame and the rear frame, in the scene of continuous traffic lights, the position of a certain traffic light in the continuous frames can be positioned according to map information. For a certain traffic light, which is compared with the previous frame, there are 4 cases: the category is the same as the color (number); the same category and different colors; different categories but the same color; the categories and colors are different, wherein the categories include circles, straight lines, left turns, right turns, turns around, pedestrian lights, etc., the colors include red, green, yellow, etc., and the numbers are continuous natural numbers, such as 1, 2, 3, etc., for characterizing the duration of the current color state.
For the parallel relationship of the same frame, if the red and green lamp frames in the same frame are the same in category and have different aspect ratios within a preset proportion range, the red and green lamp frames are defined as parallel traffic lights, wherein the preset proportion range can be set according to practical situations, the red and green lamp frames in the same frame are preferably defined as parallel traffic lights when the category of the red and green lamp frames in the same frame are the same and have different aspect ratios of <5%, and for the parallel traffic lights, the two colors (numbers) of the parallel traffic lights are the same and different, so the parallel relationship has the following 3 situations: if the first red and green lamp frames and the second red and green lamp frames exist in the current frame, the types of the two traffic lamp frames are the same, the length-width ratio is different in a preset proportion range, the same-frame parallel relation is determined, and if the color of the first red and green lamp frame is green and the color of the second red and green lamp frame is green at the moment, the two red and green lamp frames are parallel and the same; if the color of the first red-green lamp frame is green and the color of the second red-green lamp frame is red, the two lamp frames are different in parallel.
For the inclusion relationship, defining a red-green lamp frame which is completely contained in another frame as an inclusion frame; while the red and green lamp frames that are completely contained in another frame are contained frames. Therefore, the inclusion relationship is the case in the following 3: and if the A frame contains the B frame, defining the A frame as the containing frame, the containing relation as the containing frame, the B frame as the containing frame, the containing relation as the containing frame, and the C frame neither contains other frames nor is in other frames, and the containing relation is the non-containing.
For the scene information relation, the scene information relation comprises vehicle state information and pedestrian information, wherein the vehicle state information can determine the vehicle state information through obtaining lane information and detecting through a vehicle tail lamp, and specifically determine whether the vehicle can pass, namely, determine whether the vehicle in a certain direction can pass or cannot pass, if the current lane information is green light passing, but the front vehicle is not started yet, and the vehicle tail lamp is in a red light state, then determine that the current lane cannot pass, namely, the vehicle state information is not accordant; pedestrian information can be determined by determining the position of a pedestrian, such as on a road or on the roadside of a horse, so that whether the pedestrian can pass or not, and if the pedestrian exists on the road currently, the pedestrian cannot pass even if the current lane is in a green light passing state, namely the pedestrian information is not consistent. Therefore, according to the arrangement and combination, the scene information relation has the situation that the vehicle state information and the pedestrian information are both in accordance, the vehicle state information is not in accordance with the pedestrian information, and the vehicle state information and the pedestrian information are not in accordance with the four conditions.
In the specific implementation, proper parameter information is selected and input according to the construction process of the evaluation function, so that a high-precision labeling target is obtained through filtering, and if the construction process of the evaluation function needs four parameters of a front-back frame relationship, a same-frame parallel relationship, a containing relationship and a scene information relationship, the four parameters of the front-back frame relationship, the same-frame parallel relationship, the containing relationship and the scene information relationship of the target to be filtered need to be obtained when the target to be filtered is filtered; if the construction process of the evaluation function only needs three parameters of a front-back frame relationship, a same-frame parallel relationship and a containing relationship, when the target to be filtered is filtered, only three parameters of the front-back frame relationship, the same-frame parallel relationship and the containing relationship of the target to be filtered are needed to be obtained.
In one embodiment, the pre-construction step of the evaluation function comprises:
the method comprises the steps of collecting a training image set, wherein the training image set comprises a first image carrying a training target to be filtered and a second image carrying a training mark target, and the first image and the second image are the same image;
determining training parameter information of the first image, and sequentially determining weight values corresponding to the training parameter information based on preset intervals;
sequentially inputting the training parameter information and the weight value into an initial evaluation function to filter the first image, and comparing the filtering result with a second image to obtain a comparison result;
based on the comparison result, selecting an optimal weight value from the weight values;
and constructing an evaluation function based on the optimal weight value and the initial evaluation function.
That is, in an embodiment, a large number of training images are required to be collected for training the evaluation function, where the training image set includes a first image carrying a training target to be filtered and a second image carrying a training labeling target, where the first image and the second image are the same image, and the second image is used to verify the effect of the evaluation function in filtering the first image, that is, in the process of constructing the evaluation function, the first image is constructed, specifically, training parameter information of the first image is obtained, the training parameter information includes at least one or more of a front-back frame relationship, a co-frame parallel relationship, a containing relationship, and a scene information relationship, and then, based on a preset interval, weight values corresponding to the training parameter information are sequentially determined, for example, the preset interval is 0.1, then the weight values corresponding to the training parameter information may take 0,0.1,0.2,0.3,0.4,0.5,0.6,0.7,0.8,0.9,1 eleven kinds, and then the weight values are sequentially input into the initial evaluation function, so as to filter the first image. It will be appreciated that the preset spacing may be other values such as 0.05 or 0.2.
The preferred initial evaluation function of this embodiment is:
f(x)=x1*A+x2*B+x3*C+x4*D+x5*E(x1+x2+x3+x4+x5=1)
wherein A is confidence (A is more than or equal to 0 and less than or equal to 1)
B is a front-back frame relation (B is more than or equal to 0 and less than or equal to 1), and the scores of the four cases are respectively B1, B2, B3 and B4;
c is a parallel relation (C is more than or equal to 0 and less than or equal to 1), and the scores of the three conditions are C1, C2 and C3 respectively;
d is an inclusion relation (D is more than or equal to 0 and less than or equal to 1), and the scores of the three conditions are D1, D2 and D3 respectively;
e is a scene information relation (E is more than or equal to 0 and less than or equal to 1), and scores are E1, E2, E3 and E4 for four situations respectively;
and x is the weight value of the parameter information.
That is, the evaluation function is trained by four parameters of a front-back frame relationship, a parallel relationship, a containing relationship and a scene information relationship, and it can be understood that two or three parameters can be adopted for training, and the initial evaluation function is correspondingly changed under the condition of reducing the parameters.
Then, sequentially inputting the weight value and the parameter information into initial evaluation parameters, performing traversal search on each parameter, specifically filtering a first image, and comparing the filtering result with a second image to obtain a combination with the highest evaluation value, wherein a function formed by the optimal combination is an evaluation function.
And step S32, filtering the target to be filtered based on the evaluation value to obtain a labeling target.
In this embodiment, after the evaluation value is obtained through the evaluation function, the evaluation value is compared with a preset threshold, if the evaluation value is smaller than the preset threshold, the evaluation value is filtered, and if the evaluation value is greater than or equal to the preset threshold, the evaluation value is reserved, so that a high-precision labeling target is finally obtained.
In the process of filtering the target to be filtered, the embodiment selects the parameter with higher relevance as the filtering standard, and filters the incorrect labeling target meeting the filtering condition, thereby reserving the labeling target with high precision, further improving the labeling accuracy and realizing intelligent labeling.
The invention also provides a target labeling device. The target marking device of the invention comprises:
the acquisition module is used for acquiring an image to be marked and identifying a first identification area and a second identification area in the image to be marked;
the labeling module is used for labeling the first identification area and the second identification area to obtain a target to be filtered;
the filtering module is used for filtering the target to be filtered based on a pre-constructed evaluation function so as to obtain a labeling target;
the area of the first identification area is larger than the area of the second identification area.
Preferably, the acquiring module is further configured to:
and identifying the image to be marked according to the first identification area and the second identification area in sequence.
Preferably, the filtration module is further configured to:
determining parameter information of the target to be filtered, and inputting the parameter information into a pre-constructed evaluation function to obtain an evaluation value;
and filtering the target to be filtered based on the evaluation value to obtain a labeling target.
Preferably, the parameter information at least comprises one or more of a front-back frame relation, a co-frame parallel relation, a containing relation and a scene information relation.
Preferably, the filtration module is further configured to:
based on the two frames of the targets to be filtered, determining a front-to-back frame relationship corresponding to the targets to be filtered;
and/or determining the same-frame parallel relation corresponding to the target to be filtered based on the current frame;
and/or determining the inclusion relation corresponding to the target to be filtered based on the current frame;
and/or determining a scene information relation corresponding to the target to be filtered based on the current frame;
and inputting the front-back frame relation, the same-frame parallel relation and/or the containing relation and/or the scene information relation into a pre-constructed evaluation function to obtain an evaluation value.
Preferably, the target labeling device further comprises a construction module, wherein the construction module is used for:
the method comprises the steps of collecting a training image set, wherein the training image set comprises a first image carrying a training target to be filtered and a second image carrying a training mark target, and the first image and the second image are the same image;
determining training parameter information of the first image, and sequentially determining weight values corresponding to the training parameter information based on preset intervals;
sequentially inputting the training parameter information and the weight value into an initial evaluation function to filter the first image, and comparing the filtering result with a second image to obtain a comparison result;
based on the comparison result, selecting an optimal weight value from the weight values;
and constructing an evaluation function based on the optimal weight value and the initial evaluation function.
Preferably, the labeling module is further configured to:
sequentially identifying the categories and colors of the first identification area and the second identification area;
and marking the first identification area and the second identification area based on the category and the color to obtain a target to be filtered.
The invention also provides a computer readable storage medium.
The computer readable storage medium of the present invention stores thereon a target labeling program which, when executed by a processor, implements the steps of the target labeling method as described above.
The method implemented when the target labeling program running on the processor is executed may refer to various embodiments of the target labeling method of the present invention, which are not described herein.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The foregoing embodiment numbers of the present invention are merely for the purpose of description, and do not represent the advantages or disadvantages of the embodiments.
From the above description of the embodiments, it will be clear to those skilled in the art that the above-described embodiment method may be implemented by means of software plus a necessary general hardware platform, but of course may also be implemented by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (e.g. ROM/RAM, magnetic disk, optical disk) as described above, comprising instructions for causing a terminal device (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to perform the method according to the embodiments of the present invention.
The foregoing description is only of the preferred embodiments of the present invention, and is not intended to limit the scope of the invention, but rather is intended to cover any equivalents of the structures or equivalent processes disclosed herein, or any application, directly or indirectly, in the field of other related technology.

Claims (10)

1. The target labeling method is characterized by comprising the following steps of:
acquiring an image to be marked, and identifying a first identification area and a second identification area in the image to be marked;
labeling the first identification area and the second identification area to obtain a target to be filtered;
sequentially identifying the categories and colors of the first identification area and the second identification area;
identifying the category and the color of the first identification area according to the first model;
identifying a category and a color of a second identification zone based on a relationship of the first identification zone to the second identification zone;
labeling the first identification area and the second identification area based on the category and the color to obtain a target to be filtered;
filtering the target to be filtered based on a pre-constructed evaluation function to obtain a labeling target;
the area of the first identification area is larger than that of the second identification area, and the first identification area comprises the second identification area.
2. The method for labeling a target as set forth in claim 1, wherein the step of acquiring an image to be labeled and identifying a first identification area and a second identification area in the image to be labeled comprises:
and identifying the image to be marked according to the first identification area and the second identification area in sequence.
3. The method for labeling objects according to claim 1, wherein the step of filtering the objects to be filtered based on the pre-constructed evaluation function to obtain the labeled objects comprises:
determining parameter information of the target to be filtered, and inputting the parameter information into a pre-constructed evaluation function to obtain an evaluation value;
and filtering the target to be filtered based on the evaluation value to obtain a labeling target.
4. The method of claim 3, wherein the parameter information includes at least one or more of a frame-by-frame relationship, a co-frame relationship, a containment relationship, and a scene information relationship.
5. The method for labeling targets as set forth in claim 4, wherein the target to be filtered includes a current frame and a previous frame, and the step of determining parameter information of the target to be filtered and inputting the parameter information into a pre-constructed evaluation function to obtain the evaluation value includes:
based on the two frames of the targets to be filtered, determining a front-to-back frame relationship corresponding to the targets to be filtered;
and/or determining the same-frame parallel relation corresponding to the target to be filtered based on the current frame;
and/or determining the inclusion relation corresponding to the target to be filtered based on the current frame;
and/or determining a scene information relation corresponding to the target to be filtered based on the current frame;
and inputting the front-back frame relation, the same-frame parallel relation and/or the containing relation and/or the scene information relation into a pre-constructed evaluation function to obtain an evaluation value.
6. The target labeling method of claim 1, wherein the pre-constructing step of the evaluation function comprises:
the method comprises the steps of collecting a training image set, wherein the training image set comprises a first image carrying a training target to be filtered and a second image carrying a training mark target, and the first image and the second image are the same image;
determining training parameter information of the first image, and sequentially determining weight values corresponding to the training parameter information based on preset intervals;
sequentially inputting the training parameter information and the weight value into an initial evaluation function to filter the first image, and comparing the filtering result with a second image to obtain a comparison result;
based on the comparison result, selecting an optimal weight value from the weight values;
and constructing an evaluation function based on the optimal weight value and the initial evaluation function.
7. The method for labeling objects according to any of claims 1-6, wherein said labeling said first identification region and said second identification region to obtain objects to be filtered comprises:
sequentially identifying the categories and colors of the first identification area and the second identification area;
and marking the first identification area and the second identification area based on the category and the color to obtain a target to be filtered.
8. A target marking apparatus, characterized in that the target marking apparatus comprises:
the acquisition module is used for acquiring an image to be marked and identifying a first identification area and a second identification area in the image to be marked;
the labeling module is used for labeling the first identification area and the second identification area to obtain a target to be filtered;
the labeling module is further used for sequentially identifying the categories and the colors of the first identification area and the second identification area, identifying the categories and the colors of the first identification area according to a first model, identifying the categories and the colors of the second identification area based on the relation between the first identification area and the second identification area, and labeling the first identification area and the second identification area based on the categories and the colors so as to obtain a target to be filtered;
the filtering module is used for filtering the target to be filtered based on a pre-constructed evaluation function so as to obtain a labeling target;
the area of the first identification area is larger than the area of the second identification area.
9. A target marking apparatus, characterized in that the target marking apparatus comprises: memory, a processor and a target marking program stored on the memory and executable on the processor, which when executed by the processor, implements the steps of the target marking method according to any one of claims 1 to 7.
10. A computer-readable storage medium, wherein a target labeling program is stored on the computer-readable storage medium, which when executed by a processor, implements the steps of the target labeling method of any of claims 1 to 7.
CN202010179388.1A 2020-03-13 2020-03-13 Target labeling method, device, equipment and computer readable storage medium Active CN111400531B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010179388.1A CN111400531B (en) 2020-03-13 2020-03-13 Target labeling method, device, equipment and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010179388.1A CN111400531B (en) 2020-03-13 2020-03-13 Target labeling method, device, equipment and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN111400531A CN111400531A (en) 2020-07-10
CN111400531B true CN111400531B (en) 2024-04-05

Family

ID=71428806

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010179388.1A Active CN111400531B (en) 2020-03-13 2020-03-13 Target labeling method, device, equipment and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN111400531B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112131414A (en) * 2020-09-23 2020-12-25 北京百度网讯科技有限公司 Signal lamp image labeling method and device, electronic equipment and road side equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016103041A1 (en) * 2014-12-26 2016-06-30 Here Global B.V. Selecting feature geometries for localization of a device
CN109508580A (en) * 2017-09-15 2019-03-22 百度在线网络技术(北京)有限公司 Traffic lights recognition methods and device
CN109934116A (en) * 2019-02-19 2019-06-25 华南理工大学 A kind of standard faces generation method based on generation confrontation mechanism and attention mechanism
CN110660254A (en) * 2018-06-29 2020-01-07 北京市商汤科技开发有限公司 Traffic signal lamp detection and intelligent driving method and device, vehicle and electronic equipment

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016103041A1 (en) * 2014-12-26 2016-06-30 Here Global B.V. Selecting feature geometries for localization of a device
CN109508580A (en) * 2017-09-15 2019-03-22 百度在线网络技术(北京)有限公司 Traffic lights recognition methods and device
CN110660254A (en) * 2018-06-29 2020-01-07 北京市商汤科技开发有限公司 Traffic signal lamp detection and intelligent driving method and device, vehicle and electronic equipment
CN109934116A (en) * 2019-02-19 2019-06-25 华南理工大学 A kind of standard faces generation method based on generation confrontation mechanism and attention mechanism

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
一种基于场景识别的快速语义标注方法;胡涛;吴涛;李焱;;华中科技大学学报(自然科学版)(S1);全文 *

Also Published As

Publication number Publication date
CN111400531A (en) 2020-07-10

Similar Documents

Publication Publication Date Title
CN110148196B (en) Image processing method and device and related equipment
CN111874006A (en) Route planning processing method and device
CN111815959A (en) Vehicle violation detection method and device and computer readable storage medium
CN111192311A (en) Automatic extraction method and device for longitudinal deceleration marked line in high-precision map making
CN111325136B (en) Method and device for labeling object in intelligent vehicle and unmanned vehicle
CN111126323A (en) Bayonet element recognition and analysis method and system serving for traffic violation detection
CN111400531B (en) Target labeling method, device, equipment and computer readable storage medium
CN112418031B (en) Image recognition method and device, storage medium and electronic equipment
CN110188687A (en) Landform recognition methods, system, equipment and the storage medium of automobile
CN109559536A (en) Traffic lights, traffic light recognition method, device, equipment and storage medium
CN114913525A (en) Traffic signal lamp identification method, device, equipment and storage medium
CN113989772A (en) Traffic light detection method and device, vehicle and readable storage medium
CN113343872B (en) Traffic light identification method, device, equipment, medium and product
CN109635701A (en) Lane attribute acquisition methods, device and computer readable storage medium
CN112699773B (en) Traffic light identification method and device and electronic equipment
CN109635719B (en) Image recognition method, device and computer readable storage medium
CN108108729B (en) License plate type identification method and device
CN115620047A (en) Target object attribute information determination method and device, electronic equipment and storage medium
CN115830559A (en) Method for identifying lane line of tire crane, storage medium and electronic equipment
CN112164221B (en) Image data mining method, device and equipment and road side equipment
CN110741379A (en) Method for determining the type of road on which a vehicle is travelling
CN116311193A (en) Traffic light detection method, computer equipment and automobile
CN114882451A (en) Image processing method, device, equipment and medium
CN112970030A (en) Method and device for detecting traffic light
CN111881232A (en) Semantic association lane acquisition method and device for traffic lights

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant