Multi-lane arrangement method and related devices

By optimizing the layout of multiple pipes using A* and GA algorithms, the spatial allocation problem in the joint layout of multiple pipes is solved, resulting in efficient, intelligent, and practical pipe layout that meets actual building requirements.

CN115310245BActive Publication Date: 2026-11-24SHENZHEN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210975141.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-08-15
Publication Date
2026-11-24
Estimated Expiration
2042-08-15

AI Technical Summary

Technical Problem

Existing intelligent pipeline design algorithms cannot effectively solve the overall space allocation problem when multiple pipelines are arranged together, and do not fully consider the pipe arrangement rules constraints in actual building production.

Method used

The A* algorithm is used for pipe routing, combined with the GA algorithm and pipe fine-tuning operator. By constructing a rasterized 3D model, the paths of multiple pipes are optimized, and a cross operator is introduced for dynamic optimization to meet the requirements of height space and wall-mounted pipe layout in building production.

Benefits of technology

It enables collaborative layout of multiple pipelines, optimizes space allocation, improves layout efficiency and quality, meets actual engineering needs, and has strong scalability and robustness.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115310245B_ABST
    Figure CN115310245B_ABST
Patent Text Reader

Abstract

This invention provides a method and related equipment for multi-pipe layout. The method includes: reading the drawing information of the original Revit design drawings of a building; constructing a rasterized 3D model on a Python service platform based on the drawing information; reading the start and end points of multiple pipes; and obtaining the pipe layout path by performing pipe routing using the A* algorithm and optimizing the pipe routing using the GA algorithm based on the start and end points of the multiple pipes. The beneficial effect of this invention is that it can effectively solve the overall space allocation problem when multiple pipes are arranged together.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of building pipe layout technology, and in particular to a method for arranging multiple pipes and related equipment. Background Technology

[0002] Most existing intelligent pipeline design algorithms are designed for optimizing a single pipeline and cannot solve the overall space allocation problem when multiple pipelines are arranged together.

[0003] Existing intelligent pipeline design algorithms do not fully consider the constraints of pipe layout rules in actual building production, such as height space and pipe layout against walls;

[0004] Existing intelligent pipeline design algorithms are rarely applied to pipeline layout in large-scale real-world building scenarios, lacking practicality. Summary of the Invention

[0005] The technical problem to be solved by the present invention is to provide a method and related equipment for arranging multiple pipes, which aims to solve the overall space allocation problem when multiple pipes are arranged together.

[0006] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is: a multi-pipe arrangement method, including the following steps:

[0007] S10. Read the original Revit design drawings of the building;

[0008] S20. Construct a rasterized 3D model on the Python service platform;

[0009] S30. Read and store the start and end points of multiple pipelines;

[0010] S40. Based on the starting and ending points of multiple pipelines, use the A* algorithm to find the pipeline path.

[0011] S50. Optimize the pipeline path using the GA algorithm and pipeline fine-tuning operator to obtain the pipeline path.

[0012] Furthermore, pipeline routing using the A* algorithm includes the following steps:

[0013] S411. Initialize the OPEN and CLOSED tables. The OPEN table is a binary heap implemented using an array to store untraversed graticles; the CLOSED table is stored using an array to store graticles that have been detected.

[0014] S412. Place the starting point of the pipeline into the OPEN table. Assume there are n grids in the scene, with the starting point being S and the ending point being E.

[0015] S413 checks if the OPEN table is empty. If it is empty, the search process has failed and the program exits; otherwise, it proceeds to the next step.

[0016] S414. Move the first grid cell V0 in the OPEN table out as the next grid cell in the path, and store grid cell V0 in the CLOSED table to indicate that the current grid cell has been detected.

[0017] S415. Determine if V0 is the endpoint grid E. If it is, the path search is successful and path repair is performed. Otherwise, proceed to the next step.

[0018] S416. Using V0 as the center, explore the adjacent grid cells V of V0. i (i < n), calculate its valuation function value;

[0019] S417, Determine V i Does it exist in the OPEN or CLOSED table: If V i If it does not exist in the OPEN and CLOSED tables, then store it in the OPEN table and join V0 and V... i Two grids; if V i If the value already exists in the OPEN table, then update the F(V) value in the OPEN table by replacing the larger old F(V) value in the OPEN table with the smaller new F(V) value, and then concatenate V0 and V... i Two grids; if V i If the vertex already exists in the CLOSED table or is an obstacle point, ignore this vertex and return to the previous step to continue exploring the adjacent grids of V0;

[0020] S418. The grid with the smallest F(V) value in the OPEN table is updated and sorted to the top of the heap using a binary heap, and then the process jumps to step S413.

[0021] S419, Execution path repair;

[0022] S420. After all paths are repaired, complete the pipeline routing.

[0023] Further path repair steps include,

[0024] S421. Perform self-crossing detection of pipeline paths and delete redundant pipeline paths;

[0025] S422. Perform turnaround path detection and delete the paths between turnaround points to complete path deduplication;

[0026] S423. Perform continuous turning path detection, use the A* algorithm to find a new path, and cancel continuous turns.

[0027] Furthermore, with V0 as the center, explore the adjacent grids V0. i (i < n), the formula used to calculate its evaluation function value is,

[0028] F(n) = kg·g(n) + kh·h(n)

[0029] g(n) = a·L(n) + b·B(n) + c·E o (n)+d·E h (n)

[0030] h(n) = |E-V0|

[0031] Where g(n) is the path from the starting point S to V i The cost evaluation function is given by L(n), where L(n) is the path length cost, B(n) is the turning cost, and E is the turning cost. o (n) represents the cost of non-wall-mounted / parallel pipe routing, E h h(n) represents the height cost, and a to d are the corresponding weighting coefficients. The specific calculation rules for the cost are: add 1 to the path loss per unit grid length; add 1 to the loss per unit turn; add 1 to the loss per unit pipe grid not against a wall / within a pipe arrangement; add 1 to the loss per unit pipe grid relative to the false ceiling height for each grid height loss. h(n) is the grid V. i Distance from the destination in Manhattan.

[0032] Furthermore, pipeline pathfinding optimization using the GA algorithm includes the following steps:

[0033] S431. Input the start and end points of multiple pipelines;

[0034] S432. Select the area in the pipe laying area that is closest to the wall and has the highest height as the area for generating intermediate points. Generate random intermediate points within the area and combine them with the starting and ending points to obtain the set of intermediate points.

[0035] S433. Use the A* algorithm to connect the intermediate points of each point set to form an initial path, and repeat to generate 20 sets of initial paths.

[0036] S434. Evaluate the generated initial paths, score the fitness of each set of paths, and retain the best path with the highest score.

[0037] S435. Based on the fitness of each path group, 19 paths are selected by roulette wheel selection. Together with the best path obtained in step S434, a total of 20 paths enter the next iteration of the GA algorithm.

[0038] S436. Randomly select a path from each of the two sets of pipes, randomly find intersections on the path, call the A* algorithm to form a new path between the intersections, and combine it with the original path to form a new path combination.

[0039] S437. Select two pipes in the same group, choose the turning points that are close to each other as the exchange points, exchange the turning points, and call the A* algorithm to regenerate the paths before and after the turning points to form a new path group.

[0040] S438. For each path in the group, randomly select a mutation point, call the A* algorithm to regenerate the path from the mutation point to the destination, and form a new path group.

[0041] S439. Determine if the number of iterations has reached the set value. If not, return to step S434 and proceed to the next round of evolution iteration. Otherwise, exit the evolution process and output the best path (best_paths).

[0042] Furthermore, the formula used to score the fitness of each path group is as follows:

[0043] f obj =K-(α·f L +β·f B +γ·f EO +δ·f EH )

[0044] Where K is a sufficiently large positive number, ensuring f obj The value of f is always greater than 0. L For the path length loss of the pipeline group, f B The loss due to the number of bends in the pipeline path, f EO For losses in pipe groups where the grid is not placed against the wall, f EH The grid height loss for the pipeline group is represented by α, β, γ, and δ, which are the weights of the four types of losses, respectively.

[0045] The present invention also provides a multi-pipe arrangement device, comprising,

[0046] The drawing information reading module is used to read the drawing information of the original Revit design drawings of the building;

[0047] The 3D model construction module constructs rasterized 3D models on a Python service platform.

[0048] The start and end point read storage module presets the start and end points of multiple pipelines;

[0049] The pathfinding module is used to find the path of multiple pipelines using the A* algorithm based on the start and end points of those pipelines.

[0050] The optimization module uses the GA algorithm to optimize pipeline routing and obtain the pipeline layout path.

[0051] The present invention also provides a computer device, the computer device including a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the multi-pipe arrangement method as described above.

[0052] The present invention also provides a storage medium storing a computer program, which, when executed by a processor, can implement the multi-pipe routing method described above.

[0053] The beneficial effects of this invention are as follows: by utilizing the improved A* algorithm and GA algorithm, and introducing a crossover operator, the A* algorithm is used as the basic pathfinding unit to ensure the efficiency of pipeline pathfinding, the GA algorithm is used as an evolutionary algorithm to ensure the optimality of the pipeline, and the crossover operator is used as a dynamic optimization unit to solve the overall space allocation problem of multiple pipelines. It is more optimized. Based on the single-pipe algorithm, the operator is transferred to the problem of multi-pipe arrangement, so that multiple pipelines are arranged in a coordinated manner. While ensuring the quality of a single pipe, the overall allocation of space for multi-pipe arrangement is optimized. Attached Figure Description

[0054] The specific structure of the present invention will now be described in detail with reference to the accompanying drawings.

[0055] Figure 1 This is a flowchart of a multi-pipe layout method according to an embodiment of the present invention;

[0056] Figure 2 This is a block diagram of a multi-pipe arrangement device according to an embodiment of the present invention;

[0057] Figure 3 This is a schematic diagram of the array-based min-heap storage principle according to an embodiment of the present invention;

[0058] Figure 4 This is a schematic diagram of self-cross repair according to an embodiment of the present invention;

[0059] Figure 5 This is a schematic diagram of path duplication repair according to an embodiment of the present invention;

[0060] Figure 6 This is a schematic diagram illustrating the continuous turning improvement according to an embodiment of the present invention;

[0061] Figure 7 This is a schematic diagram of the inter-group crossover operator according to an embodiment of the present invention;

[0062] Figure 8 This is a schematic diagram of the intra-group crossover operator according to an embodiment of the present invention;

[0063] Figure 9 This is a schematic diagram of the mutation operator in an embodiment of the present invention;

[0064] Figure 10 This is a schematic block diagram of a computer device according to an embodiment of the present invention. Detailed Implementation

[0065] The technical solutions of the embodiments of the present 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 the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0066] It should be understood that, when used in this specification and the appended claims, the terms "comprising" and "including" indicate the presence of the described features, integrals, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or collections thereof.

[0067] It should also be understood that the terminology used in this specification is for the purpose of describing particular embodiments only and is not intended to limit the invention. As used in this specification and the appended claims, the singular forms “a,” “an,” and “the” are intended to include the plural forms unless the context clearly indicates otherwise.

[0068] It should also be further understood that the term "and / or" as used in this specification and the appended claims refers to any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.

[0069] like Figure 1 As shown, the first embodiment of the present invention is: a method for arranging multiple pipes, including the following steps:

[0070] S10. Read the drawing information of the original Revit design drawings of the building;

[0071] S20. Construct a rasterized 3D model on the Python service platform based on the drawing information, and construct the raster model at a scale of 1:500 (mm).

[0072] S30. Read and store the start and end points of multiple pipelines;

[0073] S40. Based on the start and end points of multiple pipelines, perform initial pipeline routing using the A* algorithm.

[0074] S50. Optimize pipeline routing through the GA algorithm and pipeline fine-tuning to obtain the pipeline layout path.

[0075] The pipeline routing using the A* algorithm includes the following steps:

[0076] S411. Initialize the OPEN and CLOSED tables. The OPEN table uses a binary heap implemented with an array to store unvisited graticles; the CLOSED table uses an array to store detected graticles. Figure 3 This is a schematic diagram of a min-heap storage principle based on an array.

[0077] S412. Place the starting point of the pipeline into the OPEN table. Assume there are n grids in the scene, with the starting point being S and the ending point being E.

[0078] S413 checks if the OPEN table is empty. If it is empty, the search process has failed and the program exits; otherwise, it proceeds to the next step.

[0079] S414. Move the first grid cell V0 in the OPEN table out as the next grid cell in the path, and store grid cell V0 in the CLOSED table to indicate that the current grid cell has been detected.

[0080] S415. Determine if V0 is the endpoint grid E. If it is, the path search is successful and path repair is performed. Otherwise, proceed to the next step.

[0081] S416. Using V0 as the center, explore the adjacent grid cells V of V0. i (i < n), calculate its valuation function value;

[0082] S417, Determine V i Does it exist in the OPEN or CLOSED table: If V i If it does not exist in the OPEN and CLOSED tables, then store it in the OPEN table and join V0 and V... i Two grids; if V i If the value already exists in the OPEN table, then update the F(V) value in the OPEN table by replacing the larger old F(V) value in the OPEN table with the smaller new F(V) value, and then concatenate V0 and V... i Two grids; if V i If the vertex already exists in the CLOSED table or is an obstacle point, ignore this vertex and return to the previous step to continue exploring the adjacent grids of V0;

[0083] S418. The grid with the smallest F(V) value in the OPEN table is updated and sorted to the top of the heap using a binary heap, and then the process jumps to step S413.

[0084] S419, Execution path repair;

[0085] S420. After all paths are repaired, complete the pipeline routing.

[0086] The path repair steps include,

[0087] S421, such as Figure 4 As shown, a self-crossing detection of the pipeline path is performed, and redundant pipeline paths between c and c' are deleted;

[0088] S422, such as Figure 5 As shown, the backtracking path detection is performed, and the paths between backtracking points are deleted to complete the path deduplication;

[0089] S423, such as Figure 6 As shown, continuous turning paths are detected, and the A* algorithm is used to re-find the path, thus canceling continuous turns.

[0090] Among them, with V0 as the center, explore the adjacent grids V of V0. i (i < n), the formula used to calculate its evaluation function value is,

[0091] F(n) = kg·g(n) + kh·h(n)

[0092] g(n) = a·L(n) + b·B(n) + c·E o (n)+d·E h (n)

[0093] h(n) = |E-V0|

[0094] Where g(n) is the path from the starting point S to V i The cost evaluation function is given by L(n), where L(n) is the path length cost, B(n) is the turning cost, and E is the turning cost. o (n) represents the cost of non-wall-mounted / parallel pipe routing, E h h(n) represents the height cost, and a to d are the corresponding weighting coefficients. The specific calculation rules for the cost are: add 1 to the path loss per unit grid length; add 1 to the loss per unit turn; add 1 to the loss per unit pipe grid not against a wall / within a pipe arrangement; add 1 to the loss per unit pipe grid relative to the false ceiling height for each grid height loss. h(n) is the grid V. i Distance from the destination in Manhattan.

[0095] The pipeline routing optimization using the GA algorithm includes the following steps:

[0096] S431. Input the start and end points of multiple pipelines;

[0097] S432. Select the area in the pipe laying area that is closest to the wall and has the highest height as the area for generating intermediate points. Generate random intermediate points within the area and combine them with the starting and ending points to obtain the set of intermediate points.

[0098] S433. Use the A* algorithm to connect the intermediate points of each point set to form an initial path, and repeat to generate 20 sets of initial paths.

[0099] S434. Evaluate the generated initial paths, score the fitness of each set of paths, and retain the best path with the highest score.

[0100] S435. Based on the fitness of each path group, 19 paths are selected by roulette wheel selection. Together with the best path obtained in step S434, a total of 20 paths enter the next iteration of the GA algorithm.

[0101] S436, Path cross-recombination between different groups; such as Figure 7 As shown, a path is randomly selected from each of the two sets of pipelines, and intersections are randomly found on the path. The A* algorithm is then used to form a new path between the intersections, which is then combined with the original path to form a new path combination.

[0102] S437, Path recombination within the same group; such as Figure 8 As shown, two pipes within the same group are selected, and the turning points that are close to each other are chosen as the exchange points. The turning points are exchanged, and the A* algorithm is called to regenerate the paths before and after the turning points to form a new path group.

[0103] S438, path mutation; such as Figure 9 As shown, for each path in the group, a mutation point is randomly selected, and the A* algorithm is called to regenerate the path from the mutation point to the destination, forming a new path group;

[0104] S439. Determine if the number of iterations has reached the set value. If not, return to step S434 and proceed to the next round of evolution iteration. Otherwise, exit the evolution process and output the best path (best_paths).

[0105] The formula used to score the fitness of each path group is as follows:

[0106] f obj =K-(α·f L +β·f B +γ·f EO +δ·f EH )

[0107] Where K is a sufficiently large positive number, ensuring f obj The value of f is always greater than 0. L For the path length loss of the pipeline group, f B The loss due to the number of bends in the pipeline path, f EO For losses in pipe groups where the grid is not placed against the wall, f EH The grid height loss for the pipeline group is represented by α, β, γ, and δ, which are the weights of the four types of losses, respectively.

[0108] Table 1: Comparison of Algorithm-Based Pipeline Data

[0109] algorithm Path length Number of turns Loss against the wall High loss A* 441 65 87 786 MPCEA 438 36 33 768

[0110] The technical effect of this embodiment is as follows: by using the improved A* algorithm and GA algorithm, introducing the crossover operator, using the A* algorithm as the basic pathfinding unit to ensure the efficiency of pipeline pathfinding, the GA algorithm as the evolutionary algorithm to ensure the optimality of the pipeline, and the crossover operator as the dynamic optimization unit to solve the overall space allocation problem of multiple pipelines, the following technical effect is finally achieved.

[0111] Further optimization involves transferring the operator to the multi-pipe layout problem based on the single-pipe algorithm, enabling multiple pipes to be laid out collaboratively. This optimizes the overall allocation of space for multi-pipe layout while ensuring the quality of a single pipe.

[0112] More intelligent, the multi-pipeline evolution algorithm further reduces the proportion of human-computer interaction in the algorithm application process. Users no longer need to consider the order of pipeline arrangement, making it more intelligent.

[0113] More practical, this algorithm incorporates the ideas of multi-pipe collaborative layout and dynamic fine-tuning, quantifying actual engineering aesthetics and pipe layout rules in the algorithm, making the pipe layout results of the algorithm closer to actual needs;

[0114] More flexible, this algorithm has strong scalability, can further quantify more pipe layout rules, and can incorporate different pipe fine-tuning methods in real-world cases, further enhancing the algorithm's robustness.

[0115] like Figure 2 As shown, the present invention also provides a multi-pipe arrangement device, comprising,

[0116] Drawing information reading module 10: Reads the drawing information of the original Revit design drawings of the building;

[0117] 3D model construction module 20 constructs rasterized 3D models on the Python service platform;

[0118] Start and end point preset module 30, which presets the start and end points of multiple pipelines;

[0119] The pipeline routing module 40 is used to perform pipeline routing based on the start and end points of multiple pipelines using the A* algorithm.

[0120] The pipeline optimization module 50 optimizes pipeline routing through the GA algorithm and pipeline fine-tuning to obtain the pipeline layout path.

[0121] It should be noted that those skilled in the art can clearly understand that the specific implementation process of the above-mentioned multi-pipe arrangement method and device can be referred to the corresponding description in the foregoing method embodiments. For the sake of convenience and brevity, it will not be repeated here.

[0122] The aforementioned multi-pipe arrangement device can be implemented as a computer program, which can, for example... Figure 10 It runs on the computer device shown.

[0123] Please see Figure 10 , Figure 10 This is a schematic block diagram of a computer device provided in an embodiment of this application. The computer device 500 can be a terminal or a server. The terminal can be an electronic device with communication functions, such as a smartphone, tablet, laptop, desktop computer, personal digital assistant, or wearable device. The server can be a standalone server or a server cluster composed of multiple servers.

[0124] See Figure 10 The computer device 500 includes a processor 502, a memory, and a network interface 505 connected via a system bus 501. The memory may include a non-volatile storage medium 503 and internal memory 504.

[0125] The non-volatile storage medium 503 may store an operating system 5031 and a computer program 5032. The computer program 5032 includes program instructions that, when executed, cause the processor 502 to perform a multi-pipeline arrangement method.

[0126] The processor 502 provides computing and control capabilities to support the operation of the entire computer device 500.

[0127] The internal memory 504 provides an environment for the execution of the computer program 5032 in the non-volatile storage medium 503. When the computer program 5032 is executed by the processor 502, the processor 502 can execute a multi-pipeline arrangement method.

[0128] This network interface 505 is used for network communication with other devices. Those skilled in the art will understand that... Figure 10 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device 500 to which the present application is applied. The specific computer device 500 may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0129] The processor 502 is used to run a computer program 5032 stored in the memory to implement the multi-pipeline arrangement method as described above.

[0130] It should be understood that, in the embodiments of this application, the processor 502 may be a central processing unit (CPU), or it may be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor.

[0131] It will be understood by those skilled in the art that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program includes program instructions and can be stored in a storage medium, which is a computer-readable storage medium. The program instructions are executed by at least one processor in the computer system to implement the process steps of the embodiments of the above methods.

[0132] Therefore, the present invention also provides a storage medium. This storage medium can be a computer-readable storage medium. The storage medium stores a computer program, wherein the computer program includes program instructions. When executed by a processor, the program instructions cause the processor to perform the multi-pipeline routing method as described above.

[0133] The storage medium can be any computer-readable storage medium capable of storing program code, such as a USB flash drive, portable hard drive, read-only memory (ROM), magnetic disk, or optical disk.

[0134] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.

[0135] In the several embodiments provided by this invention, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For example, the division of each unit is merely a logical functional division, and there may be other division methods in actual implementation. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed.

[0136] The steps in the method of this invention can be adjusted, merged, or reduced in order according to actual needs. The units in the device of this invention can be merged, divided, or reduced according to actual needs. Furthermore, the functional units in the various embodiments of this invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.

[0137] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part 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, a terminal, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention.

[0138] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in the present invention, and these modifications or substitutions should all be covered within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.

Claims

1. A method of arranging multiple conduits, the method comprising: Including steps, ​ S10. Read the original Revit design drawings of the building; S20. Construct a rasterized 3D model on the Python service platform; S30. Read and store the start and end points of multiple pipelines; S40. Based on the starting and ending points of multiple pipelines, use the A* algorithm to find the pipeline path. S50. Optimize the pipeline path using the GA algorithm and pipeline fine-tuning operators to obtain the pipeline path; wherein, the pipeline fine-tuning operators include: an inter-group crossover operator for cross-recombining paths from different pipeline groups; an intra-group crossover operator for exchanging two pipeline paths from the same pipeline group; and a mutation operator for performing mutation operations on a single pipeline path. Pipeline path finding optimization using the GA algorithm includes the following steps. S431. Input the start and end points of multiple pipelines; S432. Select the area in the pipe laying area that is closest to the wall and has the highest height as the area for generating intermediate points. Generate random intermediate points within the area and combine them with the starting and ending points to obtain the set of intermediate points. S433. Use the A* algorithm to connect the intermediate points of each point set to form an initial path, and repeat to generate 20 sets of initial paths. S434. Evaluate the generated initial paths, score the fitness of each set of paths, and retain the best path with the highest score. S435. Based on the fitness of each path group, 19 paths are selected by roulette wheel selection. Together with the best path obtained in step S434, a total of 20 paths enter the next iteration of the GA algorithm. S436. Randomly select a path from each of the two sets of pipes, randomly find intersections on the path, call the A* algorithm to form a new path between the intersections, and combine it with the original path to form a new path combination. S437. Select two pipes in the same group, choose the turning points that are close to each other as the exchange points, exchange the turning points, and call the A* algorithm to regenerate the paths before and after the turning points to form a new path group. S438. For each path in the group, randomly select a mutation point, call the A* algorithm to regenerate the path from the mutation point to the destination, and form a new path group. S439. Determine if the number of iterations has reached the set value. If not, return to step S434 for the next round of evolutionary iterations; otherwise, exit the evolutionary process and output the best paths (best_paths). The formula used to score the fitness of each path group is as follows: wherein, is a sufficiently large positive number, ensuring the value of is always greater than 0, is the path length loss of the pipe group, is the number of turns loss of the pipe group, is the loss of the pipe group grid not arranged against the wall, , , , are the weights of the four types of losses, respectively.

2. The method of claim 1, wherein: Pipeline routing using the A* algorithm includes the following steps. S411. Initialize the OPEN and CLOSED tables. The OPEN table is a binary heap implemented using an array to store untraversed graticles; the CLOSED table is stored using an array to store graticles that have been detected. S412. Place the starting point of the pipeline into the OPEN table. Assume there are n grids in the scene, with the starting point being S and the ending point being E. S413 checks if the OPEN table is empty. If it is empty, the search process has failed and the program exits; otherwise, it proceeds to the next step. S414. Move the first grid cell V0 in the OPEN table out as the next grid cell in the path, and store grid cell V0 in the CLOSED table to indicate that the current grid cell has been detected. S415. Determine if V0 is the endpoint grid E. If it is, the path search is successful and path repair is performed. Otherwise, proceed to the next step. S416, explore the adjacent grid of V0 with V0 as the center (i < n), calculate the estimated function value thereof; S417, Determine V i Does it exist in the OPEN or CLOSED table: If V i If it does not exist in the OPEN and CLOSED tables, then store it in the OPEN table and join V0 and V... i Two grids; if V i If it already exists in the OPEN table, then access the OPEN table. Update the value, i.e., take the smaller value. The new value replaces the larger value in the OPEN table. Old value, connecting V0 and V i Two grids; if V i If the vertex already exists in the CLOSED table or is an obstacle point, ignore this vertex and return to the previous step to continue exploring the adjacent grids of V0; S418. The grid with the smallest F(V) value in the OPEN table is updated and sorted to the top of the heap using a binary heap, and then the process jumps to step S413. S419, Execution path repair; S420. After all paths are repaired, complete the pipeline routing.

3. The multi-pipe arrangement method as described in claim 2, characterized in that: The path repair steps include, S421. Perform self-crossing detection of pipeline paths and delete redundant pipeline paths; S422. Perform turnaround path detection and delete the paths between turnaround points to complete path deduplication; S423. Perform continuous turning path detection, use the A* algorithm to find a new path, and cancel continuous turns.

4. The multi-pipe arrangement method as described in claim 3, characterized in that: With V0 as the center, explore adjacent grids of V0 (i<n), the formula used to calculate its evaluation function value is, in, The path is from the starting point S to... The cost evaluation function, For path length cost, For the cost of turning, The cost of not running pipes against a wall / running pipes in parallel At a high cost, The specific calculation rules for the cost, based on the corresponding weighting coefficients, are as follows: add 1 to the path loss per unit grid length; add 1 to the loss per unit turn; add 1 to the loss per unit pipe grid not adjacent to a wall / adjacent to a pipe; add 1 to the loss for each grid height lost relative to the false ceiling height per unit pipe grid. It is a grid V i Distance from the destination in Manhattan.

5. A multi-pipe layout device, characterized in that: include, The drawing information reading module reads the original Revit design drawings of the building; The 3D model construction module constructs rasterized 3D models on a Python service platform. The start and end point read storage module presets the start and end points of multiple pipelines; The pathfinding module is used to search for initial pipeline paths using the A* algorithm based on the start and end points of multiple pipelines. The optimization module optimizes pipeline routing using the GA algorithm and pipeline fine-tuning operators to obtain pipeline layout paths. The pipeline fine-tuning operators include: an inter-group crossover operator for cross-recombining paths from different pipeline groups; an intra-group crossover operator for exchanging two pipeline paths from the same pipeline group; and a mutation operator for performing mutation operations on a single pipeline path. Specifically, the optimization module is used to perform the following steps: S431. Input the start and end points of multiple pipelines; S432. Select the area in the pipe laying area that is closest to the wall and has the highest height as the area for generating intermediate points. Generate random intermediate points within the area and combine them with the starting and ending points to obtain the set of intermediate points. S433. Use the A* algorithm to connect the intermediate points of each point set to form an initial path, and repeat to generate 20 sets of initial paths. S434. Evaluate the generated initial paths, score the fitness of each set of paths, and retain the best path with the highest score. S435. Based on the fitness of each path group, 19 paths are selected by roulette wheel selection. Together with the best path obtained in step S434, a total of 20 paths enter the next iteration of the GA algorithm. S436. Randomly select a path from each of the two sets of pipes, randomly find intersections on the path, call the A* algorithm to form a new path between the intersections, and combine it with the original path to form a new path combination. S437. Select two pipes in the same group, choose the turning points that are close to each other as the exchange points, exchange the turning points, and call the A* algorithm to regenerate the paths before and after the turning points to form a new path group. S438. For each path in the group, randomly select a mutation point, call the A* algorithm to regenerate the path from the mutation point to the destination, and form a new path group. S439. Determine whether the number of iterations has reached the set value. If not, return to step S434 and proceed to the next round of evolution iteration. Otherwise, exit the evolution process and output the best path best_paths. The formula used to score the fitness of each path group is as follows: in, For a sufficiently large positive number, guarantee The value is always greater than 0. For pipeline path length loss, Loss due to the number of bends in the pipeline route. The loss is due to the fact that the grid was not arranged against the wall in the pipe assembly. For the loss of pipe grid height, , , , These are the weights for the four types of losses.

6. A computer device, characterized in that: The computer device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the multi-pipe routing method as described in any one of claims 1 to 4.

7. A storage medium, characterized in that: The storage medium stores a computer program, which, when executed by a processor, can implement the multi-pipe arrangement method as described in any one of claims 1 to 4.