Home automatic layout method and device and storage medium

By filtering feasible product sets and performing efficient sorting optimization in the automatic home layout process, the problem of low generation efficiency and slow response speed in existing technologies is solved, enabling the generation of fast and reasonable furniture layout schemes and improving the user experience.

CN122065377APending Publication Date: 2026-05-19QINGDAO HAIER TECH +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511994461.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-26
Publication Date
2026-05-19

AI Technical Summary

Technical Problem

Existing home layout automation technologies are inefficient and slow to respond, failing to meet consumers' real-time interaction needs. Furthermore, they lack a deep understanding of the spatial structure of the apartment and the feasibility of physical furniture placement, leading to user experience disruptions.

Method used

By acquiring apartment layout information and product information, geometric calculations are performed based on necessary layout rules to filter out feasible home furnishing product sets, and a comprehensive ranking model is constructed to rank the products. Finally, the set of layable areas is used as the search space for layout optimization, and a layout scheme that meets the preset cost threshold is output.

Benefits of technology

It significantly improves the speed and efficiency of generating automatic home layout solutions, ensuring the rationality of the layout and the timeliness of the response, thereby enhancing the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122065377A_ABST
    Figure CN122065377A_ABST
Patent Text Reader

Abstract

The invention discloses an automatic home layout method and device and a storage medium, and relates to the technical field of artificial intelligence, and the method comprises the steps: obtaining the house type structure information of a target space and the commodity information of candidate home commodities, and then determining an effective layout region of each candidate home commodity, screening out a feasible home commodity set from the candidate home commodities based on the effective layout area; based on a preset sorting strategy, sorting the commodities in the feasible household commodity set to obtain a sorting result; determining a to-be-arranged target commodity combination from the feasible household commodity set according to a sorting result; and performing layout optimization on the to-be-arranged target commodity combination by taking the layout region set as a search space, and outputting a layout scheme meeting a preset cost threshold value. According to the method and the device, the problems of low generation efficiency and slow response speed of the automatic home layout scheme in the prior art are solved, and the technical effect of remarkably improving the scheme generation speed on the premise of ensuring the layout rationality is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of artificial intelligence technology, and in particular to a method, device and storage medium for automatic home layout. Background Technology

[0002] With the deep integration of artificial intelligence technology into the residential sector, smart home design platforms targeting consumers (ToC) are gradually becoming more widespread. Among them, automatic home layout is a core function, aiming to use algorithms to automatically generate reasonable furniture placement schemes based on the user's apartment layout and preferences, thereby lowering the design threshold for users and enhancing their personalized experience.

[0003] Existing automated layout technologies primarily follow two technical paths. One path originates from professional design tools geared towards businesses (ToB), which typically employ complex optimization algorithms to comprehensively consider all layout rules in a single calculation, generating a solution through multiple iterations. While this method can produce high-quality layouts, its computational complexity is extremely high, resulting in slow response times and failing to meet consumers' urgent need for real-time interaction. The other path borrows from product recommendation systems in e-commerce, focusing on filtering products based on users' historical behavior. However, it lacks a deep understanding of the apartment's spatial structure and the feasibility of furniture placement, easily recommending products that cannot be effectively placed in the actual space, leading to an interrupted user experience. Summary of the Invention

[0004] This application provides a method, device, and storage medium for automatic home layout, which solves the problems of low efficiency and slow response speed in the generation of automatic home layout schemes in the prior art, and achieves the technical effect of significantly improving the scheme generation speed while ensuring the rationality of the layout.

[0005] This application provides a method for automatic home layout, including: Obtain information on the floor plan of the target space and product information for candidate home furnishing items; Based on the apartment layout information, the product information, and the preset necessary layout rules, the effective layout area of ​​each candidate home furnishing product is determined, and a feasible home furnishing product set is selected from the candidate home furnishing products based on the effective layout area. Based on a preset sorting strategy, the products in the feasible home furnishing product set are sorted to obtain the sorting result; Based on the sorting results, determine the target product combination to be laid out from the feasible home furnishing product set; Using the set of layable regions as the search space, the layout of the target product combination to be laid out is optimized, and a layout scheme that meets the preset cost threshold is output.

[0006] According to the automatic home layout method provided in this application, the method involves determining the effective layoutable area for each candidate home furnishing product based on the apartment structure information, the product information, and preset necessary layout rules, and then selecting a feasible home furnishing product set from the candidate home furnishing products based on the effective layoutable area. This includes: scoring the rules from a predefined layout rule library using both necessity and geometric modeling difficulty dimensions, selecting only rules with a necessity score higher than a first threshold and a geometric modeling difficulty score lower than a second threshold as necessary layout rules; converting the necessary layout rules into geometric operations on the geometric elements in the apartment structure information; determining whether each candidate home furnishing product has an effective layoutable area within the target space based on the result of the geometric operations; and including candidate home furnishing products with effective layoutable areas into the feasible home furnishing product set.

[0007] According to the automatic home layout method provided in this application, the step of converting the necessary layout rules into geometric operations on the geometric elements in the apartment structure information includes: converting the necessary layout rules into Boolean operations on the wall lines, door and window positions, or space bottom polygons in the apartment structure information.

[0008] According to the automatic home layout method provided in this application, the step of determining whether each candidate home furnishing product has a valid layoutable area in the target space based on the result of the geometric calculation includes: performing an intersection operation on the minimum outer rectangle of the candidate home furnishing product and the available ground polygon in the apartment structure information to obtain an initial candidate area; if the candidate home furnishing product attribute includes a label indicating that the back panel must be against a wall, then calculating the minimum distance between the projected line of the product's back panel and each wall line, and retaining the initial candidate area segment with a minimum distance of zero from the initial candidate area; performing a window conflict check on the initial candidate area segment and the projection of door and window openings, and removing segments whose intersection area accounts for a proportion greater than a third threshold; for the initial candidate area segment that passes the window conflict check, generating an equidistant offset line along the main orientation of the room according to the depth dimension marked on the product, and extracting a closed area with an offset distance equal to the depth dimension as the valid layoutable area of ​​the product.

[0009] According to the automatic home layout method provided in this application, the step of sorting the products in the feasible home furnishing product set based on a preset sorting strategy to obtain a sorting result includes: constructing a comprehensive sorting model, wherein the input features of the comprehensive sorting model include at least: user profile features, product attribute features of the feasible home furnishing product set, and apartment type attribute features of the target space; using the comprehensive sorting model to score each product in the feasible home furnishing product set to obtain a score result; and sorting the feasible home furnishing product set according to the score result to generate a sorting result.

[0010] According to the automatic home layout method provided in this application, the step of determining the target product combination to be laid out from the feasible home product set according to the sorting result includes: receiving a product selection instruction issued by a user based on the sorting result, and determining one or more products selected by the user as the target product combination to be laid out; or, automatically selecting one or more products from the sorting result in descending order according to preset product category configuration rules to form the target product combination to be laid out.

[0011] According to the automatic home layout method provided in this application, the method optimizes the layout of the target product combination to be laid out using a set of layable areas as the search space and outputs a layout scheme that meets a preset cost threshold. The method includes: constructing a comprehensive cost function for quantitatively evaluating the layout scheme; the comprehensive cost function is constructed based on one or more predefined optimization layout rules, each optimization layout rule corresponding to a sub-cost function for measuring the degree to which it is violated; iteratively generating new candidate layout schemes within the set of layable areas by executing one or more preset layout transformation actions; calculating the comprehensive cost function value of each candidate layout scheme; and selecting candidate layout schemes with comprehensive cost function values ​​lower than the preset cost threshold from the iterative process using a greedy search strategy, as the final output layout scheme.

[0012] This application also provides a home automation layout device, comprising: The information acquisition module is used to acquire the apartment layout information of the target space and the product information of the candidate home furnishing products; The filtering module is used to determine the effective layout area of ​​each candidate home furnishing product based on the apartment structure information, the product information and the preset necessary layout rules, and to filter out a set of feasible home furnishing products from the candidate home furnishing products based on the effective layout area. The sorting module is used to sort the products in the feasible home furnishing product set based on a preset sorting strategy to obtain the sorting result; The product combination module is used to determine the target product combination to be arranged from the feasible home furnishing product set based on the sorting result; The layout optimization module is used to optimize the layout of the target product combination to be laid out using the set of layable areas as the search space, and output a layout scheme that meets a preset cost threshold.

[0013] This application also provides an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to execute the home layout method as described above through the computer program.

[0014] This application also provides a computer-readable storage medium comprising a stored program, wherein the program, when executed, implements any of the above-described automatic home layout methods.

[0015] This application also provides a computer program product, including a computer program that, when executed by a processor, implements any of the above-described automatic home layout methods.

[0016] The home layout automatic layout method, device, and storage medium provided in this application pre-select candidate products based on necessary layout rules during the initial layout phase, eliminating a large number of products that do not meet the rigid constraints of space. This allows subsequent sorting and optimization operations to be performed only on a highly feasible set of products, significantly reducing the problem's scale and thus greatly improving the overall layout solution generation efficiency. Using the set of layable areas as the search space for subsequent layout optimization means that the optimization algorithm does not need to blindly search the vast and ineffective entire apartment space, but instead performs fine-tuning directly within a pre-calculated, finite area that conforms to basic rules. This design greatly reduces the computational complexity of the layout optimization algorithm, avoids a large amount of invalid computation, and enables the system to quickly converge to a high-quality layout solution. Attached Figure Description

[0017] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0018] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0019] Figure 1 This is a schematic diagram of the hardware environment for an automatic home layout method according to an embodiment of this application; Figure 2 This is one of the flowcharts illustrating the automatic home layout method provided in this application; Figure 3 This is a schematic diagram illustrating the core strategy for classifying and selecting layout rules provided in this application; Figure 4 This is a schematic diagram of the iterative mechanism of the layout optimization stage provided in this application; Figure 5 This is the second flowchart illustrating the automatic home layout method provided in this application; Figure 6 This is a structural schematic diagram of the automatic home layout device provided in this application; Figure 7 This is a schematic diagram of the structure of the electronic device provided in this application. Detailed Implementation

[0020] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.

[0021] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0022] According to one aspect of the embodiments of this application, a method for automatic home layout is provided. This method is widely applicable to whole-house intelligent digital control application scenarios such as smart homes, smart home ecosystems, smart home device ecosystems, and intelligence house ecosystems. Optionally, in this embodiment, the above-mentioned automatic home layout method can be applied to, for example... Figure 1 The hardware environment shown consists of terminal device 102 and server 104. For example... Figure 1 As shown, server 104 is connected to terminal device 102 via a network and can be used to provide services (such as application services) to the terminal or clients installed on the terminal. A database can be set up on the server or independently of the server to provide data storage services for server 104. Cloud computing and / or edge computing services can be configured on the server or independently of the server to provide data processing services for server 104.

[0023] The aforementioned network may include, but is not limited to, at least one of the following: wired network, wireless network. The aforementioned wired network may include, but is not limited to, at least one of the following: wide area network, metropolitan area network, local area network. The aforementioned wireless network may include, but is not limited to, at least one of the following: Wi-Fi (Wireless Fidelity), Bluetooth. The terminal device 102 may not be limited to PC, mobile phone, tablet computer, smart air conditioner, smart range hood, smart refrigerator, smart oven, smart stove, smart washing machine, smart water heater, smart washing equipment, smart dishwasher, smart projector, smart TV, smart clothes rack, smart curtains, smart audio-visual equipment, smart socket, smart speaker, smart speaker box, smart fresh air equipment, smart kitchen and bathroom equipment, smart bathroom equipment, smart robot vacuum cleaner, smart window cleaning robot, smart mopping robot, smart air purifier, smart steam oven, smart microwave oven, smart water heater, smart air purifier, smart water dispenser, smart door lock, etc.

[0024] Figure 2 This is one of the flowcharts illustrating the automatic home layout method provided in this application, which includes the following steps: S210: Obtain the floor plan information of the target space and the product information of the candidate home furnishing products.

[0025] Specifically, when acquiring the floor plan information of the target space, the system extracts key geometric and semantic data from the floor plan uploaded by the user or from the online floor plan database. This information includes not only the wall outlines formed by a series of continuous coordinate points and the locations of door and window openings marked with width and height, but also the annotations of functional areas of the space and the main orientation angle of the room. When acquiring product information of candidate home furnishing products, the system reads the digital attributes of each product from the product database. These attributes include at least the product's three-dimensional dimensions, the product's functional category, and specific attribute identifiers used for layout calculations, such as a "back panel dependency identifier" that indicates whether its back panel must be placed against a wall.

[0026] By acquiring the aforementioned structured and digitized spatial and commodity information, a precise and complete data foundation is provided for subsequent automated calculations based on geometric rules, thereby ensuring the accuracy and reliability of layout judgments.

[0027] S220: Based on the apartment layout information, the product information, and the preset necessary layout rules, determine the effective layout area for each candidate home furnishing product, and select a feasible home furnishing product set from the candidate home furnishing products based on the effective layout area.

[0028] According to the automatic home layout method provided in this application, the method involves determining the effective layoutable area for each candidate home furnishing product based on the apartment structure information, the product information, and preset necessary layout rules, and then selecting a feasible home furnishing product set from the candidate home furnishing products based on the effective layoutable area. This includes: scoring the rules from a predefined layout rule library using both necessity and geometric modeling difficulty dimensions, selecting only rules with a necessity score higher than a first threshold and a geometric modeling difficulty score lower than a second threshold as necessary layout rules; converting the necessary layout rules into geometric operations on the geometric elements in the apartment structure information; determining whether each candidate home furnishing product has an effective layoutable area within the target space based on the result of the geometric operations; and including candidate home furnishing products with effective layoutable areas into the feasible home furnishing product set.

[0029] Specifically, the layout rule library contains a variety of pre-stored layout rules, such as "the back of the cabinet must be against a wall," "furniture must not severely obstruct doors and windows," "the kitchen triangular traffic flow principle must be met," and "the TV viewing angle should cover the main seating area." The system quantitatively evaluates and filters these rules based on two dimensions: "necessity" and "geometric modeling difficulty."

[0030] Taking the rule "the back of the cabinet must be against the wall" as an example, it scores highly in the necessity dimension (because it is a basic requirement to ensure the stability and functionality of the furniture), while scoring low in the geometric modeling difficulty dimension (because it can be easily converted into calculating the minimum distance between the projection line of the cabinet back panel and the wall line, which is easy to implement through Boolean operations). Conversely, although the "kitchen triangle circulation principle" is highly necessary, its geometric modeling is complex, involving path optimization between multiple dynamic points, resulting in a high modeling difficulty score, and therefore it is not selected at this stage. The system ultimately selects only a few rules with high necessity and low modeling difficulty, such as "must be against the wall" and "avoid door and window openings," as the necessary layout rules for this stage.

[0031] The system translates these rules into specific geometric operations. For example, to execute the "against a wall" rule, it calculates the minimum distance between the furniture's back panel line and all wall lines; to execute the "avoid windows" rule, it performs an intersection check between the furniture's projection and the projections of door and window openings. By performing these lightweight geometric operations, the system can quickly determine whether there is a valid placement area for each candidate piece of furniture and include furniture with such areas in the feasible home furnishing product set.

[0032] like Figure 3A two-dimensional coordinate system visually illustrates the core strategy for classifying and selecting layout rules in this invention. The coordinate system uses "easy to model geometrically" to "difficult to model geometrically" as the horizontal axis and "necessary rules" to "recommended rules" as the vertical axis. Within this framework, different types of rules are clearly defined: for example, "cabinet back against a wall" and "cabinet side does not block windows" are categorized as "necessary rules" and "easy to model geometrically"; while "TV viewing cone angle" is considered a "recommended rule" and "difficult to model geometrically," and "kitchen triangular traffic flow" belongs to "necessary rules" but "difficult to model geometrically." This classification method allows the system to prioritize and apply rules located in the upper left corner of the chart—those with "high necessity" and "easy to model geometrically"—during the product recall stage of layout, quickly filtering feasible products through efficient geometric calculations; other rules are processed in subsequent stages, thus achieving a balance between computational efficiency and layout quality.

[0033] By introducing a two-dimensional rule-based filtering mechanism based on "necessity" and "geometric modeling difficulty," the system can intelligently identify and prioritize rigid rules that play a decisive role in layout feasibility and have low computational overhead. This allows the system to efficiently filter out a large number of obviously unsuitable items in the early stages of the layout process, greatly reducing the solution space size that needs to be processed in subsequent sorting and optimization stages. This method directly avoids complex calculations for invalid item combinations from the source, thereby significantly improving the overall efficiency of layout scheme generation and ensuring the timeliness of system response.

[0034] According to the automatic home layout method provided in this application, the step of converting the necessary layout rules into geometric operations on the geometric elements in the apartment structure information includes: converting the necessary layout rules into Boolean operations on the wall lines, door and window positions, or space bottom polygons in the apartment structure information.

[0035] Specifically, the system transforms abstract, necessary layout rules into computable geometric Boolean operations. For example, for the rule "cabinets must be against a wall," the system first extracts vector data of all wall lines from the floor plan information and generates the projection lines of the cabinet back panel. Then, it performs a specific Boolean operation to calculate the minimum distance between lines, retaining only cabinet positions that are zero distance from at least one wall. For the rule "avoid doors and windows," the system obtains the boundary polygons of door and window openings from the floor plan information and performs a Boolean operation of "polygon intersection" with the horizontal projection polygons of the furniture, automatically eliminating placement options with excessive overlap with the openings. When determining the "initial usable floor area," the system performs a "polygon difference" operation between the entire room's floor polygon and the wall outline polygons, precisely deducting the area occupied by the walls to obtain the truly usable floor area.

[0036] By transforming qualitative layout rules into precise, programmable geometric Boolean operations, the feasibility of furniture placement is objectively and automatically determined. This method avoids reliance on human experience or vague judgments, greatly improving the accuracy and reliability of the layout selection process. Simultaneously, it provides the computer with clear and efficient execution instructions, laying a solid foundation for automation in subsequent processes.

[0037] According to the automatic home layout method provided in this application, the step of determining whether each candidate home furnishing product has a valid layoutable area in the target space based on the result of the geometric calculation includes: performing an intersection operation on the minimum outer rectangle of the candidate home furnishing product and the available ground polygon in the apartment structure information to obtain an initial candidate area; if the candidate home furnishing product attribute includes a label indicating that the back panel must be against a wall, then calculating the minimum distance between the projected line of the product's back panel and each wall line, and retaining the initial candidate area segment with a minimum distance of zero from the initial candidate area; performing a window conflict check on the initial candidate area segment and the projection of door and window openings, and removing segments whose intersection area accounts for a proportion greater than a third threshold; for the initial candidate area segment that passes the window conflict check, generating an equidistant offset line along the main orientation of the room according to the depth dimension marked on the product, and extracting a closed area with an offset distance equal to the depth dimension as the valid layoutable area of ​​the product.

[0038] Specifically, taking the selection of a bookcase as an example, the system first calculates the minimum bounding rectangle of the bookcase and performs a Boolean operation on its intersection with the available floor polygon in the living room, resulting in a preliminary rectangular area where the bookcase can theoretically be placed. Since the bookcase's product attributes indicate that "the back panel must be against a wall," the system then calculates the minimum distance between the bookcase's back panel projection line and the four walls of the living room, further trimming the initial rectangular area to retain only those strip-shaped areas that are flush with the walls. Next, the system performs conflict detection on these strip-shaped areas and the projections of the living room window openings, eliminating sections that would severely obstruct the windows. Finally, for the sections that pass the detection, the system generates a parallel line equidistantly offset from the wall into the room based on the bookcase's marked depth dimensions. The closed strip-shaped area formed by this parallel line and the boundary of the strip-shaped areas is the final effective layout area for the bookcase. If this area is not empty, the bookcase is included in the feasible home furnishing product set.

[0039] Through a series of sequential and refined geometric screening operations, the coarse feasible space is gradually converged into a precise layoutable region that meets multiple rigid physical constraints. This ensures that each product and its corresponding layout position selected in the end are highly feasible at the physical level, thus providing a high-quality solution space input for the subsequent layout optimization stage. This fundamentally avoids a large number of invalid attempts by the subsequent algorithm and improves the overall efficiency and practicality of the solution generation.

[0040] S230: Based on a preset sorting strategy, sort the products in the feasible home furnishing product set to obtain the sorting result.

[0041] According to the automatic home layout method provided in this application, the step of sorting the products in the feasible home furnishing product set based on a preset sorting strategy to obtain a sorting result includes: constructing a comprehensive sorting model, wherein the input features of the comprehensive sorting model include at least: user profile features, product attribute features of the feasible home furnishing product set, and apartment type attribute features of the target space; using the comprehensive sorting model to score each product in the feasible home furnishing product set to obtain a score result; and sorting the feasible home furnishing product set according to the score result to generate a sorting result.

[0042] Specifically, when a user is arranging the layout of a small living room, the system first obtains a product set containing dozens of feasible furniture items through the aforementioned steps. At this point, the sorting module is activated. Its comprehensive sorting model takes into account the following input features: user profile features (such as a preference for modern minimalist style reflected in the user's browsing history), product attribute features of the feasible product set (such as the size, style, sales volume, and price of each sofa and coffee table), and apartment layout attribute features of the target space (such as the actual area, length-to-width ratio, and door / window location of the living room). The model performs a comprehensive weighted calculation on these multi-dimensional features, outputting a score for each product. For example, a compact, modern, and popular three-seater sofa will receive a high score, while a sofa that is too large or has a classic European style will receive a lower score. Finally, the system sorts all feasible products in descending order based on this score, generating the ranking result.

[0043] By intelligently sorting data by integrating user preferences, product characteristics, and spatial constraints, the system prioritizes displaying options from a large pool of feasible products that are most likely to meet user needs and address space limitations. This significantly improves the accuracy of recommendations and user experience, helping users quickly focus on high-quality choices, effectively reducing decision-making costs, and ensuring that subsequent layout optimization phases deal with carefully selected high-value product combinations.

[0044] S240: Based on the sorting results, determine the target product combination to be laid out from the feasible home furnishing product set.

[0045] According to the automatic home layout method provided in this application, the step of determining the target product combination to be laid out from the feasible home product set according to the sorting result includes: receiving a product selection instruction issued by a user based on the sorting result, and determining one or more products selected by the user as the target product combination to be laid out; or, automatically selecting one or more products from the sorting result in descending order according to preset product category configuration rules to form the target product combination to be laid out.

[0046] Specifically, in a scenario where a user is arranging a bedroom layout, the system displays a sorted list of feasible items. The user can directly select their preferred double bed, two bedside tables, and a wardrobe from the list. The system receives this selection instruction and identifies these four items as the target combination for the layout. Alternatively, the system can automatically act on the sorting results based on preset "basic bedroom configuration" rules: for example, selecting the highest-ranked double bed, the highest-ranked wardrobe, and the top two bedside tables to automatically create a complete target combination for the layout.

[0047] This embodiment provides a flexible and intelligent method for target determination. It respects both the user's subjective choices and personalized intentions, while also offering automated and efficient configuration capabilities. This design effectively balances user control with system efficiency, ensuring that subsequent layout optimization stages can be based on a clear and reasonable set of products, thus improving the smoothness of the entire process and the user experience.

[0048] S250: Using the set of layable regions as the search space, optimize the layout of the target product combination to be laid out, and output a layout scheme that meets the preset cost threshold.

[0049] According to the automatic home layout method provided in this application, the method optimizes the layout of the target product combination to be laid out using a set of layable areas as the search space and outputs a layout scheme that meets a preset cost threshold. The method includes: constructing a comprehensive cost function for quantitatively evaluating the layout scheme; the comprehensive cost function is constructed based on one or more predefined optimization layout rules, each optimization layout rule corresponding to a sub-cost function for measuring the degree to which it is violated; iteratively generating new candidate layout schemes within the set of layable areas by executing one or more preset layout transformation actions; calculating the comprehensive cost function value of each candidate layout scheme; and selecting candidate layout schemes with comprehensive cost function values ​​lower than the preset cost threshold from the iterative process using a greedy search strategy, as the final output layout scheme.

[0050] Specifically, when optimizing the layout of a sofa, coffee table, and TV cabinet combination in a living room, the system first constructs a comprehensive cost function. This function consists of multiple sub-cost functions, such as: the "view cone rule" cost (the larger the deviation angle, the higher the cost) which measures whether the sofa and TV cabinet are directly opposite each other; the "travel distance" cost (the cost increases when the main aisle width is insufficient) which measures whether the traffic flow is smooth; and the "alignment aesthetics" cost which measures the relative positions of the furniture. Optimization is performed within a pre-calculated set of possible placement positions for each item. The algorithm executes pre-defined layout transformation actions such as "moving the sofa to the left by a preset step," "aligning the coffee table with the sofa," and "swapping the positions of the sofa and TV cabinet," thereby iteratively generating new solutions. For each new solution generated, its comprehensive cost is calculated. The algorithm employs a greedy strategy, always searching along the direction that minimizes the cost to the greatest extent, until a layout solution with low sub-costs and a comprehensive cost below a preset threshold is found, which is then output as the final result.

[0051] like Figure 4 The layout optimization process is demonstrated. For each generated layout, the system calculates a cost function value to evaluate its rationality. This function quantifies the overall performance of the layout scheme in terms of circulation, visual effect, and space utilization. The process then determines whether the layout is more rational, i.e., whether the new cost function value is better than the previous scheme. If the result is "yes," the new product layout is adopted and iterative optimization continues; if the result is "no," the change is abandoned and the original product layout is maintained.

[0052] By quantifying subjective aesthetic and experiential rules into calculable costs and conducting targeted and efficient searches within a high-quality solution space pre-selected by rigid rules, this invention can quickly converge to a satisfactory layout scheme while taking into account multiple flexible optimization objectives. This solves the problem of low optimization efficiency or difficulty in finding satisfactory solutions under complex rules in traditional methods, achieving a balance between layout scheme quality and generation speed.

[0053] In one embodiment of this application, the iterative process of the greedy strategy further includes: when spatial overlap between items is detected in the candidate layout scheme, a penalty value is calculated based on the severity of the overlap, and the penalty value is included in the comprehensive cost function; when the optimization effect of continuous iteration is detected to be lower than the fourth threshold, a restart mechanism is triggered, and a new candidate layout scheme is generated by randomly changing the placeable position or orientation of one or more items to continue the iterative process.

[0054] Specifically, when iteratively optimizing a living room layout containing a sofa, coffee table, and bookcase, the algorithm generates a new scheme where the sofa and coffee table partially overlap. The system immediately calculates the overlapping area of ​​the two furniture projections (e.g., 0.3 square meters) and multiplies this area by a preset penalty coefficient (e.g., 10), resulting in a penalty value of 3. This value is then added to the overall cost function of the current layout scheme, causing a sharp increase in the overall cost of the scheme. This guides the algorithm to prioritize schemes that avoid this collision in subsequent iterations. If the cost of the layout scheme decreases by less than 1% in 10 consecutive iterations, the system determines that the optimization has stalled and triggers a restart mechanism: it may randomly select the bookcase and rotate it 90 degrees, or randomly swap the preset positions of the sofa and coffee table, thereby generating a completely new layout starting point and continuing the optimization iteration based on this new starting point.

[0055] By introducing a collision penalty mechanism, the algorithm can intelligently identify and proactively avoid physically infeasible layout regions, significantly reducing the waste of computational resources on invalid solutions. Simultaneously, by introducing an intelligent restart mechanism, the algorithm gains the ability to escape local optima, enhancing the robustness of the global search. These two mechanisms work together to improve the efficiency of the layout optimization process and the quality and rationality of the final generated solution.

[0056] Figure 5 This invention demonstrates a two-stage automated home layout process. First, by inputting apartment layout information, all product information, and product recall rules, the process enters the "product recall" stage. This stage filters all products according to predefined "recall rules," generating a preliminary "product ranking" list and calculating the "possible placement positions" of feasible products within the space. Next, by comprehensively utilizing the "product ranking," "possible placement positions," and complex "product layout rules" from the previous stage, "layout optimization" is performed, ultimately generating a "product layout" scheme that meets multiple requirements.

[0057] The automatic home layout device provided in this application is described below. The automatic home layout device described below can be referred to in correspondence with the automatic home layout method described above.

[0058] Figure 6 This is a schematic diagram of a home automation layout device provided in an embodiment of the present invention. The structure includes: The information acquisition module 610 is used to acquire the apartment layout information of the target space and the product information of the candidate home furnishing products; The filtering module 620 is used to determine the effective layout area of ​​each candidate home furnishing product based on the apartment structure information, the product information and the preset necessary layout rules, and to filter out a set of feasible home furnishing products from the candidate home furnishing products based on the effective layout area. The sorting module 630 is used to sort the products in the feasible home furnishing product set based on a preset sorting strategy to obtain a sorting result. The product combination module 640 is used to determine the target product combination to be arranged from the feasible home furnishing product set according to the sorting result; The layout optimization module 650 is used to optimize the layout of the target product combination to be laid out using the set of layable areas as the search space, and output a layout scheme that meets a preset cost threshold.

[0059] Figure 7 An example is a schematic diagram of the physical structure of an electronic device, such as... Figure 7 As shown, the electronic device may include a processor 710, a communication interface 720, a memory 730, and a communication bus 740, wherein the processor 710, the communication interface 720, and the memory 730 communicate with each other through the communication bus 740. The processor 710 can call logical instructions in the memory 730 to execute an automatic home layout method. The method includes: acquiring the floor plan information of the target space and the product information of candidate home furnishings; determining the effective layable area of ​​each candidate home furnishing based on the floor plan information, product information, and preset necessary layout rules; selecting a feasible home furnishing set from the candidate home furnishings based on the effective layable area; sorting the products in the feasible home furnishing set based on a preset sorting strategy to obtain a sorting result; determining the target product combination to be laid out from the feasible home furnishing set according to the sorting result; optimizing the layout of the target product combination to be laid out using the set of layable areas as the search space, and outputting a layout scheme that meets a preset cost threshold.

[0060] Furthermore, the logical instructions in the aforementioned memory 730 can be implemented as software functional units and, when sold or used as independent products, 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, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0061] On the other hand, this application also provides a computer program product, which includes a computer program that can be stored on a computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the automatic home layout method provided by the above methods. The method includes: acquiring the apartment structure information of the target space and the product information of candidate home furnishing products; determining the effective layoutable area of ​​each candidate home furnishing product based on the apartment structure information, product information, and preset necessary layout rules; selecting a feasible home furnishing product set from the candidate home furnishing products based on the effective layoutable area; sorting the products in the feasible home furnishing product set based on a preset sorting strategy to obtain a sorting result; determining the target product combination to be laid out from the feasible home furnishing product set according to the sorting result; optimizing the layout of the target product combination to be laid out using the set of layoutable areas as the search space, and outputting a layout scheme that meets a preset cost threshold.

[0062] Furthermore, this application also provides a computer-readable storage medium, which includes a stored program. When the program runs, it executes the automatic home layout method provided by the methods described above. This method includes: acquiring the floor plan information of the target space and the product information of candidate home furnishings; determining the effective layoutable area of ​​each candidate home furnishing based on the floor plan information, product information, and preset necessary layout rules; selecting a feasible home furnishing product set from the candidate home furnishings based on the effective layoutable area; sorting the products in the feasible home furnishing product set based on a preset sorting strategy to obtain a sorting result; determining the target product combination to be laid out from the feasible home furnishing product set according to the sorting result; optimizing the layout of the target product combination to be laid out using the set of layoutable areas as the search space; and outputting a layout scheme that meets a preset cost threshold.

[0063] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.

[0064] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.

[0065] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application.

Claims

1. A method for automatic home layout, characterized in that, include: Obtain information on the floor plan of the target space and product information for candidate home furnishing items; Based on the apartment layout information, the product information, and the preset necessary layout rules, the effective layout area of ​​each candidate home furnishing product is determined, and a feasible home furnishing product set is selected from the candidate home furnishing products based on the effective layout area. Based on a preset sorting strategy, the products in the feasible home furnishing product set are sorted to obtain the sorting result; Based on the sorting results, determine the target product combination to be laid out from the feasible home furnishing product set; Using the set of layable regions as the search space, the layout of the target product combination to be laid out is optimized, and a layout scheme that meets the preset cost threshold is output.

2. The automatic home layout method according to claim 1, characterized in that, Based on the apartment layout information, the product information, and preset necessary layout rules, the effective layoutable area for each candidate home furnishing product is determined. Based on the effective layoutable area, a feasible set of home furnishing products is selected from the candidate home furnishing products, including: From the predefined layout rule library, scores are performed on both the necessity dimension and the geometric modeling difficulty dimension. Only rules with a necessity score higher than the first threshold and a geometric modeling difficulty score lower than the second threshold are selected as necessary layout rules. The necessary layout rules are converted into geometric operations on the geometric elements in the apartment structure information; Based on the results of the geometric calculations, it is determined whether each candidate home furnishing product has an effective layout area within the target space. Candidate home furnishing products with available layout areas are included in the feasible home furnishing product set.

3. The automatic home layout method according to claim 2, characterized in that, The step of converting the necessary layout rules into geometric operations on the geometric elements in the apartment structure information includes: The necessary layout rules are converted into Boolean operations on the wall lines, door and window positions, or bottom polygons of the space in the apartment structure information.

4. The automatic home layout method according to claim 2, characterized in that, Based on the results of the geometric calculations, the determination of whether each candidate home furnishing item has a valid layout area within the target space includes: The minimum outer rectangle of the candidate home furnishing products is intersected with the available ground polygons in the apartment layout information to obtain the initial candidate region; If the candidate home furnishing product attributes include a label indicating that the back panel must be against a wall, then calculate the minimum distance between the product's back panel projection line and each wall line, and retain the initial candidate area segment with a minimum distance of zero from the initial candidate area; The initial candidate region segments are compared with the projections of door and window openings to perform window conflict verification, and segments whose intersection area accounts for a proportion of the opening area greater than the third threshold are removed. For the initial candidate area segments that pass the window conflict check, generate equidistant offset lines along the main orientation of the room according to the depth dimension marked on the product, and extract the closed area with an offset distance equal to the depth dimension as the effective layout area of ​​the product.

5. The automatic home layout method according to claim 1, characterized in that, The method of sorting the products in the feasible home furnishing product set based on a preset sorting strategy to obtain a sorting result includes: Construct a comprehensive ranking model, wherein the input features of the comprehensive ranking model include at least: user profile features, product attribute features of the feasible home furnishing product set, and apartment type attribute features of the target space; The comprehensive ranking model is used to score each item in the feasible home furnishing product set, and the scoring results are obtained. The feasible home furnishing products are sorted according to the scoring results to generate a sorting result.

6. The automatic home layout method according to claim 1, characterized in that, The step of determining the target product combination to be arranged from the feasible home furnishing product set according to the sorting result includes: Receive a product selection instruction from the user based on the sorting result, and determine one or more products selected by the user as the target product combination to be laid out; or, According to the preset product category configuration rules, one or more products are automatically selected from the sorting results in descending order to form the target product combination to be laid out.

7. The automatic home layout method according to claim 1, characterized in that, The process of optimizing the layout of the target product combination using a set of layable regions as the search space and outputting a layout scheme that meets a preset cost threshold includes: A comprehensive cost function for quantitatively evaluating layout schemes is constructed. The comprehensive cost function is constructed based on one or more predefined optimization layout rules, and each optimization layout rule corresponds to a sub-cost function for measuring the degree to which it is violated. Within the set of layable regions, new candidate layout schemes are generated iteratively by executing one or more preset layout transformation actions; Calculate the comprehensive cost function value for each of the candidate layout schemes; Based on a greedy search strategy, candidate layout schemes with a comprehensive cost function value lower than a preset cost threshold are selected from the iterative process and used as the final layout scheme output.

8. A home automation layout device, characterized in that, include: The information acquisition module is used to acquire the apartment layout information of the target space and the product information of the candidate home furnishing products; The filtering module is used to determine the effective layout area of ​​each candidate home furnishing product based on the apartment structure information, the product information and the preset necessary layout rules, and to filter out a set of feasible home furnishing products from the candidate home furnishing products based on the effective layout area. The sorting module is used to sort the products in the feasible home furnishing product set based on a preset sorting strategy to obtain the sorting result; The product combination module is used to determine the target product combination to be arranged from the feasible home furnishing product set based on the sorting result; The layout optimization module is used to optimize the layout of the target product combination to be laid out using the set of layable areas as the search space, and output a layout scheme that meets a preset cost threshold.

9. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a stored program, wherein the program, when executed, performs the method of any one of claims 1 to 7.

10. An electronic device comprising a memory and a processor, characterized in that, The memory stores a computer program, and the processor is configured to execute the method of any one of claims 1 to 7 through the computer program.