A sample room template matching method and device for a house type space, and an electronic device

By acquiring apartment layout data, generating rectangular spatial structures and calculating overlapping areas, and selecting the largest rectangular spatial structure for model room template matching, the problem of inaccurate similarity judgment between model room templates and apartment layouts in existing technologies is solved, achieving efficient and accurate furniture embedding and matching.

CN115512141BActive Publication Date: 2026-04-21GUANGDONG SANWEIJIA INFORMATION TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
GUANGDONG SANWEIJIA INFORMATION TECH CO LTD
Filing Date
2022-10-12
Publication Date
2026-04-21

AI Technical Summary

Technical Problem

Existing technologies cannot accurately consider the polygonal characteristics of the functional space structure of the apartment when determining whether the model room template is similar to the apartment layout, resulting in a large workload for designers and difficulty in properly embedding furniture.

Method used

By acquiring apartment layout data, extracting vertex coordinates, generating rectangular area spatial structure data, calculating overlapping areas, selecting the rectangular area spatial structure with the largest area for matching, and using a set of matching vectors for similar vector matching, the matching efficiency and accuracy are improved.

Benefits of technology

Reduce the workload of designers, improve the matching efficiency between apartment layouts and model room templates, ensure proper furniture integration, and reduce labor costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115512141B_ABST
    Figure CN115512141B_ABST
Patent Text Reader

Abstract

Embodiments of the present application provide a sample room template matching method and device for a house type space, electronic equipment and a storage medium, wherein the method comprises: obtaining house type space data; extracting vertex coordinates in the house type space data; obtaining rectangular region space structure data according to the vertex coordinates; obtaining an overlapping area between the house type space data and the rectangular region space structure data; and obtaining a sample room template corresponding to the house type space data according to the overlapping area and the rectangular region space structure data. By implementing the embodiments of the present application, the workload of designers can be reduced, suitable furniture can be embedded in the house type space structure, the house type space can be quickly matched to the sample room template, and the matching efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of home decoration technology, and more specifically, to a method, apparatus, electronic device, and computer-readable storage medium for matching templates of apartment layouts. Background Technology

[0002] Home decoration design software requires interior decoration design schemes for different spaces in different house types. The various single space structures in the house type (such as living room, dining room, bedroom, etc.) are mostly polygons with 90-degree interior angles. In order to quickly generate design schemes, designers will use the model room design method when designing the house type. This process requires providing designers with a model room template for reference. It is very important whether the structure of the model room template is similar to that of the functional space of the house type to be designed.

[0003] However, existing technologies for determining whether a model room template is similar to the apartment type to be designed usually judge whether the polygons of the spatial structure are similar. When making similarity measurements, they focus on the information of all the edges and vertices of the polygons. This is not suitable for judging the polygons of the functional spatial structure of the apartment type. The polygons of the functional spatial structure of the apartment type have many corridor edges and vertices. When arranging furniture, it will lead to the inability to embed suitable furniture, which will increase the workload of the designer. Summary of the Invention

[0004] The purpose of this application is to provide a method, device, electronic device, and computer-readable storage medium for matching model room templates of apartment spaces, which can reduce the workload of designers, facilitate the embedding of suitable furniture in the apartment space structure, and enable the apartment space to be quickly matched with the model room template, thereby improving the matching efficiency.

[0005] In a first aspect, embodiments of this application provide a method for matching model room templates for apartment layouts, the method comprising:

[0006] Obtain apartment layout data;

[0007] Extract the vertex coordinates from the apartment layout data;

[0008] The spatial structure data of the rectangular region is obtained based on the vertex coordinates;

[0009] Obtain the overlapping area between the apartment layout data and the rectangular area spatial structure data;

[0010] The model room template corresponding to the apartment layout data is obtained based on the overlapping area and the spatial structure data of the rectangular area.

[0011] In the above implementation process, by calculating the overlapping area between the apartment space data and the rectangular area space structure data, and matching the model room template based on the overlapping area, the workload of designers can be reduced, it is easier to embed suitable furniture in the apartment space structure, and the apartment space can be quickly matched with the model room template, thereby improving matching efficiency and reducing labor costs.

[0012] Further, the step of obtaining the spatial structure data of the rectangular region based on the vertex coordinates includes:

[0013] Extract the X and Y coordinates from the vertex coordinates;

[0014] Generate two-dimensional vertex coordinates based on the X coordinates and the Y coordinates;

[0015] The spatial structure data of the rectangular region is generated based on the two-dimensional vertex coordinates.

[0016] In the above implementation process, generating two-dimensional vertex coordinates based on the X and Y coordinates, and then generating rectangular region spatial structure data based on the two-dimensional vertex coordinates, can reduce errors and improve the accuracy of the rectangular region spatial structure data.

[0017] Further, the step of obtaining the model room template corresponding to the apartment space data based on the overlapping area and the rectangular area spatial structure data includes:

[0018] Select multiple rectangular spatial structures from the rectangular spatial structure data whose areas are equal to the overlapping areas;

[0019] The rectangular spatial structure with the largest area among the multiple rectangular spatial structures is selected as the main spatial structure;

[0020] The template room template is matched according to the main space structure.

[0021] In the above implementation process, selecting the largest rectangular spatial structure among multiple rectangular spatial structures to match the template room can effectively improve matching efficiency, reduce costs, and make the matching structure more accurate.

[0022] Furthermore, the step of matching the model room template according to the main space structure includes:

[0023] Calculate the matching vector of the main space structure;

[0024] Obtain the set of matching vectors corresponding to the model room template;

[0025] The matching vector is matched with each matching vector in the matching vector set to obtain the model room template.

[0026] In the above implementation process, similar vector matching is performed based on the matching vector of the main space structure and the matching vector set corresponding to the template, which can make the matching more accurate and save matching time.

[0027] Further, the step of calculating the matching vector of the main space structure includes:

[0028] Calculate the area of ​​the main space structure and use the area value as the first ratio;

[0029] Calculate the ratio of the length to the width of the main space structure, and use this ratio as the second ratio.

[0030] A two-dimensional vector is obtained based on the first ratio and the second ratio, and the two-dimensional vector is used as the matching vector.

[0031] In the above implementation process, based on the combination of the first ratio and the second ratio, the two-dimensional vector is used as the matching vector, so that the matching vector can contain information about the length, width and area of ​​the main space structure, thereby reducing errors.

[0032] Secondly, embodiments of this application also provide a model room template matching device for apartment layouts, the device comprising:

[0033] The acquisition module is used to acquire apartment layout data.

[0034] The extraction module is used to extract the vertex coordinates from the apartment layout data.

[0035] The data acquisition module is used to obtain rectangular area spatial structure data based on the vertex coordinates; it is also used to obtain the overlapping area between the apartment space data and the rectangular area spatial structure data.

[0036] The matching module is used to obtain the model room template corresponding to the apartment space data based on the overlapping area and the rectangular area spatial structure data.

[0037] In the above implementation process, by calculating the overlapping area between the apartment space data and the rectangular area space structure data, and matching the model room template based on the overlapping area, the workload of designers can be reduced, it is easier to embed suitable furniture in the apartment space structure, and the apartment space can be quickly matched with the model room template, thereby improving matching efficiency and reducing labor costs.

[0038] Furthermore, the data acquisition module is also used for:

[0039] Extract the X and Y coordinates from the vertex coordinates;

[0040] Generate two-dimensional vertex coordinates based on the X coordinates and the Y coordinates;

[0041] The spatial structure data of the rectangular region is generated based on the two-dimensional vertex coordinates.

[0042] In the above implementation process, generating two-dimensional vertex coordinates based on the X and Y coordinates, and then generating rectangular region spatial structure data based on the two-dimensional vertex coordinates, can reduce errors and improve the accuracy of the rectangular region spatial structure data.

[0043] Furthermore, the matching module is also used for:

[0044] Select multiple rectangular spatial structures from the rectangular spatial structure data whose areas are equal to the overlapping areas;

[0045] The rectangular spatial structure with the largest area among the multiple rectangular spatial structures is selected as the main spatial structure;

[0046] The template room template is matched according to the main space structure.

[0047] In the above implementation process, selecting the largest rectangular spatial structure among multiple rectangular spatial structures to match the template room can effectively improve matching efficiency, reduce costs, and make the matching structure more accurate.

[0048] Thirdly, an electronic device provided in this application includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the method described in any of the first aspects.

[0049] Fourthly, embodiments of this application provide a computer-readable storage medium storing instructions that, when executed on a computer, cause the computer to perform the method described in any of the first aspects.

[0050] Fifthly, embodiments of this application provide a computer program product that, when run on a computer, causes the computer to perform the method described in any of the first aspects.

[0051] Other features and advantages of this disclosure will be set forth in the following description, or some features and advantages may be inferred from the description or determined without doubt, or may be learned by practicing the techniques described above.

[0052] It can be implemented in accordance with the contents of the specification. The preferred embodiments of this application are described in detail below with reference to the accompanying drawings. Attached Figure Description

[0053] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments of this application will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0054] Figure 1 A flowchart illustrating the method for matching model room templates for apartment layouts provided in this application embodiment;

[0055] Figure 2 A schematic diagram illustrating the structural composition of the model room template matching device for apartment space provided in this application embodiment;

[0056] Figure 3 This is a schematic diagram of the structural composition of the electronic device provided in the embodiments of this application. Detailed Implementation

[0057] The technical solutions in the embodiments of this application will now be described with reference to the accompanying drawings.

[0058] It should be noted that similar reference numerals and letters in the following figures indicate similar items; therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures. Furthermore, in the description of this application, the terms "first," "second," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.

[0059] The specific embodiments of this application will be described in further detail below with reference to the accompanying drawings and examples. The following examples are used to illustrate this application, but are not intended to limit the scope of this application.

[0060] Example 1

[0061] Figure 1 This is a flowchart illustrating the method for matching model room templates for apartment layouts provided in this application embodiment. Figure 1 As shown, the method includes:

[0062] S1, obtain apartment layout data;

[0063] S2, extract the vertex coordinates from the apartment layout data;

[0064] S3, obtain the spatial structure data of the rectangular region based on the vertex coordinates;

[0065] S4, obtain the overlapping area between the apartment layout data and the rectangular area spatial structure data;

[0066] S5, obtain the model room template corresponding to the unit space data based on the overlapping area and rectangular area spatial structure data.

[0067] In the above implementation process, by calculating the overlapping area between the apartment space data and the rectangular area space structure data, and matching the model room template based on the overlapping area, the workload of designers can be reduced, it is easier to embed suitable furniture in the apartment space structure, and the apartment space can be quickly matched with the model room template, thereby improving matching efficiency and reducing labor costs.

[0068] In S1, the apartment layout data is obtained, which can be represented, for example, as follows: [

[0070] [[X1, Y1], [X2, Y2]],

[0071] [[X2, Y2], [X3, Y3]],

[0072] [[X3, Y3], [X4, Y4]],

[0073] [[X4, Y4], [X1, Y1]]

[0074] ].

[0075] In S2, all vertices are obtained: [X1, Y1], [X2, Y2], [X3, Y3], [X4, Y4].

[0076] Furthermore, S3 includes:

[0077] Extract the X and Y coordinates from the vertex coordinates;

[0078] Generate two-dimensional vertex coordinates based on the X coordinates and the Y coordinates;

[0079] Generate rectangular region spatial structure data based on two-dimensional vertex coordinates.

[0080] In the above implementation process, generating two-dimensional vertex coordinates based on the X and Y coordinates, and then generating rectangular region spatial structure data based on the two-dimensional vertex coordinates, can reduce errors and improve the accuracy of the rectangular region spatial structure data.

[0081] By extracting all X coordinates [X1, X2, X3, X4] and Y coordinates [Y1, Y2, Y3, Y4], a series of new points [Xi, Yj] are generated, where i and j take values ​​from 1 to 4. Combined with the original vertex coordinates, X coordinates, and Y coordinates, the spatial structure data of the rectangular region can be represented as: [

[0083] [[X1, Y1], [X1, Yj]],

[0084] [[X1, Yj], [Xi, Yj]],

[0085] [[Xi,Yj],[Xi,Y1]],

[0086] [[Xi,Y1],[X1,Y1]],

[0087] ].

[0088] In S4, based on the rectangular area spatial structure data, the overlapping area between the apartment space data and the rectangular area spatial structure data is calculated, and the rectangular area spatial structure data with the overlapping area equal to the area of ​​the rectangular area spatial structure data is retained.

[0089] Furthermore, S5 includes:

[0090] Select multiple rectangular spatial structures from the rectangular spatial structure data whose area is equal to the area of ​​the overlapping area;

[0091] The rectangular spatial structure with the largest area among multiple rectangular spatial structures is selected as the main spatial structure;

[0092] Match the template for the model room according to the main space structure.

[0093] In the above implementation process, selecting the largest rectangular spatial structure among multiple rectangular spatial structures to match the template room can effectively improve matching efficiency, reduce costs, and make the matching structure more accurate.

[0094] Furthermore, the steps for matching the model room template with the main space structure include:

[0095] Calculate the matching vector of the main space structure;

[0096] Obtain the set of matching vectors corresponding to the model room template;

[0097] The matching vector is matched with each matching vector in the matching vector set to obtain the template room template.

[0098] In the above implementation process, similar vector matching is performed based on the matching vector of the main space structure and the matching vector set corresponding to the template, which can make the matching more accurate and save matching time.

[0099] Furthermore, the steps for calculating the matching vector of the principal space structure include:

[0100] Calculate the area of ​​the main space structure and use the area value as the first ratio;

[0101] Calculate the ratio of the length to the width of the main space structure, and use this ratio as the second ratio.

[0102] A two-dimensional vector is obtained based on the first ratio and the second ratio, and this two-dimensional vector is used as the matching vector.

[0103] In the above implementation process, based on the combination of the first ratio and the second ratio, the two-dimensional vector is used as the matching vector, so that the matching vector can contain information about the length, width and area of ​​the main space structure, thereby reducing errors.

[0104] Take the one with the largest overlapping area to obtain the main space structure. Calculate the ratio of the area to length and the area to width of the main space structure to obtain a two-dimensional vector, such as [x, y], which is used as the matching vector for this apartment type.

[0105] Following the above method, the same operation is performed on the model room templates to be matched to obtain the matching vector set of the same functional space for each unit type. The unit type similarity problem is transformed into a vector similarity problem. Common vector similarity algorithms (such as Euclidean distance) can be used to perform similar vector matching to obtain the model room template. Specifically, the model room template obtained by similar vector matching through the vector similarity algorithm is the most similar model room template among all model room templates.

[0106] Example 2

[0107] In order to execute the method corresponding to Embodiment 1 above and achieve the corresponding functions and technical effects, a model room template matching device for apartment space is provided below, such as... Figure 2 As shown, the device includes:

[0108] Module 1 is used to acquire apartment layout data;

[0109] Extraction module 2 is used to extract vertex coordinates from the apartment layout data;

[0110] Data acquisition module 3 is used to obtain the spatial structure data of a rectangular area based on vertex coordinates; it is also used to obtain the overlapping area between the apartment layout data and the spatial structure data of the rectangular area.

[0111] Matching module 4 is used to obtain the model room template corresponding to the apartment space data based on the overlapping area and rectangular area spatial structure data.

[0112] In the above implementation process, by calculating the overlapping area between the apartment space data and the rectangular area space structure data, and matching the model room template based on the overlapping area, the workload of designers can be reduced, it is easier to embed suitable furniture in the apartment space structure, and the apartment space can be quickly matched with the model room template, thereby improving matching efficiency and reducing labor costs.

[0113] Furthermore, the data acquisition module 3 is also used for:

[0114] Extract the X and Y coordinates from the vertex coordinates;

[0115] Generate two-dimensional vertex coordinates based on the X and Y coordinates;

[0116] Generate rectangular region spatial structure data based on two-dimensional vertex coordinates.

[0117] In the above implementation process, generating two-dimensional vertex coordinates based on the X and Y coordinates, and then generating rectangular region spatial structure data based on the two-dimensional vertex coordinates, can reduce errors and improve the accuracy of the rectangular region spatial structure data.

[0118] Furthermore, the matching module 4 is also used for:

[0119] Select multiple rectangular spatial structures from the rectangular spatial structure data whose area is equal to the area of ​​the overlapping area;

[0120] The rectangular spatial structure with the largest area among multiple rectangular spatial structures is selected as the main spatial structure;

[0121] Match the template for the model room according to the main space structure.

[0122] In the above implementation process, selecting the largest rectangular spatial structure among multiple rectangular spatial structures to match the template room can effectively improve matching efficiency, reduce costs, and make the matching structure more accurate.

[0123] Furthermore, the matching module 4 is also used for:

[0124] Calculate the matching vector of the main space structure;

[0125] Obtain the set of matching vectors corresponding to the model room template;

[0126] The matching vector is matched with each matching vector in the matching vector set to obtain the template room template.

[0127] Furthermore, the matching module 4 is also used for:

[0128] Calculate the area of ​​the main space structure and use the area value as the first ratio;

[0129] Calculate the ratio of the length to the width of the main space structure, and use this ratio as the second ratio.

[0130] A two-dimensional vector is obtained based on the first ratio and the second ratio, and this two-dimensional vector is used as the matching vector.

[0131] The above-mentioned model room template matching device for apartment layouts can implement the method of Embodiment 1. The options in Embodiment 1 are also applicable to this embodiment, and will not be described in detail here.

[0132] The remaining contents of this embodiment can be referred to the contents of Embodiment 1 above, and will not be repeated in this embodiment.

[0133] Example 3

[0134] This application provides an electronic device, including a memory and a processor. The memory stores a computer program, and the processor runs the computer program to enable the electronic device to perform the model room template matching method for apartment layout space according to Embodiment 1.

[0135] Alternatively, the aforementioned electronic device may be a server.

[0136] Please see Figure 3 , Figure 3 This is a schematic diagram illustrating the structural composition of an electronic device provided in an embodiment of this application. The electronic device may include a processor 31, a communication interface 32, a memory 33, and at least one communication bus 34. The communication bus 34 is used to enable direct communication between these components. In this embodiment, the communication interface 32 is used for signaling or data communication with other node devices. The processor 31 may be an integrated circuit chip with signal processing capabilities.

[0137] The processor 31 described above can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor can be a microprocessor, or the processor 31 can be any conventional processor.

[0138] The memory 33 may be, but is not limited to, random access memory (RAM), read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), etc. The memory 33 stores computer-readable instructions. When these computer-readable instructions are executed by the processor 31, the device can perform the aforementioned operations. Figure 1The various steps involved in the method implementation examples.

[0139] Optionally, the electronic device may also include a storage controller and an input / output unit. The memory 33, storage controller, processor 31, peripheral interface, and input / output unit are electrically connected directly or indirectly to each other to achieve data transmission or interaction. For example, these components can be electrically connected to each other via one or more communication buses 34. The processor 31 is used to execute executable modules stored in the memory 33, such as software function modules or computer programs included in the device.

[0140] Input / output units are used to enable users to create tasks and set optional start periods or preset execution times for those tasks, facilitating user-server interaction. Input / output units can be, but are not limited to, a mouse and keyboard.

[0141] Understandable. Figure 3 The structure shown is for illustrative purposes only; the electronic device may also include components that are more advanced than those shown. Figure 3 The more or fewer components shown, or having the same Figure 3 The different configurations shown. Figure 3 The components shown can be implemented using hardware, software, or a combination thereof.

[0142] In addition, this application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the model room template matching method for apartment layouts in Embodiment 1.

[0143] This application also provides a computer program product that, when run on a computer, causes the computer to perform the method described in the method embodiment.

[0144] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can also be implemented in other ways. The apparatus embodiments described above are merely illustrative; for example, the flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions marked in the blocks may occur in a different order than those marked in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram and / or flowchart, and combinations of blocks in block diagrams and / or flowcharts, can be implemented using dedicated hardware-based apparatus that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.

[0145] In addition, the functional modules in the various embodiments of this application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.

[0146] If the aforementioned functions are implemented as software functional modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, external hard drives, ROM, RAM, magnetic disks, or optical disks.

[0147] The above description is merely an embodiment of this application and is not intended to limit the scope of protection of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application. It should be noted that similar reference numerals and letters in the following figures indicate similar items; therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.

[0148] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

[0149] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

Claims

1. A method for matching templates of a sample room of a house type space, characterized in that, The method includes: Obtain apartment layout data; Extract the vertex coordinates from the apartment layout data; The spatial structure data of the rectangular region is obtained based on the vertex coordinates; Obtain the overlapping area between the apartment layout data and the rectangular area spatial structure data; Based on the overlapping area and the spatial structure data of the rectangular area, a model room template corresponding to the apartment layout data is obtained; The step of obtaining the model room template corresponding to the apartment space data based on the overlapping area and the rectangular area spatial structure data includes: Select multiple rectangular spatial structures from the rectangular spatial structure data whose areas are equal to the overlapping areas; The rectangular spatial structure with the largest area among the multiple rectangular spatial structures is selected as the main spatial structure; Match the model room template according to the main space structure; The step of matching the model room template according to the main space structure includes: Calculate the matching vector of the main space structure; Obtain the set of matching vectors corresponding to the model room template; The matching vector is matched with each matching vector in the matching vector set to obtain the model room template. The step of calculating the matching vector of the main space structure includes: Calculate the area of ​​the main space structure and use the area value as the first ratio; Calculate the ratio of the length to the width of the main space structure, and use this ratio as the second ratio. A two-dimensional vector is obtained based on the first ratio and the second ratio, and the two-dimensional vector is used as the matching vector; The step of obtaining the spatial structure data of the rectangular region based on the vertex coordinates includes: Extract the X and Y coordinates from the vertex coordinates; Generate two-dimensional vertex coordinates based on the X coordinates and the Y coordinates; The spatial structure data of the rectangular region is generated based on the two-dimensional vertex coordinates.

2. A model room template matching device for a house type space, characterized by, The device includes: The acquisition module is used to acquire apartment layout data. The extraction module is used to extract the vertex coordinates from the apartment layout data. The data acquisition module is used to obtain rectangular area spatial structure data based on the vertex coordinates; it is also used to obtain the overlapping area between the apartment space data and the rectangular area spatial structure data. The matching module is used to obtain the model room template corresponding to the apartment space data based on the overlapping area and the rectangular area spatial structure data; The matching module is also used for: Select multiple rectangular spatial structures from the rectangular spatial structure data whose areas are equal to the overlapping areas; The rectangular spatial structure with the largest area among the multiple rectangular spatial structures is selected as the main spatial structure; Match the model room template according to the main space structure; Calculate the matching vector of the main space structure; Obtain the set of matching vectors corresponding to the model room template; The matching vector is matched with each matching vector in the matching vector set to obtain the model room template. Calculate the area of ​​the main space structure and use the area value as the first ratio; Calculate the ratio of the length to the width of the main space structure, and use this ratio as the second ratio. A two-dimensional vector is obtained based on the first ratio and the second ratio, and the two-dimensional vector is used as the matching vector; The data acquisition module is also used for: Extract the X and Y coordinates from the vertex coordinates; Generate two-dimensional vertex coordinates based on the X coordinates and the Y coordinates; The spatial structure data of the rectangular region is generated based on the two-dimensional vertex coordinates.

3. An electronic device, comprising: The device includes a memory and a processor, wherein the memory stores a computer program and the processor runs the computer program to enable the electronic device to perform the model room template matching method for apartment layouts according to claim 1.

4. A computer-readable storage medium, characterized in that, It stores a computer program, which, when executed by a processor, implements the model room template matching method for apartment layouts as described in claim 1.

Citation Information

Patent Citations

  • Building roof model construction method and device, electronic equipment and storage medium

    CN112989469A