CN114756928B - Wall identification method, computer equipment and readable storage medium - Google Patents

Wall identification method, computer equipment and readable storage medium Download PDF

Info

Publication number
CN114756928B
CN114756928B CN202210291833.2A CN202210291833A CN114756928B CN 114756928 B CN114756928 B CN 114756928B CN 202210291833 A CN202210291833 A CN 202210291833A CN 114756928 B CN114756928 B CN 114756928B
Authority
CN
China
Prior art keywords
wall
line
original
lines
wall body
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202210291833.2A
Other languages
Chinese (zh)
Other versions
CN114756928A (en
Inventor
曾开发
吴彦鲲
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujian Chenxi Information Technology Group Co ltd
Original Assignee
Fujian Chenxi Information Technology Group Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fujian Chenxi Information Technology Group Co ltd filed Critical Fujian Chenxi Information Technology Group Co ltd
Priority to CN202210291833.2A priority Critical patent/CN114756928B/en
Publication of CN114756928A publication Critical patent/CN114756928A/en
Application granted granted Critical
Publication of CN114756928B publication Critical patent/CN114756928B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/10Geometric CAD
    • G06F30/13Architectural design, e.g. computer-aided architectural design [CAAD] related to design of buildings, bridges, landscapes, production plants or roads

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Geometry (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Theoretical Computer Science (AREA)
  • Civil Engineering (AREA)
  • Structural Engineering (AREA)
  • Computational Mathematics (AREA)
  • Architecture (AREA)
  • Mathematical Analysis (AREA)
  • Mathematical Optimization (AREA)
  • Pure & Applied Mathematics (AREA)
  • Evolutionary Computation (AREA)
  • General Engineering & Computer Science (AREA)
  • Processing Or Creating Images (AREA)

Abstract

The application relates to the technical field of building design, in particular to a wall identification method, computer equipment and a readable storage medium. The method of the application comprises the following steps: acquiring required wall name labels, wall lines and door and window lines from the drawing; identifying all wall line groups consisting of two wall lines from the wall lines and generating an original wall body; dividing the door and window lines into a plurality of rectangular image blocks, wherein each door and window line in each image block at least has one intersection point which is intersected with other door and window lines in the image block, and the image block is a minimum rectangular area containing all the door and window lines in the image block; generating a supplementary wall connected with the original wall according to each image block; connecting or deleting the wall body to obtain an identification wall body; and obtaining the corresponding relation between the wall name label and the identified wall. According to the scheme, the wall can be accurately identified from the building drawing by an automatic means, a manual processing mode is eliminated, and the working flow is simplified to improve the working efficiency.

Description

Wall identification method, computer equipment and readable storage medium
Technical Field
The application relates to the technical field of building design, in particular to a wall identification method, computer equipment and a readable storage medium.
Background
In the field of architecture, it is very common to use CAD or other design software to design construction drawings. In the engineering budget, construction and other stages, technicians analyze drawing information to perform calculation, inspection and other works, so that different legends are required to be identified in the design drawing, and subsequent calculation and other operations are performed according to the legends. In practical application, because the designed drawing adopts a overlook angle, when the designed drawing contains wall information and the wall is provided with an embedded door or window, the position in the drawing can only show the specification information of the door or window, and can not show part of wall information above the actual door or below the window. This part of wall information is particularly important in subsequent operations such as calculation, computer modeling, construction and the like, and the traditional processing mode generally requires manual checking and calculation of the wall in the design drawing to obtain complete wall data information. By means of manual recognition calculation, the efficiency is low and errors are very easy to occur. With the development of information technology, more and more people expect to get rid of manual processing modes, and the computing capability of a computer is utilized to rapidly identify complete wall data in drawings so as to improve working efficiency and life quality.
Disclosure of Invention
One of the objects of the present invention is to overcome the above drawbacks and to provide a method for identifying walls accurately and rapidly from design drawings by computer-based automation.
In order to solve the technical problems, the invention provides a wall identification method, which comprises the following steps:
acquiring required picture elements from a drawing; the picture elements comprise wall name labels, wall lines and door and window lines;
Identifying all wall line groups consisting of two wall lines from the wall lines;
Generating an original wall body according to the wall line group;
Dividing the door and window lines into a plurality of rectangular blocks; each door and window line in the block has at least one intersection point which is intersected with other door and window lines in the block; and the image block is a minimum rectangular area containing all door and window lines in the image block;
Generating a supplementary wall connected with the original wall according to each block;
connecting or deleting the wall body to obtain an identification wall body;
and obtaining the corresponding relation between the wall name label and the identified wall.
Further, the identifying all the wall line groups consisting of two wall lines from the wall lines comprises the following steps:
Step 201, judging whether a first wall line and a second wall line which meet the condition exist in the unprocessed wall lines, if so, executing step 202, otherwise, executing step 299; the meeting condition is as follows: the first wall line and the second wall line are parallel to each other and are projected and intersected, and the distance is within a thickness threshold range and is minimum;
Step 202, judging whether the first wall line and the second wall line are completely projected, if yes, executing step 203, otherwise executing step 204; the full projection means that the endpoints of the first wall line can be projected onto the endpoints of the second wall line;
step 203, marking the first wall line and the second wall line as processed, and taking the wall line group formed by the first wall line and the second wall line as the identified wall line group, jumping to the step 201 to continue execution;
Step 204, dividing the first wall line and/or the second wall line into a plurality of line segments according to the projection point of the first wall line end point onto the second wall line and the projection point of the second wall line end point onto the first wall line;
Step 205, judging whether an unprocessed line segment exists, if so, executing step 206 as the current processing line segment, otherwise, executing step 208; one end point of the unprocessed line segment is a projection point, and the other end point is an end point of the first wall line or the second wall line;
step 206, judging whether a corresponding wall line which is parallel to the current processing line segment and is intersected with the projection and has the smallest distance within the thickness threshold range exists in the unprocessed wall lines, if so, executing step 207, otherwise, executing step 205;
step 207, marking the current processing line segment and the corresponding wall line as processed, and taking the wall line group formed by the current processing line segment and the corresponding wall line as the identified wall line group, and jumping to step 205 to continue execution;
Step 208, marking the first wall line and the second wall line as processed, and taking the part of the first wall line and the second wall line after the processed line segments are cut off as the identified wall line group, and jumping to the step 201 to continue execution;
step 299, identify the end of the wall line set.
Further, the generating the supplemental wall connected with the original wall according to each block comprises the following steps:
step 501, judging whether there are unprocessed blocks, if yes, executing step 502, otherwise executing step 599;
step 502, obtaining an unprocessed block as a current processed block;
step 503, calculating an angle set corresponding to the current processing image block according to the door and window lines in the current processing image block;
step 504, expanding the rectangular region of the image block according to the set threshold value;
step 505, judging whether an original wall exists in the expanded rectangular area, if so, executing step 506, otherwise, executing step 501;
Step 506, calculating wall angles corresponding to all original walls falling in the expanded rectangular area, and removing the walls with the wall angles not in the angle set corresponding to the current processing block; the wall angle refers to an angle value of a smaller included angle between a wall midline and a coordinate system transverse axis by taking any point on the wall midline as an origin of a rectangular coordinate system;
Step 507, grouping original walls, specifically: if the wall center lines of the two original walls are parallel and the vertical distance of the wall center lines is less than or equal to half of the wall thickness of the thicker original wall, dividing the two original walls into the same group; otherwise, each original wall is divided into a group separately;
Step 508, simplifying the original wall body in each group, specifically: if the grouping comprises more than two original walls, firstly reserving the two original walls closest to the current processing block, and deleting the rest original walls; judging that if the two original walls have intersected wall parts, only one original wall closest to the current processing image block is reserved;
Step 509, judging whether there is an unprocessed packet, if yes, executing step 510, otherwise executing step 501;
step 510, obtaining an unprocessed packet as a current processed packet;
Step 511, judging whether two original walls exist in the current processing group, if yes, executing step 512, otherwise executing step 513;
Step 512, generating a supplementary wall between the two original walls; the wall center line of the supplementary wall body is arranged on an extension line extending from the wall center line of the first original wall body to the direction of the other original wall body; the starting point of the wall center line of the supplementary wall body is an endpoint of the wall center line of the first original wall body, which is close to the other original wall body, and the ending point is a projection point of the endpoint of the other original wall body, which is close to the first original wall body, on the extending line of the wall center line of the first original wall body; the thickness of the supplementary wall body is the same as that of the first original wall body; the first original wall body is an original wall body with the thickness being close to the thickness of the current processed block; jump to step 509 and continue execution;
Step 513, judging whether the door and window line in the current processing block contains an arc, if yes, executing step 514, otherwise executing step 516;
Step 514, generating a connecting line from the end point of the arc to the circle center of the arc;
step 515, judging whether there is a connection line where all points can be projected on the section of the original wall perpendicular to the wall center line, if yes, executing step 516, otherwise executing 509;
Step 516, generating a supplementary wall; the wall center line of the supplementary wall body is arranged on an extension line extending from the wall center line of the original wall body to the direction of the current processing block; the starting point of the wall center line of the supplementary wall body is an endpoint of the original wall center line which is closer to the current processing image block, and the finishing point is a projection point of all points on the current processing image block which is farthest on the original wall center line extension line; the thickness of the supplementary wall body is the same as that of the original wall body; jump to step 509 and continue execution;
And 599, finishing the treatment of the supplementary wall body.
Further, the calculating the angle set corresponding to the current processing block according to the door and window line in the current processing block specifically includes:
If the door and window line is a line segment, any point on the line segment is taken as an origin of a rectangular coordinate system, an angle value of a smaller included angle between the line segment and a transverse axis of the coordinate system is calculated, and the angle value and an angle value which is larger than the angle value by 90 degrees are added into an angle set corresponding to a picture block;
If the door and window line is an arc, two starting points of the arc are respectively used as tangent points to generate tangent lines of the arc, any point on the tangent lines is used as an origin of a rectangular coordinate system, an angle value of a smaller included angle between the tangent lines and a transverse axis of the coordinate system is calculated, and the angle value and an angle value which is larger than the angle value by 90 degrees are added into an angle set corresponding to a picture block.
Further, the wall body is communicated or deleted to obtain an identification wall body, which specifically comprises:
Combining the original wall bodies or the supplementary wall bodies with the same wall thickness, the same straight line of the wall center lines and the distance between the nearest endpoints of the two wall center lines within a set threshold range into one wall body;
The original wall or the supplementary wall completely contained by other walls is deleted.
Further, the obtaining the corresponding relation between the wall name label and the identified wall specifically includes:
Step 701, judging whether unprocessed wall names are marked, if yes, executing step 702, otherwise executing 799;
step 702, selecting an unprocessed wall name label as a current processed wall name label;
Step 703, judging whether the current processing wall name label contains a line segment, if yes, executing step 707, otherwise executing step 704;
Step 704, extending the length of the identified wall body to two sides along the wall center line by a set length;
step 705, judging whether the name label of the current processing wall body is intersected with the expanded identification wall body, if yes, executing step 706, otherwise, executing step 701;
Step 706, selecting an identified wall body with the same direction and closest distance to the name label direction of the currently processed wall body, and establishing a corresponding relation between the name label of the currently processed wall body and the identified wall body; jump to step 701 to continue execution;
Step 707, selecting an identification wall body intersected with the line segment, and establishing a corresponding relation between the name label of the currently processed wall body and the identification wall body; jump to step 701 to continue execution;
step 799, end the process.
Accordingly, the present application also provides a computer device comprising: the method comprises the steps of a memory, a processor and a computer program stored in the memory and capable of running on the processor, wherein the processor realizes the method for identifying the wall body according to any one of the above steps when executing the computer program.
Accordingly, the present application also provides a computer readable storage medium having stored thereon a computer program which when executed by a processor performs the steps of the method for identifying a wall as described in any one of the above.
According to the technical scheme, an original wall body is generated by identifying a wall line group consisting of two wall lines from the wall lines in the drawing; dividing the door and window lines into a plurality of rectangular blocks, and generating a supplementary wall connected with the original wall according to each block; and connecting or deleting the wall body to obtain the final identification wall body. The method can accurately generate the missing wall information above the door or below the window in the drawing, can solve the problems that the complete information of the wall in the building drawing is low in recognition and calculation efficiency and easy to make mistakes in a manual mode, is suitable for most of design drawings in the market, has higher recognition rate and higher recognition speed, simplifies the operation flow of users, and improves the working efficiency.
Drawings
FIG. 1 is a flow chart of steps of a method for identifying a wall according to the present invention.
FIG. 2 is a flowchart illustrating the steps of identifying all of the wall wire sets consisting of two wall wires from the wall wires according to the present invention.
FIG. 3 is a schematic view showing a complete projection of a first wall line and a second wall line.
FIG. 4 is a schematic view of the present invention, in which the first wall line and the second wall line are not completely projected.
FIG. 5 is a schematic diagram of the invention for creating an original wall from a set of wall lines.
Fig. 6 is a schematic diagram of a window and door line containing block diagram of the present invention.
FIG. 7 is a flowchart illustrating the steps of generating a supplemental wall to be connected to an original wall according to tiles of the present invention.
FIG. 8 is a diagram illustrating angles corresponding to a calculation block according to the present invention.
FIG. 9 is a second schematic view of angles corresponding to the calculation blocks according to the present invention.
FIG. 10 is a schematic diagram of the grouping of original walls according to the present invention.
FIG. 11 is a schematic illustration of the present invention for creating a supplemental wall between two original walls.
FIG. 12 is a schematic diagram of a supplemental wall created in accordance with the present invention.
FIG. 13 is a schematic diagram of a second wall of the present invention.
FIG. 14 is a flowchart showing the steps for obtaining the correspondence between wall name labels and identifying walls according to the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
Example 1
As shown in fig. 1, the present invention is a step flow chart of a wall identification method, which includes the following steps:
step 1, acquiring required picture elements from a drawing; the picture elements comprise wall name labels, wall lines and door and window lines.
It should be noted that, in the design drawing in the technical field of building design, generally, different legend elements are designed on different layers, for example, a wall layer only includes information related to a wall, including name label information of the wall, a traction line, a wall line, etc., and, for example, a rebar layer only includes information related to a rebar, liang Yuansu also includes a separate layer. In the scheme, only the identification of the wall is carried out, so that only the layer and the door and window line of the wall in the design drawing are needed, and other legend elements are not needed. The wall layer comprises wall name labels and wall lines.
And 2, identifying all the wall line groups consisting of two wall lines from the wall lines. Since the wall lines in the design diagram correspond to one face of the wall body, firstly, two wall lines which possibly form one wall body need to be found out from all the wall lines, as shown in fig. 2, the invention is a step flow chart for identifying all the wall line groups formed by the two wall lines from the wall lines, which comprises the following steps:
Step 201, judging whether a first wall line and a second wall line which meet the condition exist in the unprocessed wall lines, if so, executing step 202, otherwise, executing step 299; the satisfaction condition is that the first wall line and the second wall line are parallel to each other and are intersected in a projection mode, the distance is within a thickness threshold range, and the distance is minimum. It should be noted that the scheme of the application is only aimed at the wall bodies with two parallel wall surfaces, and does not comprise other wall bodies with irregular structures, such as arc-shaped walls and the like. In addition, the first wall line and the second wall line can be projected and intersected, which means that a small segment of line segment can be found on the first wall line, two end points of the line segment can be projected on the second wall line, otherwise, a small segment of line segment can be found on the second wall line, and two end points of the line segment can be projected on the first wall line. In particular embodiments, the thickness threshold range of the wall is generally set according to building codes. Meanwhile, if one wall line can be parallel to a plurality of other wall lines and the projection is intersected, and the distance is within the thickness threshold range, the wall line with the smallest distance is taken, wherein the distance between parallel lines refers to the length of a common vertical line segment between the two wall lines.
Step 202, judging whether the first wall line and the second wall line are completely projected, if yes, executing step 203, otherwise executing step 204; the full projection herein means that the end points of the first wall line can be projected onto the end points of the second wall line.
Step 203, if the first wall line and the second wall line are completely projected, the first wall line and the second wall line are the most perfectly matched wall lines, the first wall line and the second wall line are marked as processed, and a wall line group formed by the first wall line and the second wall line is used as an identified wall line group, and the step 201 is skipped to continue to be executed;
Step 204, dividing the first wall line and/or the second wall line into a plurality of line segments according to the projection point of the first wall line end point onto the second wall line and the projection point of the second wall line end point onto the first wall line;
Step 205, judging whether an unprocessed line segment exists, if so, executing step 206 as the current processing line segment, otherwise, executing step 208; one end point of the unprocessed line segment is a projection point, and the other end point is an end point of the first wall line or the second wall line;
step 206, judging whether a corresponding wall line which is parallel to the current processing line segment and is intersected with the projection and has the smallest distance within the thickness threshold range exists in the unprocessed wall lines, if so, executing step 207, otherwise, executing step 205;
step 207, marking the current processing line segment and the corresponding wall line as processed, and taking the wall line group formed by the current processing line segment and the corresponding wall line as the identified wall line group, and jumping to step 205 to continue execution;
Step 208, marking the first wall line and the second wall line as processed, and taking the part of the first wall line and the second wall line after the processed line segments are cut off as the identified wall line group, and jumping to the step 201 to continue execution;
Step 299, identify the end of the wall line set. After the steps are completed, two wall surface line combinations which possibly form a wall body can be found out from the wall surface lines.
In a specific embodiment, as shown in fig. 3, a schematic diagram of a complete projection of a first wall line and a second wall line is shown, wherein an end point a of the first wall line may be projected onto an end point C of the second wall line, an end point B of the first wall line may be projected onto an end point D of the second wall line, and a wall line group formed by the first wall line and the second wall line is used as an identified wall line group.
In another specific embodiment, as shown in fig. 4, there is a schematic diagram of the first wall line and the second wall line not being completely projected, in which the projection point of the end point a of the first wall line AB on the second wall line CD is F, the projection point of the end point D of the second wall line CD on the first wall line AB is E, the first wall line AB is divided into line segments AE, EB, and the second wall line CD is divided into line segments CF, FD, and the line segments EB, CF are the unprocessed line segments described in the step. And for the line segment EB, if a corresponding wall line GH which is parallel to the line segment EB and is projected to intersect with the line segment EB and has the smallest distance within the thickness threshold range exists in the untreated wall lines, marking the current treated line segment EB and the corresponding wall line GH as treated, and taking a wall line group formed by the current treated line segment EB and the corresponding wall line GH as an identified wall line group. For the line segment CF, since there is no corresponding wall line which is parallel to each other and projected to intersect with CF and whose distance is within the thickness threshold range and whose distance is minimum among the untreated wall lines, the first wall line AB and the second wall line CD are identified as treated, and the remaining portion AE after the treated line segment EB is cut off by the first wall line and the second wall line CD are taken as an identified wall line group.
And step 3, generating an original wall body according to the wall line group. Specifically, two endpoints of the first wall line are respectively projected onto the second wall line, the obtained projection points are on the second wall line or an extension line thereof, and similarly, two endpoints of the second wall line are respectively projected onto the first wall line, and the obtained projection points are on the first wall line or an extension line thereof. And taking the largest rectangular area formed by the endpoints or projection points of the first wall line and the second wall line as an original wall body. As shown in fig. 5, the wall line group consisting of the first wall line AB and the second wall line CD generates a rectangular area GCFB as the original wall.
And 4, dividing all the door and window lines into a plurality of rectangular image blocks according to the connection condition of the door and window lines, wherein each door and window line in each image block at least has one intersection point which is intersected with other door and window lines in the image block, namely, no independent door and window line which is not intersected with other door and window lines exists in the image block. The rectangular block is the smallest rectangular area containing all door and window lines in the block. As shown in fig. 6, where the solid line represents intersecting door and window lines, the dashed box at the periphery represents the tile area range.
And 5, generating a supplementary wall body connected with the original wall body according to each block. As shown in fig. 7, the present application is a flowchart of the steps for generating a supplemental wall connected to an original wall according to a tile, comprising the steps of:
step 501, judging whether there are unprocessed blocks, if yes, executing step 502, otherwise executing step 599;
step 502, obtaining an unprocessed block as a current processed block;
step 503, calculating an angle set corresponding to the current processing block according to the door and window lines in the current processing block, specifically:
if the door and window line is a line segment, any point on the line segment is taken as an origin of a rectangular coordinate system, an angle value of a smaller included angle between the line segment and a transverse axis of the coordinate system is calculated, and the angle value and an angle value which is larger than the angle value by 90 degrees are added into an angle set corresponding to a picture block. As shown in fig. 8, a line segment AB is a door and window line, any point on the line segment is taken as an origin of a rectangular coordinate system, and an angle value of a smaller included angle between the line segment and a transverse axis of the coordinate system is 26.7 degrees, and then 26.7 degrees and 116.7 degrees are added into an angle set corresponding to a block.
If the door and window line is an arc, two starting points of the arc are respectively used as tangent points to generate tangent lines of the arc, any point on the tangent lines is used as an origin of a rectangular coordinate system, an angle value of a smaller included angle between the tangent lines and a transverse axis of the coordinate system is calculated, and the angle value and an angle value which is larger than the angle value by 90 degrees are added into an angle set corresponding to a picture block. As shown in fig. 9, the arc line AB is a door and window line, on the tangent line AO of the arc line AB, where a is the tangent point, any point is taken as the origin of the rectangular coordinate system, and the angle value of the smaller included angle between the tangent line and the transverse axis of the coordinate system is 40.8 degrees, and then 40.8 degrees and 130.8 degrees are added into the angle set corresponding to the image block. Similarly, any point on the tangent line taking the point B as the tangent point is taken as the origin of the rectangular coordinate system, the angle value of the tangent line with a smaller included angle with the transverse axis of the coordinate system is calculated, and the angle value which is larger than the angle value by 90 degrees are added into the angle set corresponding to the image block.
Step 504, expanding the rectangular region of the image block according to the set threshold value. In a preferred embodiment, the threshold for expansion may be set to 50mm, i.e., 50mm above, below, to the left and right of the rectangular region borders of the tiles.
Step 505, judging whether an original wall exists in the expanded rectangular area, if so, executing step 506, otherwise, executing step 501;
Step 506, calculating wall angles corresponding to all original walls falling in the expanded rectangular area, and removing the walls with the wall angles not in the angle set corresponding to the current processing block; the wall angle refers to an angle value of a smaller included angle between a wall midline and a coordinate system transverse axis by taking any point on the wall midline as an origin of a rectangular coordinate system. For example, if the calculated wall angle is 45 degrees and there is no 45 degree angle value in the angle set corresponding to the current processing block, the wall is excluded.
Step 507, grouping original walls, specifically: if the wall center lines of the two original walls are parallel and the vertical distance of the wall center lines is less than or equal to half of the wall thickness of the thicker original wall, dividing the two original walls into the same group; otherwise, each original wall is divided into a group individually. As shown in fig. 10, the original wall ABCD and the original wall EFGH are divided into the same group if the wall centerlines of the original wall ABCD and the original wall EFGH are parallel to each other and the vertical distance between the centerlines of the original wall ABCD and the original wall EFGH is less than half of the thickness of the thicker original wall ABCD.
Step 508, simplifying the original wall body in each group, specifically: if the grouping comprises more than two original walls, firstly reserving the two original walls closest to the current processing block, and deleting the rest original walls; the distance between the original wall and the current processing block refers to the minimum distance from the point on the original wall to the point on the door and window line in the current processing block. And judging that if the two original walls have intersected wall parts, which are not actually needed, only one original wall closest to the current processing block is reserved.
Step 509, judging whether there is an unprocessed packet, if yes, executing step 510, otherwise executing step 501;
step 510, obtaining an unprocessed packet as a current processed packet;
Step 511, judging whether two original walls exist in the current processing group, if yes, executing step 512, otherwise executing step 513;
step 512, generating a supplementary wall between the two original walls; the wall center line of the supplementary wall body is arranged on an extension line extending from the wall center line of the first original wall body to the direction of the other original wall body; the starting point of the wall center line of the supplementary wall body is an endpoint of the wall center line of the first original wall body, which is close to the other original wall body, and the ending point is a projection point of the endpoint of the other original wall body, which is close to the first original wall body, on the extending line of the wall center line of the first original wall body; the thickness of the supplementary wall body is the same as that of the first original wall body; the first original wall body is an original wall body with the thickness being close to the thickness of the current processed block; jump to step 509 continues execution. The current processing of the tile thickness refers to the maximum distance between two projected points after all points on all door and window lines in the tile are projected onto a straight line perpendicular to the center line of the original wall. As shown in fig. 11, the first original wall ABCD is an original wall with a thickness closer to the thickness of the current processed tile, wherein two ends of the wall center line are O1 and O2, and two ends of the wall center line of the other original wall are O3 and O4, so that the wall center line of the supplementary wall is on an extension line extending from the wall center line of the first original wall toward the direction of the other original wall; the starting point of the wall center line of the supplementary wall body is an endpoint O2 of the wall center line of the first original wall body, which is close to the other original wall body, and the endpoint is a projection point O4 of an endpoint O3 of the other original wall body, which is close to the first original wall body, on the extending line of the wall center line of the first original wall body; the thickness of the supplementary wall DCFE is the same as the thickness of the first original wall ABCD.
Step 513, judging whether the door and window line in the current processing block contains an arc, if yes, executing step 514, otherwise executing step 516;
Step 514, generating a connecting line from the end point of the arc to the circle center of the arc;
step 515, judging whether there is a connection line where all points can be projected on the section of the original wall perpendicular to the wall center line, if yes, executing step 516, otherwise executing 509;
Step 516, generating a supplementary wall; the wall center line of the supplementary wall body is arranged on an extension line extending from the wall center line of the original wall body to the direction of the current processing block; the starting point of the wall center line of the supplementary wall body is an endpoint of the original wall center line which is closer to the current processing image block, and the finishing point is a projection point of all points on the current processing image block which is farthest on the original wall center line extension line; the thickness of the supplementary wall body is the same as that of the original wall body; jump to step 509 and continue execution;
in a specific embodiment, the door and window lines in the processing block include circular arcs, as shown in fig. 12, the endpoints of the circular arcs are S1 and S2, a connection line from the endpoint of the circular arc to the circle center O of the circular arc is generated, when all points on the connection line between the endpoint S1 of the circular arc and the circular point O are judged to be projected onto the cross section AB of the original wall perpendicular to the wall center line, an extension line of the wall center line of the supplementary wall EFBA extending in the direction of the current processing block in the wall center line of the original wall ABCD is generated; the starting point of the wall center line of the supplementary wall EFBA is an endpoint O1 of the original wall ABCD wall center line which is closer to the current processing block, and the endpoint is a projection point O3 of all points on the current processing block which is farthest on the original wall ABCD wall center line extension line; the thickness of the supplemental wall EFBA is the same as the thickness of the original wall ABCD.
In another specific embodiment, wherein the door and window lines in the processing block do not include circular arcs, as shown in fig. 13, the generated wall center line of the supplemental wall EFBA is on an extension line of the original wall ABCD wall line extending toward the current processing block direction; the starting point of the wall center line of the supplementary wall EFBA is an endpoint O1 of the original wall ABCD wall center line which is closer to the current processing block, and the endpoint is a projection point O3 of all points on the current processing block which is farthest on the original wall center line extension line; the thickness of the supplemental wall EFBA is the same as the thickness of the original wall ABCD.
And 599, finishing the treatment of the supplementary wall body.
Step 6, connecting or deleting the wall body to obtain an identification wall body, which specifically comprises the following steps: combining the original wall bodies or the supplementary wall bodies with the same wall thickness, the same straight line of the wall center lines and the distance between the nearest endpoints of the two wall center lines within the set threshold range into the same wall body, and deleting the original wall bodies or the supplementary wall bodies completely contained by other wall bodies.
And 7, obtaining the corresponding relation between the wall name label and the identified wall. After all the walls are identified, the wall name label is associated with the wall, so that the wall name and other wall parameter specifications can be obtained. As shown in fig. 14, the step flow chart of the present invention for obtaining the correspondence between the wall name label and the identified wall specifically includes:
Step 701, judging whether unprocessed wall names are marked, if yes, executing step 702, otherwise executing 799;
step 702, selecting an unprocessed wall name label as a current processed wall name label;
Step 703, judging whether the current processing wall name label contains a line segment, if yes, executing step 707, otherwise executing step 704;
Step 704, extending the length of the identified wall body to two sides along the wall center line by a set length;
step 705, judging whether the name label of the current processing wall body is intersected with the expanded identification wall body, if yes, executing step 706, otherwise, executing step 701;
Step 706, selecting an identified wall body with the same direction and closest distance to the name label direction of the currently processed wall body, and establishing a corresponding relation between the name label of the currently processed wall body and the identified wall body; jump to step 701 to continue execution;
Step 707, selecting an identification wall body intersected with the line segment, and establishing a corresponding relation between the name label of the currently processed wall body and the identification wall body; jump to step 701 to continue execution;
step 799, end the process.
According to the technical scheme, an original wall body is generated by identifying a wall line group consisting of two wall lines from the wall lines in the drawing; dividing the door and window lines into a plurality of rectangular blocks, and generating a supplementary wall connected with the original wall according to each block; and connecting or deleting the wall body to obtain the final identification wall body. The method can accurately generate the missing wall information above the door or below the window in the drawing, can solve the problems that the complete information of the wall in the building drawing is low in recognition and calculation efficiency and easy to make mistakes in a manual mode, is suitable for most of design drawings in the market, has higher recognition rate and higher recognition speed, simplifies the operation flow of users, and improves the working efficiency.
Example two
The present embodiment also provides a computer device, such as a smart phone, a tablet computer, a notebook computer, a desktop computer, a rack-mounted server, a blade server, a tower server, or a rack-mounted server (including an independent server or a server cluster formed by a plurality of servers) that can execute a program. The computer device of the present embodiment includes at least, but is not limited to: a memory, a processor, and the like, which may be communicatively coupled to each other via a system bus. In some embodiments, the memory may be an internal storage unit of the computer device, such as a hard disk or a memory of the computer device, or may be an external storage device of the computer device, such as a plug-in hard disk, a smart memory card, etc. provided on the computer device. The processor may be a central processing unit (Central Processing Unit, CPU), controller, microcontroller, microprocessor, or other data processing chip for controlling the overall operation of the computer device. Specifically, in this embodiment, the processor is configured to run a computer program stored on the memory, where the processor implements the steps of the method for identifying any wall when the processor executes the computer program.
Example III
The present embodiment also provides a computer readable storage medium, such as a flash memory, a hard disk, a multimedia card, a card memory, (e.g. SD or DX memory, etc.), a Random Access Memory (RAM), a Static Random Access Memory (SRAM), a Read Only Memory (ROM), an Electrically Erasable Programmable Read Only Memory (EEPROM), a Programmable Read Only Memory (PROM), a magnetic memory, a magnetic disk, an optical disk, a server, an App application store, etc., on which a computer program is stored, characterized in that the program when executed by a processor implements the steps of the method for identifying a wall as described in any of the above.
The foregoing detailed description will be given for the purpose of illustration only, and the invention is not limited to the above-described embodiments, but is to be construed as merely illustrative of the principles of the invention, as long as they are within the scope of the invention.

Claims (7)

1. The wall identification method is characterized by comprising the following steps of:
acquiring required picture elements from a drawing; the picture elements comprise wall name labels, wall lines and door and window lines;
Identifying all wall line groups consisting of two wall lines from the wall lines;
Generating an original wall body according to the wall line group;
Dividing the door and window lines into a plurality of rectangular blocks; each door and window line in the block has at least one intersection point which is intersected with other door and window lines in the block; and the image block is a minimum rectangular area containing all door and window lines in the image block;
Generating a supplemental wall connected to the original wall according to each tile, comprising the steps of:
step 501, judging whether there are unprocessed blocks, if yes, executing step 502, otherwise executing step 599;
step 502, obtaining an unprocessed block as a current processed block;
step 503, calculating an angle set corresponding to the current processing image block according to the door and window lines in the current processing image block;
step 504, expanding the rectangular region of the image block according to the set threshold value;
step 505, judging whether an original wall exists in the expanded rectangular area, if so, executing step 506, otherwise, executing step 501;
Step 506, calculating wall angles corresponding to all original walls falling in the expanded rectangular area, and removing the walls with the wall angles not in the angle set corresponding to the current processing block; the wall angle refers to an angle value of a smaller included angle between a wall midline and a coordinate system transverse axis by taking any point on the wall midline as an origin of a rectangular coordinate system;
Step 507, grouping original walls, specifically: if the wall center lines of the two original walls are parallel and the vertical distance of the wall center lines is less than or equal to half of the wall thickness of the thicker original wall, dividing the two original walls into the same group; otherwise, each original wall is divided into a group separately;
Step 508, simplifying the original wall body in each group, specifically: if the grouping comprises more than two original walls, firstly reserving the two original walls closest to the current processing block, and deleting the rest original walls; judging that if the two original walls have intersected wall parts, only one original wall closest to the current processing image block is reserved;
Step 509, judging whether there is an unprocessed packet, if yes, executing step 510, otherwise executing step 501;
step 510, obtaining an unprocessed packet as a current processed packet;
Step 511, judging whether two original walls exist in the current processing group, if yes, executing step 512, otherwise executing step 513;
Step 512, generating a supplementary wall between the two original walls; the wall center line of the supplementary wall body is arranged on an extension line extending from the wall center line of the first original wall body to the direction of the other original wall body; the starting point of the wall center line of the supplementary wall body is an endpoint of the wall center line of the first original wall body, which is close to the other original wall body, and the ending point is a projection point of the endpoint of the other original wall body, which is close to the first original wall body, on the extending line of the wall center line of the first original wall body; the thickness of the supplementary wall body is the same as that of the first original wall body; the first original wall body is an original wall body with the thickness being close to the thickness of the current processed block; jump to step 509 and continue execution;
Step 513, judging whether the door and window line in the current processing block contains an arc, if yes, executing step 514, otherwise executing step 516;
Step 514, generating a connecting line from the end point of the arc to the circle center of the arc;
step 515, judging whether there is a connection line where all points can be projected on the section of the original wall perpendicular to the wall center line, if yes, executing step 516, otherwise executing 509;
Step 516, generating a supplementary wall; the wall center line of the supplementary wall body is arranged on an extension line extending from the wall center line of the original wall body to the direction of the current processing block; the starting point of the wall center line of the supplementary wall body is an endpoint of the original wall center line which is closer to the current processing image block, and the finishing point is a projection point of all points on the current processing image block which is farthest on the original wall center line extension line; the thickness of the supplementary wall body is the same as that of the original wall body; jump to step 509 and continue execution;
step 599, supplementing wall treatment is completed;
connecting or deleting the wall body to obtain an identification wall body;
and obtaining the corresponding relation between the wall name label and the identified wall.
2. The method for identifying a wall according to claim 1, wherein said identifying all of the wall groups consisting of two wall lines from the wall lines comprises the steps of:
Step 201, judging whether a first wall line and a second wall line which meet the condition exist in the unprocessed wall lines, if so, executing step 202, otherwise, executing step 299; the meeting condition is as follows: the first wall line and the second wall line are parallel to each other and are projected and intersected, and the distance is within a thickness threshold range and is minimum;
Step 202, judging whether the first wall line and the second wall line are completely projected, if yes, executing step 203, otherwise executing step 204; the full projection means that the endpoints of the first wall line can be projected onto the endpoints of the second wall line;
step 203, marking the first wall line and the second wall line as processed, and taking the wall line group formed by the first wall line and the second wall line as the identified wall line group, jumping to the step 201 to continue execution;
Step 204, dividing the first wall line and/or the second wall line into a plurality of line segments according to the projection point of the first wall line end point onto the second wall line and the projection point of the second wall line end point onto the first wall line;
Step 205, judging whether an unprocessed line segment exists, if so, executing step 206 as the current processing line segment, otherwise, executing step 208; one end point of the unprocessed line segment is a projection point, and the other end point is an end point of the first wall line or the second wall line;
step 206, judging whether a corresponding wall line which is parallel to the current processing line segment and is intersected with the projection and has the smallest distance within the thickness threshold range exists in the unprocessed wall lines, if so, executing step 207, otherwise, executing step 205;
step 207, marking the current processing line segment and the corresponding wall line as processed, and taking the wall line group formed by the current processing line segment and the corresponding wall line as the identified wall line group, and jumping to step 205 to continue execution;
Step 208, marking the first wall line and the second wall line as processed, and taking the part of the first wall line and the second wall line after the processed line segments are cut off as the identified wall line group, and jumping to the step 201 to continue execution;
step 299, identify the end of the wall line set.
3. The method for identifying a wall according to claim 1, wherein the calculating the angle set corresponding to the current processing block according to the door and window line in the current processing block specifically includes:
If the door and window line is a line segment, any point on the line segment is taken as an origin of a rectangular coordinate system, an angle value of a smaller included angle between the line segment and a transverse axis of the coordinate system is calculated, and the angle value and an angle value which is larger than the angle value by 90 degrees are added into an angle set corresponding to a picture block;
If the door and window line is an arc, two starting points of the arc are respectively used as tangent points to generate tangent lines of the arc, any point on the tangent lines is used as an origin of a rectangular coordinate system, an angle value of a smaller included angle between the tangent lines and a transverse axis of the coordinate system is calculated, and the angle value and an angle value which is larger than the angle value by 90 degrees are added into an angle set corresponding to a picture block.
4. The method for identifying a wall according to claim 1, wherein the identifying a wall is obtained by connecting or deleting the wall, specifically:
Combining the original wall bodies or the supplementary wall bodies with the same wall thickness, the same straight line of the wall center lines and the distance between the nearest endpoints of the two wall center lines within a set threshold range into one wall body;
The original wall or the supplementary wall completely contained by other walls is deleted.
5. The method for identifying a wall according to claim 1, wherein the obtaining the correspondence between the wall name label and the identified wall specifically includes:
Step 701, judging whether unprocessed wall names are marked, if yes, executing step 702, otherwise executing 799;
step 702, selecting an unprocessed wall name label as a current processed wall name label;
Step 703, judging whether the current processing wall name label contains a line segment, if yes, executing step 707, otherwise executing step 704;
Step 704, extending the length of the identified wall body to two sides along the wall center line by a set length;
step 705, judging whether the name label of the current processing wall body is intersected with the expanded identification wall body, if yes, executing step 706, otherwise, executing step 701;
Step 706, selecting an identified wall body with the same direction and closest distance to the name label direction of the currently processed wall body, and establishing a corresponding relation between the name label of the currently processed wall body and the identified wall body; jump to step 701 to continue execution;
Step 707, selecting an identification wall body intersected with the line segment, and establishing a corresponding relation between the name label of the currently processed wall body and the identification wall body; jump to step 701 to continue execution;
step 799, end the process.
6. A computer device, the computer device comprising: a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the steps of the method for identifying a wall according to any one of claims 1 to 5 when the computer program is executed.
7. A computer readable storage medium having stored thereon a computer program, wherein the program when executed by a processor performs the steps of the method of identifying a wall according to any one of claims 1 to 5.
CN202210291833.2A 2022-03-23 2022-03-23 Wall identification method, computer equipment and readable storage medium Active CN114756928B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210291833.2A CN114756928B (en) 2022-03-23 2022-03-23 Wall identification method, computer equipment and readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210291833.2A CN114756928B (en) 2022-03-23 2022-03-23 Wall identification method, computer equipment and readable storage medium

Publications (2)

Publication Number Publication Date
CN114756928A CN114756928A (en) 2022-07-15
CN114756928B true CN114756928B (en) 2024-05-28

Family

ID=82327402

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210291833.2A Active CN114756928B (en) 2022-03-23 2022-03-23 Wall identification method, computer equipment and readable storage medium

Country Status (1)

Country Link
CN (1) CN114756928B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115063829B (en) * 2022-08-15 2023-01-10 万翼科技有限公司 Non-closed region identification method, device, equipment and storage medium
CN115131656B (en) * 2022-09-01 2022-12-13 深圳鹏行智能研究有限公司 Space identification method and device, electronic equipment and computer readable storage medium
CN116188629B (en) * 2022-12-12 2024-02-27 贝壳找房(北京)科技有限公司 Method, electronic equipment and medium for generating decoration drawing reference

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20100138112A (en) * 2009-06-24 2010-12-31 백종성 A method to build the non bearing wall through slip casting process using the form with rapid heat system
CN105302930A (en) * 2014-06-30 2016-02-03 上海神机软件有限公司 Engineering drawing recognition system and method based on longitudinal and transverse beams, and template arrangement system and method
JP2019139756A (en) * 2018-02-09 2019-08-22 广州大学 Veranda automatic recognition method based on architecture drawing
CN112966330A (en) * 2021-04-09 2021-06-15 福建省晨曦信息科技股份有限公司 Wall surface generation method of crossed wall body, computer equipment and readable storage medium
CN113627264A (en) * 2021-07-13 2021-11-09 北京盈建科软件股份有限公司 Modeling method, system, terminal and medium based on drawing identification
CN114048535A (en) * 2021-11-17 2022-02-15 北京蜂鸟视图科技有限公司 System and method for generating door and window in CAD wall map layer during map construction

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112712584B (en) * 2019-10-25 2024-05-24 阿里巴巴集团控股有限公司 Space modeling method, device and equipment

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20100138112A (en) * 2009-06-24 2010-12-31 백종성 A method to build the non bearing wall through slip casting process using the form with rapid heat system
CN105302930A (en) * 2014-06-30 2016-02-03 上海神机软件有限公司 Engineering drawing recognition system and method based on longitudinal and transverse beams, and template arrangement system and method
JP2019139756A (en) * 2018-02-09 2019-08-22 广州大学 Veranda automatic recognition method based on architecture drawing
CN112966330A (en) * 2021-04-09 2021-06-15 福建省晨曦信息科技股份有限公司 Wall surface generation method of crossed wall body, computer equipment and readable storage medium
CN113627264A (en) * 2021-07-13 2021-11-09 北京盈建科软件股份有限公司 Modeling method, system, terminal and medium based on drawing identification
CN114048535A (en) * 2021-11-17 2022-02-15 北京蜂鸟视图科技有限公司 System and method for generating door and window in CAD wall map layer during map construction

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
建筑构件智能识别方法研究;李伟青;浙江大学学报(理学版);20050825(第04期);第393-398页 *

Also Published As

Publication number Publication date
CN114756928A (en) 2022-07-15

Similar Documents

Publication Publication Date Title
CN114756928B (en) Wall identification method, computer equipment and readable storage medium
CN110675508B (en) BIM model geometric figure simplifying method
CN112861238B (en) Method, device, equipment and readable storage medium for generating road contour line
CN114528632B (en) Beam recognition method, computer device, and readable storage medium
CN112966330A (en) Wall surface generation method of crossed wall body, computer equipment and readable storage medium
CN107564077B (en) method and device for drawing road network
US11625843B2 (en) Systems and methods for automatic alignment of drawings
CN114581639A (en) Method for generating information of beam steel bars in BIM (building information modeling) model based on beam leveling construction drawing
CN115525951A (en) Regularization method and device for building contour optimization and feature edge reconstruction
CN114240976B (en) Map iterative segmentation method, device, equipment and storage medium
US20080143708A1 (en) System and method for auto-dimensioning boundary representation model
CN106651944B (en) Method and device for calculating horizontal inscribed rectangle of any connected domain based on stroke coding
CN116343251A (en) Building drawing identification method and system based on AI building identification chart
CN110647148A (en) Wall position determining method and device, computer equipment and storage medium
CN115641436A (en) Region segmentation method and device and robot device
CN116150860B (en) Beam span identification method, computer equipment and readable storage medium
CN113051639B (en) Stirrup and lacing wire identification method, computer equipment and readable storage medium
CN111488648B (en) Automatic drawing method, system, equipment and storage medium for ship structure diagram
CN114444185A (en) In-situ labeling identification method and device and electronic equipment
CN113026457A (en) Road construction segment determining method and determining device
CN112884899A (en) Three-dimensional member generation method and device, computer device and storage medium
CN113268798B (en) Method for generating steel bar in column section, computer device and readable storage medium
CN117633973A (en) CAD file identification method, device, electronic equipment and storage medium
CN118640894B (en) Method and system for automatically generating light-weight environment map of robot inspection building
CN113255600B (en) Point cloud map updating optimization method, system, medium and equipment based on client

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