A building height extraction method and system based on oblique photogrammetry model
By using oblique photogrammetry models and graph convolutional networks to identify building surface patches, the accuracy and efficiency issues of building height extraction in existing technologies have been resolved, enabling high-precision automated building height calculation in complex urban environments.
Patent Information
- Application Number
- CN202511248885.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-03
- Publication Date
- 2025-12-12
- Estimated Expiration
- 2045-09-03
Smart Images

Figure CN120807616B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the field of three-dimensional modeling, and particularly relates to a building height extraction method and system based on oblique photogrammetry model. BACKGROUND
[0002] With the acceleration of urbanization, three-dimensional building models are increasingly widely used in the fields of urban planning, smart city construction and digital twinning. Building height, as an important parameter of three-dimensional models, directly affects the effect of subsequent analysis and application. Existing building height acquisition techniques mainly include manual measurement, single image analysis, point cloud segmentation and parameterized modeling methods, but these methods have different degrees of limitations and defects in practical application.
[0003] Manual measurement of building height usually relies on full-process manual operation. The measurement personnel need to carry professional equipment to the building site, and measure key points (such as the highest point of the roof and the eave position) one by one through a total station or a laser range finder. After obtaining the basic data, the technical personnel manually draw the building contour line in the CAD software, and then calculate the overall height combined with the measurement data. This method has a fundamental defect: it is difficult to contact measure high-rise buildings in densely populated urban areas, and the reflection of glass curtain walls easily leads to ranging deviation; it is difficult to accurately restore complex roof structures (such as the intersection of sloping surfaces) during manual drawing; at the same time, it is limited by weather and building access, and the measurement of a single building may take several hours, which cannot meet the time efficiency requirements of regional projects.
[0004] The single image analysis method analyzes the building height through aerial images. After constructing a three-dimensional model using Agisoft and other software, the position offset of the same building in adjacent aerial images is identified through image feature matching algorithms (such as SIFT operators), and the height value is calculated according to the principle of triangulation. There are obvious defects in the implementation: when the building surface is a glass curtain wall, the strong reflection causes the feature point matching to fail; for buildings with complex roof shapes (such as curved domes or dense skylights), the algorithm misjudges the feature points as roof structure points, resulting in overestimation or underestimation of the building main body height. More seriously, this method completely ignores the three-dimensional spatial structure of the building, and cannot distinguish between roof equipment (cooling towers, elevator rooms) and the building main body, resulting in serious distortion of the height data.
[0005] The point cloud segmentation method relies on laser point cloud to segment building structures, first uses a ground laser scanner to collect building point clouds, and then automatically separates roofs, walls and accessory structures through a region growing algorithm. In actual operation, the algorithm fails due to differences in point cloud density - the sparse point cloud at the top of a low-rise building leads to incorrect roof boundary identification; the point cloud at the bottom of a high-rise building is incomplete due to nearby occlusion; and the point cloud in a vegetation-covered area penetrates to form "ghost points". The technical personnel are forced to manually repair the point cloud holes in tools such as CloudCompare, and redefine the building boundaries in an artificial box selection manner. This poor repair fit causes damage to the connection between the main building body and the accessory structure, and finally outputs a defective building model.
[0006] The parametric modeling method generates buildings through preset rules, imports building base contours in platforms such as Cityengine, and extrudes building blocks in batches in combination with preset height parameters (such as the number of floors x floor height). This way of deviating from real scene data has systematic defects: the top details of the building (such as the roof and parapet) are simplified to a uniform height value; the special shapes of historical buildings are completely lost; when the real scene conflicts with the preset rules (such as the bottom commercial floor height being greater than the standard floor), the model height deviates from the actual value by more than 20%. Engineers need to manually correct each building against aerial images, which improves efficiency by only about 30% compared to full manual modeling, but greatly reduces precision.
[0007] In addition, the existing technology also has the following problems: aerial images and three-dimensional point clouds are processed separately, lacking of collaborative fusion; manual splicing of roof and main body height often causes misalignment, damaging the integrity of the building; multiple links rely on manual operation, the measurement and drawing process is affected by subjective experience, complex structures are difficult to accurately restore, and errors are continuously accumulated; local building changes require re-shooting and rebuilding the entire area, causing serious waste of computing resources and time; the recognition ability of key features is insufficient, and a single data source cannot accurately identify glass curtain walls, roof equipment, etc., leading to height misjudgment and model distortion.
[0008] In summary, the existing building height extraction technology cannot meet the needs of high precision and high efficiency in complex urban environments, and a more accurate new intelligent computing method is urgently needed. SUMMARY
[0009] The present application provides a building height extraction method and system based on oblique photogrammetry model to solve the problem that the existing technology cannot meet the needs of high precision and high efficiency in complex urban environments.
[0010] To solve the above technical problems, the embodiments of the present application disclose the following technical solutions:
[0011] One aspect of the present application provides a building height extraction method based on an oblique photogrammetry model, comprising:
[0012] Acquire the outline vector data and OSGB oblique photogrammetry model of the target building;
[0013] Based on the outline vector data, the associated facets representing the target building are selected in the OSGB model;
[0014] For each associated surface, the structural type is determined based on the normal direction. The building structural types include horizontal floor slabs, inclined surfaces, and walls.
[0015] Based on the building structure type and spatial attribute data of the associated facets, the main facets of the target building are determined using a pre-trained main body determination model.
[0016] Cluster analysis was performed on the elevation data of the main surfaces to divide all the main surfaces into multiple layers;
[0017] Calculate the elevations of the lowest and highest floors separately, and obtain the building height of the target building based on the elevation difference between the two floors.
[0018] Optionally, the step of selecting the associated facets representing the target building in the OSGB model based on the contour vector data includes:
[0019] A closed buffer boundary is generated by expanding outward by a predetermined length along the normal direction of the contour line vector.
[0020] In the OSGB model, select the mesh surface whose centroid coordinates are projected onto the buffer boundary and use it as the associated surface of the target building.
[0021] Optionally, for each associated facet, the building structure type is determined based on the normal direction, including:
[0022] Calculate the normal-zenith angle of each associated facet using the following formula. :
[0023]
[0024] in, These are the components of the normal vector of the associated facet in the x, y, and z directions, respectively; , where is the magnitude of the normal vector;
[0025] Will The building structure type of the associated surface is determined to be a horizontal floor slab;
[0026] Will The building structure type of the associated facet is determined to be an inclined facet;
[0027] Will The building structure type of the associated facet is determined to be a wall.
[0028] Optionally, the method further comprises:
[0029] The subject determination model is trained in the following manner:
[0030] A training sample set is constructed based on network facets in the OSGB model, sample attributes including spatial attribute data of the network facets, building structure types, and determination results, wherein the spatial attribute data includes centroid coordinates and normal vector data, and the determination results include building subjects and non-building subjects;
[0031] The network facets are taken as nodes, and edges shared between the network facets are taken as connection line segments to construct a graph structure;
[0032] The model structure is constructed in the following manner:
[0033] The first and second graph convolution layers adopt a 3x3 equivalent receptive field convolution kernel to extract local geometric features and neighborhood relationships in the graph structure and form high-dimensional feature mapping;
[0034] The third graph convolution layer introduces a skip connection mechanism to fuse shallow detail features and deep abstract features and perform enhanced processing on building edges;
[0035] The features output by the graph convolution layer are compressed to a single dimension through a fully connected layer, and a Sigmoid activation function is used for mapping to output the confidence results of the facets belonging to building subjects.
[0036] Optionally, the subject facets of the target building are determined based on the building structure types and spatial attribute data of the associated facets and the pre-trained subject determination model, including:
[0037] The spatial attribute data of each associated facet is obtained, including the coordinates (x, y, z) of the facet centroid and the components of the facet normal vector in the x, y, and z directions ;
[0038] The building structure types and spatial attribute data of each associated facet are input into the subject determination model to obtain the corresponding confidence results;
[0039] The subject mask is constructed based on the facets with confidence results exceeding a preset threshold;
[0040] The subject mask is optimized;
[0041] The subject facets are determined using the optimized subject mask.
[0042] Optionally, the optimization of the subject mask includes:
[0043] Holes in the subject mask are filled using a morphological closing operation;
[0044] The noise in the main mask is removed by using a connected domain analysis method.
[0045] Optionally, the elevation data of the face sheet is subjected to cluster analysis, and all the main face sheets are divided into multiple layers, including:
[0046] For each main face sheet, the average value of the three vertices in the elevation direction is calculated and used as initial elevation data;
[0047] Adjacent face sheets are subjected to elevation feature fusion to obtain fusion elevation data of each main face sheet;
[0048] Adjacent main face sheets with a fusion elevation data difference less than a preset difference value are merged into a face sheet cluster;
[0049] Face sheet clusters with a building structure type of horizontal floor and a projection area less than a preset projection area are removed;
[0050] Different face sheet clusters are divided into different layers, and each layer is sorted in ascending order of the fusion elevation data value of the face sheet in the face sheet cluster.
[0051] Optionally, the fusion elevation data of each main face sheet is obtained by fusing the elevation features of adjacent face sheets, including:
[0052] For each main face sheet, the initial elevation data and the initial elevation data of adjacent face sheets are subjected to weighted average calculation, and the calculation result is used as the fusion elevation data of the main face sheet.
[0053] Optionally, the elevation of the lowest layer and the highest layer is calculated, and the building height of the target building is obtained according to the elevation difference between the two, including:
[0054] Based on the initial elevation data of each main face sheet in the lowest layer, the weighted median algorithm is used to calculate the elevation of the lowest layer;
[0055] The maximum initial elevation data of the main face sheet contained in the highest layer is used as the elevation of the highest layer;
[0056] The difference between the elevation of the highest layer and the elevation of the lowest layer is calculated as the building height of the target building.
[0057] Another aspect of the present application provides a building height extraction system based on a tilt photogrammetry model.
[0058] The summary section is provided to introduce selected concepts in a simplified form, which will be further described in the detailed description below. The summary section is not intended to identify key or essential features of the disclosure, nor is it intended to limit the scope of the disclosure.
[0059] The building height extraction method and system based on the oblique photogrammetry model can significantly improve the precision and efficiency of extracting the building height from the OSGB oblique photogrammetry model, and realize the automatic and accurate identification and height calculation of the building main structure. By fusing the spatial geometric feature analysis and the deep learning model, the problems of glass curtain wall reflection interference, complex roof structure misjudgment, and balcony, equipment room and other accessory structure miscounting into the main height are effectively overcome, and the reliability of the main height extraction result is ensured. At the same time, the subjective links such as manual measurement, manual contour drawing and experience parameter adjustment are completely abandoned, the accumulation of human error is greatly reduced, and the processing speed is significantly improved. BRIEF DESCRIPTION OF DRAWINGS
[0060] The above and other objects, features and advantages of the present disclosure will become more apparent from the following detailed description when taken in conjunction with the accompanying drawings in which like reference characters refer to like parts throughout the figures, and wherein exemplary embodiments of the present disclosure are shown.
[0061] Figure 1 A flowchart of a building height extraction method based on an oblique photogrammetry model provided for an embodiment of the present application is shown in the figure;
[0062] Figure 2 A flowchart of a method for realizing step S200 in the method for realizing the building height extraction method based on the oblique photogrammetry model provided for an embodiment of the present application is shown in the figure; Figure 1
[0063] A flowchart of a method for realizing step S400 in the method for realizing the building height extraction method based on the oblique photogrammetry model provided for an embodiment of the present application is shown in the figure; Figure 3 Figure 1 A flowchart of a method for realizing step S500 in the method for realizing the building height extraction method based on the oblique photogrammetry model provided for an embodiment of the present application is shown in the figure;
[0064] Figure 4 A flowchart of a method for realizing step S600 in the method for realizing the building height extraction method based on the oblique photogrammetry model provided for an embodiment of the present application is shown in the figure. Figure 1
[0065] Figure 5 Figure 1 DETAILED DESCRIPTION
[0066] Embodiments of the present disclosure will be described more fully hereinafter with reference to the accompanying drawings, in which like reference characters refer to like parts throughout the figures, and where exemplary embodiments of the present disclosure are shown. It is to be understood that the present disclosure can be carried out in various forms and should not be limited by the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the present disclosure to those skilled in the art.
[0067] The term "includes" and its variants are meant to cover non-exclusive inclusions, i.e., that the listed items do not have to be present for the method or composition to be included. The term "or" means "and / or" unless otherwise indicated. The term "based on" means "based, at least in part, on" unless otherwise indicated. The terms "one example embodiment" and "an embodiment" mean "at least one example embodiment." The term "another embodiment" means "at least one additional example embodiment." The terms "a first," "a second," etc. do not require that there be only one of the indicated objects. Other explicit or implicit definitions can also be included below.
[0068] Figure 1 A flowchart of a building height extraction method based on a oblique photogrammetry model is provided for an embodiment of the present application, as shown in Figure 1 The method comprises the following steps:
[0069] Step 100: Obtain the contour line vector data of the target building and the OSGB oblique photogrammetry model.
[0070] First, obtain the contour line vector data of the target building. The data source can be the building base, the completed map vectorization results provided by the real estate / planning department, or obtained through the orthophoto / 3D scene manual digitization. The format includes SHP, GeoJSON, GDB, etc. In this embodiment, the first layer outer wall contour is used as the reference contour line vector data.
[0071] OSGB is a three-dimensional scene data format, which is usually generated by unmanned aerial vehicles or aerial cameras from multiple angles (orthophoto + oblique) to take images, through aerial triangulation, dense matching and three-dimensional reconstruction algorithm.
[0072] After obtaining the OSGB oblique photogrammetry model of the target building, the contour line vector is superimposed into the OSGB model, so that they have the same coordinate system and are registered, and it is ensured that the target building is matched and corresponding in the two.
[0073] Step 200: Select the associated surface patch representing the target building in the OSGB model based on the contour line vector data.
[0074] In one embodiment of the present application, as shown in Figure 2 The following method can be used to implement step S200:
[0075] Step S201: Expand a predetermined length along the normal direction of the contour line vector to generate a closed buffer boundary.
[0076] The outward expansion operation is performed along the normal direction of the contour line to generate a closed buffer boundary. The preset length of the outward expansion can be set according to the actual situation of the building, for example, 5 meters to 10 meters, to form a three-dimensional action range similar to the building contour, which can effectively cover the real facade of the target building and avoid missing selection due to modeling errors or shielding.
[0077] Step S202: In the OSGB model, select the mesh patches whose centroid coordinates are projected in the buffer boundary as the associated patches corresponding to the target building.
[0078] The centroid coordinates of each triangular mesh patch in the OSGB model are projected to the ground plane, and it is judged whether they fall within the buffer range generated in step S201. If the centroid projection point is located within the buffer boundary, the patch is selected as the associated patch corresponding to the target building.
[0079] Since the OSGB model contains a large number of scene elements, such as adjacent buildings, roads, vegetation, etc., through the above method, non-target building patches (such as other buildings, streets, greenery or vehicles) outside the buffer zone can be effectively removed, ensuring that the mesh data used in the subsequent processing steps mainly comes from the target building itself.
[0080] Step 300: For each associated patch, determine the structure type according to the normal direction.
[0081] This step further determines the corresponding building structure type for each associated patch selected from the OSGB model through its normal direction. The normal vector of the patch is an important geometric property that describes its orientation, which can intuitively reflect the relative inclination relationship of the patch with the ground. Building surfaces are mainly composed of three types of components: horizontal floors (such as floor slabs, roof slabs), vertical walls (such as facades, curtain walls), and structures with a certain angle of inclination (such as sloping roofs, balcony floorboards, etc.). Therefore, based on the classification of the normal direction, fine annotation of the geometric features of the building can be achieved.
[0082] In one embodiment of the present disclosure, the following method can be used to implement step S300:
[0083] The normal-zenith angle of each associated patch is calculated according to the following formula :
[0084]
[0085] wherein, are the components of the normal vector of the associated patch in the x, y, z directions, respectively; is the norm of the normal vector.
[0086] is the normal-zenith angle of the associated patch. The building structure type of the associated face patch is determined as a horizontal floor.
[0087] The building structure type of the associated face patch is determined as a horizontal floor. The building structure type of the associated face patch is determined as a horizontal floor.
[0088] The building structure type of the associated face patch is determined as a horizontal floor.
[0089] For example, if the normal vector of a face patch is n=(0.05, 0.02, 0.99), it is calculated that the face patch should be marked as a horizontal floor; if the normal vector of a face patch is n=(0.5, 0.1, 0.86), it is determined as a tilted component; and if the normal is n=(0.98, 0.05, 0.1), it is close to vertical and marked as a wall surface.
[0090] Step 400: determining the subject face patch of the target building based on the building structure type and spatial attribute data of the associated face patch and a pre-trained subject determination model;
[0091] In an embodiment of the present application, in order to realize automatic differentiation of building subjects and non-subject components, a subject determination model based on a graph convolution network (GCN) is designed and trained.
[0092] The subject determination model is trained in the following way:
[0093] (1) In the data preparation stage, network face patches are obtained based on the OSGB oblique photogrammetry model, and a training sample set is constructed. Each face patch sample contains spatial attribute data and corresponding structure type labels. The spatial attribute data includes the face patch centroid coordinates (x, y, z) and the normal vector , the former representing the position of the face patch in space, and the latter describing the orientation and geometric characteristics of the face patch. At the same time, the sample is assigned a determination result label, i.e. building subject or non-building subject.
[0094] (2) In the graph structure construction stage, the network face patches are abstracted as nodes in the graph, and if there is a shared boundary between the face patches, a connection relationship is established between the corresponding nodes to construct a graph structure. This graph structure can explicitly model the spatial adjacency relationship between face patches.
[0095] (3) The model structure is constructed in the following way:
[0096] The first and second graph convolution layers use a 3x3 equivalent receptive field convolution kernel to extract local geometric features and neighborhood relationships in the graph structure, forming a high-dimensional feature mapping.
[0097] The third layer graph convolution layer introduces a skip connection mechanism, fuses the shallow detail features and the deep abstract features, and performs enhancement processing on the building edge.
[0098] The features output by the graph convolution layer are compressed into a single dimension through a fully connected layer, and a Sigmoid activation function is used for mapping to output the confidence result of the facet belonging to the building main body.
[0099] The present application adopts a multi-layer graph convolution network for feature extraction, and the first two layers of the graph convolution layer are set to equivalent 3*3 receptive field convolution kernels, which are used to extract local geometric features in the graph structure and capture the spatial relationship between adjacent facets. For example, a certain wall facet is adjacent to a floor facet, and after convolution aggregation, the model can perceive the topological structure feature of “wall-plate”. The third layer of the graph convolution layer introduces a skip connection mechanism to realize the fusion of shallow detail features and deep abstract features, especially in the building edge or complex area (such as the junction of balcony and outer wall), the mechanism can enhance the edge determination effect and avoid the loss of detail information in the deep learning of the model.
[0100] Finally, the high-dimensional features output by the graph convolution layer are compressed into a single dimension value through a fully connected layer, and a Sigmoid activation function is used for normalized mapping to obtain the confidence value of each facet belonging to the building main body. The confidence value is in the interval of 0-1, and the closer the value is to 1, the more likely the facet is the building main body.
[0101] The main body determination model can fully utilize the spatial geometric properties and graph structure features of the OSGB model, combine the graph convolution and skip connection mechanism in deep learning, realize high-precision building main body recognition, effectively eliminate the interference components such as balcony and rain shed, and provide reliable input data for subsequent floor height reconstruction and height measurement.
[0102] In one embodiment of the present application, as shown in Figure 3 the following method can be used to realize step S400:
[0103] Step S401: Obtain the spatial attribute data of each associated facet, including the coordinates (x, y, z) of the facet centroid, and the components of the facet normal vector in the x, y, z directions .
[0104] Step S402: Input the building structure type and spatial attribute data of each associated facet into the main body determination model to obtain the corresponding confidence result.
[0105] The architectural structure type and spatial attribute of the face piece constitute seven-dimensional features, and the seven-dimensional features of each associated face piece are input into the subject determination model. The model outputs a confidence value between 0 and 1, which represents the possibility that the face piece belongs to the architectural subject. For example, a load-bearing floor may output 0.93, and a balcony face piece may output 0.25.
[0106] Step S403: Construct a subject mask based on the face pieces whose confidence results exceed the preset threshold.
[0107] According to the comparison between the confidence result and the preset threshold (≥ 0.8), the face piece set higher than the threshold is screened out and marked as a subject face piece, so as to preliminarily generate mask data of the architectural subject. The subject mask is essentially a binary distribution map for indicating which area belongs to the subject, wherein 1 represents the architectural subject, and 0 represents the non-architectural subject.
[0108] Step S404: Optimize the subject mask.
[0109] In one embodiment of the present disclosure, the optimization of the subject mask includes:
[0110] (1) The morphological closing operation is used to repair the structure of the subject mask. The closing operation is composed of dilation operation and erosion operation in sequence, and a 3x3 structural element kernel is used in this embodiment. Through the operation, the holes and small cracks in the subject area can be effectively filled, and the gaps in the subject area caused by model determination errors or edge discontinuity can be avoided, so that the mask of the architectural subject is more complete and coherent.
[0111] (2) The connected domain analysis method is used to remove noise in the subject mask. The mask area is labeled by connected components, the area or pixel number of each connected region is calculated, and the isolated regions smaller than the preset threshold are deleted. These isolated noises usually come from balconies, canopies or other decorative components and do not have the structural continuity of the subject. By removing these interference regions through connected domain analysis, the purity and accuracy of the subject mask can be significantly improved.
[0112] Step S405: Determine the subject face piece by using the optimized subject mask.
[0113] The subject mask is corresponded to the associated face piece in the original OSGB model one by one. For each associated face piece, if the centroid coordinates fall within the subject mask area, it is determined that the face piece belongs to the architectural subject; if the centroid coordinates are outside the mask, it is determined as a non-subject face piece and is removed. In this way, the subject screening at the face piece level is realized.
[0114] The final output of the main surface patch set represents the part of the target building that has structural significance, such as the core tube of the podium, the standard layer wall, the floor and the roof of the residence, and the like, and the decorative or accessory components (such as railings, balcony floors, canopies) unrelated to the main body are all removed.
[0115] Step 500: Cluster analysis is performed on the patch elevation data, and all main surface patches are divided into multiple layers.
[0116] In one embodiment of the present disclosure, as shown in Figure 4 Step S500 can be implemented in the following manner:
[0117] Step 501: For each main surface patch, the average value of the three vertices in the elevation direction is calculated and used as the initial elevation data.
[0118] For any one main surface patch, the coordinates of its three vertices are extracted, which are (x1, y1, z1), (x2, y2, z2), and (x3, y3, z3).
[0119] The average value in the z direction is calculated by the following formula:
[0120] z init =z1+z2+z3 / 3
[0121] The average value z initz is used as the initial elevation data of the patch, which describes the overall position of the patch in the elevation direction.
[0122] Step 502: Perform elevation feature fusion on adjacent surface patches to obtain the fusion elevation data of each main surface patch.
[0123] In actual building surfaces, there is a certain degree of noise and local protrusions (such as exterior wall decorations, canopies, air conditioning sites, etc.), and if only the initial elevation data is used, it will lead to discontinuous floor division. Therefore, the elevations of adjacent surface patches need to be fused to improve spatial consistency.
[0124] In one embodiment of the present disclosure, step 502 can be implemented in the following manner:
[0125] For each main surface patch, the initial elevation data and the initial elevation data of the adjacent surface patch are weighted and averaged, and the calculation result is used as the fusion elevation data of the main surface patch.
[0126] For each subject patch, the patch can be taken as the center to search for its adjacent patches (i.e., 1-hop neighborhood sharing edges), and the initial elevation of the subject patch and the initial elevations of the adjacent patches are weighted and averaged to obtain the fusion elevation of the subject patch.
[0127] Step 503: merging adjacent subject patches with a fusion elevation data difference less than a preset difference value into a patch cluster.
[0128] After obtaining the smooth fusion elevation data, adjacent patches with an elevation difference less than a preset difference value (e.g., 1.0 m) are merged to form a patch cluster.
[0129] (1) Elevation difference calculation:
[0130] For each subject patch i, search for its adjacent patch set , and calculate the fusion elevation difference between patch i and each adjacent patch j:
[0131]
[0132] wherein and represent the fusion elevation data of patch i and patch j, respectively.
[0133] (2) Merging condition:
[0134] If the following conditions are met:
[0135] wherein 1 m is a preset difference value, it is considered that patch i and patch j belong to the same elevation level and can be merged into the same patch cluster.
[0136] Starting from any unmarked patch, search for all adjacent patches that meet the above conditions recursively or iteratively, and assign these patches to the same cluster until all patches are assigned to a patch cluster.
[0137] Step 504: removing the patch cluster with a building structure type of horizontal floor and a projection area less than a preset projection area.
[0138] After the formation of the patch cluster, the effectiveness of the cluster needs to be screened to avoid interference of non-main structure such as balcony, rain shed, and decorative component on floor division.
[0139] First, determine the building structure type of the patches in the cluster. If the cluster is mainly composed of horizontal floor patches, further calculate the projection area of the cluster.
[0140] The projection area of the patch cluster is calculated as follows: :
[0141]
[0142] wherein, A is the total actual area of the patch cluster, is the angle between the normal and the vertical direction.
[0143] The actual area of the patch is mapped to the horizontal plane according to its normal direction, so as to obtain the real coverage range of the patch on the building plan.
[0144] If the projected area of a patch cluster is less than a preset threshold (such as 15 m2), it is considered that it is not enough to represent an independent floor or an important part of a floor, and the patch cluster is excluded from the subsequent clustering results. Through this screening process, it can be ensured that the patch clusters participating in the floor division are truly related to the main body.
[0145] Step 505: Divide different patch clusters into different layers, and sort each layer in ascending order according to the fusion elevation data value of the patch in the patch cluster.
[0146] After removing the invalid clusters, the remaining valid patch clusters will be further divided into different building levels. According to the fusion elevation data of the patches in the cluster, first, the average fusion elevation of the patches in all patch clusters is calculated as the average fusion elevation value of the corresponding patch cluster; then, the patch clusters are arranged in ascending order according to the average fusion elevation value, and the floor numbers are assigned from bottom to top, for example, the number 0 represents the ground floor, 1 represents the second floor, and so on. In this way, each patch cluster can be corresponded to a specific floor position of the building.
[0147] Step 600: Calculate the elevations of the lowest layer and the highest layer respectively, and obtain the building height of the target building according to the elevation difference between the two.
[0148] In one embodiment disclosed in the present application, as shown in Figure 5 Step S600 can be implemented in the following way:
[0149] Step S601: Based on the initial elevation data of each main patch in the lowest layer, the weighted median algorithm is used to calculate the elevation of the lowest layer.
[0150] The initial elevation data of all main patches in the lowest layer is counted, and in order to avoid the deviation of the overall elevation calculation caused by individual outliers (such as local depressions, external components, etc.), the weighted median algorithm is used for calculation. The specific process is as follows: the main patches in the lowest layer are sorted in ascending order according to their initial elevation values, and the area of the patch is introduced as a weight factor, and the areas of the patches are added in turn. When the cumulative area reaches 50% of the total area, the corresponding patch elevation is selected as the representative elevation of the lowest layer.
[0151] Step S602: taking the largest initial elevation data in the subject patch contained in the highest layer as the elevation of the highest layer.
[0152] Step S603: calculating the difference between the elevation of the highest layer and the elevation of the lowest layer as the building height of the target building.
[0153] The building height H of the target building is calculated by using the following formula:
[0154]
[0155] wherein, is the elevation of the highest layer, is the elevation of the lowest layer.
[0156] The embodiments of the present application further disclose a building height extraction system based on a tilt photogrammetry model, which applies the building height extraction method based on the tilt photogrammetry model disclosed in the foregoing embodiments, and details are not repeated here.
[0157] The above has described the embodiments of the present disclosure, the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes are obvious to those skilled in the art without departing from the scope and spirit of the described embodiments. The choice of terms used herein is intended to best explain the principles of the embodiments, practical application, or technical improvement to the technology in the market, or to enable other ordinary skilled persons in the art to understand the embodiments disclosed herein.
Claims
1. A building height extraction method based on oblique photogrammetry model, characterized in that, The application comprises the following steps: Obtaining contour line vector data and an OSGB oblique photogrammetry model of a target building; Selecting associated patches representing the target building in the OSGB model based on the contour line vector data; For each associated patch, determining the building structure type according to the normal direction, wherein the building structure type comprises a horizontal floor, an inclined surface and a wall surface; Determining the subject patch of the target building based on a pre-trained subject determination model according to the building structure type and spatial attribute data of the associated patch; Training the subject determination model in the following manner: Constructing a training sample set based on the network patches in the OSGB model, wherein the sample attributes comprise spatial attribute data, building structure type and determination result of the network patches, the spatial attribute data comprises centroid coordinates and normal vector data, and the determination result comprises building subject and non-building subject; Constructing a graph structure by taking the network patches as nodes and the edges shared between the network patches as connection line segments; Constructing the model structure in the following manner: The first and second graph convolution layers adopt a 3*3 equivalent receptive field convolution kernel to extract local geometric features and neighborhood relationships in the graph structure and form high-dimensional feature mapping; The third graph convolution layer introduces a skip connection mechanism to fuse shallow detail features and deep abstract features and perform enhancement processing on the building edges; The features output by the graph convolution layer are compressed into a single dimension through a fully connected layer, mapped by a Sigmoid activation function, and the confidence result of the patch belonging to the building subject is output; Performing cluster analysis on the patch elevation data to divide all the subject patches into multiple layers; Calculating the elevations of the lowest layer and the highest layer, respectively, and obtaining the building height of the target building according to the elevation difference between the two.
2. The method of claim 1, wherein, The method for selecting the associated patches representing the target building in the OSGB model based on the contour line vector data comprises the following steps: Expanding outward along the normal direction of the contour line vector by a preset length to generate a closed buffer boundary; Selecting the grid patches with the centroid coordinates projected within the buffer boundary in the OSGB model as the associated patches corresponding to the target building.
3. The method of claim 1, wherein, The method for determining the building structure type according to the normal direction for each associated patch comprises the following steps: The normal - zenith angle of each associated facet is calculated according to the following formula : wherein are the components of the normal vector of the associated facet in the x, y, z directions, respectively; is the modulus of the normal vector. The building structure type of the associated facet of is determined to be a horizontal floor; The building structure type of the associated facet of is determined as a sloping facet; The building structure type of the associated facet of is determined to be a wall surface.
4. The method of claim 1, wherein, The method for determining the subject patch of the target building based on the pre-trained subject determination model according to the building structure type and spatial attribute data of the associated patch comprises the following steps: Obtaining spatial attribute data of each associated facet, including coordinates (x, y, z) of a facet centroid and components of a facet normal vector in x, y, z directions ; Inputting the building structure type and spatial attribute data of each associated patch into the subject determination model to obtain the corresponding confidence result; Constructing a subject mask based on the patches with confidence results exceeding a preset threshold; Optimizing the subject mask; Determining the subject patch by using the optimized subject mask.
5. The method of claim 4, wherein, The method for optimizing the subject mask comprises the following steps: Filling the holes in the subject mask by using a morphological closing operation; Removing the noise in the subject mask by using a connected domain analysis method.
6. The method of claim 1, wherein, The method for performing cluster analysis on the patch elevation data to divide all the subject patches into multiple layers comprises the following steps: For each subject patch, calculating the average value of the three vertices in the elevation direction as the initial elevation data; Fusing the elevation features of adjacent patches to obtain the fusion elevation data of each subject patch; merge the adjacent main patch whose fusion elevation data difference is less than the preset difference into a patch cluster; remove the patch cluster whose building structure type is horizontal floor and whose projection area is less than the preset projection area; divide the different patch clusters into different layers, and sort each layer according to the fusion elevation data value of the patch in the patch cluster from small to large.
7. The method of claim 6, wherein, The elevation feature fusion of the adjacent interface patch to obtain the fusion elevation data of each main patch comprises: For each main patch, the initial elevation data and the initial elevation data of the adjacent interface patch are weighted and averaged to calculate the result as the fusion elevation data of the main patch.
8. The method of claim 6, wherein, The elevation of the lowest layer and the highest layer is calculated respectively, and the building height of the target building is obtained according to the elevation difference between the two, comprising: Based on the initial elevation data of each main patch in the lowest layer, the weighted median algorithm is used to calculate the elevation of the lowest layer; The maximum initial elevation data of the main patch contained in the highest layer is taken as the elevation of the highest layer; The difference between the highest layer elevation and the lowest layer elevation is calculated as the building height of the target building.
9. A building height extraction system based on oblique photogrammetry model, characterized in that, The building height extraction method based on the oblique photogrammetry model according to any one of claims 1-8.
Citation Information
Patent Citations
Many source data-driven LOD2-level city building model enhancement modeling algorithm
CN115482355A
Automatic layering method and system for oblique photography model of high-rise building
CN115496908A