CN-122023938-A - Label drawing method, label drawing device, computer equipment and readable storage medium
Abstract
The application relates to a label drawing method, a label drawing device, computer equipment and a readable storage medium. The label drawing method comprises the steps of obtaining at least one first image in an image training set to be labeled, drawing a target edge of the first image in a drawing interface of training software through an adaptive label drawing pattern to form a label line attached to the target edge, forming a region with a preset width by taking the label line as a central line, and taking the outline of the region as a label of the first image, wherein the preset width is the width of the label. By adopting the method, the label generation efficiency can be improved.
Inventors
- PENG MENG
- LI ZHAOSHUN
- HE JUNLI
- SHI HUIHUI
- LAI SHENGHUI
- WANG JIANQIANG
Assignees
- 深圳市中图仪器股份有限公司
Dates
- Publication Date
- 20260512
- Application Date
- 20251024
Claims (10)
- 1. A label drawing method, characterized in that the method comprises: acquiring at least one first image in an image training set to be annotated; Drawing a target edge of the first image in a drawing interface of training software through an adapted label drawing pattern to form a mark line attached to the target edge; And forming a region with a preset width by taking the mark line as a central line, and taking the outline of the region as a labeling label of the first image, wherein the preset width is the width of the labeling label.
- 2. The method of claim 1, wherein the drawing the target edge of the first image in the drawing interface of training software with the adapted label drawing pattern forms a mark line that fits the target edge, comprising: drawing rough drawing mark points at the positions of the target edges of the first image in a drawing interface of training software; Drawing a plurality of fine drawing mark points along a shape path determined by the target edge between every two adjacent rough drawing mark points; And connecting and fitting the fine drawing mark points and the rough drawing mark points to obtain mark lines of the target edge.
- 3. The method according to claim 2, wherein the connecting and fitting the fine drawing mark points and the rough drawing mark points to obtain the mark line of the target edge comprises: Deleting or moving any marking point in the fine drawing marking point and the rough drawing marking point, or adding marking points on the basis of the fine drawing marking point and the rough drawing marking point to obtain a target marking point; And connecting and fitting each target mark point to obtain a mark line of the target edge.
- 4. The method of claim 1, wherein the drawing the target edge of the first image in the drawing interface of training software with the adapted label drawing pattern forms a mark line that fits the target edge, comprising: the method comprises the steps of carrying out sectional drawing on a target edge of a first image through an adaptive label drawing pattern in a drawing interface of training software to obtain a multi-section marking line, wherein the tail end of the last section marking line and the beginning of the next section marking line share the same rough drawing marking point; And forming a mark line attached to the edge of the target according to the plurality of sections of mark lines.
- 5. The method according to any one of claims 1 to 4, further comprising: And determining labels of second images according to the labeling labels of the first images, wherein the second images are images in the image training set except the first images, and the number of the second images is larger than that of the first images.
- 6. The method of claim 5, wherein determining the label of the second image from the labeling label of the first image comprises: and if the similarity between the second image and the first image reaches a similarity threshold, generating a label of the second image according to the labeling label of the first image.
- 7. A label drawing apparatus, characterized in that the apparatus comprises: the image acquisition module is used for acquiring at least one first image in the image training set to be marked; The marking line drawing module is used for drawing the target edge of the first image through the matched label drawing pattern in the drawing interface of training software to form a marking line attached to the target edge; the label labeling module is used for forming a region with a preset width by taking the marking line as a central line, taking the outline of the region as a labeling label of the first image, and the preset width is the width of the labeling label.
- 8. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any of claims 1 to 6 when the computer program is executed.
- 9. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 6.
- 10. A computer program product comprising a computer program which, when executed by a processor, implements the steps of the method of any one of claims 1 to 6.
Description
Label drawing method, label drawing device, computer equipment and readable storage medium The application relates to a patent application with application date of 2025, 10 month and 24 days, application number of 202511528578.9, application name of label inheritance method, model training method, measuring equipment and medium. Technical Field The present application relates to the field of artificial intelligence technology, and in particular, to a label drawing method, apparatus, computer device, computer readable storage medium, and computer program product. Background The image measuring device (such as an image measuring instrument or a flash measuring instrument) can realize precise measurement of the surface size, the outline, the angle, the position, the form and position tolerance and the like of various complex parts. In practical application, geometric features (such as planes, lines and points) of the workpiece can be extracted through the image measuring instrument, and length or angle information of the geometric features is calculated, so that whether machining precision of the workpiece meets requirements can be judged. With the rapid development of artificial intelligence technology, image measurements may be made based on an artificial intelligence (ARTIFICIAL INTELLIGENCE, AI) model. However, when training the AI model in the image measuring instrument, a large number of sample images are often required, and each sample image needs to be labeled. In the traditional technology, when labeling of sample images is carried out, the sample images are often drawn one by one manually, which requires a great deal of repeated labor, and the labeling efficiency is low. Disclosure of Invention In view of the foregoing, it is desirable to provide a label drawing method, apparatus, computer device, computer-readable storage medium, and computer program product that can improve the efficiency of label labeling. In a first aspect, the present application provides a label drawing method, including: acquiring at least one first image in an image training set to be annotated; Drawing a target edge of the first image in a drawing interface of training software through an adapted label drawing pattern to form a mark line attached to the target edge; And forming a region with a preset width by taking the mark line as a central line, and taking the outline of the region as a labeling label of the first image, wherein the preset width is the width of the labeling label. In a second aspect, the present application also provides a label drawing apparatus, including: the image acquisition module is used for acquiring at least one first image in the image training set to be marked; The marking line drawing module is used for drawing the target edge of the first image through the matched label drawing pattern in the drawing interface of training software to form a marking line attached to the target edge; the label labeling module is used for forming a region with a preset width by taking the marking line as a central line, taking the outline of the region as a labeling label of the first image, and the preset width is the width of the labeling label. In a third aspect, the present application also provides a computer device comprising a memory storing a computer program and a processor implementing the steps of the label drawing method provided in the first aspect when the computer program is executed by the processor. In a fourth aspect, the present application also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the label drawing method provided in the first aspect. In a fifth aspect, the present application also provides a computer program product comprising a computer program which, when executed by a processor, implements the steps of the label drawing method provided in the first aspect. According to the label drawing method, the label drawing device, the computer equipment, the computer readable storage medium and the computer program product, at least one first image in the image training set to be marked is obtained, the target edge of the first image is drawn in the drawing interface of training software through the adaptive label drawing pattern to form the label line attached to the target edge, the label line is taken as the central line to form the area with the preset width, the outline of the area is taken as the marking label of the first image, quick and accurate image label marking in the training software can be achieved, the situation that labels of each image need to be marked from the beginning is avoided, a large amount of repetitive labor is caused, labor cost is reduced, and label generation efficiency is improved. Drawings In order to more clearly illustrate the embodiments of the present application or the technical solutions in the related art, the drawings that are needed in the descriptio