Binary Mask

Before interpolation the DSM contains NaNs for every pixel that doesn't contain any valid measurements. This is a simple 8bit image containing the value 0 for every pixel of the DSM containing a NaN and the value 255 for every pixel of the DSM containing an actual measurement.

Example

The image on the left is a DSM and on the right is the respective binary mask. Both images were remapped and converted for viewing purposes: