CN115131813A - Method and device for confirming numbering position, electronic equipment and storage medium - Google Patents
Method and device for confirming numbering position, electronic equipment and storage medium Download PDFInfo
- Publication number
- CN115131813A CN115131813A CN202210818961.8A CN202210818961A CN115131813A CN 115131813 A CN115131813 A CN 115131813A CN 202210818961 A CN202210818961 A CN 202210818961A CN 115131813 A CN115131813 A CN 115131813A
- Authority
- CN
- China
- Prior art keywords
- component
- target
- determining
- standard
- vertex
- 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.)
- Granted
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V30/00—Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
- G06V30/40—Document-oriented image-based pattern recognition
- G06V30/42—Document-oriented image-based pattern recognition based on the type of document
- G06V30/422—Technical drawings; Geographical maps
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V30/00—Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
- G06V30/10—Character recognition
- G06V30/14—Image acquisition
- G06V30/1444—Selective acquisition, locating or processing of specific regions, e.g. highlighted text, fiducial marks or predetermined fields
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V30/00—Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
- G06V30/10—Character recognition
- G06V30/18—Extraction of features or characteristics of the image
- G06V30/1801—Detecting partial patterns, e.g. edges or contours, or configurations, e.g. loops, corners, strokes or intersections
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02P—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
- Y02P90/00—Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
- Y02P90/30—Computing systems specially adapted for manufacturing
Landscapes
- Engineering & Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Multimedia (AREA)
- Theoretical Computer Science (AREA)
- Artificial Intelligence (AREA)
- Processing Or Creating Images (AREA)
- Image Analysis (AREA)
Abstract
The embodiment of the invention provides a method and a device for confirming a numbering position, electronic equipment and a storage medium, and relates to the field of architectural design. The method comprises the following steps: a drawing including a member and a plurality of text boxes is obtained. A plurality of extension points of the member in the drawing sheet are acquired. And respectively determining the position of each numbering frame to be selected according to each extension point. It is determined whether there is a target number box having no intersection with any of the plurality of text boxes. And if so, taking the position of the target number frame as the target number position. Therefore, the condition that the serial number is overlapped with other characters in the drawing can be avoided through the pre-detection judgment.
Description
Technical Field
The invention relates to the field of architectural design, in particular to a method and a device for confirming a numbering position, electronic equipment and a storage medium.
Background
The shear wall structure is a very common structural form in building structure design, a shear wall construction drawing belongs to an important component in the shear wall structure engineering design, and a member number is very important in the shear wall construction drawing.
However, because there are many components in the construction drawing and many corresponding notational characters, the situation that various notational characters and component numbers are overlapped is easy to occur, thereby influencing the use in actual construction.
Disclosure of Invention
The invention aims to provide a method and a device for confirming a numbering position, electronic equipment and a storage medium, which can avoid the situation that the numbering is overlapped with other characters in a drawing and improve the use convenience.
Embodiments of the invention may be implemented as follows:
in a first aspect, the present invention provides a method for confirming a numbering position, which is applied to an electronic device, and includes:
acquiring a drawing containing a component and a plurality of text boxes;
acquiring a plurality of extension points of the member in the drawing;
determining the position of each numbering frame to be selected according to each extension point;
determining whether a target number box having no intersection with the plurality of text boxes exists;
and if so, taking the position of the target number frame as the target number position.
In an optional embodiment, the electronic device is preset with a plurality of standard extension points of various standard components, and the step of acquiring the plurality of extension points of the components in the drawing includes:
identifying and obtaining the vertex characteristics of the component in the drawing;
determining a target standard component corresponding to the component according to the vertex feature;
and determining a plurality of extension points of the component in the drawing according to the component, the target standard component and a plurality of standard extension points of the target standard component.
In an alternative embodiment, the step of determining a plurality of extension points of the component in the drawing according to the component, the target standard component and a plurality of standard extension points of the target standard component includes:
respectively determining the vertex corresponding relation between each vertex in the component and the corresponding vertex in the target standard component;
determining a coordinate conversion relation between the component and the target standard component according to the vertex corresponding relation;
and determining a plurality of extension points of the member in the drawing according to the coordinate conversion relation and the plurality of standard extension points.
In an alternative embodiment, the electronic device prestores a corresponding relationship between each standard extension point in each standard component and a vertex of the standard component; the step of determining the position of each number frame to be selected according to each extension point comprises the following steps:
determining a vertex corresponding to each extension point in the member according to vertexes corresponding to the extension points, the standard extension points and the standard extension points respectively;
obtaining a plurality of serial number marking lines of the component according to each extension point and the corresponding vertex;
and determining the position of each number frame to be selected according to the number marking line.
In an alternative embodiment, the method further comprises:
if not, according to a preset rule, selecting one number frame from the number frames as a target number frame, and taking the position of the target number frame as a target number position.
In an alternative embodiment, the determining whether there is a target number box having no intersection with any of the plurality of text boxes; if yes, the step of taking the position of the target number frame as the position of the target number comprises the following steps:
arranging the number frames according to a preset sequence;
sequentially determining whether a number frame without an intersection point with the plurality of text frames exists according to the preset sequence;
if so, taking the number frame which appears for the first time and has no intersection point with the plurality of text frames as the target number frame, and taking the position of the target number frame as the target number position.
In an alternative embodiment, the step of determining the coordinate transformation relationship between the component and the target standard component according to the vertex correspondence relationship includes:
acquiring a component from the drawing to obtain a second component;
determining a second coordinate system of the second component according to the vertex corresponding relation, so that the second component is consistent with the target standard component in direction under the second coordinate system; wherein the consistent orientation characterizes the target building element as being fully coincident with the second building element by a zoom operation;
and determining the coordinate conversion relation according to the coordinates of each vertex of the member on the drawing and the coordinates of each vertex of the second member under the second coordinate system.
In a second aspect, the present invention provides an apparatus for confirming a numbering position, the apparatus comprising:
the acquisition module is used for acquiring a drawing comprising a component and a plurality of text boxes;
the conversion module is used for acquiring a plurality of extension points of the component in the drawing;
the detection module is used for determining the position of each serial number frame to be selected according to each extension point; determining whether a target number box having no intersection with the plurality of text boxes exists; and if so, taking the position of the target number frame as the target number position.
In a third aspect, the present invention provides an electronic device comprising: memory, a processor and a program stored on the memory and executable on the processor, which when executed by the processor implements the method according to any of the preceding embodiments.
In a fourth aspect, the present invention provides a storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the method according to any one of the preceding embodiments.
The beneficial effects of the embodiment of the invention include, for example: the method comprises the steps of obtaining a drawing containing a component and a plurality of text boxes, and determining the positions of a plurality of number boxes to be selected of the component by determining a plurality of extension points of the component in the drawing. And subsequently, respectively judging whether the number frames to be selected and the text frames have no intersection points in the number frames to be selected so as to determine the position of the target number frame, namely the position of the target number. Therefore, when the construction drawing is generated, the target number frame which does not have the intersection point with other text frames is selected, the position of the target number frame is used as the target position, the condition that the number is overlapped with other characters in the drawing is avoided, the use in the construction process is not influenced, and the use convenience is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present invention and therefore should not be considered as limiting the scope, and for those skilled in the art, other related drawings can be obtained according to the drawings without inventive efforts.
Fig. 1 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Fig. 2 is a schematic flowchart of a method for confirming a numbering position according to an embodiment of the present invention.
Fig. 3 is a second flowchart illustrating a method for confirming a numbering position according to an embodiment of the present invention.
Fig. 4 is a third flowchart illustrating a method for confirming a number position according to an embodiment of the present invention.
Fig. 5 is a schematic structural diagram of a component and a corresponding standard component according to an embodiment of the present invention.
Fig. 6 is a fourth flowchart illustrating a method for confirming a numbering position according to an embodiment of the present invention.
Fig. 7 is a fifth flowchart illustrating a method for confirming a numbering position according to an embodiment of the present invention.
Fig. 8 is a schematic diagram of a position of a component in a plurality of coordinate systems according to an embodiment of the present invention.
Fig. 9 is a sixth flowchart illustrating a method for confirming a numbering position according to an embodiment of the present invention.
Fig. 10 is a seventh flowchart illustrating a method for confirming a numbering position according to an embodiment of the present invention.
Fig. 11 is a functional block diagram of a device for confirming a number position according to an embodiment of the present invention.
Icon: 100-an electronic device; 110-a communication unit; 120-a memory; 130-a processor;
200-confirmation of the numbered positions; 210-an obtaining module; 220-a conversion module; 230-detection module.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all embodiments of the present invention. The components of embodiments of the present invention generally described and illustrated in the figures herein may be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the present invention, presented in the figures, is not intended to limit the scope of the invention, as claimed, but is merely representative of selected embodiments of the invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
In the description of the present invention, it should be noted that if the terms "upper", "lower", "outer", etc. are used to indicate orientations or positional relationships based on the orientations or positional relationships shown in the drawings or the orientations or positional relationships usually placed when the products of the present invention are used, the terms are only used for convenience of description and simplification of the description, but do not indicate or imply that the devices or elements referred to must have specific orientations, be constructed in specific orientations, and operate, and therefore, the present invention should not be construed as being limited.
Furthermore, the appearances of the terms "first," "second," and the like, if any, are only used to distinguish one description from another and are not to be construed as indicating or implying relative importance.
It should be noted that the features of the embodiments of the present invention may be combined with each other without conflict.
In the engineering design process, various building structures and labeled information corresponding to the various building structures are provided in the construction drawing. However, due to the limited space of the drawing and the requirement that the marked characters are required to be located near the corresponding building structure, the situation that various characters are overlapped with each other is easy to occur, and the use in the actual construction process is affected.
In view of the above problems, referring to fig. 1, a schematic structural diagram of an electronic device 100 according to an embodiment of the invention is provided. The electronic device 100 comprises a memory 120, a processor 130 and a communication unit 110.
The memory 120, the processor 130, and the communication unit 110 are electrically connected to each other directly or indirectly to achieve data transmission or interaction. For example, the components may be electrically connected to each other via one or more communication buses or signal lines. The method for confirming the number position includes at least one software function module which may be stored in the memory 120 in the form of software or Firmware (Firmware) or solidified in an Operating System (OS) of the electronic device 100. Processor 130 is used to execute executable modules stored in memory 120.
The Memory 120 may be, but is not limited to, a Random Access Memory (RAM), a Read Only Memory (ROM), a Programmable Read-Only Memory (PROM), an Erasable Read-Only Memory (EPROM), an electrically Erasable Read-Only Memory (EEPROM), and the like. The memory 120 is used for storing a program, and the processor 130 executes the program after receiving the execution instruction. The communication unit 110 may be communicatively coupled to an external system.
The processor 130 may be an integrated circuit chip having signal processing capabilities. The Processor may be a general-purpose Processor, and includes a Central Processing Unit (CPU), a Network Processor (NP), and the like; but may also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware components. The various methods, steps, and logic blocks disclosed in the embodiments of the present application may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The embodiment of the method provides a method for avoiding the numbering position, and the method can be applied to the electronic equipment. Please refer to fig. 2, which is a flowchart illustrating a method for confirming a numbering position according to an embodiment of the present invention. The above method may be implemented by steps S101 to S105:
step S101, acquiring a drawing containing a member and a plurality of text boxes.
And step S102, acquiring a plurality of extension points of the member in the drawing.
And S103, determining the position of each numbering frame to be selected according to each extension point.
And step S104, determining whether a target number box without an intersection point with the plurality of text boxes exists. If yes, go to step S105.
In step S105, the position of the target number frame is set as the target number position.
The method comprises the steps of obtaining a drawing containing a component and a plurality of text boxes, and determining the positions of a plurality of number boxes to be selected of the component by determining a plurality of extension points of the component in the drawing. And subsequently, respectively judging whether the number frames to be selected and the text frames have no intersection points in the number frames to be selected so as to determine the position of the target number frame, namely the position of the target number. Therefore, when the construction drawing is generated, the target number frame which does not have the intersection point with other text frames is selected, and the position of the target number frame is used as the target position, so that the condition that the number is overlapped with other characters in the drawing can be avoided, and the use in the construction process cannot be influenced.
Meanwhile, compared with the method that after the construction drawing is automatically generated by software, the efficiency of manually searching, adjusting and checking the characters in each character overlapping area is higher.
For the convenience of subsequent understanding, since the component is in the drawing, when the position is expressed, the two-dimensional coordinate of the component in the drawing is said.
Continuing to refer to fig. 2, for example, to further ensure the clarity between the component and the labeled text in the drawing, it may be detected whether there is no intersection between the numbering box and the drawing number and the labeled line in the drawing. And if so, determining the number frame as a target number frame.
If there is no target number box having no intersection with any of the text boxes, step S106 may be executed, as shown in fig. 3, which is a second flowchart of the method for confirming the number position according to the embodiment of the present invention.
And S106, selecting one number frame from the number frames as a target number frame according to a preset rule, and taking the position of the target number frame as a target number position.
In the drawings, the placement positions of the components may be slightly different based on practical use considerations, that is, the directions of the components of the same type in the drawings are not consistent. Fig. 4 is a third flowchart illustrating a method for confirming a number position according to an embodiment of the present invention. As shown in fig. 4, a plurality of standard extension points of various standard components are preset in the electronic device, and the plurality of extension points of the components in step S102 can be obtained as follows:
step S201, identifying and obtaining the vertex characteristics of the component in the drawing.
And step S202, determining a target standard component corresponding to the component according to the vertex characteristics.
Step S203, determining a plurality of extension points of the member in the drawing according to the member, the target standard member and the plurality of standard extension points of the target standard member.
Illustratively, it is convenient to understand what is the same type of component in this method embodiment. Fig. 5 is a schematic structural diagram of a component and a corresponding standard component according to an embodiment of the present invention. In fig. 5, the left drawing is understood to be an F-like edge member in the drawing, and the right drawing is understood to be a target standard member corresponding to the F-like edge member, which is the position where the standard extension point is set in the standard member, namely r0 to r 9. The right drawing is also provided with a coordinate system of the standard component, so that the coordinates of the extension point can be determined subsequently based on the coordinate system in the drawing, the coordinate system of the standard component and the vertex correspondence.
For example, when a member in a drawing needs to generate a number, a fill area identifying the member may be detected. And obtaining a graph corresponding to the component according to the filling surface area, thereby obtaining the position of each vertex of the graph. I.e. the coordinates of the respective vertices of the member are obtained.
For example, the arrangement order of the vertices may be specified by a user, or may be arranged according to the order of obtaining the vertices.
For example, the type of the member may be determined based on the two-dimensional coordinates of the extracted plurality of vertices, the relative positional relationship between the respective vertices, and the like. E.g., an F-like edge member, etc. And determining the standard component corresponding to the component, namely the target standard component according to the type of the component.
For example, after the type of the component is identified, the order of the vertices of the component may be rearranged so as to directly correspond to the order of the vertices of the target standard component, thereby facilitating the subsequent determination of the coordinate transformation relationship.
Please refer to fig. 6, which is a fourth flowchart illustrating a method for confirming a numbering position according to an embodiment of the present invention. After the target standard component is determined, a plurality of extension points of the component may be determined based on the extension points set by the target standard component. Step S203 may be implemented as follows:
step S301, respectively determining the vertex corresponding relation between each vertex in the component and the corresponding vertex in the target standard component;
step S302, determining a coordinate conversion relation between the component and a target standard component according to the vertex corresponding relation;
and step S303, determining a plurality of extension points of the member in the drawing according to the coordinate conversion relation and the plurality of standard extension points.
For ease of understanding, the coordinate systems of the component and the target building block are different, i.e., the two-dimensional coordinates between corresponding points in the component and the target building block are not the same. The member is a member whose plurality of extension points on the original paper are determined by using the plurality of standard extension points of the target standard member.
Wherein the plurality of extension points of the member may be determined using a mapping relationship between the points and the points. For example, the mapping relationship between the points may be determined by means of coordinate conversion. It is also possible to preset the relative positional relationship between each standard extension point and its corresponding vertex, and determine the plurality of extension points of the member respectively according to the relative positional relationship.
Illustratively, after the type of the component is determined, the corresponding relationship between the component and the vertices of the target standard component is directly determined by rearranging the order of the vertices of the component so as to coincide with the order of the corresponding vertices of the target standard component.
For example, the correspondence between the vertices in the component and the target standard component may be stored in a key-value pair manner to facilitate determination of the subsequent coordinate transformation relationship.
There are many methods for determining the mapping relationship between the points by coordinate transformation, for example, please refer to fig. 7, which is a fifth flowchart of a method for determining the number position according to an embodiment of the present invention. Step S302 may be implemented in the following manner:
step S401, acquiring the component from the drawing to obtain a second component.
Step S401, according to the vertex corresponding relation, determining a second coordinate system of the second member, so that the direction of the second member is consistent with that of the target standard member under the second coordinate system.
Step S402, determining a coordinate transformation relation according to the coordinates of each vertex of the member on the drawing and the coordinates of each vertex of the second member under a second coordinate system.
Wherein the consistent direction characterizes the target standard component to be completely overlapped with the component through the zooming operation. It is understood that the lengths of the sides of the component and the target standard component are different, that is, the lengths of the sides of the target standard component are the lengths of the sides of the component after scaling according to a certain proportion.
Illustratively, in step S401, a member is obtained from a drawing sheet, resulting in a second member. It is understood that after the component is extracted, a second coordinate system of the component is determined. It is also understood that the second coordinate system is established for the component directly on the drawing sheet.
Wherein a second coordinate system is established for the member directly on the drawing. Reference may be made to fig. 8, which is a schematic diagram of a position of a component in multiple coordinate systems according to an embodiment of the present invention. Wherein the member is a figure formed by connecting lines between points (P0-P7). The external large coordinate system is a coordinate system carried by the drawing. The small coordinate system may be understood as the second coordinate system.
For the convenience of subsequent understanding, the coordinate system of the drawing is named as a whole coordinate system, and the second coordinate system is named as a local coordinate system.
For example, after the correspondence between the vertices of the component and the target standard component is obtained, the origin of coordinates in the local coordinate system may be determined, thereby determining how the second coordinate system should be set such that the locations of the vertices of the second component and the target standard component in the local coordinate system are corresponding.
For example, the coordinates of the vertices of the member in the global coordinate system may be converted into coordinates in the local coordinate system, that is, the coordinate transformation relationship between each point may be determined, by using a coordinate vector expression formula (a ═ b ═ x2+ y1y2) and a general expression formula (a ═ a | cos < a, b >) of the vector.
For example: please refer to fig. 8. The abscissa (nx3) and the ordinate (ny3) of the P3 point in the local coordinate system can be determined by the following formula:
wherein v1 is a vector of a coordinate origin and a vertex, and the coordinates are (vx1, vy 1). v1 is a vector in the positive x-direction and can be determined based on the vertex P1 and the origin of coordinates, which are (vx2, vy 2).
After the coordinates of each vertex in the local coordinate system of the member are determined, the position of the extension point of the member in the local coordinate system can be determined by the relative positional relationship of the standard extension point and the target standard member and the corresponding relationship of each vertex in the member and the target standard member.
Similarly, converting the points of the member in the local coordinate system to the points in the global coordinate system may also be performed in the manner described above.
When the length of each side of the member is not consistent with that of the target standard member, the relative position of the extension point of the member and the vertex thereof can be determined in the following manner.
May be determined directly from the length of the displacement between the standard extension point and its corresponding apex of the target standard component. For example, if the displacement length between the standard extension point and the vertex of the corresponding target standard member is 1, the displacement length between the extension point of the corresponding member and the vertex thereof is also 1.
It may also be determined by the scaling of the component to the target annotation component and the length of the displacement between the canonical extension point and its corresponding vertex of the target canonical component. For example, if the member is reduced by 0.5 from the target standard member and the displacement length between the standard extension point and the vertex of the corresponding target standard member is 1, the displacement length between the extension point of the corresponding member and the vertex thereof is also 0.5.
For example, the coordinate transformation relationship between each point can also be determined by the included angle between the global coordinate system and the local coordinate system. That is, the coordinates of the component in the local coordinate system can be determined based on the sine value, the cosine value, the coordinates of each vertex and the coordinate origin by calculating the sine value and the cosine value of the included angle between the positive direction of the x axis of the local coordinate system and the positive direction of the x axis in the global coordinate system.
Similarly, after obtaining the local coordinates of the extended point of the member in the local coordinate system, the global coordinates of the plurality of extended points of the member in the global coordinates may be determined based on the above coordinate conversion relationship.
After the plurality of extension points are obtained, a plurality of number frames to be selected can be determined based on the extension points. Please refer to fig. 8, which is a sixth flowchart illustrating a method for confirming a numbering position according to an embodiment of the present invention. The electronic device prestores a corresponding relation between each standard extension point in each standard component and a vertex of the standard component. Step S103 may determine the position of the number frame in the following manner:
step S501, determining a vertex corresponding to each extension point in the member according to vertexes corresponding to the extension points, the standard extension points and the standard extension points respectively.
And step S502, obtaining a plurality of numbered marking lines of the component according to each extension point and the corresponding vertex.
Step S503, determining the position of each number frame to be selected according to the number marking line.
Illustratively, the vertex corresponding to each extension point in the member is determined according to the vertexes corresponding to the extension points, the standard extension points and the standard extension points respectively. And then obtaining a plurality of first connecting lines between the extension points and the vertexes according to each extension point and the corresponding vertex. The situation that the situation of viewing the drawing is influenced by the first connecting line between the extended point and the vertex generated in the drawing due to the fact that the extended point and the vertex are not corresponding is prevented.
For example, after obtaining a plurality of first links, a second link is determined, so as to obtain a numbered marking line composed of the first links and the second links. In the drawing, the second connecting lines are horizontal lines led out from the extending points, and an upper included angle between the first connecting lines and the second connecting lines is an obtuse angle. Of course, the determination of the second connection line may be modified accordingly according to the requirements in the actual design process.
For example, after the numbered marking line is determined, based on the second connection line, the position of each numbered frame to be selected may be determined by determining, according to the actual application requirements, the position of the numbered frame above or below the second connection line and the relative position of the numbered frame with respect to the second connection line.
Because there are a plurality of number frames to be selected, there may be a condition that there is no intersection between the number frames and the text frames. Please refer to fig. 9, which is a seventh flowchart illustrating a method for confirming a numbering position according to an embodiment of the present invention. Step S104 and step S105 can be implemented as follows:
step S601 arranges the plurality of numbered frames in a predetermined order.
And step S602, sequentially determining whether a numbered frame without an intersection point with a plurality of text frames exists according to a preset sequence. If yes, go to step S603. If not, go to step S106.
And step S603, taking the number frame which appears for the first time and has no intersection point with the plurality of text frames as a target number frame, and taking the position of the target number frame as a target number position.
For example, the sequence between each number frame to be selected may be arranged according to an automatically determined time sequence of the number frame to be selected, or may be arranged according to a sequence specified by a user. For example, the elements may be arranged in the size of the abscissa or ordinate of a designated vertex of a number frame, or may be arranged in the clockwise direction or the counterclockwise direction with the element as the center.
Fig. 11 is a functional block diagram of an apparatus 200 for confirming a number position according to an embodiment of the present invention, the basic principle and the technical effect of the apparatus are the same as those of the corresponding method embodiments, and for a brief description, the corresponding contents in the method embodiments may be referred to for the parts not mentioned in this embodiment. As shown in fig. 11, the apparatus includes an acquisition module 210, a conversion module 220, and a detection module 230.
The obtaining module 210 is configured to obtain a drawing including a component and a plurality of text boxes.
And a conversion module 220 for acquiring a plurality of extension points of the member in the drawing.
The detecting module 230 is configured to determine a position of each number frame to be selected according to each extension point. Determining whether a target number box without an intersection point with the plurality of text boxes exists; and if so, taking the position of the target number frame as the target number position.
The detecting module 230 is further configured to, if there is no target numbering frame that has no intersection with the plurality of text frames, select one numbering frame from the plurality of numbering frames as a target numbering frame according to a predetermined rule, and use a position where the target numbering frame is located as a target numbering position.
The embodiment of the present invention further provides a storage medium, where a computer program is stored on the storage medium, and the computer program is executed by a processor to perform the steps of the above method embodiments.
To sum up, the embodiment of the invention provides a method and a device for confirming a numbering position, an electronic device and a storage medium, when a construction drawing is generated, a target numbering frame which has no intersection point with other text frames is selected, and the position of the target numbering frame is used as a target position, so that the condition that the numbering in the drawing is overlapped with other characters can be avoided, the use in the construction process cannot be influenced, and the use convenience is improved.
In the embodiments provided by the present invention, it should be understood that the disclosed apparatus and method may be implemented in other manners. The apparatus embodiments described above are merely illustrative, and for example, the flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, 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.
In addition, the functional modules in the embodiments of the present invention may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
The functions, if implemented in the form of software functional modules and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk, and various media capable of storing program codes.
The above is only a preferred embodiment of the present invention, and is not intended to limit the present invention, and various modifications and changes will occur to those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
The above description is only for the specific embodiments of the present invention, but the scope of the present invention is not limited thereto, and any changes or substitutions that can be easily conceived by those skilled in the art within the technical scope of the present invention are included in the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.
Claims (10)
1. A method for confirming a numbering position is applied to an electronic device, and the method comprises the following steps:
acquiring a drawing containing a component and a plurality of text boxes;
acquiring a plurality of extension points of the member in the drawing;
determining the position of each numbering frame to be selected according to each extension point;
determining whether a target number box having no intersection with the plurality of text boxes exists;
and if so, taking the position of the target number frame as the target number position.
2. The method according to claim 1, wherein the electronic device presets a plurality of standard extension points of various standard components, and the step of acquiring the plurality of extension points of the components in the drawing comprises:
identifying and obtaining the vertex feature of the component in the drawing;
determining a target standard component corresponding to the component according to the vertex feature;
and determining a plurality of extension points of the component in the drawing according to the component, the target standard component and a plurality of standard extension points of the target standard component.
3. The method of claim 2, wherein the step of determining a plurality of extension points of the component in the drawing based on the component, the target standard component, and a plurality of standard extension points of the target standard component comprises:
respectively determining vertex corresponding relations between all vertexes in the component and corresponding vertexes in the target standard component;
determining a coordinate conversion relation between the component and the target standard component according to the vertex corresponding relation;
and determining a plurality of extension points of the member in the drawing according to the coordinate conversion relation and the plurality of standard extension points.
4. The method of claim 2, wherein the electronic device prestores a correspondence between each standard extension point in each standard component and a vertex of the standard component; the step of determining the position of each number frame to be selected according to each extension point comprises the following steps:
determining a vertex corresponding to each extension point in the member according to vertexes corresponding to the extension points, the standard extension points and the standard extension points respectively;
obtaining a plurality of serial number marking lines of the component according to each extension point and the corresponding vertex;
and determining the position of each numbering frame to be selected according to the numbering marking line.
5. The method of claim 1, further comprising:
if not, according to a preset rule, one numbering frame is selected from the multiple numbering frames as a target numbering frame, and the position of the target numbering frame is used as a target numbering position.
6. The method of claim 1, wherein the determining whether there is a target number box that has no intersection with the plurality of text boxes; if yes, the step of taking the position of the target number frame as the position of the target number comprises the following steps:
arranging the number frames according to a preset sequence;
determining whether a number frame without an intersection point with the plurality of text frames exists in sequence according to the preset sequence;
if so, taking the number frame which appears for the first time and has no intersection point with the plurality of text frames as the target number frame, and taking the position of the target number frame as the target number position.
7. The method of claim 3, wherein said step of determining a coordinate transformation relationship between said component and said target standard component based on said vertex correspondences comprises:
acquiring a component from the drawing to obtain a second component;
determining a second coordinate system of the second component according to the vertex corresponding relation, so that the second component is consistent with the target standard component in direction under the second coordinate system; wherein the orientation agreement characterizes the target building element as being fully coincident with the second building element by a zoom operation;
and determining the coordinate conversion relation according to the coordinates of each vertex of the member on the drawing and the coordinates of each vertex of the second member under the second coordinate system.
8. An apparatus for confirming a numbered position, the apparatus comprising:
the acquisition module is used for acquiring a drawing comprising a component and a plurality of text boxes;
the conversion module is used for acquiring a plurality of extension points of the component in the drawing;
the detection module is used for determining the position of each serial number frame to be selected according to each extension point; determining whether a target number box having no intersection with the plurality of text boxes exists; and if so, taking the position of the target number frame as a target number position.
9. An electronic device, comprising: memory, processor and program stored on the memory and executable on the processor, which when executed by the processor implements the method of any one of claims 1 to 7.
10. A storage medium, having stored thereon a computer program which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210818961.8A CN115131813B (en) | 2022-07-12 | 2022-07-12 | Method and device for confirming numbering position, electronic equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210818961.8A CN115131813B (en) | 2022-07-12 | 2022-07-12 | Method and device for confirming numbering position, electronic equipment and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN115131813A true CN115131813A (en) | 2022-09-30 |
CN115131813B CN115131813B (en) | 2023-04-07 |
Family
ID=83384126
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210818961.8A Active CN115131813B (en) | 2022-07-12 | 2022-07-12 | Method and device for confirming numbering position, electronic equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115131813B (en) |
Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5003601A (en) * | 1984-05-25 | 1991-03-26 | Sony Corporation | Speech recognition method and apparatus thereof |
US20080240614A1 (en) * | 2007-03-30 | 2008-10-02 | Garcia Jason A | Traceability marks |
CN108121863A (en) * | 2017-12-13 | 2018-06-05 | 机械工业第六设计研究院有限公司 | Creation method, device, equipment and the computer readable storage medium of pipeline label |
CN109684947A (en) * | 2018-12-11 | 2019-04-26 | 广州景骐科技有限公司 | Mark quality control method, device, computer equipment and storage medium |
CN110889160A (en) * | 2019-12-09 | 2020-03-17 | 中冶南方工程技术有限公司 | Municipal pipeline construction method based on BIM technology |
US20200125776A1 (en) * | 2017-08-09 | 2020-04-23 | China Construction Steel Structure Corp. Ltd. | Collision check data processing method and apparatus, electronic device, and storage medium |
CN112784350A (en) * | 2021-03-17 | 2021-05-11 | 杭州品茗安控信息技术股份有限公司 | Construction drawing label generation method, device and system and readable storage medium |
CN113553453A (en) * | 2021-07-20 | 2021-10-26 | 广联达科技股份有限公司 | Two-dimensional drawing marking method and device and electronic equipment |
CN114565703A (en) * | 2022-03-04 | 2022-05-31 | 广联达科技股份有限公司 | Method, device and equipment for adjusting centralized labeling and readable storage medium |
-
2022
- 2022-07-12 CN CN202210818961.8A patent/CN115131813B/en active Active
Patent Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5003601A (en) * | 1984-05-25 | 1991-03-26 | Sony Corporation | Speech recognition method and apparatus thereof |
US20080240614A1 (en) * | 2007-03-30 | 2008-10-02 | Garcia Jason A | Traceability marks |
US20200125776A1 (en) * | 2017-08-09 | 2020-04-23 | China Construction Steel Structure Corp. Ltd. | Collision check data processing method and apparatus, electronic device, and storage medium |
CN108121863A (en) * | 2017-12-13 | 2018-06-05 | 机械工业第六设计研究院有限公司 | Creation method, device, equipment and the computer readable storage medium of pipeline label |
CN109684947A (en) * | 2018-12-11 | 2019-04-26 | 广州景骐科技有限公司 | Mark quality control method, device, computer equipment and storage medium |
CN110889160A (en) * | 2019-12-09 | 2020-03-17 | 中冶南方工程技术有限公司 | Municipal pipeline construction method based on BIM technology |
CN112784350A (en) * | 2021-03-17 | 2021-05-11 | 杭州品茗安控信息技术股份有限公司 | Construction drawing label generation method, device and system and readable storage medium |
CN113553453A (en) * | 2021-07-20 | 2021-10-26 | 广联达科技股份有限公司 | Two-dimensional drawing marking method and device and electronic equipment |
CN114565703A (en) * | 2022-03-04 | 2022-05-31 | 广联达科技股份有限公司 | Method, device and equipment for adjusting centralized labeling and readable storage medium |
Non-Patent Citations (3)
Title |
---|
FORRESTER COLE 等: "Where Do People Draw Lines?", 《ACM》 * |
方长建 等: "建筑工程结构设计BIM数据交换SIM标准", 《土木工程与管理学报》 * |
龙小裕 等: "模具二维装配图件号自动标注算法研究与系统开发", 《锻压技术》 * |
Also Published As
Publication number | Publication date |
---|---|
CN115131813B (en) | 2023-04-07 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11157766B2 (en) | Method, apparatus, device and medium for calibrating pose relationship between vehicle sensor and vehicle | |
US10880541B2 (en) | Stereo correspondence and depth sensors | |
US9135710B2 (en) | Depth map stereo correspondence techniques | |
US20100278418A1 (en) | System and method for measuring errors of workpieces | |
CN113077548B (en) | Collision detection method, device, equipment and storage medium for object | |
JP5618728B2 (en) | Reinforcement information acquisition method | |
CN113759348B (en) | Radar calibration method, device, equipment and storage medium | |
CN115131813B (en) | Method and device for confirming numbering position, electronic equipment and storage medium | |
JP7507600B2 (en) | Meter meter/installed equipment information management system, meter meter/installed equipment information management method, and meter meter/installed equipment information management program | |
CN113872798A (en) | Method and device for constructing space network topological graph, storage medium and electronic equipment | |
CN114359204A (en) | Point cloud hole detection method and device and electronic equipment | |
JP5586414B2 (en) | Bar arrangement information acquisition apparatus and bar arrangement information acquisition method | |
US12062206B2 (en) | Methods of estimating pose graph and transformation matrix between cameras by recognizing markers on the ground in panorama images | |
KR102718576B1 (en) | Method for detecting collision with objects, apparatus, electronic device, storage medium and computer program | |
CN113312440B (en) | Map construction method and device, electronic equipment and computer readable storage medium | |
CN115861561B (en) | Contour line generation method and device based on semantic constraint | |
CN113536025B (en) | Method and device for determining signboard orientation of interest point, electronic equipment and storage medium | |
CN117593378B (en) | Device and method for calibrating internal parameters of vehicle-mounted camera module | |
EP4102466A1 (en) | Collision detection method and apparatus for objects, and device and storage medium | |
CN118521463A (en) | Method, device, equipment and storage medium for converting two-dimensional coordinates into three-dimensional coordinates | |
CN118583081A (en) | Roundness deviation detection method, device, equipment and medium for cylindrical ship structural member | |
CN114255171A (en) | Method and device for calculating conversion relation of similar legends | |
CN114565673A (en) | Object determination method, device, equipment, storage medium and program product | |
CN115424201A (en) | Region monitoring method, device, equipment and storage medium | |
CN115062388A (en) | Method and device for determining component direction and computer readable storage medium |
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 |