Method for automatically generating tunnel model based on Revit and Dynamo
By automatically generating tunnel models based on Revit and Dynamo, the problems of low tunnel modeling efficiency and low accuracy in the existing technology are solved, and more efficient and accurate tunnel model construction is achieved, which is suitable for tunnel engineering with complex geological conditions.
Patent Information
- Application Number
- CN202510080719.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-20
- Publication Date
- 2025-02-25
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing tunnel modeling software has limitations in dealing with complex geological conditions and improving modeling efficiency, resulting in low model construction efficiency and low accuracy.
Using the automatic tunnel model method based on Revit and Dynamo, the three-dimensional geometry generation and model construction of the tunnel is realized by drawing the tunnel outline in Revit and creating scripts with Dynamo. This method includes creating tunnel profiles, generating tunnel shapes, and building tunnel models, and creating complex path and cross-section shapes through custom node and node combinations.
It improves the construction efficiency and accuracy of tunnel models, realizes more flexible and intelligent design solutions, reduces the need for manual data sorting and adjustment of models, and improves the computing efficiency and automation of models.
Smart Images

Figure CN119514242A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of tunnel modeling, and in particular relates to a method for automatically generating a tunnel model based on Revit and Dynamo. Background Art
[0002] At present, the domestic BIM (Building Information Modeling) technology has been widely recognized by the industry worldwide. It can help realize the integration of building information. From the design, construction, operation of the building to the end of the building's entire life cycle, various information is always integrated in a three-dimensional model information database. In order to improve the efficiency and quality of tunnel construction and improve the level of tunnel construction safety management, BIM technology has been introduced into tunnel engineering. Through the BIM model, tunnel full life cycle management can be achieved. Since tunnel engineering construction involves many complex factors, including geological conditions, environmental impacts and construction technology, etc. At present, the mainstream software for tunnel modeling has various limitations. For example, Autodesk Civil3D provides powerful civil engineering design functions, which are suitable for tunnel modeling, but there are certain limitations in dealing with complex geological conditions. Revit, as a mainstream BIM software, can perform comprehensive architectural design and model creation, but its professional support for tunnels is relatively insufficient.
[0003] In response to the above problems, Chinese patent application with publication number CN109800536A discloses a rapid modeling method of parametric tunnel model based on Revit and Dynamo. By using the visual programming software Dynamo+Revit to establish a parametric BIM model of the tunnel, it has the following characteristics: it can realize fast and accurate modeling, and achieve good visualization, and improve work efficiency; the main structure model of the tunnel constructed by this parametric tunnel modeling system can realize the controllability of each component, and can realize the readability and modification of all parameters such as component material, volume, size, etc. It is a truly digital information model, which provides great convenience and possibility for the extraction of engineering quantities, force calculation and analysis, and customization of prefabricated components in the subsequent in-depth design of the tunnel. However, although the above modeling method has improved the modeling efficiency and model accuracy to a certain extent, it still faces challenges in terms of automation and data integration. For example, the Excel data source and family library data of the tunnel need to be manually sorted, which has low efficiency and accuracy; it is necessary to create parametric contour lines for the lining, ditch, pavement and other sections of different lining types of the tunnel based on the design drawings, which has high technical requirements for personnel, and the designers still need to make appropriate adjustments and annotations to the design drawings. In addition, after the drawings are slightly adjusted, the modeling needs to be re-performed, which increases the extra workload and affects the modeling efficiency. Therefore, the present invention proposes a method for automatically generating a tunnel model based on Revit and Dynamo to solve the above problems. Summary of the invention
[0004] The present invention provides a method for automatically generating a tunnel model based on Revit and Dynamo, aiming to solve the problems of low efficiency in tunnel model construction and low model accuracy. The method comprises the following steps: Step S1: Create a tunnel outline: draw the center line or outline of the tunnel in Revit, select different views to depict the shape of the tunnel, and use built-in data to set tunnel parameters; the built-in data is pre-set, and the specific setting method is: collect tunnel data, the data includes: tunnel geometry data, geological data, structural data, tunnel facility data, tunnel environment data; use Revit to link the tunnel data; Step S2: Create a Dynamo script: set input parameters, and use the nodes provided in Dynamo to create the cross section of the tunnel; the nodes include: geometry nodes, list nodes, Revit nodes, math nodes, and string nodes; the input parameters are controlled by creating sliders; Step S3: Generate tunnel shape: Use stretch or sweep function and according to the weight factor threshold preset by the custom node in Dynamo, expand the cross section of the tunnel along the set path to form a three-dimensional tunnel geometry; Step S4: Building the tunnel model: Incorporating the three-dimensional tunnel geometry into the Revit project, ensuring that it is associated with other building elements.
[0005] Furthermore, the step S2 also includes: creating custom nodes according to actual needs to implement more complex logic.
[0006] Furthermore, the geometry node, list node, Revit node, math node, and string node in step S2 are specifically: Geometry Nodes include: Polygon.ByPoints: creates polygons, suitable for the design of tunnel sections; Curve.Create: generates curves for defining the path of the tunnel; Surface.ByPatch: generates a surface through a curve; List Nodes include: List.Create: create a list to organize input data; List.Reverse: reverse the order of the list, suitable for path processing; Transform Nodes include: Transform.Identity: Get unit transformation; Transform.Translate: Translate geometry, suitable for the layout of tunnel parts; Revit nodes include: FamilyInstance.ByPoint: creates a family instance at a specified point; Element.SetParameterByName: sets the parameters of an element, including the width and height of the tunnel; Math Nodes include: Math.Add, Math.Subtract: calculate the size and position of the tunnel model; String Nodes include: String.Concat: connects strings, suitable for naming or identifying components.
[0007] Furthermore, other building elements in step S4 include: vehicle passages and pedestrian passages in the tunnel, emergency parking strips, ventilator openings, lighting equipment, fire hydrants, variable information boards, escape distances and instructions.
[0008] Furthermore, the step S4 also includes: setting parameters for the other building elements, the parameters including material, thickness, and connectors.
[0009] Furthermore, before executing the step S1, it includes: installing Revit and Dynamo, wherein Dynamo exists as a plug-in of Revit and can be directly accessed in Revit.
[0010] Furthermore, the method further comprises step S5: verifying and optimizing the tunnel model.
[0011] Furthermore, verifying the tunnel model includes: switching views and performing section checks on the tunnel model in Revit.
[0012] Furthermore, verifying the tunnel model also includes: utilizing the collision detection function in Revit to ensure the safety and feasibility of the three-dimensional tunnel geometry and other surrounding building elements.
[0013] Furthermore, the tunnel model is optimized by optimizing the Dynamo script according to actual needs.
[0014] Compared with the prior art, the present invention has the following beneficial effects: (1) The present invention realizes the modeling of complex paths by creating scripts using Dynamo's own nodes and custom nodes, and the Dynamo script can be adjusted as needed in the later stage to improve the speed and accuracy of model generation, reduce redundant nodes, and improve computing efficiency.
[0015] (2) Parametric design: By setting input parameters, the size and other properties of the tunnel can be quickly adjusted later; and by setting parameters for each component in the tunnel, it can be automatically updated when it is modified later, thus improving the efficiency of model creation.
[0016] (3) In order to ensure the accuracy of the model, the present invention also includes verifying and optimizing the tunnel model.
[0017] In summary, by combining Revit and Dynamo, the present invention can greatly improve the construction efficiency of the tunnel model and achieve a more flexible and intelligent design solution. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.
[0019] Figure 1 This is a flowchart of the method for automatically generating a tunnel model based on Revit and Dynamo according to the present invention. DETAILED DESCRIPTION
[0020] In order to make the purpose, technical scheme and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. Obviously, the specific embodiments described herein are only used to explain the present invention and are part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0021] Example 1 like Figure 1 As shown, an embodiment of the present invention relates to a method for automatically generating a tunnel model based on Revit and Dynamo, the method comprising the following steps: Step S1: Create a tunnel outline: draw the center line or outline of the tunnel in Revit, select different views to depict the shape of the tunnel, and use built-in data to set tunnel parameters; the built-in data is pre-set, and the specific setting method is: collect tunnel data, the data includes: tunnel geometry data, geological data, structural data, tunnel facility data, tunnel environment data; use Revit to link the tunnel data; Before executing step S1, make sure to install Revit and Dynamo. Dynamo exists as a Revit plug-in and can be directly accessed in Revit. Be familiar with the basic operations of Revit and the node logic of Dynamo, and understand how to program and generate models through Dynamo.
[0022] Revit and Dynamo can be used to create smarter and more flexible models through programming, and applied to building information models. The construction industry has always preferred to use visual programming tools such as Dynamo. It does not require special learning to write traditional programming languages, and has powerful and flexible functions. When greater flexibility is required, it is necessary to use programming languages such as Python. Dynamo is a tool that is plug-in to Revit, and the elements provided to the client for interaction are called "nodes". Dynamo can connect predefined nodes in the work interface to set up a set of step-by-step program flows for a certain problem, and solve the problem through the basic logic of input, processing and output.
[0023] Create the tunnel outline: In Revit, use the Sketch tool to draw the centerline or outline of the tunnel. You can choose different views (such as plan or section) to accurately depict the shape of the tunnel. Set the tunnel parameters, such as the diameter, length, slope, etc. of the tunnel.
[0024] Step S2: Create a Dynamo script: set input parameters, and use the nodes provided in Dynamo to create the cross section of the tunnel; the nodes include: geometry nodes, list nodes, Revit nodes, math nodes, and string nodes; the input parameters are controlled by creating sliders; The present invention utilizes various node types in Dynamo, including geometry nodes, list nodes, Revit nodes, math nodes, and string nodes, to create tunnel cross-sections. A Number Slider node is used to create a slider to control input parameters, so that the creation of tunnel cross-sections has parametric characteristics, which is convenient for later modification and adjustment. By combining different nodes, the creation of tunnel cross-section shapes from simple to complex can be achieved.
[0025] Specifically, 1. Open Dynamo: Click the "Manage" tab in Revit and select "Dynamo" to open the Dynamo working environment. 2. Create a script: Node selection: Use the nodes provided in Dynamo to select appropriate geometric shape nodes (such as circle, ellipse) to create the cross section of the tunnel as needed.
[0026] To use Dynamo to model tunnels in Revit, you can use the following specific nodes: (1) Geometry Nodes: Polygon.ByPoints: Creates polygons, suitable for the design of tunnel sections.
[0027] Curve.Create: Generates a curve to define the path of the tunnel.
[0028] Surface.ByPatch: Generate a surface through a curve.
[0029] (2) List Nodes: List.Create: Creates a list to organize input data.
[0030] List.Reverse: Reverses the order of a list, suitable for path processing.
[0031] (3) Transform Nodes: Transform.Identity: Get the unit transform.
[0032] Transform.Translate: Translates the geometry, suitable for the layout of tunnel parts.
[0033] (4) Revit Nodes: FamilyInstance.ByPoint: Creates a family instance at a specified point, including the type and grade of surrounding rock, type and thickness of primary support and secondary lining, longitudinal and circumferential drainage facilities, whether the construction date and subsequent maintenance conditions can be attached.
[0034] Element.SetParameterByName: Sets the parameters of an element, such as the width and height of a tunnel.
[0035] (5) Math Nodes: Math.Add, Math.Subtract: Perform numerical calculations to provide size and position for the model.
[0036] (6) String Nodes: String.Concat: Concatenates strings, suitable for naming or identifying components.
[0037] (7) Custom Nodes: Depending on the requirements, custom nodes can be created to implement more complex logic, such as generating tunnel construction according to specific rules.
[0038] The present invention uses parametric design: input parameters are set so that the size and other properties of the tunnel can be quickly adjusted later. For example, a slider can be created to control the diameter or curvature of the tunnel.
[0039] Step S3: Generate tunnel shape: Use the stretch or sweep function and according to the weight factor threshold preset by the custom node in Dynamo, expand the cross section of the tunnel along the set path to form a three-dimensional tunnel geometry.
[0040] Among them, the three-dimensional tunnel geometry includes the tunnel arch wall, the large pipe shed outside the arch wall, the arch combined hollow grouting anchor rods, the locking foot anchor pipe, the tunnel temporary support frame, etc.
[0041] Due to the different terrains and top pressures borne by different areas of the tunnel, the top pressure received by the tunnel section near the middle area of the tunnel is greater than the pressure borne by the tunnel sections at both ends, and the thickness of the tunnel arch wall near the middle area of the tunnel should be thicker than the thickness of the arch wall of the tunnel sections at both ends. Therefore, in this embodiment, by adding a stretching or sweeping weight factor in the custom node, when using the stretching or sweeping function, different weight factors are assigned to different area segments when stretching or sweeping the tunnel model according to the established weight factor combined with the distance between the middle position of the tunnel and the two ends. For example, the preset weight factor is t, and the preset sketch thickness of the arch wall is h. When using the stretching function, the thickness of the arch wall in the middle position of the tunnel is h*t, the thickness of the arch wall near the edge positions of the two ends of the tunnel is h, and the thickness of the arch wall from the edge position of the tunnel to the middle position of the tunnel is between h~h*t. The specific arch wall thickness is weighted and set according to the distance between the tunnel edge and the tunnel center.
[0042] Furthermore, a support frame model is constructed in a suitable length unit for the generated 3D tunnel model. The support frame model is used to support and repair the top of the tunnel, etc., wherein the support frame model is arranged around the wall and top position area of the tunnel, and includes support frame model units such as frames, diagonal braces, and corners. When using different support frame model units to replace the support frame model constructed in the tunnel, a list node is used to display a list of selectable support frame unit sizes, and all are directly replaced after manual selection. Afterwards, when generating a 2D tunnel model drawing from the 3D tunnel model, a custom node of the Revit node is used to construct a shielding component, and the shielding component is placed at the front end of the support frame unit to be removed from the 3D tunnel model to avoid overlapping of the upper and lower support frame units in the generated 2D tunnel model drawing, which affects the effect of the 2D tunnel model drawing.
[0043] Step S4: Building the tunnel model: Incorporating the three-dimensional tunnel geometry into the Revit project, ensuring that it is associated with other building elements.
[0044] Specifically, the generated tunnel geometry is merged into the Revit project to ensure interrelationship with other building elements. Necessary details are added, such as vehicle and pedestrian passages in the tunnel, emergency parking strips, ventilator openings, lighting equipment, fire hydrants, variable information boards, escape distances and instructions, etc. Parameters are set for each component in the tunnel so that it can be automatically updated when modified later. By merging the tunnel model, the entire project can be displayed on a visual platform, and different professionals can check whether the design is reasonable from different perspectives. For example, architects can view the relationship between the tunnel and the building as a whole from the perspective of building appearance and space utilization, and structural engineers can evaluate the design from the perspective of mechanics and structure to improve the overall quality of the design. In summary, merging the 3D tunnel geometry into the Revit project and ensuring interrelationship with other building elements can improve the work efficiency and quality of multiple stages such as design, construction, and operation, realize the effective integration and sharing of information, and promote multi-professional collaborative work.
[0045] Step S5: verifying and optimizing the tunnel model.
[0046] Specifically, in order to ensure the accuracy of the model, the present invention also verifies and optimizes the tunnel model: ① Check the model: In Revit, the generated tunnel model is switched and sectioned to confirm its accuracy and rationality. ② Optimize the script: Adjust the Dynamo script as needed to improve the speed and accuracy of model generation, reduce redundant nodes, and improve calculation efficiency. ③ Perform collision detection: Use the collision detection function in Revit to ensure the safety and feasibility of the tunnel and surrounding structures, and discover design problems in a timely manner.
[0047] By combining Revit and Dynamo, the present invention can greatly improve the efficiency of tunnel model construction and achieve a more flexible and intelligent design solution. This method is not only applicable to tunnel engineering, but can also be extended to other types of tunnel projects, providing strong support for digital construction.
[0048] The above embodiments only express the preferred implementation mode of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the scope of the patent of the present invention. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be subject to the attached claims.
Claims
1. A method for automatically generating a tunnel model based on Revit and Dynamo, characterized in that: The following steps are involved: Step S1: Create tunnel outline: Draw the centerline or outline of the tunnel in Revit, select different views to depict the shape of the tunnel, and use built-in data to set tunnel parameters; The built-in data is pre-set, and the specific setting method is: collect tunnel data, the data includes: tunnel geometry data, geological data, structural data, tunnel facility data, tunnel environment data; use Revit to link the tunnel data; Step S2: Create a Dynamo script: set input parameters, and use the nodes provided in Dynamo to create the cross section of the tunnel; the nodes include: geometry nodes, list nodes, Revit nodes, math nodes, and string nodes; the input parameters are controlled by creating sliders; Step S3: Generate tunnel shape: Use stretch or sweep function and according to the weight factor threshold preset by the custom node in Dynamo, expand the cross section of the tunnel along the set path to form a three-dimensional tunnel geometry; Step S4: Building the tunnel model: Incorporating the three-dimensional tunnel geometry into the Revit project, ensuring that it is associated with other building elements.
2. The method for automatically generating a tunnel model based on Revit and Dynamo according to claim 1, characterized in that: The step S2 also includes: creating custom nodes according to actual needs to implement more complex logic.
3. The method for automatically generating a tunnel model based on Revit and Dynamo according to claim 1, characterized in that: The geometry node, list node, Revit node, math node, and string node in step S2 are specifically: Geometry Nodes include: Polygon.ByPoints: creates polygons, suitable for the design of tunnel sections; Curve.Create: generates curves for defining the path of the tunnel; Surface.ByPatch: generates a surface through a curve; List Nodes include: List.Create: create a list to organize input data; List.Reverse: reverse the order of the list, suitable for path processing; Transform Nodes include: Transform.Identity: Get unit transformation; Transform.Translate: Translate geometry, suitable for the layout of tunnel parts; Revit nodes include: FamilyInstance.ByPoint: creates a family instance at a specified point; Element.SetParameterByName: sets the parameters of an element, including the width and height of the tunnel; Math Nodes include: Math.Add, Math.Subtract: calculate the size and position of the tunnel model; String Nodes include: String.Concat: connects strings, suitable for naming or identifying components.
4. The method for automatically generating a tunnel model based on Revit and Dynamo according to claim 1, characterized in that: Other building elements in step S4 include: vehicle and pedestrian passages in the tunnel, emergency parking strips, ventilation fan openings, lighting equipment, fire hydrants, variable information boards, escape distances and instructions.
5. The method for automatically generating a tunnel model based on Revit and Dynamo according to claim 4, characterized in that: The step S4 further includes: setting parameters for the other building elements, the parameters including material, thickness, and connectors.
6. The method for automatically generating a tunnel model based on Revit and Dynamo according to claim 4, characterized in that: Before executing the step S1, the process includes: installing Revit and Dynamo, wherein Dynamo exists as a plug-in of Revit and can be directly accessed in Revit.
7. The method for automatically generating a tunnel model based on Revit and Dynamo according to claim 1, characterized in that: The method further comprises step S5: verifying and optimizing the tunnel model.
8. The method for automatically generating a tunnel model based on Revit and Dynamo according to claim 7, characterized in that: Verifying the tunnel model includes: switching views and performing section checks on the tunnel model in Revit.
9. The method for automatically generating a tunnel model based on Revit and Dynamo according to claim 8, characterized in that: Validation of the tunnel model also includes utilizing collision detection capabilities in Revit to ensure the safety and feasibility of the 3D tunnel geometry with other surrounding building elements.
10. The method for automatically generating a tunnel model based on Revit and Dynamo according to claim 7, characterized in that: The optimization of the tunnel model is specifically as follows: optimizing the Dynamo script according to actual needs.
Citation Information
Patent Citations
rapid modeling method based on Revit and Dynamo parameterization tunnel models
CN109800536A
Mining-method tunnel parametric modeling method and device based on Revit and Dynamo
CN111159808A
Parameterized TBM shield tunnel model establishing method
CN112906106A