Improve DEM
The code below uses the Toolbox SDK, which you can install with pip install toolbox-sdk.
Additional Python examples: using SDK, using Requests. If you prefer other programming language or need full API reference, check out Toolbox OpenAPI as well.
Docs
Improves Digital Elevation Model, makes the resulting contour lines smoother and simpler.
Input, all fields are required:
Raster file - DEM file in TIFF format downloaded from NextGIS Data;
-
Interpolation method used to enhance the DEM file. Available methods:
Nearest neighbor (nearest)
Bilinear (bilinear)
Cubic (cubic)
Cubic spline (cubicspline)
Lanczos (lanczos)
Linear (average)
RMS (rms)
Mode (mode);
Interval between contours - Vertical step of the contour lines in meters;
Simplification step for the contour lines. Integer (for example, 2), decimal separated by a dot (for example, 0.02) or exponential notation (for example, 2e-2)
Refinement, % - Improvement of the DEM file resolution, in percents. Shows how much the pixel size should increase/decrease. For example, a value of 1000 % will result in 10 times smaller pixels
Output:
TIFF file of the refined DEM;
GeoPackage file of the contour lines.
Input raster¶
Processed raster and contours generated from it¶
Try the tool in action
Click on the Demo button above the tool form. The fields are filled in with demo values.
Click on the Run button.