BIM-based automatic extraction method of engineering quantity, electronic device and medium
By acquiring the bounding box and geometric information of the components, and combining the medium resistance value and construction sequence level, the problem of inaccurate determination of voxel block ownership was solved, and the accuracy and effectiveness of engineering quantity calculation were achieved.
Patent Information
- Application Number
- CN202610422567.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-04-01
- Publication Date
- 2026-06-26
AI Technical Summary
Existing technologies, when using morphological dilation algorithms to process BIM models, struggle to accurately determine the ownership of voxel blocks, leading to errors in quantity calculations and affecting the effectiveness of these calculations.
By acquiring the bounding box of the component, the conflict area of the component is determined, and path search calculation is performed based on geometric information and medium resistance value. Combining the construction sequence level and discretization resolution, the final assignment of the voxel block is determined, and the engineering quantity data is calculated and its validity is judged.
It improves the accuracy of quantity calculations, ensures that the quantity data is closer to the actual situation, and reduces errors in filling and calculation deviations.
Smart Images

Figure CN122286914A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of engineering quantity analysis technology, specifically to a BIM-based automatic engineering quantity extraction method, electronic equipment, and medium. Background Technology
[0002] In the field of construction cost estimation and construction management, quantity calculation is the foundation for key aspects such as project planning, cost control, and schedule arrangement. Accurate quantity calculation relies on precise geometric analysis of each component entity in the Building Information Model (BIM). According to the requirements of construction cost specifications, when different types of components overlap in space (such as the intersection of a concrete column and a masonry wall, or the intersection of a beam and a slab), the overlapping volume must be deducted to obtain the true net quantity of work.
[0003] However, BIM model data generally contains geometric defects. Due to the accuracy limitations of modeling software or human error, there may be missing parts or tiny gaps on the surface of components. These geometric defects destroy the closure of the entity. Therefore, existing technologies usually use morphological dilation algorithms to process and repair them. However, such methods are usually voxelization methods for the entire model. Moreover, this indiscriminate filling method is difficult to accurately determine the ownership of voxel blocks, which can easily lead to incorrect filling and affect subsequent engineering quantity calculations and validity determination. Summary of the Invention
[0004] To address potential defects or minute gaps on component surfaces, morphological dilation algorithms are typically used for full-model voxelization during repair. However, this indiscriminate filling method struggles to accurately determine voxel assignments, leading to erroneous filling and impacting subsequent quantity calculations and validity assessments. This invention aims to provide a BIM-based automatic quantity extraction method, electronic equipment, and medium. The specific technical solution adopted is as follows: A method for automatic quantity extraction of engineering works based on BIM, the method comprising: Obtain the bounding box of each component and determine the component conflict region based on the positional relationship between the bounding boxes of different components. The component conflict region is composed of voxel blocks, and the component corresponding to each component conflict region is denoted as the target component. In the component conflict zone, the initial component affiliation of each voxel block is determined based on geometric information and the medium resistance value is calculated; In the component conflict area, the source point unit corresponding to each target component is determined according to the position characteristics of the voxel block; the path search calculation is performed based on the source point unit, and the cumulative cost corresponding to each voxel block under each target component is determined by combining the construction sequence level of the target component, the discretization resolution of the voxel block and the medium resistance value. The final component ownership of each voxel block is determined based on the cumulative cost corresponding to the voxel block in the component conflict area; the engineering quantity data is calculated and its validity is determined based on the changing characteristics of the component ownership of the voxel blocks in the component conflict area, the location distribution characteristics of the voxel blocks, and the discretization resolution.
[0005] Furthermore, the method for obtaining the component conflict region includes: The bounding box of each component is expanded according to the preset buffer distance to obtain the outer expansion area corresponding to each component; For any two components, determine whether their outer regions intersect. If they intersect, take the intersection of their outer regions as the component conflict region and divide the component conflict region into voxel blocks based on the preset discretization resolution.
[0006] Furthermore, the step of determining the initial component affiliation of each voxel block based on geometric information and calculating the medium resistance value includes: In each component conflict area, the center coordinates of each voxel block are obtained, and detection rays are emitted along the positive directions of the three orthogonal axes, starting from the center coordinates of each voxel block. The number of intersections between the detection ray in each preset direction and the geometric facet of each target component is counted. If the number is odd, the detection result in the positive direction of each orthogonal axis is considered to be inside the target component; otherwise, it is considered to be outside the target component. When the detection result of a voxel block in the positive direction of at least two preset orthogonal axes is inside a target component, the initial component affiliation of the voxel block is the target component, and the medium resistance value of the voxel block is the first preset resistance value; otherwise, the initial component affiliation of the voxel block is empty, and the medium resistance value is the second preset resistance value, wherein the first preset resistance value is less than the second preset resistance value.
[0007] Furthermore, the method for obtaining the source point unit includes: In each component conflict zone, for any target component; First-level extraction of voxel blocks: If a voxel block belongs to the target component, and the neighboring voxel blocks within the preset range of the voxel block also belong to the target component, then the voxel block is the source point unit of the target component. If the source point unit extracted in the first stage is empty, then the second stage extraction is performed: the voxel block belonging to the target component is taken as the source point unit. If the source point unit of the secondary extraction is empty, then the tertiary extraction is performed: obtain the geometric center of the bounding box of the target component, take the voxel block with the smallest distance from the geometric center in the component conflict area as the source point unit, and set the medium resistance value of the source point unit to the first preset resistance value.
[0008] Furthermore, the method for obtaining the cumulative cost includes: In the component conflict area, the expansion difficulty weight is calculated according to the construction sequence level of each target component; The step size between adjacent voxel blocks is determined based on the discretization resolution of the voxel blocks; In all source units of each target component, 0 is used as the cumulative cost of each source unit, and all source units are added to the unprocessed set, with infinity used as the cumulative cost of all remaining voxel blocks. Select the voxel block with the minimum cumulative cost from the set to be processed as the search starting point, and remove the voxel block from the set to be processed; Within the local range of the search starting point, calculate the new cumulative cost for each neighboring voxel block of the starting point. The formula model includes: in, This represents the new cumulative cost for each adjacent prime block; Indicates the cumulative cost at the starting point of the search; This represents the dielectric resistance value of each adjacent bulk element; Indicates the difficulty weight of expanding the target component; Indicates the step size; If the new cumulative cost of the neighboring voxel is less than the current cumulative cost of the neighboring voxel, then update the cumulative cost of the neighboring voxel to the new cumulative cost and add the neighboring voxel to the set to be processed. The search process is repeated until the set to be processed is empty, and the cumulative cost of each voxel block in the component conflict region under each target component is obtained.
[0009] Furthermore, the formula model for the expansion difficulty weight includes: in, This represents the expansion difficulty weight for each target component; This indicates the construction sequence level of each target component; Let represent the logarithmic function with the natural logarithm e as the base.
[0010] Furthermore, the method for obtaining the final component ownership status includes: In the component conflict region, for any voxel block, determine the minimum cumulative cost among the cumulative costs of that voxel block under all target components; If the minimum cumulative cost is less than the preset effective cost threshold, the final component assignment of the voxel block is the target component corresponding to the minimum cumulative cost; otherwise, the final component assignment of the voxel block is empty.
[0011] Furthermore, the calculation and validity determination of the engineering quantity data includes: The volume of each voxel block is determined based on the discretization resolution; In a component conflict area, if the final component ownership of a voxel block is not empty, but the initial component ownership is empty, the voxel block is used as a filler unit. For any filling unit, the voxel block whose initial component assignment is the same as the final component assignment of the filling unit is used as the comparison block. The Euclidean distance between the filling unit and each comparison block is calculated. If the minimum Euclidean distance is greater than the preset distance threshold, the filling unit is regarded as an abnormal change unit. If the filling unit does not have a corresponding comparison block, the filling unit is directly marked as an abnormal change unit. The value obtained by negatively mapping the ratio of the number of abnormal change units to the number of fill units is used as the geometric restoration index. When the geometric accuracy index is greater than or equal to the preset accuracy threshold, the engineering quantity is determined to be valid, and the number of voxel blocks corresponding to each target component is multiplied by the volume of each voxel block in the component conflict area to obtain the net volume of each target component in the component conflict area. When the geometric accuracy index is less than the preset accuracy threshold, the engineering quantity is deemed invalid and an early warning is required.
[0012] An electronic device for automatic quantity extraction based on BIM includes a processor and a memory. The memory stores at least one instruction, at least one program, code set, or instruction set. When the processor loads and executes the at least one instruction, at least one program, code set, or instruction set, it implements the steps of an automatic quantity extraction method based on BIM.
[0013] A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of a BIM-based automatic quantity extraction method.
[0014] The present invention has the following beneficial effects: The bounding box of each component is obtained, and the conflict regions are determined based on the positional relationships between the bounding boxes of different components. This allows for the precise location of conflicting parts in the model. The conflict regions are discretized into voxel blocks, and the target component corresponding to each conflict region is clearly identified, facilitating detailed processing of each voxel block and improving computational accuracy. Within the component conflict regions, the initial component affiliation of each voxel block is determined based on geometric information. The influence of the physical characteristics between components on voxel block affiliation is considered, and this influence is quantified using medium resistance values. When performing path search, a starting point needs to be determined. To prevent incorrect starting positions due to model damage, the source element corresponding to each target component is determined based on the positional characteristics of the voxel blocks, providing a reasonable starting point for path search. Furthermore, path search calculations are performed using source point units, and the cumulative cost of each voxel block under each target component is determined by combining the construction sequence level of the target component, the discretization resolution of the voxel block, and the medium resistance value. The construction sequence level reflects the order of components in actual construction, the discretization resolution reflects the precision of the calculation, and the medium resistance value considers physical characteristics. Combining these factors to calculate the cumulative cost allows for a more comprehensive and accurate assessment of the correlation between each voxel block and different target components, thus providing a more accurate basis for determining the final assignment of voxel blocks. Finally, the engineering quantity data is calculated based on the changing characteristics of the component assignment of voxel blocks in the component conflict area, the location distribution characteristics of the voxel blocks, and the discretization resolution. This fully considers various characteristic information of voxel blocks in the conflict area, which can more realistically reflect the actual relationship and spatial distribution between components, thus making the calculated engineering quantity data closer to the actual situation and improving the accuracy of the engineering quantity calculation. Attached Figure Description
[0015] To more clearly illustrate the technical solutions and advantages in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0016] Figure 1 A flowchart illustrating a BIM-based automatic quantity extraction method according to an embodiment of the present invention; Figure 2 A schematic diagram of a BIM-based automatic quantity extraction electronic device provided in one embodiment of the present invention; Figure 3 This is a schematic diagram of a computer-readable storage medium provided in one embodiment of the present invention. Detailed Implementation
[0017] To further illustrate the technical means and effects adopted by the present invention to achieve its intended purpose, the following, in conjunction with the accompanying drawings and preferred embodiments, details the specific implementation, structure, features, and effects of a BIM-based automatic quantity extraction method, electronic device, and medium proposed according to the present invention. In the following description, different "one embodiment" or "another embodiment" do not necessarily refer to the same embodiment. Furthermore, specific features, structures, or characteristics in one or more embodiments can be combined in any suitable form.
[0018] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains.
[0019] The following description, in conjunction with the accompanying drawings, details the specific scheme of the BIM-based automatic quantity extraction method, electronic equipment, and medium provided by this invention.
[0020] Please see Figure 1 The diagram illustrates a flowchart of a BIM-based automatic quantity extraction method according to an embodiment of the present invention, which includes the following steps: Step S1: Obtain the bounding box of each component and determine the component conflict area based on the positional relationship between the bounding boxes of different components. The component conflict area is composed of voxel blocks, and the component corresponding to each component conflict area is denoted as the target component.
[0021] To avoid invalid calculations for irrelevant regions, this step requires identifying areas in the model that may overlap or require repair.
[0022] First, detailed information for each component is extracted from the integrated BIM model, including its geometry, dimensions, and location. BIM software is then used to automatically identify different types of components, such as walls, columns, beams, and floor slabs. Next, the bounding box of each component in the model is obtained: using the axisymmetric bounding box (AABB) algorithm, the maximum and minimum values in the three positive X, Y, and Z axes are found by traversing the vertex coordinates of the component, thus determining the boundary of the bounding box and obtaining the bounding box for each component.
[0023] Then the positional relationship between the bounding boxes of different components can be analyzed to determine the conflict areas of the components, that is, the areas where overlap may occur or where repair is needed.
[0024] Preferably, in one embodiment of the present invention, the method for obtaining the component conflict region includes: In real-world modeling, there are often tiny gaps between components (errors or design allowances), causing components that should intersect / deduct to actually not intersect geometrically. Therefore, an expansion operation can be added to artificially create overlapping areas, bringing adjacent components into the same computational domain and providing physical space for subsequent crack repair.
[0025] The bounding box of each component is expanded according to a preset buffer distance: the bounding box of each component is expanded outward along the three positive directions X, Y, and Z by a preset buffer distance (set to 0.1 meters in this embodiment; the specific size can be adjusted according to the implementation scenario to adapt to the gap tolerance requirements under different modeling accuracies) to obtain the corresponding expansion area of each component.
[0026] Then, for any two components, it is determined whether their outer expansion regions intersect. If they intersect, the intersection region of the outer expansion regions of the two components is taken as the component conflict region, and the component conflict region is divided into voxel blocks based on a preset discretization resolution (the value is 0.01 meters, i.e., 10 millimeters in this embodiment). At this time, the component conflict region is divided into several regular cubic units.
[0027] At this point, all component conflict areas can be obtained, and the component corresponding to each component conflict area (that is, the component that intersects with the expanded area) is taken as the target component. Each component conflict area corresponds to at least two target components.
[0028] Step S2: In the component conflict zone, determine the initial component affiliation of each voxel block based on geometric information and calculate the medium resistance value.
[0029] To help identify whether a voxel block exists inside a component or in the background air in a component conflict zone, geometric information can be analyzed in the component conflict zone to determine the initial component affiliation of each voxel block and to calculate the medium resistance value of each voxel block. The initial component affiliation can be used to characterize the affiliation features of the voxel block, while the medium resistance value helps to describe the influence of the physical properties between the components on the affiliation features of the voxel block in subsequent processes.
[0030] Preferably, in one embodiment of the present invention, determining the initial component affiliation of each voxel block based on geometric information and calculating the medium resistance value includes: In each component conflict area, the center coordinates of each voxel block are obtained (which can be calculated based on the three-dimensional coordinate position of each voxel block and the preset discrete resolution), and detection rays are emitted along the positive directions of the three orthogonal axes, starting from the center coordinates of each voxel block.
[0031] According to the basic principles of geometric topology, when a ray intersects a geometric facet of a closed object, it enters the object once and exits the object once. Therefore, if the number of intersection points is even, the ray is outside the object; if it is odd, it is inside the object. Thus, the number of intersection points between the detection ray in each preset direction and the geometric facet of each target component is counted. If the number is odd, the detection result in the positive direction of each orthogonal axis is considered to be inside the target component; otherwise, it is considered to be outside the target component.
[0032] Then, when the detection result of a voxel block in the positive direction of at least two preset orthogonal axes is inside a target component, the initial component affiliation of the voxel block is the target component. In actual engineering, in order to guide the subsequent propagation path to propagate preferentially inside the component entity, an index that can describe the passage difficulty can be constructed. Therefore, in this case, the medium resistance value of the voxel block is the first preset resistance value; otherwise, the initial component affiliation of the voxel block is empty (meaning outside the target component), and the medium resistance value is the second preset resistance value, wherein the first preset resistance value is less than the second preset resistance value.
[0033] It should be noted that, in this embodiment of the invention, the first preset resistance value is set to a very small positive number, such as 10. -6 The second preset resistance value can be set to 1. Setting the second preset resistance value to a million times that of the first preset resistance value means that there will be a huge cost during subsequent path searching, effectively suppressing the path search from spreading into unexpected background air. Adjustments can be made in other embodiments of the invention depending on the implementation scenario, and are not limited here. If the initial component affiliation of a voxel block belongs to multiple target components, the determination is made based on distance characteristics: the voxel block is assigned to the target component with the closest distance (the minimum Euclidean distance between it and the geometric facet).
[0034] Step S3: In the component conflict area, determine the source element corresponding to each target component based on the positional characteristics of the voxel block; perform path search calculation based on the source element, and determine the cumulative cost of each voxel block under each target component by combining the construction sequence level of the target component, the discretization resolution of the voxel block and the medium resistance value.
[0035] In this step, path searching can be performed in the component conflict area, using the path competition mechanism instead of rigid Boolean operations. This is the core step for subsequent accurate calculation of engineering quantities.
[0036] First, the source element needs to be determined in the component conflict area, which is the starting position for path search. In general, to prevent incorrect starting positions due to model edge damage, the source element determination strategy is adopted from the inside out in this step.
[0037] Preferably, in one embodiment of the present invention, the method for obtaining the source point unit includes: In each component conflict zone, for any target component.
[0038] First, a primary extraction is performed on the voxel blocks in the component conflict area: the "safest and most advantageous" internal core point is selected. If a voxel block belongs to the target component, and its neighboring voxel blocks within a preset range also belong to the target component, it indicates that the voxel block is located more at the core of the target component. Therefore, this voxel block is used as the source point unit of the target component. It should be noted that in this embodiment of the invention, the preset range is set to a 3*3*3 grid, which is a 26-neighborhood.
[0039] If the source element extracted in the first stage is empty and no suitable source element can be found, then the second stage extraction is performed: a more lenient source element determination method is set, that is, the voxel block belonging to the target component is directly used as the source element.
[0040] Finally, if the source unit extracted in the second stage is also empty, then the third stage extraction is performed: the geometric center of the bounding box of the target component is obtained, and the voxel block with the smallest distance from the geometric center in the component's conflict area is taken as the source unit. Although it may not be completely inside the target component, it is relatively close to the geometric center of the target component in space, which has a certain degree of rationality and representativeness. At the same time, the medium resistance value of the source unit obtained at this time is set as the first preset resistance value (10 in this embodiment of the invention). -6 In order to ensure that the source point unit in this case has the same expansion rate as the voxel block inside the target component in the subsequent process.
[0041] After obtaining the source element corresponding to each target component in the component conflict area, path search calculation can be performed based on the source element. At the same time, since different component types correspond to different construction sequence levels in actual engineering, and different construction sequence levels correspond to different levels of importance, generally, the higher the construction sequence level, the more important the structure is, that is, the earlier the construction stage. Furthermore, the discretization resolution of the voxel block can be used as a physical distance metric, and the medium resistance value can be used for spatial guidance. Therefore, when performing path search calculation, the aforementioned multiple features are also combined to determine the cumulative cost corresponding to each voxel block under each target component.
[0042] Preferably, in one embodiment of the present invention, the method for obtaining the cumulative cost includes: In the component conflict zone, the expansion difficulty weight is calculated based on the construction sequence level of each target component. The formula model for the expansion difficulty weight includes: in, This represents the expansion difficulty weight for each target component; This indicates the construction sequence level of each target component; Let represent the logarithmic function with the natural logarithm e as the base.
[0043] Since a higher construction sequence level indicates a more important structure, the expansion difficulty should be lower, resulting in a smaller cost increase in subsequent path searches. Therefore, a negative correlation mapping is needed for the construction sequence levels. In the formula model for the expansion difficulty weight, the construction sequence levels are first numerically smoothed using a logarithmic function, and then a negative correlation mapping is performed using ratios to obtain the expansion difficulty weight. At this point, a higher expansion difficulty weight is considered to result in a greater cost increase in subsequent path searches. The construction sequence level can be determined according to construction requirements; for example, the construction sequence level for a wall is 5, for a decorative layer it is 1, and for a structural column it is 10.
[0044] The step size between adjacent voxel blocks is determined based on the discretization resolution of the voxel blocks. In this embodiment of the invention, the step size is 0.01 meters.
[0045] Furthermore, in all source point units of each target component, 0 is used as the cumulative cost of each source point unit (that is, the core source point of the component has no cost), and all source point units are added to the set to be processed, and infinity is used as the cumulative cost of all remaining voxel blocks (that is, the unexplored area).
[0046] Next, using Dijkstra's core logic, the voxel block with the minimum cumulative cost is selected from the set of objects to be processed as the search starting point, and this voxel block is removed from the set of objects to be processed. Within the local range of the search starting point, the new cumulative cost of each adjacent voxel block of the starting point is calculated. The formula model includes: in, This represents the new cumulative cost for each adjacent prime block; Indicates the cumulative cost at the starting point of the search; This represents the dielectric resistance value of each adjacent bulk element; Indicates the difficulty weight of expanding the target component; Indicates the step size.
[0047] In the above formula model, the new cumulative cost of each adjacent voxel can be divided into two parts. One part is the cumulative cost of the search starting point, representing the "total cost" experienced when reaching the search starting point from the source unit of the component. The other part is the "new cost" required to reach the adjacent voxel from the search starting point, which is composed of the product of three indices: the medium resistance value reflects the difficulty; the larger the value, the more likely the adjacent voxel is located in the background air rather than in the component entity, thus increasing the resistance and cost; the expansion difficulty weight reflects its own capability; the larger the value, the lower the priority of the target component, the greater the expansion difficulty, and the higher the cost; the step size represents the physical distance; similarly, the larger the value, the greater the cost. Therefore, the larger the product of these three indices, the greater the cost required to reach the adjacent voxel from the search starting point. Finally, the previous total cost is... With the new cost of this step The sum of the values is used as the new cumulative cost to reach each adjacent prime block.
[0048] If the new cumulative cost of an adjacent voxel is less than the current cumulative cost (old cumulative cost) of the adjacent voxel, then update the cumulative cost of the adjacent voxel to the new cumulative cost (path optimization) and add the adjacent voxel to the set to be processed.
[0049] Finally, the search process is repeated until the set to be processed is empty, and then the cumulative cost of each voxel block in the component conflict area under each target component can be obtained.
[0050] It should be noted that the adjacent voxel blocks here are the voxel blocks that are directly above, below, in front of, and behind the search starting point.
[0051] Step S4: Determine the final component ownership of each voxel block based on the cumulative cost corresponding to the voxel block in the component conflict area; calculate the quantity data and determine its validity based on the changing characteristics of the component ownership of the voxel blocks in the component conflict area, the location distribution characteristics of the voxel blocks, and the discretization resolution.
[0052] Based on the aforementioned steps, the cumulative cost of each voxel block in each component conflict area under each target component can be obtained. Therefore, in this step, the final spatial allocation can be carried out based on this index, that is, the final component ownership of each voxel block can be determined.
[0053] Preferably, in one embodiment of the present invention, the method for obtaining the final component ownership status includes: In each component conflict region, for any voxel block, the minimum cumulative cost is determined among the cumulative costs of the voxel block under all target components. The minimum cumulative cost represents the most reasonable and most likely choice among all possible ownership scenarios of the voxel block.
[0054] If the minimum cumulative cost is less than the preset effective cost threshold, the final component assignment of the voxel block is the target component corresponding to the minimum cumulative cost; otherwise, it is considered that the voxel block has weak correlation with all target components. Therefore, in this case, the final component assignment of the voxel block is empty.
[0055] It should be noted that in this embodiment of the present invention, the preset effective cost threshold is set to 0.5, which has the same dimension as the cumulative cost. In other embodiments of the present invention, it can be changed according to the implementation scenario, and is not limited here.
[0056] After determining the final component ownership of each voxel block in each component conflict area, it can be compared with the initial component ownership to identify the ownership change characteristics of the voxel block. At the same time, in order to avoid the influence of the component's own size on the cumulative cost, the positional distribution characteristics of the voxel block can be introduced as a standard for anomaly review, and combined with discretization resolution, engineering quantity data can be calculated and validity determined.
[0057] Preferably, in one embodiment of the present invention, the calculation and validity determination of engineering quantity data includes: The volume of a voxel is a key basic data for calculating engineering quantities. Therefore, the volume of each voxel is first determined according to the discretization resolution. For example, in this embodiment of the present invention, the volume calculation formula is 0.01 m × 0.01 m × 0.01 m.
[0058] In a component conflict area, if the final component ownership of a voxel block is not empty, but the initial component ownership is empty, the voxel block is used as a filling unit. This means that the voxel block originally existed in the air background area, but after the algorithm processing, it became a voxel block of a solid component. Then, such voxel blocks are regarded as the volume part added to close cracks or occupy overlapping space.
[0059] To address the risk of the algorithm incorrectly filling wide design gaps (such as expansion joints), a hard constraint based on geometric distance is introduced: Since voxel blocks belonging to the same component should be relatively concentrated in space under normal circumstances, for any filling unit, voxel blocks with the same initial component affiliation as the final component affiliation of that filling unit are used as comparison blocks. Then, the Euclidean distance between the filling unit and each comparison block is calculated. If the minimum Euclidean distance is greater than a preset distance threshold, it indicates an abnormal change in the affiliation of the filling unit, most likely incorrectly crossing a wide design gap, constituting abnormal over-repair. Therefore, this filling unit is designated as an abnormal change unit. It should be noted that in this embodiment of the invention, the preset distance threshold is 0.05 meters, representing the maximum half-width of the crack that is allowed to automatically close. The specific value can be adjusted according to the implementation scenario and is not limited here. It should also be noted that if a filling unit does not have a corresponding comparison block, the filling unit is directly marked as an abnormal change unit.
[0060] The ratio of the number of abnormal change units to the number of fill units is calculated. A larger ratio indicates a higher degree of abnormality, meaning that the geometry of the component deviated during the restoration process, resulting in a lower degree of restoration. Therefore, this ratio is subjected to negative correlation mapping to obtain a geometric restoration index. A larger geometric restoration index indicates a better restoration and higher reliability. Since this ratio is less than 1, the negative correlation mapping can be performed using the formula... , where x represents the independent variable. It should be noted that if the number of filling units is 0, it indicates that the geometric quality of the model is high, and the set fidelity index can be directly set to 1.
[0061] When the geometric accuracy index is greater than or equal to the preset accuracy threshold, the quantity of work is determined to be valid. In the component conflict area, the number of voxel blocks corresponding to each target component is multiplied by the volume of each voxel block to obtain the net volume of each target component in the component conflict area. Conversely, when the geometric accuracy index is less than the preset accuracy threshold, the quantity of work is determined to be invalid and an early warning needs to be issued.
[0062] It should be noted that in this embodiment of the present invention, the preset fidelity threshold is 0.85, and the specific value can be adjusted according to the implementation scenario, and is not limited here.
[0063] In summary, by acquiring the bounding box of each component and determining the component conflict regions based on the positional relationships between the bounding boxes of different components, the conflicting parts in the model can be accurately located. The component conflict regions are discretized into voxel blocks, and the target component corresponding to each conflict region is clearly identified, facilitating subsequent detailed processing of each voxel block and improving computational accuracy. Within the component conflict regions, the initial component affiliation of each voxel block is determined based on geometric information, considering the influence of the physical characteristics between components on voxel block affiliation, and quantifying this influence using medium resistance values. When performing path search, a starting point needs to be determined. To prevent incorrect starting positions due to model damage, the source point element corresponding to each target component is determined based on the positional characteristics of the voxel blocks, providing a reasonable starting point for path search. Furthermore, path search calculations are performed using source point units, and the cumulative cost of each voxel block under each target component is determined by combining the construction sequence level of the target component, the discretization resolution of the voxel block, and the medium resistance value. The construction sequence level reflects the order of components in actual construction, the discretization resolution reflects the precision of the calculation, and the medium resistance value considers physical characteristics. Combining these factors to calculate the cumulative cost allows for a more comprehensive and accurate assessment of the correlation between each voxel block and different target components, thus providing a more accurate basis for determining the final assignment of voxel blocks. Finally, the engineering quantity data is calculated based on the changing characteristics of the component assignment of voxel blocks in the component conflict area, the location distribution characteristics of the voxel blocks, and the discretization resolution. This fully considers various characteristic information of voxel blocks in the conflict area, which can more realistically reflect the actual relationship and spatial distribution between components, thus making the calculated engineering quantity data closer to the actual situation and improving the accuracy of the engineering quantity calculation.
[0064] This invention also provides an electronic device for automatic quantity extraction based on BIM. Please refer to [link / reference]. Figure 2 The diagram illustrates the structure of an electronic device, including a processor 200, a memory 201, a bus 202, and a communication interface 203. The processor 200, communication interface 203, and memory 201 are connected via the bus 202. The memory 201 may contain high-speed random access memory, and the bus 202 may be an ISA bus, PCI bus, or EISA bus, etc. The processor 200 may be an integrated circuit chip with signal processing capabilities. The memory 201 stores at least one instruction, at least one program, code set, or instruction set. When the processor loads and executes the at least one instruction, at least one program, code set, or instruction set, it implements the steps in a BIM-based automatic quantity extraction method.
[0065] This invention also provides a computer-readable storage medium corresponding to the method provided in the foregoing embodiments. Please refer to [link to relevant documentation]. Figure 3 The storage medium shown is an optical disc, on which a computer program (i.e., a program product) is stored. When the computer program is run by a processor, it executes the methods provided in any of the foregoing embodiments.
[0066] It should be noted that examples of the computer-readable storage medium may also include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), read-only memory (ROM), and other optical and magnetic storage media, which will not be elaborated here.
[0067] It should be noted that the order of the above embodiments of the present invention is merely for descriptive purposes and does not represent the superiority or inferiority of the embodiments. The processes depicted in the accompanying drawings do not necessarily require a specific or sequential order to achieve the desired result. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0068] The various embodiments in this specification are described in a progressive manner. The same or similar parts between the various embodiments can be referred to each other. Each embodiment focuses on describing the differences from other embodiments.
Claims
1. A method for automatic quantity extraction of engineering works based on BIM, characterized in that, The method includes: Obtain the bounding box of each component and determine the component conflict region based on the positional relationship between the bounding boxes of different components. The component conflict region is composed of voxel blocks, and the component corresponding to each component conflict region is denoted as the target component. In the component conflict zone, the initial component affiliation of each voxel block is determined based on geometric information and the medium resistance value is calculated; In the component conflict area, the source point unit corresponding to each target component is determined according to the position characteristics of the voxel block; the path search calculation is performed based on the source point unit, and the cumulative cost corresponding to each voxel block under each target component is determined by combining the construction sequence level of the target component, the discretization resolution of the voxel block and the medium resistance value. The final component ownership of each voxel block is determined based on the cumulative cost corresponding to the voxel block in the component conflict area; the engineering quantity data is calculated and its validity is determined based on the changing characteristics of the component ownership of the voxel blocks in the component conflict area, the location distribution characteristics of the voxel blocks, and the discretization resolution.
2. The method for automatic quantity extraction of engineering works based on BIM according to claim 1, characterized in that, The method for obtaining the component conflict region includes: The bounding box of each component is expanded according to the preset buffer distance to obtain the outer expansion area corresponding to each component; For any two components, determine whether their outer regions intersect. If they intersect, take the intersection of their outer regions as the component conflict region and divide the component conflict region into voxel blocks based on the preset discretization resolution.
3. The method for automatic quantity extraction of engineering works based on BIM according to claim 1, characterized in that, The process of determining the initial component affiliation of each voxel block based on geometric information and calculating the medium resistance value includes: In each component conflict area, the center coordinates of each voxel block are obtained, and detection rays are emitted along the positive directions of the three orthogonal axes, starting from the center coordinates of each voxel block. The number of intersections between the detection ray in each preset direction and the geometric facet of each target component is counted. If the number is odd, the detection result in the positive direction of each orthogonal axis is considered to be inside the target component; otherwise, it is considered to be outside the target component. When the detection result of a voxel block in the positive direction of at least two preset orthogonal axes is inside a target component, the initial component affiliation of the voxel block is the target component, and the medium resistance value of the voxel block is the first preset resistance value; otherwise, the initial component affiliation of the voxel block is empty, and the medium resistance value is the second preset resistance value, wherein the first preset resistance value is less than the second preset resistance value.
4. The method for automatic quantity extraction of engineering works based on BIM according to claim 1, characterized in that, The method for obtaining the source point unit includes: In each component conflict zone, for any target component; First-level extraction of voxel blocks: If a voxel block belongs to the target component, and the neighboring voxel blocks within the preset range of the voxel block also belong to the target component, then the voxel block is the source point unit of the target component. If the source point unit extracted in the first stage is empty, then the second stage extraction is performed: the voxel block belonging to the target component is taken as the source point unit. If the source point unit of the secondary extraction is empty, then the tertiary extraction is performed: obtain the geometric center of the bounding box of the target component, take the voxel block with the smallest distance from the geometric center in the component conflict area as the source point unit, and set the medium resistance value of the source point unit to the first preset resistance value.
5. The method for automatic quantity extraction of engineering works based on BIM according to claim 1, characterized in that, The method for obtaining the cumulative cost includes: In the component conflict area, the expansion difficulty weight is calculated according to the construction sequence level of each target component; The step size between adjacent voxel blocks is determined based on the discretization resolution of the voxel blocks; In all source units of each target component, 0 is used as the cumulative cost of each source unit, and all source units are added to the unprocessed set, with infinity used as the cumulative cost of all remaining voxel blocks. Select the voxel block with the minimum cumulative cost from the set to be processed as the search starting point, and remove the voxel block from the set to be processed; Within the local range of the search starting point, calculate the new cumulative cost for each neighboring voxel block of the starting point. The formula model includes: in, This represents the new cumulative cost for each adjacent prime block; Indicates the cumulative cost at the starting point of the search; This represents the dielectric resistance value of each adjacent bulk element; Indicates the difficulty weight of expanding the target component; Indicates the step size; If the new cumulative cost of the neighboring voxel is less than the current cumulative cost of the neighboring voxel, then update the cumulative cost of the neighboring voxel to the new cumulative cost and add the neighboring voxel to the set to be processed. The search process is repeated until the set to be processed is empty, and the cumulative cost of each voxel block in the component conflict region under each target component is obtained.
6. The method for automatic quantity extraction of engineering works based on BIM according to claim 5, characterized in that, The formula model for the expansion difficulty weight includes: in, This represents the expansion difficulty weight for each target component; This indicates the construction sequence level of each target component; Let represent the logarithmic function with the natural logarithm e as the base.
7. The method for automatic quantity extraction of engineering works based on BIM according to claim 1, characterized in that, The method for obtaining the final component ownership status includes: In the component conflict region, for any voxel block, determine the minimum cumulative cost among the cumulative costs of that voxel block under all target components; If the minimum cumulative cost is less than the preset effective cost threshold, the final component assignment of the voxel block is the target component corresponding to the minimum cumulative cost; otherwise, the final component assignment of the voxel block is empty.
8. The method for automatic quantity extraction of engineering works based on BIM according to claim 1, characterized in that, The calculation and validity determination of the engineering quantity data include: The volume of each voxel block is determined based on the discretization resolution; In a component conflict area, if the final component ownership of a voxel block is not empty, but the initial component ownership is empty, the voxel block is used as a filler unit. For any filling unit, the voxel block whose initial component assignment is the same as the final component assignment of the filling unit is used as the comparison block. The Euclidean distance between the filling unit and each comparison block is calculated. If the minimum Euclidean distance is greater than the preset distance threshold, the filling unit is regarded as an abnormal change unit. If the filling unit does not have a corresponding comparison block, the filling unit is directly marked as an abnormal change unit. The value obtained by negatively mapping the ratio of the number of abnormal change units to the number of fill units is used as the geometric restoration index. When the geometric accuracy index is greater than or equal to the preset accuracy threshold, the engineering quantity is determined to be valid, and the number of voxel blocks corresponding to each target component is multiplied by the volume of each voxel block in the component conflict area to obtain the net volume of each target component in the component conflict area. When the geometric accuracy index is less than the preset accuracy threshold, the engineering quantity is deemed invalid and an early warning is required.
9. An electronic device for automatic quantity extraction of engineering works based on BIM, characterized in that, It includes a processor and a memory, the memory storing at least one instruction, at least one program, code set or instruction set, and when the at least one instruction, at least one program, code set or instruction set is loaded and executed by the processor, it implements the steps of the BIM-based automatic quantity extraction method as described in any one of claims 1-8.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the BIM-based automatic quantity extraction method as described in any one of claims 1 to 8.
