TODO: To change the header's content go to Dr.Explain menu Options : Project Settings : HTML (CHM) Export : Setup HTML Template and Layout
Menu
Index

Thinning using Adaptive Grid

 
From March 2026 we have added in a menu item Tools -> Adaptive Grid (Data Thinning)
 
I am going to explain the theory and how to run it efficiently.
 

Overview

 
Adaptive Grid Thinning is a method used to reduce the number of points in a triangulated surface while preserving the essential characteristics of the original terrain. The method combines an initial grid-based point selection with an iterative error-controlled refinement process.
 
The objective is to create a reduced dataset that maintains the geometric integrity of the original surface within a specified vertical tolerance while significantly decreasing the number of points.
 

Method

 

1. Initial Point Set

 
The process begins with a set of points forming a triangulated irregular network (TIN). These points represent the original surface and include:
 
Boundary and protected points are preserved during thinning to maintain surface integrity.
 

2. Grid Generation

 
A regular rectangular grid is superimposed over the horizontal extent of the dataset.
 
The grid origin is typically defined by the minimum easting and northing coordinates of the dataset, and the grid spacing is specified by the user.
 
Each input point is assigned to a grid cell based on its horizontal coordinates.
 

3. Cell-Based Point Selection

 
For each grid cell, a small subset of representative points is selected from the points contained within that cell.
 
The selected points typically include
 
Selecting both minimum and maximum elevations ensures that local terrain extremes are preserved, while the centre point helps maintain surface shape in areas with limited relief.
 
The set of representative points from all grid cells is combined with the boundary and protected points to form the initial reduced point set.
 

4. Initial Surface Construction

 
A new triangulated surface is constructed using the reduced set of points. This surface represents the first approximation of the original terrain.
 

5. Error Evaluation

 
The accuracy of the reduced surface is evaluated by comparing it with the original surface.For each triangle in the reduced surface, several test locations are evaluated, typically including:
 
At each test location:
 
If this vertical difference exceeds the specified tolerance, the triangle is considered insufficiently represented.
 

6. Adaptive Point Insertion

 
When a triangle fails the error tolerance test, additional points from the original dataset are inserted into the reduced dataset.
 
A common approach is to identify the nearest original point associated with the area of maximum error that is not already included in the reduced surface.
 
These points are added to the reduced point set to improve the local representation of the surface.
 

7. Iterative Refinement

 
After new points are added, the reduced surface is reconstructed and the error evaluation process is repeated.
 
This iterative process continues until one of the following conditions is satisfied:
 

Characteristics of the Method

 
Adaptive grid thinning provides several advantages:
 
Because additional points are introduced only where necessary, the resulting surface maintains high fidelity while minimizing data size.
 

How this all works within Ezigrade

 
Within Ezigrade click on Tools -> Adaptive Grid and we have the following dialog:
 
 
 
When you are ready to go then hit Run.
 
Here is an example of a job with 250,000 points. I did run this successfully on the same job starting with over 1 million points.
 
 
We have a very discernable channel running to the south-east. We also have a ragged outline around the field which could even include trees etc.
 
Lets click on Tools -> Adaptive Grid
 
 
and start with max passes of 100, grid size of 25 and max vertical error of 40mm.
 
Click Run. The algorithm puts in the initial grid and then runs successive passes until the thinned surface is within our limits. In this case it took 18 passes to complete and took 9 minutes. (This is running under a debugger which slows things down). So yes it does take some initial time but will speed things up in the long run.
 
For nerds like me you would like some understanding of how things converge here is a table showing number of points and the max error:
 
Pass
Number Points
Error
1
11611
>4
2
20905
>4
3
33299
>4
4
46701
>4
5
56265
3.239
6
61011
0.767
7
62981
.758
8
63861
.430
9
64314
.299
10
64553
.161
11
64682
.091
12
64758
.086
13
64799
.088
14
64818
.075
15
64831
.051
16
64832
.053
17
64834
.048
18
64838
<0.04
 
On Pass 18 it stops automatically and we are shown the new job. And here is the same screen shot using the same contour interval and height ranges for a visual comparison:
 
 
The thinned example still shows the channel. The contours tend to be less noisier. All very subjective. But remember if you are grading with a 5m bucket then points on a 0.5m grid make little sense.
 
 
The online help was created with Dr.Explain