A mountain segmentation method and device based on DEM data

By combining hydrological analysis and neighborhood analysis, saddle points are identified and maximum gradient lines are generated, solving the problem of difficult saddle point identification in existing technologies. This enables accurate closure and automated segmentation of mountain boundaries, making it suitable for mountain analysis in complex terrain.

CN123141484APending Publication Date: 2026-11-20CHUZHOU UNIV
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202611316065.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-28
Publication Date
2026-11-20

AI Technical Summary

Technical Problem

In existing technologies, saddle points cannot be accurately identified, and there is a lack of effective methods for tracing the descent path from the saddle points to both sides, making it difficult to form closed mountain boundaries and achieve automated, high-precision mountain segmentation.

Method used

The hydrological analysis method is used to extract valley lines and ridge lines, and the neighborhood analysis method is used to extract candidate mountain peaks. The saddle points are identified by the local tangent vector and unidirectional flow algorithm to generate the maximum gradient line. The maximum gradient line is then superimposed with the valley line to establish a topological connection and generate a closed mountain boundary.

Benefits of technology

It enables accurate identification and closure of mountain boundaries, improves the automation and accuracy of mountain segmentation, and is suitable for mountain analysis of large-scale and complex terrain.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123141484A_ABST
    Figure CN123141484A_ABST
Patent Text Reader

Abstract

The application belongs to the technical field of geographic information systems, and discloses a mountain segmentation method and equipment based on DEM data. The method comprises the following steps: obtaining DEM data and performing preprocessing; the preprocessing result is processed in parallel through two branches, the first branch extracts a valley line and a ridge line by using a hydrological analysis method, and the second branch extracts a candidate mountain top point by using a neighborhood analysis method; in combination with the processing results of the two branches, a mountain top point pair adjacent in space along the ridge line is determined, and the mountain top point pair is determined as a candidate saddle point; a tracking starting point is generated, a single flow direction algorithm is used to start tracking from the tracking starting point to the downstream by grid, and a maximum slope line is obtained; a closed loop is extracted based on the maximum slope line and the valley line, and a mountain boundary is generated. The application accurately identifies a saddle point, simulates a surface convergence process to generate a maximum slope line, and forms a closed boundary together with a valley line.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of geographic information system technology, specifically relating to a method and device for mountain segmentation based on DEM data. Background Technology

[0002] Digital terrain analysis is a core supporting technology in fields such as geographic information science, geomorphology, ecological environment, and geological disaster prevention and control. Relying on high-resolution DEMs to conduct object-oriented terrain analysis of natural geographic entities, it conforms to the true morphology and evolution of the Earth's surface and has become a mainstream technical direction in the field of geographic information systems. Among the three key terrain units—slopes, watersheds, and mountains—the extraction methods for slopes and watersheds are relatively mature. However, as the most holistic core geographic entity in mountainous areas, the automated and high-precision segmentation methods for mountains have long lacked effective breakthroughs, becoming a key technical bottleneck restricting macro-terrain analysis, ecological management, and disaster assessment in mountainous areas.

[0003] Mountains serve as the fundamental spatial carriers for material and energy exchange, ecological succession, and disaster development in mountainous environments. Applications such as ecological vertical zonation identification, mountain climate effect research, regional landslide risk assessment, and land spatial planning all require complete, independent mountains that conform to natural landforms as basic analytical units. However, traditional mountain boundary methods heavily rely on manual visual interpretation, resulting in low efficiency, strong subjectivity, poor consistency, and difficulty in large-scale application, failing to meet the demands of automated and standardized analysis. While recent domestic and international research has explored these methods, they generally exhibit significant limitations: extraction methods for special landforms such as karst, volcanoes, and glaciers have narrow applicability and cannot be extended to continuously distributed, strongly dissected conventional mountain areas; morphological and image segmentation methods rely solely on surface statistical features such as elevation and slope, failing to integrate skeletal elements like ridgelines, saddle points, and valley lines, and further failing to couple surface runoff development processes, leading to harsh segmentation boundaries, fragmented mountains, and significant deviations from natural landforms.

[0004] Current technologies have relatively mature methods for extracting single topographic features such as ridgelines, saddle points, and valley lines. However, there is a lack of methods that can integrate these topographic features to segment mountains. For example, patent document CN118840500A provides a topographic modeling method based on multi-source satellite remote sensing data, which achieves topographic modeling through DEM data preprocessing, confluence accumulation calculation, and ridgeline extraction. However, current technologies lack effective methods for extracting saddle points, which, as natural boundary control points between adjacent mountains, play a crucial role in defining the mountain's extent. Some existing saddle point extraction methods are prone to generating false saddle points, making it difficult to accurately identify saddle points. Furthermore, there is a lack of effective methods for tracing slope paths from saddle points to both sides, thus making it difficult to form closed mountain boundaries.

[0005] Meanwhile, mainstream GIS and terrain analysis software do not provide standardized mountain segmentation tools. In practical applications, alternative solutions such as fixed grids, manual delineation, and simple threshold segmentation can only be used, which cannot reflect the real mountain structure and seriously reduce the reliability and comparability of subsequent analysis results. This makes it difficult to generate regular, stable, and closed mountain boundaries for contour-cut and continuous mountainous areas, resulting in significant lack of practicality. Summary of the Invention

[0006] The purpose of this invention is to provide a mountain segmentation method based on DEM data to solve the technical problem that existing technologies cannot accurately identify saddle points and lack an effective method for tracing slope paths from saddle points to both sides, thus making it difficult to form closed mountain boundaries.

[0007] The mountain segmentation method based on DEM data includes the following steps: Acquire DEM data and perform preprocessing; The preprocessing results are processed in parallel through two branches: the first branch uses hydrological analysis to extract valley lines and ridge lines, and the second branch uses neighborhood analysis to extract candidate mountain peaks. The effective mountain peaks are determined by combining the processing results of the two branches. The pairs of mountain peaks that are adjacent along the ridgeline in space are determined. The criteria for determination include: the mountain peak pairs are connected by the ridgeline and there are no other effective mountain peaks in between. For each pair of adjacent mountain peaks, obtain the elevation value of the grid cells that the ridgeline between the mountain peak pairs passes through, and determine the grid cells with the lowest elevation that are simultaneously lower than the elevations of the two valid mountain peaks as candidate saddle points. Calculate the local tangent vector of the ridge line segment at the candidate saddle point location, offset it to both sides of the ridge line along the direction perpendicular to the local tangent vector to generate the tracking starting point, and use a single flow direction algorithm to track downstream grid by grid starting from the tracking starting point. The complete tracked path is taken as the maximum gradient line starting from the candidate saddle point. Based on the spatial superposition of the maximum slope line and the valley line and the establishment of a topological connection relationship, a polygonization algorithm is used to extract closed loops and generate closed mountain boundaries.

[0008] Preferably, in the first branch, the hydrological analysis method includes: for the preprocessed DEM, sequentially performing flow direction calculation and runoff accumulation calculation; then calculating the optimal threshold for runoff accumulation based on the mean change point method, extracting the gully line based on the optimal threshold, further dividing the catchment area, and extracting the catchment area boundary line; setting a buffer radius, establishing a buffer zone along the gully line according to the buffer radius, removing the catchment area boundary line falling into the buffer zone, and outputting the remaining catchment area boundary line as the ridge line.

[0009] Preferably, in the second branch, the neighborhood analysis method includes: for the preprocessed DEM, setting the neighborhood window radius, and extracting the corresponding local maxima points as candidate mountain peaks based on the set neighborhood range.

[0010] Preferably, before determining the pairs of adjacent mountain peaks along the ridgeline in space, an association tolerance is set, and the candidate mountain peaks are associated with the ridgeline based on the association tolerance, thus completing the topological connection between the effective mountain peaks and the ridgeline.

[0011] Preferably, the method for calculating the local tangent vector includes: taking a candidate saddle point as the center, taking one point forward and one point backward along the ridgeline at certain intervals, and then using the line connecting the two points from front to back as the local tangent vector.

[0012] Preferably, the tracking termination condition is: when the tracking path reaches the grid corresponding to the valley line, the boundary of the study area, or reaches the preset maximum number of tracking steps; when any condition is met, tracking stops and the tracked path is output.

[0013] Preferably, candidate saddle points are screened using a method that includes: calculating two parameters, saddle cutting depth and confluence descent, and setting corresponding parameter thresholds for dual threshold screening of candidate saddle points; the parameter threshold for saddle cutting depth is threshold 1, and the parameter threshold for confluence descent is threshold 2. If a candidate saddle point satisfies the condition that the saddle cutting depth is greater than threshold 1 and the confluence descent is less than threshold 2, it is selected as a valid saddle point. The maximum slope line of the valid saddle point is then spatially superimposed with the valley line to establish a topological connection relationship.

[0014] Preferred saddle cut depth This indicates the degree of incision of the candidate saddle point relative to the two effective mountain peaks on either side. The smaller value between the candidate saddle point and the two effective mountain peaks on either side is used. The calculation formula is as follows:

[0015] In the formula, This represents the elevation value at the candidate saddle point. and Indicates the elevation values ​​of the effective mountain peaks on both sides; gradient of the confluence. The formula for calculating the maximum elevation difference between the two slope lines is:

[0016] In the formula, This represents the elevation value at the candidate saddle point. and These represent the elevation values ​​of the termination points of the two slope lines, respectively.

[0017] Preferably, the method for mountain segmentation based on DEM data further includes: after generating closed mountain boundaries, converting them into vector surface features, generating a unique identifier code for each mountain unit, and saving and outputting the mountain unit data and its attribute information.

[0018] The present invention also provides a computer device, including a memory, a processor, and a computer program stored in the memory and capable of running on the processor, wherein the processor executes the computer program to implement the steps of the mountain segmentation method based on DEM data as described above.

[0019] This invention has the following advantages: It identifies key morphological features of mountains, such as summit points and saddle points. In particular, it innovatively employs a strategy of identifying saddle points by finding the lowest elevation point between adjacent summit points along the ridgeline, and further uses local tangent vectors and unidirectional flow algorithms to track the maximum gradient line. These innovations enable the invention to accurately identify saddle points, effectively construct a ridgeline network describing the mountain's framework, and simulate surface runoff processes to generate the maximum gradient line, which, together with valley lines, forms a closed boundary. This elevates mountain segmentation from simple morphological identification to considering both causal mechanisms, resulting in segmentation results with clear geomorphological rationality.

[0020] Furthermore, this invention topologically connects the mountain peaks extracted by neighborhood analysis with the ridgelines extracted by hydrological analysis, and further utilizes the topological connection relationship to determine adjacent mountain peak pairs to identify saddle points. This achieves synergistic optimization of mountain peak and saddle point identification, enhancing the accuracy of both identifications. It also avoids the problems of incomplete removal of false mountain peaks and the loss of local mountain peaks. Finally, this invention also uses a valley line buffer to remove non-ridge portions from the catchment area boundary line, effectively optimizing the ridgeline and preventing non-ridge portions from being mixed in the catchment area boundary line, thus ensuring the accuracy of the ridgeline.

[0021] Based on the above improvements, this invention achieves mountain segmentation through graph theory and the standard D8 flow algorithm, and can automatically perform batch processing. It is suitable for large-scale, continuously distributed, and complex mountainous areas, and can objectively and efficiently divide mountainous areas into independent, complete, and geomorphologically significant mountain objects. Attached Figure Description

[0022] Figure 1 This is a flowchart of a mountain segmentation method based on DEM data according to the present invention; Figure 2 This is a partial schematic diagram showing the positional relationship between the mountain peak and the ridgeline obtained in step S5 of Embodiment 1 of the present invention. Figure 3 This is a partial schematic diagram showing the positional relationship between the candidate saddle point, the mountain peak, and the ridgeline obtained in step S6 of Embodiment 1 of the present invention. Figure 4 This is a partial schematic diagram of the slope line generation result obtained in step S8 of Embodiment 1 of the present invention; Figure 5 This is a partial schematic diagram of the mountain unit boundary generation result obtained in step S11 of Embodiment 1 of the present invention; Figure 6 This is a schematic diagram of the entire area of ​​the gully line and catchment area boundary line generation results obtained in step S3 of Embodiment 1 of the present invention. Figure 7 This is a schematic diagram of the entire area of ​​the ridgeline generation result obtained in step S4 of Embodiment 1 of the present invention; Figure 8 This is a schematic diagram of the positional relationship between the candidate mountain peak and the ridgeline obtained in step S4 of Embodiment 1 of the present invention; Figure 9 This is a full-area positional relationship diagram of the candidate saddle points, mountain peaks, and ridgelines obtained in step S6 of Embodiment 1 of the present invention. Figure 10 This is a schematic diagram of the entire area of ​​the mountain unit boundary generation result obtained in step S11 of Embodiment 1 of the present invention. Detailed Implementation

[0023] The following detailed description of the embodiments, with reference to the accompanying drawings, will further illustrate the specific implementation of the present invention, in order to help those skilled in the art to have a more complete, accurate, and in-depth understanding of the inventive concept and technical solution of the present invention.

[0024] Example 1 like Figure 1 As shown, this invention provides a mountain segmentation method based on DEM data, comprising: acquiring DEM data and preprocessing it; processing the preprocessing results in parallel through two branches; the first branch uses hydrological analysis to extract valley lines and ridge lines; the second branch uses neighborhood analysis to extract candidate mountain peaks; combining the processing results of the two branches, determining spatially adjacent pairs of mountain peaks along the ridge line; the determination criteria include: the mountain peak pairs are connected by the ridge line and there are no other valid mountain peaks in between; for each pair of adjacent mountain peaks, obtaining the elevation of the grid cells traversed by the ridge line between the mountain peak pairs. The grid with the lowest elevation, which is also lower than the elevations of the two effective mountain peaks, is identified as a candidate saddle point. The local tangent vector of the ridgeline segment at the candidate saddle point is calculated, and the saddle point is offset to both sides of the ridgeline in a direction perpendicular to the local tangent vector to generate a tracking starting point. A single-flow algorithm is used to track the saddle point grid by grid downstream from the tracking starting point, and the complete tracked path is taken as the maximum gradient line starting from the candidate saddle point. The maximum gradient line and the valley line are spatially superimposed and a topological connection is established. A polygonization algorithm is used to extract closed loops and generate a closed mountain boundary.

[0025] Optionally, preprocessing includes filling depressions in the DEM, and the resulting DEM without depressions is used as the preprocessing result.

[0026] Optionally, in the first branch, the hydrological analysis method includes: for the preprocessed DEM, performing flow direction calculation and runoff accumulation calculation in sequence; then calculating the optimal threshold for runoff accumulation based on the mean change point method, extracting the gully line based on the optimal threshold, further dividing the catchment area, and extracting the catchment area boundary line; setting a buffer radius, for example, 5 times the grid size; establishing a buffer zone along the gully line according to the buffer radius (performing masking, the masked area is the buffer zone), removing the catchment area boundary line falling into the buffer zone, and outputting the remaining catchment area boundary line as the ridge line.

[0027] This invention employs the mean-variable point method to automatically and objectively determine the optimal threshold for the accumulation of runoff, which improves the accuracy and repeatability of valley line extraction compared to the traditional trial-and-error method. The valley line buffer zone elimination strategy is one of the core innovations of this invention, which effectively removes the non-ridge portion of the catchment area boundary line and significantly improves the accuracy of the ridge line. This step provides high-quality basic data for subsequent mountain peak association, saddle point identification, and mountain boundary closure.

[0028] Optionally, in the second branch, the neighborhood analysis method includes: for the preprocessed DEM, setting the neighborhood window radius to R, for example, R = 20 times the number of rasters; calculating the maximum elevation value in the neighborhood of each raster; subtracting the original elevation of the raster from the maximum elevation value of its neighborhood, and the raster with a result of 0 is the local maximum point, and the raster is used as a candidate mountain peak.

[0029] Neighborhood analysis is computationally efficient and simple to implement. It first extracts candidate mountain peaks, which provides basic data support for subsequent topological connections between mountain peaks and ridgelines, as well as saddle point identification.

[0030] Optionally, before determining adjacent mountain peak pairs along a ridgeline in space, candidate mountain peaks can be associated with the ridgeline to complete the topological connection between mountain peaks and ridgelines. For example, by setting the association tolerance to 1 grid size, candidate mountain peaks can be associated with the nearest ridgeline within the tolerance range, thus eliminating most false mountain peaks and obtaining valid mountain peaks.

[0031] This invention, through an association process and the aforementioned determination method, can identify candidate mountain peaks that meet the requirements as valid mountain peaks. Setting an association tolerance effectively addresses the positional offset between mountain peaks and ridgelines, improving the robustness of the association between mountain peaks and ridgelines. Topological connectivity is a prerequisite for subsequently determining adjacent mountain peak pairs and identifying saddle points. In this invention, the magnitude of the association tolerance can be flexibly adjusted according to the DEM resolution.

[0032] Optionally, the calculation method of the local tangent vector includes: taking the candidate saddle point as the center, taking one point in front and one point in front along the ridge line, for example, the distance between the point and the candidate saddle point is 1 grid, and then the line connecting the two points from front to back is the local tangent vector.

[0033] This calculation method is simple and efficient. The accurate calculation of the local tangent vector is the key to generating the tracking starting point in the direction perpendicular to the ridgeline, which directly determines the accuracy of the tracking direction of the maximum gradient line.

[0034] Optionally, the tracking can be terminated when the tracking path reaches the grid corresponding to the valley line, the boundary of the study area (i.e., the area in the DEM where the mountain boundary needs to be generated), or the preset maximum number of tracking steps is reached; if any of these conditions are met, tracking will stop and the tracked path will be output.

[0035] The triple termination condition ensures reliable convergence of the tracking process under various terrain conditions. The termination condition of reaching the grid corresponding to the valley line reflects the geomorphological rationality of the surface runoff process, that is, the maximum gradient line extending from the saddle point to the valley constitutes a complete water flow path. The study area boundary and the maximum number of tracking steps serve as fallback conditions to prevent the tracking from getting stuck in a dead loop or extending indefinitely.

[0036] Optionally, candidate saddle points are screened. The screening method includes: calculating two parameters, saddle cutting depth and confluence steepness, and setting corresponding parameter thresholds for dual threshold screening of candidate saddle points to obtain corresponding valid saddle points. The maximum slope line of the valid saddle points is then spatially superimposed with the valley line to establish a topological connection relationship.

[0037] The above screening mechanism effectively eliminated false saddle points, ensuring the geomorphic authenticity of the saddle points ultimately used for mountain segmentation; it also avoided mountain boundary distortion caused by false saddle points, significantly improving the reliability of mountain segmentation results.

[0038] Among them, saddle cutting depth This indicates the degree of incision of the candidate saddle point relative to the two effective mountain peaks on either side. The smaller value between the candidate saddle point and the two effective mountain peaks on either side is used. The calculation formula is as follows:

[0039] In the formula, This represents the elevation value at the candidate saddle point. and This indicates the elevation values ​​of the effective mountain peaks on both sides.

[0040] Convergence steepness The formula for calculating the maximum elevation difference between the two slope lines is:

[0041] In the formula, This represents the elevation value at the candidate saddle point. and These represent the elevation values ​​of the termination points of the two slope lines, respectively.

[0042] Corresponding saddle depth The parameter threshold is threshold 1, for example, 60m; corresponding to the confluence descent. The parameter threshold is threshold 2, for example, 150m; if a candidate saddle point satisfies the condition that the saddle depth is greater than threshold 1 and the confluence gradient is less than threshold 2, it is selected as a valid saddle point. Valid saddle points are used for the final segmentation of the mountain.

[0043] The two parameters mentioned above, used as selection parameters, characterize the terrain features of the saddle point from both vertical and horizontal dimensions, complementing each other and forming a complete saddle point quality evaluation system.

[0044] Optionally, after generating the closed mountain boundary, it can be converted into a vector surface feature, a unique identifier code can be generated for each mountain unit, and the mountain unit data and its attribute information can be saved and output.

[0045] This step forms a standard geographic information data format that can be directly used for further analysis and visualization on mainstream GIS platforms; it generates a unique identifier code for each mountain unit, realizing the unique identification and traceability management of mountain objects; the recording of attribute information provides a directly usable data foundation, thus possessing practicality and industrial application value.

[0046] Optionally, the single-flow algorithm is the D8 single-flow algorithm, with a maximum tracking step count of 5000 steps.

[0047] The specific steps of this embodiment include: S1: Obtain DEM data of the study area, perform depression filling processing on the DEM to obtain a depression-free DEM.

[0048] S2: Based on a depression-free DEM, candidate hilltop points are extracted using neighborhood analysis. The specific operation method is as follows: set the neighborhood window radius to 20 times the grid, calculate the maximum elevation value of the neighborhood for each grid; subtract the original elevation from the maximum elevation value of the neighborhood, and the grid with a result of 0 is the local maximum point, which is used as a candidate hilltop point.

[0049] S3: Based on the depression-free DEM, the flow direction and runoff accumulation are calculated sequentially. Then, the optimal threshold for runoff accumulation is calculated using the mean-variable point method. Based on the optimal threshold, the valley lines of the study area are extracted, and the catchment areas of the study area are divided. The boundary lines of the catchment areas are extracted as candidate ridgeline lines (e.g., Figure 6 (As shown).

[0050] S4: Establish a buffer zone for the valley lines obtained in step S3, with a buffer radius of 5 times the grid size. Remove the water catchment boundary segments that fall into the buffer zone; the remaining line features are the ridge lines (e.g., Figure 7 As shown); associate the candidate mountain peaks obtained in step S2 with the ridgeline (e.g. Figure 8 As shown in the figure, complete the topological connection between the mountain peak and the ridgeline to determine the valid mountain peak.

[0051] S5: Based on the ridgeline and valid mountain peaks obtained in step S4, determine the pairs of mountain peaks that are spatially adjacent along the ridgeline; specifically, the mountain peak pairs must be connected by the ridgeline and there must be no other valid mountain peaks in between (e.g., ...). Figure 2 (As shown).

[0052] S6: For each pair of adjacent mountain peaks, obtain the elevation values ​​of the grid cells traversed by the ridgeline between the valid mountain peak pairs, and identify the grid cells with the lowest elevation that are simultaneously lower than the elevations of the two valid mountain peaks as candidate saddle points (e.g., ...). Figure 3 and Figure 9 (As shown).

[0053] S7: For the candidate saddle points identified in S6, calculate the local tangent vector of the ridge line segment at the candidate saddle point location. The specific calculation method is as follows: take the saddle point as the center, take one point forward and one point backward along the ridge line (with a spacing of 1 grid), and calculate the direction of the line connecting the two points as the local tangent vector.

[0054] S8: Along a direction perpendicular to the local tangent vector, offset by 1 grid distance to each side of the ridgeline to generate two tracking starting points; using a unidirectional flow algorithm, track downstream grid by grid starting from the starting points. Tracking terminates when the tracking path reaches the grid corresponding to the valley line, the boundary of the study area, or reaches the preset maximum number of tracking steps. The complete tracked path is taken as the maximum gradient line starting from the candidate saddle point. Figure 4 ).

[0055] S9: For each candidate saddle point, calculate the saddle depth based on the generated maximum gradient line. ) and the steepness of the confluence ( Two parameters.

[0056] in This indicates the degree of incision of the candidate saddle point relative to the two effective mountain peaks on either side. The smaller value between the candidate saddle point and the two effective mountain peaks on either side is used. The calculation formula is as follows:

[0057] In the formula, This represents the elevation value at the candidate saddle point. and This indicates the elevation values ​​of the effective mountain peaks on both sides.

[0058] The formula for calculating the maximum elevation difference between the two slope lines is:

[0059] In the formula, This represents the elevation value at the candidate saddle point. and These represent the elevation values ​​of the termination points of the two slope lines, respectively.

[0060] S10: For all candidate saddle points, after calculating the two parameters of saddle cutting depth and confluence descent, set a threshold of 1 for the saddle cutting depth parameter and a threshold of 2 for the confluence descent parameter. Select all candidate saddle points whose saddle cutting depth parameter is greater than threshold 1 and whose confluence descent parameter is less than threshold 2 as valid saddle points for the final mountain segmentation.

[0061] S11: The maximum gradient line generated from the effective saddle points is spatially superimposed with the valley line extracted in S3 to establish a topological connection. A polygonization algorithm is used to extract closed loops, generating closed mountain boundaries (e.g., Figure 5 and Figure 10 (As shown). The polygonization algorithm automatically closes the line segments obtained in the above steps to form a polygonal region. The line segments touch at their endpoints and do not intersect, ultimately generating a closed polygonal feature.

[0062] S12: Convert the mountain unit boundary lines generated in S9 into vector surface features, generate a unique identifier code for each mountain unit, and save and output the mountain unit data and its attribute information.

[0063] Example 2 This invention also provides a computer device, including a memory, a processor, and a computer program stored in the memory and capable of running on the processor. When the processor executes the computer program, it performs the following steps according to the method of Embodiment 1: acquiring DEM data and performing preprocessing; processing the preprocessing results in parallel through two branches; the first branch uses hydrological analysis to extract valley lines and ridge lines; the second branch uses neighborhood analysis to extract candidate mountain peaks; combining the processing results of the two branches, determining spatially adjacent pairs of mountain peaks along the ridge line; the determination criteria include: the mountain peak pairs are connected by the ridge line, and there are no other valid mountain peaks in between; for each pair... For adjacent mountain peak pairs, obtain the elevation values ​​of the grid cells traversed by the ridgeline between the mountain peak pairs. Identify the grid cells with the lowest elevation that are simultaneously lower than the elevations of the two valid mountain peaks as candidate saddle points. Calculate the local tangent vector of the ridgeline segment at the candidate saddle point location. Offset the ridgeline to both sides along a direction perpendicular to the local tangent vector to generate a tracking starting point. Use a unidirectional flow algorithm to track downstream grid by grid starting from the tracking starting point. Use the complete tracked path as the maximum gradient line starting from the candidate saddle point. Spatially superimpose the maximum gradient line with the valley line and establish a topological connection relationship. Use a polygonization algorithm to extract closed loops and generate closed mountain boundaries.

[0064] The specific limitations regarding the implementation steps of the computer device can be found in Example 1, and will not be described in detail here.

[0065] The memory includes a USB flash drive, a portable hard drive, a read-only memory, a random access memory, a magnetic disk, or an optical disk; the processor includes a CPU, an integrated circuit chip with signal processing capabilities, a general-purpose processor, a digital signal processor, an application-specific integrated circuit, a field-programmable gate array or other programmable logic device, a discrete gate or transistor logic device, or a discrete hardware component.

[0066] The present invention has been described above by way of example with reference to the accompanying drawings. Obviously, the specific implementation of the present invention is not limited to the above-described manner. Any non-substantial improvements made using the inventive concept and technical solution of the present invention, or the direct application of the inventive concept and technical solution of the present invention to other occasions without modification, are all within the protection scope of the present invention.

Claims

1. A method for hill segmentation based on DEM data, characterized in that, Includes the following steps: Acquire DEM data and perform preprocessing; The preprocessing results are processed in parallel through two branches: the first branch uses hydrological analysis to extract valley lines and ridge lines, and the second branch uses neighborhood analysis to extract candidate mountain peaks. The effective mountain peaks are determined by combining the processing results of the two branches. The pairs of mountain peaks that are adjacent along the ridgeline in space are determined. The criteria for determination include: the mountain peak pairs are connected by the ridgeline and there are no other effective mountain peaks in between. For each pair of adjacent mountain peaks, obtain the elevation value of the grid cells that the ridgeline between the mountain peak pairs passes through, and determine the grid cells with the lowest elevation that are simultaneously lower than the elevations of the two valid mountain peaks as candidate saddle points. Calculate the local tangent vector of the ridge line segment at the candidate saddle point location, offset it to both sides of the ridge line along the direction perpendicular to the local tangent vector to generate the tracking starting point, and use a single flow direction algorithm to track downstream grid by grid starting from the tracking starting point. The complete tracked path is taken as the maximum gradient line starting from the candidate saddle point. Based on the spatial superposition of the maximum slope line and the valley line and the establishment of a topological connection relationship, a polygonization algorithm is used to extract closed loops and generate closed mountain boundaries.

2. The method for mountain segmentation based on DEM data according to claim 1, characterized in that, In the first branch, the hydrological analysis method includes: for the preprocessed DEM, the flow direction is calculated and the cumulative runoff is calculated in sequence; then, the optimal threshold for the cumulative runoff is calculated based on the mean change point method, the valley line is extracted based on the optimal threshold, and the catchment area is further divided and the catchment area boundary line is extracted; a buffer radius is set, a buffer zone is established along the valley line according to the buffer radius, the catchment area boundary line falling into the buffer zone is removed, and the remaining catchment area boundary line is output as the ridge line.

3. The method for mountain segmentation based on DEM data according to claim 2, characterized in that, In the second branch, the neighborhood analysis method includes: for the preprocessed DEM, setting the neighborhood window radius, and extracting the corresponding local maxima points as candidate mountain peaks based on the set neighborhood range.

4. The mountain segmentation method based on DEM data according to claim 3, characterized in that, Before determining the pairs of adjacent mountain peaks along the ridgeline in space, an association tolerance is set. Based on the association tolerance, candidate mountain peaks are associated with the ridgeline, thus completing the topological connection between the effective mountain peaks and the ridgeline.

5. A method for mountain segmentation based on DEM data according to claim 1, characterized in that, The method for calculating the local tangent vector includes: taking the candidate saddle point as the center, taking one point forward and one point backward along the ridgeline at certain intervals, and then using the line connecting the two points from front to back as the local tangent vector.

6. The method for mountain segmentation based on DEM data according to claim 1, characterized in that, The tracking will terminate when the tracking path reaches the grid corresponding to the valley line, the boundary of the study area, or reaches the preset maximum number of tracking steps. Once any of these conditions are met, tracking will stop and the tracked path will be output.

7. A method for mountain segmentation based on DEM data according to claim 1, characterized in that, Candidate saddle points are screened using a method that includes calculating two parameters: saddle cut depth and confluence gradient, and setting corresponding threshold values ​​for dual threshold screening. The threshold value for saddle cut depth is set to threshold 1, and the threshold value for confluence gradient is set to threshold 2. If a candidate saddle point satisfies the condition that its saddle cut depth is greater than threshold 1 and its confluence gradient is less than threshold 2, it is selected as a valid saddle point. The maximum gradient line of the valid saddle point is then spatially superimposed with the valley line to establish a topological connection.

8. A method for mountain segmentation based on DEM data according to claim 7, characterized in that, Saddle depth This indicates the degree of incision of the candidate saddle point relative to the two effective mountain peaks on either side. The smaller value between the candidate saddle point and the two effective mountain peaks on either side is used. The calculation formula is as follows: In the formula, This represents the elevation value at the candidate saddle point. and Indicates the elevation values ​​of the effective mountain peaks on both sides; gradient of the confluence. The formula for calculating the maximum elevation difference between the two slope lines is: In the formula, This represents the elevation value at the candidate saddle point. and These represent the elevation values ​​of the termination points of the two slope lines, respectively.

9. A method for mountain segmentation based on DEM data according to claim 1, characterized in that, It also includes: after generating a closed mountain boundary, converting it into a vector surface feature, generating a unique identifier code for each mountain unit, and saving and outputting the mountain unit data and its attribute information.

10. A computer device, comprising a memory, a processor, and a computer program stored in the memory and capable of running on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the mountain segmentation method based on DEM data as described in any one of claims 1-9.

Citation Information

Patent Citations

  • Terrain modeling method based on multisource satellite remote sensing data collaboration

    CN118840500A