shareloc.dtm_reader

Image DTM Image to handle DTM image data. Inherits from Image Class with DTM particularities.

Module Contents

Classes

dtm_reader

class dtm_reader to handle DTM image data

Functions

interpolate_geoid_height(geoid_filename, positions[, ...])

terrain to index conversion

class shareloc.dtm_reader.dtm_reader(dtm_filename, geoid_filename=None, roi=None, roi_is_in_physical_space=False, fill_nodata='rio_fillnodata', fill_value=None)[source]

Bases: shareloc.image.Image

class dtm_reader to handle DTM image data Inherits from Image Class with DTM particularities

fill_nodata(strategy='rio_fillnodata', max_search_distance=100.0, smoothing_iterations=0, fill_value=0.0)[source]

fill nodata in DTM image

Parameters:
  • strategy (str) – fill strategy (‘constant’/’min’/’median’/’max’/’mean’/’rio_fillnodata’/)

  • max_search_distance (float) – fill max_search_distance

  • smoothing_iterations (int) – smoothing_iterations

  • fill_value (float) – fill value for constant strategy. fill value is used for ‘roi_fillnodata’ residuals nodata, if None ‘min’ is used

shareloc.dtm_reader.interpolate_geoid_height(geoid_filename, positions, interpolation_method='linear')[source]

terrain to index conversion retrieve geoid height above ellispoid

Parameters:
  • geoid_filename (str) – geoid_filename

  • positions (2D numpy array: (number of points, [long coord, lat coord])) – geodetic coordinates

  • interpolation_method (str) – default is ‘linear’ (interpn interpolation method)

Returns:

geoid height

Return type:

1 numpy array (number of points)