Method, device, electronic device and storage medium for identifying wall columns in architectural drawings
By automatically identifying the contours of wall columns in architectural drawings, the problems of high labor consumption and poor work quality caused by relying on manual reading of drawings in the prior art are solved, and an efficient automated identification process is achieved.
Patent Information
- Application Number
- CN202111617582.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-27
- Publication Date
- 2024-11-05
- Estimated Expiration
- 2041-12-27
AI Technical Summary
In the prior art, CAD software cannot analyze and process building drawing information in a timely manner, resulting in relying on manual reading of drawings, which consumes a lot of manpower and cannot be fully guaranteed.
By obtaining the set of target line elements of the architectural drawings, the closed polygon set is determined, and the wall column outline is identified according to the feature parameters meeting specific conditions, so as to achieve automated recognition.
The contours of wall columns in building drawings can be determined without human participation, saving manpower, improving identification efficiency, and ensuring work quality.
Smart Images

Figure CN114444168B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of building object recognition, and in particular to a method, device, electronic device and storage medium for recognizing wall columns in building drawings. Background Art
[0002] In the construction industry, CAD (Computer Aided Design) software has been used more and more. After designers use CAD software to design the details of the plan, construction workers can carry out construction according to CAD drawings, which greatly helps the design work of engineers and the construction workers.
[0003] The various designs in CAD drawings need to fully comply with the specifications of the construction industry. Therefore, after the designers complete the CAD drawing design, they need to be strictly reviewed by special reviewers. However, the review work after the architectural drawing design still relies on manual reading. CAD software cannot analyze and process the drawing information in a timely manner, which requires huge manpower and the work quality cannot be fully guaranteed. Summary of the invention
[0004] The present application provides a method, device, electronic device and storage medium for identifying wall columns in architectural drawings, so as to solve the problem in the prior art that CAD software cannot timely analyze and process the drawing information because of reliance on manual reading of drawings, which requires huge manpower and the work quality cannot be fully guaranteed.
[0005] In a first aspect, an embodiment of the present application provides a method for identifying wall columns in a building drawing, comprising:
[0006] Obtaining the architectural drawings to be identified;
[0007] Determine a target line primitive set in any first layer of the architectural drawing, the first layer being a layer including line primitives;
[0008] Determine a closed polygon set in the first layer according to the target line primitive set;
[0009] If the characteristic parameters of the closed polygon set meet the first recognition condition in the first layer, the closed polygon in the first layer is determined to be a wall column outline.
[0010] Optionally, determining the set of line graphic elements in the first layer of the architectural drawing includes:
[0011] Get the layer name of the first layer;
[0012] Determine that the line primitive including the layer name in the primitive information is the target line primitive;
[0013] The target line primitive set is determined as the target line primitive set.
[0014] Optionally, determining the closed polygon set in the first layer according to the target line primitive set includes:
[0015] Obtaining the starting point coordinates and the ending point coordinates of each target line primitive in the target line primitive set;
[0016] According to the starting point coordinates and the ending point coordinates, the closed polygons in the first layer are determined to obtain the closed polygon set, wherein, for any target line primitive in the closed polygon, there is a target line primitive that coincides with its starting point coordinates, and there is another target line primitive that coincides with its ending point coordinates.
[0017] Optionally, before determining the closed polygon set in the first layer according to the target line primitive set, the method further includes:
[0018] Calculating the line segment length of each target line primitive in the target line primitive set;
[0019] If the length of the line segment does not meet the preset value of the length of the wall column, it is determined that the first layer does not include the wall column;
[0020] If the line segment length meets the preset value of the wall column length, the step of determining the closed polygon set in the first layer according to the target line primitive set is performed.
[0021] Optionally, the characteristic parameters of the closed polygon set include a first number of closed polygons in the closed polygon set, a second number of target line primitives in the closed polygon set, and a first area of each closed polygon in the closed polygon set;
[0022] The first recognition condition in the first layer includes:
[0023] The first number is greater than a first preset value, the ratio of the second number to the third number of target line primitives in the first layer is greater than or equal to the second preset value, the number of the first area greater than the first preset area is less than the third preset value, and the number of the first area less than the second preset area is less than a fourth preset value.
[0024] Optionally, also include:
[0025] Determine a target fill primitive set in any second layer of the architectural drawing, where the second layer is a layer including fill primitives;
[0026] Determine a second area of each target filling primitive in the target filling primitive set;
[0027] If the second area satisfies the second identification condition in the second layer, determining that the filling element in the second layer is a wall column filling;
[0028] The level of the wall column outline is determined according to the wall column filling and the wall column outline.
[0029] Optionally, determining the level of the wall column outline according to the wall column filling and the wall column outline includes:
[0030] Determine that the wall column outlines whose distances between the wall column outlines are less than a preset overlap threshold are wall columns at the same level;
[0031] Determine the filling ratio of the wall column within a preset distance of each wall column outline;
[0032] If the filling ratio is less than a preset filling threshold, determining that the wall column outline is a lower layer wall column;
[0033] If the filling ratio is greater than or equal to a preset filling threshold, it is determined that the wall column outline is an upper wall column.
[0034] In a second aspect, an embodiment of the present application provides a device for identifying wall columns in a building drawing, comprising:
[0035] An acquisition module, used for acquiring the architectural drawings to be identified;
[0036] A first determination module is used to determine a target line primitive set in any first layer of the architectural drawing, where the first layer is a layer including line primitives;
[0037] A second determination module, configured to determine a closed polygon set in the first layer according to the target line primitive set;
[0038] The recognition module is used to determine that the closed polygon in the first layer is a wall column outline if the characteristic parameters of the closed polygon set meet the first recognition condition in the first layer.
[0039] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other via the communication bus;
[0040] The memory is used to store computer programs;
[0041] The processor is used to execute the program stored in the memory to implement the method for identifying wall columns in architectural drawings described in the first aspect.
[0042] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the method for identifying wall columns in architectural drawings described in the first aspect.
[0043] The above technical solution provided by the embodiment of the present application has the following advantages over the prior art: the method provided by the embodiment of the present application obtains the architectural drawing to be identified; determines the target line primitive set in any first layer of the architectural drawing, the first layer being a layer including line primitives; determines the closed polygon set in the first layer according to the target line primitive set; if the characteristic parameters of the closed polygon set meet the first recognition condition in the first layer, determines that the closed polygon in the first layer is the outline of the wall column. In this way, after obtaining the architectural drawing to be identified, the closed polygon set in the first layer can be determined according to the line primitive set in the architectural drawing, thereby determining the outline of the wall column in the first layer according to the first recognition condition. In this recognition process, the outline of the wall column in the architectural drawing can be determined without human participation, which saves manpower and avoids the problem of low recognition efficiency caused by human recognition. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.
[0045] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0046] Figure 1 This is an application scenario diagram of a method for identifying wall columns in architectural drawings provided in an embodiment of the present application;
[0047] Figure 2 A flow chart of a method for identifying wall columns in architectural drawings provided in one embodiment of the present application;
[0048] Figure 3 A flowchart of a method for identifying wall columns in architectural drawings provided by another embodiment of the present application;
[0049] Figure 4 A structural diagram of a device for identifying wall columns in architectural drawings provided in one embodiment of the present application;
[0050] Figure 5 A structural diagram of an electronic device provided in one embodiment of the present application. DETAILED DESCRIPTION
[0051] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.
[0052] According to an embodiment of the present application, a method for identifying wall columns in a building drawing is provided. Optionally, in the embodiment of the present application, the method for identifying wall columns in a building drawing can be applied to Figure 1 In the hardware environment composed of the terminal 101 and the server 102 shown in FIG. Figure 1 As shown, the server 102 is connected to the terminal 101 via a network, and can be used to provide services (such as application services, etc.) for the terminal or a client installed on the terminal. A database can be set on the server or independently of the server to provide data storage services for the server 102. The above-mentioned network includes but is not limited to: a wide area network, a metropolitan area network or a local area network, and the terminal 101 is not limited to a PC, a mobile phone, a tablet computer, etc.
[0053] The method for identifying wall columns in the architectural drawings of the embodiment of the present application can be executed by the server 102, or by the terminal 101, or by both the server 102 and the terminal 101. The terminal 101 executes the method for identifying wall columns in the architectural drawings of the embodiment of the present application, or the client installed thereon.
[0054] Taking the method for identifying wall columns in the architectural drawings of the present application as an example, Figure 2 is a flow chart of an optional method for identifying wall columns in architectural drawings according to an embodiment of the present application, such as Figure 2 As shown, the process of the method may include the following steps:
[0055] Step 201: Obtain a building drawing to be identified.
[0056] In some embodiments, the architectural drawing to be identified may be uploaded to the terminal after the designer has completed the design and when the architectural drawing needs to be identified; or, it may be obtained from the database when the relevant personnel identify the architectural drawing. The database stores multiple architectural drawings to be identified, and the relevant personnel can select one of the architectural drawings to be identified for identification according to the drawing name of the architectural drawing to be identified.
[0057] Exemplarily, the architectural drawings to be identified may be, but are not limited to, drawings of projects such as airports, railway stations, bus stations, office buildings, residential buildings, hospitals, museums, tourist attractions, churches, schools, parks, and the like.
[0058] Step 202: Determine a target line primitive set in any first layer of the architectural drawing, where the first layer is a layer including line primitives.
[0059] In some embodiments, when designing architectural drawings, for ease of management and drawing, they are often designed in layers, with different types of primitives set in each layer. Based on this, after obtaining the architectural drawings to be identified, the first layer including line primitives can be determined according to the type of primitives in the layer, and then the target line primitive set in each first layer can be determined.
[0060] There are many types of graphic elements, such as line graphic elements, fill graphic elements, and annotation graphic sources.
[0061] In an optional embodiment, determining a set of line primitives in a first layer of the architectural drawing includes:
[0062] The layer name of the first layer is obtained; the line primitive including the layer name in the primitive information is determined to be the target line primitive; and the set of the target line primitives is determined to be the target line primitive set.
[0063] In some embodiments, when designing architectural drawings, layer names are often reset for different layers to distinguish between the layers. When drawing primitives in each layer, the layer name of the layer in which it is located is carried. Therefore, according to the layer name of the first layer, the line primitive including the layer name can be determined from the primitive information of the architectural drawing and used as the target line primitive.
[0064] Step 203: Determine a closed polygon set in the first layer according to the target line primitive set.
[0065] In some embodiments, since the graphic elements in the first layer include line graphic elements, when drawing architectural drawings, the drawing of wall columns is often in the form of closed polygons, see Figure 3 For example, the closed polygon may be a rectangle, an "L"-shaped figure or other closed shapes. Therefore, after determining the target line primitive set in the first layer, the closed polygon therein may be determined according to the target line primitive set in the first layer.
[0066] Specifically, determining the closed polygon set in the first layer according to the target line primitive set includes:
[0067] The starting point coordinates and the ending point coordinates of each target line primitive in the target line primitive set are obtained; according to the starting point coordinates and the ending point coordinates, a closed polygon in the first layer is determined to obtain the closed polygon set, wherein, for any target line primitive in the closed polygon, there is a target line primitive that coincides with its starting point coordinates, and there is another target line primitive that coincides with its ending point coordinates.
[0068] In some embodiments, since the first layer includes a target line primitive set, in the process of drawing architectural drawings, the outline of the wall column is often obtained by drawing the line primitives into a closed polygon. Therefore, the starting point coordinates and the end point coordinates of each target line primitive in the target line primitive set can be determined first, and then based on the starting point coordinates and the end point coordinates of each target line primitive, it is determined whether multiple line primitives constitute a closed polygon. Usually, in a closed polygon, there is a target line primitive whose starting point coordinates coincide with any target line primitive, and there is another target line primitive whose end point coordinates coincide with any target line primitive.
[0069] In an optional embodiment, before determining the closed polygon set in the first layer according to the target line primitive set, the method includes:
[0070] Calculate the line segment length of each target line primitive in the target line primitive set; if the line segment length does not meet the preset value of the wall column length, determine that the first layer does not include the wall column; if the line segment length meets the preset value of the wall column length, execute the method of determining the closed polygon set in the first layer based on the target line primitive set.
[0071] In some embodiments, since wall columns play an important role in buildings, when designing architectural drawings, the line segment length of the line graphics elements included in the wall column outline will be longer. Therefore, it can be determined whether the first layer includes wall columns by judging whether the line segment length meets the preset value of the wall column length.
[0072] Step 204: If the characteristic parameters of the closed polygon set meet the first recognition condition in the first layer, determine that the closed polygon in the first layer is a wall column outline.
[0073] In some embodiments, in the architectural drawings, not all closed polygons are closed polygons corresponding to wall columns. For example, the design of the balcony in the architectural drawings also exists in the form of closed polygons. Therefore, it is necessary to screen the closed polygon set determined in the first layer to determine that the closed polygon in the first layer whose characteristic parameters of the closed polygon set meet the first recognition condition is the outline of the wall column.
[0074] Specifically, the characteristic parameters of the closed polygon set include a first number of closed polygons in the closed polygon set, a second number of target line primitives in the closed polygon set, and a first area of each closed polygon in the closed polygon set;
[0075] The first recognition condition in the first layer includes: the first number is greater than a first preset value, the ratio of the second number to the third number of target line primitives in the first layer is greater than or equal to a second preset value, the number of the first area greater than the first preset area is less than a third preset value, and the number of the first area less than the second preset area is less than a fourth preset value.
[0076] In an optional embodiment, the method further includes: determining a target fill primitive set in any second layer of the architectural drawing, the second layer being a layer including fill primitives; determining a second area of each target fill primitive in the target fill primitive set; determining that the fill primitive in the second layer is a wall column fill if the second area satisfies a second identification condition in the second layer; and determining the level at which the wall column outline is located based on the wall column fill and the wall column outline.
[0077] In some embodiments, in addition to the outline of the wall column, the wall column designed in the architectural drawing often has filled content (such as fill color or graphics) in the wall column to distinguish the wall column from other items and facilitate user viewing. The filled content often exists in the form of fill primitives. Based on this, the wall column fill in each second layer can be determined by determining the target fill primitive set in the second layer.
[0078] Specifically, whether the filling primitive in the second layer is a wall column filling can be determined by judging whether the second area of each target filling primitive satisfies the second recognition condition in the second layer.
[0079] After obtaining the second area of each target filling primitive, a fourth quantity of the second area in the second layer may be counted.
[0080] Furthermore, the second recognition condition in the second layer includes: the ratio of the number of target filling primitives in the second layer whose second area is greater than the second preset area value to the fourth number is less than a fifth preset value, and the ratio of the number of target filling primitives whose second area is less than the third preset area value to the fourth number is less than a sixth preset value. The third preset area value is less than the second preset area value.
[0081] The second layer is a layer including fill primitives. Since the fill primitives are filled in the wall column outline, the first area of the wall column outline within the preset range of each fill primitive can be used as the second area of the fill primitive.
[0082] Further, determining the level of the wall column outline according to the wall column filling and the wall column outline includes:
[0083] Determine that the wall column outlines whose distances are less than a preset overlap threshold are wall columns of the same level; determine the filling ratio of the wall columns within the preset distance of each wall column outline; if the filling ratio is less than the preset filling threshold, determine that the wall column outline is a lower-level wall column; if the filling ratio is greater than or equal to the preset filling threshold, determine that the wall column outline is an upper-level wall column.
[0084] In some embodiments, the architectural drawings are usually two-dimensional drawings. When the building has multiple layers, the upper layer filling content usually covers the lower layer filling content, so that the lower layer filling content cannot be fully displayed. Based on this, the layer where the wall column outline is located can be determined by the distance between the wall column outlines and the filling ratio of the wall column filling.
[0085] The method for identifying wall columns in architectural drawings of the present invention is to select filling graphics elements that meet the wall column filling characteristics from all filling graphics elements layer by layer; locate line segment graphics elements that meet the wall column line segment characteristics from all line segment lists layer by layer, and splice them into the wall column outline; distinguish the upper and lower wall columns according to the filling graphics elements and the wall column outline. Usually, there are two types of wall columns, one is the standard layer wall column, the upper and lower wall columns are of the same type, and the other is the conversion layer, which is mostly used in commercial and residential buildings. In general, the lower wall columns are large and the upper wall columns are small. Based on this, the specific identification process includes:
[0086] 1. Identify wall column filling;
[0087] 1. Extract the layer list from all fill primitives;
[0088] 2. Loop through each layer in the layer list and filter the fill primitives in the current layer according to the layer name attribute of the primitive;
[0089] 3. Count the number of primitives with an area greater than 4 square meters, and calculate the ratio of this number to the total number of filling primitives in the current layer. If it is greater than a certain ratio, it is determined not to be wall column filling;
[0090] 4. Count the number of primitives with an area less than 0.12 square meters, and calculate the ratio of this number to the total number of filling primitives in the current layer. If it is greater than a certain ratio, it is determined not to be wall column filling;
[0091] 5. If the above checks are passed, it is determined to be a wall column filling. The wall column filling identified here is used to distinguish the upper and lower wall columns later.
[0092] 2. Identify the list of wall column outlines;
[0093] 1. Extract the layer list from all line segment primitives;
[0094] 2. Loop through each layer in the layer list and filter the line segment primitives in the current layer according to the layer name attribute of the primitive;
[0095] 3. Calculate the length of the line segment based on the coordinates of the starting and ending points of the line segment;
[0096] 4. Count the number of line segments with lengths less than 399, and calculate the ratio of this number to the total number of line segment primitives in the current layer. If it is greater than a certain ratio, continue processing the next layer;
[0097] 5. Count the number of line segments a with a length greater than 1000 and the number of line segments b with a length greater than 7000, and calculate the ratio of b to a. If it is greater than a certain ratio, continue processing the next layer;
[0098] 6. Connect the coordinates of the line segment primitives end to end and splice them into closed polygons and non-closed polylines;
[0099] 7. Determine the number of closed polygons. If it is less than a certain number, continue to process the next layer;
[0100] 8. Calculate the ratio of the number of line segments involved in forming a closed polygon to the total number of line segments in the current layer. If the ratio is less than a certain ratio, continue processing the next layer.
[0101] 9. Count the number of closed polygons with an area greater than 4 square meters, and calculate the ratio of this number to the total number of closed polygons. If it is greater than a certain ratio, it is determined not to be wall column filling;
[0102] 10. Count the number of closed polygons with an area less than 0.12 square meters, and calculate the ratio of this number to the total number of closed polygons. If it is greater than a certain ratio, it is determined not to be wall column filling;
[0103] 11. If the above inspection is passed, it is determined to be a wall column profile.
[0104] 3. Distinguish between upper and lower wall columns (in the case of transfer layer wall columns);
[0105] The upper wall columns and lower wall columns are mainly distinguished by filling; if both the lower wall column line and the upper wall column line are filled, the filling style SOLID is used as the upper wall column. The detailed process is as follows:
[0106] 1. For each wall column polygon, find nearby polygons,
[0107] 1.1. If there are no other polygons nearby,
[0108] 1.2, or when the nearby polygons completely overlap (less than the set overlap threshold),
[0109] 1.3. Consider this polygon as belonging to both the upper and lower layers of the wall column
[0110] 2. Then determine the filling near the wall column polygon,
[0111] 2.1. If there is no filling, it is determined to be a lower wall column;
[0112] 2.2. If there is filling and it is completely filled (the proportion is greater than the set threshold), it is determined to be an upper wall column.
[0113] 2.3. If there is filling and the filling ratio is less than the set threshold, it is judged as the lower wall column.
[0114] The end result is a list of wall stud profiles separated into two lists of wall stud profiles: upper level wall stud profiles and lower level wall stud profiles.
[0115] Based on the same concept, an embodiment of the present application provides a device for identifying wall columns in a building drawing. The specific implementation of the device can be found in the description of the method embodiment part, and the repeated parts will not be repeated. Figure 4 As shown, the device mainly includes:
[0116] An acquisition module 401 is used to acquire a building drawing to be identified;
[0117] A first determination module 402 is used to determine a target line primitive set in any first layer of the architectural drawing, where the first layer is a layer including line primitives;
[0118] A second determination module 403 is used to determine a closed polygon set in the first layer according to the target line primitive set;
[0119] The identification module 404 is configured to determine that the closed polygon in the first layer is a wall column outline if the characteristic parameters of the closed polygon set meet the first identification condition in the first layer.
[0120] Based on the same concept, an electronic device is also provided in the embodiment of the present application, such as Figure 5 As shown, the electronic device mainly includes: a processor 501, a memory 502 and a communication bus 503, wherein the processor 501 and the memory 502 communicate with each other through the communication bus 503. The memory 502 stores a program executable by the processor 501, and the processor 501 executes the program stored in the memory 502 to implement the following steps:
[0121] Obtaining the architectural drawings to be identified;
[0122] Determine a target line primitive set in any first layer of the architectural drawing, the first layer being a layer including line primitives;
[0123] Determine a closed polygon set in the first layer according to the target line primitive set;
[0124] If the characteristic parameters of the closed polygon set meet the first recognition condition in the first layer, the closed polygon in the first layer is determined to be a wall column outline.
[0125] The communication bus 503 mentioned in the above electronic device can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The communication bus 503 can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 5 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.
[0126] The memory 502 may include a random access memory (RAM) or a non-volatile memory, such as at least one disk memory. Alternatively, the memory may also be at least one storage device located away from the processor 501 .
[0127] The above-mentioned processor 501 can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc., and can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components.
[0128] In another embodiment of the present application, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program is run on a computer, the computer executes the method for identifying wall columns in architectural drawings described in the above embodiments.
[0129] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer instruction is loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network or other programmable device. The computer instruction can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instruction is transmitted from a website site, a computer, a server or a data center by wired (such as coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (such as infrared, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server, a data center, etc. that contains one or more available media integration. The available medium can be a magnetic medium (such as a floppy disk, a hard disk, a magnetic tape, etc.), an optical medium (such as a DVD) or a semiconductor medium (such as a solid-state hard disk), etc.
[0130] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0131] The foregoing is merely a specific embodiment of the present invention, which enables those skilled in the art to understand or implement the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but rather to the widest scope consistent with the principles and novel features claimed herein.
Claims
1. A method for identifying wall columns in architectural drawings. It is characterized in that include: Obtaining the architectural drawings to be identified; Determine a target line primitive set in any first layer of the architectural drawing, the first layer being a layer including line primitives; Determine a closed polygon set in the first layer according to the target line primitive set; If the characteristic parameters of the closed polygon set meet the first recognition condition in the first layer, determining that the closed polygon in the first layer is a wall column outline; Before determining the closed polygon set in the first layer according to the target line primitive set, the method further includes: Calculating the line segment length of each target line primitive in the target line primitive set; If the length of the line segment does not meet the preset value of the length of the wall column, it is determined that the first layer does not include the wall column; If the line segment length meets the preset value of the wall column length, determining the closed polygon set in the first layer according to the target line primitive set; The characteristic parameters of the closed polygon set include a first number of closed polygons in the closed polygon set, a second number of target line primitives in the closed polygon set, and a first area of each closed polygon in the closed polygon set; The first recognition condition in the first layer includes: The first number is greater than a first preset value, the ratio of the second number to the third number of target line primitives in the first layer is greater than or equal to the second preset value, the number of the first area greater than the first preset area is less than the third preset value, and the number of the first area less than the second preset area is less than a fourth preset value.
2. The method for identifying wall columns in architectural drawings according to claim 1, It is characterized in that The step of determining a set of line graphic elements in the first layer of the architectural drawing comprises: Get the layer name of the first layer; Determine that the line primitive including the layer name in the primitive information is the target line primitive; The target line primitive set is determined as the target line primitive set.
3. The method for identifying wall columns in architectural drawings according to claim 1, It is characterized in that The step of determining the closed polygon set in the first layer according to the target line primitive set includes: Obtaining the starting point coordinates and the ending point coordinates of each target line primitive in the target line primitive set; According to the starting point coordinates and the ending point coordinates, the closed polygons in the first layer are determined to obtain the closed polygon set, wherein, for any target line primitive in the closed polygon, there is a target line primitive that coincides with its starting point coordinates, and there is another target line primitive that coincides with its ending point coordinates.
4. The method for identifying wall columns in architectural drawings according to claim 1, It is characterized in that Also includes: Determine a target fill primitive set in any second layer of the architectural drawing, where the second layer is a layer including fill primitives; Determine a second area of each target filling primitive in the target filling primitive set; If the second area satisfies the second identification condition in the second layer, determining that the filling element in the second layer is a wall column filling; The level of the wall column outline is determined according to the wall column filling and the wall column outline.
5. The method for identifying wall columns in architectural drawings according to claim 4, It is characterized in that The step of determining the level of the wall column outline according to the wall column filling and the wall column outline includes: Determine that the wall column outlines whose distances between the wall column outlines are less than a preset overlap threshold are wall columns at the same level; Determine the filling ratio of the wall column within a preset distance of each wall column outline; If the filling ratio is less than a preset filling threshold, determining that the wall column outline is a lower layer wall column; If the filling ratio is greater than or equal to a preset filling threshold, it is determined that the wall column outline is an upper wall column.
6. A device for identifying wall columns in architectural drawings, It is characterized in that include: An acquisition module, used for acquiring the architectural drawings to be identified; A first determination module is used to determine a target line primitive set in any first layer of the architectural drawing, where the first layer is a layer including line primitives; A second determination module, configured to determine a closed polygon set in the first layer according to the target line primitive set; an identification module, configured to determine that the closed polygon in the first layer is a wall column outline if the characteristic parameters of the closed polygon set meet the first identification condition in the first layer; Before determining the closed polygon set in the first layer according to the target line primitive set, the line segment length of each target line primitive in the target line primitive set is calculated; if the line segment length does not meet the preset value of the wall column length, it is determined that the first layer does not include the wall column; if the line segment length meets the preset value of the wall column length, the step of determining the closed polygon set in the first layer according to the target line primitive set is executed; The characteristic parameters of the closed polygon set include a first number of closed polygons in the closed polygon set, a second number of target line primitives in the closed polygon set, and a first area of each closed polygon in the closed polygon set; The first recognition condition in the first layer includes: The first number is greater than a first preset value, the ratio of the second number to the third number of target line primitives in the first layer is greater than or equal to the second preset value, the number of the first area greater than the first preset area is less than the third preset value, and the number of the first area less than the second preset area is less than a fourth preset value.
7. An electronic device, It is characterized in that include: A processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus; The memory is used to store computer programs; The processor is used to execute the program stored in the memory to implement the method for identifying wall columns in architectural drawings as described in any one of claims 1-5.
8. A computer-readable storage medium storing a computer program, It is characterized in that When the computer program is executed by a processor, the method for identifying wall columns in architectural drawings according to any one of claims 1 to 5 is implemented.
