Real estate house hierarchical plan vectorization automatic mapping method

By automating the processing of floor plans of real estate buildings, including area selection and recognition, image preprocessing, and corner detection, and constructing line segment coordinate pairs, the inefficiency of existing technologies is solved, achieving automated vectorization and improving efficiency and accuracy.

CN114445524BActive Publication Date: 2025-10-17GUILIN UNIVERSITY OF TECHNOLOGY
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111559003.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-20
Publication Date
2025-10-17
Estimated Expiration
2041-12-20

AI Technical Summary

Technical Problem

The existing process of vectorizing floor plans of real estate buildings relies on manual drawing, which is inefficient and prone to errors.

Method used

An automated method is used to scan the floor plan of a building, select the identification area, perform image preprocessing, text recognition and corner detection, construct line segment coordinate pairs, and finally import them into drawing software to automatically generate a map.

Benefits of technology

It has enabled the automated vectorization of floor plans for real estate buildings, reducing manpower and material resources consumption and improving operational efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114445524B_ABST
    Figure CN114445524B_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of electronic digital data processing, in particular to a kind of real estate house stratified plan vector automatic mapping method, including scanning house stratified plan, obtains electronic picture;Frame the identification area of electronic picture;Image pre-processing is carried out to identification area, and identification area frame diagram is obtained;Text information in identification area frame diagram is identified and extracted, while corner point detection and screening are carried out, and screening information and extraction information are paired, and paired group is obtained;Line segment coordinate pair is selected based on paired group, self-defined coordinate pair coordinates, and actual line segment coordinate pair is constructed;Actual line segment coordinate pair is saved in text form, and text information is obtained;Text information is imported into drawing software and automatically mapped, the whole process does not need manual participation to draw, solve the problem that the efficiency and accuracy of existing house stratified plan are low by manual drawing.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of electronic digital data processing, and particularly relates to a real estate house layered plan vectorization automatic mapping method. BACKGROUND

[0002] In the real estate surveying and mapping industry, for the work of vectorization of real estate house layered plan into the warehouse, a company or unit with certain surveying and mapping qualifications often needs to manually draw the house layered plan by using CASS software through drawing personnel to realize the vectorization of the house layered plan.

[0003] The traditional way of vectorizing the house layered plan consumes a large amount of manpower and material resources, and has low work efficiency and is prone to drawing, labeling and other errors. SUMMARY

[0004] The present application relates to the technical field of electronic digital data processing, and particularly relates to a real estate house layered plan vectorization automatic mapping method.

[0005] To achieve the above-mentioned purpose, the present application provides a real estate house layered plan vectorization automatic mapping method, comprising the following steps:

[0006] Scanning the house layered plan to obtain an electronic picture;

[0007] Based on the house structure, the recognition area of the electronic picture is framed;

[0008] The image of the recognition area is pre-processed to obtain a recognition area frame;

[0009] The text information in the recognition area frame is recognized and extracted to obtain pixel position information, and the corner points in the recognition area frame are detected and screened to obtain screening information, and the screening information and the pixel position information are paired to obtain a paired group;

[0010] Based on the paired group, a line segment coordinate pair is selected, a coordinate pair coordinate is defined, and an actual line segment coordinate pair is constructed;

[0011] The actual line segment coordinate pair is saved in text form to obtain text information;

[0012] The text information is imported into a drawing software to automatically map.

[0013] The specific way of framing the recognition area of the electronic picture based on the house structure is as follows:

[0014] The recognition area in the electronic picture and the text and graphics in the recognition area are framed.

[0015] Discard the information not framed.

[0016] The specific method for image pre-processing the recognition area to obtain the recognition area frame diagram is:

[0017] Image correction is performed on the framed recognition area to obtain a corrected image;

[0018] The corrected image is subjected to a binarization process to obtain a binary image;

[0019] The binary image is subjected to a skeletonization process to obtain a recognition area frame diagram.

[0020] The specific method for recognizing and extracting the text information in the recognition area frame diagram to obtain pixel position information, simultaneously detecting and screening the corner points in the recognition area frame diagram to obtain screening information, and pairing the screening information and the pixel position information to obtain a pairing group is:

[0021] The text information in the recognition area frame diagram is recognized and extracted, and horizontal or vertical markers are displayed according to the direction of the text information to obtain recognition information, and the pixel position information corresponding to the recognition information is saved;

[0022] The recognition area frame diagram is subjected to corner point detection, and after quantity calculation, local non-maximum suppression is performed to obtain corner point information;

[0023] A local limit area of the recognition area frame diagram is defined, the corner point information in the local limit area is matched with the pixel position information, the corner points corresponding to the local limit area are screened out and stored in a first corner point set, and the remaining corner points are stored in a second corner point set;

[0024] The corner points in the first corner point set are paired with the pixel position information to obtain a pairing group.

[0025] The specific method for selecting line segment coordinate pairs based on the pairing group to construct actual line segment coordinate pairs is:

[0026] Based on the pairing group and the pixel position information, a longitudinal line segment coordinate pair containing distance information is obtained;

[0027] Based on the pairing group and the pixel position information, a transverse line segment coordinate pair containing distance information is obtained;

[0028] Combine the longitudinal line segment coordinate pairs with the transverse line segment coordinate pairs, and select line segment coordinate pairs according to distance information of the longitudinal line segment coordinate pairs and the transverse line segment coordinate pairs, define coordinate pair coordinates, and construct actual line segment coordinate pairs.

[0029] The specific manner of obtaining the longitudinal line segment coordinate pairs containing distance information based on the pairing group and the pixel position information is as follows:

[0030] Sort the corner points in the pairing group according to the horizontal coordinates to obtain a first straight line set group;

[0031] Sort the corner points in the first straight line set group according to the vertical coordinates, and group adjacent two corner points into a corner point pair and store the corner point pair in a first corner point pair set group;

[0032] Match the identification information with a vertical mark in the first corner point set with the corner point pairs in the first corner point pair set group to obtain the longitudinal line segment coordinate pairs containing distance information.

[0033] The specific manner of obtaining the transverse line segment coordinate pairs containing distance information based on the pairing group and the pixel position information is as follows:

[0034] Sort the corner points in the pairing group according to the vertical coordinates to obtain a second straight line set group;

[0035] Sort the corner points in the second straight line set group according to the horizontal coordinates, group adjacent two corner points into a corner point pair, and store the corner point pair in a second corner point pair set group;

[0036] Match the identification information with a horizontal mark in the first corner point set with the corner point pairs in the second corner point pair set group to obtain the transverse line segment coordinate pairs containing distance information.

[0037] The application discloses an automatic vectorization and mapping method for a real estate house layered plan, which comprises the following steps: scanning a house layered plan to obtain an electronic picture; framing an identification area of the electronic picture; performing image preprocessing on the identification area to obtain an identification area frame; recognizing and extracting text information in the identification area frame, simultaneously performing corner point detection and screening, pairing the screening information and the extracted information to obtain a pairing group; selecting line segment coordinate pairs based on the pairing group, defining coordinate pair coordinates, and constructing actual line segment coordinate pairs; saving the actual line segment coordinate pairs in a text form to obtain text information; and importing the text information into a drawing software to automatically generate a drawing, so that the whole process does not need manual drawing, and the problems of low efficiency and low accuracy of manual drawing of the existing house layered plan are solved. BRIEF DESCRIPTION OF DRAWINGS

[0038] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the accompanying drawings used in the description of the embodiments or prior art will be briefly described in the following. Obviously, the drawings described below only show some embodiments of the present application, and for those skilled in the art, other drawings can also be obtained without creative labor on the basis of these drawings.

[0039] Figure 1 is a flow chart of a real estate house layered plan vectorization automatic mapping method provided by the present application.

[0040] Figure 2 is a flow chart of image preprocessing of the identified area to obtain an identified area frame diagram.

[0041] Figure 3 is a flow chart of recognizing and extracting text information in the identified area frame diagram, simultaneously performing corner point detection and screening, and pairing the screened information and the extracted information to obtain a paired group.

[0042] Figure 4 is a flow chart of selecting line segment coordinate pairs based on the paired group to construct actual line segment coordinate pairs.

[0043] Figure 5 is a flow chart of obtaining longitudinal line segment coordinate pairs containing distance information based on the paired group and the pixel position information.

[0044] Figure 6 is a flow chart of obtaining transverse line segment coordinate pairs containing distance information based on the paired group and the pixel position information.

[0045] Figure 7 is a demonstration diagram of text recognition and extraction.

[0046] Figure 8 is a demonstration diagram of corner point detection. DETAILED DESCRIPTION

[0047] The embodiments of the present application will be described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference signs represent the same or similar elements or elements having the same or similar functions throughout. The embodiments described below by referring to the accompanying drawings are exemplary and are intended to explain the present application, and cannot be understood as a limitation of the present application.

[0048] Referring to Figures 1 to 6 , the present application provides a real estate house layered plan vectorization automatic mapping method, comprising the following steps:

[0049] S1, scanning a house layered plan to obtain an electronic picture;

[0050] S2, frame the recognition area of the electronic picture based on the house structure;

[0051] Specifically, the recognition area in the electronic picture and the text and graphics in the recognition area are framed, and information such as text, graphics and tables that are not framed is removed.

[0052] S3, image pre-processing is performed on the recognition area to obtain a recognition area frame;

[0053] The specific mode is: S31, image correction is performed on the framed recognition area to obtain a corrected image;

[0054] Specifically, in the scanning of the house layered plan, due to printing and improper operation of users and other factors, the image scanning piece often has a small inclination or even a drawing inclination, so the house layered plan scanning piece needs to be image corrected before OCR recognition and corner point detection. Hough transformation is used to realize the house layered plan correction. First, the pixel point coordinates (X, Y) in the Cartesian coordinate system of the house layered plan are one-to-one mapped to the pixel point coordinates (p, q) in the polar coordinate space to obtain the straight line representation in the polar coordinate system of the house layered plan:

[0055] p = x cos q + y sin q

[0056] Where (X, Y) is the pixel point coordinate in the Cartesian coordinate system, p is the distance from the space origin of the house layered plan to the straight line, q is the angle between the line connecting the origin and the point on the straight line and the positive half of the X axis, q e [0, 2p].

[0057] Edge detection is performed on the house layered plan to obtain all possible polar coordinates (p, q) values of each edge point. These (p, q) values can be connected as a curve in the Hough transformation space. At this time, each edge point corresponds to a curve. When there are enough curves in the space that intersect at a (p, q) value, it is considered that the (p, q) value corresponds to a straight line in the image space position. At this time, the number of curve intersections corresponding to the (p, q) value in the Hough transformation space is recorded, and then the local maximum value of the number of intersections is obtained. Then, the maximum value points are reflected to the original image space to obtain the position of the straight line in the original image. Then, the inclination angle q of the house layered plan is obtained. According to the obtained inclination angle q, the house layered plan is corrected to the horizontal direction using a rotation correction matrix. The rotation correction matrix formula is as follows:

[0058]

[0059] S32, the corrected image is subjected to binaryzation processing to obtain a binaryzation image;

[0060] Specifically, for the text information recognition and corner point detection, the main useful information on the house layered plan is text and graphics. In order to simplify the image information and improve the speed and accuracy of OCR text recognition and corner point detection, the corrected house layered plan needs to be binarized to divide the picture into important foreground information and unimportant background information. The foreground information is defined as black, including text and graphics, and the background information is defined as white.

[0061] S33, skeletonize the binarized image to obtain a recognition area frame diagram.

[0062] Specifically, the important foreground information such as text and image is retained after the corrected house layered plan is binarized. However, the text or graphic lines in the house layered plan are usually too thick due to the size of the pen head and the non-uniform setting of the print line width, which may lead to poor recognition or detection accuracy due to too many pixels in the OCR text recognition and corner point detection process. Therefore, in order to reduce the recognition difficulty and improve the recognition and detection accuracy, the house layered plan after binarization needs to be further skeletonized. The house layered plan after skeletonization ensures that the skeleton center line of the text and graphics has certain connectivity and the line segment intersection does not distort.

[0063] S4, recognize and extract the text information in the recognition area frame diagram to obtain pixel position information, and detect and screen the corner points in the recognition area frame diagram to obtain screening information. The screening information and the pixel position information are paired to obtain a paired group;

[0064] The specific method is: S41, recognize and extract the text information in the recognition area frame diagram, and mark horizontally or vertically according to the direction of the text information to obtain recognition information. The pixel position information corresponding to the recognition information is saved;

[0065] Specifically, please refer to Figure 7The Tesseract open-source OCR engine is used as the technical support for text recognition and extraction. The main method for recognizing and extracting the text information in the housing hierarchical plan is to use the optical character recognition engine Tesseract-OCR as the bottom layer and the Pytesseract module packaged by using the Python language as the main method. Through the above engine and module method specially used for text recognition and extraction, a program script is written based on the Python program development language to realize the text recognition and extraction of the housing hierarchical plan, and the recognized text information is partially framed to provide conditions for subsequent corner point screening. In the process of text information recognition and extraction, semantic rules are set, the identified horizontal text information is set as identifier F=0, the identified vertical text information is set as identifier F=1, and the pixel position information corresponding to the identified information is saved.

[0066] S42, corner point detection is performed on the recognition area frame diagram, and after quantity calculation and local non-maximum suppression, corner point information is obtained;

[0067] Specifically, refer to Figure 8 The Harris corner point detection algorithm is used to realize the corner point detection and recognition in the housing hierarchical plan, and a program script is written by using the Python program development language. Specifically, semantic rules are set to specify that only the three types of acute angle, right angle and obtuse angle in the recognition area frame diagram are detected and recognized in the corner point detection process. Then, a horizontal and vertical difference operator is used to filter each pixel point in the housing hierarchical plan to obtain the element value required for Harris corner point detection. A 5*5 Gaussian filter template is then used to perform Gaussian smoothing on the obtained element to eliminate some unnecessary isolated points or convex points and reduce noise influence. Then, the number of detected corner points is calculated and local non-maximum suppression is performed. Finally, the local maximum value is obtained, i.e. the corner point information with the specified semantic features in the housing hierarchical plan is obtained.

[0068] S43, a local restriction area of the recognition area frame diagram is defined, the corner point information in the local restriction area is matched with the pixel position information, the corner points corresponding to the local restriction area are screened out and stored in a first corner point set, and the remaining corner points are stored in a second corner point set;

[0069] Specifically, the corner point information detected in the floor plan of the house has two types: one is the text corner point contained in the local box of the text information, and the other is the graphic corner point outside the local box of the text information. A program script is written based on the Python program development language, a semantic rule is set, the red box used for framing text in the OCR text recognition process is taken as a local restriction area, the coordinate information of the corner point is matched with the pixel coordinate information of the local restriction area, the corner points belonging to the corresponding local restriction area are screened out and stored in the corresponding corner point set, and then the corner points in the set are sorted according to the pixel X coordinate, only the corner point with the smallest X coordinate value is retained, and the remaining corner points are deleted. At this time, the corner points existing in each local restriction area are unique, and these unique corner points are stored in the first corner point set; at the same time, in the screening process, the corner points not belonging to the local restriction area are stored in the second corner point set.

[0070] S44, the corner points in the first corner point set are matched with the pixel position information to obtain a matched group.

[0071] The corner points in the first corner point set are matched with the pixel position information saved in step S41, if the pixel coordinates of the corner points are consistent with the pixel position coordinates of a certain text, it is considered that the corner point belongs to the field, and the corner point is matched with the text information and the text information identifier, and is saved as a different matched group.

[0072] S5, selecting line segment coordinate pairs based on the matched group to construct actual line segment coordinate pairs;

[0073] Specifically, S51, obtaining longitudinal line segment coordinate pairs containing distance information based on the matched group and the pixel position information.

[0074] Specifically, S511, sorting the corner points in the matched group according to the horizontal coordinates to obtain a first straight line set group.

[0075] Specifically, the X coordinates of the corner points in the matched group are sorted, a semantic rule is set, the corner point with the smallest X coordinate is taken as a base point, a threshold is set, and it is judged whether the change range of the X coordinate values of the remaining corner points is within the threshold. If yes, the corner points meeting the requirements are stored in a corresponding corner point set A1, then the remaining corner points that do not meet the requirements are re-sorted, and the above operation is continued to store all the corner points in the corresponding corner point sets (B1, C1, D1, E1, …) according to the requirements. At this time, the corner points in each set are considered to be points on a straight line in the set, wherein A1, B1, C1, D1, E1, … are the first straight line set group.

[0076] S512, sort the corner points in the first straight line set group according to the longitudinal coordinates, and store adjacent two corner points as a corner point pair in a first corner point pair set group;

[0077] Specifically, the corner points in the first straight line set group (A1, B1, C1, D1, E1,...) are sorted according to their pixel Y coordinate values, the corner point with the smallest Y coordinate value is taken as a base point, then adjacent two corner points are combined to form a corresponding corner point pair, and the corner point pair is stored in the first corner point pair set group.

[0078] S513, match the identification information with a vertical mark in the first corner point set with a corner point pair in the first corner point pair set group, to obtain a longitudinal line segment coordinate pair containing distance information;

[0079] Specifically, the corner points in the first corner point set of step S43 with the identifier F=1 in the matching group are operated, the corner points are matched with the corner point pairs in the first corner point pair set group according to the X and Y coordinate values of the corner points, a threshold range is set for the X coordinate of the corner point pair, if the X coordinate value of the corner point in the matching group is within the threshold range of the X coordinate of the corner point pair, the corner point pair meeting the requirements is extracted, then it is judged whether the Y coordinate value of the corner point in the matching group is between the two Y coordinate values in the extracted corner point pair and the sum of the distances between the two Y coordinate values is the shortest, if so, the text information in the matching group is included in the matched corner point pair, finally a longitudinal line segment coordinate pair containing distance information is obtained, for example: {(x1, y1), (x2, y2), distance information}.

[0080] S52, obtain a transverse line segment coordinate pair containing distance information based on the matching group and the pixel position information;

[0081] Specifically: S521, sort the corner points in the matching group according to the longitudinal coordinates to obtain a second straight line set group;

[0082] Specifically, the Y coordinates of the corner points in the matching group are sorted, a semantic rule is set, the corner point with the smallest Y coordinate is taken as a base point, a threshold is set, it is judged whether the variation range of the Y coordinate values of the remaining corner points is within the threshold, if so, the corner points meeting the requirements are stored in a corresponding corner point set A2, then the remaining corner points not meeting the requirements are re-sorted, the above operation is continued, and all the corner points are respectively stored in the corresponding corner point sets (B2, C2, D2, E2,...) according to the requirements. At this time, the corner points in each set are considered to be points on a straight line in the set, wherein A2, B2, C2, D2, E2,..., are the second straight line set group.

[0083] S522, sort the corner points in the second straight line set group according to the horizontal coordinates, and store the adjacent two corner points as a corner point pair in a second corner point pair set group;

[0084] Specifically, the semantic rules are set, the corner points in the second straight line set group (A2, B2, C2, D2, E2, …) are sorted according to the pixel X coordinate values, the corner point with the minimum X coordinate value is taken as a base point, then the adjacent two corner points are combined to form a corresponding corner point pair from the base point, and the corner point pair is stored in the second corner point pair set group.

[0085] S523, match the identification information with the horizontal marker in the first corner point set with the corner point pairs in the second corner point pair set group, and obtain the horizontal line segment coordinate pair containing distance information.

[0086] Specifically, the corner points in the pairing group with the identifier F=0 in the first corner point set in step S43 need to be operated, the corner points are matched with the corner point pairs in the second corner point pair set group according to the X and Y coordinate values, a threshold range is set for the Y coordinate of the corner point pair, if the Y coordinate value of the corner point in the pairing group is within the threshold range of the Y coordinate of the corner point pair, the corner point pair meeting the requirements is extracted, then it is judged whether the X coordinate value of the corner point in the pairing group is between the two X coordinate values in the extracted corner point pair and the sum of the distances between the two X coordinate values is the shortest, if so, the text information in the pairing group is included in the matched corner point pair, and finally the horizontal line segment coordinate pair containing distance information is obtained.

[0087] S53, combine the vertical line segment coordinate pair with the horizontal line segment coordinate pair, select the line segment coordinate pair according to the distance information of the vertical line segment coordinate pair and the horizontal line segment coordinate pair, define the coordinate pair coordinates, and construct the actual line segment coordinate pair.

[0088] Specifically, according to the relationship between the pixel X and Y coordinate values of different coordinate pairs and the corresponding distance information, the line segment coordinate pair is selected, the coordinate pair coordinates are defined, and the actual line segment coordinate pair is constructed.

[0089] Specifically, the pixel coordinate X value of the vertical line segment coordinate pair is sorted and screened, the coordinate pair with the minimum X coordinate value is taken as a base point, a threshold is set, it is judged whether the pixel coordinate X value of the remaining coordinate pairs is within the threshold variation range, if so, the coordinate pair meeting the requirements is stored in the corresponding vertical coordinate pair set group, then the above operation is continued for the coordinate pairs not meeting the requirements, and all vertical coordinate pairs are stored in the corresponding vertical coordinate pair set group according to the requirements.

[0090] Similarly, the pixel coordinate Y values of the horizontal line segment coordinate pairs are sorted and filtered, the coordinate pair with the smallest Y coordinate value is taken as a base point, a threshold value is set, and it is determined whether the pixel coordinate Y values of the remaining coordinate pairs are within the threshold value variation range, if yes, the coordinate pairs meeting the requirements are stored in the corresponding horizontal coordinate pair set group, and then the above operation is continuously performed on the coordinate pairs not meeting the requirements, and all horizontal coordinate pairs are respectively stored in the corresponding horizontal coordinate pair set group according to the requirements.

[0091] In the vertical coordinate pair set group, the coordinate pair set group with the smallest pixel X coordinate value is operated, the corner point coordinate with the smallest pixel X and Y coordinate values in the coordinate pair set group is defined as (0, 0), the X coordinates of the remaining corner points can be defined as 0, and then the Y coordinate values of the remaining corner points are defined in sequence according to the distance information in the coordinate pairs, for example:

[0092]

[0093] wherein X0, Y0, X1, Y1, X2 and Y2 represent the pixel coordinates of the corner points, and 1, 2 and 1 represent the distance information of the corresponding coordinate pairs.

[0094] In this process, the pixel Y coordinate value of the defined corner point is taken as a base point, a threshold value is set, and then all the corner point pixel coordinates in the horizontal and vertical coordinate pair set groups are traversed, it is determined whether the pixel Y coordinate value of the corner point is the same as or within the threshold value variation range of the pixel Y coordinate value of the base point, if yes, the Y coordinate of the corner point meeting the requirements is defined as the same value as the Y coordinate of the base point. At this time, the Y coordinate values of all coordinate pairs have been defined.

[0095] In all horizontal coordinate pair set groups, the X coordinate values of the remaining corner points are defined in sequence according to the distance information in the coordinate pairs, for example:

[0096]

[0097] wherein X0, X1 and X2 represent the pixel X coordinate values of the corner points, and 2, 3 and 1 represent the distance information of the corresponding coordinate pairs, and 0 in the left formula represents the defined Y coordinate value.

[0098] At this time, according to the relationship between the pixel X and Y coordinate values of different coordinate pairs and the corresponding distance information, the line segment coordinate pairs are selected, the coordinate pairs are defined, and the entire process of constructing the actual line segment coordinate pairs has been completed.

[0099] S6, saving the actual line segment coordinate pairs in a text form to obtain text information;

[0100] Specifically, the actual line segment coordinate pairs are labeled with serial numbers and saved and output in a text form.

[0101] S7, importing the text information into drawing software to automatically generate a drawing.

[0102] Specifically, the drawing software is a CAD system, and the text information is imported into the CAD system to automatically generate a drawing, specifically including: secondary development of the CAD system to create the function of reading the text information and automatically drawing in the form of a plug-in, and then importing the text information into the CAD system to automatically draw.

[0103] Beneficial effects: the real estate house layered plan is scanned into an electronic picture, which is used as an initial data source for vector automatic drawing; then a program script is written based on a Python program development language to frame the recognition area for subsequent OCR text recognition and Harris corner point detection on the scanned house layered plan, to eliminate some unnecessary text or table information on the house layered plan, to reduce unnecessary computer recognition workload, and to improve efficiency; image correction, image binarization processing and image skeletonization processing operations are performed on the framed recognition area to improve the accuracy and efficiency of subsequent recognition work; then OCR text recognition and Harris corner point detection are performed on the framed preprocessed house layered plan, and the detected corner points are then screened, corner point pairs are constructed, line segment coordinate pairs are constructed by combining the line segment length information extracted from the recognition and the corresponding corner point pairs, actual line segment coordinate pairs are constructed by customizing the line segment coordinate pairs, and finally the line segment coordinate pairs are saved and output in text form, imported into a CAD system, and vector automatic drawing of the real estate house layered plan is realized through a plug-in function. Since the vector automatic drawing process of the real estate house layered plan is realized based on a program, manual drawing in the traditional operation mode is avoided, human and material resources are reduced, and operation efficiency is improved.

[0104] The above only discloses a preferred embodiment of the real estate house layered plan vector automatic drawing method of the present application, and of course cannot limit the scope of the present application, and those skilled in the art can understand that all or part of the above-mentioned embodiments are implemented, and equivalent changes made according to the claims of the present application still belong to the scope covered by the present application.

Claims

1. A method for automatically generating vectorized floor plans of real estate buildings, characterized in that: The following steps are involved: Scan the floor plan of the house to get an electronic picture; Selecting a recognition area of ​​the electronic image based on the structure of the house; Performing image preprocessing on the recognition area to obtain a recognition area frame diagram; Identifying and extracting text information in the recognition area frame diagram to obtain pixel position information, detecting and filtering corner points in the recognition area frame diagram to obtain filtered information, and pairing the filtered information with the pixel position information to obtain a paired group; Selecting a line segment coordinate pair based on the pairing group, customizing the coordinate pair coordinates, and constructing an actual line segment coordinate pair; Saving the actual line segment coordinate pair in text form to obtain text information; Importing the text information into a drawing software to automatically generate a drawing; The specific method of selecting the identification area of ​​the electronic image based on the house structure is: Selecting the recognition area in the electronic image and the text and graphics in the recognition area; Eliminate the information that is not selected; The specific method of performing image preprocessing on the recognition area to obtain the recognition area frame diagram is: Performing image correction on the identified area selected by the frame to obtain a corrected image; performing binarization processing on the corrected image to obtain a binarized image; Performing skeleton processing on the binary image to obtain a recognition area frame; The specific method of identifying and extracting the text information in the recognition area frame diagram to obtain pixel position information, detecting and filtering the corner points in the recognition area frame diagram to obtain filtering information, and pairing the filtering information with the pixel position information to obtain the pairing group is as follows: Identify and extract text information in the recognition area frame diagram, mark it horizontally or vertically according to the display direction of the text information, obtain identification information, and save pixel position information corresponding to the identification information; Performing corner detection on the recognition area frame, and performing local non-maximum suppression after counting the number of corners to obtain corner information; defining a local restricted area of ​​the recognition area frame, matching the corner point information within the local restricted area with the pixel position information, filtering out corner points corresponding to the local restricted area and storing them in a first corner point set, and storing the remaining corner points in a second corner point set; Pairing the corner points in the first corner point set with the pixel position information to obtain a pairing group; The specific method of selecting a line segment coordinate pair based on the pairing group, customizing the coordinate pair coordinates, and constructing the actual line segment coordinate pair is: Obtaining a longitudinal line segment coordinate pair containing distance information based on the pairing group and the pixel position information; Obtaining a horizontal line segment coordinate pair containing distance information based on the pairing group and the pixel position information; The longitudinal line segment coordinate pair is combined with the transverse line segment coordinate pair, and a line segment coordinate pair is selected according to distance information between the longitudinal line segment coordinate pair and the transverse line segment coordinate pair, and the coordinate pair coordinates are customized to construct an actual line segment coordinate pair.

2. The method for automatically generating vectorized floor plans of real estate buildings according to claim 1, wherein: The specific method of obtaining the vertical line segment coordinate pair containing distance information based on the pairing group and the pixel position information is: Sort the corner points in the pairing group according to the horizontal coordinates to obtain a first straight line set group; Sort the corner points of the first straight line set according to their ordinates, and group two adjacent corner points into corner point pairs, which are stored in the first corner point pair set; The identification information with vertical marks in the first corner point set is matched with the corner point pairs in the first corner point pair set group to obtain a longitudinal line segment coordinate pair containing distance information.

3. The method for automatically generating vectorized floor plans of real estate buildings according to claim 2, wherein: The specific method of obtaining the horizontal line segment coordinate pair containing distance information based on the pairing group and the pixel position information is: Sort the corner points in the pairing group according to the vertical coordinates to obtain a second straight line set group; sorting the corner points of the second straight line set according to their horizontal coordinates, and forming corner point pairs from two adjacent corner points, and storing the pairs in the second corner point pair set; The identification information with horizontal marks in the first corner point set is matched with the corner point pairs in the second corner point pair set to obtain horizontal line segment coordinate pairs containing distance information.

Citation Information

Patent Citations

  • CAD house type drawing batch drawing method based on data table

    CN110569626A

  • Image recognition method based on deep learning

    CN111797748A