CN114239169A - Automatic part size marking method and device based on key point matching - Google Patents

Automatic part size marking method and device based on key point matching Download PDF

Info

Publication number
CN114239169A
CN114239169A CN202111531700.XA CN202111531700A CN114239169A CN 114239169 A CN114239169 A CN 114239169A CN 202111531700 A CN202111531700 A CN 202111531700A CN 114239169 A CN114239169 A CN 114239169A
Authority
CN
China
Prior art keywords
labeled
neural network
network model
marked
points
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.)
Pending
Application number
CN202111531700.XA
Other languages
Chinese (zh)
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.)
Beijing Construction Technology Co ltd
Original Assignee
Beijing Construction 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 Beijing Construction Technology Co ltd filed Critical Beijing Construction Technology Co ltd
Priority to CN202111531700.XA priority Critical patent/CN114239169A/en
Publication of CN114239169A publication Critical patent/CN114239169A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/10Geometric CAD
    • G06F30/17Mechanical parametric or variational design
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Geometry (AREA)
  • General Physics & Mathematics (AREA)
  • Evolutionary Computation (AREA)
  • General Engineering & Computer Science (AREA)
  • Biophysics (AREA)
  • Software Systems (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • Biomedical Technology (AREA)
  • Artificial Intelligence (AREA)
  • Mathematical Physics (AREA)
  • Data Mining & Analysis (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Computational Mathematics (AREA)
  • Mathematical Analysis (AREA)
  • Mathematical Optimization (AREA)
  • Pure & Applied Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Processing Or Creating Images (AREA)

Abstract

The embodiment of the disclosure relates to a computer-implemented automatic part size marking method and device. The method comprises the following steps: reading a part drawing to be marked; determining a plurality of key points of the part to be marked based on the part drawing to be marked; obtaining a plurality of candidate marking points of the part to be marked by utilizing a first neural network model based on a plurality of key points; based on the candidate marking points, obtaining a plurality of matching marking point pairs of the part to be marked by utilizing a second neural network model; marking the size of the related part to be marked in the part drawing to be marked based on the plurality of matched marking point pairs to obtain a marked part drawing; and constructing a labeled relation graph based on the plurality of matched labeled point pairs, and checking the labeled part graph by using the labeled relation graph to obtain a checking result. By using the method, the selection and matching of the marking points in the part marking can be automatically completed in a machine learning mode, and the automatic marking of the linear dimension of the part is realized.

Description

Automatic part size marking method and device based on key point matching
Technical Field
The embodiment of the disclosure mainly relates to the field of part size marking. And more particularly, to a method and apparatus for automatic part dimension labeling based on keypoint matching.
Background
A great deal of functional requirements for drawing size marking of parts exist in the civil engineering field and the mechanical design field. At present, automatic labeling of part sizes is mainly realized by comparing the existing parts with part templates in a part library one by one through a template matching method (for example, the existing parts are I-shaped sections, and the corresponding I-shaped section labeling mode in the part library can be directly applied), determining a part labeling method, and modeling by using inherent parts in the part library in part design software to realize automatic labeling more conveniently. However, as the number of special-shaped parts is increased and the special-shaped parts do not have uniform shapes, corresponding part templates are difficult to find in the part library, and the parts are added into the part library completely, so that the part library is overstaffed, the retrieval efficiency is reduced, and the use is influenced.
Disclosure of Invention
The embodiment of the disclosure provides a method and a device for automatically labeling a part size based on key point matching, electronic equipment and a computer-readable storage medium.
In a first aspect of the present disclosure, a computer-implemented automatic part sizing method is provided. The method comprises the following steps: reading a part drawing to be marked; determining a plurality of key points of the part to be marked based on the part drawing to be marked; obtaining a plurality of candidate marking points of the part to be marked by utilizing a first neural network model based on a plurality of key points; obtaining a plurality of matching marking point pairs of the part to be marked by utilizing a second neural network model based on the plurality of candidate marking points; marking the size of the related part to be marked in the part drawing to be marked based on the plurality of matched marking point pairs to obtain a marked part drawing; and constructing a labeled relation graph based on the plurality of matched labeled point pairs, and checking the labeled part graph by using the labeled relation graph to obtain a checking result.
In a second aspect of the present disclosure, there is provided an automatic part size labeling apparatus, including: the input module is configured to read a part drawing to be marked; the key point determining module is configured to determine a plurality of key points of the part to be marked based on the part drawing to be marked; the candidate marking point obtaining module is configured to obtain a plurality of candidate marking points of the part to be marked by utilizing the first neural network model based on the plurality of key points; the matching marking point acquisition module is configured to acquire a plurality of matching marking point pairs of the part to be marked by utilizing the second neural network model based on the plurality of candidate marking points; the marking module is configured to mark the size of the relevant part to be marked in the part drawing to be marked to obtain the marked part drawing; and the inspection module is configured to construct a labeled relation diagram based on the plurality of matched labeled point pairs and inspect the labeled part diagram by using the labeled relation diagram to obtain an inspection result.
In a third aspect of the present disclosure, an electronic device is provided. The electronic device includes: a memory and a processor; wherein the memory is for storing one or more computer instructions, wherein the one or more computer instructions are executed by the processor to implement the method according to the first aspect.
In a fourth aspect of the disclosure, a computer-readable storage medium is provided. The computer readable storage medium has stored thereon one or more computer instructions, wherein the one or more computer instructions are executed by a processor to implement a method according to the first aspect.
In a fifth aspect of the disclosure, a computer program product is provided. The computer program product comprises one or more computer instructions, wherein the one or more computer instructions are executed by a processor to implement the method according to the first aspect.
This summary is provided to introduce a selection of concepts in a simplified form that are further described below in the detailed description. This summary is not intended to identify key features or essential features of the claimed subject matter, nor is it intended to be used to limit the scope of the claimed subject matter.
Drawings
The above and other features, advantages and aspects of various embodiments of the present disclosure will become more apparent by referring to the following detailed description when taken in conjunction with the accompanying drawings. In the drawings, like or similar reference characters designate like or similar elements, and wherein:
FIG. 1 shows a schematic diagram of an exemplary environment 100, in accordance with embodiments of the present disclosure;
FIG. 2 illustrates a flow diagram of an exemplary part dimension automatic labeling method 200, according to an embodiment of the present disclosure;
FIG. 3 illustrates a block diagram of an exemplary automatic part-size labeling apparatus 300, in accordance with an embodiment of the present disclosure;
FIG. 4 illustrates an exemplary part to be labeled diagram according to an embodiment of the present disclosure;
FIG. 5 illustrates an exemplary labeled part view according to an embodiment of the disclosure; and
FIG. 6 illustrates a block diagram of a computing system 600 in which one or more embodiments of the disclosure may be implemented.
Detailed Description
Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While certain embodiments of the present disclosure are shown in the drawings, it is to be understood that the present disclosure may be embodied in various forms and should not be construed as limited to the embodiments set forth herein, but rather are provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the disclosure are for illustration purposes only and are not intended to limit the scope of the disclosure.
As used herein, the terms "comprises," comprising, "and variations thereof are intended to be open-ended, i.e.," including, but not limited to. The term "based on" is "based, at least in part, on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment". Relevant definitions for other terms will be given in the following description.
The inventor notices that the existing automatic part size labeling mainly determines the part labeling method by comparing the existing part and the part templates in the part library one by one through a template matching method (for example, the existing part has an I-shaped section, and the corresponding I-shaped section labeling mode exists in the part library, which can be directly applied). Although automatic labeling can be more conveniently realized by using inherent part modeling in a part library in part design software, because the existing special-shaped parts are more and the special-shaped parts are not in uniform shapes, corresponding part templates are difficult to find in the part library, and the part library is overstaffed when the special-shaped parts are completely added into the part library, so that the retrieval efficiency is reduced, and the use is influenced.
To at least partially solve some of the above problems. The embodiment of the disclosure provides a part size automatic labeling method based on key point matching. In the embodiment of the disclosure, a part drawing of a part to be labeled is obtained first, and all key points possibly related to labeling in the part drawing are extracted, namely possible end points in the labeling. And then extracting key points which can possibly mark points for the part from all the key points by utilizing a corresponding neural network model to obtain a set of candidate marking points. And pairing the candidate marking points pairwise, and determining a marking point pair matched with the part graph to be marked by utilizing another corresponding neural network model. Matching annotation point pairs refer to the combination of points pointed to by the size boundary in the dimension annotation. And the marked dimension lines and marked characters can be led out by matching the marked point pairs. And finally, marking the whole part based on the matched marking points by utilizing the prior art. For example, in AutoCAD, linear dimension marking can be automatically performed based on the matching mark points, that is, the steps of drawing dimension lines and marking characters are completed. The method can also verify the labeling result of the part by generating a relation graph of the labeling points after labeling.
Through the technical scheme, the method is combined with the deep learning model and the marking points of the part are automatically judged and matched based on the key points of the part, so that the problem of automation of marking point selection and matching in part marking is solved, and the method is particularly suitable for automatic marking of special-shaped parts. And the method provides a result checking method on the basis of automatically generating the label, thereby ensuring the correctness of the result.
Fig. 1 shows a schematic diagram of an exemplary environment 100, in accordance with an embodiment of the present disclosure.
At a computing device, e.g., computing device 120 of FIG. 1, an unlabeled part view, e.g., unlabeled part view 110 of FIG. 1, is read. In some embodiments, a two-dimensional part drawing having the shape of the part to be labeled may be generated by techniques known in the art based on a three-dimensional model of the part.
The computing device 120 first obtains the keypoints in the part drawing, e.g., as executed in a keypoint obtaining module, and then determines candidate annotation points in the keypoints using the first neural network model, e.g., as executed in a candidate annotation point obtaining module. The computing device 120 then pairs the annotation points pairwise and determines pairs of annotation points that match the annotation to be added to the part using the second neural network model, e.g., as performed in a matching annotation point acquisition module.
After obtaining the matching annotation points, the computing device 120 automatically completes the addition of the annotation using techniques known in the art, e.g., executing in an annotation module, and finally generates an annotated part drawing, e.g., the annotated part drawing 130 of fig. 1. For example, the marking work such as automatically measuring the dimension number, adding the dimension, and leading out the dimension line can be completed based on the matching marking point pair by the existing design drawing software such as Autodesk and the like.
After the annotation is completed, the computing device 120 may check whether the annotation of the part is correct by constructing a relationship diagram of the annotation points, and generate a corresponding check result, for example, to be executed in a check module.
In some embodiments, computing device 120 may include, but is not limited to, a personal computer, a server computer, a hand-held or laptop device, a mobile device (such as a mobile phone, a Personal Digital Assistant (PDA), a media player, etc.), a multiprocessor system, a consumer electronics, a minicomputer, a mainframe computer, a distributed computing environment that includes any of the above systems or devices, and the like.
The process of automatic labeling of parts according to the disclosed embodiments will be described in detail below with reference to the accompanying drawings. For ease of understanding, specific data mentioned in the following description are exemplary and are not intended to limit the scope of the present disclosure. It is to be understood that the described methods may include additional acts not shown and/or may omit acts shown, as the scope of the disclosure is not limited in this respect.
FIG. 2 shows a flow diagram of an exemplary part dimension automatic labeling method, according to an embodiment of the present disclosure.
At block 202, a part drawing to be labeled is read.
In some embodiments, a two-dimensional part drawing having the shape of the part to be labeled may be generated by techniques known in the art based on a three-dimensional model of the part. By way of example, FIG. 4 illustrates a two-dimensional part drawing to be labeled.
At block 204, a plurality of keypoints for the part to be labeled is determined based on the part drawing to be labeled.
In some embodiments, the key points of the part to be labeled include line segment end points, line segment middle points, arc end points, arc center points, foci of ellipses, polygons, geometric center points of circles, intersections of lines, and the like.
At block 206, a plurality of candidate labels for the part to be labeled are obtained using the first neural network model based on the plurality of keypoints.
In some embodiments, the first neural network model is a multi-classification model of the machine learning field to achieve automatic classification of the key points to obtain candidate labeling points matching the part to be labeled therein.
In some embodiments, the training process of the first neural network model comprises:
the labeled sample part drawings are read, and in some embodiments, the previously completed labeled part drawings may be employed as the sample part drawings.
Determining a plurality of keypoints for the sample part map based on the sample part map, in some embodiments, keypoints may be extracted for each part map in the sample part map set, and the keypoints may include line segment endpoints, line segment midpoints, arc line endpoints, arc center points, foci of ellipses, polygons, geometric center points of circles, and intersections of lines, among others.
A training data set is constructed based on the plurality of key points and the sample part map, and in some embodiments, the training data set is constructed by classifying the key points into two types, labeled points and non-labeled points, in combination with the sample part map.
And constructing a first neural network model, and training the first neural network model by using the training data set to obtain the trained first neural network model.
The trained first neural network model can automatically classify key points in the input part drawing to be labeled, so that candidate labeling points in the part drawing to be labeled are obtained.
At block 208, a plurality of matching pairs of labeled points for the part to be labeled is obtained using the second neural network model based on the plurality of candidate labeled points.
In some embodiments, the second neural network model is a multi-classification model of the machine learning domain.
In some embodiments, the training process of the second neural network model comprises:
the labeled sample part drawings are read, and in some embodiments, the previously completed labeled part drawings may be employed as the sample part drawings.
A plurality of annotation points in the sample part view are determined based on the sample part view.
In some embodiments, the marking points are combined and paired pairwise, and then the pairing result is compared with the existing marking result in the sample part map, so that the consistent sample is classified as a positive sample, and the inconsistent sample is classified as a negative sample. The labels of the positive swatches are then set to paired and the labels of the negative swatches are set to unpaired. In some embodiments, the label categories of the data set may be further divided into: unpaired, horizontal annotation paired, vertical annotation paired, horizontal and vertical simultaneous paired and equal. In some embodiments, the number of samples in the dataset of different tags may be scaled according to a scale.
And constructing a second neural network model, and training the second neural network model by utilizing the training data set to obtain the trained second neural network model.
The trained second neural network model can perform matching judgment on pairwise matched marking point pairs consisting of candidate marking points in the part drawing to be marked and the part to be marked, and obtain marking point pairs matched with the part to be marked, namely matched marking point pairs.
At block 210, based on the plurality of matching labeling point pairs, in the part drawing to be labeled, the size of the relevant part to be labeled is labeled, and a labeled part drawing is obtained.
After the matching marking points are obtained, the addition of the marks can be automatically completed by utilizing the prior art in the field, and finally, the marked part drawing is generated. In some embodiments, the labeling work of automatically measuring the dimension numbers and adding dimensions, and drawing out dimension lines, etc. can be done by existing design drawing software such as AutoCAD. Illustratively, FIG. 5 shows a labeled part view.
At block 212, a labeled relational graph is constructed based on the plurality of matching labeled point pairs and the labeled part graph is inspected using the labeled relational graph to obtain inspection results.
First, a labeled relationship graph is constructed based on a plurality of matching labeled point pairs, and in some embodiments, edges of the labeled relationship graph can be generated according to pairwise matching results of the matching labeled points. In some embodiments, the annotated relationship graph comprises a horizontal pair relationship graph and a vertical pair relationship graph.
And inspecting the labeled part drawing based on the generated labeling relation drawing to obtain an inspection result. In some embodiments, when a ring-shaped relationship exists in the annotation relationship graph, the annotation redundancy phenomenon is illustrated, so that an annotation redundancy result is generated, and the relevant annotation producing the ring is indicated to remind a user whether to delete a certain annotation.
In some embodiments, when isolated points exist in the annotation relation graph, the existence of the missing matching behavior is illustrated, so that a missing matching result is generated, and the isolated points are indicated, and whether the annotation is supplemented or not is determined by a user.
In some embodiments, the inferred coordinates of the matching labeled points may be generated based on a labeled relationship diagram, for example, with a labeled point in the diagram as an origin, and the coordinates of each labeled point are inferred according to the pairing relationship (the connection relationship of the points, the labeled type (horizontal or vertical) and the dimension number, etc.) in the labeled relationship diagram, so as to find the drawing problem according to the comparison of the inferred result and the coordinates of the actual drawing point. And when the inferred coordinate is inconsistent with the actual coordinate of the labeled point, generating a labeled size abnormal result.
Fig. 3 shows a block diagram of an exemplary automatic part-size labeling apparatus according to an embodiment of the present disclosure.
An input module 302 configured to read a part drawing to be labeled.
The key point determining module 304 is configured to determine a plurality of key points of the part to be labeled based on the part drawing to be labeled.
The candidate annotation point obtaining module 306 is configured to obtain a plurality of candidate annotation points of the part to be annotated by using the first neural network model based on the plurality of key points.
A matching annotation point obtaining module 308 configured to obtain a plurality of matching annotation point pairs of the part to be annotated by using the second neural network model based on the plurality of candidate annotation points.
And the marking module 310 is configured to mark the size of the relevant part to be marked at each matching marking point in the part drawing to be marked, so as to obtain the marked part drawing.
And the checking module 312 is configured to construct a labeled relation diagram based on the plurality of matching labeled point pairs and check the labeled part diagram by using the labeled relation diagram to obtain a checking result.
In some embodiments, the candidate annotation point acquisition module further comprises: a sample acquisition module configured to read the labeled sample part drawing; a training data generation module configured to determine a plurality of keypoints for the sample part map based on the sample part map, and construct a training data set based on the plurality of keypoints and the sample part map; a training module configured to construct a first neural network model and train the first neural network model using a training data set, obtaining the trained first neural network model, wherein the first neural network model is a multi-classification neural network model; and the reasoning module is configured to obtain a plurality of candidate marking points of the part to be marked by utilizing the trained first neural network model.
In some embodiments, the matching annotation point obtaining module further comprises: a sample acquisition module configured to read the labeled sample part drawing; a training data generation module configured to obtain a plurality of labeling points of the sample part drawing based on the sample part drawing, and construct a training data set based on the labeling points and the sample part drawing; a training module configured to construct a second neural network model and train the second neural network model using the training data set to obtain a trained second neural network model, wherein the second neural network model is a multi-classification neural network model; and the reasoning module is configured to determine a plurality of matching marking point pairs matched with the part to be marked by utilizing the trained second neural network model.
In some embodiments, the inspection module further comprises: the annotation relation graph building module is configured to build an annotation relation graph based on the plurality of matching annotation point pairs; and the inspection result generation module is configured to inspect the labeled part drawing based on the labeled relation drawing to obtain an inspection result.
In some embodiments, the annotated relationship graph comprises a horizontal pair relationship graph and a vertical pair relationship graph.
In some embodiments, the inspection module is further configured to: when the labeling relation graph has a ring relation, generating a labeling redundancy result; when isolated points exist in the labeling relation graph, generating a missing matching result; and generating an inferred coordinate matched with the labeled point based on the labeling relation graph, and generating a labeled size abnormal result when the inferred coordinate is inconsistent with the actual coordinate of the labeled point.
In some embodiments, the keypoints comprise line segment endpoints, line segment midpoints, arc endpoints, arc center points, foci of ellipses, polygons, geometric center points of circles, and intersections of lines.
In some embodiments, the data sets include unpaired data sets, horizontally annotated paired data sets, vertically annotated paired data sets, and horizontally and vertically paired simultaneous data sets.
FIG. 6 illustrates a schematic block diagram of an example electronic device 600 that can be used to implement embodiments of the present disclosure. For example, electronic device 600 may be used to implement computing device 120 shown in fig. 1. As shown, device 600 includes a Central Processing Unit (CPU)601 that may perform various appropriate actions and processes in accordance with computer program instructions stored in a Read Only Memory (ROM)602 or loaded from a storage unit 608 into a Random Access Memory (RAM) 603. In the RAM603, various programs and data required for the operation of the device 600 can also be stored. The CPU 601, ROM 602, and RAM603 are connected to each other via a bus 604. An input/output (I/O) interface 605 is also connected to bus 604.
A number of components in the device 600 are connected to the I/O interface 605, including: an input unit 606 such as a keyboard, a mouse, or the like; an output unit 607 such as various types of displays, speakers, and the like; a storage unit 608, such as a magnetic disk, optical disk, or the like; and a communication unit 609 such as a network card, modem, wireless communication transceiver, etc. The communication unit 609 allows the device 600 to exchange information/data with other devices via a computer network such as the internet and/or various telecommunication networks.
Processing unit 601 performs the methods and processes described above, such as process 200. For example, in some embodiments, process 200 may be implemented as a computer software program or computer program product tangibly embodied in a machine-readable medium, such as storage unit 608. In some embodiments, part or all of the computer program may be loaded and/or installed onto the device 600 via the ROM 602 and/or the communication unit 609. When the computer program is loaded into RAM603 and executed by CPU 601, one or more steps of any of processes 200 described above may be performed. Alternatively, in other embodiments, CPU 601 may be configured to perform process 200 in any other suitable manner (e.g., by way of firmware).
The present disclosure may be methods, apparatus, systems, and/or computer program products. The computer program product may include a computer-readable storage medium having computer-readable program instructions embodied thereon for carrying out various aspects of the present disclosure. In some embodiments, the methods described in the present disclosure may be used in steel structure deepening design software. In some embodiments, the methods described in the present disclosure may be implemented in the steel structure deepening design software PKPM-DetailWorks.
The computer readable storage medium may be a tangible device that can hold and store the instructions for use by the instruction execution device. The computer readable storage medium may be, for example, but not limited to, an electronic memory device, a magnetic memory device, an optical memory device, an electromagnetic memory device, a semiconductor memory device, any non-transitory memory device, or any suitable combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium would include the following: a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a Static Random Access Memory (SRAM), a portable compact disc read-only memory (CD-ROM), a Digital Versatile Disc (DVD), a memory stick, a floppy disk, a mechanical coding device, such as punch cards or in-groove projection structures having instructions stored thereon, and any suitable combination of the foregoing. Computer-readable storage media as used herein is not to be construed as transitory signals per se, such as radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through a waveguide or other transmission medium (e.g., optical pulses through a fiber optic cable), or electrical signals transmitted through electrical wires.
The computer-readable program instructions described herein may be downloaded from a computer-readable storage medium to a respective computing/processing device, or to an external computer or external storage device via a network, such as the internet, a local area network, a wide area network, and/or a wireless network. The network may include copper transmission cables, fiber optic transmission, wireless transmission, routers, firewalls, switches, gateway computers and/or edge servers. The network adapter card or network interface in each computing/processing device receives computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in a computer-readable storage medium in the respective computing/processing device.
The computer program instructions for carrying out operations of the present disclosure may be assembler instructions, Instruction Set Architecture (ISA) instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source or object code written in any combination of one or more programming languages, including an object oriented programming language such as Smalltalk, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The computer-readable program instructions may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider). In some embodiments, the electronic circuitry that can execute the computer-readable program instructions implements aspects of the present disclosure by utilizing the state information of the computer-readable program instructions to personalize the electronic circuitry, such as a programmable logic circuit, a Field Programmable Gate Array (FPGA), or a Programmable Logic Array (PLA).
Various aspects of the present disclosure are described herein with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the disclosure. It will be understood that each block of the flowchart illustrations and/or block diagrams, and combinations of blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer-readable program instructions.
These computer-readable program instructions may be provided to a processing unit of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processing unit of the computer or other programmable data processing apparatus, create means for implementing the functions/acts specified in the flowchart and/or block diagram block or blocks. These computer-readable program instructions may also be stored in a computer-readable storage medium that can direct a computer, programmable data processing apparatus, and/or other devices to function in a particular manner, such that the computer-readable medium storing the instructions comprises an article of manufacture including instructions which implement the function/act specified in the flowchart and/or block diagram block or blocks.
The computer readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other devices to cause a series of operational steps to be performed on the computer, other programmable apparatus or other devices to produce a computer implemented process such that the instructions which execute on the computer, other programmable apparatus or other devices implement the functions/acts specified in the flowchart and/or block diagram block or blocks.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of instructions, which comprises one or more executable instructions for implementing the specified logical function(s). In some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
Having described embodiments of the present disclosure, the foregoing description is intended to be exemplary, not exhaustive, and not limited to the disclosed embodiments. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The terminology used herein was chosen in order to best explain the principles of the embodiments, the practical application, or improvements made to the technology in the marketplace, or to enable others of ordinary skill in the art to understand the embodiments disclosed herein.

Claims (18)

1. A computer-implemented automatic part size labeling method comprises the following steps:
reading a part drawing to be marked;
determining a plurality of key points of the part to be marked based on the part drawing to be marked;
obtaining a plurality of candidate marking points of the part to be marked by utilizing a first neural network model based on the plurality of key points;
obtaining a plurality of matching marking point pairs of the part to be marked by utilizing a second neural network model based on the plurality of candidate marking points;
marking the size of the relevant part to be marked in the part drawing to be marked based on the plurality of matched marking point pairs to obtain a marked part drawing; and
and constructing a labeled relation graph based on the plurality of matched labeled point pairs, and inspecting the labeled part graph by using the labeled relation graph to obtain an inspection result.
2. The method of claim 1, wherein obtaining a plurality of candidate marking points for the part to be marked using a first neural network model comprises:
reading the marked sample part drawing;
determining a plurality of keypoints for the sample part map based on the sample part map;
constructing a training data set based on the plurality of key points and the sample part map;
constructing the first neural network model, and training the first neural network model by using the training data set to obtain a trained first neural network model, wherein the first neural network model is a multi-classification neural network model; and
and obtaining a plurality of candidate marking points of the part to be marked by utilizing the trained first neural network model.
3. The method of claim 1, wherein obtaining a plurality of matching labeled point pairs for the part to be labeled using a second neural network model comprises:
reading the marked sample part drawing;
determining a plurality of annotation points for the sample part drawing based on the sample part drawing;
constructing a training data set based on the plurality of marking points and the sample part drawing;
constructing the second neural network model, and training the second neural network model by using the training data set to obtain a trained second neural network model, wherein the second neural network model is a multi-classification neural network model; and
and obtaining a plurality of matching marking point pairs of the part to be marked by utilizing the trained second neural network model.
4. The method of claim 1, wherein the annotated relationship graph comprises a horizontal pair relationship graph and a vertical pair relationship graph.
5. The method of claim 1, wherein inspecting the labeled part drawing using the labeled relationship drawing comprises:
when the labeling relation graph has a ring relation, generating a labeling redundancy result;
when isolated points exist in the labeling relation graph, generating a missing matching result; and
and generating an inferred coordinate of each labeled point in the matched labeled point pair based on the labeled relation graph, and generating a labeled size abnormal result when the inferred coordinate is inconsistent with the actual coordinate of the labeled point.
6. The method of claim 1, wherein the keypoints comprise line segment endpoints, line segment midpoints, arc endpoints, arc center points, foci of ellipses, polygons, geometric center points of circles, and intersections of lines.
7. The method of claim 3, wherein the data sets comprise an unpaired data set, a horizontally annotated paired data set, a vertically annotated paired data set, and a horizontally vertically simultaneous paired data set.
8. An automatic part size marking device, comprising:
the input module is configured to read a part drawing to be marked;
the key point determining module is configured to determine a plurality of key points of the part to be marked based on the part drawing to be marked;
the candidate marking point obtaining module is configured to obtain a plurality of candidate marking points of the part to be marked by utilizing a first neural network model based on the plurality of key points;
a matching annotation point acquisition module configured to acquire a plurality of matching annotation point pairs of the part to be annotated by using a second neural network model based on the plurality of candidate annotation points;
the marking module is configured to mark the size of the relevant part to be marked in the part drawing to be marked to obtain a marked part drawing; and
the checking module is configured to construct a labeled relation graph based on the plurality of matched labeled point pairs and check the labeled part graph by using the labeled relation graph to obtain a checking result.
9. The apparatus of claim 8, wherein the candidate annotation point acquisition module further comprises:
a sample acquisition module configured to read the labeled sample part drawing;
a training data generation module configured to determine a plurality of keypoints for the sample part diagram based on the sample part diagram, and construct a training data set based on the plurality of keypoints and the sample part diagram;
a training module configured to build the first neural network model and train the first neural network model using the training data set to obtain a trained first neural network model, wherein the first neural network model is a multi-class neural network model; and
and the reasoning module is configured to obtain a plurality of candidate marking points of the part to be marked by utilizing the trained first neural network model.
10. The apparatus of claim 8, wherein the matching annotation point acquisition module further comprises:
a sample acquisition module configured to read the labeled sample part drawing;
a training data generation module configured to obtain a plurality of labeling points of the sample part drawing based on the sample part drawing, and construct a training data set based on the plurality of labeling points and the sample part drawing;
a training module configured to construct the second neural network model and train the second neural network model using the training data set to obtain a trained second neural network model, wherein the second neural network model is a multi-class neural network model; and
and the reasoning module is configured to determine a plurality of matching marking point pairs matched with the part to be marked by utilizing the trained second neural network model.
11. The apparatus of claim 8, wherein the inspection module further comprises:
the annotation relation graph building module is configured to build an annotation relation graph based on the plurality of matching annotation point pairs; and
and the inspection result generation module is configured to inspect the labeled part drawing based on the labeled relation drawing to obtain an inspection result.
12. The apparatus of claim 11, wherein the annotated relationship graph comprises a horizontal pair relationship graph and a vertical pair relationship graph.
13. The apparatus of claim 11, wherein the inspection module is further configured to:
when the labeling relation graph has a ring relation, generating a labeling redundancy result;
when isolated points exist in the labeling relation graph, generating a missing matching result; and
and generating an inferred coordinate of each labeled point in the matched labeled point pair based on the labeled relation graph, and generating a labeled size abnormal result when the inferred coordinate is inconsistent with the actual coordinate of the labeled point.
14. The apparatus of claim 8, wherein the keypoints comprise line segment endpoints, line segment midpoints, arc endpoints, arc center points, foci of ellipses, polygons, geometric center points of circles, and intersections of lines.
15. The apparatus of claim 10, wherein the data sets comprise an unpaired data set, a horizontally annotated paired data set, a vertically annotated paired data set, and a horizontally and vertically simultaneous paired data set.
16. An electronic device, comprising:
a memory and a processor;
wherein the memory is to store one or more computer instructions, wherein the one or more computer instructions are to be executed by the processor to implement the method of any one of claims 1 to 7.
17. A computer readable storage medium having one or more computer instructions stored thereon, wherein the one or more computer instructions are executed by a processor to implement the method of any one of claims 1 to 7.
18. A computer program product comprising one or more computer instructions, wherein the one or more computer instructions are executed by a processor to implement the method of any one of claims 1 to 7.
CN202111531700.XA 2021-12-14 2021-12-14 Automatic part size marking method and device based on key point matching Pending CN114239169A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111531700.XA CN114239169A (en) 2021-12-14 2021-12-14 Automatic part size marking method and device based on key point matching

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111531700.XA CN114239169A (en) 2021-12-14 2021-12-14 Automatic part size marking method and device based on key point matching

Publications (1)

Publication Number Publication Date
CN114239169A true CN114239169A (en) 2022-03-25

Family

ID=80756152

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111531700.XA Pending CN114239169A (en) 2021-12-14 2021-12-14 Automatic part size marking method and device based on key point matching

Country Status (1)

Country Link
CN (1) CN114239169A (en)

Similar Documents

Publication Publication Date Title
US10360703B2 (en) Automatic data extraction from a digital image
US20140313216A1 (en) Recognition and Representation of Image Sketches
CN111095296A (en) Classifying character strings using machine learning
CN109684803B (en) Man-machine verification method based on gesture sliding
CN110796031A (en) Table identification method and device based on artificial intelligence and electronic equipment
US20230011678A1 (en) Method for predicting protein-protein interaction
JP2023529939A (en) Multimodal POI feature extraction method and apparatus
CN111488873B (en) Character level scene text detection method and device based on weak supervision learning
CN112632844A (en) Extracting and analyzing information from engineering drawings
CN113657274B (en) Table generation method and device, electronic equipment and storage medium
CN112119397A (en) Classification of pipe and meter flow chart information using machine learning
US20220391598A1 (en) Text checking method based on knowledge graph, electronic device, and medium
CN110427524A (en) Method, apparatus, electronic equipment and the storage medium of knowledge mapping completion
CN111325031B (en) Resume analysis method and device
CN115359308A (en) Model training method, apparatus, device, storage medium, and program for identifying difficult cases
CN114547301A (en) Document processing method, document processing device, recognition model training equipment and storage medium
CN111753365B (en) Method and device for extracting roadway center line
CN110362688B (en) Test question labeling method, device and equipment and computer readable storage medium
CN114239169A (en) Automatic part size marking method and device based on key point matching
CN113160385B (en) Pipeline three-dimensional modeling method and device based on graphic file and electronic equipment
CN112395450B (en) Picture character detection method and device, computer equipment and storage medium
CN115168575A (en) Subject supplement method applied to audit field and related equipment
Wijesinghe et al. Computer representation of Venn and Euler diagrams
CN113190679A (en) Relationship determination method, relationship determination device, electronic equipment and storage medium
Rana et al. Internet of Things: Energy, Industry, and Healthcare

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