Efficient editing method of flow water DEM based on two-dimensional vector and a small amount of elevation points

CN122906196APending Publication Date: 2026-10-13CHENGDU TECH UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611399103.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-10
Publication Date
2026-10-13

AI Technical Summary

Technical Problem

[0006]本发明的目的在于提供一种基于二维矢量和少量高程点的流动水DEM高效编辑方法,主要解决现有流动水DEM编辑中人工分段赋高工作量大、分段结果呈台阶状、普通插值可能产生反坡以及质量检查依赖经验判断的问题

Benefits of technology

[0028](1)本发明以少量三维高程控制点替代传统分段矢量面逐段赋高方式,显著降低了人工高程采集与编辑工作量。 通过在流动水区域的上游端、下游端及弯曲、汇流、宽度突变等关键位置仅设置少量离散三维高程控制点,并利用累计平面弧长参数化与单调约束下的连续纵向目标高程函数,即可自动生成沿下游方向不升高的连续水面高程,无需频繁分段、逐段赋值和反复检查,大幅提升了流动水DEM的编辑效率。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122906196A_ABST
    Figure CN122906196A_ABST
Patent Text Reader

Abstract

The application discloses a flow water DEM efficient editing method based on two-dimensional vectors and a small amount of elevation points and belongs to the technical field of digital elevation model editing. Two-dimensional vector boundaries of flow water, an original DEM and three-dimensional elevation control points discretely arranged along a flow direction are acquired; the control points are sorted according to the flow direction and the cumulative plane arc length is calculated, and a continuous longitudinal elevation function is constructed under a monotonic constraint; the in-plane orthogonal projection or the nearest projection position of each DEM grid point in the flow water region on a two-dimensional reference curve is solved, and the corresponding longitudinal elevation is extended to a cross section; the DEM is updated according to the vector boundaries and an edge transition zone; backflow and overflow are checked by using a downstream monotonicity index and an elevation difference index between a water surface and a bank side buffer zone, and the control points or constraint parameters are adjusted and recalculated when the threshold value is not satisfied. The application replaces segmented vector surfaces with a small amount of elevation interaction to assign elevation, obtains flow water DEM with consistent transverse and continuous longitudinal descending, and improves editing efficiency and quality controllability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of remote sensing and mapping technology. Specifically, it relates to an efficient method for editing a flowing water DEM based on two-dimensional vectors and a small number of elevation points. Background Technology

[0002] DEMs are crucial data for topographic representation, orthophoto production, hydrological analysis, and the creation of basic geographic information products. When generating DEMs from stereo satellite imagery, aerial imagery, or point clouds, the surface of flowing water is easily affected by factors such as specular reflection, ripples, weak textures, temporal differences, and occlusion, leading to dense matching failures, voids, or anomalous elevations. These anomalous elevations typically manifest as irregular protrusions, depressions, or localized reverse slopes in topographic rendering and longitudinal profiles, failing to reflect the overall downward slope of the water surface from upstream to downstream.

[0003] Current production operations often involve manually collecting two-dimensional vector surfaces along the river in segments and assigning fixed elevations to each segment to replace abnormal DEMs. This method requires frequent segmentation, value assignment, and checking; jumps and steps are easily formed between adjacent segments, and the longer and more complex the river segment, the more manual interactions are required. If only a few elevation values ​​are interpolated using ordinary methods, the interpolation curve may overshoot, causing local elevations to rise downstream; if the elevation is directly diffused within the two-dimensional surface according to Euclidean distance, different mileage positions may be incorrectly mapped at river bends.

[0004] Furthermore, traditional quality inspection methods largely rely on visual observation of color rendering or manual drawing of longitudinal sections, lacking unified and repeatable quantitative criteria for determining the presence of backflow, shoreline overflow, and abrupt elevation changes. For large-format DEMs, reading and writing the entire image back for each edit would increase unnecessary data input / output and memory usage.

[0005] Therefore, a technical solution is needed that closely integrates with DEM raster, two-dimensional boundaries of flowing water, and a small number of reliable elevation observations. This solution can reduce manual elevation acquisition, stably generate flowing water elevations that are consistent across cross sections, continuous along the flow direction, and non-countercurrent, and perform traceable quantitative quality checks on the editing results. Summary of the Invention

[0006] The purpose of this invention is to provide an efficient method for editing flowing water DEMs based on two-dimensional vectors and a small number of elevation points. This method mainly solves the problems of large workload for manual segmentation and elevation assignment, stepped segmentation results, potential back slopes from ordinary interpolation, and reliance on experience for quality inspection in existing flowing water DEM editing.

[0007] To achieve the above objectives, the technical solution adopted by the present invention is as follows:

[0008] An efficient method for editing a flowing water DEM based on two-dimensional vectors and a small number of elevation points includes the following steps:

[0009] S1, obtain the original DEM, the two-dimensional vector boundary of the flowing water region, and multiple three-dimensional elevation control points located within the flowing water region and discretely set along the flow direction;

[0010] S2, determine the flow direction, sort the three-dimensional elevation control points according to the flow direction, and calculate the cumulative plane arc length based on the plane coordinates of adjacent three-dimensional elevation control points;

[0011] S3. Based on the plane coordinates of the three-dimensional elevation control points, establish a two-dimensional reference curve, and with the cumulative plane arc length as the independent variable and the elevation of the three-dimensional elevation control points as the constraint, establish a continuous longitudinal target elevation function that does not rise in the downstream direction.

[0012] S4. Determine the target elevation of each DEM grid point within the two-dimensional vector boundary based on the continuous longitudinal target elevation function, and make the DEM grid points within the same local cross section have the same target elevation.

[0013] S5. Based on the update range defined by the two-dimensional vector boundary, the target elevation is written into the original DEM to obtain the candidate edit DEM;

[0014] S6, determine the countercurrent index based on the target elevation difference between adjacent positions along the flow direction, and determine the overflow index based on the difference between the target elevation of the flowing water area and the original DEM elevation in the quality inspection buffer zone on its shore.

[0015] S7. When the backflow index or the overflow index does not meet the corresponding preset quality threshold, adjust the elevation and / or constraint parameters of the three-dimensional elevation control point, re-establish the continuous longitudinal target elevation function and update the DEM until the preset quality threshold is met, and output the edited DEM.

[0016] Furthermore, in this invention, the two-dimensional vector boundary is obtained by reusing existing water system surface vector data or by acquiring data based on remote sensing images or orthophotos; the three-dimensional elevation control points are acquired in a stereoscopic observation environment, point cloud, measured elevation or reliable reference DEM, and are set at least at one or more of the following locations in the flowing water area: upstream end, downstream end, and bending position, confluence position, abrupt width change position or slope change position.

[0017] Furthermore, in this invention, in step S2, the three-dimensional elevation control points sorted by downstream direction are assumed to be... The cumulative planar arc length is obtained by accumulating the planar distances between adjacent control points. Before establishing the continuous longitudinal target elevation function, the corrected elevation is obtained through weighted least squares correction with monotonic constraints. ,make , where gmin is the minimum descent slope constraint that is not less than zero.

[0018] Furthermore, in this invention, the continuous longitudinal target elevation function adopts a piecewise cubic Hermite shape-preserving spline function; the tangent slope at the endpoint of each interval is determined based on the sign and weighted harmonic mean of the secant slopes of adjacent intervals, and the tangent slope at the endpoint is limited so that the spline function does not generate overshoot exceeding the corrected elevation range between adjacent control points and remains unchanged in the downstream direction.

[0019] Furthermore, in this invention, the specific process of step S4 is as follows:

[0020] For each DEM grid point within the two-dimensional vector boundary, determine the orthogonal projection position or the nearest projection position of the DEM grid point in the plane on the two-dimensional reference curve; that is, for a DEM grid point with planar coordinate q, solve s*(q)=arg min||qC(s)|| 2 Determine the projection position, where C(s) is a two-dimensional reference curve parameterized by the cumulative plane arc length;

[0021] Obtain the cumulative plane arc length corresponding to the projection position, and determine the function value of the continuous longitudinal target elevation function at the cumulative plane arc length as the target elevation of the DEM grid point, so that the DEM grid points in the same local cross section have the same target elevation.

[0022] Furthermore, in this invention, when there are multiple candidate projection positions for the same DEM grid point, the flowing water area is divided into multiple stations arranged along the flow direction by using the normal dividing lines at adjacent control points. The projection search is restricted to the arc length interval corresponding to the station area where the DEM grid point is located, and the candidate projection position with the smallest projection residual is selected within the arc length interval.

[0023] Furthermore, in this invention, an edge transition zone with a width of bt is set outside the two-dimensional vector boundary; the DEM grid points within the two-dimensional vector boundary adopt the target elevation, and the DEM grid points within the edge transition zone adopt the weighted value of the target elevation and the original DEM elevation, and the weight of the target elevation continuously decreases from 1 at the flowing water boundary to 0 at the outer edge of the edge transition zone.

[0024] Furthermore, in this invention, the maximum value of the positive part of the difference between the positive increment and the reverse flow tolerance in the adjacent target elevation difference obtained by sampling along the two-dimensional reference curve at a preset interval is determined as the reverse flow index; and the maximum absolute value of the adjacent slope difference or adjacent second-order elevation difference is determined as the continuity index. When the candidate edit DEM simultaneously satisfies that the reverse flow index is zero and the continuity index is not greater than the continuity threshold, it is determined that it meets the longitudinal elevation quality requirements.

[0025] Furthermore, in this invention, a preset low quantile of the effective original DEM elevation is calculated in the quality inspection buffer zone on both sides of each shoreline inspection position; the maximum amount by which the target elevation exceeds the sum of the corresponding preset low quantile and the overflow tolerance is determined as the overflow index, and when the overflow index is zero, it is determined that there is no river overflow.

[0026] Furthermore, in this invention, a minimum local editing window aligned with the original DEM mesh is determined based on the union of the two-dimensional vector boundary, edge transition zone, and quality check buffer. Only DEM data blocks intersecting with the local editing window are read, calculated, and written back. During output, at least one of the original DEM's spatial reference, resolution, cell alignment method, invalid value definition, and data type is maintained, and the input data identifier, control points, constraint parameters, and quality check results are recorded.

[0027] Compared with the prior art, the present invention has the following beneficial effects:

[0028] (1) This invention replaces the traditional segmented vector surface elevation assignment method with a small number of three-dimensional elevation control points, which significantly reduces the workload of manual elevation acquisition and editing. By setting only a small number of discrete three-dimensional elevation control points at the upstream and downstream ends of the flowing water area and at key locations such as bends, confluences, and abrupt width changes, and by using the continuous longitudinal target elevation function under cumulative plane arc length parameterization and monotonic constraints, the continuous water surface elevation that does not rise in the downstream direction can be automatically generated. This eliminates the need for frequent segmentation, segmented assignment, and repeated checks, greatly improving the editing efficiency of flowing water DEM.

[0029] (2) This invention achieves DEM reconstruction of flowing water with consistent cross-sectional elevation and continuous longitudinal descent by establishing a two-dimensional reference curve and orthogonal projection mechanism, overcoming the step-like jumps caused by traditional segmented elevation assignment and the reverse slope problem that may occur with ordinary interpolation. By using a piecewise cubic Hermite conformal spline function to construct a continuous longitudinal target elevation function, combined with the amplitude limiting processing of the tangent slope at the endpoints, the elevation interpolation between adjacent control points does not produce overshoot, fundamentally avoiding the technical defect that the downstream elevation is higher than the upstream elevation; at the same time, by projecting DEM grid points onto the two-dimensional reference curve and assigning target elevation values ​​at the corresponding arc lengths, the grid points in the same local cross-section obtain the same elevation, ensuring the lateral consistency of the water surface.

[0030] (3) This invention proposes a quantitative quality inspection method for backflow and overflow indicators, upgrading the quality evaluation of editing results from traditional visual observation and experience-based judgment of manually drawn longitudinal sections to repeatable and traceable quantitative criteria. By sampling and calculating the elevation difference between adjacent positions along the reference curve and the low quantile of the original DEM elevation in the shore buffer zone, backflow and overflow indicators are established respectively. With the addition of preset quality thresholds and iterative adjustment mechanisms, candidate edited DEMs that do not meet the quality requirements can be automatically located at the problem location and the control points can be adjusted until all quality indicators are met, thereby ensuring the controllability and reliability of the editing results.

[0031] (4) This invention effectively reduces the amount of data input / output and memory usage during DEM editing by constructing a local editing window and a data block-level read / write strategy. The smallest local editing window aligned with the original DEM grid is determined based on the union of the two-dimensional vector boundary, edge transition zone, and quality check buffer. Only the DEM data blocks intersecting with this window are read, calculated, and written back, avoiding the unnecessary overhead of reading and writing the entire large-format DEM. At the same time, the spatial reference, resolution, pixel alignment, invalid value definition, and data type of the original DEM are maintained during output, and the input data identifier, control point parameters, and quality check results are recorded, realizing the traceability of the editing process. Attached Figure Description

[0032] Figure 1 This is a flowchart of the method of the present invention.

[0033] Figure 2 The image shows the DEM of the flowing water area and its corresponding longitudinal section before editing using the method of this invention.

[0034] Figure 3 The image shows the DEM of the flowing water area and its corresponding longitudinal section after being edited using the method of this invention. Detailed Implementation

[0035] The present invention will be further described below with reference to the accompanying drawings and embodiments. The embodiments of the present invention include, but are not limited to, the following embodiments.

[0036] This invention discloses an efficient method for editing a flowing water DEM based on two-dimensional vectors and a small number of elevation points. This method is implemented using a DEM editing system, which includes a data acquisition module, a longitudinal modeling module, a two-dimensional expansion module, a raster update module, and a quality inspection and feedback module. The data acquisition module reads and unifies the coordinates of the DEM, two-dimensional vectors, and control points; the longitudinal modeling module performs control point sorting, arc length calculation, monotonic correction, and spline modeling; the two-dimensional expansion module performs station area construction and projection mapping; the raster update module performs local data block reading, replacement, fusion, and write-back; and the quality inspection and feedback module calculates various quality indicators and saves traceability information. Each module can be implemented by the same process, multiple threads, or multiple computing nodes.

[0037] like Figure 1 As shown, the specific implementation process of this invention is as follows:

[0038] S1. Obtain the original DEM, the two-dimensional vector boundary of the flowing water area, and multiple discrete three-dimensional elevation control points. Unify the three types of data to the same plane coordinate reference and elevation datum; the original DEM should include at least the raster extent, resolution, pixel starting position, invalid values, and elevation values; the three-dimensional elevation control points are denoted as P. i =(x i ,y i ,z i Two-dimensional vector boundaries can reuse existing water surface results or be acquired from remote sensing images or orthophotos; control points can be obtained from stereoscopic observation environments, point clouds, measured elevations or reliable reference DEMs, and should be set at least at one or more of the following locations in the flowing water area: upstream end, downstream end, bend location, confluence location, abrupt width change location or slope change location.

[0039] The two-dimensional vector boundary is checked for closure, repetition points, holes, self-intersection, and coordinate range. Based on the boundary, a flowing water update region W, an edge transition zone T, and a quality check buffer Q are constructed. The smallest outer grid range corresponding to the union of W, T, and Q and aligned with the DEM grid is used as a local editing window; in the block-stored DEM, only data blocks intersecting with this window are loaded.

[0040] S2, determine the upstream to downstream direction of the flowing water, sort the three-dimensional elevation control points according to the direction, and calculate the cumulative plane arc length of each control point. Control points are preferentially set at the upstream end, downstream end, river bends, confluences, locations of abrupt width changes, or slope changes; supplementary control points are added for river sections where the distance between adjacent control points is greater than the preset maximum distance. If the collected elevation does not meet the condition of not increasing downstream, elevation correction with monotonic constraints is used.

[0041] Let P be the three-dimensional elevation control point sorted by downstream direction. i =(x i,y i ,z i The cumulative planar arc length is obtained by summing the planar distances between adjacent control points. Before establishing the continuous longitudinal target elevation function, the corrected elevation is obtained through weighted least squares correction with monotonic constraints. ,make ≥gmin(s i+1 -s i ), where gmin is the minimum descent slope constraint that is not less than zero.

[0042] Let the number of sorted control points be n, where n≥2, then the cumulative plane arc length of the i-th control point is... for:

[0043] (1)

[0044] To avoid local reverse slopes caused by observation errors, the elevation of the original control points can be adjusted. Solve the following constrained optimization problem to obtain the corrected elevation. :

[0045]

[0046] (2)

[0047] In equation (2), The weights are determined by the confidence level of the control points. The minimum descent slope constraint is not less than zero; Local horizontal elevation is permissible, but downstream elevation is not. Correction results =u i Constrained optimization can be solved using ordinal-preserving regression, quadratic programming, or numerical methods with equivalent monotonic constraints.

[0048] S3, construct a two-dimensional reference curve C(s)=[X(s),Y(s)] parameterized with the cumulative planar arc length s based on the planar coordinates of the control points. T ;according to( Construct a continuous longitudinal target elevation function H(s) along the flow direction. Piecewise cubic Hermite conformal splines are preferred to avoid overshoot between control points caused by ordinary cubic splines.

[0049] make = , For internal control points, when When ≤0, let the slope of the tangent line be... =0; when When the slope is greater than 0, the weighted harmonic average of the slopes of adjacent secant lines is used to determine the value. :

[0050] , , (3)

[0051] The slope of the endpoint tangent is estimated on one side and limited to ensure that its sign is not adjacent. Conversely, and whose absolute value does not exceed a preset multiple | |. For s∈[ , Let t = (s - ) / Then the longitudinal target elevation function is:

[0052] (4)

[0053] From equations (2) to (4), H(s) is corrected at the control points and remains first-order continuous at the interval connections; when the input elevation does not increase downstream, H(s) remains unchanged within the interval between adjacent control points. When n=2, a linear function can be used as H(s), which still belongs to the continuous longitudinal target elevation function of this invention.

[0054] S4. For each DEM grid point q=(x,y) within W, calculate its orthogonal projection or nearest projection position on the two-dimensional reference curve C(s) in the plane, and take H(s) at the corresponding arc length as the target elevation. The projection is performed in the DEM horizontal coordinate plane, and its direction is perpendicular to the local flow direction. Therefore, grid points within the same local cross-section obtain the same elevation or the same elevation within the numerical tolerance.

[0055] (5)

[0056] (6)

[0057] In equation (5), L is the total arc length of the reference curve; when the optimal point is located at a non-endpoint, the orthogonality condition in equation (6) is satisfied. The elevation of the target water surface is given. For river bends with significant curvature, the W region can be divided into station areas arranged according to flow direction by the normal dividing lines at adjacent control points. The projection search is then limited to the arc length interval corresponding to the station area where the grid point is located, avoiding the incorrect projection of the same grid point onto another river segment that is spatially close but geographically distant. If multiple candidate projections still exist, the candidate with the smallest projection residual and whose arc length order is consistent with the station area is selected.

[0058] S5, adopted within W Replace the original DEM elevation When setting the outer edge transition band T, the fusion weights are determined by the normalized distance from the boundary, forming a candidate editable DEM. :

[0059] (7)

[0060] (8)

[0061] In equation (8), Let q be the distance from the flowing water boundary to the outer edge of the transition zone. Let α be the width of the transition zone; therefore, α is 1 at the boundary and 0 at the outer edge of the transition zone. For applications where modification of the shore-side DEM is not permitted, let α = 1. Only W is updated.

[0062] S6 performs longitudinal monotonicity, continuity, and shore-side overflow checks on the candidate editable DEM. M locations are sampled along C(s) at intervals no greater than a preset check interval. The countercurrent index R is calculated according to the following formula:

[0063] (9)

[0064] In equation (9) To account for the backflow tolerance of DEM elevation quantization error; R=0 indicates that no downstream elevation exceeding the tolerance occurred at any sampling location. To identify abrupt changes, the continuity index C can be further calculated:

[0065] (10)

[0066] Set shoreline inspection positions on both sides of the two-dimensional vector boundary. For the shoreside neighborhood on both sides of the j-th inspection position... and After removing invalid values ​​and obvious outliers, the ρ quantiles of the original DEM elevation were calculated. ν∈{L,R}; ρ takes a preset value within the range of 0 to 0.5 to reduce the impact of individual abnormally high points on the inspection. The overflow index O is:

[0067] (11)

[0068] In formula (11) This is for overflow tolerance. R=0, O=0, and C is not greater than the continuity threshold. If the candidate DEM meets the preset quality requirements, the system will determine that it does not; otherwise, it will locate the mileage position that generates the maximum index value, adjust the elevation of adjacent control points, add control points, change gmin or tangent limit parameters, and return to step S3 or S4 to recalculate. The adjustment can be completed by the operator on the longitudinal profile, or it can be automatically completed by simultaneously adding monotonic constraints and constraints on the upper limit of the shoreline elevation.

[0069] S7, when the backflow index or the overflow index does not meet the corresponding preset quality threshold, adjust the elevation and / or constraint parameters of the three-dimensional elevation control points, re-establish the continuous longitudinal target elevation function, and update the DEM until the preset quality threshold is met, and output the edited DEM. Determine the smallest local editing window aligned with the original DEM grid based on the union of the two-dimensional vector boundary, edge transition zone, and quality check buffer. Only read, calculate, and write back DEM data blocks intersecting with the local editing window. During output, maintain at least one of the original DEM's spatial reference, resolution, cell alignment method, invalid value definition, and data type, and record the input data identifier, control points, constraint parameters, and quality check results.

[0070] The two-dimensional reference curve C(s) can be directly fitted from the planar coordinates of the sorted control points, or the central axis can be extracted from the boundary of the two-dimensional vector and then the arc length of the central axis can be calibrated using the projection positions of the control points. For flowing water surfaces containing tributaries, the two-dimensional vector is decomposed into multiple river segments according to the confluence nodes, and reference curves and longitudinal target elevation functions are established for each segment. Elevation continuity constraints for each river segment are set at the confluence nodes.

[0071] In this embodiment, "a small number of elevation points" refers to discrete three-dimensional elevation control points that are significantly fewer in number than the number of DEM grid points, two-dimensional vector boundary vertices, or traditional segmented vector surfaces in a flowing water area. Their specific number is determined based on variations in river length, curvature, and slope, and is not intended as a subjective limitation on the scope of protection of this invention.

[0072] Take the original DEM generated by dense matching of satellite stereo images as an example. Figure 2 The shown area of ​​flowing water contains multiple irregular elevation protrusions and depressions, resulting in significant fluctuations in the longitudinal profile curve. The operator delineates the river surface boundary on the 2D image or loads an existing river surface vector. In a 3D observation environment, reliable water surface elevations are accurately determined at least at the upstream end, downstream end, and major bends of the river segment to obtain 3D elevation control points. Positioning in the 3D image can be achieved using rational polynomial coefficients (RPC), exterior orientation elements, regional network adjustment correction parameters, or combinations thereof.

[0073] The program converts the two-dimensional vector, control points, and original DEM to the same coordinate reference. After performing closure and self-intersection checks on the two-dimensional vector, a local window is generated according to the user-defined transition zone width and quality check width. For control points, the direction is first determined according to the specified upstream inlet and downstream outlet, and then sorting ambiguities are eliminated through nearest neighbor connectivity, reference curve projection, or manual confirmation. The cumulative plane arc length is calculated according to formula (1).

[0074] When the elevation of adjacent control points rises downstream beyond the tolerance, the program marks the corresponding point on the interface and performs monotonic correction using equation (2). If the operator sets a certain control point as a fixed point, its weight is increased or it is used as an equality constraint; the remaining control points are adjusted with minimal amplitude under the premise of satisfying the descent slope constraint. Then, a shape-preserving spline H(s) is established according to equations (3) and (4).

[0075] In an efficient implementation, a two-dimensional reference curve C(s) is first discretely sampled with a step size no greater than half the diagonal of the DEM pixels, and a spatial index of line segments is established. For each water surface grid point q in the local editing window, several candidate curve segments are first queried using the spatial index, and then the analytical projection is calculated on the candidate line segments. Let the endpoints of the line segments be... and The corresponding arc length is and ,but:

[0076] (12)

[0077] The clip function in equation (12) restricts λ to [0,1]. From all candidate line segments, the one with the smallest projected distance that satisfies the arc length range of the station area is selected. Then by Obtain the target elevation. Compared to searching point by point along the entire curve, spatial indexing limits projection calculations to a small number of candidate line segments; compared to processing the entire DEM, local window and data block updates further limit the number of raster cells.

[0078] After completing the water surface grid replacement and optional edge transition, the inspection positions are automatically generated along the reference curve and the left and right shorelines, and the indicators of equations (9) to (11) are calculated respectively. If backflow is found, the interface is positioned to the corresponding longitudinal section interval; if overflow is found, the interface is positioned to the corresponding shoreline position and the left or right bank. The operator adjusts the nearby control points and recalculates until all indicators meet the threshold.

[0079] Figure 3 The results after completing the above processing are shown. (Compared to...) Figure 2 In contrast, the abnormal undulations in the original flowing water area are replaced by a continuous water surface, the cross-sectional elevation remains consistent, and the longitudinal profile decreases continuously from upstream to downstream; the DEM outside the two-dimensional vector boundary remains unchanged or only smoothly connects within a preset transition zone. This result demonstrates that the present invention can achieve two-dimensional DEM reconstruction of flowing water areas with a small number of elevation control points.

[0080] For river sections with significant bends, if only the global nearest distance is used, grid points on the inner side of the bend may be mapped to adjacent but different river sections. In this embodiment, a plane normal line is constructed at each control point based on C′(s), and the intersection of adjacent normal lines and the two-dimensional flowing water surface is used to enclose the station area, and each station area is bound to the corresponding arc length interval. The grid points are solved only within the bound interval, thereby maintaining the topological consistency between the two-dimensional position and the river mileage.

[0081] For a two-dimensional flowing water surface containing multiple tributaries, it is divided into multiple single river segments at the confluence node. Each river segment is assigned a flow direction, control point, and H(s), and an elevation continuity constraint is applied to the confluence node to ensure that the difference between the elevations at the ends of the upstream tributaries and the starting elevation of the downstream main stream is within a preset confluence tolerance. During updates, target elevations are generated according to the station areas of each river segment, and results that satisfy the flow direction topology and are continuous with the confluence node are selected at overlapping pixels.

[0082] Through the above design, the present invention only needs to obtain the two-dimensional vector boundary of the flowing water and the three-dimensional elevation control points discretely set along the flow direction, without having to artificially divide the entire river into a large number of fixed elevation surfaces and assign values ​​to each segment, thus significantly reducing the number of elevation interactions.

[0083] The above embodiments are merely one of the preferred embodiments of the present invention and should not be used to limit the scope of protection of the present invention. Any modifications or refinements made to the main design concept and spirit of the present invention that are not of substantial significance, but solve the same technical problem as the present invention, should be included within the scope of protection of the present invention.

Claims

1. A method for efficient editing of a flowing water DEM based on two-dimensional vectors and a small number of elevation points, characterized in that, Includes the following steps: S1, obtain the original DEM, the two-dimensional vector boundary of the flowing water region, and multiple three-dimensional elevation control points located within the flowing water region and discretely set along the flow direction; S2, determine the flow direction, sort the three-dimensional elevation control points according to the flow direction, and calculate the cumulative plane arc length based on the plane coordinates of adjacent three-dimensional elevation control points; S3. Based on the plane coordinates of the three-dimensional elevation control points, establish a two-dimensional reference curve, and with the cumulative plane arc length as the independent variable and the elevation of the three-dimensional elevation control points as the constraint, establish a continuous longitudinal target elevation function that does not rise in the downstream direction. S4. Determine the target elevation of each DEM grid point within the two-dimensional vector boundary based on the continuous longitudinal target elevation function, and make the DEM grid points within the same local cross section have the same target elevation. S5. Based on the update range defined by the two-dimensional vector boundary, the target elevation is written into the original DEM to obtain the candidate edit DEM; S6, determine the countercurrent index based on the target elevation difference between adjacent positions along the flow direction, and determine the overflow index based on the difference between the target elevation of the flowing water area and the original DEM elevation in the quality inspection buffer zone on its shore. S7. When the backflow index or the overflow index does not meet the corresponding preset quality threshold, adjust the elevation and / or constraint parameters of the three-dimensional elevation control point, re-establish the continuous longitudinal target elevation function and update the DEM until the preset quality threshold is met, and output the edited DEM.

2. The efficient editing method for flowing water DEM based on two-dimensional vectors and a small number of elevation points according to claim 1, characterized in that, The two-dimensional vector boundary is obtained by reusing existing water system surface vector data or by acquiring data based on remote sensing images or orthophotos; the three-dimensional elevation control points are acquired in a stereoscopic observation environment, point cloud, measured elevation or reliable reference DEM, and are set at least at one or more of the following locations in the flowing water area: upstream end, downstream end, bend location, confluence location, width change location or slope change location.

3. The efficient editing method for flowing water DEM based on two-dimensional vectors and a small number of elevation points according to claim 2, characterized in that, In step S2, let the three-dimensional elevation control points sorted by downstream direction be... The cumulative planar arc length is obtained by accumulating the planar distances between adjacent control points. Before establishing the continuous longitudinal target elevation function, the corrected elevation is obtained through weighted least squares correction with monotonic constraints. ,make , where gmin is the minimum descent slope constraint that is not less than zero.

4. The efficient editing method for flowing water DEM based on two-dimensional vectors and a small number of elevation points according to claim 3, characterized in that, The continuous longitudinal target elevation function adopts a piecewise cubic Hermite shape-preserving spline function; the tangent slope at the endpoint of each interval is determined according to the sign and weighted harmonic mean of the secant slopes of adjacent intervals, and the tangent slope at the endpoint is limited so that the spline function does not produce overshoot exceeding the corrected elevation range between adjacent control points and maintains no increase in the downstream direction.

5. The efficient editing method for flowing water DEM based on two-dimensional vectors and a small number of elevation points according to claim 4, characterized in that, The specific process of step S4 is as follows: For each DEM grid point within the two-dimensional vector boundary, determine the orthogonal projection position or the nearest projection position of the DEM grid point in the plane on the two-dimensional reference curve; that is, for a DEM grid point with planar coordinate q, solve s*(q)=arg min||qC(s)|| 2 Determine the projection position, where C(s) is a two-dimensional reference curve parameterized by the cumulative plane arc length; Obtain the cumulative plane arc length corresponding to the projection position, and determine the function value of the continuous longitudinal target elevation function at the cumulative plane arc length as the target elevation of the DEM grid point, so that the DEM grid points in the same local cross section have the same target elevation.

6. The efficient editing method for flowing water DEM based on two-dimensional vectors and a small number of elevation points according to claim 5, characterized in that, When there are multiple candidate projection positions for the same DEM grid point, the flowing water area is divided into multiple stations arranged along the flow direction by using the normal dividing lines at adjacent control points. The projection search is restricted to the arc length interval corresponding to the station area where the DEM grid point is located, and the candidate projection position with the smallest projection residual is selected within the arc length interval.

7. The efficient editing method for flowing water DEM based on two-dimensional vectors and a small number of elevation points according to claim 6, characterized in that, An edge transition zone with a width of bt is set outside the two-dimensional vector boundary; the DEM grid points within the two-dimensional vector boundary adopt the target elevation, and the DEM grid points within the edge transition zone adopt the weighted value of the target elevation and the original DEM elevation, and the weight of the target elevation decreases continuously from 1 at the flowing water boundary to 0 at the outer edge of the edge transition zone.

8. The efficient editing method for flowing water DEM based on two-dimensional vectors and a small number of elevation points according to claim 7, characterized in that, The maximum value of the positive part of the difference between the positive increment and the reverse flow tolerance in the adjacent target elevation difference obtained by sampling along the two-dimensional reference curve at a preset interval is determined as the reverse flow index; and the maximum absolute value of the adjacent slope difference or adjacent second-order elevation difference is determined as the continuity index. When the candidate edit DEM simultaneously satisfies that the reverse flow index is zero and the continuity index is not greater than the continuity threshold, it is determined that it meets the longitudinal elevation quality requirements.

9. The efficient editing method for flowing water DEM based on two-dimensional vectors and a small number of elevation points according to claim 8, characterized in that, Within the quality inspection buffer zones on both sides of each shoreline inspection location, the preset low quantile of the effective original DEM elevation is calculated respectively; the maximum amount by which the target elevation exceeds the sum of the corresponding preset low quantile and the overflow tolerance is determined as the overflow index, and when the overflow index is zero, it is determined that there is no river overflow.

10. The efficient editing method for flowing water DEM based on two-dimensional vectors and a small number of elevation points according to claim 9, characterized in that, The minimum local editing window aligned with the original DEM mesh is determined based on the union of the two-dimensional vector boundary, edge transition zone, and quality check buffer. Only DEM data blocks intersecting with the local editing window are read, calculated, and written back. When outputting, at least one of the original DEM's spatial reference, resolution, cell alignment, invalid value definition, and data type is maintained, and the input data identifier, control points, constraint parameters, and quality check results are recorded.