A New Simplified DSM-to-DTM Algorithm – dsm-to-dtm-step

In this paper we will present a simplified approach for extracting the ground level – a digital terrain model (DTM) – from the surface provided in a digital surface model (DSM). Most existing algorithms try to find the ground values in a digital surface model. Our approach works the opposite direction by detecting probable above ground areas. The main advantage of our approach is the possibility to use it with incomplete DSMs containing much no data values which can be e.g. occlusions in the calculated DSM. A smoothing or filling of such original derived DSMs will destroy much information which is very useful for deriving a ground surface from the DSM. Since the presented approach needs steep edges to detect potential high objects it will fail on smoothed and filled DSMs. After presenting the algorithm it will be applied to a test area in Salzburg and compared to a terrain model freely available from the Austrian government.


Introduction
For many applications a representation of the ground is needed.Such so called digital terrain models (DTMs) are the basis e.g. for water run-off simulations or extracting elevated objects from a normalized digital elevation model (nDEM).Deriving heights from photogrammetric approaches like stereo imagery from airborne or spaceborne cameras deliver the surface of the objects -so called digital surface models (DSMs).These contain beneath the visible ground all objects above the ground.To derive the ground (DTM) many approaches already exist but none of these approaches work absolutely perfect in all cases.
Already since the 1980s there is intense research on digital terrain models [1].A DTM is in general derived from a DSM by detecting and removing all objects and filling these areas.The problem is so the detection of off-ground objects.The Classical morphological approach [2] for example just searches for each point in a DSM the lowest neighbour in a given radius around this point.Newer approaches include e.g. the geodesic dilation as described in [3] or the multi-directional slope dependent (MSD) DTM generation method by [4] which is an extension to the directional filtering concept of [5].The Normalized Volume above Ground (NVAG) method proposed in [6] is an extension to [4] including also the volume of the objects on the scanline.
Our presented algorithm is designed for usage together with unfilled DSMs still containing occluded areas as no-data values.For processing such DSMs we simplify the approach of [4] by just taking height steps into account and ignoring all no-data areas between.

Materials and Methods
Our here presented DSM-to-DTM-step approach is a simplified version of many multidirectional ground detection methods like MSD [4] or NVAG [6].These approaches are designed for detecting ground areas in filled DSMs using much sophisticated methods for discriminating slopes in a DSM from natural slopes like on hills and object-induced slopes like such from buildings or trees.In contrast we obtain unfilled DSMs from very high resolution satellite imagery like WorldView or Pléiades with ground sampling distances of about 0.5 m.In such unfilled DSMs most of the no-data regions are occlusions near steep walls.
If such DSMs get filled these occlusions often get interpolated to a soft slope which prevent ground detection algorithms to perform correctly.Our presented approach works in contrast on the unfilled DSMs just using the last valid height and skipping any no-data areas.In the case of occlusions the last valid height is the ground, the next valid height is on the roof which results in a steep step.
So the algorithm tries to remove areas of high elevated objects from a DSM starting on a steep raising edge and lasting until a mostly not so steep edge at the end.
In detail the image is processed in four (left-right, right-left, top-bottom, bottom-top) or eight (also including all diagonals) directions and each valid height h is compared to the previous valid height h in this direction -just ignoring any no-data values.If the new height is more than UpStep u higher than the old all following pixels in this line are marked as "high" until a new height lower than DownStep d below the old height is found.All other pixels are left "unknown".
Fig. 1 illustrates the method.In the top row the processing of the first iteration is shown in one line of a DSM.First the line is processed from left to right.Each height h is compared to the last found valid height h .If h > h + u all following values are set to "high" and moved to "unknown" or no-data values (depicted as dotted red lines in the bottom in fig. 1) until a valid down-step h < h − d is detected.Else (h ≤ h + u) nothing is changed.The arrows in fig. 1 are large with continous lines if the criterion fits and small with dotted lines if the criterion does not fit.The red arrows stand for steps up, the green for steps down.So for all four or eight directions pixels are marked "high" and these values are ignored (as no-data) in the next processing steps.This may be repeated for a provided number of iterations.Afterwards the input-DSM with all high pixels set to no-data is written out.To derive the final DTM this non-high-DSM has to be interpolated using any common interpolation-method.
The default parameters are: UpStep = 2 m, DownStep = 1 m, NumDirections = 4 and NumIterations = 2.The method is implemented in C in the XDibias processing environment of DLR-IMF.The main advantage of this method is that it works very good on unfilled DSMs from very high resolution satellites with ground sampling distances (GSD) of about 0.5 m.There the no-data areas are originating mostly from occlusions occuring near steep walls.

Differences per class
Using the classification shown in fig. 4 allows a more detailed evaluation of the derivations per class.Table 1 shows the classes, the coverage in percent of the class in the whole DTM and for each of the four derived test DTMs the mean shift µ and the standard deviation σ.Fig. 10 show the individual distribution plots for each class.Looking in more detail to the results shown in tab. 1 shows that the mean values as also the standard deviations are best for the filtered T5f approach in flat areas (grass and ground).Also for built-up areas the T5f approach delivers mostly good results.The unfiltered DSM-to-DTM-step experiments are also nearly perfect in flat areas but show larger mean deviations in built-up areas.In forested areas the simple classical approach seems to be much better than any tried version of the new DSM-to-DTM-step method.Figure 10.Histograms of differences DTM i − DTM re f for classes (top to bottom) "buildings", "forest", "grass", "ground" and "water", from left to right: DTM TM, T3, T5, T5f, binning to 0.5 m, percentage of values

Evaluation of nDEMs, tree-and building-masks
A main usage of a DTM is the derivation of off-ground objects or a nDEM.So in this evaluation we calculated the nDEMs for all derived DTMs and from them a tree-and a building-mask using a height-threshold of 3 m.Afterwards these masks were compared to the masks derived using the ground-truth DTM.For this the whole number of pixels of the reference height mask were calculated for vegetation (N v ) and non-vegetation (N n ) areas.Using the DTM under investigation for the derived height mask HM i = (DSM − DTM i > 3 m) the true positives (TP), false positives (FP) and the false negatives (FN) were calculated as Table 2 shows the results using the completeness as TP i /N and the correctness as 1 − (FP i + FN i )/N.As can be seen in tab. 2 the correctness increased from the simple T3, T5 over TM to T5f but the completeness decreases.The filtered version of the step algorithm delivers the nominally best results of all calculations using the DSM-to-DSM-step method.But in contrast to the classical method the completeness of detected above ground objects can not be reached by the new method.To sum up the results from sections 3 and 4 the results of the DSM-to-DTM-step approach give better results for build-up areas conserving steep natural hills in cities better than the traditional morphological approach.

Conclusions
The presented simplified DSM-to-DTM-step method for deriving DTMs from unfilled DSMs gives good results in urban areas conserving also hilly regions in builtup context.But overall the results compared to a ground truth DTM or to the also simple traditional morphological DTM extraction method shows no significant improvements in the resulting DTMs.As in most approaches for extracing DTMs from DSMs any method is not useful for all cases.So our final recommendation will be calculating the DTMs using different methods, classifying the terrain using terrain and spectral classification methods and finally fusing the results of the different DTM methods using different weights for each classified type of terrain.In the previous example the DSM-to-DTM-step method may be used in steep hills in urban areas whereas other methods will be better in rural areas.

Iteration 1 -Figure 1 .
Figure 1.Illustration of DSM-to-DTM-step method, top: first iteration, bottom: second iteration, left: processing from left to right, right: processing from right to left (www.preprints.org)| NOT PEER-REVIEWED | Posted: 2 July 2018 doi:10.20944/preprints201807.0017.v1 3. Experiments 3.1.Data For an experimental evaluation a DSM derived from a Pléiades stereo triplet acquired on 2015-09-01 was used as input.For comparison a DTM provided as open government data for Salzburg in 5 m resolution was used.It is available from https://www.data.gv.at/katalog/dataset/d585e816-1a36-4c76-b2dc-6db487d22ca3 (900 MB for the whole federal state of Salzburg) covered by the Creative Commons License "Namensnennung 3.0 Österreich".The DSM calculated from the Pléiades triplet is shown in figs. 2 or 3 on the left side, the filled DSM in the center and the same sections from the reference DTM in figs. 2 or 3 on the right.

Fig. 11
Fig. 11 shows a profile across an area in the old city center starting from the river Salzach, going south across the cupola of the Dom and crossing the hill with castle Hohensalzburg on it.The filled input DSM is shown in red, the reference DTM in green.All other profile lines are the derived DTMs TM, T3, T5 and T5f.

Table 1 .
Classes used for detailled evaluation, coverage in percent of the class in the whole DTM, mean shift µ and standard deviation σ for DTM i − DTM re f per class.

Table 2 .
Completeness (how many pixels were "high" in both DTM and reference) and correctness (how many pixels were same "high" or "low" in both) for all derived DTMs